Amazon Integrator V6 - Online Help
Amazon Integrator V6
Questions / Feedback?

Publish Method

Publishes a message to the topic.

Syntax

sns.publish(topicArn, subject, message, [callback])

Callback

The 'callback' parameter specifies a function which will be called when the operation completes (or an error is encountered). If the 'callback' parameter is not specified, then the method will block and will not return until the operation completes (or an error is encountered).

The callback for this method is defined as:

function(err, data){ }

'err' is the error that occurred. If there was no error, then 'err' is 'null'.

'data' is the value returned by the method.

'err' has 2 properties which hold detailed information:

err.code
err.message

Remarks

This method publishes a message to the topic specified by TopicArn.

The Subject parameter is optional and specifies the "Subject" line of the message delivered to e-mail endpoints. Subjects must be ASCII text that begins with a letter, number or punctuation mark; must not include line breaks or control characters; and must be less than 100 characters long.

The Message parameter is the text to send. Messages must be UTF-8 encoded strings at most 64 KB in size (65536 bytes, not 65536 characters).

The same message will be delivered to all subscribers. To send different messages based on the protocol used by the subscription call PublishCustom instead.

The method returns the unique MessageId assigned to the published message. It will be at most 100 characters in length.

 
 
Copyright (c) 2017 /n software inc. - All rights reserved.
Build 6.0.6240.0