aws / aws-sdk-php-laravel

A Laravel 5+ (and 4) service provider for the AWS SDK for PHP
http://aws.amazon.com/sdkforphp/
Apache License 2.0
1.64k stars 242 forks source link

Can't receiving SNS messages #203

Closed Zubair-Iftikhar closed 2 years ago

Zubair-Iftikhar commented 2 years ago

Confirm by changing [ ] to [x] below:

Version of AWS SDK for PHP? aws/aws-sdk-php-laravel: ^3.6 aws/aws-sdk-php: 3.192.1

Version of AWS Service Provider for Laravel?

Version of Laravel (php artisan --version)? 8.59.0

Version of PHP (php -v)? 7.4.10

Describe the question

$Otpcode = mt_rand(1000, 9999);
$message = $Otpcode . " is your Ask Mommy verification code.";
$sms = AWS::createClient('sns');
$res = $sms->publish([
    'Message' => $message,
    'PhoneNumber' => '+92314xxxxxx',
    'MessageAttributes' => [
        'AWS.SNS.SMS.SMSType' => [
            'DataType' => 'String',
            'StringValue' => 'Transactional',
        ]
    ],
]);
dd($res );

can not received sms

Receiving MessageId with statusCode 200 it's means message successfully send... but on mobile not received ..i've test on different mobile & countries too.. can you help me debug the issue...

github-actions[bot] commented 2 years ago

⚠️COMMENT VISIBILITY WARNING⚠️

Comments on closed issues are hard for our team to see. If you need more assistance, please either tag a team member or open a new issue that references this one. If you wish to keep having a conversation with other community members under this issue feel free to do so.