https://github.com/simalexan/api-lambda-send-email-ses
API and a Lambda Function for sending emails
https://github.com/simalexan/api-lambda-send-email-ses
Last synced: 11 days ago
JSON representation
API and a Lambda Function for sending emails
- Host: GitHub
- URL: https://github.com/simalexan/api-lambda-send-email-ses
- Owner: simalexan
- Created: 2018-12-10T04:08:34.000Z (over 6 years ago)
- Default Branch: master
- Last Pushed: 2020-03-07T22:34:15.000Z (over 5 years ago)
- Last Synced: 2024-10-11T21:26:20.331Z (9 months ago)
- Language: JavaScript
- Homepage: https://serverless.pub
- Size: 5.86 KB
- Stars: 57
- Watchers: 4
- Forks: 23
- Open Issues: 4
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
- jimsghstars - simalexan/api-lambda-send-email-ses - API and a Lambda Function for sending emails (JavaScript)
README
# Api Gateway -> Lambda (Send Email) -> SES (Simple Email Service)
## Description
This is a serverless component consisting of:
- an Api Gateway with a POST `/send` endpoint, that requires three parameters:
- `toEmails`, Array of strings, that represent all the emails you want to send an email to,
- `subject`, a string representing the subject of the email
- `message`, a string representing the message of the email, can be either HTML or regular text
It also accepts two optional ones: `ccEmails` and `replyToEmails`, both of Array of strings type.- a Lambda that sends an email to one or more specified email addresses. Also, depending if the `message` is in a Text or HTML format, it will send it in either of those formats. The `toEmails`,`ccEmails`, and `replyToEmails` parameters must be of Array type.
It's a Nuts & Bolts application component for AWS Serverless Application Repository.
## Deployment Parameters
This component has two CloudFormation deployment parameters:
- `FromEmail`, a required parameter, represents the email sender. Must be a SES verified email. If you attempt to send email using a non-verified address or domain, the operation results in an "Email address not verified" error.
- `CorsOrigin`, an optional parameter, where you can restrict access to only specified domains.## Latest Release - 1.1.0
- Upgrade to Node.js 12.x LTS
## Roadmap - Upcoming changes
Here are the upcoming changes that I'll add to this serverless component:
- ESLint
- Tests