ListTagsForResource - Amazon Billing and Cost Management
Services or capabilities described in Amazon Web Services documentation might vary by Region. To see the differences applicable to the China Regions, see Getting Started with Amazon Web Services in China (PDF).

ListTagsForResource

Returns a list of resource tags associated with the resource specified by the Amazon Resource Name (ARN).

Request Syntax

{ "ResourceArn": "string" }

Request Parameters

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

The request accepts the following data in JSON format.

ResourceArn

The Amazon Resource Name (ARN) of the resource. For a list of supported resources, see ResourceTag.

Type: String

Length Constraints: Minimum length of 20. Maximum length of 2048.

Pattern: arn:aws[-a-z0-9]*:[a-z0-9]+:[-a-z0-9]*:[0-9]{12}:[-a-zA-Z0-9/:_]+

Required: Yes

Response Syntax

{ "ResourceTags": [ { "Key": "string", "Value": "string" } ] }

Response Elements

If the action is successful, the service sends back an HTTP 200 response.

The following data is returned in JSON format by the service.

ResourceTags

A list of tag key value pairs that are associated with the resource.

Type: Array of ResourceTag objects

Array Members: Minimum number of 0 items. Maximum number of 200 items.

Errors

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

LimitExceededException

You made too many calls in a short period of time. Try again later.

HTTP Status Code: 400

ResourceNotFoundException

The specified ARN in the request doesn't exist.

HTTP Status Code: 400

See Also

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