

# ListTagsForResource
<a name="API_AWSBCMPricingCalculator_ListTagsForResource"></a>

 Lists all tags associated with a specified resource. 

## Request Syntax
<a name="API_AWSBCMPricingCalculator_ListTagsForResource_RequestSyntax"></a>

```
{
   "arn": "{{string}}"
}
```

## Request Parameters
<a name="API_AWSBCMPricingCalculator_ListTagsForResource_RequestParameters"></a>

For information about the parameters that are common to all actions, see [Common Parameters](CommonParameters.md).

The request accepts the following data in JSON format.

 ** [arn](#API_AWSBCMPricingCalculator_ListTagsForResource_RequestSyntax) **   <a name="awscostmanagement-AWSBCMPricingCalculator_ListTagsForResource-request-arn"></a>
 The Amazon Resource Name (ARN) of the resource to list tags for.   
Type: String  
Length Constraints: Minimum length of 20. Maximum length of 2048.  
Pattern: `arn:aws[-a-z0-9]*:bcm-pricing-calculator:[-a-z0-9]*:[0-9]{12}:[-a-z0-9/:_]+`   
Required: Yes

## Response Syntax
<a name="API_AWSBCMPricingCalculator_ListTagsForResource_ResponseSyntax"></a>

```
{
   "tags": { 
      "string" : "string" 
   }
}
```

## Response Elements
<a name="API_AWSBCMPricingCalculator_ListTagsForResource_ResponseElements"></a>

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

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

 ** [tags](#API_AWSBCMPricingCalculator_ListTagsForResource_ResponseSyntax) **   <a name="awscostmanagement-AWSBCMPricingCalculator_ListTagsForResource-response-tags"></a>
 The list of tags associated with the specified resource.   
Type: String to string map  
Map Entries: Minimum number of 0 items. Maximum number of 200 items.  
Key Length Constraints: Minimum length of 1. Maximum length of 128.  
Key Pattern: `[\w\s:+=@/-]+`   
Value Length Constraints: Minimum length of 0. Maximum length of 256.  
Value Pattern: `[\w\s:+=@/-]*` 

## Errors
<a name="API_AWSBCMPricingCalculator_ListTagsForResource_Errors"></a>

For information about the errors that are common to all actions, see [Common Error Types](CommonErrors.md).

 ** AccessDeniedException **   
 You do not have sufficient access to perform this action.   
HTTP Status Code: 400

 ** InternalServerException **   
 An internal error has occurred. Retry your request, but if the problem persists, contact Amazon support.     
 ** retryAfterSeconds **   
 An internal error has occurred. Retry your request, but if the problem persists, contact Amazon support. 
HTTP Status Code: 500

 ** ResourceNotFoundException **   
 The specified resource was not found.     
 ** resourceId **   
 The identifier of the resource that was not found.   
 ** resourceType **   
 The type of the resource that was not found. 
HTTP Status Code: 400

 ** ThrottlingException **   
 The request was denied due to request throttling.     
 ** quotaCode **   
The quota code that exceeded the throttling limit.  
 ** retryAfterSeconds **   
The service code that exceeded the throttling limit. Retry your request, but if the problem persists, contact Amazon support.  
 ** serviceCode **   
The service code that exceeded the throttling limit.
HTTP Status Code: 400

 ** ValidationException **   
 The input provided fails to satisfy the constraints specified by an Amazon service.     
 ** fieldList **   
 The list of fields that are invalid.   
 ** reason **   
 The reason for the validation exception. 
HTTP Status Code: 400

## See Also
<a name="API_AWSBCMPricingCalculator_ListTagsForResource_SeeAlso"></a>

For more information about using this API in one of the language-specific Amazon SDKs, see the following:
+  [Amazon Command Line Interface V2](https://docs.amazonaws.cn/goto/cli2/bcm-pricing-calculator-2024-06-19/ListTagsForResource) 
+  [Amazon SDK for .NET V4](https://docs.amazonaws.cn/goto/DotNetSDKV4/bcm-pricing-calculator-2024-06-19/ListTagsForResource) 
+  [Amazon SDK for C\+\+](https://docs.amazonaws.cn/goto/SdkForCpp/bcm-pricing-calculator-2024-06-19/ListTagsForResource) 
+  [Amazon SDK for Go v2](https://docs.amazonaws.cn/goto/SdkForGoV2/bcm-pricing-calculator-2024-06-19/ListTagsForResource) 
+  [Amazon SDK for Java V2](https://docs.amazonaws.cn/goto/SdkForJavaV2/bcm-pricing-calculator-2024-06-19/ListTagsForResource) 
+  [Amazon SDK for JavaScript V3](https://docs.amazonaws.cn/goto/SdkForJavaScriptV3/bcm-pricing-calculator-2024-06-19/ListTagsForResource) 
+  [Amazon SDK for Kotlin](https://docs.amazonaws.cn/goto/SdkForKotlin/bcm-pricing-calculator-2024-06-19/ListTagsForResource) 
+  [Amazon SDK for PHP V3](https://docs.amazonaws.cn/goto/SdkForPHPV3/bcm-pricing-calculator-2024-06-19/ListTagsForResource) 
+  [Amazon SDK for Python](https://docs.amazonaws.cn/goto/boto3/bcm-pricing-calculator-2024-06-19/ListTagsForResource) 
+  [Amazon SDK for Ruby V3](https://docs.amazonaws.cn/goto/SdkForRubyV3/bcm-pricing-calculator-2024-06-19/ListTagsForResource) 