ListCostCategoryDefinitions - AWS Billing and Cost Management

ListCostCategoryDefinitions

Returns the name, Amazon Resource Name (ARN), NumberOfRules and effective dates of all Cost Categories defined in the account. You have the option to use EffectiveOn to return a list of Cost Categories that were active on a specific date. If there is no EffectiveOn specified, you’ll see Cost Categories that are effective on the current date. If Cost Category is still effective, EffectiveEnd is omitted in the response. ListCostCategoryDefinitions supports pagination. The request can have a MaxResults range up to 100.

Request Syntax

{ "EffectiveOn": "string", "MaxResults": number, "NextToken": "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.

EffectiveOn

The date when the Cost Category was effective.

Type: String

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

Pattern: ^\d{4}-\d\d-\d\dT\d\d:\d\d:\d\d(([+-]\d\d:\d\d)|Z)$

Required: No

MaxResults

The number of entries a paginated response contains.

Type: Integer

Valid Range: Minimum value of 1. Maximum value of 100.

Required: No

NextToken

The token to retrieve the next set of results. Amazon Web Services provides the token when the response from a previous call has more results than the maximum page size.

Type: String

Length Constraints: Minimum length of 0. Maximum length of 8192.

Pattern: [\S\s]*

Required: No

Response Syntax

{ "CostCategoryReferences": [ { "CostCategoryArn": "string", "DefaultValue": "string", "EffectiveEnd": "string", "EffectiveStart": "string", "Name": "string", "NumberOfRules": number, "ProcessingStatus": [ { "Component": "string", "Status": "string" } ], "Values": [ "string" ] } ], "NextToken": "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.

CostCategoryReferences

A reference to a Cost Category that contains enough information to identify the Cost Category.

Type: Array of CostCategoryReference objects

NextToken

The token to retrieve the next set of results. AWS provides the token when the response from a previous call has more results than the maximum page size.

Type: String

Length Constraints: Minimum length of 0. Maximum length of 8192.

Pattern: [\S\s]*

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

See Also

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