ListTagsForResource - Amazon Simple Notification Service


List all tags added to the specified Amazon SNS topic. For an overview, see Amazon SNS Tags in the Amazon Simple Notification Service Developer Guide.

Request Parameters

For information about the parameters that are common to all actions, see Common Parameters.


The ARN of the topic for which to list tags.

Type: String

Length Constraints: Minimum length of 1. Maximum length of 1011.

Required: Yes

Response Elements

The following element is returned by the service.


The tags associated with the specified topic.

Type: Array of Tag objects


For information about the errors that are common to all actions, see Common Errors.


Indicates that the user has been denied access to the requested resource.

HTTP Status Code: 403


Can't perform multiple operations on a tag simultaneously. Perform the operations sequentially.

HTTP Status Code: 400


Indicates that a request parameter does not comply with the associated constraints.

HTTP Status Code: 400


Can’t perform the action on the specified resource. Make sure that the resource exists.

HTTP Status Code: 404


The request doesn't comply with the IAM tag policy. Correct your request and then retry it.

HTTP Status Code: 400


The structure of AUTHPARAMS depends on the signature of the API request. For more information, see Examples of the complete Signature Version 4 signing process (Python) in the AWS General Reference.


This example illustrates one usage of ListTagsForResource.

Sample Request &ResourceArn=arn%3Aaws%3Asns%3Aus-west-2%3A123456789012%3Atagging &Version=2010-03-31 &AUTHPARAMS

Sample Response

<ListTagsForResourceResponse> <ListTagsForResourceResult> <Tags> <member> <Value>tagValue</Value> <Key>tagKey</Key> </member> </Tags> </ListTagsForResourceResult> <ResponseMetadata> <RequestId>123456a7-b8c9-01de-fg2h-3456i7j890k1</RequestId> </ResponseMetadata> </ListTagsForResourceResponse>

See Also

For more information about using this API in one of the language-specific AWS SDKs, see the following: