https://github.com/kirillseva/mailgunner
Send emails from R using mailgun
https://github.com/kirillseva/mailgunner
email mailgun r
Last synced: 4 months ago
JSON representation
Send emails from R using mailgun
- Host: GitHub
- URL: https://github.com/kirillseva/mailgunner
- Owner: kirillseva
- Created: 2016-08-24T21:10:45.000Z (over 8 years ago)
- Default Branch: master
- Last Pushed: 2018-02-22T16:29:31.000Z (about 7 years ago)
- Last Synced: 2024-08-13T07:13:26.951Z (8 months ago)
- Topics: email, mailgun, r
- Language: R
- Homepage:
- Size: 5.86 KB
- Stars: 3
- Watchers: 1
- Forks: 3
- Open Issues: 2
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
- jimsghstars - kirillseva/mailgunner - Send emails from R using mailgun (R)
README
# Send emails from R using mailgun.
## How to use
1. Create an account with [Mailgun](https://www.mailgun.com/).
2. Obtain your API key and domain name from mailgun. Follow [official documentation](https://documentation.mailgun.com/en/latest/quickstart-sending.html#send-with-smtp-or-api).
3. Set `MAILGUNNER_DOMAIN_NAME` and `MAILGUNNER_API_KEY` environment variables.
4. Enjoy!```r
emails <- c(
"[email protected]",
"[email protected]",
"[email protected]",
"[email protected]"
)params <- list(
from = c("Kirill Sevastyanenko", "kirillseva"),
subject = paste("An exciting investment opportunity"),
text = paste0(
"This email was sent to you from R. If you are not excited yet - you should be!\n",
"Contact me at https://github.com/kirillseva for investment opportunities."
),
tag = "investment",
to = emails
)
do.call(mailgunner::send_email, params)
```