Amazon SES
You can send email notifications through your AWS SES service.
Unique Identifier
Each provider is identified by a unique identifier. Unique identifier of Amazon SES provider is ses
Enabling AWS SES
To enable AWS SES provider, login to your Engagespot dashboard, goto Channels -> Email and enable AES SES Provider.
AWS SES provider uses email
attribute in your user's profile as the primary address to deliver the notifications. So make sure your user's profile has the email
attribute set.
Create an AWS SES API Key and Secret using your AWS IAM Service
To connect your AWS SES service with Engagespot, you must create an IAM user with SendEmail
permission.
- After logging into your AWS Console, search for the
IAM
service.
- Then, on the sidebar, navigate to Access Management -> Users, and click Add Users
- Set a username, and credential type to Access Key - Programmatic Access
- In the next step (Permissions), select Attach Existing Policies Directly, and click Create Policy
- In the create policy dialog, select "JSON" tab, and paste the following policy. After that, click on the Next:Tags button at the bottom, then Next:Review button, and specify a name for your policy and finally click Create policy button.
{
"Version": "2012-10-17",
"Statement": [
{
"Sid": "VisualEditor0",
"Effect": "Allow",
"Action": ["ses:SendRawEmail", "ses:SendEmail", "ses:GetSendStatistics"],
"Resource": "*"
}
]
}
- After creating the policy, go back to the previous tab (Add User -> Set Permissions), and choose the policy you've just created. After that, click on the Next:Tags button at the bottom, then Next:Review button and finally Create user button.
- Note the AWS Access Key ID and Secret Access Key
-
Now, goto your Engagespot dashboard -> Channels -> Email -> AWS SES.
-
Add the Access Key ID, Secret, Region and From Email. (Region where you created your AWS SES service, for example
us-east
)
The FROM_EMAIL
should be created as a Verified Identity in your SES account.
Also, by default your AWS SES account will be in sandbox mode which means you can send emails only to verified identities.To enable production access, you must send a request to AWS. Read more details here
AWS SES Configurations.
AWS SES requires the following configurations.
Configuration | Description | Required | Example |
---|---|---|---|
ACCESS_KEY_ID | AWS IAM Access Key ID | Yes | |
SECRET_ACCESS_KEY | AWS IAM Secret Access Key | Yes | |
REGION | Your AWS SES Region | Yes | us-west-2 |
FROM_EMAIL | Verified From Email identity on your SES account | Yes |
Overriding Configurations
SES provider allows you to override all the above configurations (and you can specify several more options) while sending a notification through Engagespot API, using the https://api.engagespot.co/v3/notifications
endpoint.
To override the configurations, you must supply them via override
-> ses
parameter of the above API. Configurations override values should be passed via _config
object, and you can override subject
, text
, html
and from_name
For example,
{
"notification": {
"title": "Anand commented on your photo",
"message": "Hey Steve, you're looking cool 😎. Who took this photo?",
"url": "https://your-app.com/photos/17293739",
"category": "comment"
},
"recipients": ["steve@example.com"],
"override": {
"ses": {
"_config": {
"ACCESS_KEY_ID": "ANNHYAAJMLCPWRWGCNBSKHFY",
"SECRET_ACCESS_KEY": "nxxkjjuUtgVvcHjKpOJfdERFCJklytVbnkkksjshsgHHhsn",
"REGION": "us-west-2",
"FROM_EMAIL": "from@yourverifieddomain.com",
},
"from_name": "From Name",
"subject": "Custom email subject",
"text": "Email body plaintext",
"html": "Email body with <h1>HTML</h1> support",
}
}
}