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.1.tar.gz
(3.5 kB
view hashes)
Built Distribution
Close
Hashes for mailcli-0.3.1-py2.py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | f410080632191af3965987c486d815eb1e826c1624d5072618a82d8eb7f8a631 |
|
MD5 | ca3ce3ece35ceb3a9bca34fe36442cf4 |
|
BLAKE2b-256 | 7192761a180383f1fda9b9f0155632e71c9b417650ace425cde5585ca506cbf5 |