We recommend new projects start with resources from the AWS provider.
aws-native.sns.Subscription
Explore with Pulumi AI
We recommend new projects start with resources from the AWS provider.
Resource Type definition for AWS::SNS::Subscription
Create Subscription Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
new Subscription(name: string, args: SubscriptionArgs, opts?: CustomResourceOptions);@overload
def Subscription(resource_name: str,
                 args: SubscriptionArgs,
                 opts: Optional[ResourceOptions] = None)
@overload
def Subscription(resource_name: str,
                 opts: Optional[ResourceOptions] = None,
                 protocol: Optional[str] = None,
                 topic_arn: Optional[str] = None,
                 delivery_policy: Optional[Any] = None,
                 endpoint: Optional[str] = None,
                 filter_policy: Optional[Any] = None,
                 filter_policy_scope: Optional[str] = None,
                 raw_message_delivery: Optional[bool] = None,
                 redrive_policy: Optional[Any] = None,
                 region: Optional[str] = None,
                 replay_policy: Optional[Any] = None,
                 subscription_role_arn: Optional[str] = None)func NewSubscription(ctx *Context, name string, args SubscriptionArgs, opts ...ResourceOption) (*Subscription, error)public Subscription(string name, SubscriptionArgs args, CustomResourceOptions? opts = null)
public Subscription(String name, SubscriptionArgs args)
public Subscription(String name, SubscriptionArgs args, CustomResourceOptions options)
type: aws-native:sns:Subscription
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.
Parameters
- name string
- The unique name of the resource.
- args SubscriptionArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- resource_name str
- The unique name of the resource.
- args SubscriptionArgs
- The arguments to resource properties.
- opts ResourceOptions
- Bag of options to control resource's behavior.
- ctx Context
- Context object for the current deployment.
- name string
- The unique name of the resource.
- args SubscriptionArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args SubscriptionArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args SubscriptionArgs
- The arguments to resource properties.
- options CustomResourceOptions
- Bag of options to control resource's behavior.
Subscription Resource Properties
To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.
Inputs
In Python, inputs that are objects can be passed either as argument classes or as dictionary literals.
The Subscription resource accepts the following input properties:
- Protocol string
- The subscription's protocol.
- TopicArn string
- The ARN of the topic to subscribe to.
- DeliveryPolicy object
- The 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. - Search the CloudFormation User Guide for - AWS::SNS::Subscriptionfor more information about the expected schema for this property.
- Endpoint string
- The subscription's endpoint. The endpoint value depends on the protocol that you specify.
- FilterPolicy object
- The filter policy JSON assigned to the subscription. Enables the subscriber to filter out unwanted messages. - Search the CloudFormation User Guide for - AWS::SNS::Subscriptionfor more information about the expected schema for this property.
- FilterPolicy stringScope 
- This attribute lets you choose the filtering scope by using one of the following string value types: MessageAttributes (default) and MessageBody.
- RawMessage boolDelivery 
- When 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.
- RedrivePolicy object
- When 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. - Search the CloudFormation User Guide for - AWS::SNS::Subscriptionfor more information about the expected schema for this property.
- Region string
- For 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.
- ReplayPolicy object
- Specifies whether Amazon SNS resends the notification to the subscription when a message's attribute changes. - Search the CloudFormation User Guide for - AWS::SNS::Subscriptionfor more information about the expected schema for this property.
- SubscriptionRole stringArn 
- This property applies only to Amazon Data Firehose delivery stream subscriptions.
- Protocol string
- The subscription's protocol.
- TopicArn string
- The ARN of the topic to subscribe to.
- DeliveryPolicy interface{}
- The 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. - Search the CloudFormation User Guide for - AWS::SNS::Subscriptionfor more information about the expected schema for this property.
- Endpoint string
- The subscription's endpoint. The endpoint value depends on the protocol that you specify.
- FilterPolicy interface{}
- The filter policy JSON assigned to the subscription. Enables the subscriber to filter out unwanted messages. - Search the CloudFormation User Guide for - AWS::SNS::Subscriptionfor more information about the expected schema for this property.
- FilterPolicy stringScope 
- This attribute lets you choose the filtering scope by using one of the following string value types: MessageAttributes (default) and MessageBody.
- RawMessage boolDelivery 
- When 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.
- RedrivePolicy interface{}
- When 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. - Search the CloudFormation User Guide for - AWS::SNS::Subscriptionfor more information about the expected schema for this property.
- Region string
- For 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.
- ReplayPolicy interface{}
- Specifies whether Amazon SNS resends the notification to the subscription when a message's attribute changes. - Search the CloudFormation User Guide for - AWS::SNS::Subscriptionfor more information about the expected schema for this property.
- SubscriptionRole stringArn 
- This property applies only to Amazon Data Firehose delivery stream subscriptions.
- protocol String
- The subscription's protocol.
- topicArn String
- The ARN of the topic to subscribe to.
- deliveryPolicy Object
- The 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. - Search the CloudFormation User Guide for - AWS::SNS::Subscriptionfor more information about the expected schema for this property.
- endpoint String
- The subscription's endpoint. The endpoint value depends on the protocol that you specify.
- filterPolicy Object
- The filter policy JSON assigned to the subscription. Enables the subscriber to filter out unwanted messages. - Search the CloudFormation User Guide for - AWS::SNS::Subscriptionfor more information about the expected schema for this property.
- filterPolicy StringScope 
- This attribute lets you choose the filtering scope by using one of the following string value types: MessageAttributes (default) and MessageBody.
- rawMessage BooleanDelivery 
- When 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.
- redrivePolicy Object
- When 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. - Search the CloudFormation User Guide for - AWS::SNS::Subscriptionfor more information about the expected schema for this property.
- region String
- For 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.
- replayPolicy Object
- Specifies whether Amazon SNS resends the notification to the subscription when a message's attribute changes. - Search the CloudFormation User Guide for - AWS::SNS::Subscriptionfor more information about the expected schema for this property.
- subscriptionRole StringArn 
- This property applies only to Amazon Data Firehose delivery stream subscriptions.
- protocol string
- The subscription's protocol.
- topicArn string
- The ARN of the topic to subscribe to.
- deliveryPolicy any
- The 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. - Search the CloudFormation User Guide for - AWS::SNS::Subscriptionfor more information about the expected schema for this property.
- endpoint string
- The subscription's endpoint. The endpoint value depends on the protocol that you specify.
- filterPolicy any
- The filter policy JSON assigned to the subscription. Enables the subscriber to filter out unwanted messages. - Search the CloudFormation User Guide for - AWS::SNS::Subscriptionfor more information about the expected schema for this property.
- filterPolicy stringScope 
- This attribute lets you choose the filtering scope by using one of the following string value types: MessageAttributes (default) and MessageBody.
- rawMessage booleanDelivery 
- When 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.
- redrivePolicy any
- When 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. - Search the CloudFormation User Guide for - AWS::SNS::Subscriptionfor more information about the expected schema for this property.
- region string
- For 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.
- replayPolicy any
- Specifies whether Amazon SNS resends the notification to the subscription when a message's attribute changes. - Search the CloudFormation User Guide for - AWS::SNS::Subscriptionfor more information about the expected schema for this property.
- subscriptionRole stringArn 
- This property applies only to Amazon Data Firehose delivery stream subscriptions.
- protocol str
- The subscription's protocol.
- topic_arn str
- The ARN of the topic to subscribe to.
- delivery_policy Any
- The 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. - Search the CloudFormation User Guide for - AWS::SNS::Subscriptionfor more information about the expected schema for this property.
- endpoint str
- The subscription's endpoint. The endpoint value depends on the protocol that you specify.
- filter_policy Any
- The filter policy JSON assigned to the subscription. Enables the subscriber to filter out unwanted messages. - Search the CloudFormation User Guide for - AWS::SNS::Subscriptionfor more information about the expected schema for this property.
- filter_policy_ strscope 
- This attribute lets you choose the filtering scope by using one of the following string value types: MessageAttributes (default) and MessageBody.
- raw_message_ booldelivery 
- When 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.
- redrive_policy Any
- When 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. - Search the CloudFormation User Guide for - AWS::SNS::Subscriptionfor more information about the expected schema for this property.
- region str
- For 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.
- replay_policy Any
- Specifies whether Amazon SNS resends the notification to the subscription when a message's attribute changes. - Search the CloudFormation User Guide for - AWS::SNS::Subscriptionfor more information about the expected schema for this property.
- subscription_role_ strarn 
- This property applies only to Amazon Data Firehose delivery stream subscriptions.
- protocol String
- The subscription's protocol.
- topicArn String
- The ARN of the topic to subscribe to.
- deliveryPolicy Any
- The 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. - Search the CloudFormation User Guide for - AWS::SNS::Subscriptionfor more information about the expected schema for this property.
- endpoint String
- The subscription's endpoint. The endpoint value depends on the protocol that you specify.
- filterPolicy Any
- The filter policy JSON assigned to the subscription. Enables the subscriber to filter out unwanted messages. - Search the CloudFormation User Guide for - AWS::SNS::Subscriptionfor more information about the expected schema for this property.
- filterPolicy StringScope 
- This attribute lets you choose the filtering scope by using one of the following string value types: MessageAttributes (default) and MessageBody.
- rawMessage BooleanDelivery 
- When 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.
- redrivePolicy Any
- When 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. - Search the CloudFormation User Guide for - AWS::SNS::Subscriptionfor more information about the expected schema for this property.
- region String
- For 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.
- replayPolicy Any
- Specifies whether Amazon SNS resends the notification to the subscription when a message's attribute changes. - Search the CloudFormation User Guide for - AWS::SNS::Subscriptionfor more information about the expected schema for this property.
- subscriptionRole StringArn 
- This property applies only to Amazon Data Firehose delivery stream subscriptions.
Outputs
All input properties are implicitly available as output properties. Additionally, the Subscription resource produces the following output properties:
Package Details
- Repository
- AWS Native pulumi/pulumi-aws-native
- License
- Apache-2.0
We recommend new projects start with resources from the AWS provider.