| :py:mod:`airflow.providers.amazon.aws.hooks.sns` |
| ================================================ |
| |
| .. py:module:: airflow.providers.amazon.aws.hooks.sns |
| |
| .. autoapi-nested-parse:: |
| |
| This module contains AWS SNS hook |
| |
| |
| |
| Module Contents |
| --------------- |
| |
| Classes |
| ~~~~~~~ |
| |
| .. autoapisummary:: |
| |
| airflow.providers.amazon.aws.hooks.sns.SnsHook |
| airflow.providers.amazon.aws.hooks.sns.AwsSnsHook |
| |
| |
| |
| |
| .. py:class:: SnsHook(*args, **kwargs) |
| |
| Bases: :py:obj:`airflow.providers.amazon.aws.hooks.base_aws.AwsBaseHook` |
| |
| Interact with Amazon Simple Notification Service. |
| |
| Additional arguments (such as ``aws_conn_id``) may be specified and |
| are passed down to the underlying AwsBaseHook. |
| |
| .. seealso:: |
| :class:`~airflow.providers.amazon.aws.hooks.base_aws.AwsBaseHook` |
| |
| .. py:method:: publish_to_target(self, target_arn, message, subject = None, message_attributes = None) |
| |
| Publish a message to a topic or an endpoint. |
| |
| :param target_arn: either a TopicArn or an EndpointArn |
| :param message: the default message you want to send |
| :param message: str |
| :param subject: subject of message |
| :param message_attributes: additional attributes to publish for message filtering. This should be |
| a flat dict; the DataType to be sent depends on the type of the value: |
| |
| - bytes = Binary |
| - str = String |
| - int, float = Number |
| - iterable = String.Array |
| |
| |
| |
| |
| .. py:class:: AwsSnsHook(*args, **kwargs) |
| |
| Bases: :py:obj:`SnsHook` |
| |
| This hook is deprecated. |
| Please use :class:`airflow.providers.amazon.aws.hooks.sns.SnsHook`. |
| |
| |