Skip to content

Commit cff1fce

Browse files
authored
Update README.md
1 parent a4878ac commit cff1fce

File tree

1 file changed

+7
-4
lines changed

1 file changed

+7
-4
lines changed

README.md

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@ More advanced features like support for topics could be added in the future.
1919
- [Setting up the AwsSns service](#setting-up-the-aws-sns-service)
2020
- [Usage](#usage)
2121
- [Available Message methods](#available-message-methods)
22+
- [Common Problems](#common-problems)
2223
- [Changelog](#changelog)
2324
- [Testing](#testing)
2425
- [Security](#security)
@@ -130,7 +131,9 @@ More information about the SMS Attributes can be found on the [AWS SNS Docs](htt
130131
It's important to know that the attributes set on the message will override the
131132
default ones configured in your AWS account.
132133

133-
## Exception handling
134+
## Common Problems
135+
136+
### Exception Handling
134137
Exceptions are not thrown by the package in order to give other channels a chance to work properly. Instead, a `Illuminate\Notifications\Events\NotificationFailed` event is dispatched. For debugging purposes you may listen to this event in the `boot` method of `EventServiceProvider.php`.
135138

136139
```php
@@ -143,10 +146,10 @@ Event::listen(function (\Illuminate\Notifications\Events\NotificationFailed $eve
143146
});
144147
```
145148

146-
## Laravel Vapor
147-
By default [Laravel Vapor](https://vapor.laravel.com/) creates a role `laravel-vapor-role` in AWS which does not have permission to send SMS via SNS. This results in SMS being sent successfully in local but will not be sent on a Vapor environment. Note that no exception will be thrown as described above.
149+
### Lack of Permissions on AWS
150+
By default [Laravel Vapor](https://vapor.laravel.com/) creates the role `laravel-vapor-role` in AWS, which does not have permissions to send SMS via SNS. This results in SMS being sent successfully in local environments but will not be sent on a Vapor environment. Your messages might also not be sent if you are using an ID/Secret pair for a particular IAM user that can't interact with SNS.
148151

149-
In the AWS console, navigate to Identity and Access Management (IAM) and click on roles. Select `laravel-vapor-role` then add the `AmazonSNSFullAccess` policy to enable sending in Vapor.
152+
In either case, you need to make sure the credentials you are using (either your role or user) are allowed to interact with the AWS services your application needs. On IAM (Identity and Access Management), you may attach the AWS Managed policy `AmazonSNSFullAccess` or a more granular custom policy to the role/user your application is using.
150153

151154
## Changelog
152155

0 commit comments

Comments
 (0)