Mail-CLI, send mail with mailgun service.
Project description
Mail CLI
Encapsulation for email senders, include mailgun service and SMTP mailer.
Install
To install mail helper, run this command in your terminal:
$ pip install -U git+https://github.com/debugtalk/mail-cli.git#egg=mail-cli
Usage
$ python mailcli.py -h
usage: mailcli.py [-h] [-V] [-u MAILGUN_SMTP_USERNAME]
[-p MAILGUN_SMTP_PASSWORD] [--mail-sender MAIL_SENDER]
[--mail-recepients [MAIL_RECEPIENTS [MAIL_RECEPIENTS ...]]]
[--mail-subject MAIL_SUBJECT] [--mail-content MAIL_CONTENT]
[--mail-content-path MAIL_CONTENT_PATH]
Mail-CLI, send mail with mailgun service.
optional arguments:
-h, --help show this help message and exit
-V, --version show version
-u MAILGUN_SMTP_USERNAME, --mailgun-smtp-username MAILGUN_SMTP_USERNAME
Specify mailgun smtp username.
-p MAILGUN_SMTP_PASSWORD, --mailgun-smtp-password MAILGUN_SMTP_PASSWORD
Specify mailgun smtp password.
--mail-sender MAIL_SENDER
Specify email sender.
--mail-recepients [MAIL_RECEPIENTS [MAIL_RECEPIENTS ...]]
Specify email recepients.
--mail-subject MAIL_SUBJECT
Specify email subject.
--mail-content MAIL_CONTENT
Specify email content.
--mail-content-path MAIL_CONTENT_PATH
Load file content as mail content.
Examples
send mail with content
$ python mailcli.py \
-u "user@mail.com" \
-p "pwd123" \
--mail-sender "sender@mail.com" \
--mail-recepients test1@mail.com test2@mail.com \
--mail-subject subject-test \
--mail-content hello-world
send mail with file content
$ python mailcli.py \
-u "user@mail.com" \
-p "pwd123" \
--mail-sender "sender@mail.com" \
--mail-recepients test1@mail.com test2@mail.com \
--mail-subject subject-test \
--mail-content-path 1534006836.html
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
mailcli-0.3.0.tar.gz
(2.5 kB
view hashes)
Built Distribution
Close
Hashes for mailcli-0.3.0-py2.py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | ab3ec7abf4830643879d8bf87b32e5dca84d8abfbd03df16b28e73bd46a51045 |
|
MD5 | cd9c012ff1f4cef9c420029570be1a8a |
|
BLAKE2b-256 | d390d55a514ad1df799048dc588d2df4c29d48316b57bcdab16c061983f81b5b |