amazonka-cost-explorer-2.0: Amazon Cost Explorer Service SDK.
Copyright(c) 2013-2023 Brendan Hay
LicenseMozilla Public License, v. 2.0.
MaintainerBrendan Hay
Stabilityauto-generated
Portabilitynon-portable (GHC extensions)
Safe HaskellSafe-Inferred
LanguageHaskell2010

Amazonka.CostExplorer.GetCostCategories

Description

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.

Synopsis

Creating a Request

data GetCostCategories Source #

See: newGetCostCategories smart constructor.

Constructors

GetCostCategories' 

Fields

  • costCategoryName :: Maybe Text
     
  • filter' :: Maybe Expression
     
  • maxResults :: Maybe Natural

    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.

  • nextPageToken :: Maybe Text

    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.

  • searchString :: Maybe Text

    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.

  • sortBy :: Maybe [SortDefinition]

    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.

  • timePeriod :: DateInterval
     

Instances

Instances details
ToJSON GetCostCategories Source # 
Instance details

Defined in Amazonka.CostExplorer.GetCostCategories

ToHeaders GetCostCategories Source # 
Instance details

Defined in Amazonka.CostExplorer.GetCostCategories

ToPath GetCostCategories Source # 
Instance details

Defined in Amazonka.CostExplorer.GetCostCategories

ToQuery GetCostCategories Source # 
Instance details

Defined in Amazonka.CostExplorer.GetCostCategories

AWSRequest GetCostCategories Source # 
Instance details

Defined in Amazonka.CostExplorer.GetCostCategories

Associated Types

type AWSResponse GetCostCategories #

Generic GetCostCategories Source # 
Instance details

Defined in Amazonka.CostExplorer.GetCostCategories

Associated Types

type Rep GetCostCategories :: Type -> Type #

Read GetCostCategories Source # 
Instance details

Defined in Amazonka.CostExplorer.GetCostCategories

Show GetCostCategories Source # 
Instance details

Defined in Amazonka.CostExplorer.GetCostCategories

NFData GetCostCategories Source # 
Instance details

Defined in Amazonka.CostExplorer.GetCostCategories

Methods

rnf :: GetCostCategories -> () #

Eq GetCostCategories Source # 
Instance details

Defined in Amazonka.CostExplorer.GetCostCategories

Hashable GetCostCategories Source # 
Instance details

Defined in Amazonka.CostExplorer.GetCostCategories

type AWSResponse GetCostCategories Source # 
Instance details

Defined in Amazonka.CostExplorer.GetCostCategories

type Rep GetCostCategories Source # 
Instance details

Defined in Amazonka.CostExplorer.GetCostCategories

type Rep GetCostCategories = D1 ('MetaData "GetCostCategories" "Amazonka.CostExplorer.GetCostCategories" "amazonka-cost-explorer-2.0-QqVzyVvst98QYs5s2Ea4h" 'False) (C1 ('MetaCons "GetCostCategories'" 'PrefixI 'True) ((S1 ('MetaSel ('Just "costCategoryName") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (Maybe Text)) :*: (S1 ('MetaSel ('Just "filter'") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (Maybe Expression)) :*: S1 ('MetaSel ('Just "maxResults") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (Maybe Natural)))) :*: ((S1 ('MetaSel ('Just "nextPageToken") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (Maybe Text)) :*: S1 ('MetaSel ('Just "searchString") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (Maybe Text))) :*: (S1 ('MetaSel ('Just "sortBy") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (Maybe [SortDefinition])) :*: S1 ('MetaSel ('Just "timePeriod") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 DateInterval)))))

newGetCostCategories Source #

Create a value of GetCostCategories with all optional fields omitted.

Use generic-lens or optics to modify other optional fields.

The following record fields are available, with the corresponding lenses provided for backwards compatibility:

$sel:costCategoryName:GetCostCategories', getCostCategories_costCategoryName - Undocumented member.

$sel:filter':GetCostCategories', getCostCategories_filter - Undocumented member.

$sel:maxResults:GetCostCategories', getCostCategories_maxResults - 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.

GetCostCategories, getCostCategories_nextPageToken - 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.

$sel:searchString:GetCostCategories', getCostCategories_searchString - 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.

$sel:sortBy:GetCostCategories', getCostCategories_sortBy - 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.

GetCostCategories, getCostCategories_timePeriod - Undocumented member.

Request Lenses

getCostCategories_maxResults :: Lens' GetCostCategories (Maybe Natural) Source #

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.

getCostCategories_nextPageToken :: Lens' GetCostCategories (Maybe Text) Source #

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.

getCostCategories_searchString :: Lens' GetCostCategories (Maybe Text) Source #

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.

getCostCategories_sortBy :: Lens' GetCostCategories (Maybe [SortDefinition]) Source #

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.

Destructuring the Response

data GetCostCategoriesResponse Source #

See: newGetCostCategoriesResponse smart constructor.

Constructors

GetCostCategoriesResponse' 

Fields

  • costCategoryNames :: Maybe [Text]

    The names of the Cost Categories.

  • costCategoryValues :: Maybe [Text]

    The Cost Category values.

    If the CostCategoryName key isn't specified in the request, the CostCategoryValues fields aren't returned.

  • nextPageToken :: Maybe Text

    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 marker from the prior call in your next request.

  • httpStatus :: Int

    The response's http status code.

  • returnSize :: Int

    The number of objects that are returned.

  • totalSize :: Int

    The total number of objects.

Instances

Instances details
Generic GetCostCategoriesResponse Source # 
Instance details

Defined in Amazonka.CostExplorer.GetCostCategories

Associated Types

type Rep GetCostCategoriesResponse :: Type -> Type #

Read GetCostCategoriesResponse Source # 
Instance details

Defined in Amazonka.CostExplorer.GetCostCategories

Show GetCostCategoriesResponse Source # 
Instance details

Defined in Amazonka.CostExplorer.GetCostCategories

NFData GetCostCategoriesResponse Source # 
Instance details

Defined in Amazonka.CostExplorer.GetCostCategories

Eq GetCostCategoriesResponse Source # 
Instance details

Defined in Amazonka.CostExplorer.GetCostCategories

type Rep GetCostCategoriesResponse Source # 
Instance details

Defined in Amazonka.CostExplorer.GetCostCategories

type Rep GetCostCategoriesResponse = D1 ('MetaData "GetCostCategoriesResponse" "Amazonka.CostExplorer.GetCostCategories" "amazonka-cost-explorer-2.0-QqVzyVvst98QYs5s2Ea4h" 'False) (C1 ('MetaCons "GetCostCategoriesResponse'" 'PrefixI 'True) ((S1 ('MetaSel ('Just "costCategoryNames") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (Maybe [Text])) :*: (S1 ('MetaSel ('Just "costCategoryValues") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (Maybe [Text])) :*: S1 ('MetaSel ('Just "nextPageToken") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (Maybe Text)))) :*: (S1 ('MetaSel ('Just "httpStatus") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 Int) :*: (S1 ('MetaSel ('Just "returnSize") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 Int) :*: S1 ('MetaSel ('Just "totalSize") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 Int)))))

newGetCostCategoriesResponse Source #

Create a value of GetCostCategoriesResponse with all optional fields omitted.

Use generic-lens or optics to modify other optional fields.

The following record fields are available, with the corresponding lenses provided for backwards compatibility:

$sel:costCategoryNames:GetCostCategoriesResponse', getCostCategoriesResponse_costCategoryNames - The names of the Cost Categories.

$sel:costCategoryValues:GetCostCategoriesResponse', getCostCategoriesResponse_costCategoryValues - The Cost Category values.

If the CostCategoryName key isn't specified in the request, the CostCategoryValues fields aren't returned.

GetCostCategories, getCostCategoriesResponse_nextPageToken - 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 marker from the prior call in your next request.

$sel:httpStatus:GetCostCategoriesResponse', getCostCategoriesResponse_httpStatus - The response's http status code.

$sel:returnSize:GetCostCategoriesResponse', getCostCategoriesResponse_returnSize - The number of objects that are returned.

$sel:totalSize:GetCostCategoriesResponse', getCostCategoriesResponse_totalSize - The total number of objects.

Response Lenses

getCostCategoriesResponse_costCategoryValues :: Lens' GetCostCategoriesResponse (Maybe [Text]) Source #

The Cost Category values.

If the CostCategoryName key isn't specified in the request, the CostCategoryValues fields aren't returned.

getCostCategoriesResponse_nextPageToken :: Lens' GetCostCategoriesResponse (Maybe Text) Source #

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 marker from the prior call in your next request.