mspt.email package

Submodules

mspt.email.Email module

class mspt.email.Email.Email(emailUser, emailPwd, emailSMTP, emailSMTPPort)[source]

Bases: object

The class Email aims to send an e-mail.

Parameters:
  • emailUser – The e-mail address from where the e-mail will be send.
  • emailPwd – The e-mail password corresponding to the account emailUser.
  • emailSMTP – SMPT server to send the e-mail.
  • emailSMTPPort – SMPT port to send the e-mail.
mail(to, subject, text, attach=None, html=True)[source]

Send an e-mail with text and attachement.

Parameters:
  • to – recipient’s e-mail address
  • subject – e-mail subject
  • text – body of the e-mail
  • attach – Attachment: list pf local path to files being attached
  • html – True (default) if ‘text’ is formated as html, False otherwise.
mspt.email.Email.htmlTextBoldRed(text)[source]

Format a text in red bold html.

Parameters:text – Text to format
Returns:Formatted text.

Module contents