Amazon Simple Notification Service (Amazon SNS) is a web service that makes it easy to set up, operate, and send notifications from the cloud. It provides developers with a highly scalable, flexible, and cost-effective capability to publish messages from an application and immediately deliver them to subscribers or other applications. It is designed to make web-scale computing easier for developers.
Additional Info
Requires Mule Enterprise License |
Yes |
Requires Entitlement |
No |
Mule Version |
3.5.0 or higher |
Configs
Configuration
<sns:config>
Connection Management
Attributes
Name | Java Type | Description | Default Value | Required |
---|---|---|---|---|
name |
The name of this configuration. With this name can be later referenced. |
x |
||
accessKey |
The access key provided by Amazon |
x |
||
secretKey |
The secret key provided by Amazon |
x |
||
sessionToken |
|
|||
tryDefaultAWSCredentialsProviderChain |
boolean |
Set it to true to try first to obtain credentials from AWS environment. See: http://docs.aws.amazon.com/java-sdk/latest/developer-guide/credentials.html#using-the-default-credential-provider-chain |
|
|
maxConnections |
Sets the maximum number of allowed open HTTP connections. |
50 |
|
|
region |
Set the topic region endpoint |
|
||
testTopicArn |
Arn of the topic to test. This is used only to test the connectivity and validate credentials with Amazon SNS. |
|
||
protocol |
Protocol |
The optional communication protocol to use when sending requests to AWS. Communication over HTTPS is the default |
HTTPS |
|
proxyHost |
The optional proxy port |
|
||
proxyPort |
The optional proxy port |
|
||
proxyUsername |
The optional proxy username |
|
||
proxyPassword |
The optional proxy password |
|
||
proxyDomain |
The optional proxy domain |
|
||
proxyWorkstation |
The optional proxy workstation |
|
||
socketTimeout |
The amount of time to wait (in milliseconds) for data to be transferred over an established, open connection before the connection is timed out. A value of 0 means infinity, and is not recommended. |
50000 |
|
|
connectionTimeout |
The amount of time to wait (in milliseconds) when initially establishing a connection before giving up and timing out. A value of 0 means infinity, and is not recommended. |
50000 |
|
Role Configuration
<sns:role-config>
Connection Management
Attributes
Name | Java Type | Description | Default Value | Required |
---|---|---|---|---|
name |
The name of this configuration. With this name can be later referenced. |
x |
||
accessKey |
The access key provided by Amazon |
x |
||
secretKey |
The secret key provided by Amazon |
x |
||
roleARN |
The Role ARN allows you to cross account access without using security credentials. |
x |
||
tryDefaultAWSCredentialsProviderChain |
boolean |
Set it to true to try first to obtain credentials from AWS environment. See: http://docs.aws.amazon.com/java-sdk/latest/developer-guide/credentials.html#using-the-default-credential-provider-chain |
|
|
maxConnections |
Sets the maximum number of allowed open HTTP connections. |
50 |
|
|
region |
Set the topic region endpoint |
|
||
testTopicArn |
Arn of the topic to test. This is used only to test the connectivity and validate credentials with Amazon SNS. |
|
||
protocol |
Protocol |
The optional communication protocol to use when sending requests to AWS. Communication over HTTPS is the default |
HTTPS |
|
proxyHost |
The optional proxy port |
|
||
proxyPort |
The optional proxy port |
|
||
proxyUsername |
The optional proxy username |
|
||
proxyPassword |
The optional proxy password |
|
||
proxyDomain |
The optional proxy domain |
|
||
proxyWorkstation |
The optional proxy workstation |
|
||
socketTimeout |
The amount of time to wait (in milliseconds) for data to be transferred over an established, open connection before the connection is timed out. A value of 0 means infinity, and is not recommended. |
50000 |
|
|
connectionTimeout |
The amount of time to wait (in milliseconds) when initially establishing a connection before giving up and timing out. A value of 0 means infinity, and is not recommended. |
50000 |
|
Processors
Add permission
<sns:add-permission>
Adds a statement to a topic's access control policy, granting access for the specified AWS accounts to the specified actions.
Attributes
Name | Java Type | Description | Default Value | Required |
---|---|---|---|---|
config-ref |
Specify which config to use |
x |
||
addPermission |
Container for the parameters to the AddPermission operation. |
#[payload] |
|
Confirm subscription
<sns:confirm-subscription>
The ConfirmSubscription action verifies an endpoint owner's intent to receive messages by validating the token sent to the endpoint by an earlier Subscribe action. If the token is valid, the action creates a new subscription and returns its Amazon Resource Name (ARN). This call requires an AWS signature only when the AuthenticateOnUnsubscribe flag is set to "true".
Attributes
Name | Java Type | Description | Default Value | Required |
---|---|---|---|---|
config-ref |
Specify which config to use |
x |
||
confirmSubscription |
Container for the parameters to the ConfirmSubscription operation. |
#[payload] |
|
Create platform application
<sns:create-platform-application>
Creates a platform application object for one of the supported push notification services, such as APNS and GCM, to which devices and mobile apps may register.
Attributes
Name | Java Type | Description | Default Value | Required |
---|---|---|---|---|
config-ref |
Specify which config to use |
x |
||
createPlatformApplication |
Container for the parameters to the CreatePlatformApplication operation. |
#[payload] |
|
Create platform endpoint
<sns:create-platform-endpoint>
Creates an endpoint for a device and mobile app on one of the supported push notification services. CreatePlatformEndpoint requires the PlatformApplicationArn that is returned from CreatePlatformApplication.
Attributes
Name | Java Type | Description | Default Value | Required |
---|---|---|---|---|
config-ref |
Specify which config to use |
x |
||
createPlatformEndpoint |
Container for the parameters to the CreatePlatformEndpoint operation. |
#[payload] |
|
Create topic
<sns:create-topic>
The CreateTopic action creates a topic to which notifications can be published. Users can create at most 100 topics
Attributes
Name | Java Type | Description | Default Value | Required |
---|---|---|---|---|
config-ref |
Specify which config to use |
x |
||
topicName |
The name of the topic you want to create. |
x |
Returns
Return Java Type | Description |
---|---|
The Amazon Resource Name (ARN) assigned to the created topic. |
Delete endpoint
<sns:delete-endpoint>
Deletes the endpoint for a device and mobile app from Amazon SNS.
Delete platform application
<sns:delete-platform-application>
Deletes a platform application object for one of the supported push notification services, such as APNS and GCM.
Delete topic
<sns:delete-topic>
The DeleteTopic action deletes a topic and all its subscriptions. Deleting a topic might prevent some messages previously sent to the topic from being delivered to subscribers. This action is idempotent, so deleting a topic that does not exist does not result in an error.
Get endpoint attributes
<sns:get-endpoint-attributes>
Retrieves the endpoint attributes for a device on one of the supported push notification services, such as GCM and APNS.
Attributes
Name | Java Type | Description | Default Value | Required |
---|---|---|---|---|
config-ref |
Specify which config to use |
x |
||
endpointArn |
EndpointArn for GetEndpointAttributes input. |
x |
Get platform application attributes
<sns:get-platform-application-attributes>
Retrieves the attributes of the platform application object for the supported push notification services, such as APNS and GCM.
Attributes
Name | Java Type | Description | Default Value | Required |
---|---|---|---|---|
config-ref |
Specify which config to use |
x |
||
platformApplicationArn |
PlatformApplicationArn for GetPlatformApplicationAttributesInput. |
x |
Get subscription attributes
<sns:get-subscription-attributes>
The GetSubscriptionAttributes action returns all of the properties of a subscription.
Attributes
Name | Java Type | Description | Default Value | Required |
---|---|---|---|---|
config-ref |
Specify which config to use |
x |
||
subscriptionArn |
The ARN of the subscription whose properties you want to get |
x |
Get topic attributes
<sns:get-topic-attributes>
The GetTopicAttributes action returns all of the properties of a topic. Topic properties returned might differ based on the authorization of the user.
Attributes
Name | Java Type | Description | Default Value | Required |
---|---|---|---|---|
config-ref |
Specify which config to use |
x |
||
topicArn |
The ARN of the topic whose properties you want to get. |
x |
List endpoints by platform application
<sns:list-endpoints-by-platform-application>
Lists the endpoints and endpoint attributes for devices in a supported push notification service, such as GCM and APNS.
Attributes
Name | Java Type | Description | Default Value | Required |
---|---|---|---|---|
config-ref |
Specify which config to use |
x |
||
endpointsByPlatform |
Container for the parameters to the ListEndpointsByPlatformApplication operation. |
#[payload] |
|
Returns
Return Java Type | Description |
---|---|
Returns a list of the requester's endpoints. |
List platform applications
<sns:list-platform-applications>
Lists the platform application objects for the supported push notification services, such as APNS and GCM.
Attributes
Name | Java Type | Description | Default Value | Required |
---|---|---|---|---|
config-ref |
Specify which config to use |
x |
||
nextToken |
NextToken string is used when calling ListPlatformApplications action to retrieve additional records that are available after the first page results. |
|
Returns
Return Java Type | Description |
---|---|
a list of the requester's PlatformApplications. |
List subscriptions
<sns:list-subscriptions>
The ListSubscriptions action returns a list of the requester's subscriptions. Each call returns a limited list of subscriptions, up to 100. If there are more subscriptions, a NextToken is also returned. Use the NextToken parameter in a new ListSubscriptions call to get further results.
Attributes
Name | Java Type | Description | Default Value | Required |
---|---|---|---|---|
config-ref |
Specify which config to use |
x |
||
nextToken |
Token returned by the previous ListSubscriptions request |
|
Returns
Return Java Type | Description |
---|---|
Returns a list of the requester's subscriptions. |
List subscriptions by topic
<sns:list-subscriptions-by-topic>
The SubscriptionsByTopic action returns a list of the subscriptions to a specific topic. Each call returns a limited list of subscriptions, up to 100. If there are more subscriptions, a NextToken is also returned. Use the NextToken parameter in a new SubscriptionsByTopic call to get further results.
Attributes
Name | Java Type | Description | Default Value | Required |
---|---|---|---|---|
config-ref |
Specify which config to use |
x |
||
subscriptionsByTopic |
Container for the parameters to the ListSubscriptionsByTopic operation. |
#[payload] |
|
Returns
Return Java Type | Description |
---|---|
Returns a list of the subscriptions to a specific topic. |
List topics
<sns:list-topics>
The ListTopics action returns a list of the requester's topics. Each call returns a limited list of topics, up to 100. If there are more topics, a NextToken is also returned. Use the NextToken parameter in a new ListTopics call to get further results.
Attributes
Name | Java Type | Description | Default Value | Required |
---|---|---|---|---|
config-ref |
Specify which config to use |
x |
||
nextTopic |
Token returned by the previous ListTopics request. |
|
Publish
<sns:publish>
The Publish action sends a message to all of a topic's subscribed endpoints. When a messageId is returned, the message has been saved and Amazon SNS will attempt to deliver it to the topic's subscribers shortly. The format of the outgoing message to each subscribed endpoint depends on the notification protocol selected.
Attributes
Name | Java Type | Description | Default Value | Required |
---|---|---|---|---|
config-ref |
Specify which config to use |
x |
||
publish |
Container for the parameters to the publish operation. |
#[payload] |
|
Remove permission
<sns:remove-permission>
The RemovePermission action removes a statement from a topic's access control policy.
Attributes
Name | Java Type | Description | Default Value | Required |
---|---|---|---|---|
config-ref |
Specify which config to use |
x |
||
removePermission |
Container for the parameters to the RemovePermission operation. |
#[payload] |
|
Set endpoint attributes
<sns:set-endpoint-attributes>
Sets the attributes for an endpoint for a device on one of the supported push notification services, such as GCM and APNS.
Set platform application attributes
<sns:set-platform-application-attributes>
Sets the attributes of the platform application object for the supported push notification services, such as APNS and GCM.
Attributes
Name | Java Type | Description | Default Value | Required |
---|---|---|---|---|
config-ref |
Specify which config to use |
x |
||
platformApplicationAttributes |
Container for the parameters to the SetPlatformApplicationAttributes operation. |
#[payload] |
|
Set subscription attributes
<sns:set-subscription-attributes>
The SubscriptionAttributes action allows a subscription owner to set an attribute of the topic to a new value.
Attributes
Name | Java Type | Description | Default Value | Required |
---|---|---|---|---|
config-ref |
Specify which config to use |
x |
||
subscriptionAttributes |
Container for the parameters to the SetSubscriptionAttributes operation. |
#[payload] |
|
Set topic attributes
<sns:set-topic-attributes>
The TopicAttributes action allows a topic owner to set an attribute of the topic to a new value.
Attributes
Name | Java Type | Description | Default Value | Required |
---|---|---|---|---|
config-ref |
Specify which config to use |
x |
||
topicAttributes |
Container for the parameters to the SetTopicAttributes operation. |
#[payload] |
|
Subscribe
<sns:subscribe>
The Subscribe action prepares to subscribe an endpoint by sending the endpoint a confirmation message. To actually create a subscription, the endpoint owner must call the ConfirmSubscription action with the token from the confirmation message. Confirmation tokens are valid for three days.
Attributes
Name | Java Type | Description | Default Value | Required |
---|---|---|---|---|
config-ref |
Specify which config to use |
x |
||
subscribe |
Container for the parameters to the Subscribe operation. |
#[payload] |
|
Returns
Return Java Type | Description |
---|---|
The ARN of the subscription, if the service was able to create a subscription immediately (without requiring endpoint owner confirmation). |
Unsubscribe
<sns:unsubscribe>
The Unsubscribe action deletes a subscription. If the subscription requires authentication for deletion, only the owner of the subscription or the its topic's owner can unsubscribe, and an AWS signature is required. If the Unsubscribe call does not require authentication and the requester is not the subscription owner, a final cancellation message is delivered to the endpoint, so that the endpoint owner can easily resubscribe to the topic if the Unsubscribe request was unintended.