Skip to main content

@swamp/aws/sns

v2026.04.03.2

AWS SNS infrastructure models

Labels

awssnscloudinfrastructure

Contents

Install

$ swamp extension pull @swamp/aws/sns

Release Notes

  • Updated: subscription, topic, topic_inline_policy

@swamp/aws/sns/subscriptionv2026.04.03.2subscription.ts

Global Arguments

ArgumentTypeDescription
namestringInstance name for this resource (used as the unique identifier in the factory pattern)
ReplayPolicy?stringSpecifies whether Amazon SNS resends the notification to the subscription when a message's attribute changes.
RawMessageDelivery?booleanWhen set to true, enables raw message delivery. Raw messages don't contain any JSON formatting and can be sent to Amazon SQS and HTTP/S endpoints.
Endpoint?stringThe subscription's endpoint. The endpoint value depends on the protocol that you specify.
FilterPolicy?stringThe filter policy JSON assigned to the subscription. Enables the subscriber to filter out unwanted messages.
TopicArnstringThe ARN of the topic to subscribe to.
RedrivePolicy?stringWhen specified, sends undeliverable messages to the specified Amazon SQS dead-letter queue. Messages that can't be delivered due to client errors are held in the dead-letter queue for further analysis or reprocessing.
DeliveryPolicy?stringThe delivery policy JSON assigned to the subscription. Enables the subscriber to define the message delivery retry strategy in the case of an HTTP/S endpoint subscribed to the topic.
Region?stringFor cross-region subscriptions, the region in which the topic resides.If no region is specified, AWS CloudFormation uses the region of the caller as the default.
SubscriptionRoleArn?stringThis property applies only to Amazon Data Firehose delivery stream subscriptions.
FilterPolicyScope?stringThis attribute lets you choose the filtering scope by using one of the following string value types: MessageAttributes (default) and MessageBody.
ProtocolstringThe subscription's protocol.
createCreate a SNS Subscription
getGet a SNS Subscription
ArgumentTypeDescription
identifierstringThe primary identifier of the SNS Subscription
updateUpdate a SNS Subscription
deleteDelete a SNS Subscription
ArgumentTypeDescription
identifierstringThe primary identifier of the SNS Subscription
syncSync SNS Subscription state from AWS

Resources

state(infinite)— SNS Subscription resource state
@swamp/aws/sns/topicv2026.04.03.2topic.ts

Global Arguments

ArgumentTypeDescription
namestringInstance name for this resource (used as the unique identifier in the factory pattern)
DisplayName?stringThe display name to use for an SNS topic with SMS subscriptions. The display name must be maximum 100 characters long, including hyphens (-), underscores (_), spaces, and tabs.
KmsMasterKeyId?stringThe ID of an AWS managed customer master key (CMK) for SNS or a custom CMK. For more information, see [Key terms](https://docs.aws.amazon.com/sns/latest/dg/sns-server-side-encryption.html#sse-key-terms). For more examples, see KeyId in the *API Reference*. This property applies only to [server-side-encryption](https://docs.aws.amazon.com/sns/latest/dg/sns-server-side-encryption.html).
DataProtectionPolicy?stringThe body of the policy document you want to use for this topic. You can only add one policy per topic. The policy must be in JSON string format. Length Constraints: Maximum length of 30,720.
Subscription?arrayThe SNS subscriptions (endpoints) for this topic. If you specify the Subscription property in the AWS::SNS::Topic resource and it creates an associated subscription resource, the associated subscription is not deleted when the AWS::SNS::Topic resource is deleted.
FifoTopic?booleanSet to true to create a FIFO topic.
ContentBasedDeduplication?booleanEnables content-based deduplication for FIFO topics. By default, ContentBasedDeduplication is set to false. If you create a FIFO topic and this attribute is false, you must specify a value for the MessageDeduplicationId parameter for the [Publish](https://docs.aws.amazon.com/sns/latest/api/API_Publish.html) action. When you set ContentBasedDeduplication to true, SNS uses a SHA-256 hash to generate the MessageDeduplicationId using the body of the message (but not the attributes of the message). (
ArchivePolicy?stringThe archive policy determines the number of days SNS retains messages. You can set a retention period from 1 to 365 days.
FifoThroughputScope?string
Tags?arrayThe list of tags to add to a new topic. To be able to tag a topic on creation, you must have the sns:CreateTopic and sns:TagResource permissions.
TopicName?stringThe name of the topic you want to create. Topic names must include only uppercase and lowercase ASCII letters, numbers, underscores, and hyphens, and must be between 1 and 256 characters long. FIFO topic names must end with.fifo. If you don't specify a name, CFN generates a unique physical ID and uses that ID for the topic name. For more information, see [Name type](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-name.html). If you specify a name, you can't perform
SignatureVersion?stringThe signature version corresponds to the hashing algorithm used while creating the signature of the notifications, subscription confirmations, or unsubscribe confirmation messages sent by Amazon SNS. By default, SignatureVersion is set to 1.
TracingConfig?stringTracing mode of an SNS topic. By default TracingConfig is set to PassThrough, and the topic passes through the tracing header it receives from an SNS publisher to its subscriptions. If set to Active, SNS will vend X-Ray segment data to topic owner account if the sampled flag in the tracing header is true.
DeliveryStatusLogging?arrayThe DeliveryStatusLogging configuration enables you to log the delivery status of messages sent from your Amazon SNS topic to subscribed endpoints with the following supported delivery protocols: HTTP Amazon Kinesis Data Firehose AWS Lambda Platform application endpoint Amazon Simple Queue Service Once configured, log entries are sent to Amazon CloudWatch Logs.
createCreate a SNS Topic
getGet a SNS Topic
ArgumentTypeDescription
identifierstringThe primary identifier of the SNS Topic
updateUpdate a SNS Topic
deleteDelete a SNS Topic
ArgumentTypeDescription
identifierstringThe primary identifier of the SNS Topic
syncSync SNS Topic state from AWS

Resources

state(infinite)— SNS Topic resource state
@swamp/aws/sns/topic-inline-policyv2026.04.03.2topic_inline_policy.ts

Global Arguments

ArgumentTypeDescription
PolicyDocumentstringA policy document that contains permissions to add to the specified SNS topics.
TopicArnstringThe Amazon Resource Name (ARN) of the topic to which you want to add the policy.
createCreate a SNS TopicInlinePolicy
getGet a SNS TopicInlinePolicy
ArgumentTypeDescription
identifierstringThe primary identifier of the SNS TopicInlinePolicy
updateUpdate a SNS TopicInlinePolicy
deleteDelete a SNS TopicInlinePolicy
ArgumentTypeDescription
identifierstringThe primary identifier of the SNS TopicInlinePolicy
syncSync SNS TopicInlinePolicy state from AWS

Resources

state(infinite)— SNS TopicInlinePolicy resource state