AWS Lambda to SES

AWS Lambda → Simple Email Service

Creates a Lambda function that sends an email with Amazon SES.

When invoked, Lambda sends an email to Amazon SES. You can customize the email based on the needs of your application by supplying the function with the event contents.
The email address of the sender ('from') is provided in the AWS SAM deployment. This email message can contain both plain text and HTML content. The body and subject of the email message are passed into the function as an event. The receiver email address is also supplied in the event.

< Back to all patterns

GitHub icon Download this pattern (.zip)

GitHub icon View this pattern on GitHub


Clone repo

git clone https://github.com/aws-samples/serverless-patterns/cd serverless-patterns/lambda-ses

Deploy

sam deploy --guided


Testing

See the GitHub repo for detailed testing instructions.

Cleanup

1. Delete the stack: sam delete --stack-name STACK_NAME.
2. Confirm the stack has been deleted: aws cloudformation list-stacks --query "StackSummaries[?contains(StackName,'STACK_NAME')].StackStatus"

Created by:

Curtis Darst

Curtis Darst

Curtis is a Solutions Architect for EDU at Amazon Web Services based in the US.