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.GetReservationUtilization

Description

Retrieves the reservation utilization for your account. Management account in an organization have access to member accounts. You can filter data by dimensions in a time period. You can use GetDimensionValues to determine the possible dimension values. Currently, you can group only by SUBSCRIPTION_ID.

Synopsis

Creating a Request

data GetReservationUtilization Source #

See: newGetReservationUtilization smart constructor.

Constructors

GetReservationUtilization' 

Fields

  • filter' :: Maybe Expression

    Filters utilization data by dimensions. You can filter by the following dimensions:

    • AZ
    • CACHE_ENGINE
    • DEPLOYMENT_OPTION
    • INSTANCE_TYPE
    • LINKED_ACCOUNT
    • OPERATING_SYSTEM
    • PLATFORM
    • REGION
    • SERVICE
    • SCOPE
    • TENANCY

    GetReservationUtilization uses the same Expression object as the other operations, but only AND is supported among each dimension, and nesting is supported up to only one level deep. If there are multiple values for a dimension, they are OR'd together.

  • granularity :: Maybe Granularity

    If GroupBy is set, Granularity can't be set. If Granularity isn't set, the response object doesn't include Granularity, either MONTHLY or DAILY. If both GroupBy and Granularity aren't set, GetReservationUtilization defaults to DAILY.

    The GetReservationUtilization operation supports only DAILY and MONTHLY granularities.

  • groupBy :: Maybe [GroupDefinition]

    Groups only by SUBSCRIPTION_ID. Metadata is included.

  • maxResults :: Maybe Natural

    The maximum number of objects that you returned for this request. If more objects are available, in the response, Amazon Web Services provides a NextPageToken value that you can use in a subsequent call to get the next batch of objects.

  • nextPageToken :: Maybe Text

    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.

  • sortBy :: Maybe SortDefinition

    The value that you want to sort the data by.

    The following values are supported for Key:

    • UtilizationPercentage
    • UtilizationPercentageInUnits
    • PurchasedHours
    • PurchasedUnits
    • TotalActualHours
    • TotalActualUnits
    • UnusedHours
    • UnusedUnits
    • OnDemandCostOfRIHoursUsed
    • NetRISavings
    • TotalPotentialRISavings
    • AmortizedUpfrontFee
    • AmortizedRecurringFee
    • TotalAmortizedFee
    • RICostForUnusedHours
    • RealizedSavings
    • UnrealizedSavings

    The supported values for SortOrder are ASCENDING and DESCENDING.

  • timePeriod :: DateInterval

    Sets the start and end dates for retrieving Reserved Instance (RI) utilization. The start date is inclusive, but the end date is exclusive. For example, if start is 2017-01-01 and end is 2017-05-01, then the cost and usage data is retrieved from 2017-01-01 up to and including 2017-04-30 but not including 2017-05-01.

Instances

Instances details
ToJSON GetReservationUtilization Source # 
Instance details

Defined in Amazonka.CostExplorer.GetReservationUtilization

ToHeaders GetReservationUtilization Source # 
Instance details

Defined in Amazonka.CostExplorer.GetReservationUtilization

ToPath GetReservationUtilization Source # 
Instance details

Defined in Amazonka.CostExplorer.GetReservationUtilization

ToQuery GetReservationUtilization Source # 
Instance details

Defined in Amazonka.CostExplorer.GetReservationUtilization

AWSRequest GetReservationUtilization Source # 
Instance details

Defined in Amazonka.CostExplorer.GetReservationUtilization

Generic GetReservationUtilization Source # 
Instance details

Defined in Amazonka.CostExplorer.GetReservationUtilization

Associated Types

type Rep GetReservationUtilization :: Type -> Type #

Read GetReservationUtilization Source # 
Instance details

Defined in Amazonka.CostExplorer.GetReservationUtilization

Show GetReservationUtilization Source # 
Instance details

Defined in Amazonka.CostExplorer.GetReservationUtilization

NFData GetReservationUtilization Source # 
Instance details

Defined in Amazonka.CostExplorer.GetReservationUtilization

Eq GetReservationUtilization Source # 
Instance details

Defined in Amazonka.CostExplorer.GetReservationUtilization

Hashable GetReservationUtilization Source # 
Instance details

Defined in Amazonka.CostExplorer.GetReservationUtilization

type AWSResponse GetReservationUtilization Source # 
Instance details

Defined in Amazonka.CostExplorer.GetReservationUtilization

type Rep GetReservationUtilization Source # 
Instance details

Defined in Amazonka.CostExplorer.GetReservationUtilization

newGetReservationUtilization Source #

Create a value of GetReservationUtilization 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:filter':GetReservationUtilization', getReservationUtilization_filter - Filters utilization data by dimensions. You can filter by the following dimensions:

  • AZ
  • CACHE_ENGINE
  • DEPLOYMENT_OPTION
  • INSTANCE_TYPE
  • LINKED_ACCOUNT
  • OPERATING_SYSTEM
  • PLATFORM
  • REGION
  • SERVICE
  • SCOPE
  • TENANCY

GetReservationUtilization uses the same Expression object as the other operations, but only AND is supported among each dimension, and nesting is supported up to only one level deep. If there are multiple values for a dimension, they are OR'd together.

$sel:granularity:GetReservationUtilization', getReservationUtilization_granularity - If GroupBy is set, Granularity can't be set. If Granularity isn't set, the response object doesn't include Granularity, either MONTHLY or DAILY. If both GroupBy and Granularity aren't set, GetReservationUtilization defaults to DAILY.

The GetReservationUtilization operation supports only DAILY and MONTHLY granularities.

$sel:groupBy:GetReservationUtilization', getReservationUtilization_groupBy - Groups only by SUBSCRIPTION_ID. Metadata is included.

$sel:maxResults:GetReservationUtilization', getReservationUtilization_maxResults - The maximum number of objects that you returned for this request. If more objects are available, in the response, Amazon Web Services provides a NextPageToken value that you can use in a subsequent call to get the next batch of objects.

GetReservationUtilization, getReservationUtilization_nextPageToken - 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.

$sel:sortBy:GetReservationUtilization', getReservationUtilization_sortBy - The value that you want to sort the data by.

The following values are supported for Key:

  • UtilizationPercentage
  • UtilizationPercentageInUnits
  • PurchasedHours
  • PurchasedUnits
  • TotalActualHours
  • TotalActualUnits
  • UnusedHours
  • UnusedUnits
  • OnDemandCostOfRIHoursUsed
  • NetRISavings
  • TotalPotentialRISavings
  • AmortizedUpfrontFee
  • AmortizedRecurringFee
  • TotalAmortizedFee
  • RICostForUnusedHours
  • RealizedSavings
  • UnrealizedSavings

The supported values for SortOrder are ASCENDING and DESCENDING.

GetReservationUtilization, getReservationUtilization_timePeriod - Sets the start and end dates for retrieving Reserved Instance (RI) utilization. The start date is inclusive, but the end date is exclusive. For example, if start is 2017-01-01 and end is 2017-05-01, then the cost and usage data is retrieved from 2017-01-01 up to and including 2017-04-30 but not including 2017-05-01.

Request Lenses

getReservationUtilization_filter :: Lens' GetReservationUtilization (Maybe Expression) Source #

Filters utilization data by dimensions. You can filter by the following dimensions:

  • AZ
  • CACHE_ENGINE
  • DEPLOYMENT_OPTION
  • INSTANCE_TYPE
  • LINKED_ACCOUNT
  • OPERATING_SYSTEM
  • PLATFORM
  • REGION
  • SERVICE
  • SCOPE
  • TENANCY

GetReservationUtilization uses the same Expression object as the other operations, but only AND is supported among each dimension, and nesting is supported up to only one level deep. If there are multiple values for a dimension, they are OR'd together.

getReservationUtilization_granularity :: Lens' GetReservationUtilization (Maybe Granularity) Source #

If GroupBy is set, Granularity can't be set. If Granularity isn't set, the response object doesn't include Granularity, either MONTHLY or DAILY. If both GroupBy and Granularity aren't set, GetReservationUtilization defaults to DAILY.

The GetReservationUtilization operation supports only DAILY and MONTHLY granularities.

getReservationUtilization_groupBy :: Lens' GetReservationUtilization (Maybe [GroupDefinition]) Source #

Groups only by SUBSCRIPTION_ID. Metadata is included.

getReservationUtilization_maxResults :: Lens' GetReservationUtilization (Maybe Natural) Source #

The maximum number of objects that you returned for this request. If more objects are available, in the response, Amazon Web Services provides a NextPageToken value that you can use in a subsequent call to get the next batch of objects.

getReservationUtilization_nextPageToken :: Lens' GetReservationUtilization (Maybe Text) Source #

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.

getReservationUtilization_sortBy :: Lens' GetReservationUtilization (Maybe SortDefinition) Source #

The value that you want to sort the data by.

The following values are supported for Key:

  • UtilizationPercentage
  • UtilizationPercentageInUnits
  • PurchasedHours
  • PurchasedUnits
  • TotalActualHours
  • TotalActualUnits
  • UnusedHours
  • UnusedUnits
  • OnDemandCostOfRIHoursUsed
  • NetRISavings
  • TotalPotentialRISavings
  • AmortizedUpfrontFee
  • AmortizedRecurringFee
  • TotalAmortizedFee
  • RICostForUnusedHours
  • RealizedSavings
  • UnrealizedSavings

The supported values for SortOrder are ASCENDING and DESCENDING.

getReservationUtilization_timePeriod :: Lens' GetReservationUtilization DateInterval Source #

Sets the start and end dates for retrieving Reserved Instance (RI) utilization. The start date is inclusive, but the end date is exclusive. For example, if start is 2017-01-01 and end is 2017-05-01, then the cost and usage data is retrieved from 2017-01-01 up to and including 2017-04-30 but not including 2017-05-01.

Destructuring the Response

data GetReservationUtilizationResponse Source #

See: newGetReservationUtilizationResponse smart constructor.

Constructors

GetReservationUtilizationResponse' 

Fields

Instances

Instances details
Generic GetReservationUtilizationResponse Source # 
Instance details

Defined in Amazonka.CostExplorer.GetReservationUtilization

Associated Types

type Rep GetReservationUtilizationResponse :: Type -> Type #

Read GetReservationUtilizationResponse Source # 
Instance details

Defined in Amazonka.CostExplorer.GetReservationUtilization

Show GetReservationUtilizationResponse Source # 
Instance details

Defined in Amazonka.CostExplorer.GetReservationUtilization

NFData GetReservationUtilizationResponse Source # 
Instance details

Defined in Amazonka.CostExplorer.GetReservationUtilization

Eq GetReservationUtilizationResponse Source # 
Instance details

Defined in Amazonka.CostExplorer.GetReservationUtilization

type Rep GetReservationUtilizationResponse Source # 
Instance details

Defined in Amazonka.CostExplorer.GetReservationUtilization

type Rep GetReservationUtilizationResponse = D1 ('MetaData "GetReservationUtilizationResponse" "Amazonka.CostExplorer.GetReservationUtilization" "amazonka-cost-explorer-2.0-QqVzyVvst98QYs5s2Ea4h" 'False) (C1 ('MetaCons "GetReservationUtilizationResponse'" 'PrefixI 'True) ((S1 ('MetaSel ('Just "nextPageToken") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (Maybe Text)) :*: S1 ('MetaSel ('Just "total") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (Maybe ReservationAggregates))) :*: (S1 ('MetaSel ('Just "httpStatus") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 Int) :*: S1 ('MetaSel ('Just "utilizationsByTime") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 [UtilizationByTime]))))

newGetReservationUtilizationResponse Source #

Create a value of GetReservationUtilizationResponse 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:

GetReservationUtilization, getReservationUtilizationResponse_nextPageToken - The token for the next set of retrievable results. Amazon Web Services provides the token when the response from a previous call has more results than the maximum page size.

GetReservationUtilizationResponse, getReservationUtilizationResponse_total - The total amount of time that you used your Reserved Instances (RIs).

$sel:httpStatus:GetReservationUtilizationResponse', getReservationUtilizationResponse_httpStatus - The response's http status code.

$sel:utilizationsByTime:GetReservationUtilizationResponse', getReservationUtilizationResponse_utilizationsByTime - The amount of time that you used your Reserved Instances (RIs).

Response Lenses

getReservationUtilizationResponse_nextPageToken :: Lens' GetReservationUtilizationResponse (Maybe Text) Source #

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

getReservationUtilizationResponse_total :: Lens' GetReservationUtilizationResponse (Maybe ReservationAggregates) Source #

The total amount of time that you used your Reserved Instances (RIs).