airflow.providers.amazon.aws.hooks.ses
¶
This module contains AWS SES Hook
Module Contents¶
Classes¶
Interact with Amazon Simple Email Service. |
|
This hook is deprecated. |
- class airflow.providers.amazon.aws.hooks.ses.SesHook(*args, **kwargs)[source]¶
Bases:
airflow.providers.amazon.aws.hooks.base_aws.AwsBaseHook
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, to, subject, html_content, files=None, cc=None, bcc=None, mime_subtype='mixed', mime_charset='utf-8', reply_to=None, return_path=None, custom_headers=None)[source]¶
Send email using Amazon Simple Email Service
- Parameters
mail_from (str) – Email address to set as email’s from
to (Union[str, Iterable[str]]) – List of email addresses to set as email’s to
subject (str) – Email’s subject
html_content (str) – Content of email in HTML format
files (Optional[List[str]]) – List of paths of files to be attached
cc (Optional[Union[str, Iterable[str]]]) – List of email addresses to set as email’s CC
bcc (Optional[Union[str, Iterable[str]]]) – List of email addresses to set as email’s BCC
mime_subtype (str) – Can be used to specify the sub-type of the message. Default = mixed
mime_charset (str) – Email’s charset. Default = UTF-8.
return_path (Optional[str]) – The email address to which replies will be sent. By default, replies are sent to the original sender’s email address.
reply_to (Optional[str]) – 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 (Optional[Dict[str, Any]]) – Additional headers to add to the MIME message. No validations are run on these values and they should be able to be encoded.
- Returns
Response from Amazon SES service with unique message identifier.
- Return type
- class airflow.providers.amazon.aws.hooks.ses.SESHook(*args, **kwargs)[source]¶
Bases:
SesHook
This hook is deprecated. Please use
airflow.providers.amazon.aws.hooks.ses.SesHook
.