Skip to content

/AWS1/CL_CEX=>GETCOSTCATEGORIES()

About GetCostCategories

Retrieves an array of Cost Category names and values incurred cost.

If some Cost Category names and values are not associated with any cost, they will not be returned by this API.

Method Signature

IMPORTING

Required arguments:

IO_TIMEPERIOD TYPE REF TO /AWS1/CL_CEXDATEINTERVAL /AWS1/CL_CEXDATEINTERVAL

TimePeriod

Optional arguments:

IV_SEARCHSTRING TYPE /AWS1/CEXSEARCHSTRING /AWS1/CEXSEARCHSTRING

The value that you want to search the filter values for.

If you don't specify a CostCategoryName, SearchString is used to filter Cost Category names that match the SearchString pattern. If you specify a CostCategoryName, SearchString is used to filter Cost Category values that match the SearchString pattern.

IV_COSTCATEGORYNAME TYPE /AWS1/CEXCOSTCATEGORYNAME /AWS1/CEXCOSTCATEGORYNAME

CostCategoryName

IO_FILTER TYPE REF TO /AWS1/CL_CEXEXPRESSION /AWS1/CL_CEXEXPRESSION

Filter

IT_SORTBY TYPE /AWS1/CL_CEXSORTDEFINITION=>TT_SORTDEFINITIONS TT_SORTDEFINITIONS

The value that you sort the data by.

The key represents the cost and usage metrics. The following values are supported:

  • BlendedCost

  • UnblendedCost

  • AmortizedCost

  • NetAmortizedCost

  • NetUnblendedCost

  • UsageQuantity

  • NormalizedUsageAmount

The supported key values for the SortOrder value are ASCENDING and DESCENDING.

When you use the SortBy value, the NextPageToken and SearchString key values aren't supported.

IV_MAXRESULTS TYPE /AWS1/CEXMAXRESULTS /AWS1/CEXMAXRESULTS

This field is only used when the SortBy value is provided in the request.

The maximum number of objects that are returned for this request. If MaxResults isn't specified with the SortBy value, the request returns 1000 results as the default value for this parameter.

For GetCostCategories, MaxResults has an upper quota of 1000.

IV_NEXTPAGETOKEN TYPE /AWS1/CEXNEXTPAGETOKEN /AWS1/CEXNEXTPAGETOKEN

If the number of objects that are still available for retrieval exceeds the quota, Amazon Web Services returns a NextPageToken value in the response. To retrieve the next batch of objects, provide the NextPageToken from the previous call in your next request.

RETURNING

OO_OUTPUT TYPE REF TO /AWS1/CL_CEXGETCOSTCATSRSP /AWS1/CL_CEXGETCOSTCATSRSP