This module contains AWS SES Hook

Module Contents

class*args, **kwargs)[source]


Interact with Amazon Simple Email Service.

Additional arguments (such as aws_conn_id) may be specified and are passed down to the underlying AwsBaseHook.

See also


send_email(self, mail_from: str, to: Union[str, Iterable[str]], subject: str, html_content: str, files: Optional[List[str]] = None, cc: Optional[Union[str, Iterable[str]]] = None, bcc: Optional[Union[str, Iterable[str]]] = None, mime_subtype: str = 'mixed', mime_charset: str = 'utf-8', reply_to: Optional[str] = None, return_path: Optional[str] = None, custom_headers: Optional[Dict[str, Any]] = None)[source]

Send email using Amazon Simple Email Service

  • mail_from -- Email address to set as email's from

  • to -- List of email addresses to set as email's to

  • subject -- Email's subject

  • html_content -- Content of email in HTML format

  • files -- List of paths of files to be attached

  • cc -- List of email addresses to set as email's CC

  • bcc -- List of email addresses to set as email's BCC

  • mime_subtype -- Can be used to specify the sub-type of the message. Default = mixed

  • mime_charset -- Email's charset. Default = UTF-8.

  • return_path -- The email address to which replies will be sent. By default, replies are sent to the original sender's email address.

  • reply_to -- The email address to which message bounces and complaints should be sent. "Return-Path" is sometimes called "envelope from", "envelope sender", or "MAIL FROM".

  • custom_headers -- Additional headers to add to the MIME message. No validations are run on these values and they should be able to be encoded.


Response from Amazon SES service with unique message identifier.

Was this entry helpful?