Publish

The Publish activity is used to publish a message on an SNS Topic.

General

On the General tab, you can select shared resource to establish a connection to the Amazon server. The following table lists the configurations on the General tab of the Publish activity.

Field Module Property? Description
Name No Name to be displayed as a label for the activity in the process.
SNS Client Yes Required. The SNS activities use the same client shared resource configuration as the SQS activities. Select SNS Client configuration either from an existing resource or create a new resource, by using the Choose/Create Default Resource icon.

Description

On the Description tab, you can provide a short description for the Publish activity.

Input

On the Input tab, you can specify input values for the Publish activity. The following table lists the input elements on the Input tab of the Publish activity.

Input Item Data Type Description
TopicARN String Optional. The Amazon Resource Name for the topic. Either TopicARN, TargetARN or PhoneNumber must be specified but not all.
TargetARN String Optional. The Amazon Resource Name for the endpoint to which you want to publish the output. Either TopicARN, TargetARN or PhoneNumber must be specified but not all.
Subject String Optional. The value to be used as the subject line when the message is delivered to email endpoints.
MessageStructure String Optional. Set MessageStructure to JSON, if you want to send a different message for each protocol.
PhoneNumber String Optional. Specify the phone number using the E.164 format to send an SMS message. If you don't specify a value for the PhoneNumber parameter, you must specify a value for the TargetARN or TopicARN parameters. For more details about Sending an SMS Message and configuring the message attributes, see Sending an SMS Message.
SnsMessage String The message you want to send to the topic.
Body String Required. Content of the message.
MessageAttrs Complex Optional. Any message attributes that were included with the message. Each attribute is composed of a Name, Type, and Value.
Name String The name of the attribute.
Type String The type of the attribute. The attribute types supported are:
  • String
  • Number
  • Binary
  • String.Array
Note: String.Array type expects comma-separated values. To map the activity input, use the following XPath function: tib:concat-sequence-format(<String-repeating-element>, ",").
Value String A string representation of the attribute value.
Note: Provide Base64 encoded string as input when the attribute of the Type field is Binary.

Output

On the Output tab, you can find the output value of the Publish activity. The following table lists the output element on the Output tab of the Publish activity.

Output Item Data Type Description
MessageId String Contains the message identifier for the message.

Fault

The Fault tab lists exceptions that are generated by this activity.

Fault Data Type Description
SQSException Any exception generated by the activity after execution. It has the following fields: ErrorCode and ErrorMessage.
ErrorCode String The plug-in error code for the exception. For more information, see Error Codes topic.
ErrorMessage String The plug-in error message for the exception. It contains the error message from the AWS SQS API call that failed.

Sending an SMS Message

You can send a message directly to the phone number without subscribing the phone number to an Amazon SNS topic. You can use the MessageAttrs to set the values for the following attribute names:
Name Type Value
AWS.SNS.SMS.SenderID String A custom ID that contains up to 11 alphanumeric characters, including at least one letter and no spaces. The sender ID is displayed as the message sender on the receiving device. If the SenderID is not defined, then the default SenderID is used. For the countries and regions that support sender IDs, see Supported Regions and Countries.
AWS.SNS.SMS.MaxPrice String The maximum amount in USD that you are willing to spend to send an SMS message.
Note: The message is not sent, if the cost of sending the message exceeds the amount specified in the MaxPrice.
AWS.SNS.SMS.SMSType String The type of message that you are sending:
  • Promotional- Noncritical messages, such as marketing messages. Amazon SNS optimizes the message delivery to incur the lowest cost.
    Note: By default, Promotional is used as a value for MessageAttrs.
  • Transactional- Critical messages that support customer transactions, such as one-time passcodes for multi-factor authentication. Amazon SNS optimizes the message delivery to achieve the highest reliability.