abstraction layer on top of the email package to make sending emails a little bit easier
Project description
easymail
========
[![Build Status](https://secure.travis-ci.org/mfussenegger/easymail.png?branch=master)](https://travis-ci.org/mfussenegger/easymail)
The email package in pythons standard library is pretty low level.
Easymail aims to add an abstraction layer on top that sets some (hopefully) sane
defaults.
These defaults include:
* using utf-8 encoding by default.
* important headers (like Date)
A simple example:
from easymail import Email
from smtplib import SMTP
e = Email('My Name <mymail@somedomain.com>', 'recipient@otherdomain.org')
e.subject = 'hello world'
e.body = 'with some non-äscii charöcters'
smtp = SMTP('mymailserver.com')
smtp.sendmail(*e.args)
Slightly more advanced:
from easymail import Email, Attachment
from smtplib import SMTP
e = Email('My Name <mymail@somedomain.com>', 'recipient@otherdomain.org')
e.subject = 'hello world'
e.body = 'with some non-äscii charöcters'
e.attachments.append(Attachment('./path/to/picture.png'))
e.attachments.append(Attachment('./path/to/document.pdf'))
smtp = SMTP('mymailserver.com')
smtp.sendmail(*e.args)
Dependencies
============
Pure Python 3.5+
License
=======
Easymail is licensed under the MIT license.
========
[![Build Status](https://secure.travis-ci.org/mfussenegger/easymail.png?branch=master)](https://travis-ci.org/mfussenegger/easymail)
The email package in pythons standard library is pretty low level.
Easymail aims to add an abstraction layer on top that sets some (hopefully) sane
defaults.
These defaults include:
* using utf-8 encoding by default.
* important headers (like Date)
A simple example:
from easymail import Email
from smtplib import SMTP
e = Email('My Name <mymail@somedomain.com>', 'recipient@otherdomain.org')
e.subject = 'hello world'
e.body = 'with some non-äscii charöcters'
smtp = SMTP('mymailserver.com')
smtp.sendmail(*e.args)
Slightly more advanced:
from easymail import Email, Attachment
from smtplib import SMTP
e = Email('My Name <mymail@somedomain.com>', 'recipient@otherdomain.org')
e.subject = 'hello world'
e.body = 'with some non-äscii charöcters'
e.attachments.append(Attachment('./path/to/picture.png'))
e.attachments.append(Attachment('./path/to/document.pdf'))
smtp = SMTP('mymailserver.com')
smtp.sendmail(*e.args)
Dependencies
============
Pure Python 3.5+
License
=======
Easymail is licensed under the MIT license.
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
easymail-0.3.0.tar.gz
(31.7 kB
view details)
Built Distribution
File details
Details for the file easymail-0.3.0.tar.gz
.
File metadata
- Download URL: easymail-0.3.0.tar.gz
- Upload date:
- Size: 31.7 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | c644de6081a167e698cae411cfd60d94bf14cf931060de1d50cdc67bd8369735 |
|
MD5 | 4437f00107ffc5a764be1f96eaa212e4 |
|
BLAKE2b-256 | c858fe655f925aa282506dc11e8dfc0bcf6ca8c219fcdee7802586f44fe0cdad |
File details
Details for the file easymail-0.3.0-py2.py3-none-any.whl
.
File metadata
- Download URL: easymail-0.3.0-py2.py3-none-any.whl
- Upload date:
- Size: 5.3 kB
- Tags: Python 2, Python 3
- Uploaded using Trusted Publishing? No
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | e9d8c7d8cf8d9d035d53d68e4132038bcf86a8fa5b9682e8b6c315b4b3053c1b |
|
MD5 | e6397cad4d368d4c103079ab5ace4f90 |
|
BLAKE2b-256 | 2a48c70ffa1f87de7b65df92d6056cbaa74be307eb782a5ba71899d4d742f578 |