Skip to content
/ em Public

Python class that allows me to send emails through Gmail

License

Notifications You must be signed in to change notification settings

imgerson/em

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 

Repository files navigation

#Em

Little Python class that allows me to connect to Gmail and send emails for me. It's pretty basic.

Will be working on it based on my own needs. Please feel free to fork/contribute in any way you want.

Here's an example of what it does.

#!/usr/bin/env python3


from em import ConfigEm, Em


subject = 'Hey There'
message = 'Hello World.'

conf = ConfigEm()
conf.user = 'email@gmail.com'
conf.user_password = '!passwordomg!'

em = Em(conf=conf)
em.login()
em.set_message(toaddr='someemail@gmail.com', subject=subject,
    message=message)
em.attach(attachment='pdf.pdf')
em.send()
em.logout()

About

Python class that allows me to send emails through Gmail

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages