GetSubscriptionAttributes
Returns all of the properties of a subscription.
Request Parameters
For information about the parameters that are common to all actions, see Common Parameters.
- SubscriptionArn
-
The ARN of the subscription whose properties you want to get.
Type: String
Required: Yes
Response Elements
The following element is returned by the service.
- Attributes
- Attributes.entry.N.key (key)
- Attributes.entry.N.value (value)
-
A map of the subscription's attributes. Attributes in this map include the following:
-
ConfirmationWasAuthenticated
–true
if the subscription confirmation request was authenticated. -
DeliveryPolicy
– The JSON serialization of the subscription's delivery policy. -
EffectiveDeliveryPolicy
– The JSON serialization of the effective delivery policy that takes into account the topic delivery policy and account system defaults. -
FilterPolicy
– The filter policy JSON that is assigned to the subscription. -
Owner
– The AWS account ID of the subscription's owner. -
PendingConfirmation
–true
if the subscription hasn't been confirmed. To confirm a pending subscription, call theConfirmSubscription
action with a confirmation token. -
RawMessageDelivery
–true
if raw message delivery is enabled for the subscription. Raw messages are free of JSON formatting and can be sent to HTTP/S and Amazon SQS endpoints. -
SubscriptionArn
– The subscription's ARN. -
TopicArn
– The topic ARN that the subscription is associated with.
Type: String to string map
-
Errors
For information about the errors that are common to all actions, see Common Errors.
- AuthorizationError
-
Indicates that the user has been denied access to the requested resource.
HTTP Status Code: 403
- InternalError
-
Indicates an internal service error.
HTTP Status Code: 500
- InvalidParameter
-
Indicates that a request parameter does not comply with the associated constraints.
HTTP Status Code: 400
- NotFound
-
Indicates that the requested resource does not exist.
HTTP Status Code: 404
Example
The structure of AUTHPARAMS
depends on the signature of the API request.
For more information, see Examples
of Signed Signature Version 4 Requests in the Amazon Web Services General Reference.
Example
Sample Request
https://sns.us-east-2.amazonaws.com/?Action=GetSubscriptionAttributes &SubscriptionArn=arn%3Aaws%3Asns%3Aus-east-2%3A123456789012%3AMy-Topic%3A80289ba6-0fd4-4079-afb4-ce8c8260f0ca &Version=2010-03-31 &AUTHPARAMS
Sample Response
<GetSubscriptionAttributesResponse xmlns="https://sns.amazonaws.com/doc/2010-03-31/"> <GetSubscriptionAttributesResult> <Attributes> <entry> <key>Owner</key> <value>123456789012</value> </entry> <entry> <key>DeliveryPolicy</key> <value>{"healthyRetryPolicy":{"numRetries":10}}</value> </entry> <entry> <key>SubscriptionArn</key> <value>arn:aws:sns:us-east-2:123456789012:My-Topic:80289ba6-0fd4-4079-afb4-ce8c8260f0ca</value> </entry> </Attributes> </GetSubscriptionAttributesResult> <ResponseMetadata> <RequestId>057f074c-33a7-11df-9540-99d0768312d3</RequestId> </ResponseMetadata> </GetTopicAttributesResponse>
See Also
For more information about using this API in one of the language-specific AWS SDKs, see the following: