https://github.com/thesurlydev/aws-ses-classic-howto
How to send emails from the command line using AWS SES (Classic)
https://github.com/thesurlydev/aws-ses-classic-howto
Last synced: 5 months ago
JSON representation
How to send emails from the command line using AWS SES (Classic)
- Host: GitHub
- URL: https://github.com/thesurlydev/aws-ses-classic-howto
- Owner: thesurlydev
- License: apache-2.0
- Created: 2021-10-29T15:02:55.000Z (over 4 years ago)
- Default Branch: main
- Last Pushed: 2021-10-29T15:21:46.000Z (over 4 years ago)
- Last Synced: 2025-02-06T18:52:28.618Z (over 1 year ago)
- Size: 6.84 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# How to Send Email Messages from the Command Line Using AWS SES (Classic)
The following outlines how to send email messages from the command line using [AWS SES](https://awscli.amazonaws.com/v2/documentation/api/latest/reference/ses/index.html) and the [AWS CLI](https://docs.aws.amazon.com/cli/latest/userguide/cli-chap-install.html).
## Using shorthand
```
aws ses send-email \
--from "test@digitalsanctum.com" \
--destination "ToAddresses=shane@digitalsanctum.com" \
--message "Subject={Data=test1,Charset=utf8},Body={Text={Data=testing123,Charset=utf8},Html={Data=,Charset=utf8}}"
```
## Using local files
```
aws ses send-email \
--from test@digitalsanctum.com \
--destination file://destination.json \
--message file://message.json
```
where `destination.json` is something like:
```
{
"ToAddresses":["shane@digitalsanctum.com"]
}
```
and `message.json` is something like:
```
{
"Subject": {
"Data": "test1",
"Charset": "utf-8"
},
"Body": {
"Text": {
"Data": "testing123",
"Charset": "utf-8"
}
}
}
```