AWS Cost Explorer Service 2017-10-25
- Client: Aws\CostExplorer\CostExplorerClient
- Service ID: ce
- Version: 2017-10-25
This page describes the parameters and results for the operations of the AWS Cost Explorer Service (2017-10-25), and shows how to use the Aws\CostExplorer\CostExplorerClient object to call the described operations. This documentation is specific to the 2017-10-25 API version of the service.
Operation Summary
Each of the following operations can be created from a client using
$client->getCommand('CommandName'), where "CommandName" is the
name of one of the following operations. Note: a command is a value that
encapsulates an operation and the parameters used to create an HTTP request.
You can also create and send a command immediately using the magic methods
available on a client object: $client->commandName(/* parameters */).
You can send the command asynchronously (returning a promise) by appending the
word "Async" to the operation name: $client->commandNameAsync(/* parameters */).
- CreateAnomalyMonitor ( array $params = [] )
- Creates a new cost anomaly detection monitor with the requested type and monitor specification.
- CreateAnomalySubscription ( array $params = [] )
- Adds an alert subscription to a cost anomaly detection monitor.
- CreateCostCategoryDefinition ( array $params = [] )
- Creates a new Cost Category with the requested name and rules.
- DeleteAnomalyMonitor ( array $params = [] )
- Deletes a cost anomaly monitor.
- DeleteAnomalySubscription ( array $params = [] )
- Deletes a cost anomaly subscription.
- DeleteCostCategoryDefinition ( array $params = [] )
- Deletes a Cost Category.
- DescribeCostCategoryDefinition ( array $params = [] )
- Returns the name, Amazon Resource Name (ARN), rules, definition, and effective dates of a Cost Category that's defined in the account.
- GetAnomalies ( array $params = [] )
- Retrieves all of the cost anomalies detected on your account during the time period that's specified by the DateInterval object.
- GetAnomalyMonitors ( array $params = [] )
- Retrieves the cost anomaly monitor definitions for your account.
- GetAnomalySubscriptions ( array $params = [] )
- Retrieves the cost anomaly subscription objects for your account.
- GetApproximateUsageRecords ( array $params = [] )
- Retrieves estimated usage records for hourly granularity or resource-level data at daily granularity.
- GetCommitmentPurchaseAnalysis ( array $params = [] )
- Retrieves a commitment purchase analysis result based on the AnalysisId.
- GetCostAndUsage ( array $params = [] )
- Retrieves cost and usage metrics for your account.
- GetCostAndUsageComparisons ( array $params = [] )
- Retrieves cost and usage comparisons for your account between two periods within the last 13 months.
- GetCostAndUsageWithResources ( array $params = [] )
- Retrieves cost and usage metrics with resources for your account.
- GetCostCategories ( array $params = [] )
- Retrieves an array of Cost Category names and values incurred cost.
- GetCostComparisonDrivers ( array $params = [] )
- Retrieves key factors driving cost changes between two time periods within the last 13 months, such as usage changes, discount changes, and commitment-based savings.
- GetCostForecast ( array $params = [] )
- Retrieves a forecast for how much Amazon Web Services predicts that you will spend over the forecast time period that you select, based on your past costs.
- GetDimensionValues ( array $params = [] )
- Retrieves all available filter values for a specified filter over a period of time.
- GetReservationCoverage ( array $params = [] )
- Retrieves the reservation coverage for your account, which you can use to see how much of your Amazon Elastic Compute Cloud, Amazon ElastiCache, Amazon Relational Database Service, or Amazon Redshift usage is covered by a reservation.
- GetReservationPurchaseRecommendation ( array $params = [] )
- Gets recommendations for reservation purchases.
- GetReservationUtilization ( array $params = [] )
- Retrieves the reservation utilization for your account.
- GetRightsizingRecommendation ( array $params = [] )
- Creates recommendations that help you save cost by identifying idle and underutilized Amazon EC2 instances.
- GetSavingsPlanPurchaseRecommendationDetails ( array $params = [] )
- Retrieves the details for a Savings Plan recommendation.
- GetSavingsPlansCoverage ( array $params = [] )
- Retrieves the Savings Plans covered for your account.
- GetSavingsPlansPurchaseRecommendation ( array $params = [] )
- Retrieves the Savings Plans recommendations for your account.
- GetSavingsPlansUtilization ( array $params = [] )
- Retrieves the Savings Plans utilization for your account across date ranges with daily or monthly granularity.
- GetSavingsPlansUtilizationDetails ( array $params = [] )
- Retrieves attribute data along with aggregate utilization and savings data for a given time period.
- GetTags ( array $params = [] )
- Queries for available tag keys and tag values for a specified period.
- GetUsageForecast ( array $params = [] )
- Retrieves a forecast for how much Amazon Web Services predicts that you will use over the forecast time period that you select, based on your past usage.
- ListCommitmentPurchaseAnalyses ( array $params = [] )
- Lists the commitment purchase analyses for your account.
- ListCostAllocationTagBackfillHistory ( array $params = [] )
- Retrieves a list of your historical cost allocation tag backfill requests.
- ListCostAllocationTags ( array $params = [] )
- Get a list of cost allocation tags.
- ListCostCategoryDefinitions ( array $params = [] )
- Returns the name, Amazon Resource Name (ARN), NumberOfRules and effective dates of all Cost Categories defined in the account.
- ListSavingsPlansPurchaseRecommendationGeneration ( array $params = [] )
- Retrieves a list of your historical recommendation generations within the past 30 days.
- ListTagsForResource ( array $params = [] )
- Returns a list of resource tags associated with the resource specified by the Amazon Resource Name (ARN).
- ProvideAnomalyFeedback ( array $params = [] )
- Modifies the feedback property of a given cost anomaly.
- StartCommitmentPurchaseAnalysis ( array $params = [] )
- Specifies the parameters of a planned commitment purchase and starts the generation of the analysis.
- StartCostAllocationTagBackfill ( array $params = [] )
- Request a cost allocation tag backfill.
- StartSavingsPlansPurchaseRecommendationGeneration ( array $params = [] )
- Requests a Savings Plans recommendation generation.
- TagResource ( array $params = [] )
- An API operation for adding one or more tags (key-value pairs) to a resource.
- UntagResource ( array $params = [] )
- Removes one or more tags from a resource.
- UpdateAnomalyMonitor ( array $params = [] )
- Updates an existing cost anomaly monitor.
- UpdateAnomalySubscription ( array $params = [] )
- Updates an existing cost anomaly subscription.
- UpdateCostAllocationTagsStatus ( array $params = [] )
- Updates status for cost allocation tags in bulk, with maximum batch size of 20.
- UpdateCostCategoryDefinition ( array $params = [] )
- Updates an existing Cost Category.
Paginators
Paginators handle automatically iterating over paginated API results. Paginators are associated with specific API operations, and they accept the parameters that the corresponding API operation accepts. You can get a paginator from a client class using getPaginator($paginatorName, $operationParameters). This client supports the following paginators:
- GetAnomalies
- GetAnomalyMonitors
- GetAnomalySubscriptions
- GetCostAndUsageComparisons
- GetCostComparisonDrivers
- GetSavingsPlansCoverage
- GetSavingsPlansUtilizationDetails
- ListCostAllocationTagBackfillHistory
- ListCostAllocationTags
- ListCostCategoryDefinitions
Operations
CreateAnomalyMonitor
$result = $client->createAnomalyMonitor([/* ... */]); $promise = $client->createAnomalyMonitorAsync([/* ... */]);
Creates a new cost anomaly detection monitor with the requested type and monitor specification.
Parameter Syntax
$result = $client->createAnomalyMonitor([
    'AnomalyMonitor' => [ // REQUIRED
        'CreationDate' => '<string>',
        'DimensionalValueCount' => <integer>,
        'LastEvaluatedDate' => '<string>',
        'LastUpdatedDate' => '<string>',
        'MonitorArn' => '<string>',
        'MonitorDimension' => 'SERVICE',
        'MonitorName' => '<string>', // REQUIRED
        'MonitorSpecification' => [
            'And' => [
                [...], // RECURSIVE
                // ...
            ],
            'CostCategories' => [
                'Key' => '<string>',
                'MatchOptions' => ['<string>', ...],
                'Values' => ['<string>', ...],
            ],
            'Dimensions' => [
                'Key' => 'AZ|INSTANCE_TYPE|LINKED_ACCOUNT|PAYER_ACCOUNT|LINKED_ACCOUNT_NAME|OPERATION|PURCHASE_TYPE|REGION|SERVICE|SERVICE_CODE|USAGE_TYPE|USAGE_TYPE_GROUP|RECORD_TYPE|OPERATING_SYSTEM|TENANCY|SCOPE|PLATFORM|SUBSCRIPTION_ID|LEGAL_ENTITY_NAME|DEPLOYMENT_OPTION|DATABASE_ENGINE|CACHE_ENGINE|INSTANCE_TYPE_FAMILY|BILLING_ENTITY|RESERVATION_ID|RESOURCE_ID|RIGHTSIZING_TYPE|SAVINGS_PLANS_TYPE|SAVINGS_PLAN_ARN|PAYMENT_OPTION|AGREEMENT_END_DATE_TIME_AFTER|AGREEMENT_END_DATE_TIME_BEFORE|INVOICING_ENTITY|ANOMALY_TOTAL_IMPACT_ABSOLUTE|ANOMALY_TOTAL_IMPACT_PERCENTAGE',
                'MatchOptions' => ['<string>', ...],
                'Values' => ['<string>', ...],
            ],
            'Not' => [...], // RECURSIVE
            'Or' => [
                [...], // RECURSIVE
                // ...
            ],
            'Tags' => [
                'Key' => '<string>',
                'MatchOptions' => ['<string>', ...],
                'Values' => ['<string>', ...],
            ],
        ],
        'MonitorType' => 'DIMENSIONAL|CUSTOM', // REQUIRED
    ],
    'ResourceTags' => [
        [
            'Key' => '<string>', // REQUIRED
            'Value' => '<string>', // REQUIRED
        ],
        // ...
    ],
]);
	Parameter Details
Members
- AnomalyMonitor
- 
- Required: Yes
- Type: AnomalyMonitor structure
 The cost anomaly detection monitor object that you want to create. 
- ResourceTags
- 
- Type: Array of ResourceTag structures
 An optional list of tags to associate with the specified AnomalyMonitor. You can use resource tags to control access to yourmonitorusing IAM policies.Each tag consists of a key and a value, and each key must be unique for the resource. The following restrictions apply to resource tags: -  Although the maximum number of array members is 200, you can assign a maximum of 50 user-tags to one resource. The remaining are reserved for Amazon Web Services use 
-  The maximum length of a key is 128 characters 
-  The maximum length of a value is 256 characters 
-  Keys and values can only contain alphanumeric characters, spaces, and any of the following: _.:/=+@-
-  Keys and values are case sensitive 
-  Keys and values are trimmed for any leading or trailing whitespaces 
-  Don’t use aws:as a prefix for your keys. This prefix is reserved for Amazon Web Services use
 
Result Syntax
[
    'MonitorArn' => '<string>',
]
	Result Details
Members
- MonitorArn
- 
- Required: Yes
- Type: string
 The unique identifier of your newly created cost anomaly detection monitor. 
Errors
- LimitExceededException:
- You made too many calls in a short period of time. Try again later. 
CreateAnomalySubscription
$result = $client->createAnomalySubscription([/* ... */]); $promise = $client->createAnomalySubscriptionAsync([/* ... */]);
Adds an alert subscription to a cost anomaly detection monitor. You can use each subscription to define subscribers with email or SNS notifications. Email subscribers can set an absolute or percentage threshold and a time frequency for receiving notifications.
Parameter Syntax
$result = $client->createAnomalySubscription([
    'AnomalySubscription' => [ // REQUIRED
        'AccountId' => '<string>',
        'Frequency' => 'DAILY|IMMEDIATE|WEEKLY', // REQUIRED
        'MonitorArnList' => ['<string>', ...], // REQUIRED
        'Subscribers' => [ // REQUIRED
            [
                'Address' => '<string>',
                'Status' => 'CONFIRMED|DECLINED',
                'Type' => 'EMAIL|SNS',
            ],
            // ...
        ],
        'SubscriptionArn' => '<string>',
        'SubscriptionName' => '<string>', // REQUIRED
        'Threshold' => <float>,
        'ThresholdExpression' => [
            'And' => [
                [...], // RECURSIVE
                // ...
            ],
            'CostCategories' => [
                'Key' => '<string>',
                'MatchOptions' => ['<string>', ...],
                'Values' => ['<string>', ...],
            ],
            'Dimensions' => [
                'Key' => 'AZ|INSTANCE_TYPE|LINKED_ACCOUNT|PAYER_ACCOUNT|LINKED_ACCOUNT_NAME|OPERATION|PURCHASE_TYPE|REGION|SERVICE|SERVICE_CODE|USAGE_TYPE|USAGE_TYPE_GROUP|RECORD_TYPE|OPERATING_SYSTEM|TENANCY|SCOPE|PLATFORM|SUBSCRIPTION_ID|LEGAL_ENTITY_NAME|DEPLOYMENT_OPTION|DATABASE_ENGINE|CACHE_ENGINE|INSTANCE_TYPE_FAMILY|BILLING_ENTITY|RESERVATION_ID|RESOURCE_ID|RIGHTSIZING_TYPE|SAVINGS_PLANS_TYPE|SAVINGS_PLAN_ARN|PAYMENT_OPTION|AGREEMENT_END_DATE_TIME_AFTER|AGREEMENT_END_DATE_TIME_BEFORE|INVOICING_ENTITY|ANOMALY_TOTAL_IMPACT_ABSOLUTE|ANOMALY_TOTAL_IMPACT_PERCENTAGE',
                'MatchOptions' => ['<string>', ...],
                'Values' => ['<string>', ...],
            ],
            'Not' => [...], // RECURSIVE
            'Or' => [
                [...], // RECURSIVE
                // ...
            ],
            'Tags' => [
                'Key' => '<string>',
                'MatchOptions' => ['<string>', ...],
                'Values' => ['<string>', ...],
            ],
        ],
    ],
    'ResourceTags' => [
        [
            'Key' => '<string>', // REQUIRED
            'Value' => '<string>', // REQUIRED
        ],
        // ...
    ],
]);
	Parameter Details
Members
- AnomalySubscription
- 
- Required: Yes
- Type: AnomalySubscription structure
 The cost anomaly subscription object that you want to create. 
- ResourceTags
- 
- Type: Array of ResourceTag structures
 An optional list of tags to associate with the specified AnomalySubscription. You can use resource tags to control access to yoursubscriptionusing IAM policies.Each tag consists of a key and a value, and each key must be unique for the resource. The following restrictions apply to resource tags: -  Although the maximum number of array members is 200, you can assign a maximum of 50 user-tags to one resource. The remaining are reserved for Amazon Web Services use 
-  The maximum length of a key is 128 characters 
-  The maximum length of a value is 256 characters 
-  Keys and values can only contain alphanumeric characters, spaces, and any of the following: _.:/=+@-
-  Keys and values are case sensitive 
-  Keys and values are trimmed for any leading or trailing whitespaces 
-  Don’t use aws:as a prefix for your keys. This prefix is reserved for Amazon Web Services use
 
Result Syntax
[
    'SubscriptionArn' => '<string>',
]
	Result Details
Members
- SubscriptionArn
- 
- Required: Yes
- Type: string
 The unique identifier of your newly created cost anomaly subscription. 
Errors
- UnknownMonitorException:
- The cost anomaly monitor does not exist for the account. 
- LimitExceededException:
- You made too many calls in a short period of time. Try again later. 
CreateCostCategoryDefinition
$result = $client->createCostCategoryDefinition([/* ... */]); $promise = $client->createCostCategoryDefinitionAsync([/* ... */]);
Creates a new Cost Category with the requested name and rules.
Parameter Syntax
$result = $client->createCostCategoryDefinition([
    'DefaultValue' => '<string>',
    'EffectiveStart' => '<string>',
    'Name' => '<string>', // REQUIRED
    'ResourceTags' => [
        [
            'Key' => '<string>', // REQUIRED
            'Value' => '<string>', // REQUIRED
        ],
        // ...
    ],
    'RuleVersion' => 'CostCategoryExpression.v1', // REQUIRED
    'Rules' => [ // REQUIRED
        [
            'InheritedValue' => [
                'DimensionKey' => '<string>',
                'DimensionName' => 'LINKED_ACCOUNT_NAME|TAG',
            ],
            'Rule' => [
                'And' => [
                    [...], // RECURSIVE
                    // ...
                ],
                'CostCategories' => [
                    'Key' => '<string>',
                    'MatchOptions' => ['<string>', ...],
                    'Values' => ['<string>', ...],
                ],
                'Dimensions' => [
                    'Key' => 'AZ|INSTANCE_TYPE|LINKED_ACCOUNT|PAYER_ACCOUNT|LINKED_ACCOUNT_NAME|OPERATION|PURCHASE_TYPE|REGION|SERVICE|SERVICE_CODE|USAGE_TYPE|USAGE_TYPE_GROUP|RECORD_TYPE|OPERATING_SYSTEM|TENANCY|SCOPE|PLATFORM|SUBSCRIPTION_ID|LEGAL_ENTITY_NAME|DEPLOYMENT_OPTION|DATABASE_ENGINE|CACHE_ENGINE|INSTANCE_TYPE_FAMILY|BILLING_ENTITY|RESERVATION_ID|RESOURCE_ID|RIGHTSIZING_TYPE|SAVINGS_PLANS_TYPE|SAVINGS_PLAN_ARN|PAYMENT_OPTION|AGREEMENT_END_DATE_TIME_AFTER|AGREEMENT_END_DATE_TIME_BEFORE|INVOICING_ENTITY|ANOMALY_TOTAL_IMPACT_ABSOLUTE|ANOMALY_TOTAL_IMPACT_PERCENTAGE',
                    'MatchOptions' => ['<string>', ...],
                    'Values' => ['<string>', ...],
                ],
                'Not' => [...], // RECURSIVE
                'Or' => [
                    [...], // RECURSIVE
                    // ...
                ],
                'Tags' => [
                    'Key' => '<string>',
                    'MatchOptions' => ['<string>', ...],
                    'Values' => ['<string>', ...],
                ],
            ],
            'Type' => 'REGULAR|INHERITED_VALUE',
            'Value' => '<string>',
        ],
        // ...
    ],
    'SplitChargeRules' => [
        [
            'Method' => 'FIXED|PROPORTIONAL|EVEN', // REQUIRED
            'Parameters' => [
                [
                    'Type' => 'ALLOCATION_PERCENTAGES', // REQUIRED
                    'Values' => ['<string>', ...], // REQUIRED
                ],
                // ...
            ],
            'Source' => '<string>', // REQUIRED
            'Targets' => ['<string>', ...], // REQUIRED
        ],
        // ...
    ],
]);
	Parameter Details
Members
- DefaultValue
- 
- Type: string
 The default value for the cost category. 
- EffectiveStart
- 
- Type: string
 The Cost Category's effective start date. It can only be a billing start date (first day of the month). If the date isn't provided, it's the first day of the current month. Dates can't be before the previous twelve months, or in the future. 
- Name
- 
- Required: Yes
- Type: string
 The unique name of the Cost Category. 
- ResourceTags
- 
- Type: Array of ResourceTag structures
 An optional list of tags to associate with the specified CostCategory. You can use resource tags to control access to yourcost categoryusing IAM policies.Each tag consists of a key and a value, and each key must be unique for the resource. The following restrictions apply to resource tags: -  Although the maximum number of array members is 200, you can assign a maximum of 50 user-tags to one resource. The remaining are reserved for Amazon Web Services use 
-  The maximum length of a key is 128 characters 
-  The maximum length of a value is 256 characters 
-  Keys and values can only contain alphanumeric characters, spaces, and any of the following: _.:/=+@-
-  Keys and values are case sensitive 
-  Keys and values are trimmed for any leading or trailing whitespaces 
-  Don’t use aws:as a prefix for your keys. This prefix is reserved for Amazon Web Services use
 
- RuleVersion
- 
- Required: Yes
- Type: string
 The rule schema version in this particular Cost Category. 
- Rules
- 
- Required: Yes
- Type: Array of CostCategoryRule structures
 The Cost Category rules used to categorize costs. For more information, see CostCategoryRule. 
- SplitChargeRules
- 
- Type: Array of CostCategorySplitChargeRule structures
 The split charge rules used to allocate your charges between your Cost Category values. 
Result Syntax
[
    'CostCategoryArn' => '<string>',
    'EffectiveStart' => '<string>',
]
	Result Details
Members
- CostCategoryArn
- 
- Type: string
 The unique identifier for your newly created Cost Category. 
- EffectiveStart
- 
- Type: string
 The Cost Category's effective start date. It can only be a billing start date (first day of the month). 
Errors
- ServiceQuotaExceededException:
- You've reached the limit on the number of resources you can create, or exceeded the size of an individual resource. 
- LimitExceededException:
- You made too many calls in a short period of time. Try again later. 
DeleteAnomalyMonitor
$result = $client->deleteAnomalyMonitor([/* ... */]); $promise = $client->deleteAnomalyMonitorAsync([/* ... */]);
Deletes a cost anomaly monitor.
Parameter Syntax
$result = $client->deleteAnomalyMonitor([
    'MonitorArn' => '<string>', // REQUIRED
]);
	Parameter Details
Members
- MonitorArn
- 
- Required: Yes
- Type: string
 The unique identifier of the cost anomaly monitor that you want to delete. 
Result Syntax
[]
Result Details
Errors
- LimitExceededException:
- You made too many calls in a short period of time. Try again later. 
- UnknownMonitorException:
- The cost anomaly monitor does not exist for the account. 
DeleteAnomalySubscription
$result = $client->deleteAnomalySubscription([/* ... */]); $promise = $client->deleteAnomalySubscriptionAsync([/* ... */]);
Deletes a cost anomaly subscription.
Parameter Syntax
$result = $client->deleteAnomalySubscription([
    'SubscriptionArn' => '<string>', // REQUIRED
]);
	Parameter Details
Members
- SubscriptionArn
- 
- Required: Yes
- Type: string
 The unique identifier of the cost anomaly subscription that you want to delete. 
Result Syntax
[]
Result Details
Errors
- LimitExceededException:
- You made too many calls in a short period of time. Try again later. 
- UnknownSubscriptionException:
- The cost anomaly subscription does not exist for the account. 
DeleteCostCategoryDefinition
$result = $client->deleteCostCategoryDefinition([/* ... */]); $promise = $client->deleteCostCategoryDefinitionAsync([/* ... */]);
Deletes a Cost Category. Expenses from this month going forward will no longer be categorized with this Cost Category.
Parameter Syntax
$result = $client->deleteCostCategoryDefinition([
    'CostCategoryArn' => '<string>', // REQUIRED
]);
	Parameter Details
Members
- CostCategoryArn
- 
- Required: Yes
- Type: string
 The unique identifier for your Cost Category. 
Result Syntax
[
    'CostCategoryArn' => '<string>',
    'EffectiveEnd' => '<string>',
]
	Result Details
Members
- CostCategoryArn
- 
- Type: string
 The unique identifier for your Cost Category. 
- EffectiveEnd
- 
- Type: string
 The effective end date of the Cost Category as a result of deleting it. No costs after this date is categorized by the deleted Cost Category. 
Errors
- ResourceNotFoundException:
- The specified ARN in the request doesn't exist. 
- LimitExceededException:
- You made too many calls in a short period of time. Try again later. 
DescribeCostCategoryDefinition
$result = $client->describeCostCategoryDefinition([/* ... */]); $promise = $client->describeCostCategoryDefinitionAsync([/* ... */]);
Returns the name, Amazon Resource Name (ARN), rules, definition, and effective dates of a Cost Category that's defined in the account.
You have the option to use EffectiveOn to return a Cost Category that's active on a specific date. If there's no EffectiveOn specified, you see a Cost Category that's effective on the current date. If Cost Category is still effective, EffectiveEnd is omitted in the response. 
Parameter Syntax
$result = $client->describeCostCategoryDefinition([
    'CostCategoryArn' => '<string>', // REQUIRED
    'EffectiveOn' => '<string>',
]);
	Parameter Details
Members
- CostCategoryArn
- 
- Required: Yes
- Type: string
 The unique identifier for your Cost Category. 
- EffectiveOn
- 
- Type: string
 The date when the Cost Category was effective. 
Result Syntax
[
    'CostCategory' => [
        'CostCategoryArn' => '<string>',
        'DefaultValue' => '<string>',
        'EffectiveEnd' => '<string>',
        'EffectiveStart' => '<string>',
        'Name' => '<string>',
        'ProcessingStatus' => [
            [
                'Component' => 'COST_EXPLORER',
                'Status' => 'PROCESSING|APPLIED',
            ],
            // ...
        ],
        'RuleVersion' => 'CostCategoryExpression.v1',
        'Rules' => [
            [
                'InheritedValue' => [
                    'DimensionKey' => '<string>',
                    'DimensionName' => 'LINKED_ACCOUNT_NAME|TAG',
                ],
                'Rule' => [
                    'And' => [
                        [...], // RECURSIVE
                        // ...
                    ],
                    'CostCategories' => [
                        'Key' => '<string>',
                        'MatchOptions' => ['<string>', ...],
                        'Values' => ['<string>', ...],
                    ],
                    'Dimensions' => [
                        'Key' => 'AZ|INSTANCE_TYPE|LINKED_ACCOUNT|PAYER_ACCOUNT|LINKED_ACCOUNT_NAME|OPERATION|PURCHASE_TYPE|REGION|SERVICE|SERVICE_CODE|USAGE_TYPE|USAGE_TYPE_GROUP|RECORD_TYPE|OPERATING_SYSTEM|TENANCY|SCOPE|PLATFORM|SUBSCRIPTION_ID|LEGAL_ENTITY_NAME|DEPLOYMENT_OPTION|DATABASE_ENGINE|CACHE_ENGINE|INSTANCE_TYPE_FAMILY|BILLING_ENTITY|RESERVATION_ID|RESOURCE_ID|RIGHTSIZING_TYPE|SAVINGS_PLANS_TYPE|SAVINGS_PLAN_ARN|PAYMENT_OPTION|AGREEMENT_END_DATE_TIME_AFTER|AGREEMENT_END_DATE_TIME_BEFORE|INVOICING_ENTITY|ANOMALY_TOTAL_IMPACT_ABSOLUTE|ANOMALY_TOTAL_IMPACT_PERCENTAGE',
                        'MatchOptions' => ['<string>', ...],
                        'Values' => ['<string>', ...],
                    ],
                    'Not' => [...], // RECURSIVE
                    'Or' => [
                        [...], // RECURSIVE
                        // ...
                    ],
                    'Tags' => [
                        'Key' => '<string>',
                        'MatchOptions' => ['<string>', ...],
                        'Values' => ['<string>', ...],
                    ],
                ],
                'Type' => 'REGULAR|INHERITED_VALUE',
                'Value' => '<string>',
            ],
            // ...
        ],
        'SplitChargeRules' => [
            [
                'Method' => 'FIXED|PROPORTIONAL|EVEN',
                'Parameters' => [
                    [
                        'Type' => 'ALLOCATION_PERCENTAGES',
                        'Values' => ['<string>', ...],
                    ],
                    // ...
                ],
                'Source' => '<string>',
                'Targets' => ['<string>', ...],
            ],
            // ...
        ],
    ],
]
	Result Details
Members
- CostCategory
- 
- Type: CostCategory structure
 The structure of Cost Categories. This includes detailed metadata and the set of rules for the CostCategoryobject.
Errors
- ResourceNotFoundException:
- The specified ARN in the request doesn't exist. 
- LimitExceededException:
- You made too many calls in a short period of time. Try again later. 
GetAnomalies
$result = $client->getAnomalies([/* ... */]); $promise = $client->getAnomaliesAsync([/* ... */]);
Retrieves all of the cost anomalies detected on your account during the time period that's specified by the DateInterval object. Anomalies are available for up to 90 days.
Parameter Syntax
$result = $client->getAnomalies([
    'DateInterval' => [ // REQUIRED
        'EndDate' => '<string>',
        'StartDate' => '<string>', // REQUIRED
    ],
    'Feedback' => 'YES|NO|PLANNED_ACTIVITY',
    'MaxResults' => <integer>,
    'MonitorArn' => '<string>',
    'NextPageToken' => '<string>',
    'TotalImpact' => [
        'EndValue' => <float>,
        'NumericOperator' => 'EQUAL|GREATER_THAN_OR_EQUAL|LESS_THAN_OR_EQUAL|GREATER_THAN|LESS_THAN|BETWEEN', // REQUIRED
        'StartValue' => <float>, // REQUIRED
    ],
]);
	Parameter Details
Members
- DateInterval
- 
- Required: Yes
- Type: AnomalyDateInterval structure
 Assigns the start and end dates for retrieving cost anomalies. The returned anomaly object will have an AnomalyEndDatein the specified time range.
- Feedback
- 
- Type: string
 Filters anomaly results by the feedback field on the anomaly object. 
- MaxResults
- 
- Type: int
 The number of entries a paginated response contains. 
- MonitorArn
- 
- Type: string
 Retrieves all of the cost anomalies detected for a specific cost anomaly monitor Amazon Resource Name (ARN). 
- NextPageToken
- 
- Type: string
 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. 
- TotalImpact
- 
- Type: TotalImpactFilter structure
 Filters anomaly results by the total impact field on the anomaly object. For example, you can filter anomalies GREATER_THAN 200.00to retrieve anomalies, with an estimated dollar impact greater than 200.
Result Syntax
[
    'Anomalies' => [
        [
            'AnomalyEndDate' => '<string>',
            'AnomalyId' => '<string>',
            'AnomalyScore' => [
                'CurrentScore' => <float>,
                'MaxScore' => <float>,
            ],
            'AnomalyStartDate' => '<string>',
            'DimensionValue' => '<string>',
            'Feedback' => 'YES|NO|PLANNED_ACTIVITY',
            'Impact' => [
                'MaxImpact' => <float>,
                'TotalActualSpend' => <float>,
                'TotalExpectedSpend' => <float>,
                'TotalImpact' => <float>,
                'TotalImpactPercentage' => <float>,
            ],
            'MonitorArn' => '<string>',
            'RootCauses' => [
                [
                    'Impact' => [
                        'Contribution' => <float>,
                    ],
                    'LinkedAccount' => '<string>',
                    'LinkedAccountName' => '<string>',
                    'Region' => '<string>',
                    'Service' => '<string>',
                    'UsageType' => '<string>',
                ],
                // ...
            ],
        ],
        // ...
    ],
    'NextPageToken' => '<string>',
]
	Result Details
Members
- Anomalies
- 
- Required: Yes
- Type: Array of Anomaly structures
 A list of cost anomalies. 
- NextPageToken
- 
- Type: string
 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. 
Errors
- LimitExceededException:
- You made too many calls in a short period of time. Try again later. 
- InvalidNextTokenException:
- The pagination token is invalid. Try again without a pagination token. 
GetAnomalyMonitors
$result = $client->getAnomalyMonitors([/* ... */]); $promise = $client->getAnomalyMonitorsAsync([/* ... */]);
Retrieves the cost anomaly monitor definitions for your account. You can filter using a list of cost anomaly monitor Amazon Resource Names (ARNs).
Parameter Syntax
$result = $client->getAnomalyMonitors([
    'MaxResults' => <integer>,
    'MonitorArnList' => ['<string>', ...],
    'NextPageToken' => '<string>',
]);
	Parameter Details
Members
- MaxResults
- 
- Type: int
 The number of entries that a paginated response contains. 
- MonitorArnList
- 
- Type: Array of strings
 A list of cost anomaly monitor ARNs. 
- NextPageToken
- 
- Type: string
 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. 
Result Syntax
[
    'AnomalyMonitors' => [
        [
            'CreationDate' => '<string>',
            'DimensionalValueCount' => <integer>,
            'LastEvaluatedDate' => '<string>',
            'LastUpdatedDate' => '<string>',
            'MonitorArn' => '<string>',
            'MonitorDimension' => 'SERVICE',
            'MonitorName' => '<string>',
            'MonitorSpecification' => [
                'And' => [
                    [...], // RECURSIVE
                    // ...
                ],
                'CostCategories' => [
                    'Key' => '<string>',
                    'MatchOptions' => ['<string>', ...],
                    'Values' => ['<string>', ...],
                ],
                'Dimensions' => [
                    'Key' => 'AZ|INSTANCE_TYPE|LINKED_ACCOUNT|PAYER_ACCOUNT|LINKED_ACCOUNT_NAME|OPERATION|PURCHASE_TYPE|REGION|SERVICE|SERVICE_CODE|USAGE_TYPE|USAGE_TYPE_GROUP|RECORD_TYPE|OPERATING_SYSTEM|TENANCY|SCOPE|PLATFORM|SUBSCRIPTION_ID|LEGAL_ENTITY_NAME|DEPLOYMENT_OPTION|DATABASE_ENGINE|CACHE_ENGINE|INSTANCE_TYPE_FAMILY|BILLING_ENTITY|RESERVATION_ID|RESOURCE_ID|RIGHTSIZING_TYPE|SAVINGS_PLANS_TYPE|SAVINGS_PLAN_ARN|PAYMENT_OPTION|AGREEMENT_END_DATE_TIME_AFTER|AGREEMENT_END_DATE_TIME_BEFORE|INVOICING_ENTITY|ANOMALY_TOTAL_IMPACT_ABSOLUTE|ANOMALY_TOTAL_IMPACT_PERCENTAGE',
                    'MatchOptions' => ['<string>', ...],
                    'Values' => ['<string>', ...],
                ],
                'Not' => [...], // RECURSIVE
                'Or' => [
                    [...], // RECURSIVE
                    // ...
                ],
                'Tags' => [
                    'Key' => '<string>',
                    'MatchOptions' => ['<string>', ...],
                    'Values' => ['<string>', ...],
                ],
            ],
            'MonitorType' => 'DIMENSIONAL|CUSTOM',
        ],
        // ...
    ],
    'NextPageToken' => '<string>',
]
	Result Details
Members
- AnomalyMonitors
- 
- Required: Yes
- Type: Array of AnomalyMonitor structures
 A list of cost anomaly monitors that includes the detailed metadata for each monitor. 
- NextPageToken
- 
- Type: string
 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. 
Errors
- LimitExceededException:
- You made too many calls in a short period of time. Try again later. 
- UnknownMonitorException:
- The cost anomaly monitor does not exist for the account. 
- InvalidNextTokenException:
- The pagination token is invalid. Try again without a pagination token. 
GetAnomalySubscriptions
$result = $client->getAnomalySubscriptions([/* ... */]); $promise = $client->getAnomalySubscriptionsAsync([/* ... */]);
Retrieves the cost anomaly subscription objects for your account. You can filter using a list of cost anomaly monitor Amazon Resource Names (ARNs).
Parameter Syntax
$result = $client->getAnomalySubscriptions([
    'MaxResults' => <integer>,
    'MonitorArn' => '<string>',
    'NextPageToken' => '<string>',
    'SubscriptionArnList' => ['<string>', ...],
]);
	Parameter Details
Members
- MaxResults
- 
- Type: int
 The number of entries a paginated response contains. 
- MonitorArn
- 
- Type: string
 Cost anomaly monitor ARNs. 
- NextPageToken
- 
- Type: string
 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. 
- SubscriptionArnList
- 
- Type: Array of strings
 A list of cost anomaly subscription ARNs. 
Result Syntax
[
    'AnomalySubscriptions' => [
        [
            'AccountId' => '<string>',
            'Frequency' => 'DAILY|IMMEDIATE|WEEKLY',
            'MonitorArnList' => ['<string>', ...],
            'Subscribers' => [
                [
                    'Address' => '<string>',
                    'Status' => 'CONFIRMED|DECLINED',
                    'Type' => 'EMAIL|SNS',
                ],
                // ...
            ],
            'SubscriptionArn' => '<string>',
            'SubscriptionName' => '<string>',
            'Threshold' => <float>,
            'ThresholdExpression' => [
                'And' => [
                    [...], // RECURSIVE
                    // ...
                ],
                'CostCategories' => [
                    'Key' => '<string>',
                    'MatchOptions' => ['<string>', ...],
                    'Values' => ['<string>', ...],
                ],
                'Dimensions' => [
                    'Key' => 'AZ|INSTANCE_TYPE|LINKED_ACCOUNT|PAYER_ACCOUNT|LINKED_ACCOUNT_NAME|OPERATION|PURCHASE_TYPE|REGION|SERVICE|SERVICE_CODE|USAGE_TYPE|USAGE_TYPE_GROUP|RECORD_TYPE|OPERATING_SYSTEM|TENANCY|SCOPE|PLATFORM|SUBSCRIPTION_ID|LEGAL_ENTITY_NAME|DEPLOYMENT_OPTION|DATABASE_ENGINE|CACHE_ENGINE|INSTANCE_TYPE_FAMILY|BILLING_ENTITY|RESERVATION_ID|RESOURCE_ID|RIGHTSIZING_TYPE|SAVINGS_PLANS_TYPE|SAVINGS_PLAN_ARN|PAYMENT_OPTION|AGREEMENT_END_DATE_TIME_AFTER|AGREEMENT_END_DATE_TIME_BEFORE|INVOICING_ENTITY|ANOMALY_TOTAL_IMPACT_ABSOLUTE|ANOMALY_TOTAL_IMPACT_PERCENTAGE',
                    'MatchOptions' => ['<string>', ...],
                    'Values' => ['<string>', ...],
                ],
                'Not' => [...], // RECURSIVE
                'Or' => [
                    [...], // RECURSIVE
                    // ...
                ],
                'Tags' => [
                    'Key' => '<string>',
                    'MatchOptions' => ['<string>', ...],
                    'Values' => ['<string>', ...],
                ],
            ],
        ],
        // ...
    ],
    'NextPageToken' => '<string>',
]
	Result Details
Members
- AnomalySubscriptions
- 
- Required: Yes
- Type: Array of AnomalySubscription structures
 A list of cost anomaly subscriptions that includes the detailed metadata for each one. 
- NextPageToken
- 
- Type: string
 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. 
Errors
- LimitExceededException:
- You made too many calls in a short period of time. Try again later. 
- UnknownSubscriptionException:
- The cost anomaly subscription does not exist for the account. 
- InvalidNextTokenException:
- The pagination token is invalid. Try again without a pagination token. 
GetApproximateUsageRecords
$result = $client->getApproximateUsageRecords([/* ... */]); $promise = $client->getApproximateUsageRecordsAsync([/* ... */]);
Retrieves estimated usage records for hourly granularity or resource-level data at daily granularity.
Parameter Syntax
$result = $client->getApproximateUsageRecords([
    'ApproximationDimension' => 'SERVICE|RESOURCE', // REQUIRED
    'Granularity' => 'DAILY|MONTHLY|HOURLY', // REQUIRED
    'Services' => ['<string>', ...],
]);
	Parameter Details
Members
- ApproximationDimension
- 
- Required: Yes
- Type: string
 The service to evaluate for the usage records. You can choose resource-level data at daily granularity, or hourly granularity with or without resource-level data. 
- Granularity
- 
- Required: Yes
- Type: string
 How granular you want the data to be. You can enable data at hourly or daily granularity. 
- Services
- 
- Type: Array of strings
 The service metadata for the service or services you want to query. If not specified, all elements are returned. 
Result Syntax
[
    'LookbackPeriod' => [
        'End' => '<string>',
        'Start' => '<string>',
    ],
    'Services' => [<integer>, ...],
    'TotalRecords' => <integer>,
]
	Result Details
Members
- LookbackPeriod
- 
- Type: DateInterval structure
 The lookback period that's used for the estimation. 
- Services
- 
- Type: Associative array of custom strings keys (GenericString) to long (int|float)s
 The service metadata for the service or services in the response. 
- TotalRecords
- 
- Type: long (int|float)
 The total number of usage records for all services in the services list. 
Errors
- LimitExceededException:
- You made too many calls in a short period of time. Try again later. 
- DataUnavailableException:
- The requested data is unavailable. 
GetCommitmentPurchaseAnalysis
$result = $client->getCommitmentPurchaseAnalysis([/* ... */]); $promise = $client->getCommitmentPurchaseAnalysisAsync([/* ... */]);
Retrieves a commitment purchase analysis result based on the AnalysisId.
Parameter Syntax
$result = $client->getCommitmentPurchaseAnalysis([
    'AnalysisId' => '<string>', // REQUIRED
]);
	Parameter Details
Members
- AnalysisId
- 
- Required: Yes
- Type: string
 The analysis ID that's associated with the commitment purchase analysis. 
Result Syntax
[
    'AnalysisCompletionTime' => '<string>',
    'AnalysisDetails' => [
        'SavingsPlansPurchaseAnalysisDetails' => [
            'AdditionalMetadata' => '<string>',
            'CurrencyCode' => '<string>',
            'CurrentAverageCoverage' => '<string>',
            'CurrentAverageHourlyOnDemandSpend' => '<string>',
            'CurrentMaximumHourlyOnDemandSpend' => '<string>',
            'CurrentMinimumHourlyOnDemandSpend' => '<string>',
            'CurrentOnDemandSpend' => '<string>',
            'EstimatedAverageCoverage' => '<string>',
            'EstimatedAverageUtilization' => '<string>',
            'EstimatedCommitmentCost' => '<string>',
            'EstimatedMonthlySavingsAmount' => '<string>',
            'EstimatedOnDemandCost' => '<string>',
            'EstimatedOnDemandCostWithCurrentCommitment' => '<string>',
            'EstimatedROI' => '<string>',
            'EstimatedSavingsAmount' => '<string>',
            'EstimatedSavingsPercentage' => '<string>',
            'ExistingHourlyCommitment' => '<string>',
            'HourlyCommitmentToPurchase' => '<string>',
            'LatestUsageTimestamp' => '<string>',
            'LookbackPeriodInHours' => '<string>',
            'MetricsOverLookbackPeriod' => [
                [
                    'CurrentCoverage' => '<string>',
                    'EstimatedCoverage' => '<string>',
                    'EstimatedNewCommitmentUtilization' => '<string>',
                    'EstimatedOnDemandCost' => '<string>',
                    'StartTime' => '<string>',
                ],
                // ...
            ],
            'UpfrontCost' => '<string>',
        ],
    ],
    'AnalysisId' => '<string>',
    'AnalysisStartedTime' => '<string>',
    'AnalysisStatus' => 'SUCCEEDED|PROCESSING|FAILED',
    'CommitmentPurchaseAnalysisConfiguration' => [
        'SavingsPlansPurchaseAnalysisConfiguration' => [
            'AccountId' => '<string>',
            'AccountScope' => 'PAYER|LINKED',
            'AnalysisType' => 'MAX_SAVINGS|CUSTOM_COMMITMENT',
            'LookBackTimePeriod' => [
                'End' => '<string>',
                'Start' => '<string>',
            ],
            'SavingsPlansToAdd' => [
                [
                    'InstanceFamily' => '<string>',
                    'OfferingId' => '<string>',
                    'PaymentOption' => 'NO_UPFRONT|PARTIAL_UPFRONT|ALL_UPFRONT|LIGHT_UTILIZATION|MEDIUM_UTILIZATION|HEAVY_UTILIZATION',
                    'Region' => '<string>',
                    'SavingsPlansCommitment' => <float>,
                    'SavingsPlansType' => 'COMPUTE_SP|EC2_INSTANCE_SP|SAGEMAKER_SP',
                    'TermInYears' => 'ONE_YEAR|THREE_YEARS',
                ],
                // ...
            ],
            'SavingsPlansToExclude' => ['<string>', ...],
        ],
    ],
    'ErrorCode' => 'NO_USAGE_FOUND|INTERNAL_FAILURE|INVALID_SAVINGS_PLANS_TO_ADD|INVALID_SAVINGS_PLANS_TO_EXCLUDE|INVALID_ACCOUNT_ID',
    'EstimatedCompletionTime' => '<string>',
]
	Result Details
Members
- AnalysisCompletionTime
- 
- Type: string
 The completion time of the analysis. 
- AnalysisDetails
- 
- Type: AnalysisDetails structure
 Details about the analysis. 
- AnalysisId
- 
- Required: Yes
- Type: string
 The analysis ID that's associated with the commitment purchase analysis. 
- AnalysisStartedTime
- 
- Required: Yes
- Type: string
 The start time of the analysis. 
- AnalysisStatus
- 
- Required: Yes
- Type: string
 The status of the analysis. 
- CommitmentPurchaseAnalysisConfiguration
- 
- Required: Yes
- Type: CommitmentPurchaseAnalysisConfiguration structure
 The configuration for the commitment purchase analysis. 
- ErrorCode
- 
- Type: string
 The error code used for the analysis. 
- EstimatedCompletionTime
- 
- Required: Yes
- Type: string
 The estimated time for when the analysis will complete. 
Errors
- LimitExceededException:
- You made too many calls in a short period of time. Try again later. 
- AnalysisNotFoundException:
- The requested analysis can't be found. 
- DataUnavailableException:
- The requested data is unavailable. 
GetCostAndUsage
$result = $client->getCostAndUsage([/* ... */]); $promise = $client->getCostAndUsageAsync([/* ... */]);
Retrieves cost and usage metrics for your account. You can specify which cost and usage-related metric that you want the request to return. For example, you can specify BlendedCosts or UsageQuantity. You can also filter and group your data by various dimensions, such as SERVICE or AZ, in a specific time range. For a complete list of valid dimensions, see the GetDimensionValues operation. Management account in an organization in Organizations have access to all member accounts.
For information about filter limitations, see Quotas and restrictions in the Billing and Cost Management User Guide.
Parameter Syntax
$result = $client->getCostAndUsage([
    'BillingViewArn' => '<string>',
    'Filter' => [
        'And' => [
            [...], // RECURSIVE
            // ...
        ],
        'CostCategories' => [
            'Key' => '<string>',
            'MatchOptions' => ['<string>', ...],
            'Values' => ['<string>', ...],
        ],
        'Dimensions' => [
            'Key' => 'AZ|INSTANCE_TYPE|LINKED_ACCOUNT|PAYER_ACCOUNT|LINKED_ACCOUNT_NAME|OPERATION|PURCHASE_TYPE|REGION|SERVICE|SERVICE_CODE|USAGE_TYPE|USAGE_TYPE_GROUP|RECORD_TYPE|OPERATING_SYSTEM|TENANCY|SCOPE|PLATFORM|SUBSCRIPTION_ID|LEGAL_ENTITY_NAME|DEPLOYMENT_OPTION|DATABASE_ENGINE|CACHE_ENGINE|INSTANCE_TYPE_FAMILY|BILLING_ENTITY|RESERVATION_ID|RESOURCE_ID|RIGHTSIZING_TYPE|SAVINGS_PLANS_TYPE|SAVINGS_PLAN_ARN|PAYMENT_OPTION|AGREEMENT_END_DATE_TIME_AFTER|AGREEMENT_END_DATE_TIME_BEFORE|INVOICING_ENTITY|ANOMALY_TOTAL_IMPACT_ABSOLUTE|ANOMALY_TOTAL_IMPACT_PERCENTAGE',
            'MatchOptions' => ['<string>', ...],
            'Values' => ['<string>', ...],
        ],
        'Not' => [...], // RECURSIVE
        'Or' => [
            [...], // RECURSIVE
            // ...
        ],
        'Tags' => [
            'Key' => '<string>',
            'MatchOptions' => ['<string>', ...],
            'Values' => ['<string>', ...],
        ],
    ],
    'Granularity' => 'DAILY|MONTHLY|HOURLY', // REQUIRED
    'GroupBy' => [
        [
            'Key' => '<string>',
            'Type' => 'DIMENSION|TAG|COST_CATEGORY',
        ],
        // ...
    ],
    'Metrics' => ['<string>', ...], // REQUIRED
    'NextPageToken' => '<string>',
    'TimePeriod' => [ // REQUIRED
        'End' => '<string>', // REQUIRED
        'Start' => '<string>', // REQUIRED
    ],
]);
	Parameter Details
Members
- BillingViewArn
- 
- Type: string
 The Amazon Resource Name (ARN) that uniquely identifies a specific billing view. The ARN is used to specify which particular billing view you want to interact with or retrieve information from when making API calls related to Amazon Web Services Billing and Cost Management features. The BillingViewArn can be retrieved by calling the ListBillingViews API. 
- Filter
- 
- Type: Expression structure
 Filters Amazon Web Services costs by different dimensions. For example, you can specify SERVICEandLINKED_ACCOUNTand get the costs that are associated with that account's usage of that service. You can nestExpressionobjects to define any combination of dimension filters. For more information, see Expression.Valid values for MatchOptionsforDimensionsareEQUALSandCASE_SENSITIVE.Valid values for MatchOptionsforCostCategoriesandTagsareEQUALS,ABSENT, andCASE_SENSITIVE. Default values areEQUALSandCASE_SENSITIVE.
- Granularity
- 
- Required: Yes
- Type: string
 Sets the Amazon Web Services cost granularity to MONTHLYorDAILY, orHOURLY. IfGranularityisn't set, the response object doesn't include theGranularity, eitherMONTHLYorDAILY, orHOURLY.
- GroupBy
- 
- Type: Array of GroupDefinition structures
 You can group Amazon Web Services costs using up to two different groups, either dimensions, tag keys, cost categories, or any two group by types. Valid values for the DIMENSIONtype areAZ,INSTANCE_TYPE,LEGAL_ENTITY_NAME,INVOICING_ENTITY,LINKED_ACCOUNT,OPERATION,PLATFORM,PURCHASE_TYPE,SERVICE,TENANCY,RECORD_TYPE, andUSAGE_TYPE.When you group by the TAGtype and include a valid tag key, you get all tag values, including empty strings.
- Metrics
- 
- Required: Yes
- Type: Array of strings
 Which metrics are returned in the query. For more information about blended and unblended rates, see Why does the "blended" annotation appear on some line items in my bill?. Valid values are AmortizedCost,BlendedCost,NetAmortizedCost,NetUnblendedCost,NormalizedUsageAmount,UnblendedCost, andUsageQuantity.If you return the UsageQuantitymetric, the service aggregates all usage numbers without taking into account the units. For example, if you aggregateusageQuantityacross all of Amazon EC2, the results aren't meaningful because Amazon EC2 compute hours and data transfer are measured in different units (for example, hours and GB). To get more meaningfulUsageQuantitymetrics, filter byUsageTypeorUsageTypeGroups.Metricsis required forGetCostAndUsagerequests.
- NextPageToken
- 
- Type: string
 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. 
- TimePeriod
- 
- Required: Yes
- Type: DateInterval structure
 Sets the start date and end date for retrieving Amazon Web Services costs. The start date is inclusive, but the end date is exclusive. For example, if startis2017-01-01andendis2017-05-01, then the cost and usage data is retrieved from2017-01-01up to and including2017-04-30but not including2017-05-01.
Result Syntax
[
    'DimensionValueAttributes' => [
        [
            'Attributes' => ['<string>', ...],
            'Value' => '<string>',
        ],
        // ...
    ],
    'GroupDefinitions' => [
        [
            'Key' => '<string>',
            'Type' => 'DIMENSION|TAG|COST_CATEGORY',
        ],
        // ...
    ],
    'NextPageToken' => '<string>',
    'ResultsByTime' => [
        [
            'Estimated' => true || false,
            'Groups' => [
                [
                    'Keys' => ['<string>', ...],
                    'Metrics' => [
                        '<MetricName>' => [
                            'Amount' => '<string>',
                            'Unit' => '<string>',
                        ],
                        // ...
                    ],
                ],
                // ...
            ],
            'TimePeriod' => [
                'End' => '<string>',
                'Start' => '<string>',
            ],
            'Total' => [
                '<MetricName>' => [
                    'Amount' => '<string>',
                    'Unit' => '<string>',
                ],
                // ...
            ],
        ],
        // ...
    ],
]
	Result Details
Members
- DimensionValueAttributes
- 
- Type: Array of DimensionValuesWithAttributes structures
 The attributes that apply to a specific dimension value. For example, if the value is a linked account, the attribute is that account name. 
- GroupDefinitions
- 
- Type: Array of GroupDefinition structures
 The groups that are specified by the FilterorGroupByparameters in the request.
- NextPageToken
- 
- Type: string
 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. 
- ResultsByTime
- 
- Type: Array of ResultByTime structures
 The time period that's covered by the results in the response. 
Errors
- LimitExceededException:
- You made too many calls in a short period of time. Try again later. 
- BillExpirationException:
- The requested report expired. Update the date interval and try again. 
- DataUnavailableException:
- The requested data is unavailable. 
- InvalidNextTokenException:
- The pagination token is invalid. Try again without a pagination token. 
- RequestChangedException:
- Your request parameters changed between pages. Try again with the old parameters or without a pagination token. 
- ResourceNotFoundException:
- The specified ARN in the request doesn't exist. 
- BillingViewHealthStatusException:
- The billing view status must be - HEALTHYto perform this action. Try again when the status is- HEALTHY.
GetCostAndUsageComparisons
$result = $client->getCostAndUsageComparisons([/* ... */]); $promise = $client->getCostAndUsageComparisonsAsync([/* ... */]);
Retrieves cost and usage comparisons for your account between two periods within the last 13 months. If you have enabled multi-year data at monthly granularity, you can go back up to 38 months.
Parameter Syntax
$result = $client->getCostAndUsageComparisons([
    'BaselineTimePeriod' => [ // REQUIRED
        'End' => '<string>', // REQUIRED
        'Start' => '<string>', // REQUIRED
    ],
    'BillingViewArn' => '<string>',
    'ComparisonTimePeriod' => [ // REQUIRED
        'End' => '<string>', // REQUIRED
        'Start' => '<string>', // REQUIRED
    ],
    'Filter' => [
        'And' => [
            [...], // RECURSIVE
            // ...
        ],
        'CostCategories' => [
            'Key' => '<string>',
            'MatchOptions' => ['<string>', ...],
            'Values' => ['<string>', ...],
        ],
        'Dimensions' => [
            'Key' => 'AZ|INSTANCE_TYPE|LINKED_ACCOUNT|PAYER_ACCOUNT|LINKED_ACCOUNT_NAME|OPERATION|PURCHASE_TYPE|REGION|SERVICE|SERVICE_CODE|USAGE_TYPE|USAGE_TYPE_GROUP|RECORD_TYPE|OPERATING_SYSTEM|TENANCY|SCOPE|PLATFORM|SUBSCRIPTION_ID|LEGAL_ENTITY_NAME|DEPLOYMENT_OPTION|DATABASE_ENGINE|CACHE_ENGINE|INSTANCE_TYPE_FAMILY|BILLING_ENTITY|RESERVATION_ID|RESOURCE_ID|RIGHTSIZING_TYPE|SAVINGS_PLANS_TYPE|SAVINGS_PLAN_ARN|PAYMENT_OPTION|AGREEMENT_END_DATE_TIME_AFTER|AGREEMENT_END_DATE_TIME_BEFORE|INVOICING_ENTITY|ANOMALY_TOTAL_IMPACT_ABSOLUTE|ANOMALY_TOTAL_IMPACT_PERCENTAGE',
            'MatchOptions' => ['<string>', ...],
            'Values' => ['<string>', ...],
        ],
        'Not' => [...], // RECURSIVE
        'Or' => [
            [...], // RECURSIVE
            // ...
        ],
        'Tags' => [
            'Key' => '<string>',
            'MatchOptions' => ['<string>', ...],
            'Values' => ['<string>', ...],
        ],
    ],
    'GroupBy' => [
        [
            'Key' => '<string>',
            'Type' => 'DIMENSION|TAG|COST_CATEGORY',
        ],
        // ...
    ],
    'MaxResults' => <integer>,
    'MetricForComparison' => '<string>', // REQUIRED
    'NextPageToken' => '<string>',
]);
	Parameter Details
Members
- BaselineTimePeriod
- 
- Required: Yes
- Type: DateInterval structure
 The reference time period for comparison. This time period serves as the baseline against which other cost and usage data will be compared. The interval must start and end on the first day of a month, with a duration of exactly one month. 
- BillingViewArn
- 
- Type: string
 The Amazon Resource Name (ARN) that uniquely identifies a specific billing view. The ARN is used to specify which particular billing view you want to interact with or retrieve information from when making API calls related to Amazon Web Services Billing and Cost Management features. The BillingViewArn can be retrieved by calling the ListBillingViews API. 
- ComparisonTimePeriod
- 
- Required: Yes
- Type: DateInterval structure
 The comparison time period for analysis. This time period's cost and usage data will be compared against the baseline time period. The interval must start and end on the first day of a month, with a duration of exactly one month. 
- Filter
- 
- Type: Expression structure
 Use Expressionto filter in various Cost Explorer APIs.Not all Expressiontypes are supported in each API. Refer to the documentation for each specific API to see what is supported.There are two patterns: -  Simple dimension values. -  There are three types of simple dimension values: CostCategories,Tags, andDimensions.-  Specify the CostCategoriesfield to define a filter that acts on Cost Categories.
-  Specify the Tagsfield to define a filter that acts on Cost Allocation Tags.
-  Specify the Dimensionsfield to define a filter that acts on theDimensionValues.
 
-  
-  For each filter type, you can set the dimension name and values for the filters that you plan to use. -  For example, you can filter for REGION==us-east-1 OR REGION==us-west-1. ForGetRightsizingRecommendation, the Region is a full name (for example,REGION==US East (N. Virginia).
-  The corresponding Expressionfor this example is as follows:{ "Dimensions": { "Key": "REGION", "Values": [ "us-east-1", "us-west-1" ] } }
-  As shown in the previous example, lists of dimension values are combined with ORwhen applying the filter.
 
-  
-  You can also set different match options to further control how the filter behaves. Not all APIs support match options. Refer to the documentation for each specific API to see what is supported. -  For example, you can filter for linked account names that start with "a". 
-  The corresponding Expressionfor this example is as follows:{ "Dimensions": { "Key": "LINKED_ACCOUNT_NAME", "MatchOptions": [ "STARTS_WITH" ], "Values": [ "a" ] } }
 
-  
 
-  
-  Compound Expressiontypes with logical operations.-  You can use multiple Expressiontypes and the logical operatorsAND/OR/NOTto create a list of one or moreExpressionobjects. By doing this, you can filter by more advanced options.
-  For example, you can filter by ((REGION == us-east-1 OR REGION == us-west-1) OR (TAG.Type == Type1)) AND (USAGE_TYPE != DataTransfer).
-  The corresponding Expressionfor this example is as follows:{ "And": [ {"Or": [ {"Dimensions": { "Key": "REGION", "Values": [ "us-east-1", "us-west-1" ] }}, {"Tags": { "Key": "TagName", "Values": ["Value1"] } } ]}, {"Not": {"Dimensions": { "Key": "USAGE_TYPE", "Values": ["DataTransfer"] }}} ] }
 Because each Expressioncan have only one operator, the service returns an error if more than one is specified. The following example shows anExpressionobject that creates an error:{ "And": [ ... ], "Dimensions": { "Key": "USAGE_TYPE", "Values": [ "DataTransfer" ] } }The following is an example of the corresponding error message: "Expression has more than one roots. Only one root operator is allowed for each expression: And, Or, Not, Dimensions, Tags, CostCategories"
-  
 For the GetRightsizingRecommendationaction, a combination of OR and NOT isn't supported. OR isn't supported between different dimensions, or dimensions and tags. NOT operators aren't supported. Dimensions are also limited toLINKED_ACCOUNT,REGION, orRIGHTSIZING_TYPE.For the GetReservationPurchaseRecommendationaction, only NOT is supported. AND and OR aren't supported. Dimensions are limited toLINKED_ACCOUNT.
- GroupBy
- 
- Type: Array of GroupDefinition structures
 You can group results using the attributes DIMENSION,TAG, andCOST_CATEGORY.
- MaxResults
- 
- Type: int
 The maximum number of results that are returned for the request. 
- MetricForComparison
- 
- Required: Yes
- Type: string
 The cost and usage metric to compare. Valid values are AmortizedCost,BlendedCost,NetAmortizedCost,NetUnblendedCost,NormalizedUsageAmount,UnblendedCost, andUsageQuantity.
- NextPageToken
- 
- Type: string
 The token to retrieve the next set of paginated results. 
Result Syntax
[
    'CostAndUsageComparisons' => [
        [
            'CostAndUsageSelector' => [
                'And' => [
                    [...], // RECURSIVE
                    // ...
                ],
                'CostCategories' => [
                    'Key' => '<string>',
                    'MatchOptions' => ['<string>', ...],
                    'Values' => ['<string>', ...],
                ],
                'Dimensions' => [
                    'Key' => 'AZ|INSTANCE_TYPE|LINKED_ACCOUNT|PAYER_ACCOUNT|LINKED_ACCOUNT_NAME|OPERATION|PURCHASE_TYPE|REGION|SERVICE|SERVICE_CODE|USAGE_TYPE|USAGE_TYPE_GROUP|RECORD_TYPE|OPERATING_SYSTEM|TENANCY|SCOPE|PLATFORM|SUBSCRIPTION_ID|LEGAL_ENTITY_NAME|DEPLOYMENT_OPTION|DATABASE_ENGINE|CACHE_ENGINE|INSTANCE_TYPE_FAMILY|BILLING_ENTITY|RESERVATION_ID|RESOURCE_ID|RIGHTSIZING_TYPE|SAVINGS_PLANS_TYPE|SAVINGS_PLAN_ARN|PAYMENT_OPTION|AGREEMENT_END_DATE_TIME_AFTER|AGREEMENT_END_DATE_TIME_BEFORE|INVOICING_ENTITY|ANOMALY_TOTAL_IMPACT_ABSOLUTE|ANOMALY_TOTAL_IMPACT_PERCENTAGE',
                    'MatchOptions' => ['<string>', ...],
                    'Values' => ['<string>', ...],
                ],
                'Not' => [...], // RECURSIVE
                'Or' => [
                    [...], // RECURSIVE
                    // ...
                ],
                'Tags' => [
                    'Key' => '<string>',
                    'MatchOptions' => ['<string>', ...],
                    'Values' => ['<string>', ...],
                ],
            ],
            'Metrics' => [
                '<MetricName>' => [
                    'BaselineTimePeriodAmount' => '<string>',
                    'ComparisonTimePeriodAmount' => '<string>',
                    'Difference' => '<string>',
                    'Unit' => '<string>',
                ],
                // ...
            ],
        ],
        // ...
    ],
    'NextPageToken' => '<string>',
    'TotalCostAndUsage' => [
        '<MetricName>' => [
            'BaselineTimePeriodAmount' => '<string>',
            'ComparisonTimePeriodAmount' => '<string>',
            'Difference' => '<string>',
            'Unit' => '<string>',
        ],
        // ...
    ],
]
	Result Details
Members
- CostAndUsageComparisons
- 
- Type: Array of CostAndUsageComparison structures
 An array of comparison results showing cost and usage metrics between BaselineTimePeriodandComparisonTimePeriod.
- NextPageToken
- 
- Type: string
 The token to retrieve the next set of paginated results. 
- TotalCostAndUsage
- 
- Type: Associative array of custom strings keys (MetricName) to ComparisonMetricValue structures
 A summary of the total cost and usage, comparing amounts between BaselineTimePeriodandComparisonTimePeriodand their differences. This total represents the aggregate total across all paginated results, if the response spans multiple pages.
Errors
- DataUnavailableException:
- The requested data is unavailable. 
- InvalidNextTokenException:
- The pagination token is invalid. Try again without a pagination token. 
- LimitExceededException:
- You made too many calls in a short period of time. Try again later. 
- ResourceNotFoundException:
- The specified ARN in the request doesn't exist. 
- BillingViewHealthStatusException:
- The billing view status must be - HEALTHYto perform this action. Try again when the status is- HEALTHY.
GetCostAndUsageWithResources
$result = $client->getCostAndUsageWithResources([/* ... */]); $promise = $client->getCostAndUsageWithResourcesAsync([/* ... */]);
Retrieves cost and usage metrics with resources for your account. You can specify which cost and usage-related metric, such as BlendedCosts or UsageQuantity, that you want the request to return. You can also filter and group your data by various dimensions, such as SERVICE or AZ, in a specific time range. For a complete list of valid dimensions, see the GetDimensionValues operation. Management account in an organization in Organizations have access to all member accounts.
Hourly granularity is only available for EC2-Instances (Elastic Compute Cloud) resource-level data. All other resource-level data is available at daily granularity.
This is an opt-in only feature. You can enable this feature from the Cost Explorer Settings page. For information about how to access the Settings page, see Controlling Access for Cost Explorer in the Billing and Cost Management User Guide.
Parameter Syntax
$result = $client->getCostAndUsageWithResources([
    'BillingViewArn' => '<string>',
    'Filter' => [ // REQUIRED
        'And' => [
            [...], // RECURSIVE
            // ...
        ],
        'CostCategories' => [
            'Key' => '<string>',
            'MatchOptions' => ['<string>', ...],
            'Values' => ['<string>', ...],
        ],
        'Dimensions' => [
            'Key' => 'AZ|INSTANCE_TYPE|LINKED_ACCOUNT|PAYER_ACCOUNT|LINKED_ACCOUNT_NAME|OPERATION|PURCHASE_TYPE|REGION|SERVICE|SERVICE_CODE|USAGE_TYPE|USAGE_TYPE_GROUP|RECORD_TYPE|OPERATING_SYSTEM|TENANCY|SCOPE|PLATFORM|SUBSCRIPTION_ID|LEGAL_ENTITY_NAME|DEPLOYMENT_OPTION|DATABASE_ENGINE|CACHE_ENGINE|INSTANCE_TYPE_FAMILY|BILLING_ENTITY|RESERVATION_ID|RESOURCE_ID|RIGHTSIZING_TYPE|SAVINGS_PLANS_TYPE|SAVINGS_PLAN_ARN|PAYMENT_OPTION|AGREEMENT_END_DATE_TIME_AFTER|AGREEMENT_END_DATE_TIME_BEFORE|INVOICING_ENTITY|ANOMALY_TOTAL_IMPACT_ABSOLUTE|ANOMALY_TOTAL_IMPACT_PERCENTAGE',
            'MatchOptions' => ['<string>', ...],
            'Values' => ['<string>', ...],
        ],
        'Not' => [...], // RECURSIVE
        'Or' => [
            [...], // RECURSIVE
            // ...
        ],
        'Tags' => [
            'Key' => '<string>',
            'MatchOptions' => ['<string>', ...],
            'Values' => ['<string>', ...],
        ],
    ],
    'Granularity' => 'DAILY|MONTHLY|HOURLY', // REQUIRED
    'GroupBy' => [
        [
            'Key' => '<string>',
            'Type' => 'DIMENSION|TAG|COST_CATEGORY',
        ],
        // ...
    ],
    'Metrics' => ['<string>', ...],
    'NextPageToken' => '<string>',
    'TimePeriod' => [ // REQUIRED
        'End' => '<string>', // REQUIRED
        'Start' => '<string>', // REQUIRED
    ],
]);
	Parameter Details
Members
- BillingViewArn
- 
- Type: string
 The Amazon Resource Name (ARN) that uniquely identifies a specific billing view. The ARN is used to specify which particular billing view you want to interact with or retrieve information from when making API calls related to Amazon Web Services Billing and Cost Management features. The BillingViewArn can be retrieved by calling the ListBillingViews API. 
- Filter
- 
- Required: Yes
- Type: Expression structure
 Filters Amazon Web Services costs by different dimensions. For example, you can specify SERVICEandLINKED_ACCOUNTand get the costs that are associated with that account's usage of that service. You can nestExpressionobjects to define any combination of dimension filters. For more information, see Expression.Valid values for MatchOptionsforDimensionsareEQUALSandCASE_SENSITIVE.Valid values for MatchOptionsforCostCategoriesandTagsareEQUALS,ABSENT, andCASE_SENSITIVE. Default values areEQUALSandCASE_SENSITIVE.
- Granularity
- 
- Required: Yes
- Type: string
 Sets the Amazon Web Services cost granularity to MONTHLY,DAILY, orHOURLY. IfGranularityisn't set, the response object doesn't include theGranularity,MONTHLY,DAILY, orHOURLY.
- GroupBy
- 
- Type: Array of GroupDefinition structures
 You can group Amazon Web Services costs using up to two different groups: DIMENSION,TAG,COST_CATEGORY.
- Metrics
- 
- Type: Array of strings
 Which metrics are returned in the query. For more information about blended and unblended rates, see Why does the "blended" annotation appear on some line items in my bill?. Valid values are AmortizedCost,BlendedCost,NetAmortizedCost,NetUnblendedCost,NormalizedUsageAmount,UnblendedCost, andUsageQuantity.If you return the UsageQuantitymetric, the service aggregates all usage numbers without taking the units into account. For example, if you aggregateusageQuantityacross all of Amazon EC2, the results aren't meaningful because Amazon EC2 compute hours and data transfer are measured in different units (for example, hour or GB). To get more meaningfulUsageQuantitymetrics, filter byUsageTypeorUsageTypeGroups.Metricsis required forGetCostAndUsageWithResourcesrequests.
- NextPageToken
- 
- Type: string
 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. 
- TimePeriod
- 
- Required: Yes
- Type: DateInterval structure
 Sets the start and end dates for retrieving Amazon Web Services costs. The range must be within the last 14 days (the start date cannot be earlier than 14 days ago). The start date is inclusive, but the end date is exclusive. For example, if startis2017-01-01andendis2017-05-01, then the cost and usage data is retrieved from2017-01-01up to and including2017-04-30but not including2017-05-01.
Result Syntax
[
    'DimensionValueAttributes' => [
        [
            'Attributes' => ['<string>', ...],
            'Value' => '<string>',
        ],
        // ...
    ],
    'GroupDefinitions' => [
        [
            'Key' => '<string>',
            'Type' => 'DIMENSION|TAG|COST_CATEGORY',
        ],
        // ...
    ],
    'NextPageToken' => '<string>',
    'ResultsByTime' => [
        [
            'Estimated' => true || false,
            'Groups' => [
                [
                    'Keys' => ['<string>', ...],
                    'Metrics' => [
                        '<MetricName>' => [
                            'Amount' => '<string>',
                            'Unit' => '<string>',
                        ],
                        // ...
                    ],
                ],
                // ...
            ],
            'TimePeriod' => [
                'End' => '<string>',
                'Start' => '<string>',
            ],
            'Total' => [
                '<MetricName>' => [
                    'Amount' => '<string>',
                    'Unit' => '<string>',
                ],
                // ...
            ],
        ],
        // ...
    ],
]
	Result Details
Members
- DimensionValueAttributes
- 
- Type: Array of DimensionValuesWithAttributes structures
 The attributes that apply to a specific dimension value. For example, if the value is a linked account, the attribute is that account name. 
- GroupDefinitions
- 
- Type: Array of GroupDefinition structures
 The groups that are specified by the FilterorGroupByparameters in the request.
- NextPageToken
- 
- Type: string
 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. 
- ResultsByTime
- 
- Type: Array of ResultByTime structures
 The time period that's covered by the results in the response. 
Errors
- DataUnavailableException:
- The requested data is unavailable. 
- LimitExceededException:
- You made too many calls in a short period of time. Try again later. 
- BillExpirationException:
- The requested report expired. Update the date interval and try again. 
- InvalidNextTokenException:
- The pagination token is invalid. Try again without a pagination token. 
- RequestChangedException:
- Your request parameters changed between pages. Try again with the old parameters or without a pagination token. 
- ResourceNotFoundException:
- The specified ARN in the request doesn't exist. 
- BillingViewHealthStatusException:
- The billing view status must be - HEALTHYto perform this action. Try again when the status is- HEALTHY.
GetCostCategories
$result = $client->getCostCategories([/* ... */]); $promise = $client->getCostCategoriesAsync([/* ... */]);
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.
Parameter Syntax
$result = $client->getCostCategories([
    'BillingViewArn' => '<string>',
    'CostCategoryName' => '<string>',
    'Filter' => [
        'And' => [
            [...], // RECURSIVE
            // ...
        ],
        'CostCategories' => [
            'Key' => '<string>',
            'MatchOptions' => ['<string>', ...],
            'Values' => ['<string>', ...],
        ],
        'Dimensions' => [
            'Key' => 'AZ|INSTANCE_TYPE|LINKED_ACCOUNT|PAYER_ACCOUNT|LINKED_ACCOUNT_NAME|OPERATION|PURCHASE_TYPE|REGION|SERVICE|SERVICE_CODE|USAGE_TYPE|USAGE_TYPE_GROUP|RECORD_TYPE|OPERATING_SYSTEM|TENANCY|SCOPE|PLATFORM|SUBSCRIPTION_ID|LEGAL_ENTITY_NAME|DEPLOYMENT_OPTION|DATABASE_ENGINE|CACHE_ENGINE|INSTANCE_TYPE_FAMILY|BILLING_ENTITY|RESERVATION_ID|RESOURCE_ID|RIGHTSIZING_TYPE|SAVINGS_PLANS_TYPE|SAVINGS_PLAN_ARN|PAYMENT_OPTION|AGREEMENT_END_DATE_TIME_AFTER|AGREEMENT_END_DATE_TIME_BEFORE|INVOICING_ENTITY|ANOMALY_TOTAL_IMPACT_ABSOLUTE|ANOMALY_TOTAL_IMPACT_PERCENTAGE',
            'MatchOptions' => ['<string>', ...],
            'Values' => ['<string>', ...],
        ],
        'Not' => [...], // RECURSIVE
        'Or' => [
            [...], // RECURSIVE
            // ...
        ],
        'Tags' => [
            'Key' => '<string>',
            'MatchOptions' => ['<string>', ...],
            'Values' => ['<string>', ...],
        ],
    ],
    'MaxResults' => <integer>,
    'NextPageToken' => '<string>',
    'SearchString' => '<string>',
    'SortBy' => [
        [
            'Key' => '<string>', // REQUIRED
            'SortOrder' => 'ASCENDING|DESCENDING',
        ],
        // ...
    ],
    'TimePeriod' => [ // REQUIRED
        'End' => '<string>', // REQUIRED
        'Start' => '<string>', // REQUIRED
    ],
]);
	Parameter Details
Members
- BillingViewArn
- 
- Type: string
 The Amazon Resource Name (ARN) that uniquely identifies a specific billing view. The ARN is used to specify which particular billing view you want to interact with or retrieve information from when making API calls related to Amazon Web Services Billing and Cost Management features. The BillingViewArn can be retrieved by calling the ListBillingViews API. 
- CostCategoryName
- 
- Type: string
 The unique name of the Cost Category. 
- Filter
- 
- Type: Expression structure
 Use Expressionto filter in various Cost Explorer APIs.Not all Expressiontypes are supported in each API. Refer to the documentation for each specific API to see what is supported.There are two patterns: -  Simple dimension values. -  There are three types of simple dimension values: CostCategories,Tags, andDimensions.-  Specify the CostCategoriesfield to define a filter that acts on Cost Categories.
-  Specify the Tagsfield to define a filter that acts on Cost Allocation Tags.
-  Specify the Dimensionsfield to define a filter that acts on theDimensionValues.
 
-  
-  For each filter type, you can set the dimension name and values for the filters that you plan to use. -  For example, you can filter for REGION==us-east-1 OR REGION==us-west-1. ForGetRightsizingRecommendation, the Region is a full name (for example,REGION==US East (N. Virginia).
-  The corresponding Expressionfor this example is as follows:{ "Dimensions": { "Key": "REGION", "Values": [ "us-east-1", "us-west-1" ] } }
-  As shown in the previous example, lists of dimension values are combined with ORwhen applying the filter.
 
-  
-  You can also set different match options to further control how the filter behaves. Not all APIs support match options. Refer to the documentation for each specific API to see what is supported. -  For example, you can filter for linked account names that start with "a". 
-  The corresponding Expressionfor this example is as follows:{ "Dimensions": { "Key": "LINKED_ACCOUNT_NAME", "MatchOptions": [ "STARTS_WITH" ], "Values": [ "a" ] } }
 
-  
 
-  
-  Compound Expressiontypes with logical operations.-  You can use multiple Expressiontypes and the logical operatorsAND/OR/NOTto create a list of one or moreExpressionobjects. By doing this, you can filter by more advanced options.
-  For example, you can filter by ((REGION == us-east-1 OR REGION == us-west-1) OR (TAG.Type == Type1)) AND (USAGE_TYPE != DataTransfer).
-  The corresponding Expressionfor this example is as follows:{ "And": [ {"Or": [ {"Dimensions": { "Key": "REGION", "Values": [ "us-east-1", "us-west-1" ] }}, {"Tags": { "Key": "TagName", "Values": ["Value1"] } } ]}, {"Not": {"Dimensions": { "Key": "USAGE_TYPE", "Values": ["DataTransfer"] }}} ] }
 Because each Expressioncan have only one operator, the service returns an error if more than one is specified. The following example shows anExpressionobject that creates an error:{ "And": [ ... ], "Dimensions": { "Key": "USAGE_TYPE", "Values": [ "DataTransfer" ] } }The following is an example of the corresponding error message: "Expression has more than one roots. Only one root operator is allowed for each expression: And, Or, Not, Dimensions, Tags, CostCategories"
-  
 For the GetRightsizingRecommendationaction, a combination of OR and NOT isn't supported. OR isn't supported between different dimensions, or dimensions and tags. NOT operators aren't supported. Dimensions are also limited toLINKED_ACCOUNT,REGION, orRIGHTSIZING_TYPE.For the GetReservationPurchaseRecommendationaction, only NOT is supported. AND and OR aren't supported. Dimensions are limited toLINKED_ACCOUNT.
- MaxResults
- 
- Type: int
 This field is only used when the SortByvalue is provided in the request.The maximum number of objects that are returned for this request. If MaxResultsisn't specified with theSortByvalue, the request returns 1000 results as the default value for this parameter.For GetCostCategories, MaxResults has an upper quota of 1000.
- NextPageToken
- 
- Type: string
 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
- 
- Type: string
 The value that you want to search the filter values for. If you don't specify a CostCategoryName,SearchStringis used to filter Cost Category names that match theSearchStringpattern. If you specify aCostCategoryName,SearchStringis used to filter Cost Category values that match theSearchStringpattern.
- SortBy
- 
- Type: Array of SortDefinition structures
 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 SortOrdervalue areASCENDINGandDESCENDING.When you use the SortByvalue, theNextPageTokenandSearchStringkey values aren't supported.
- TimePeriod
- 
- Required: Yes
- Type: DateInterval structure
 The time period of the request. 
Result Syntax
[
    'CostCategoryNames' => ['<string>', ...],
    'CostCategoryValues' => ['<string>', ...],
    'NextPageToken' => '<string>',
    'ReturnSize' => <integer>,
    'TotalSize' => <integer>,
]
	Result Details
Members
- CostCategoryNames
- 
- Type: Array of strings
 The names of the Cost Categories. 
- CostCategoryValues
- 
- Type: Array of strings
 The Cost Category values. If the CostCategoryNamekey isn't specified in the request, theCostCategoryValuesfields aren't returned.
- NextPageToken
- 
- Type: string
 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. 
- ReturnSize
- 
- Required: Yes
- Type: int
 The number of objects that are returned. 
- TotalSize
- 
- Required: Yes
- Type: int
 The total number of objects. 
Errors
- LimitExceededException:
- You made too many calls in a short period of time. Try again later. 
- BillExpirationException:
- The requested report expired. Update the date interval and try again. 
- DataUnavailableException:
- The requested data is unavailable. 
- InvalidNextTokenException:
- The pagination token is invalid. Try again without a pagination token. 
- RequestChangedException:
- Your request parameters changed between pages. Try again with the old parameters or without a pagination token. 
- ResourceNotFoundException:
- The specified ARN in the request doesn't exist. 
- BillingViewHealthStatusException:
- The billing view status must be - HEALTHYto perform this action. Try again when the status is- HEALTHY.
GetCostComparisonDrivers
$result = $client->getCostComparisonDrivers([/* ... */]); $promise = $client->getCostComparisonDriversAsync([/* ... */]);
Retrieves key factors driving cost changes between two time periods within the last 13 months, such as usage changes, discount changes, and commitment-based savings. If you have enabled multi-year data at monthly granularity, you can go back up to 38 months.
Parameter Syntax
$result = $client->getCostComparisonDrivers([
    'BaselineTimePeriod' => [ // REQUIRED
        'End' => '<string>', // REQUIRED
        'Start' => '<string>', // REQUIRED
    ],
    'BillingViewArn' => '<string>',
    'ComparisonTimePeriod' => [ // REQUIRED
        'End' => '<string>', // REQUIRED
        'Start' => '<string>', // REQUIRED
    ],
    'Filter' => [
        'And' => [
            [...], // RECURSIVE
            // ...
        ],
        'CostCategories' => [
            'Key' => '<string>',
            'MatchOptions' => ['<string>', ...],
            'Values' => ['<string>', ...],
        ],
        'Dimensions' => [
            'Key' => 'AZ|INSTANCE_TYPE|LINKED_ACCOUNT|PAYER_ACCOUNT|LINKED_ACCOUNT_NAME|OPERATION|PURCHASE_TYPE|REGION|SERVICE|SERVICE_CODE|USAGE_TYPE|USAGE_TYPE_GROUP|RECORD_TYPE|OPERATING_SYSTEM|TENANCY|SCOPE|PLATFORM|SUBSCRIPTION_ID|LEGAL_ENTITY_NAME|DEPLOYMENT_OPTION|DATABASE_ENGINE|CACHE_ENGINE|INSTANCE_TYPE_FAMILY|BILLING_ENTITY|RESERVATION_ID|RESOURCE_ID|RIGHTSIZING_TYPE|SAVINGS_PLANS_TYPE|SAVINGS_PLAN_ARN|PAYMENT_OPTION|AGREEMENT_END_DATE_TIME_AFTER|AGREEMENT_END_DATE_TIME_BEFORE|INVOICING_ENTITY|ANOMALY_TOTAL_IMPACT_ABSOLUTE|ANOMALY_TOTAL_IMPACT_PERCENTAGE',
            'MatchOptions' => ['<string>', ...],
            'Values' => ['<string>', ...],
        ],
        'Not' => [...], // RECURSIVE
        'Or' => [
            [...], // RECURSIVE
            // ...
        ],
        'Tags' => [
            'Key' => '<string>',
            'MatchOptions' => ['<string>', ...],
            'Values' => ['<string>', ...],
        ],
    ],
    'GroupBy' => [
        [
            'Key' => '<string>',
            'Type' => 'DIMENSION|TAG|COST_CATEGORY',
        ],
        // ...
    ],
    'MaxResults' => <integer>,
    'MetricForComparison' => '<string>', // REQUIRED
    'NextPageToken' => '<string>',
]);
	Parameter Details
Members
- BaselineTimePeriod
- 
- Required: Yes
- Type: DateInterval structure
 The reference time period for comparison. This time period serves as the baseline against which other cost and usage data will be compared. The interval must start and end on the first day of a month, with a duration of exactly one month. 
- BillingViewArn
- 
- Type: string
 The Amazon Resource Name (ARN) that uniquely identifies a specific billing view. The ARN is used to specify which particular billing view you want to interact with or retrieve information from when making API calls related to Amazon Web Services Billing and Cost Management features. The BillingViewArn can be retrieved by calling the ListBillingViews API. 
- ComparisonTimePeriod
- 
- Required: Yes
- Type: DateInterval structure
 The comparison time period for analysis. This time period's cost and usage data will be compared against the baseline time period. The interval must start and end on the first day of a month, with a duration of exactly one month. 
- Filter
- 
- Type: Expression structure
 Use Expressionto filter in various Cost Explorer APIs.Not all Expressiontypes are supported in each API. Refer to the documentation for each specific API to see what is supported.There are two patterns: -  Simple dimension values. -  There are three types of simple dimension values: CostCategories,Tags, andDimensions.-  Specify the CostCategoriesfield to define a filter that acts on Cost Categories.
-  Specify the Tagsfield to define a filter that acts on Cost Allocation Tags.
-  Specify the Dimensionsfield to define a filter that acts on theDimensionValues.
 
-  
-  For each filter type, you can set the dimension name and values for the filters that you plan to use. -  For example, you can filter for REGION==us-east-1 OR REGION==us-west-1. ForGetRightsizingRecommendation, the Region is a full name (for example,REGION==US East (N. Virginia).
-  The corresponding Expressionfor this example is as follows:{ "Dimensions": { "Key": "REGION", "Values": [ "us-east-1", "us-west-1" ] } }
-  As shown in the previous example, lists of dimension values are combined with ORwhen applying the filter.
 
-  
-  You can also set different match options to further control how the filter behaves. Not all APIs support match options. Refer to the documentation for each specific API to see what is supported. -  For example, you can filter for linked account names that start with "a". 
-  The corresponding Expressionfor this example is as follows:{ "Dimensions": { "Key": "LINKED_ACCOUNT_NAME", "MatchOptions": [ "STARTS_WITH" ], "Values": [ "a" ] } }
 
-  
 
-  
-  Compound Expressiontypes with logical operations.-  You can use multiple Expressiontypes and the logical operatorsAND/OR/NOTto create a list of one or moreExpressionobjects. By doing this, you can filter by more advanced options.
-  For example, you can filter by ((REGION == us-east-1 OR REGION == us-west-1) OR (TAG.Type == Type1)) AND (USAGE_TYPE != DataTransfer).
-  The corresponding Expressionfor this example is as follows:{ "And": [ {"Or": [ {"Dimensions": { "Key": "REGION", "Values": [ "us-east-1", "us-west-1" ] }}, {"Tags": { "Key": "TagName", "Values": ["Value1"] } } ]}, {"Not": {"Dimensions": { "Key": "USAGE_TYPE", "Values": ["DataTransfer"] }}} ] }
 Because each Expressioncan have only one operator, the service returns an error if more than one is specified. The following example shows anExpressionobject that creates an error:{ "And": [ ... ], "Dimensions": { "Key": "USAGE_TYPE", "Values": [ "DataTransfer" ] } }The following is an example of the corresponding error message: "Expression has more than one roots. Only one root operator is allowed for each expression: And, Or, Not, Dimensions, Tags, CostCategories"
-  
 For the GetRightsizingRecommendationaction, a combination of OR and NOT isn't supported. OR isn't supported between different dimensions, or dimensions and tags. NOT operators aren't supported. Dimensions are also limited toLINKED_ACCOUNT,REGION, orRIGHTSIZING_TYPE.For the GetReservationPurchaseRecommendationaction, only NOT is supported. AND and OR aren't supported. Dimensions are limited toLINKED_ACCOUNT.
- GroupBy
- 
- Type: Array of GroupDefinition structures
 You can group results using the attributes DIMENSION,TAG, andCOST_CATEGORY. Note thatSERVICEandUSAGE_TYPEdimensions are automatically included in the cost comparison drivers analysis.
- MaxResults
- 
- Type: int
 The maximum number of results that are returned for the request. 
- MetricForComparison
- 
- Required: Yes
- Type: string
 The cost and usage metric to compare. Valid values are AmortizedCost,BlendedCost,NetAmortizedCost,NetUnblendedCost,NormalizedUsageAmount,UnblendedCost, andUsageQuantity.
- NextPageToken
- 
- Type: string
 The token to retrieve the next set of paginated results. 
Result Syntax
[
    'CostComparisonDrivers' => [
        [
            'CostDrivers' => [
                [
                    'Metrics' => [
                        '<MetricName>' => [
                            'BaselineTimePeriodAmount' => '<string>',
                            'ComparisonTimePeriodAmount' => '<string>',
                            'Difference' => '<string>',
                            'Unit' => '<string>',
                        ],
                        // ...
                    ],
                    'Name' => '<string>',
                    'Type' => '<string>',
                ],
                // ...
            ],
            'CostSelector' => [
                'And' => [
                    [...], // RECURSIVE
                    // ...
                ],
                'CostCategories' => [
                    'Key' => '<string>',
                    'MatchOptions' => ['<string>', ...],
                    'Values' => ['<string>', ...],
                ],
                'Dimensions' => [
                    'Key' => 'AZ|INSTANCE_TYPE|LINKED_ACCOUNT|PAYER_ACCOUNT|LINKED_ACCOUNT_NAME|OPERATION|PURCHASE_TYPE|REGION|SERVICE|SERVICE_CODE|USAGE_TYPE|USAGE_TYPE_GROUP|RECORD_TYPE|OPERATING_SYSTEM|TENANCY|SCOPE|PLATFORM|SUBSCRIPTION_ID|LEGAL_ENTITY_NAME|DEPLOYMENT_OPTION|DATABASE_ENGINE|CACHE_ENGINE|INSTANCE_TYPE_FAMILY|BILLING_ENTITY|RESERVATION_ID|RESOURCE_ID|RIGHTSIZING_TYPE|SAVINGS_PLANS_TYPE|SAVINGS_PLAN_ARN|PAYMENT_OPTION|AGREEMENT_END_DATE_TIME_AFTER|AGREEMENT_END_DATE_TIME_BEFORE|INVOICING_ENTITY|ANOMALY_TOTAL_IMPACT_ABSOLUTE|ANOMALY_TOTAL_IMPACT_PERCENTAGE',
                    'MatchOptions' => ['<string>', ...],
                    'Values' => ['<string>', ...],
                ],
                'Not' => [...], // RECURSIVE
                'Or' => [
                    [...], // RECURSIVE
                    // ...
                ],
                'Tags' => [
                    'Key' => '<string>',
                    'MatchOptions' => ['<string>', ...],
                    'Values' => ['<string>', ...],
                ],
            ],
            'Metrics' => [
                '<MetricName>' => [
                    'BaselineTimePeriodAmount' => '<string>',
                    'ComparisonTimePeriodAmount' => '<string>',
                    'Difference' => '<string>',
                    'Unit' => '<string>',
                ],
                // ...
            ],
        ],
        // ...
    ],
    'NextPageToken' => '<string>',
]
	Result Details
Members
- CostComparisonDrivers
- 
- Type: Array of CostComparisonDriver structures
 An array of comparison results showing factors that drive significant cost differences between BaselineTimePeriodandComparisonTimePeriod.
- NextPageToken
- 
- Type: string
 The token to retrieve the next set of paginated results. 
Errors
- DataUnavailableException:
- The requested data is unavailable. 
- InvalidNextTokenException:
- The pagination token is invalid. Try again without a pagination token. 
- LimitExceededException:
- You made too many calls in a short period of time. Try again later. 
- ResourceNotFoundException:
- The specified ARN in the request doesn't exist. 
- BillingViewHealthStatusException:
- The billing view status must be - HEALTHYto perform this action. Try again when the status is- HEALTHY.
GetCostForecast
$result = $client->getCostForecast([/* ... */]); $promise = $client->getCostForecastAsync([/* ... */]);
Retrieves a forecast for how much Amazon Web Services predicts that you will spend over the forecast time period that you select, based on your past costs.
Parameter Syntax
$result = $client->getCostForecast([
    'BillingViewArn' => '<string>',
    'Filter' => [
        'And' => [
            [...], // RECURSIVE
            // ...
        ],
        'CostCategories' => [
            'Key' => '<string>',
            'MatchOptions' => ['<string>', ...],
            'Values' => ['<string>', ...],
        ],
        'Dimensions' => [
            'Key' => 'AZ|INSTANCE_TYPE|LINKED_ACCOUNT|PAYER_ACCOUNT|LINKED_ACCOUNT_NAME|OPERATION|PURCHASE_TYPE|REGION|SERVICE|SERVICE_CODE|USAGE_TYPE|USAGE_TYPE_GROUP|RECORD_TYPE|OPERATING_SYSTEM|TENANCY|SCOPE|PLATFORM|SUBSCRIPTION_ID|LEGAL_ENTITY_NAME|DEPLOYMENT_OPTION|DATABASE_ENGINE|CACHE_ENGINE|INSTANCE_TYPE_FAMILY|BILLING_ENTITY|RESERVATION_ID|RESOURCE_ID|RIGHTSIZING_TYPE|SAVINGS_PLANS_TYPE|SAVINGS_PLAN_ARN|PAYMENT_OPTION|AGREEMENT_END_DATE_TIME_AFTER|AGREEMENT_END_DATE_TIME_BEFORE|INVOICING_ENTITY|ANOMALY_TOTAL_IMPACT_ABSOLUTE|ANOMALY_TOTAL_IMPACT_PERCENTAGE',
            'MatchOptions' => ['<string>', ...],
            'Values' => ['<string>', ...],
        ],
        'Not' => [...], // RECURSIVE
        'Or' => [
            [...], // RECURSIVE
            // ...
        ],
        'Tags' => [
            'Key' => '<string>',
            'MatchOptions' => ['<string>', ...],
            'Values' => ['<string>', ...],
        ],
    ],
    'Granularity' => 'DAILY|MONTHLY|HOURLY', // REQUIRED
    'Metric' => 'BLENDED_COST|UNBLENDED_COST|AMORTIZED_COST|NET_UNBLENDED_COST|NET_AMORTIZED_COST|USAGE_QUANTITY|NORMALIZED_USAGE_AMOUNT', // REQUIRED
    'PredictionIntervalLevel' => <integer>,
    'TimePeriod' => [ // REQUIRED
        'End' => '<string>', // REQUIRED
        'Start' => '<string>', // REQUIRED
    ],
]);
	Parameter Details
Members
- BillingViewArn
- 
- Type: string
 The Amazon Resource Name (ARN) that uniquely identifies a specific billing view. The ARN is used to specify which particular billing view you want to interact with or retrieve information from when making API calls related to Amazon Web Services Billing and Cost Management features. The BillingViewArn can be retrieved by calling the ListBillingViews API. 
- Filter
- 
- Type: Expression structure
 The filters that you want to use to filter your forecast. The GetCostForecastAPI supports filtering by the following dimensions:-  AZ
-  INSTANCE_TYPE
-  LINKED_ACCOUNT
-  OPERATION
-  PURCHASE_TYPE
-  REGION
-  SERVICE
-  USAGE_TYPE
-  USAGE_TYPE_GROUP
-  RECORD_TYPE
-  OPERATING_SYSTEM
-  TENANCY
-  SCOPE
-  PLATFORM
-  SUBSCRIPTION_ID
-  LEGAL_ENTITY_NAME
-  DEPLOYMENT_OPTION
-  DATABASE_ENGINE
-  INSTANCE_TYPE_FAMILY
-  BILLING_ENTITY
-  RESERVATION_ID
-  SAVINGS_PLAN_ARN
 
- Granularity
- 
- Required: Yes
- Type: string
 How granular you want the forecast to be. You can get 3 months of DAILYforecasts or 12 months ofMONTHLYforecasts.The GetCostForecastoperation supports onlyDAILYandMONTHLYgranularities.
- Metric
- 
- Required: Yes
- Type: string
 Which metric Cost Explorer uses to create your forecast. For more information about blended and unblended rates, see Why does the "blended" annotation appear on some line items in my bill?. Valid values for a GetCostForecastcall are the following:-  AMORTIZED_COST 
-  BLENDED_COST 
-  NET_AMORTIZED_COST 
-  NET_UNBLENDED_COST 
-  UNBLENDED_COST 
 
- PredictionIntervalLevel
- 
- Type: int
 Cost Explorer always returns the mean forecast as a single point. You can request a prediction interval around the mean by specifying a confidence level. The higher the confidence level, the more confident Cost Explorer is about the actual value falling in the prediction interval. Higher confidence levels result in wider prediction intervals. 
- TimePeriod
- 
- Required: Yes
- Type: DateInterval structure
 The period of time that you want the forecast to cover. The start date must be equal to or no later than the current date to avoid a validation error. 
Result Syntax
[
    'ForecastResultsByTime' => [
        [
            'MeanValue' => '<string>',
            'PredictionIntervalLowerBound' => '<string>',
            'PredictionIntervalUpperBound' => '<string>',
            'TimePeriod' => [
                'End' => '<string>',
                'Start' => '<string>',
            ],
        ],
        // ...
    ],
    'Total' => [
        'Amount' => '<string>',
        'Unit' => '<string>',
    ],
]
	Result Details
Members
- ForecastResultsByTime
- 
- Type: Array of ForecastResult structures
 The forecasts for your query, in order. For DAILYforecasts, this is a list of days. ForMONTHLYforecasts, this is a list of months.
- Total
- 
- Type: MetricValue structure
 How much you are forecasted to spend over the forecast period, in USD.
Errors
- LimitExceededException:
- You made too many calls in a short period of time. Try again later. 
- DataUnavailableException:
- The requested data is unavailable. 
- ResourceNotFoundException:
- The specified ARN in the request doesn't exist. 
- BillingViewHealthStatusException:
- The billing view status must be - HEALTHYto perform this action. Try again when the status is- HEALTHY.
GetDimensionValues
$result = $client->getDimensionValues([/* ... */]); $promise = $client->getDimensionValuesAsync([/* ... */]);
Retrieves all available filter values for a specified filter over a period of time. You can search the dimension values for an arbitrary string.
Parameter Syntax
$result = $client->getDimensionValues([
    'BillingViewArn' => '<string>',
    'Context' => 'COST_AND_USAGE|RESERVATIONS|SAVINGS_PLANS',
    'Dimension' => 'AZ|INSTANCE_TYPE|LINKED_ACCOUNT|PAYER_ACCOUNT|LINKED_ACCOUNT_NAME|OPERATION|PURCHASE_TYPE|REGION|SERVICE|SERVICE_CODE|USAGE_TYPE|USAGE_TYPE_GROUP|RECORD_TYPE|OPERATING_SYSTEM|TENANCY|SCOPE|PLATFORM|SUBSCRIPTION_ID|LEGAL_ENTITY_NAME|DEPLOYMENT_OPTION|DATABASE_ENGINE|CACHE_ENGINE|INSTANCE_TYPE_FAMILY|BILLING_ENTITY|RESERVATION_ID|RESOURCE_ID|RIGHTSIZING_TYPE|SAVINGS_PLANS_TYPE|SAVINGS_PLAN_ARN|PAYMENT_OPTION|AGREEMENT_END_DATE_TIME_AFTER|AGREEMENT_END_DATE_TIME_BEFORE|INVOICING_ENTITY|ANOMALY_TOTAL_IMPACT_ABSOLUTE|ANOMALY_TOTAL_IMPACT_PERCENTAGE', // REQUIRED
    'Filter' => [
        'And' => [
            [...], // RECURSIVE
            // ...
        ],
        'CostCategories' => [
            'Key' => '<string>',
            'MatchOptions' => ['<string>', ...],
            'Values' => ['<string>', ...],
        ],
        'Dimensions' => [
            'Key' => 'AZ|INSTANCE_TYPE|LINKED_ACCOUNT|PAYER_ACCOUNT|LINKED_ACCOUNT_NAME|OPERATION|PURCHASE_TYPE|REGION|SERVICE|SERVICE_CODE|USAGE_TYPE|USAGE_TYPE_GROUP|RECORD_TYPE|OPERATING_SYSTEM|TENANCY|SCOPE|PLATFORM|SUBSCRIPTION_ID|LEGAL_ENTITY_NAME|DEPLOYMENT_OPTION|DATABASE_ENGINE|CACHE_ENGINE|INSTANCE_TYPE_FAMILY|BILLING_ENTITY|RESERVATION_ID|RESOURCE_ID|RIGHTSIZING_TYPE|SAVINGS_PLANS_TYPE|SAVINGS_PLAN_ARN|PAYMENT_OPTION|AGREEMENT_END_DATE_TIME_AFTER|AGREEMENT_END_DATE_TIME_BEFORE|INVOICING_ENTITY|ANOMALY_TOTAL_IMPACT_ABSOLUTE|ANOMALY_TOTAL_IMPACT_PERCENTAGE',
            'MatchOptions' => ['<string>', ...],
            'Values' => ['<string>', ...],
        ],
        'Not' => [...], // RECURSIVE
        'Or' => [
            [...], // RECURSIVE
            // ...
        ],
        'Tags' => [
            'Key' => '<string>',
            'MatchOptions' => ['<string>', ...],
            'Values' => ['<string>', ...],
        ],
    ],
    'MaxResults' => <integer>,
    'NextPageToken' => '<string>',
    'SearchString' => '<string>',
    'SortBy' => [
        [
            'Key' => '<string>', // REQUIRED
            'SortOrder' => 'ASCENDING|DESCENDING',
        ],
        // ...
    ],
    'TimePeriod' => [ // REQUIRED
        'End' => '<string>', // REQUIRED
        'Start' => '<string>', // REQUIRED
    ],
]);
	Parameter Details
Members
- BillingViewArn
- 
- Type: string
 The Amazon Resource Name (ARN) that uniquely identifies a specific billing view. The ARN is used to specify which particular billing view you want to interact with or retrieve information from when making API calls related to Amazon Web Services Billing and Cost Management features. The BillingViewArn can be retrieved by calling the ListBillingViews API. 
- Context
- 
- Type: string
 The context for the call to GetDimensionValues. This can beRESERVATIONSorCOST_AND_USAGE. The default value isCOST_AND_USAGE. If the context is set toRESERVATIONS, the resulting dimension values can be used in theGetReservationUtilizationoperation. If the context is set toCOST_AND_USAGE, the resulting dimension values can be used in theGetCostAndUsageoperation.If you set the context to COST_AND_USAGE, you can use the following dimensions for searching:-  AZ - The Availability Zone. An example is us-east-1a.
-  BILLING_ENTITY - The Amazon Web Services seller that your account is with. Possible values are the following: - Amazon Web Services(Amazon Web Services): The entity that sells Amazon Web Services services. - AISPL (Amazon Internet Services Pvt. Ltd.): The local Indian entity that's an acting reseller for Amazon Web Services services in India. - Amazon Web Services Marketplace: The entity that supports the sale of solutions that are built on Amazon Web Services by third-party software providers. 
-  CACHE_ENGINE - The Amazon ElastiCache operating system. Examples are Windows or Linux. 
-  DEPLOYMENT_OPTION - The scope of Amazon Relational Database Service deployments. Valid values are SingleAZandMultiAZ.
-  DATABASE_ENGINE - The Amazon Relational Database Service database. Examples are Aurora or MySQL. 
-  INSTANCE_TYPE - The type of Amazon EC2 instance. An example is m4.xlarge.
-  INSTANCE_TYPE_FAMILY - A family of instance types optimized to fit different use cases. Examples are Compute Optimized(for example,C4,C5,C6g, andC7g),Memory Optimization(for example,R4,R5n,R5b, andR6g).
-  INVOICING_ENTITY - The name of the entity that issues the Amazon Web Services invoice. 
-  LEGAL_ENTITY_NAME - The name of the organization that sells you Amazon Web Services services, such as Amazon Web Services. 
-  LINKED_ACCOUNT - The description in the attribute map that includes the full name of the member account. The value field contains the Amazon Web Services ID of the member account. 
-  OPERATING_SYSTEM - The operating system. Examples are Windows or Linux. 
-  OPERATION - The action performed. Examples include RunInstanceandCreateBucket.
-  PLATFORM - The Amazon EC2 operating system. Examples are Windows or Linux. 
-  PURCHASE_TYPE - The reservation type of the purchase that this usage is related to. Examples include On-Demand Instances and Standard Reserved Instances. 
-  RESERVATION_ID - The unique identifier for an Amazon Web Services Reservation Instance. 
-  SAVINGS_PLAN_ARN - The unique identifier for your Savings Plans. 
-  SAVINGS_PLANS_TYPE - Type of Savings Plans (EC2 Instance or Compute). 
-  SERVICE - The Amazon Web Services service such as Amazon DynamoDB. 
-  TENANCY - The tenancy of a resource. Examples are shared or dedicated. 
-  USAGE_TYPE - The type of usage. An example is DataTransfer-In-Bytes. The response for the GetDimensionValuesoperation includes a unit attribute. Examples include GB and Hrs.
-  USAGE_TYPE_GROUP - The grouping of common usage types. An example is Amazon EC2: CloudWatch – Alarms. The response for this operation includes a unit attribute. 
-  REGION - The Amazon Web Services Region. 
-  RECORD_TYPE - The different types of charges such as Reserved Instance (RI) fees, usage costs, tax refunds, and credits. 
-  RESOURCE_ID - The unique identifier of the resource. ResourceId is an opt-in feature only available for last 14 days for EC2-Compute Service. 
 If you set the context to RESERVATIONS, you can use the following dimensions for searching:-  AZ - The Availability Zone. An example is us-east-1a.
-  CACHE_ENGINE - The Amazon ElastiCache operating system. Examples are Windows or Linux. 
-  DEPLOYMENT_OPTION - The scope of Amazon Relational Database Service deployments. Valid values are SingleAZandMultiAZ.
-  INSTANCE_TYPE - The type of Amazon EC2 instance. An example is m4.xlarge.
-  LINKED_ACCOUNT - The description in the attribute map that includes the full name of the member account. The value field contains the Amazon Web Services ID of the member account. 
-  PLATFORM - The Amazon EC2 operating system. Examples are Windows or Linux. 
-  REGION - The Amazon Web Services Region. 
-  SCOPE (Utilization only) - The scope of a Reserved Instance (RI). Values are regional or a single Availability Zone. 
-  TAG (Coverage only) - The tags that are associated with a Reserved Instance (RI). 
-  TENANCY - The tenancy of a resource. Examples are shared or dedicated. 
 If you set the context to SAVINGS_PLANS, you can use the following dimensions for searching:-  SAVINGS_PLANS_TYPE - Type of Savings Plans (EC2 Instance or Compute) 
-  PAYMENT_OPTION - The payment option for the given Savings Plans (for example, All Upfront) 
-  REGION - The Amazon Web Services Region. 
-  INSTANCE_TYPE_FAMILY - The family of instances (For example, m5)
-  LINKED_ACCOUNT - The description in the attribute map that includes the full name of the member account. The value field contains the Amazon Web Services ID of the member account. 
-  SAVINGS_PLAN_ARN - The unique identifier for your Savings Plans. 
 
- Dimension
- 
- Required: Yes
- Type: string
 The name of the dimension. Each Dimensionis available for a differentContext. For more information, seeContext.LINK_ACCOUNT_NAMEandSERVICE_CODEcan only be used in CostCategoryRule.
- Filter
- 
- Type: Expression structure
 Use Expressionto filter in various Cost Explorer APIs.Not all Expressiontypes are supported in each API. Refer to the documentation for each specific API to see what is supported.There are two patterns: -  Simple dimension values. -  There are three types of simple dimension values: CostCategories,Tags, andDimensions.-  Specify the CostCategoriesfield to define a filter that acts on Cost Categories.
-  Specify the Tagsfield to define a filter that acts on Cost Allocation Tags.
-  Specify the Dimensionsfield to define a filter that acts on theDimensionValues.
 
-  
-  For each filter type, you can set the dimension name and values for the filters that you plan to use. -  For example, you can filter for REGION==us-east-1 OR REGION==us-west-1. ForGetRightsizingRecommendation, the Region is a full name (for example,REGION==US East (N. Virginia).
-  The corresponding Expressionfor this example is as follows:{ "Dimensions": { "Key": "REGION", "Values": [ "us-east-1", "us-west-1" ] } }
-  As shown in the previous example, lists of dimension values are combined with ORwhen applying the filter.
 
-  
-  You can also set different match options to further control how the filter behaves. Not all APIs support match options. Refer to the documentation for each specific API to see what is supported. -  For example, you can filter for linked account names that start with "a". 
-  The corresponding Expressionfor this example is as follows:{ "Dimensions": { "Key": "LINKED_ACCOUNT_NAME", "MatchOptions": [ "STARTS_WITH" ], "Values": [ "a" ] } }
 
-  
 
-  
-  Compound Expressiontypes with logical operations.-  You can use multiple Expressiontypes and the logical operatorsAND/OR/NOTto create a list of one or moreExpressionobjects. By doing this, you can filter by more advanced options.
-  For example, you can filter by ((REGION == us-east-1 OR REGION == us-west-1) OR (TAG.Type == Type1)) AND (USAGE_TYPE != DataTransfer).
-  The corresponding Expressionfor this example is as follows:{ "And": [ {"Or": [ {"Dimensions": { "Key": "REGION", "Values": [ "us-east-1", "us-west-1" ] }}, {"Tags": { "Key": "TagName", "Values": ["Value1"] } } ]}, {"Not": {"Dimensions": { "Key": "USAGE_TYPE", "Values": ["DataTransfer"] }}} ] }
 Because each Expressioncan have only one operator, the service returns an error if more than one is specified. The following example shows anExpressionobject that creates an error:{ "And": [ ... ], "Dimensions": { "Key": "USAGE_TYPE", "Values": [ "DataTransfer" ] } }The following is an example of the corresponding error message: "Expression has more than one roots. Only one root operator is allowed for each expression: And, Or, Not, Dimensions, Tags, CostCategories"
-  
 For the GetRightsizingRecommendationaction, a combination of OR and NOT isn't supported. OR isn't supported between different dimensions, or dimensions and tags. NOT operators aren't supported. Dimensions are also limited toLINKED_ACCOUNT,REGION, orRIGHTSIZING_TYPE.For the GetReservationPurchaseRecommendationaction, only NOT is supported. AND and OR aren't supported. Dimensions are limited toLINKED_ACCOUNT.
- MaxResults
- 
- Type: int
 This field is only used when SortBy is provided in the request. The maximum number of objects that are returned for this request. If MaxResults isn't specified with SortBy, the request returns 1000 results as the default value for this parameter. For GetDimensionValues, MaxResults has an upper limit of 1000.
- NextPageToken
- 
- Type: string
 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. 
- SearchString
- 
- Type: string
 The value that you want to search the filter values for. 
- SortBy
- 
- Type: Array of SortDefinition structures
 The value that you want to sort the data by. The key represents cost and usage metrics. The following values are supported: -  BlendedCost
-  UnblendedCost
-  AmortizedCost
-  NetAmortizedCost
-  NetUnblendedCost
-  UsageQuantity
-  NormalizedUsageAmount
 The supported values for the SortOrderkey areASCENDINGorDESCENDING.When you specify a SortByparamater, the context must beCOST_AND_USAGE. Further, when usingSortBy,NextPageTokenandSearchStringaren't supported.
- TimePeriod
- 
- Required: Yes
- Type: DateInterval structure
 The start date and end date for retrieving the dimension values. The start date is inclusive, but the end date is exclusive. For example, if startis2017-01-01andendis2017-05-01, then the cost and usage data is retrieved from2017-01-01up to and including2017-04-30but not including2017-05-01.
Result Syntax
[
    'DimensionValues' => [
        [
            'Attributes' => ['<string>', ...],
            'Value' => '<string>',
        ],
        // ...
    ],
    'NextPageToken' => '<string>',
    'ReturnSize' => <integer>,
    'TotalSize' => <integer>,
]
	Result Details
Members
- DimensionValues
- 
- Required: Yes
- Type: Array of DimensionValuesWithAttributes structures
 The filters that you used to filter your request. Some dimensions are available only for a specific context. If you set the context to COST_AND_USAGE, you can use the following dimensions for searching:-  AZ - The Availability Zone. An example is us-east-1a.
-  DATABASE_ENGINE - The Amazon Relational Database Service database. Examples are Aurora or MySQL. 
-  INSTANCE_TYPE - The type of Amazon EC2 instance. An example is m4.xlarge.
-  LEGAL_ENTITY_NAME - The name of the organization that sells you Amazon Web Services services, such as Amazon Web Services. 
-  LINKED_ACCOUNT - The description in the attribute map that includes the full name of the member account. The value field contains the Amazon Web Services ID of the member account. 
-  OPERATING_SYSTEM - The operating system. Examples are Windows or Linux. 
-  OPERATION - The action performed. Examples include RunInstanceandCreateBucket.
-  PLATFORM - The Amazon EC2 operating system. Examples are Windows or Linux. 
-  PURCHASE_TYPE - The reservation type of the purchase to which this usage is related. Examples include On-Demand Instances and Standard Reserved Instances. 
-  SERVICE - The Amazon Web Services service such as Amazon DynamoDB. 
-  USAGE_TYPE - The type of usage. An example is DataTransfer-In-Bytes. The response for the GetDimensionValuesoperation includes a unit attribute. Examples include GB and Hrs.
-  USAGE_TYPE_GROUP - The grouping of common usage types. An example is Amazon EC2: CloudWatch – Alarms. The response for this operation includes a unit attribute. 
-  RECORD_TYPE - The different types of charges such as RI fees, usage costs, tax refunds, and credits. 
-  RESOURCE_ID - The unique identifier of the resource. ResourceId is an opt-in feature only available for last 14 days for EC2-Compute Service. You can opt-in by enabling HourlyandResource Level Datain Cost Management Console preferences.
 If you set the context to RESERVATIONS, you can use the following dimensions for searching:-  AZ - The Availability Zone. An example is us-east-1a.
-  CACHE_ENGINE - The Amazon ElastiCache operating system. Examples are Windows or Linux. 
-  DEPLOYMENT_OPTION - The scope of Amazon Relational Database Service deployments. Valid values are SingleAZandMultiAZ.
-  INSTANCE_TYPE - The type of Amazon EC2 instance. An example is m4.xlarge.
-  LINKED_ACCOUNT - The description in the attribute map that includes the full name of the member account. The value field contains the Amazon Web Services ID of the member account. 
-  PLATFORM - The Amazon EC2 operating system. Examples are Windows or Linux. 
-  REGION - The Amazon Web Services Region. 
-  SCOPE (Utilization only) - The scope of a Reserved Instance (RI). Values are regional or a single Availability Zone. 
-  TAG (Coverage only) - The tags that are associated with a Reserved Instance (RI). 
-  TENANCY - The tenancy of a resource. Examples are shared or dedicated. 
 If you set the context to SAVINGS_PLANS, you can use the following dimensions for searching:-  SAVINGS_PLANS_TYPE - Type of Savings Plans (EC2 Instance or Compute) 
-  PAYMENT_OPTION - Payment option for the given Savings Plans (for example, All Upfront) 
-  REGION - The Amazon Web Services Region. 
-  INSTANCE_TYPE_FAMILY - The family of instances (For example, m5)
-  LINKED_ACCOUNT - The description in the attribute map that includes the full name of the member account. The value field contains the Amazon Web Services ID of the member account. 
-  SAVINGS_PLAN_ARN - The unique identifier for your Savings Plan 
 
- NextPageToken
- 
- Type: string
 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. 
- ReturnSize
- 
- Required: Yes
- Type: int
 The number of results that Amazon Web Services returned at one time. 
- TotalSize
- 
- Required: Yes
- Type: int
 The total number of search results. 
Errors
- LimitExceededException:
- You made too many calls in a short period of time. Try again later. 
- BillExpirationException:
- The requested report expired. Update the date interval and try again. 
- DataUnavailableException:
- The requested data is unavailable. 
- InvalidNextTokenException:
- The pagination token is invalid. Try again without a pagination token. 
- RequestChangedException:
- Your request parameters changed between pages. Try again with the old parameters or without a pagination token. 
- ResourceNotFoundException:
- The specified ARN in the request doesn't exist. 
- BillingViewHealthStatusException:
- The billing view status must be - HEALTHYto perform this action. Try again when the status is- HEALTHY.
GetReservationCoverage
$result = $client->getReservationCoverage([/* ... */]); $promise = $client->getReservationCoverageAsync([/* ... */]);
Retrieves the reservation coverage for your account, which you can use to see how much of your Amazon Elastic Compute Cloud, Amazon ElastiCache, Amazon Relational Database Service, or Amazon Redshift usage is covered by a reservation. An organization's management account can see the coverage of the associated member accounts. This supports dimensions, Cost Categories, and nested expressions. For any time period, you can filter data about reservation usage by the following dimensions:
-  AZ 
-  CACHE_ENGINE 
-  DATABASE_ENGINE 
-  DEPLOYMENT_OPTION 
-  INSTANCE_TYPE 
-  LINKED_ACCOUNT 
-  OPERATING_SYSTEM 
-  PLATFORM 
-  REGION 
-  SERVICE 
-  TAG 
-  TENANCY 
To determine valid values for a dimension, use the GetDimensionValues operation. 
Parameter Syntax
$result = $client->getReservationCoverage([
    'Filter' => [
        'And' => [
            [...], // RECURSIVE
            // ...
        ],
        'CostCategories' => [
            'Key' => '<string>',
            'MatchOptions' => ['<string>', ...],
            'Values' => ['<string>', ...],
        ],
        'Dimensions' => [
            'Key' => 'AZ|INSTANCE_TYPE|LINKED_ACCOUNT|PAYER_ACCOUNT|LINKED_ACCOUNT_NAME|OPERATION|PURCHASE_TYPE|REGION|SERVICE|SERVICE_CODE|USAGE_TYPE|USAGE_TYPE_GROUP|RECORD_TYPE|OPERATING_SYSTEM|TENANCY|SCOPE|PLATFORM|SUBSCRIPTION_ID|LEGAL_ENTITY_NAME|DEPLOYMENT_OPTION|DATABASE_ENGINE|CACHE_ENGINE|INSTANCE_TYPE_FAMILY|BILLING_ENTITY|RESERVATION_ID|RESOURCE_ID|RIGHTSIZING_TYPE|SAVINGS_PLANS_TYPE|SAVINGS_PLAN_ARN|PAYMENT_OPTION|AGREEMENT_END_DATE_TIME_AFTER|AGREEMENT_END_DATE_TIME_BEFORE|INVOICING_ENTITY|ANOMALY_TOTAL_IMPACT_ABSOLUTE|ANOMALY_TOTAL_IMPACT_PERCENTAGE',
            'MatchOptions' => ['<string>', ...],
            'Values' => ['<string>', ...],
        ],
        'Not' => [...], // RECURSIVE
        'Or' => [
            [...], // RECURSIVE
            // ...
        ],
        'Tags' => [
            'Key' => '<string>',
            'MatchOptions' => ['<string>', ...],
            'Values' => ['<string>', ...],
        ],
    ],
    'Granularity' => 'DAILY|MONTHLY|HOURLY',
    'GroupBy' => [
        [
            'Key' => '<string>',
            'Type' => 'DIMENSION|TAG|COST_CATEGORY',
        ],
        // ...
    ],
    'MaxResults' => <integer>,
    'Metrics' => ['<string>', ...],
    'NextPageToken' => '<string>',
    'SortBy' => [
        'Key' => '<string>', // REQUIRED
        'SortOrder' => 'ASCENDING|DESCENDING',
    ],
    'TimePeriod' => [ // REQUIRED
        'End' => '<string>', // REQUIRED
        'Start' => '<string>', // REQUIRED
    ],
]);
	Parameter Details
Members
- Filter
- 
- Type: Expression structure
 Filters utilization data by dimensions. You can filter by the following dimensions: -  AZ 
-  CACHE_ENGINE 
-  DATABASE_ENGINE 
-  DEPLOYMENT_OPTION 
-  INSTANCE_TYPE 
-  LINKED_ACCOUNT 
-  OPERATING_SYSTEM 
-  PLATFORM 
-  REGION 
-  SERVICE 
-  TAG 
-  TENANCY 
 GetReservationCoverageuses the same Expression object as the other operations, but onlyANDis supported among each dimension. You can nest only one level deep. If there are multiple values for a dimension, they are OR'd together.If you don't provide a SERVICEfilter, Cost Explorer defaults to EC2.Cost category is also supported. 
- Granularity
- 
- Type: string
 The granularity of the Amazon Web Services cost data for the reservation. Valid values are MONTHLYandDAILY.If GroupByis set,Granularitycan't be set. IfGranularityisn't set, the response object doesn't includeGranularity, eitherMONTHLYorDAILY.The GetReservationCoverageoperation supports onlyDAILYandMONTHLYgranularities.
- GroupBy
- 
- Type: Array of GroupDefinition structures
 You can group the data by the following attributes: -  AZ 
-  CACHE_ENGINE 
-  DATABASE_ENGINE 
-  DEPLOYMENT_OPTION 
-  INSTANCE_TYPE 
-  INVOICING_ENTITY 
-  LINKED_ACCOUNT 
-  OPERATING_SYSTEM 
-  PLATFORM 
-  REGION 
-  TENANCY 
 
- MaxResults
- 
- Type: int
 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. 
- Metrics
- 
- Type: Array of strings
 The measurement that you want your reservation coverage reported in. Valid values are Hour,Unit, andCost. You can use multiple values in a request.
- NextPageToken
- 
- Type: string
 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
- 
- Type: SortDefinition structure
 The value by which you want to sort the data. The following values are supported for Key:-  OnDemandCost
-  CoverageHoursPercentage
-  OnDemandHours
-  ReservedHours
-  TotalRunningHours
-  CoverageNormalizedUnitsPercentage
-  OnDemandNormalizedUnits
-  ReservedNormalizedUnits
-  TotalRunningNormalizedUnits
-  Time
 Supported values for SortOrderareASCENDINGorDESCENDING.
- TimePeriod
- 
- Required: Yes
- Type: DateInterval structure
 The start and end dates of the period that you want to retrieve data about reservation coverage for. You can retrieve data for a maximum of 13 months: the last 12 months and the current month. The start date is inclusive, but the end date is exclusive. For example, if startis2017-01-01andendis2017-05-01, then the cost and usage data is retrieved from2017-01-01up to and including2017-04-30but not including2017-05-01.
Result Syntax
[
    'CoveragesByTime' => [
        [
            'Groups' => [
                [
                    'Attributes' => ['<string>', ...],
                    'Coverage' => [
                        'CoverageCost' => [
                            'OnDemandCost' => '<string>',
                        ],
                        'CoverageHours' => [
                            'CoverageHoursPercentage' => '<string>',
                            'OnDemandHours' => '<string>',
                            'ReservedHours' => '<string>',
                            'TotalRunningHours' => '<string>',
                        ],
                        'CoverageNormalizedUnits' => [
                            'CoverageNormalizedUnitsPercentage' => '<string>',
                            'OnDemandNormalizedUnits' => '<string>',
                            'ReservedNormalizedUnits' => '<string>',
                            'TotalRunningNormalizedUnits' => '<string>',
                        ],
                    ],
                ],
                // ...
            ],
            'TimePeriod' => [
                'End' => '<string>',
                'Start' => '<string>',
            ],
            'Total' => [
                'CoverageCost' => [
                    'OnDemandCost' => '<string>',
                ],
                'CoverageHours' => [
                    'CoverageHoursPercentage' => '<string>',
                    'OnDemandHours' => '<string>',
                    'ReservedHours' => '<string>',
                    'TotalRunningHours' => '<string>',
                ],
                'CoverageNormalizedUnits' => [
                    'CoverageNormalizedUnitsPercentage' => '<string>',
                    'OnDemandNormalizedUnits' => '<string>',
                    'ReservedNormalizedUnits' => '<string>',
                    'TotalRunningNormalizedUnits' => '<string>',
                ],
            ],
        ],
        // ...
    ],
    'NextPageToken' => '<string>',
    'Total' => [
        'CoverageCost' => [
            'OnDemandCost' => '<string>',
        ],
        'CoverageHours' => [
            'CoverageHoursPercentage' => '<string>',
            'OnDemandHours' => '<string>',
            'ReservedHours' => '<string>',
            'TotalRunningHours' => '<string>',
        ],
        'CoverageNormalizedUnits' => [
            'CoverageNormalizedUnitsPercentage' => '<string>',
            'OnDemandNormalizedUnits' => '<string>',
            'ReservedNormalizedUnits' => '<string>',
            'TotalRunningNormalizedUnits' => '<string>',
        ],
    ],
]
	Result Details
Members
- CoveragesByTime
- 
- Required: Yes
- Type: Array of CoverageByTime structures
 The amount of time that your reservations covered. 
- NextPageToken
- 
- Type: string
 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. 
- Total
- 
- Type: Coverage structure
 The total amount of instance usage that a reservation covered. 
Errors
- LimitExceededException:
- You made too many calls in a short period of time. Try again later. 
- DataUnavailableException:
- The requested data is unavailable. 
- InvalidNextTokenException:
- The pagination token is invalid. Try again without a pagination token. 
GetReservationPurchaseRecommendation
$result = $client->getReservationPurchaseRecommendation([/* ... */]); $promise = $client->getReservationPurchaseRecommendationAsync([/* ... */]);
Gets recommendations for reservation purchases. These recommendations might help you to reduce your costs. Reservations provide a discounted hourly rate (up to 75%) compared to On-Demand pricing.
Amazon Web Services generates your recommendations by identifying your On-Demand usage during a specific time period and collecting your usage into categories that are eligible for a reservation. After Amazon Web Services has these categories, it simulates every combination of reservations in each category of usage to identify the best number of each type of Reserved Instance (RI) to purchase to maximize your estimated savings.
For example, Amazon Web Services automatically aggregates your Amazon EC2 Linux, shared tenancy, and c4 family usage in the US West (Oregon) Region and recommends that you buy size-flexible regional reservations to apply to the c4 family usage. Amazon Web Services recommends the smallest size instance in an instance family. This makes it easier to purchase a size-flexible Reserved Instance (RI). Amazon Web Services also shows the equal number of normalized units. This way, you can purchase any instance size that you want. For this example, your RI recommendation is for c4.large because that is the smallest size instance in the c4 instance family.
Parameter Syntax
$result = $client->getReservationPurchaseRecommendation([
    'AccountId' => '<string>',
    'AccountScope' => 'PAYER|LINKED',
    'Filter' => [
        'And' => [
            [...], // RECURSIVE
            // ...
        ],
        'CostCategories' => [
            'Key' => '<string>',
            'MatchOptions' => ['<string>', ...],
            'Values' => ['<string>', ...],
        ],
        'Dimensions' => [
            'Key' => 'AZ|INSTANCE_TYPE|LINKED_ACCOUNT|PAYER_ACCOUNT|LINKED_ACCOUNT_NAME|OPERATION|PURCHASE_TYPE|REGION|SERVICE|SERVICE_CODE|USAGE_TYPE|USAGE_TYPE_GROUP|RECORD_TYPE|OPERATING_SYSTEM|TENANCY|SCOPE|PLATFORM|SUBSCRIPTION_ID|LEGAL_ENTITY_NAME|DEPLOYMENT_OPTION|DATABASE_ENGINE|CACHE_ENGINE|INSTANCE_TYPE_FAMILY|BILLING_ENTITY|RESERVATION_ID|RESOURCE_ID|RIGHTSIZING_TYPE|SAVINGS_PLANS_TYPE|SAVINGS_PLAN_ARN|PAYMENT_OPTION|AGREEMENT_END_DATE_TIME_AFTER|AGREEMENT_END_DATE_TIME_BEFORE|INVOICING_ENTITY|ANOMALY_TOTAL_IMPACT_ABSOLUTE|ANOMALY_TOTAL_IMPACT_PERCENTAGE',
            'MatchOptions' => ['<string>', ...],
            'Values' => ['<string>', ...],
        ],
        'Not' => [...], // RECURSIVE
        'Or' => [
            [...], // RECURSIVE
            // ...
        ],
        'Tags' => [
            'Key' => '<string>',
            'MatchOptions' => ['<string>', ...],
            'Values' => ['<string>', ...],
        ],
    ],
    'LookbackPeriodInDays' => 'SEVEN_DAYS|THIRTY_DAYS|SIXTY_DAYS',
    'NextPageToken' => '<string>',
    'PageSize' => <integer>,
    'PaymentOption' => 'NO_UPFRONT|PARTIAL_UPFRONT|ALL_UPFRONT|LIGHT_UTILIZATION|MEDIUM_UTILIZATION|HEAVY_UTILIZATION',
    'Service' => '<string>', // REQUIRED
    'ServiceSpecification' => [
        'EC2Specification' => [
            'OfferingClass' => 'STANDARD|CONVERTIBLE',
        ],
    ],
    'TermInYears' => 'ONE_YEAR|THREE_YEARS',
]);
	Parameter Details
Members
- AccountId
- 
- Type: string
 The account ID that's associated with the recommendation. 
- AccountScope
- 
- Type: string
 The account scope that you want your recommendations for. Amazon Web Services calculates recommendations including the management account and member accounts if the value is set to PAYER. If the value isLINKED, recommendations are calculated for individual member accounts only.
- Filter
- 
- Type: Expression structure
 Use Expressionto filter in various Cost Explorer APIs.Not all Expressiontypes are supported in each API. Refer to the documentation for each specific API to see what is supported.There are two patterns: -  Simple dimension values. -  There are three types of simple dimension values: CostCategories,Tags, andDimensions.-  Specify the CostCategoriesfield to define a filter that acts on Cost Categories.
-  Specify the Tagsfield to define a filter that acts on Cost Allocation Tags.
-  Specify the Dimensionsfield to define a filter that acts on theDimensionValues.
 
-  
-  For each filter type, you can set the dimension name and values for the filters that you plan to use. -  For example, you can filter for REGION==us-east-1 OR REGION==us-west-1. ForGetRightsizingRecommendation, the Region is a full name (for example,REGION==US East (N. Virginia).
-  The corresponding Expressionfor this example is as follows:{ "Dimensions": { "Key": "REGION", "Values": [ "us-east-1", "us-west-1" ] } }
-  As shown in the previous example, lists of dimension values are combined with ORwhen applying the filter.
 
-  
-  You can also set different match options to further control how the filter behaves. Not all APIs support match options. Refer to the documentation for each specific API to see what is supported. -  For example, you can filter for linked account names that start with "a". 
-  The corresponding Expressionfor this example is as follows:{ "Dimensions": { "Key": "LINKED_ACCOUNT_NAME", "MatchOptions": [ "STARTS_WITH" ], "Values": [ "a" ] } }
 
-  
 
-  
-  Compound Expressiontypes with logical operations.-  You can use multiple Expressiontypes and the logical operatorsAND/OR/NOTto create a list of one or moreExpressionobjects. By doing this, you can filter by more advanced options.
-  For example, you can filter by ((REGION == us-east-1 OR REGION == us-west-1) OR (TAG.Type == Type1)) AND (USAGE_TYPE != DataTransfer).
-  The corresponding Expressionfor this example is as follows:{ "And": [ {"Or": [ {"Dimensions": { "Key": "REGION", "Values": [ "us-east-1", "us-west-1" ] }}, {"Tags": { "Key": "TagName", "Values": ["Value1"] } } ]}, {"Not": {"Dimensions": { "Key": "USAGE_TYPE", "Values": ["DataTransfer"] }}} ] }
 Because each Expressioncan have only one operator, the service returns an error if more than one is specified. The following example shows anExpressionobject that creates an error:{ "And": [ ... ], "Dimensions": { "Key": "USAGE_TYPE", "Values": [ "DataTransfer" ] } }The following is an example of the corresponding error message: "Expression has more than one roots. Only one root operator is allowed for each expression: And, Or, Not, Dimensions, Tags, CostCategories"
-  
 For the GetRightsizingRecommendationaction, a combination of OR and NOT isn't supported. OR isn't supported between different dimensions, or dimensions and tags. NOT operators aren't supported. Dimensions are also limited toLINKED_ACCOUNT,REGION, orRIGHTSIZING_TYPE.For the GetReservationPurchaseRecommendationaction, only NOT is supported. AND and OR aren't supported. Dimensions are limited toLINKED_ACCOUNT.
- LookbackPeriodInDays
- 
- Type: string
 The number of previous days that you want Amazon Web Services to consider when it calculates your recommendations. 
- NextPageToken
- 
- Type: string
 The pagination token that indicates the next set of results that you want to retrieve. 
- PageSize
- 
- Type: int
 The number of recommendations that you want returned in a single response object. 
- PaymentOption
- 
- Type: string
 The reservation purchase option that you want recommendations for. 
- Service
- 
- Required: Yes
- Type: string
 The specific service that you want recommendations for. 
- ServiceSpecification
- 
- Type: ServiceSpecification structure
 The hardware specifications for the service instances that you want recommendations for, such as standard or convertible Amazon EC2 instances. 
- TermInYears
- 
- Type: string
 The reservation term that you want recommendations for. 
Result Syntax
[
    'Metadata' => [
        'AdditionalMetadata' => '<string>',
        'GenerationTimestamp' => '<string>',
        'RecommendationId' => '<string>',
    ],
    'NextPageToken' => '<string>',
    'Recommendations' => [
        [
            'AccountScope' => 'PAYER|LINKED',
            'LookbackPeriodInDays' => 'SEVEN_DAYS|THIRTY_DAYS|SIXTY_DAYS',
            'PaymentOption' => 'NO_UPFRONT|PARTIAL_UPFRONT|ALL_UPFRONT|LIGHT_UTILIZATION|MEDIUM_UTILIZATION|HEAVY_UTILIZATION',
            'RecommendationDetails' => [
                [
                    'AccountId' => '<string>',
                    'AverageNormalizedUnitsUsedPerHour' => '<string>',
                    'AverageNumberOfCapacityUnitsUsedPerHour' => '<string>',
                    'AverageNumberOfInstancesUsedPerHour' => '<string>',
                    'AverageUtilization' => '<string>',
                    'CurrencyCode' => '<string>',
                    'EstimatedBreakEvenInMonths' => '<string>',
                    'EstimatedMonthlyOnDemandCost' => '<string>',
                    'EstimatedMonthlySavingsAmount' => '<string>',
                    'EstimatedMonthlySavingsPercentage' => '<string>',
                    'EstimatedReservationCostForLookbackPeriod' => '<string>',
                    'InstanceDetails' => [
                        'EC2InstanceDetails' => [
                            'AvailabilityZone' => '<string>',
                            'CurrentGeneration' => true || false,
                            'Family' => '<string>',
                            'InstanceType' => '<string>',
                            'Platform' => '<string>',
                            'Region' => '<string>',
                            'SizeFlexEligible' => true || false,
                            'Tenancy' => '<string>',
                        ],
                        'ESInstanceDetails' => [
                            'CurrentGeneration' => true || false,
                            'InstanceClass' => '<string>',
                            'InstanceSize' => '<string>',
                            'Region' => '<string>',
                            'SizeFlexEligible' => true || false,
                        ],
                        'ElastiCacheInstanceDetails' => [
                            'CurrentGeneration' => true || false,
                            'Family' => '<string>',
                            'NodeType' => '<string>',
                            'ProductDescription' => '<string>',
                            'Region' => '<string>',
                            'SizeFlexEligible' => true || false,
                        ],
                        'MemoryDBInstanceDetails' => [
                            'CurrentGeneration' => true || false,
                            'Family' => '<string>',
                            'NodeType' => '<string>',
                            'Region' => '<string>',
                            'SizeFlexEligible' => true || false,
                        ],
                        'RDSInstanceDetails' => [
                            'CurrentGeneration' => true || false,
                            'DatabaseEdition' => '<string>',
                            'DatabaseEngine' => '<string>',
                            'DeploymentOption' => '<string>',
                            'Family' => '<string>',
                            'InstanceType' => '<string>',
                            'LicenseModel' => '<string>',
                            'Region' => '<string>',
                            'SizeFlexEligible' => true || false,
                        ],
                        'RedshiftInstanceDetails' => [
                            'CurrentGeneration' => true || false,
                            'Family' => '<string>',
                            'NodeType' => '<string>',
                            'Region' => '<string>',
                            'SizeFlexEligible' => true || false,
                        ],
                    ],
                    'MaximumNormalizedUnitsUsedPerHour' => '<string>',
                    'MaximumNumberOfCapacityUnitsUsedPerHour' => '<string>',
                    'MaximumNumberOfInstancesUsedPerHour' => '<string>',
                    'MinimumNormalizedUnitsUsedPerHour' => '<string>',
                    'MinimumNumberOfCapacityUnitsUsedPerHour' => '<string>',
                    'MinimumNumberOfInstancesUsedPerHour' => '<string>',
                    'RecommendedNormalizedUnitsToPurchase' => '<string>',
                    'RecommendedNumberOfCapacityUnitsToPurchase' => '<string>',
                    'RecommendedNumberOfInstancesToPurchase' => '<string>',
                    'RecurringStandardMonthlyCost' => '<string>',
                    'ReservedCapacityDetails' => [
                        'DynamoDBCapacityDetails' => [
                            'CapacityUnits' => '<string>',
                            'Region' => '<string>',
                        ],
                    ],
                    'UpfrontCost' => '<string>',
                ],
                // ...
            ],
            'RecommendationSummary' => [
                'CurrencyCode' => '<string>',
                'TotalEstimatedMonthlySavingsAmount' => '<string>',
                'TotalEstimatedMonthlySavingsPercentage' => '<string>',
            ],
            'ServiceSpecification' => [
                'EC2Specification' => [
                    'OfferingClass' => 'STANDARD|CONVERTIBLE',
                ],
            ],
            'TermInYears' => 'ONE_YEAR|THREE_YEARS',
        ],
        // ...
    ],
]
	Result Details
Members
- Metadata
- 
- Type: ReservationPurchaseRecommendationMetadata structure
 Information about this specific recommendation call, such as the time stamp for when Cost Explorer generated this recommendation. 
- NextPageToken
- 
- Type: string
 The pagination token for the next set of retrievable results. 
- Recommendations
- 
- Type: Array of ReservationPurchaseRecommendation structures
 Recommendations for reservations to purchase. 
Errors
- LimitExceededException:
- You made too many calls in a short period of time. Try again later. 
- DataUnavailableException:
- The requested data is unavailable. 
- InvalidNextTokenException:
- The pagination token is invalid. Try again without a pagination token. 
GetReservationUtilization
$result = $client->getReservationUtilization([/* ... */]); $promise = $client->getReservationUtilizationAsync([/* ... */]);
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. 
Parameter Syntax
$result = $client->getReservationUtilization([
    'Filter' => [
        'And' => [
            [...], // RECURSIVE
            // ...
        ],
        'CostCategories' => [
            'Key' => '<string>',
            'MatchOptions' => ['<string>', ...],
            'Values' => ['<string>', ...],
        ],
        'Dimensions' => [
            'Key' => 'AZ|INSTANCE_TYPE|LINKED_ACCOUNT|PAYER_ACCOUNT|LINKED_ACCOUNT_NAME|OPERATION|PURCHASE_TYPE|REGION|SERVICE|SERVICE_CODE|USAGE_TYPE|USAGE_TYPE_GROUP|RECORD_TYPE|OPERATING_SYSTEM|TENANCY|SCOPE|PLATFORM|SUBSCRIPTION_ID|LEGAL_ENTITY_NAME|DEPLOYMENT_OPTION|DATABASE_ENGINE|CACHE_ENGINE|INSTANCE_TYPE_FAMILY|BILLING_ENTITY|RESERVATION_ID|RESOURCE_ID|RIGHTSIZING_TYPE|SAVINGS_PLANS_TYPE|SAVINGS_PLAN_ARN|PAYMENT_OPTION|AGREEMENT_END_DATE_TIME_AFTER|AGREEMENT_END_DATE_TIME_BEFORE|INVOICING_ENTITY|ANOMALY_TOTAL_IMPACT_ABSOLUTE|ANOMALY_TOTAL_IMPACT_PERCENTAGE',
            'MatchOptions' => ['<string>', ...],
            'Values' => ['<string>', ...],
        ],
        'Not' => [...], // RECURSIVE
        'Or' => [
            [...], // RECURSIVE
            // ...
        ],
        'Tags' => [
            'Key' => '<string>',
            'MatchOptions' => ['<string>', ...],
            'Values' => ['<string>', ...],
        ],
    ],
    'Granularity' => 'DAILY|MONTHLY|HOURLY',
    'GroupBy' => [
        [
            'Key' => '<string>',
            'Type' => 'DIMENSION|TAG|COST_CATEGORY',
        ],
        // ...
    ],
    'MaxResults' => <integer>,
    'NextPageToken' => '<string>',
    'SortBy' => [
        'Key' => '<string>', // REQUIRED
        'SortOrder' => 'ASCENDING|DESCENDING',
    ],
    'TimePeriod' => [ // REQUIRED
        'End' => '<string>', // REQUIRED
        'Start' => '<string>', // REQUIRED
    ],
]);
	Parameter Details
Members
- Filter
- 
- Type: Expression structure
 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 If not specified, the SERVICEfilter defaults to Amazon Elastic Compute Cloud - Compute. Supported values forSERVICEare Amazon Elastic Compute Cloud - Compute, Amazon Relational Database Service, Amazon ElastiCache, Amazon Redshift, and Amazon Elasticsearch Service. The value for theSERVICEfilter should not exceed "1".
-  SCOPE 
-  TENANCY 
 GetReservationUtilizationuses the same Expression object as the other operations, but onlyANDis 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
- 
- Type: string
 If GroupByis set,Granularitycan't be set. IfGranularityisn't set, the response object doesn't includeGranularity, eitherMONTHLYorDAILY. If bothGroupByandGranularityaren't set,GetReservationUtilizationdefaults toDAILY.The GetReservationUtilizationoperation supports onlyDAILYandMONTHLYgranularities.
- GroupBy
- 
- Type: Array of GroupDefinition structures
 Groups only by SUBSCRIPTION_ID. Metadata is included.
- MaxResults
- 
- Type: int
 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
- 
- Type: string
 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
- 
- Type: SortDefinition structure
 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 SortOrderareASCENDINGandDESCENDING.
- TimePeriod
- 
- Required: Yes
- Type: DateInterval structure
 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 startis2017-01-01andendis2017-05-01, then the cost and usage data is retrieved from2017-01-01up to and including2017-04-30but not including2017-05-01.
Result Syntax
[
    'NextPageToken' => '<string>',
    'Total' => [
        'AmortizedRecurringFee' => '<string>',
        'AmortizedUpfrontFee' => '<string>',
        'NetRISavings' => '<string>',
        'OnDemandCostOfRIHoursUsed' => '<string>',
        'PurchasedHours' => '<string>',
        'PurchasedUnits' => '<string>',
        'RICostForUnusedHours' => '<string>',
        'RealizedSavings' => '<string>',
        'TotalActualHours' => '<string>',
        'TotalActualUnits' => '<string>',
        'TotalAmortizedFee' => '<string>',
        'TotalPotentialRISavings' => '<string>',
        'UnrealizedSavings' => '<string>',
        'UnusedHours' => '<string>',
        'UnusedUnits' => '<string>',
        'UtilizationPercentage' => '<string>',
        'UtilizationPercentageInUnits' => '<string>',
    ],
    'UtilizationsByTime' => [
        [
            'Groups' => [
                [
                    'Attributes' => ['<string>', ...],
                    'Key' => '<string>',
                    'Utilization' => [
                        'AmortizedRecurringFee' => '<string>',
                        'AmortizedUpfrontFee' => '<string>',
                        'NetRISavings' => '<string>',
                        'OnDemandCostOfRIHoursUsed' => '<string>',
                        'PurchasedHours' => '<string>',
                        'PurchasedUnits' => '<string>',
                        'RICostForUnusedHours' => '<string>',
                        'RealizedSavings' => '<string>',
                        'TotalActualHours' => '<string>',
                        'TotalActualUnits' => '<string>',
                        'TotalAmortizedFee' => '<string>',
                        'TotalPotentialRISavings' => '<string>',
                        'UnrealizedSavings' => '<string>',
                        'UnusedHours' => '<string>',
                        'UnusedUnits' => '<string>',
                        'UtilizationPercentage' => '<string>',
                        'UtilizationPercentageInUnits' => '<string>',
                    ],
                    'Value' => '<string>',
                ],
                // ...
            ],
            'TimePeriod' => [
                'End' => '<string>',
                'Start' => '<string>',
            ],
            'Total' => [
                'AmortizedRecurringFee' => '<string>',
                'AmortizedUpfrontFee' => '<string>',
                'NetRISavings' => '<string>',
                'OnDemandCostOfRIHoursUsed' => '<string>',
                'PurchasedHours' => '<string>',
                'PurchasedUnits' => '<string>',
                'RICostForUnusedHours' => '<string>',
                'RealizedSavings' => '<string>',
                'TotalActualHours' => '<string>',
                'TotalActualUnits' => '<string>',
                'TotalAmortizedFee' => '<string>',
                'TotalPotentialRISavings' => '<string>',
                'UnrealizedSavings' => '<string>',
                'UnusedHours' => '<string>',
                'UnusedUnits' => '<string>',
                'UtilizationPercentage' => '<string>',
                'UtilizationPercentageInUnits' => '<string>',
            ],
        ],
        // ...
    ],
]
	Result Details
Members
- NextPageToken
- 
- Type: string
 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. 
- Total
- 
- Type: ReservationAggregates structure
 The total amount of time that you used your Reserved Instances (RIs). 
- UtilizationsByTime
- 
- Required: Yes
- Type: Array of UtilizationByTime structures
 The amount of time that you used your Reserved Instances (RIs). 
Errors
- LimitExceededException:
- You made too many calls in a short period of time. Try again later. 
- DataUnavailableException:
- The requested data is unavailable. 
- InvalidNextTokenException:
- The pagination token is invalid. Try again without a pagination token. 
GetRightsizingRecommendation
$result = $client->getRightsizingRecommendation([/* ... */]); $promise = $client->getRightsizingRecommendationAsync([/* ... */]);
Creates recommendations that help you save cost by identifying idle and underutilized Amazon EC2 instances.
Recommendations are generated to either downsize or terminate instances, along with providing savings detail and metrics. For more information about calculation and function, see Optimizing Your Cost with Rightsizing Recommendations in the Billing and Cost Management User Guide.
Parameter Syntax
$result = $client->getRightsizingRecommendation([
    'Configuration' => [
        'BenefitsConsidered' => true || false, // REQUIRED
        'RecommendationTarget' => 'SAME_INSTANCE_FAMILY|CROSS_INSTANCE_FAMILY', // REQUIRED
    ],
    'Filter' => [
        'And' => [
            [...], // RECURSIVE
            // ...
        ],
        'CostCategories' => [
            'Key' => '<string>',
            'MatchOptions' => ['<string>', ...],
            'Values' => ['<string>', ...],
        ],
        'Dimensions' => [
            'Key' => 'AZ|INSTANCE_TYPE|LINKED_ACCOUNT|PAYER_ACCOUNT|LINKED_ACCOUNT_NAME|OPERATION|PURCHASE_TYPE|REGION|SERVICE|SERVICE_CODE|USAGE_TYPE|USAGE_TYPE_GROUP|RECORD_TYPE|OPERATING_SYSTEM|TENANCY|SCOPE|PLATFORM|SUBSCRIPTION_ID|LEGAL_ENTITY_NAME|DEPLOYMENT_OPTION|DATABASE_ENGINE|CACHE_ENGINE|INSTANCE_TYPE_FAMILY|BILLING_ENTITY|RESERVATION_ID|RESOURCE_ID|RIGHTSIZING_TYPE|SAVINGS_PLANS_TYPE|SAVINGS_PLAN_ARN|PAYMENT_OPTION|AGREEMENT_END_DATE_TIME_AFTER|AGREEMENT_END_DATE_TIME_BEFORE|INVOICING_ENTITY|ANOMALY_TOTAL_IMPACT_ABSOLUTE|ANOMALY_TOTAL_IMPACT_PERCENTAGE',
            'MatchOptions' => ['<string>', ...],
            'Values' => ['<string>', ...],
        ],
        'Not' => [...], // RECURSIVE
        'Or' => [
            [...], // RECURSIVE
            // ...
        ],
        'Tags' => [
            'Key' => '<string>',
            'MatchOptions' => ['<string>', ...],
            'Values' => ['<string>', ...],
        ],
    ],
    'NextPageToken' => '<string>',
    'PageSize' => <integer>,
    'Service' => '<string>', // REQUIRED
]);
	Parameter Details
Members
- Configuration
- 
- Type: RightsizingRecommendationConfiguration structure
 You can use Configuration to customize recommendations across two attributes. You can choose to view recommendations for instances within the same instance families or across different instance families. You can also choose to view your estimated savings that are associated with recommendations with consideration of existing Savings Plans or RI benefits, or neither. 
- Filter
- 
- Type: Expression structure
 Use Expressionto filter in various Cost Explorer APIs.Not all Expressiontypes are supported in each API. Refer to the documentation for each specific API to see what is supported.There are two patterns: -  Simple dimension values. -  There are three types of simple dimension values: CostCategories,Tags, andDimensions.-  Specify the CostCategoriesfield to define a filter that acts on Cost Categories.
-  Specify the Tagsfield to define a filter that acts on Cost Allocation Tags.
-  Specify the Dimensionsfield to define a filter that acts on theDimensionValues.
 
-  
-  For each filter type, you can set the dimension name and values for the filters that you plan to use. -  For example, you can filter for REGION==us-east-1 OR REGION==us-west-1. ForGetRightsizingRecommendation, the Region is a full name (for example,REGION==US East (N. Virginia).
-  The corresponding Expressionfor this example is as follows:{ "Dimensions": { "Key": "REGION", "Values": [ "us-east-1", "us-west-1" ] } }
-  As shown in the previous example, lists of dimension values are combined with ORwhen applying the filter.
 
-  
-  You can also set different match options to further control how the filter behaves. Not all APIs support match options. Refer to the documentation for each specific API to see what is supported. -  For example, you can filter for linked account names that start with "a". 
-  The corresponding Expressionfor this example is as follows:{ "Dimensions": { "Key": "LINKED_ACCOUNT_NAME", "MatchOptions": [ "STARTS_WITH" ], "Values": [ "a" ] } }
 
-  
 
-  
-  Compound Expressiontypes with logical operations.-  You can use multiple Expressiontypes and the logical operatorsAND/OR/NOTto create a list of one or moreExpressionobjects. By doing this, you can filter by more advanced options.
-  For example, you can filter by ((REGION == us-east-1 OR REGION == us-west-1) OR (TAG.Type == Type1)) AND (USAGE_TYPE != DataTransfer).
-  The corresponding Expressionfor this example is as follows:{ "And": [ {"Or": [ {"Dimensions": { "Key": "REGION", "Values": [ "us-east-1", "us-west-1" ] }}, {"Tags": { "Key": "TagName", "Values": ["Value1"] } } ]}, {"Not": {"Dimensions": { "Key": "USAGE_TYPE", "Values": ["DataTransfer"] }}} ] }
 Because each Expressioncan have only one operator, the service returns an error if more than one is specified. The following example shows anExpressionobject that creates an error:{ "And": [ ... ], "Dimensions": { "Key": "USAGE_TYPE", "Values": [ "DataTransfer" ] } }The following is an example of the corresponding error message: "Expression has more than one roots. Only one root operator is allowed for each expression: And, Or, Not, Dimensions, Tags, CostCategories"
-  
 For the GetRightsizingRecommendationaction, a combination of OR and NOT isn't supported. OR isn't supported between different dimensions, or dimensions and tags. NOT operators aren't supported. Dimensions are also limited toLINKED_ACCOUNT,REGION, orRIGHTSIZING_TYPE.For the GetReservationPurchaseRecommendationaction, only NOT is supported. AND and OR aren't supported. Dimensions are limited toLINKED_ACCOUNT.
- NextPageToken
- 
- Type: string
 The pagination token that indicates the next set of results that you want to retrieve. 
- PageSize
- 
- Type: int
 The number of recommendations that you want returned in a single response object. 
- Service
- 
- Required: Yes
- Type: string
 The specific service that you want recommendations for. The only valid value for GetRightsizingRecommendationis "AmazonEC2".
Result Syntax
[
    'Configuration' => [
        'BenefitsConsidered' => true || false,
        'RecommendationTarget' => 'SAME_INSTANCE_FAMILY|CROSS_INSTANCE_FAMILY',
    ],
    'Metadata' => [
        'AdditionalMetadata' => '<string>',
        'GenerationTimestamp' => '<string>',
        'LookbackPeriodInDays' => 'SEVEN_DAYS|THIRTY_DAYS|SIXTY_DAYS',
        'RecommendationId' => '<string>',
    ],
    'NextPageToken' => '<string>',
    'RightsizingRecommendations' => [
        [
            'AccountId' => '<string>',
            'CurrentInstance' => [
                'CurrencyCode' => '<string>',
                'InstanceName' => '<string>',
                'MonthlyCost' => '<string>',
                'OnDemandHoursInLookbackPeriod' => '<string>',
                'ReservationCoveredHoursInLookbackPeriod' => '<string>',
                'ResourceDetails' => [
                    'EC2ResourceDetails' => [
                        'HourlyOnDemandRate' => '<string>',
                        'InstanceType' => '<string>',
                        'Memory' => '<string>',
                        'NetworkPerformance' => '<string>',
                        'Platform' => '<string>',
                        'Region' => '<string>',
                        'Sku' => '<string>',
                        'Storage' => '<string>',
                        'Vcpu' => '<string>',
                    ],
                ],
                'ResourceId' => '<string>',
                'ResourceUtilization' => [
                    'EC2ResourceUtilization' => [
                        'DiskResourceUtilization' => [
                            'DiskReadBytesPerSecond' => '<string>',
                            'DiskReadOpsPerSecond' => '<string>',
                            'DiskWriteBytesPerSecond' => '<string>',
                            'DiskWriteOpsPerSecond' => '<string>',
                        ],
                        'EBSResourceUtilization' => [
                            'EbsReadBytesPerSecond' => '<string>',
                            'EbsReadOpsPerSecond' => '<string>',
                            'EbsWriteBytesPerSecond' => '<string>',
                            'EbsWriteOpsPerSecond' => '<string>',
                        ],
                        'MaxCpuUtilizationPercentage' => '<string>',
                        'MaxMemoryUtilizationPercentage' => '<string>',
                        'MaxStorageUtilizationPercentage' => '<string>',
                        'NetworkResourceUtilization' => [
                            'NetworkInBytesPerSecond' => '<string>',
                            'NetworkOutBytesPerSecond' => '<string>',
                            'NetworkPacketsInPerSecond' => '<string>',
                            'NetworkPacketsOutPerSecond' => '<string>',
                        ],
                    ],
                ],
                'SavingsPlansCoveredHoursInLookbackPeriod' => '<string>',
                'Tags' => [
                    [
                        'Key' => '<string>',
                        'MatchOptions' => ['<string>', ...],
                        'Values' => ['<string>', ...],
                    ],
                    // ...
                ],
                'TotalRunningHoursInLookbackPeriod' => '<string>',
            ],
            'FindingReasonCodes' => ['<string>', ...],
            'ModifyRecommendationDetail' => [
                'TargetInstances' => [
                    [
                        'CurrencyCode' => '<string>',
                        'DefaultTargetInstance' => true || false,
                        'EstimatedMonthlyCost' => '<string>',
                        'EstimatedMonthlySavings' => '<string>',
                        'ExpectedResourceUtilization' => [
                            'EC2ResourceUtilization' => [
                                'DiskResourceUtilization' => [
                                    'DiskReadBytesPerSecond' => '<string>',
                                    'DiskReadOpsPerSecond' => '<string>',
                                    'DiskWriteBytesPerSecond' => '<string>',
                                    'DiskWriteOpsPerSecond' => '<string>',
                                ],
                                'EBSResourceUtilization' => [
                                    'EbsReadBytesPerSecond' => '<string>',
                                    'EbsReadOpsPerSecond' => '<string>',
                                    'EbsWriteBytesPerSecond' => '<string>',
                                    'EbsWriteOpsPerSecond' => '<string>',
                                ],
                                'MaxCpuUtilizationPercentage' => '<string>',
                                'MaxMemoryUtilizationPercentage' => '<string>',
                                'MaxStorageUtilizationPercentage' => '<string>',
                                'NetworkResourceUtilization' => [
                                    'NetworkInBytesPerSecond' => '<string>',
                                    'NetworkOutBytesPerSecond' => '<string>',
                                    'NetworkPacketsInPerSecond' => '<string>',
                                    'NetworkPacketsOutPerSecond' => '<string>',
                                ],
                            ],
                        ],
                        'PlatformDifferences' => ['<string>', ...],
                        'ResourceDetails' => [
                            'EC2ResourceDetails' => [
                                'HourlyOnDemandRate' => '<string>',
                                'InstanceType' => '<string>',
                                'Memory' => '<string>',
                                'NetworkPerformance' => '<string>',
                                'Platform' => '<string>',
                                'Region' => '<string>',
                                'Sku' => '<string>',
                                'Storage' => '<string>',
                                'Vcpu' => '<string>',
                            ],
                        ],
                    ],
                    // ...
                ],
            ],
            'RightsizingType' => 'TERMINATE|MODIFY',
            'TerminateRecommendationDetail' => [
                'CurrencyCode' => '<string>',
                'EstimatedMonthlySavings' => '<string>',
            ],
        ],
        // ...
    ],
    'Summary' => [
        'EstimatedTotalMonthlySavingsAmount' => '<string>',
        'SavingsCurrencyCode' => '<string>',
        'SavingsPercentage' => '<string>',
        'TotalRecommendationCount' => '<string>',
    ],
]
	Result Details
Members
- Configuration
- 
- Type: RightsizingRecommendationConfiguration structure
 You can use Configuration to customize recommendations across two attributes. You can choose to view recommendations for instances within the same instance families or across different instance families. You can also choose to view your estimated savings that are associated with recommendations with consideration of existing Savings Plans or RI benefits, or neither. 
- Metadata
- 
- Type: RightsizingRecommendationMetadata structure
 Information regarding this specific recommendation set. 
- NextPageToken
- 
- Type: string
 The token to retrieve the next set of results. 
- RightsizingRecommendations
- 
- Type: Array of RightsizingRecommendation structures
 Recommendations to rightsize resources. 
- Summary
- 
- Type: RightsizingRecommendationSummary structure
 Summary of this recommendation set. 
Errors
- LimitExceededException:
- You made too many calls in a short period of time. Try again later. 
- InvalidNextTokenException:
- The pagination token is invalid. Try again without a pagination token. 
GetSavingsPlanPurchaseRecommendationDetails
$result = $client->getSavingsPlanPurchaseRecommendationDetails([/* ... */]); $promise = $client->getSavingsPlanPurchaseRecommendationDetailsAsync([/* ... */]);
Retrieves the details for a Savings Plan recommendation. These details include the hourly data-points that construct the cost, coverage, and utilization charts.
Parameter Syntax
$result = $client->getSavingsPlanPurchaseRecommendationDetails([
    'RecommendationDetailId' => '<string>', // REQUIRED
]);
	Parameter Details
Members
- RecommendationDetailId
- 
- Required: Yes
- Type: string
 The ID that is associated with the Savings Plan recommendation. 
Result Syntax
[
    'RecommendationDetailData' => [
        'AccountId' => '<string>',
        'AccountScope' => 'PAYER|LINKED',
        'CurrencyCode' => '<string>',
        'CurrentAverageCoverage' => '<string>',
        'CurrentAverageHourlyOnDemandSpend' => '<string>',
        'CurrentMaximumHourlyOnDemandSpend' => '<string>',
        'CurrentMinimumHourlyOnDemandSpend' => '<string>',
        'EstimatedAverageCoverage' => '<string>',
        'EstimatedAverageUtilization' => '<string>',
        'EstimatedMonthlySavingsAmount' => '<string>',
        'EstimatedOnDemandCost' => '<string>',
        'EstimatedOnDemandCostWithCurrentCommitment' => '<string>',
        'EstimatedROI' => '<string>',
        'EstimatedSPCost' => '<string>',
        'EstimatedSavingsAmount' => '<string>',
        'EstimatedSavingsPercentage' => '<string>',
        'ExistingHourlyCommitment' => '<string>',
        'GenerationTimestamp' => '<string>',
        'HourlyCommitmentToPurchase' => '<string>',
        'InstanceFamily' => '<string>',
        'LatestUsageTimestamp' => '<string>',
        'LookbackPeriodInDays' => 'SEVEN_DAYS|THIRTY_DAYS|SIXTY_DAYS',
        'MetricsOverLookbackPeriod' => [
            [
                'CurrentCoverage' => '<string>',
                'EstimatedCoverage' => '<string>',
                'EstimatedNewCommitmentUtilization' => '<string>',
                'EstimatedOnDemandCost' => '<string>',
                'StartTime' => '<string>',
            ],
            // ...
        ],
        'OfferingId' => '<string>',
        'PaymentOption' => 'NO_UPFRONT|PARTIAL_UPFRONT|ALL_UPFRONT|LIGHT_UTILIZATION|MEDIUM_UTILIZATION|HEAVY_UTILIZATION',
        'Region' => '<string>',
        'SavingsPlansType' => 'COMPUTE_SP|EC2_INSTANCE_SP|SAGEMAKER_SP',
        'TermInYears' => 'ONE_YEAR|THREE_YEARS',
        'UpfrontCost' => '<string>',
    ],
    'RecommendationDetailId' => '<string>',
]
	Result Details
Members
- RecommendationDetailData
- 
- Type: RecommendationDetailData structure
 Contains detailed information about a specific Savings Plan recommendation. 
- RecommendationDetailId
- 
- Type: string
 The ID that is associated with the Savings Plan recommendation. 
Errors
- LimitExceededException:
- You made too many calls in a short period of time. Try again later. 
- DataUnavailableException:
- The requested data is unavailable. 
GetSavingsPlansCoverage
$result = $client->getSavingsPlansCoverage([/* ... */]); $promise = $client->getSavingsPlansCoverageAsync([/* ... */]);
Retrieves the Savings Plans covered for your account. This enables you to see how much of your cost is covered by a Savings Plan. An organization’s management account can see the coverage of the associated member accounts. This supports dimensions, Cost Categories, and nested expressions. For any time period, you can filter data for Savings Plans usage with the following dimensions:
-  LINKED_ACCOUNT
-  REGION
-  SERVICE
-  INSTANCE_FAMILY
To determine valid values for a dimension, use the GetDimensionValues operation.
Parameter Syntax
$result = $client->getSavingsPlansCoverage([
    'Filter' => [
        'And' => [
            [...], // RECURSIVE
            // ...
        ],
        'CostCategories' => [
            'Key' => '<string>',
            'MatchOptions' => ['<string>', ...],
            'Values' => ['<string>', ...],
        ],
        'Dimensions' => [
            'Key' => 'AZ|INSTANCE_TYPE|LINKED_ACCOUNT|PAYER_ACCOUNT|LINKED_ACCOUNT_NAME|OPERATION|PURCHASE_TYPE|REGION|SERVICE|SERVICE_CODE|USAGE_TYPE|USAGE_TYPE_GROUP|RECORD_TYPE|OPERATING_SYSTEM|TENANCY|SCOPE|PLATFORM|SUBSCRIPTION_ID|LEGAL_ENTITY_NAME|DEPLOYMENT_OPTION|DATABASE_ENGINE|CACHE_ENGINE|INSTANCE_TYPE_FAMILY|BILLING_ENTITY|RESERVATION_ID|RESOURCE_ID|RIGHTSIZING_TYPE|SAVINGS_PLANS_TYPE|SAVINGS_PLAN_ARN|PAYMENT_OPTION|AGREEMENT_END_DATE_TIME_AFTER|AGREEMENT_END_DATE_TIME_BEFORE|INVOICING_ENTITY|ANOMALY_TOTAL_IMPACT_ABSOLUTE|ANOMALY_TOTAL_IMPACT_PERCENTAGE',
            'MatchOptions' => ['<string>', ...],
            'Values' => ['<string>', ...],
        ],
        'Not' => [...], // RECURSIVE
        'Or' => [
            [...], // RECURSIVE
            // ...
        ],
        'Tags' => [
            'Key' => '<string>',
            'MatchOptions' => ['<string>', ...],
            'Values' => ['<string>', ...],
        ],
    ],
    'Granularity' => 'DAILY|MONTHLY|HOURLY',
    'GroupBy' => [
        [
            'Key' => '<string>',
            'Type' => 'DIMENSION|TAG|COST_CATEGORY',
        ],
        // ...
    ],
    'MaxResults' => <integer>,
    'Metrics' => ['<string>', ...],
    'NextToken' => '<string>',
    'SortBy' => [
        'Key' => '<string>', // REQUIRED
        'SortOrder' => 'ASCENDING|DESCENDING',
    ],
    'TimePeriod' => [ // REQUIRED
        'End' => '<string>', // REQUIRED
        'Start' => '<string>', // REQUIRED
    ],
]);
	Parameter Details
Members
- Filter
- 
- Type: Expression structure
 Filters Savings Plans coverage data by dimensions. You can filter data for Savings Plans usage with the following dimensions: -  LINKED_ACCOUNT
-  REGION
-  SERVICE
-  INSTANCE_FAMILY
 GetSavingsPlansCoverageuses the same Expression object as the other operations, but onlyANDis supported among each dimension. If there are multiple values for a dimension, they are OR'd together.Cost category is also supported. 
- Granularity
- 
- Type: string
 The granularity of the Amazon Web Services cost data for your Savings Plans. Granularitycan't be set ifGroupByis set.The GetSavingsPlansCoverageoperation supports onlyDAILYandMONTHLYgranularities.
- GroupBy
- 
- Type: Array of GroupDefinition structures
 You can group the data using the attributes INSTANCE_FAMILY,REGION, orSERVICE.
- MaxResults
- 
- Type: int
 The number of items to be returned in a response. The default is 20, with a minimum value of1.
- Metrics
- 
- Type: Array of strings
 The measurement that you want your Savings Plans coverage reported in. The only valid value is SpendCoveredBySavingsPlans.
- NextToken
- 
- Type: string
 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
- 
- Type: SortDefinition structure
 The value that you want to sort the data by. The following values are supported for Key:-  SpendCoveredBySavingsPlan
-  OnDemandCost
-  CoveragePercentage
-  TotalCost
-  InstanceFamily
-  Region
-  Service
 The supported values for SortOrderareASCENDINGandDESCENDING.
- TimePeriod
- 
- Required: Yes
- Type: DateInterval structure
 The time period that you want the usage and costs for. The Startdate must be within 13 months. TheEnddate must be after theStartdate, and before the current date. Future dates can't be used as anEnddate.
Result Syntax
[
    'NextToken' => '<string>',
    'SavingsPlansCoverages' => [
        [
            'Attributes' => ['<string>', ...],
            'Coverage' => [
                'CoveragePercentage' => '<string>',
                'OnDemandCost' => '<string>',
                'SpendCoveredBySavingsPlans' => '<string>',
                'TotalCost' => '<string>',
            ],
            'TimePeriod' => [
                'End' => '<string>',
                'Start' => '<string>',
            ],
        ],
        // ...
    ],
]
	Result Details
Members
- NextToken
- 
- Type: string
 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. 
- SavingsPlansCoverages
- 
- Required: Yes
- Type: Array of SavingsPlansCoverage structures
 The amount of spend that your Savings Plans covered. 
Errors
- LimitExceededException:
- You made too many calls in a short period of time. Try again later. 
- DataUnavailableException:
- The requested data is unavailable. 
- InvalidNextTokenException:
- The pagination token is invalid. Try again without a pagination token. 
GetSavingsPlansPurchaseRecommendation
$result = $client->getSavingsPlansPurchaseRecommendation([/* ... */]); $promise = $client->getSavingsPlansPurchaseRecommendationAsync([/* ... */]);
Retrieves the Savings Plans recommendations for your account. First use StartSavingsPlansPurchaseRecommendationGeneration to generate a new set of recommendations, and then use GetSavingsPlansPurchaseRecommendation to retrieve them.
Parameter Syntax
$result = $client->getSavingsPlansPurchaseRecommendation([
    'AccountScope' => 'PAYER|LINKED',
    'Filter' => [
        'And' => [
            [...], // RECURSIVE
            // ...
        ],
        'CostCategories' => [
            'Key' => '<string>',
            'MatchOptions' => ['<string>', ...],
            'Values' => ['<string>', ...],
        ],
        'Dimensions' => [
            'Key' => 'AZ|INSTANCE_TYPE|LINKED_ACCOUNT|PAYER_ACCOUNT|LINKED_ACCOUNT_NAME|OPERATION|PURCHASE_TYPE|REGION|SERVICE|SERVICE_CODE|USAGE_TYPE|USAGE_TYPE_GROUP|RECORD_TYPE|OPERATING_SYSTEM|TENANCY|SCOPE|PLATFORM|SUBSCRIPTION_ID|LEGAL_ENTITY_NAME|DEPLOYMENT_OPTION|DATABASE_ENGINE|CACHE_ENGINE|INSTANCE_TYPE_FAMILY|BILLING_ENTITY|RESERVATION_ID|RESOURCE_ID|RIGHTSIZING_TYPE|SAVINGS_PLANS_TYPE|SAVINGS_PLAN_ARN|PAYMENT_OPTION|AGREEMENT_END_DATE_TIME_AFTER|AGREEMENT_END_DATE_TIME_BEFORE|INVOICING_ENTITY|ANOMALY_TOTAL_IMPACT_ABSOLUTE|ANOMALY_TOTAL_IMPACT_PERCENTAGE',
            'MatchOptions' => ['<string>', ...],
            'Values' => ['<string>', ...],
        ],
        'Not' => [...], // RECURSIVE
        'Or' => [
            [...], // RECURSIVE
            // ...
        ],
        'Tags' => [
            'Key' => '<string>',
            'MatchOptions' => ['<string>', ...],
            'Values' => ['<string>', ...],
        ],
    ],
    'LookbackPeriodInDays' => 'SEVEN_DAYS|THIRTY_DAYS|SIXTY_DAYS', // REQUIRED
    'NextPageToken' => '<string>',
    'PageSize' => <integer>,
    'PaymentOption' => 'NO_UPFRONT|PARTIAL_UPFRONT|ALL_UPFRONT|LIGHT_UTILIZATION|MEDIUM_UTILIZATION|HEAVY_UTILIZATION', // REQUIRED
    'SavingsPlansType' => 'COMPUTE_SP|EC2_INSTANCE_SP|SAGEMAKER_SP', // REQUIRED
    'TermInYears' => 'ONE_YEAR|THREE_YEARS', // REQUIRED
]);
	Parameter Details
Members
- AccountScope
- 
- Type: string
 The account scope that you want your recommendations for. Amazon Web Services calculates recommendations including the management account and member accounts if the value is set to PAYER. If the value isLINKED, recommendations are calculated for individual member accounts only.
- Filter
- 
- Type: Expression structure
 You can filter your recommendations by Account ID with the LINKED_ACCOUNTdimension. To filter your recommendations by Account ID, specifyKeyasLINKED_ACCOUNTandValueas the comma-separated Acount ID(s) that you want to see Savings Plans purchase recommendations for.For GetSavingsPlansPurchaseRecommendation, the Filterdoesn't includeCostCategoriesorTags. It only includesDimensions. WithDimensions,Keymust beLINKED_ACCOUNTandValuecan be a single Account ID or multiple comma-separated Account IDs that you want to see Savings Plans Purchase Recommendations for.ANDandORoperators are not supported.
- LookbackPeriodInDays
- 
- Required: Yes
- Type: string
 The lookback period that's used to generate the recommendation. 
- NextPageToken
- 
- Type: string
 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. 
- PageSize
- 
- Type: int
 The number of recommendations that you want returned in a single response object. 
- PaymentOption
- 
- Required: Yes
- Type: string
 The payment option that's used to generate these recommendations. 
- SavingsPlansType
- 
- Required: Yes
- Type: string
 The Savings Plans recommendation type that's requested. 
- TermInYears
- 
- Required: Yes
- Type: string
 The savings plan recommendation term that's used to generate these recommendations. 
Result Syntax
[
    'Metadata' => [
        'AdditionalMetadata' => '<string>',
        'GenerationTimestamp' => '<string>',
        'RecommendationId' => '<string>',
    ],
    'NextPageToken' => '<string>',
    'SavingsPlansPurchaseRecommendation' => [
        'AccountScope' => 'PAYER|LINKED',
        'LookbackPeriodInDays' => 'SEVEN_DAYS|THIRTY_DAYS|SIXTY_DAYS',
        'PaymentOption' => 'NO_UPFRONT|PARTIAL_UPFRONT|ALL_UPFRONT|LIGHT_UTILIZATION|MEDIUM_UTILIZATION|HEAVY_UTILIZATION',
        'SavingsPlansPurchaseRecommendationDetails' => [
            [
                'AccountId' => '<string>',
                'CurrencyCode' => '<string>',
                'CurrentAverageHourlyOnDemandSpend' => '<string>',
                'CurrentMaximumHourlyOnDemandSpend' => '<string>',
                'CurrentMinimumHourlyOnDemandSpend' => '<string>',
                'EstimatedAverageUtilization' => '<string>',
                'EstimatedMonthlySavingsAmount' => '<string>',
                'EstimatedOnDemandCost' => '<string>',
                'EstimatedOnDemandCostWithCurrentCommitment' => '<string>',
                'EstimatedROI' => '<string>',
                'EstimatedSPCost' => '<string>',
                'EstimatedSavingsAmount' => '<string>',
                'EstimatedSavingsPercentage' => '<string>',
                'HourlyCommitmentToPurchase' => '<string>',
                'RecommendationDetailId' => '<string>',
                'SavingsPlansDetails' => [
                    'InstanceFamily' => '<string>',
                    'OfferingId' => '<string>',
                    'Region' => '<string>',
                ],
                'UpfrontCost' => '<string>',
            ],
            // ...
        ],
        'SavingsPlansPurchaseRecommendationSummary' => [
            'CurrencyCode' => '<string>',
            'CurrentOnDemandSpend' => '<string>',
            'DailyCommitmentToPurchase' => '<string>',
            'EstimatedMonthlySavingsAmount' => '<string>',
            'EstimatedOnDemandCostWithCurrentCommitment' => '<string>',
            'EstimatedROI' => '<string>',
            'EstimatedSavingsAmount' => '<string>',
            'EstimatedSavingsPercentage' => '<string>',
            'EstimatedTotalCost' => '<string>',
            'HourlyCommitmentToPurchase' => '<string>',
            'TotalRecommendationCount' => '<string>',
        ],
        'SavingsPlansType' => 'COMPUTE_SP|EC2_INSTANCE_SP|SAGEMAKER_SP',
        'TermInYears' => 'ONE_YEAR|THREE_YEARS',
    ],
]
	Result Details
Members
- Metadata
- 
- Type: SavingsPlansPurchaseRecommendationMetadata structure
 Information that regards this specific recommendation set. 
- NextPageToken
- 
- Type: string
 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. 
- SavingsPlansPurchaseRecommendation
- 
- Type: SavingsPlansPurchaseRecommendation structure
 Contains your request parameters, Savings Plan Recommendations Summary, and Details. 
Errors
- LimitExceededException:
- You made too many calls in a short period of time. Try again later. 
- InvalidNextTokenException:
- The pagination token is invalid. Try again without a pagination token. 
GetSavingsPlansUtilization
$result = $client->getSavingsPlansUtilization([/* ... */]); $promise = $client->getSavingsPlansUtilizationAsync([/* ... */]);
Retrieves the Savings Plans utilization for your account across date ranges with daily or monthly granularity. Management account in an organization have access to member accounts. You can use GetDimensionValues in SAVINGS_PLANS to determine the possible dimension values.
You can't group by any dimension values for GetSavingsPlansUtilization.
Parameter Syntax
$result = $client->getSavingsPlansUtilization([
    'Filter' => [
        'And' => [
            [...], // RECURSIVE
            // ...
        ],
        'CostCategories' => [
            'Key' => '<string>',
            'MatchOptions' => ['<string>', ...],
            'Values' => ['<string>', ...],
        ],
        'Dimensions' => [
            'Key' => 'AZ|INSTANCE_TYPE|LINKED_ACCOUNT|PAYER_ACCOUNT|LINKED_ACCOUNT_NAME|OPERATION|PURCHASE_TYPE|REGION|SERVICE|SERVICE_CODE|USAGE_TYPE|USAGE_TYPE_GROUP|RECORD_TYPE|OPERATING_SYSTEM|TENANCY|SCOPE|PLATFORM|SUBSCRIPTION_ID|LEGAL_ENTITY_NAME|DEPLOYMENT_OPTION|DATABASE_ENGINE|CACHE_ENGINE|INSTANCE_TYPE_FAMILY|BILLING_ENTITY|RESERVATION_ID|RESOURCE_ID|RIGHTSIZING_TYPE|SAVINGS_PLANS_TYPE|SAVINGS_PLAN_ARN|PAYMENT_OPTION|AGREEMENT_END_DATE_TIME_AFTER|AGREEMENT_END_DATE_TIME_BEFORE|INVOICING_ENTITY|ANOMALY_TOTAL_IMPACT_ABSOLUTE|ANOMALY_TOTAL_IMPACT_PERCENTAGE',
            'MatchOptions' => ['<string>', ...],
            'Values' => ['<string>', ...],
        ],
        'Not' => [...], // RECURSIVE
        'Or' => [
            [...], // RECURSIVE
            // ...
        ],
        'Tags' => [
            'Key' => '<string>',
            'MatchOptions' => ['<string>', ...],
            'Values' => ['<string>', ...],
        ],
    ],
    'Granularity' => 'DAILY|MONTHLY|HOURLY',
    'SortBy' => [
        'Key' => '<string>', // REQUIRED
        'SortOrder' => 'ASCENDING|DESCENDING',
    ],
    'TimePeriod' => [ // REQUIRED
        'End' => '<string>', // REQUIRED
        'Start' => '<string>', // REQUIRED
    ],
]);
	Parameter Details
Members
- Filter
- 
- Type: Expression structure
 Filters Savings Plans utilization coverage data for active Savings Plans dimensions. You can filter data with the following dimensions: -  LINKED_ACCOUNT
-  SAVINGS_PLAN_ARN
-  SAVINGS_PLANS_TYPE
-  REGION
-  PAYMENT_OPTION
-  INSTANCE_TYPE_FAMILY
 GetSavingsPlansUtilizationuses the same Expression object as the other operations, but onlyANDis supported among each dimension.
- Granularity
- 
- Type: string
 The granularity of the Amazon Web Services utillization data for your Savings Plans. The GetSavingsPlansUtilizationoperation supports onlyDAILYandMONTHLYgranularities.
- SortBy
- 
- Type: SortDefinition structure
 The value that you want to sort the data by. The following values are supported for Key:-  UtilizationPercentage
-  TotalCommitment
-  UsedCommitment
-  UnusedCommitment
-  NetSavings
 The supported values for SortOrderareASCENDINGandDESCENDING.
- TimePeriod
- 
- Required: Yes
- Type: DateInterval structure
 The time period that you want the usage and costs for. The Startdate must be within 13 months. TheEnddate must be after theStartdate, and before the current date. Future dates can't be used as anEnddate.
Result Syntax
[
    'SavingsPlansUtilizationsByTime' => [
        [
            'AmortizedCommitment' => [
                'AmortizedRecurringCommitment' => '<string>',
                'AmortizedUpfrontCommitment' => '<string>',
                'TotalAmortizedCommitment' => '<string>',
            ],
            'Savings' => [
                'NetSavings' => '<string>',
                'OnDemandCostEquivalent' => '<string>',
            ],
            'TimePeriod' => [
                'End' => '<string>',
                'Start' => '<string>',
            ],
            'Utilization' => [
                'TotalCommitment' => '<string>',
                'UnusedCommitment' => '<string>',
                'UsedCommitment' => '<string>',
                'UtilizationPercentage' => '<string>',
            ],
        ],
        // ...
    ],
    'Total' => [
        'AmortizedCommitment' => [
            'AmortizedRecurringCommitment' => '<string>',
            'AmortizedUpfrontCommitment' => '<string>',
            'TotalAmortizedCommitment' => '<string>',
        ],
        'Savings' => [
            'NetSavings' => '<string>',
            'OnDemandCostEquivalent' => '<string>',
        ],
        'Utilization' => [
            'TotalCommitment' => '<string>',
            'UnusedCommitment' => '<string>',
            'UsedCommitment' => '<string>',
            'UtilizationPercentage' => '<string>',
        ],
    ],
]
	Result Details
Members
- SavingsPlansUtilizationsByTime
- 
- Type: Array of SavingsPlansUtilizationByTime structures
 The amount of cost/commitment that you used your Savings Plans. You can use it to specify date ranges. 
- Total
- 
- Required: Yes
- Type: SavingsPlansUtilizationAggregates structure
 The total amount of cost/commitment that you used your Savings Plans, regardless of date ranges. 
Errors
- LimitExceededException:
- You made too many calls in a short period of time. Try again later. 
- DataUnavailableException:
- The requested data is unavailable. 
GetSavingsPlansUtilizationDetails
$result = $client->getSavingsPlansUtilizationDetails([/* ... */]); $promise = $client->getSavingsPlansUtilizationDetailsAsync([/* ... */]);
Retrieves attribute data along with aggregate utilization and savings data for a given time period. This doesn't support granular or grouped data (daily/monthly) in response. You can't retrieve data by dates in a single response similar to GetSavingsPlanUtilization, but you have the option to make multiple calls to GetSavingsPlanUtilizationDetails by providing individual dates. You can use GetDimensionValues in SAVINGS_PLANS to determine the possible dimension values.
 GetSavingsPlanUtilizationDetails internally groups data by SavingsPlansArn.
Parameter Syntax
$result = $client->getSavingsPlansUtilizationDetails([
    'DataType' => ['<string>', ...],
    'Filter' => [
        'And' => [
            [...], // RECURSIVE
            // ...
        ],
        'CostCategories' => [
            'Key' => '<string>',
            'MatchOptions' => ['<string>', ...],
            'Values' => ['<string>', ...],
        ],
        'Dimensions' => [
            'Key' => 'AZ|INSTANCE_TYPE|LINKED_ACCOUNT|PAYER_ACCOUNT|LINKED_ACCOUNT_NAME|OPERATION|PURCHASE_TYPE|REGION|SERVICE|SERVICE_CODE|USAGE_TYPE|USAGE_TYPE_GROUP|RECORD_TYPE|OPERATING_SYSTEM|TENANCY|SCOPE|PLATFORM|SUBSCRIPTION_ID|LEGAL_ENTITY_NAME|DEPLOYMENT_OPTION|DATABASE_ENGINE|CACHE_ENGINE|INSTANCE_TYPE_FAMILY|BILLING_ENTITY|RESERVATION_ID|RESOURCE_ID|RIGHTSIZING_TYPE|SAVINGS_PLANS_TYPE|SAVINGS_PLAN_ARN|PAYMENT_OPTION|AGREEMENT_END_DATE_TIME_AFTER|AGREEMENT_END_DATE_TIME_BEFORE|INVOICING_ENTITY|ANOMALY_TOTAL_IMPACT_ABSOLUTE|ANOMALY_TOTAL_IMPACT_PERCENTAGE',
            'MatchOptions' => ['<string>', ...],
            'Values' => ['<string>', ...],
        ],
        'Not' => [...], // RECURSIVE
        'Or' => [
            [...], // RECURSIVE
            // ...
        ],
        'Tags' => [
            'Key' => '<string>',
            'MatchOptions' => ['<string>', ...],
            'Values' => ['<string>', ...],
        ],
    ],
    'MaxResults' => <integer>,
    'NextToken' => '<string>',
    'SortBy' => [
        'Key' => '<string>', // REQUIRED
        'SortOrder' => 'ASCENDING|DESCENDING',
    ],
    'TimePeriod' => [ // REQUIRED
        'End' => '<string>', // REQUIRED
        'Start' => '<string>', // REQUIRED
    ],
]);
	Parameter Details
Members
- DataType
- 
- Type: Array of strings
 The data type. 
- Filter
- 
- Type: Expression structure
 Filters Savings Plans utilization coverage data for active Savings Plans dimensions. You can filter data with the following dimensions: -  LINKED_ACCOUNT
-  SAVINGS_PLAN_ARN
-  REGION
-  PAYMENT_OPTION
-  INSTANCE_TYPE_FAMILY
 GetSavingsPlansUtilizationDetailsuses the same Expression object as the other operations, but onlyANDis supported among each dimension.
- MaxResults
- 
- Type: int
 The number of items to be returned in a response. The default is 20, with a minimum value of1.
- NextToken
- 
- Type: string
 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
- 
- Type: SortDefinition structure
 The value that you want to sort the data by. The following values are supported for Key:-  UtilizationPercentage
-  TotalCommitment
-  UsedCommitment
-  UnusedCommitment
-  NetSavings
-  AmortizedRecurringCommitment
-  AmortizedUpfrontCommitment
 The supported values for SortOrderareASCENDINGandDESCENDING.
- TimePeriod
- 
- Required: Yes
- Type: DateInterval structure
 The time period that you want the usage and costs for. The Startdate must be within 13 months. TheEnddate must be after theStartdate, and before the current date. Future dates can't be used as anEnddate.
Result Syntax
[
    'NextToken' => '<string>',
    'SavingsPlansUtilizationDetails' => [
        [
            'AmortizedCommitment' => [
                'AmortizedRecurringCommitment' => '<string>',
                'AmortizedUpfrontCommitment' => '<string>',
                'TotalAmortizedCommitment' => '<string>',
            ],
            'Attributes' => ['<string>', ...],
            'Savings' => [
                'NetSavings' => '<string>',
                'OnDemandCostEquivalent' => '<string>',
            ],
            'SavingsPlanArn' => '<string>',
            'Utilization' => [
                'TotalCommitment' => '<string>',
                'UnusedCommitment' => '<string>',
                'UsedCommitment' => '<string>',
                'UtilizationPercentage' => '<string>',
            ],
        ],
        // ...
    ],
    'TimePeriod' => [
        'End' => '<string>',
        'Start' => '<string>',
    ],
    'Total' => [
        'AmortizedCommitment' => [
            'AmortizedRecurringCommitment' => '<string>',
            'AmortizedUpfrontCommitment' => '<string>',
            'TotalAmortizedCommitment' => '<string>',
        ],
        'Savings' => [
            'NetSavings' => '<string>',
            'OnDemandCostEquivalent' => '<string>',
        ],
        'Utilization' => [
            'TotalCommitment' => '<string>',
            'UnusedCommitment' => '<string>',
            'UsedCommitment' => '<string>',
            'UtilizationPercentage' => '<string>',
        ],
    ],
]
	Result Details
Members
- NextToken
- 
- Type: string
 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. 
- SavingsPlansUtilizationDetails
- 
- Required: Yes
- Type: Array of SavingsPlansUtilizationDetail structures
 Retrieves a single daily or monthly Savings Plans utilization rate and details for your account. 
- TimePeriod
- 
- Required: Yes
- Type: DateInterval structure
 The time period of the request. 
- Total
- 
- Type: SavingsPlansUtilizationAggregates structure
 The total Savings Plans utilization, regardless of time period. 
Errors
- LimitExceededException:
- You made too many calls in a short period of time. Try again later. 
- DataUnavailableException:
- The requested data is unavailable. 
- InvalidNextTokenException:
- The pagination token is invalid. Try again without a pagination token. 
GetTags
$result = $client->getTags([/* ... */]); $promise = $client->getTagsAsync([/* ... */]);
Queries for available tag keys and tag values for a specified period. You can search the tag values for an arbitrary string.
Parameter Syntax
$result = $client->getTags([
    'BillingViewArn' => '<string>',
    'Filter' => [
        'And' => [
            [...], // RECURSIVE
            // ...
        ],
        'CostCategories' => [
            'Key' => '<string>',
            'MatchOptions' => ['<string>', ...],
            'Values' => ['<string>', ...],
        ],
        'Dimensions' => [
            'Key' => 'AZ|INSTANCE_TYPE|LINKED_ACCOUNT|PAYER_ACCOUNT|LINKED_ACCOUNT_NAME|OPERATION|PURCHASE_TYPE|REGION|SERVICE|SERVICE_CODE|USAGE_TYPE|USAGE_TYPE_GROUP|RECORD_TYPE|OPERATING_SYSTEM|TENANCY|SCOPE|PLATFORM|SUBSCRIPTION_ID|LEGAL_ENTITY_NAME|DEPLOYMENT_OPTION|DATABASE_ENGINE|CACHE_ENGINE|INSTANCE_TYPE_FAMILY|BILLING_ENTITY|RESERVATION_ID|RESOURCE_ID|RIGHTSIZING_TYPE|SAVINGS_PLANS_TYPE|SAVINGS_PLAN_ARN|PAYMENT_OPTION|AGREEMENT_END_DATE_TIME_AFTER|AGREEMENT_END_DATE_TIME_BEFORE|INVOICING_ENTITY|ANOMALY_TOTAL_IMPACT_ABSOLUTE|ANOMALY_TOTAL_IMPACT_PERCENTAGE',
            'MatchOptions' => ['<string>', ...],
            'Values' => ['<string>', ...],
        ],
        'Not' => [...], // RECURSIVE
        'Or' => [
            [...], // RECURSIVE
            // ...
        ],
        'Tags' => [
            'Key' => '<string>',
            'MatchOptions' => ['<string>', ...],
            'Values' => ['<string>', ...],
        ],
    ],
    'MaxResults' => <integer>,
    'NextPageToken' => '<string>',
    'SearchString' => '<string>',
    'SortBy' => [
        [
            'Key' => '<string>', // REQUIRED
            'SortOrder' => 'ASCENDING|DESCENDING',
        ],
        // ...
    ],
    'TagKey' => '<string>',
    'TimePeriod' => [ // REQUIRED
        'End' => '<string>', // REQUIRED
        'Start' => '<string>', // REQUIRED
    ],
]);
	Parameter Details
Members
- BillingViewArn
- 
- Type: string
 The Amazon Resource Name (ARN) that uniquely identifies a specific billing view. The ARN is used to specify which particular billing view you want to interact with or retrieve information from when making API calls related to Amazon Web Services Billing and Cost Management features. The BillingViewArn can be retrieved by calling the ListBillingViews API. 
- Filter
- 
- Type: Expression structure
 Use Expressionto filter in various Cost Explorer APIs.Not all Expressiontypes are supported in each API. Refer to the documentation for each specific API to see what is supported.There are two patterns: -  Simple dimension values. -  There are three types of simple dimension values: CostCategories,Tags, andDimensions.-  Specify the CostCategoriesfield to define a filter that acts on Cost Categories.
-  Specify the Tagsfield to define a filter that acts on Cost Allocation Tags.
-  Specify the Dimensionsfield to define a filter that acts on theDimensionValues.
 
-  
-  For each filter type, you can set the dimension name and values for the filters that you plan to use. -  For example, you can filter for REGION==us-east-1 OR REGION==us-west-1. ForGetRightsizingRecommendation, the Region is a full name (for example,REGION==US East (N. Virginia).
-  The corresponding Expressionfor this example is as follows:{ "Dimensions": { "Key": "REGION", "Values": [ "us-east-1", "us-west-1" ] } }
-  As shown in the previous example, lists of dimension values are combined with ORwhen applying the filter.
 
-  
-  You can also set different match options to further control how the filter behaves. Not all APIs support match options. Refer to the documentation for each specific API to see what is supported. -  For example, you can filter for linked account names that start with "a". 
-  The corresponding Expressionfor this example is as follows:{ "Dimensions": { "Key": "LINKED_ACCOUNT_NAME", "MatchOptions": [ "STARTS_WITH" ], "Values": [ "a" ] } }
 
-  
 
-  
-  Compound Expressiontypes with logical operations.-  You can use multiple Expressiontypes and the logical operatorsAND/OR/NOTto create a list of one or moreExpressionobjects. By doing this, you can filter by more advanced options.
-  For example, you can filter by ((REGION == us-east-1 OR REGION == us-west-1) OR (TAG.Type == Type1)) AND (USAGE_TYPE != DataTransfer).
-  The corresponding Expressionfor this example is as follows:{ "And": [ {"Or": [ {"Dimensions": { "Key": "REGION", "Values": [ "us-east-1", "us-west-1" ] }}, {"Tags": { "Key": "TagName", "Values": ["Value1"] } } ]}, {"Not": {"Dimensions": { "Key": "USAGE_TYPE", "Values": ["DataTransfer"] }}} ] }
 Because each Expressioncan have only one operator, the service returns an error if more than one is specified. The following example shows anExpressionobject that creates an error:{ "And": [ ... ], "Dimensions": { "Key": "USAGE_TYPE", "Values": [ "DataTransfer" ] } }The following is an example of the corresponding error message: "Expression has more than one roots. Only one root operator is allowed for each expression: And, Or, Not, Dimensions, Tags, CostCategories"
-  
 For the GetRightsizingRecommendationaction, a combination of OR and NOT isn't supported. OR isn't supported between different dimensions, or dimensions and tags. NOT operators aren't supported. Dimensions are also limited toLINKED_ACCOUNT,REGION, orRIGHTSIZING_TYPE.For the GetReservationPurchaseRecommendationaction, only NOT is supported. AND and OR aren't supported. Dimensions are limited toLINKED_ACCOUNT.
- MaxResults
- 
- Type: int
 This field is only used when SortBy is provided in the request. The maximum number of objects that are returned for this request. If MaxResults isn't specified with SortBy, the request returns 1000 results as the default value for this parameter. For GetTags, MaxResults has an upper quota of 1000.
- NextPageToken
- 
- Type: string
 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. 
- SearchString
- 
- Type: string
 The value that you want to search for. 
- SortBy
- 
- Type: Array of SortDefinition structures
 The value that you want to sort the data by. The key represents cost and usage metrics. The following values are supported: -  BlendedCost
-  UnblendedCost
-  AmortizedCost
-  NetAmortizedCost
-  NetUnblendedCost
-  UsageQuantity
-  NormalizedUsageAmount
 The supported values for SortOrderareASCENDINGandDESCENDING.When you use SortBy,NextPageTokenandSearchStringaren't supported.
- TagKey
- 
- Type: string
 The key of the tag that you want to return values for. 
- TimePeriod
- 
- Required: Yes
- Type: DateInterval structure
 The start and end dates for retrieving the dimension values. The start date is inclusive, but the end date is exclusive. For example, if startis2017-01-01andendis2017-05-01, then the cost and usage data is retrieved from2017-01-01up to and including2017-04-30but not including2017-05-01.
Result Syntax
[
    'NextPageToken' => '<string>',
    'ReturnSize' => <integer>,
    'Tags' => ['<string>', ...],
    'TotalSize' => <integer>,
]
	Result Details
Members
- NextPageToken
- 
- Type: string
 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. 
- ReturnSize
- 
- Required: Yes
- Type: int
 The number of query results that Amazon Web Services returns at a time. 
- Tags
- 
- Required: Yes
- Type: Array of strings
 The tags that match your request. 
- TotalSize
- 
- Required: Yes
- Type: int
 The total number of query results. 
Errors
- LimitExceededException:
- You made too many calls in a short period of time. Try again later. 
- BillExpirationException:
- The requested report expired. Update the date interval and try again. 
- DataUnavailableException:
- The requested data is unavailable. 
- InvalidNextTokenException:
- The pagination token is invalid. Try again without a pagination token. 
- RequestChangedException:
- Your request parameters changed between pages. Try again with the old parameters or without a pagination token. 
- ResourceNotFoundException:
- The specified ARN in the request doesn't exist. 
- BillingViewHealthStatusException:
- The billing view status must be - HEALTHYto perform this action. Try again when the status is- HEALTHY.
GetUsageForecast
$result = $client->getUsageForecast([/* ... */]); $promise = $client->getUsageForecastAsync([/* ... */]);
Retrieves a forecast for how much Amazon Web Services predicts that you will use over the forecast time period that you select, based on your past usage.
Parameter Syntax
$result = $client->getUsageForecast([
    'BillingViewArn' => '<string>',
    'Filter' => [
        'And' => [
            [...], // RECURSIVE
            // ...
        ],
        'CostCategories' => [
            'Key' => '<string>',
            'MatchOptions' => ['<string>', ...],
            'Values' => ['<string>', ...],
        ],
        'Dimensions' => [
            'Key' => 'AZ|INSTANCE_TYPE|LINKED_ACCOUNT|PAYER_ACCOUNT|LINKED_ACCOUNT_NAME|OPERATION|PURCHASE_TYPE|REGION|SERVICE|SERVICE_CODE|USAGE_TYPE|USAGE_TYPE_GROUP|RECORD_TYPE|OPERATING_SYSTEM|TENANCY|SCOPE|PLATFORM|SUBSCRIPTION_ID|LEGAL_ENTITY_NAME|DEPLOYMENT_OPTION|DATABASE_ENGINE|CACHE_ENGINE|INSTANCE_TYPE_FAMILY|BILLING_ENTITY|RESERVATION_ID|RESOURCE_ID|RIGHTSIZING_TYPE|SAVINGS_PLANS_TYPE|SAVINGS_PLAN_ARN|PAYMENT_OPTION|AGREEMENT_END_DATE_TIME_AFTER|AGREEMENT_END_DATE_TIME_BEFORE|INVOICING_ENTITY|ANOMALY_TOTAL_IMPACT_ABSOLUTE|ANOMALY_TOTAL_IMPACT_PERCENTAGE',
            'MatchOptions' => ['<string>', ...],
            'Values' => ['<string>', ...],
        ],
        'Not' => [...], // RECURSIVE
        'Or' => [
            [...], // RECURSIVE
            // ...
        ],
        'Tags' => [
            'Key' => '<string>',
            'MatchOptions' => ['<string>', ...],
            'Values' => ['<string>', ...],
        ],
    ],
    'Granularity' => 'DAILY|MONTHLY|HOURLY', // REQUIRED
    'Metric' => 'BLENDED_COST|UNBLENDED_COST|AMORTIZED_COST|NET_UNBLENDED_COST|NET_AMORTIZED_COST|USAGE_QUANTITY|NORMALIZED_USAGE_AMOUNT', // REQUIRED
    'PredictionIntervalLevel' => <integer>,
    'TimePeriod' => [ // REQUIRED
        'End' => '<string>', // REQUIRED
        'Start' => '<string>', // REQUIRED
    ],
]);
	Parameter Details
Members
- BillingViewArn
- 
- Type: string
 The Amazon Resource Name (ARN) that uniquely identifies a specific billing view. The ARN is used to specify which particular billing view you want to interact with or retrieve information from when making API calls related to Amazon Web Services Billing and Cost Management features. The BillingViewArn can be retrieved by calling the ListBillingViews API. 
- Filter
- 
- Type: Expression structure
 The filters that you want to use to filter your forecast. The GetUsageForecastAPI supports filtering by the following dimensions:-  AZ
-  INSTANCE_TYPE
-  LINKED_ACCOUNT
-  LINKED_ACCOUNT_NAME
-  OPERATION
-  PURCHASE_TYPE
-  REGION
-  SERVICE
-  USAGE_TYPE
-  USAGE_TYPE_GROUP
-  RECORD_TYPE
-  OPERATING_SYSTEM
-  TENANCY
-  SCOPE
-  PLATFORM
-  SUBSCRIPTION_ID
-  LEGAL_ENTITY_NAME
-  DEPLOYMENT_OPTION
-  DATABASE_ENGINE
-  INSTANCE_TYPE_FAMILY
-  BILLING_ENTITY
-  RESERVATION_ID
-  SAVINGS_PLAN_ARN
 
- Granularity
- 
- Required: Yes
- Type: string
 How granular you want the forecast to be. You can get 3 months of DAILYforecasts or 12 months ofMONTHLYforecasts.The GetUsageForecastoperation supports onlyDAILYandMONTHLYgranularities.
- Metric
- 
- Required: Yes
- Type: string
 Which metric Cost Explorer uses to create your forecast. Valid values for a GetUsageForecastcall are the following:-  USAGE_QUANTITY 
-  NORMALIZED_USAGE_AMOUNT 
 
- PredictionIntervalLevel
- 
- Type: int
 Amazon Web Services Cost Explorer always returns the mean forecast as a single point. You can request a prediction interval around the mean by specifying a confidence level. The higher the confidence level, the more confident Cost Explorer is about the actual value falling in the prediction interval. Higher confidence levels result in wider prediction intervals. 
- TimePeriod
- 
- Required: Yes
- Type: DateInterval structure
 The start and end dates of the period that you want to retrieve usage forecast for. The start date is included in the period, but the end date isn't included in the period. For example, if startis2017-01-01andendis2017-05-01, then the cost and usage data is retrieved from2017-01-01up to and including2017-04-30but not including2017-05-01. The start date must be equal to or later than the current date to avoid a validation error.
Result Syntax
[
    'ForecastResultsByTime' => [
        [
            'MeanValue' => '<string>',
            'PredictionIntervalLowerBound' => '<string>',
            'PredictionIntervalUpperBound' => '<string>',
            'TimePeriod' => [
                'End' => '<string>',
                'Start' => '<string>',
            ],
        ],
        // ...
    ],
    'Total' => [
        'Amount' => '<string>',
        'Unit' => '<string>',
    ],
]
	Result Details
Members
- ForecastResultsByTime
- 
- Type: Array of ForecastResult structures
 The forecasts for your query, in order. For DAILYforecasts, this is a list of days. ForMONTHLYforecasts, this is a list of months.
- Total
- 
- Type: MetricValue structure
 How much you're forecasted to use over the forecast period. 
Errors
- LimitExceededException:
- You made too many calls in a short period of time. Try again later. 
- DataUnavailableException:
- The requested data is unavailable. 
- UnresolvableUsageUnitException:
- Cost Explorer was unable to identify the usage unit. Provide - UsageType/UsageTypeGroupfilter selections that contain matching units, for example:- hours.
- ResourceNotFoundException:
- The specified ARN in the request doesn't exist. 
- BillingViewHealthStatusException:
- The billing view status must be - HEALTHYto perform this action. Try again when the status is- HEALTHY.
ListCommitmentPurchaseAnalyses
$result = $client->listCommitmentPurchaseAnalyses([/* ... */]); $promise = $client->listCommitmentPurchaseAnalysesAsync([/* ... */]);
Lists the commitment purchase analyses for your account.
Parameter Syntax
$result = $client->listCommitmentPurchaseAnalyses([
    'AnalysisIds' => ['<string>', ...],
    'AnalysisStatus' => 'SUCCEEDED|PROCESSING|FAILED',
    'NextPageToken' => '<string>',
    'PageSize' => <integer>,
]);
	Parameter Details
Members
- AnalysisIds
- 
- Type: Array of strings
 The analysis IDs associated with the commitment purchase analyses. 
- AnalysisStatus
- 
- Type: string
 The status of the analysis. 
- NextPageToken
- 
- Type: string
 The token to retrieve the next set of results. 
- PageSize
- 
- Type: int
 The number of analyses that you want returned in a single response object. 
Result Syntax
[
    'AnalysisSummaryList' => [
        [
            'AnalysisCompletionTime' => '<string>',
            'AnalysisId' => '<string>',
            'AnalysisStartedTime' => '<string>',
            'AnalysisStatus' => 'SUCCEEDED|PROCESSING|FAILED',
            'CommitmentPurchaseAnalysisConfiguration' => [
                'SavingsPlansPurchaseAnalysisConfiguration' => [
                    'AccountId' => '<string>',
                    'AccountScope' => 'PAYER|LINKED',
                    'AnalysisType' => 'MAX_SAVINGS|CUSTOM_COMMITMENT',
                    'LookBackTimePeriod' => [
                        'End' => '<string>',
                        'Start' => '<string>',
                    ],
                    'SavingsPlansToAdd' => [
                        [
                            'InstanceFamily' => '<string>',
                            'OfferingId' => '<string>',
                            'PaymentOption' => 'NO_UPFRONT|PARTIAL_UPFRONT|ALL_UPFRONT|LIGHT_UTILIZATION|MEDIUM_UTILIZATION|HEAVY_UTILIZATION',
                            'Region' => '<string>',
                            'SavingsPlansCommitment' => <float>,
                            'SavingsPlansType' => 'COMPUTE_SP|EC2_INSTANCE_SP|SAGEMAKER_SP',
                            'TermInYears' => 'ONE_YEAR|THREE_YEARS',
                        ],
                        // ...
                    ],
                    'SavingsPlansToExclude' => ['<string>', ...],
                ],
            ],
            'ErrorCode' => 'NO_USAGE_FOUND|INTERNAL_FAILURE|INVALID_SAVINGS_PLANS_TO_ADD|INVALID_SAVINGS_PLANS_TO_EXCLUDE|INVALID_ACCOUNT_ID',
            'EstimatedCompletionTime' => '<string>',
        ],
        // ...
    ],
    'NextPageToken' => '<string>',
]
	Result Details
Members
- AnalysisSummaryList
- 
- Type: Array of AnalysisSummary structures
 The list of analyses. 
- NextPageToken
- 
- Type: string
 The token to retrieve the next set of results. 
Errors
- LimitExceededException:
- You made too many calls in a short period of time. Try again later. 
- InvalidNextTokenException:
- The pagination token is invalid. Try again without a pagination token. 
- DataUnavailableException:
- The requested data is unavailable. 
ListCostAllocationTagBackfillHistory
$result = $client->listCostAllocationTagBackfillHistory([/* ... */]); $promise = $client->listCostAllocationTagBackfillHistoryAsync([/* ... */]);
Retrieves a list of your historical cost allocation tag backfill requests.
Parameter Syntax
$result = $client->listCostAllocationTagBackfillHistory([
    'MaxResults' => <integer>,
    'NextToken' => '<string>',
]);
	Parameter Details
Members
- MaxResults
- 
- Type: int
 The maximum number of objects that are returned for this request. 
- NextToken
- 
- Type: string
 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. 
Result Syntax
[
    'BackfillRequests' => [
        [
            'BackfillFrom' => '<string>',
            'BackfillStatus' => 'SUCCEEDED|PROCESSING|FAILED',
            'CompletedAt' => '<string>',
            'LastUpdatedAt' => '<string>',
            'RequestedAt' => '<string>',
        ],
        // ...
    ],
    'NextToken' => '<string>',
]
	Result Details
Members
- BackfillRequests
- 
- Type: Array of CostAllocationTagBackfillRequest structures
 The list of historical cost allocation tag backfill requests. 
- NextToken
- 
- Type: string
 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. 
Errors
- LimitExceededException:
- You made too many calls in a short period of time. Try again later. 
- InvalidNextTokenException:
- The pagination token is invalid. Try again without a pagination token. 
ListCostAllocationTags
$result = $client->listCostAllocationTags([/* ... */]); $promise = $client->listCostAllocationTagsAsync([/* ... */]);
Get a list of cost allocation tags. All inputs in the API are optional and serve as filters. By default, all cost allocation tags are returned.
Parameter Syntax
$result = $client->listCostAllocationTags([
    'MaxResults' => <integer>,
    'NextToken' => '<string>',
    'Status' => 'Active|Inactive',
    'TagKeys' => ['<string>', ...],
    'Type' => 'AWSGenerated|UserDefined',
]);
	Parameter Details
Members
- MaxResults
- 
- Type: int
 The maximum number of objects that are returned for this request. By default, the request returns 100 results. 
- NextToken
- 
- Type: string
 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. 
- Status
- 
- Type: string
 The status of cost allocation tag keys that are returned for this request. 
- TagKeys
- 
- Type: Array of strings
 The list of cost allocation tag keys that are returned for this request. 
- Type
- 
- Type: string
 The type of CostAllocationTagobject that are returned for this request. TheAWSGeneratedtype tags are tags that Amazon Web Services defines and applies to support Amazon Web Services resources for cost allocation purposes. TheUserDefinedtype tags are tags that you define, create, and apply to resources.
Result Syntax
[
    'CostAllocationTags' => [
        [
            'LastUpdatedDate' => '<string>',
            'LastUsedDate' => '<string>',
            'Status' => 'Active|Inactive',
            'TagKey' => '<string>',
            'Type' => 'AWSGenerated|UserDefined',
        ],
        // ...
    ],
    'NextToken' => '<string>',
]
	Result Details
Members
- CostAllocationTags
- 
- Type: Array of CostAllocationTag structures
 A list of cost allocation tags that includes the detailed metadata for each one. 
- NextToken
- 
- Type: string
 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. 
Errors
- LimitExceededException:
- You made too many calls in a short period of time. Try again later. 
- InvalidNextTokenException:
- The pagination token is invalid. Try again without a pagination token. 
ListCostCategoryDefinitions
$result = $client->listCostCategoryDefinitions([/* ... */]); $promise = $client->listCostCategoryDefinitionsAsync([/* ... */]);
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.
Parameter Syntax
$result = $client->listCostCategoryDefinitions([
    'EffectiveOn' => '<string>',
    'MaxResults' => <integer>,
    'NextToken' => '<string>',
]);
	Parameter Details
Members
- EffectiveOn
- 
- Type: string
 The date when the Cost Category was effective. 
- MaxResults
- 
- Type: int
 The number of entries a paginated response contains. 
- NextToken
- 
- Type: string
 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. 
Result Syntax
[
    'CostCategoryReferences' => [
        [
            'CostCategoryArn' => '<string>',
            'DefaultValue' => '<string>',
            'EffectiveEnd' => '<string>',
            'EffectiveStart' => '<string>',
            'Name' => '<string>',
            'NumberOfRules' => <integer>,
            'ProcessingStatus' => [
                [
                    'Component' => 'COST_EXPLORER',
                    'Status' => 'PROCESSING|APPLIED',
                ],
                // ...
            ],
            'Values' => ['<string>', ...],
        ],
        // ...
    ],
    'NextToken' => '<string>',
]
	Result Details
Members
- CostCategoryReferences
- 
- Type: Array of CostCategoryReference structures
 A reference to a Cost Category that contains enough information to identify the Cost Category. 
- NextToken
- 
- Type: string
 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. 
Errors
- LimitExceededException:
- You made too many calls in a short period of time. Try again later. 
ListSavingsPlansPurchaseRecommendationGeneration
$result = $client->listSavingsPlansPurchaseRecommendationGeneration([/* ... */]); $promise = $client->listSavingsPlansPurchaseRecommendationGenerationAsync([/* ... */]);
Retrieves a list of your historical recommendation generations within the past 30 days.
Parameter Syntax
$result = $client->listSavingsPlansPurchaseRecommendationGeneration([
    'GenerationStatus' => 'SUCCEEDED|PROCESSING|FAILED',
    'NextPageToken' => '<string>',
    'PageSize' => <integer>,
    'RecommendationIds' => ['<string>', ...],
]);
	Parameter Details
Members
- GenerationStatus
- 
- Type: string
 The status of the recommendation generation. 
- NextPageToken
- 
- Type: string
 The token to retrieve the next set of results. 
- PageSize
- 
- Type: int
 The number of recommendations that you want returned in a single response object. 
- RecommendationIds
- 
- Type: Array of strings
 The IDs for each specific recommendation. 
Result Syntax
[
    'GenerationSummaryList' => [
        [
            'EstimatedCompletionTime' => '<string>',
            'GenerationCompletionTime' => '<string>',
            'GenerationStartedTime' => '<string>',
            'GenerationStatus' => 'SUCCEEDED|PROCESSING|FAILED',
            'RecommendationId' => '<string>',
        ],
        // ...
    ],
    'NextPageToken' => '<string>',
]
	Result Details
Members
- GenerationSummaryList
- 
- Type: Array of GenerationSummary structures
 The list of historical recommendation generations. 
- NextPageToken
- 
- Type: string
 The token to retrieve the next set of results. 
Errors
- LimitExceededException:
- You made too many calls in a short period of time. Try again later. 
- InvalidNextTokenException:
- The pagination token is invalid. Try again without a pagination token. 
- DataUnavailableException:
- The requested data is unavailable. 
ListTagsForResource
$result = $client->listTagsForResource([/* ... */]); $promise = $client->listTagsForResourceAsync([/* ... */]);
Returns a list of resource tags associated with the resource specified by the Amazon Resource Name (ARN).
Parameter Syntax
$result = $client->listTagsForResource([
    'ResourceArn' => '<string>', // REQUIRED
]);
	Parameter Details
Members
- ResourceArn
- 
- Required: Yes
- Type: string
 The Amazon Resource Name (ARN) of the resource. For a list of supported resources, see ResourceTag. 
Result Syntax
[
    'ResourceTags' => [
        [
            'Key' => '<string>',
            'Value' => '<string>',
        ],
        // ...
    ],
]
	Result Details
Members
- ResourceTags
- 
- Type: Array of ResourceTag structures
 A list of tag key value pairs that are associated with the resource. 
Errors
- ResourceNotFoundException:
- The specified ARN in the request doesn't exist. 
- LimitExceededException:
- You made too many calls in a short period of time. Try again later. 
ProvideAnomalyFeedback
$result = $client->provideAnomalyFeedback([/* ... */]); $promise = $client->provideAnomalyFeedbackAsync([/* ... */]);
Modifies the feedback property of a given cost anomaly.
Parameter Syntax
$result = $client->provideAnomalyFeedback([
    'AnomalyId' => '<string>', // REQUIRED
    'Feedback' => 'YES|NO|PLANNED_ACTIVITY', // REQUIRED
]);
	Parameter Details
Members
- AnomalyId
- 
- Required: Yes
- Type: string
 A cost anomaly ID. 
- Feedback
- 
- Required: Yes
- Type: string
 Describes whether the cost anomaly was a planned activity or you considered it an anomaly. 
Result Syntax
[
    'AnomalyId' => '<string>',
]
	Result Details
Members
- AnomalyId
- 
- Required: Yes
- Type: string
 The ID of the modified cost anomaly. 
Errors
- LimitExceededException:
- You made too many calls in a short period of time. Try again later. 
StartCommitmentPurchaseAnalysis
$result = $client->startCommitmentPurchaseAnalysis([/* ... */]); $promise = $client->startCommitmentPurchaseAnalysisAsync([/* ... */]);
Specifies the parameters of a planned commitment purchase and starts the generation of the analysis. This enables you to estimate the cost, coverage, and utilization impact of your planned commitment purchases.
Parameter Syntax
$result = $client->startCommitmentPurchaseAnalysis([
    'CommitmentPurchaseAnalysisConfiguration' => [ // REQUIRED
        'SavingsPlansPurchaseAnalysisConfiguration' => [
            'AccountId' => '<string>',
            'AccountScope' => 'PAYER|LINKED',
            'AnalysisType' => 'MAX_SAVINGS|CUSTOM_COMMITMENT', // REQUIRED
            'LookBackTimePeriod' => [ // REQUIRED
                'End' => '<string>', // REQUIRED
                'Start' => '<string>', // REQUIRED
            ],
            'SavingsPlansToAdd' => [ // REQUIRED
                [
                    'InstanceFamily' => '<string>',
                    'OfferingId' => '<string>',
                    'PaymentOption' => 'NO_UPFRONT|PARTIAL_UPFRONT|ALL_UPFRONT|LIGHT_UTILIZATION|MEDIUM_UTILIZATION|HEAVY_UTILIZATION',
                    'Region' => '<string>',
                    'SavingsPlansCommitment' => <float>,
                    'SavingsPlansType' => 'COMPUTE_SP|EC2_INSTANCE_SP|SAGEMAKER_SP',
                    'TermInYears' => 'ONE_YEAR|THREE_YEARS',
                ],
                // ...
            ],
            'SavingsPlansToExclude' => ['<string>', ...],
        ],
    ],
]);
	Parameter Details
Members
- CommitmentPurchaseAnalysisConfiguration
- 
- Required: Yes
- Type: CommitmentPurchaseAnalysisConfiguration structure
 The configuration for the commitment purchase analysis. 
Result Syntax
[
    'AnalysisId' => '<string>',
    'AnalysisStartedTime' => '<string>',
    'EstimatedCompletionTime' => '<string>',
]
	Result Details
Members
- AnalysisId
- 
- Required: Yes
- Type: string
 The analysis ID that's associated with the commitment purchase analysis. 
- AnalysisStartedTime
- 
- Required: Yes
- Type: string
 The start time of the analysis. 
- EstimatedCompletionTime
- 
- Required: Yes
- Type: string
 The estimated time for when the analysis will complete. 
Errors
- LimitExceededException:
- You made too many calls in a short period of time. Try again later. 
- ServiceQuotaExceededException:
- You've reached the limit on the number of resources you can create, or exceeded the size of an individual resource. 
- DataUnavailableException:
- The requested data is unavailable. 
- GenerationExistsException:
- A request to generate a recommendation or analysis is already in progress. 
StartCostAllocationTagBackfill
$result = $client->startCostAllocationTagBackfill([/* ... */]); $promise = $client->startCostAllocationTagBackfillAsync([/* ... */]);
 Request a cost allocation tag backfill. This will backfill the activation status (either active or inactive) for all tag keys from para:BackfillFrom up to the time this request is made.
You can request a backfill once every 24 hours.
Parameter Syntax
$result = $client->startCostAllocationTagBackfill([
    'BackfillFrom' => '<string>', // REQUIRED
]);
	Parameter Details
Members
- BackfillFrom
- 
- Required: Yes
- Type: string
 The date you want the backfill to start from. The date can only be a first day of the month (a billing start date). Dates can't precede the previous twelve months, or in the future. 
Result Syntax
[
    'BackfillRequest' => [
        'BackfillFrom' => '<string>',
        'BackfillStatus' => 'SUCCEEDED|PROCESSING|FAILED',
        'CompletedAt' => '<string>',
        'LastUpdatedAt' => '<string>',
        'RequestedAt' => '<string>',
    ],
]
	Result Details
Members
- BackfillRequest
- 
- Type: CostAllocationTagBackfillRequest structure
 An object containing detailed metadata of your new backfill request. 
Errors
- LimitExceededException:
- You made too many calls in a short period of time. Try again later. 
- BackfillLimitExceededException:
- A request to backfill is already in progress. Once the previous request is complete, you can create another request. 
StartSavingsPlansPurchaseRecommendationGeneration
$result = $client->startSavingsPlansPurchaseRecommendationGeneration([/* ... */]); $promise = $client->startSavingsPlansPurchaseRecommendationGenerationAsync([/* ... */]);
Requests a Savings Plans recommendation generation. This enables you to calculate a fresh set of Savings Plans recommendations that takes your latest usage data and current Savings Plans inventory into account. You can refresh Savings Plans recommendations up to three times daily for a consolidated billing family.
 StartSavingsPlansPurchaseRecommendationGeneration has no request syntax because no input parameters are needed to support this operation.
Parameter Syntax
$result = $client->startSavingsPlansPurchaseRecommendationGeneration([ ]);
Parameter Details
Members
Result Syntax
[
    'EstimatedCompletionTime' => '<string>',
    'GenerationStartedTime' => '<string>',
    'RecommendationId' => '<string>',
]
	Result Details
Members
- EstimatedCompletionTime
- 
- Type: string
 The estimated time for when the recommendation generation will complete. 
- GenerationStartedTime
- 
- Type: string
 The start time of the recommendation generation. 
- RecommendationId
- 
- Type: string
 The ID for this specific recommendation. 
Errors
- LimitExceededException:
- You made too many calls in a short period of time. Try again later. 
- ServiceQuotaExceededException:
- You've reached the limit on the number of resources you can create, or exceeded the size of an individual resource. 
- GenerationExistsException:
- A request to generate a recommendation or analysis is already in progress. 
- DataUnavailableException:
- The requested data is unavailable. 
TagResource
$result = $client->tagResource([/* ... */]); $promise = $client->tagResourceAsync([/* ... */]);
An API operation for adding one or more tags (key-value pairs) to a resource.
You can use the TagResource operation with a resource that already has tags. If you specify a new tag key for the resource, this tag is appended to the list of tags associated with the resource. If you specify a tag key that is already associated with the resource, the new tag value you specify replaces the previous value for that tag.
Although the maximum number of array members is 200, user-tag maximum is 50. The remaining are reserved for Amazon Web Services use.
Parameter Syntax
$result = $client->tagResource([
    'ResourceArn' => '<string>', // REQUIRED
    'ResourceTags' => [ // REQUIRED
        [
            'Key' => '<string>', // REQUIRED
            'Value' => '<string>', // REQUIRED
        ],
        // ...
    ],
]);
	Parameter Details
Members
- ResourceArn
- 
- Required: Yes
- Type: string
 The Amazon Resource Name (ARN) of the resource. For a list of supported resources, see ResourceTag. 
- ResourceTags
- 
- Required: Yes
- Type: Array of ResourceTag structures
 A list of tag key-value pairs to be added to the resource. Each tag consists of a key and a value, and each key must be unique for the resource. The following restrictions apply to resource tags: -  Although the maximum number of array members is 200, you can assign a maximum of 50 user-tags to one resource. The remaining are reserved for Amazon Web Services use 
-  The maximum length of a key is 128 characters 
-  The maximum length of a value is 256 characters 
-  Keys and values can only contain alphanumeric characters, spaces, and any of the following: _.:/=+@-
-  Keys and values are case sensitive 
-  Keys and values are trimmed for any leading or trailing whitespaces 
-  Don’t use aws:as a prefix for your keys. This prefix is reserved for Amazon Web Services use
 
Result Syntax
[]
Result Details
Errors
- ResourceNotFoundException:
- The specified ARN in the request doesn't exist. 
- TooManyTagsException:
- Can occur if you specify a number of tags for a resource greater than the maximum 50 user tags per resource. 
- LimitExceededException:
- You made too many calls in a short period of time. Try again later. 
UntagResource
$result = $client->untagResource([/* ... */]); $promise = $client->untagResourceAsync([/* ... */]);
Removes one or more tags from a resource. Specify only tag keys in your request. Don't specify the value.
Parameter Syntax
$result = $client->untagResource([
    'ResourceArn' => '<string>', // REQUIRED
    'ResourceTagKeys' => ['<string>', ...], // REQUIRED
]);
	Parameter Details
Members
- ResourceArn
- 
- Required: Yes
- Type: string
 The Amazon Resource Name (ARN) of the resource. For a list of supported resources, see ResourceTag. 
- ResourceTagKeys
- 
- Required: Yes
- Type: Array of strings
 A list of tag keys associated with tags that need to be removed from the resource. If you specify a tag key that doesn't exist, it's ignored. Although the maximum number of array members is 200, user-tag maximum is 50. The remaining are reserved for Amazon Web Services use. 
Result Syntax
[]
Result Details
Errors
- ResourceNotFoundException:
- The specified ARN in the request doesn't exist. 
- LimitExceededException:
- You made too many calls in a short period of time. Try again later. 
UpdateAnomalyMonitor
$result = $client->updateAnomalyMonitor([/* ... */]); $promise = $client->updateAnomalyMonitorAsync([/* ... */]);
Updates an existing cost anomaly monitor. The changes made are applied going forward, and doesn't change anomalies detected in the past.
Parameter Syntax
$result = $client->updateAnomalyMonitor([
    'MonitorArn' => '<string>', // REQUIRED
    'MonitorName' => '<string>',
]);
	Parameter Details
Members
- MonitorArn
- 
- Required: Yes
- Type: string
 Cost anomaly monitor Amazon Resource Names (ARNs). 
- MonitorName
- 
- Type: string
 The new name for the cost anomaly monitor. 
Result Syntax
[
    'MonitorArn' => '<string>',
]
	Result Details
Members
- MonitorArn
- 
- Required: Yes
- Type: string
 A cost anomaly monitor ARN. 
Errors
- LimitExceededException:
- You made too many calls in a short period of time. Try again later. 
- UnknownMonitorException:
- The cost anomaly monitor does not exist for the account. 
UpdateAnomalySubscription
$result = $client->updateAnomalySubscription([/* ... */]); $promise = $client->updateAnomalySubscriptionAsync([/* ... */]);
Updates an existing cost anomaly subscription. Specify the fields that you want to update. Omitted fields are unchanged.
The JSON below describes the generic construct for each type. See Request Parameters for possible values as they apply to AnomalySubscription.
Parameter Syntax
$result = $client->updateAnomalySubscription([
    'Frequency' => 'DAILY|IMMEDIATE|WEEKLY',
    'MonitorArnList' => ['<string>', ...],
    'Subscribers' => [
        [
            'Address' => '<string>',
            'Status' => 'CONFIRMED|DECLINED',
            'Type' => 'EMAIL|SNS',
        ],
        // ...
    ],
    'SubscriptionArn' => '<string>', // REQUIRED
    'SubscriptionName' => '<string>',
    'Threshold' => <float>,
    'ThresholdExpression' => [
        'And' => [
            [...], // RECURSIVE
            // ...
        ],
        'CostCategories' => [
            'Key' => '<string>',
            'MatchOptions' => ['<string>', ...],
            'Values' => ['<string>', ...],
        ],
        'Dimensions' => [
            'Key' => 'AZ|INSTANCE_TYPE|LINKED_ACCOUNT|PAYER_ACCOUNT|LINKED_ACCOUNT_NAME|OPERATION|PURCHASE_TYPE|REGION|SERVICE|SERVICE_CODE|USAGE_TYPE|USAGE_TYPE_GROUP|RECORD_TYPE|OPERATING_SYSTEM|TENANCY|SCOPE|PLATFORM|SUBSCRIPTION_ID|LEGAL_ENTITY_NAME|DEPLOYMENT_OPTION|DATABASE_ENGINE|CACHE_ENGINE|INSTANCE_TYPE_FAMILY|BILLING_ENTITY|RESERVATION_ID|RESOURCE_ID|RIGHTSIZING_TYPE|SAVINGS_PLANS_TYPE|SAVINGS_PLAN_ARN|PAYMENT_OPTION|AGREEMENT_END_DATE_TIME_AFTER|AGREEMENT_END_DATE_TIME_BEFORE|INVOICING_ENTITY|ANOMALY_TOTAL_IMPACT_ABSOLUTE|ANOMALY_TOTAL_IMPACT_PERCENTAGE',
            'MatchOptions' => ['<string>', ...],
            'Values' => ['<string>', ...],
        ],
        'Not' => [...], // RECURSIVE
        'Or' => [
            [...], // RECURSIVE
            // ...
        ],
        'Tags' => [
            'Key' => '<string>',
            'MatchOptions' => ['<string>', ...],
            'Values' => ['<string>', ...],
        ],
    ],
]);
	Parameter Details
Members
- Frequency
- 
- Type: string
 The update to the frequency value that subscribers receive notifications. 
- MonitorArnList
- 
- Type: Array of strings
 A list of cost anomaly monitor ARNs. 
- Subscribers
- 
- Type: Array of Subscriber structures
 The update to the subscriber list. 
- SubscriptionArn
- 
- Required: Yes
- Type: string
 A cost anomaly subscription Amazon Resource Name (ARN). 
- SubscriptionName
- 
- Type: string
 The new name of the subscription. 
- Threshold
- 
- Type: double
 (deprecated) The update to the threshold value for receiving notifications. This field has been deprecated. To update a threshold, use ThresholdExpression. Continued use of Threshold will be treated as shorthand syntax for a ThresholdExpression. You can specify either Threshold or ThresholdExpression, but not both. 
- ThresholdExpression
- 
- Type: Expression structure
 The update to the Expression object used to specify the anomalies that you want to generate alerts for. This supports dimensions and nested expressions. The supported dimensions are ANOMALY_TOTAL_IMPACT_ABSOLUTEandANOMALY_TOTAL_IMPACT_PERCENTAGE, corresponding to an anomaly’s TotalImpact and TotalImpactPercentage, respectively (see Impact for more details). The supported nested expression types areANDandOR. The match optionGREATER_THAN_OR_EQUALis required. Values must be numbers between 0 and 10,000,000,000 in string format.You can specify either Threshold or ThresholdExpression, but not both. The following are examples of valid ThresholdExpressions: -  Absolute threshold: { "Dimensions": { "Key": "ANOMALY_TOTAL_IMPACT_ABSOLUTE", "MatchOptions": [ "GREATER_THAN_OR_EQUAL" ], "Values": [ "100" ] } }
-  Percentage threshold: { "Dimensions": { "Key": "ANOMALY_TOTAL_IMPACT_PERCENTAGE", "MatchOptions": [ "GREATER_THAN_OR_EQUAL" ], "Values": [ "100" ] } }
-  ANDtwo thresholds together:{ "And": [ { "Dimensions": { "Key": "ANOMALY_TOTAL_IMPACT_ABSOLUTE", "MatchOptions": [ "GREATER_THAN_OR_EQUAL" ], "Values": [ "100" ] } }, { "Dimensions": { "Key": "ANOMALY_TOTAL_IMPACT_PERCENTAGE", "MatchOptions": [ "GREATER_THAN_OR_EQUAL" ], "Values": [ "100" ] } } ] }
-  ORtwo thresholds together:{ "Or": [ { "Dimensions": { "Key": "ANOMALY_TOTAL_IMPACT_ABSOLUTE", "MatchOptions": [ "GREATER_THAN_OR_EQUAL" ], "Values": [ "100" ] } }, { "Dimensions": { "Key": "ANOMALY_TOTAL_IMPACT_PERCENTAGE", "MatchOptions": [ "GREATER_THAN_OR_EQUAL" ], "Values": [ "100" ] } } ] }
 
Result Syntax
[
    'SubscriptionArn' => '<string>',
]
	Result Details
Members
- SubscriptionArn
- 
- Required: Yes
- Type: string
 A cost anomaly subscription ARN. 
Errors
- LimitExceededException:
- You made too many calls in a short period of time. Try again later. 
- UnknownMonitorException:
- The cost anomaly monitor does not exist for the account. 
- UnknownSubscriptionException:
- The cost anomaly subscription does not exist for the account. 
UpdateCostAllocationTagsStatus
$result = $client->updateCostAllocationTagsStatus([/* ... */]); $promise = $client->updateCostAllocationTagsStatusAsync([/* ... */]);
Updates status for cost allocation tags in bulk, with maximum batch size of 20. If the tag status that's updated is the same as the existing tag status, the request doesn't fail. Instead, it doesn't have any effect on the tag status (for example, activating the active tag).
Parameter Syntax
$result = $client->updateCostAllocationTagsStatus([
    'CostAllocationTagsStatus' => [ // REQUIRED
        [
            'Status' => 'Active|Inactive', // REQUIRED
            'TagKey' => '<string>', // REQUIRED
        ],
        // ...
    ],
]);
	Parameter Details
Members
- CostAllocationTagsStatus
- 
- Required: Yes
- Type: Array of CostAllocationTagStatusEntry structures
 The list of CostAllocationTagStatusEntryobjects that are used to update cost allocation tags status for this request.
Result Syntax
[
    'Errors' => [
        [
            'Code' => '<string>',
            'Message' => '<string>',
            'TagKey' => '<string>',
        ],
        // ...
    ],
]
	Result Details
Members
- Errors
- 
- Type: Array of UpdateCostAllocationTagsStatusError structures
 A list of UpdateCostAllocationTagsStatusErrorobjects with error details about each cost allocation tag that can't be updated. If there's no failure, an empty array returns.
Errors
- LimitExceededException:
- You made too many calls in a short period of time. Try again later. 
UpdateCostCategoryDefinition
$result = $client->updateCostCategoryDefinition([/* ... */]); $promise = $client->updateCostCategoryDefinitionAsync([/* ... */]);
Updates an existing Cost Category. Changes made to the Cost Category rules will be used to categorize the current month’s expenses and future expenses. This won’t change categorization for the previous months.
Parameter Syntax
$result = $client->updateCostCategoryDefinition([
    'CostCategoryArn' => '<string>', // REQUIRED
    'DefaultValue' => '<string>',
    'EffectiveStart' => '<string>',
    'RuleVersion' => 'CostCategoryExpression.v1', // REQUIRED
    'Rules' => [ // REQUIRED
        [
            'InheritedValue' => [
                'DimensionKey' => '<string>',
                'DimensionName' => 'LINKED_ACCOUNT_NAME|TAG',
            ],
            'Rule' => [
                'And' => [
                    [...], // RECURSIVE
                    // ...
                ],
                'CostCategories' => [
                    'Key' => '<string>',
                    'MatchOptions' => ['<string>', ...],
                    'Values' => ['<string>', ...],
                ],
                'Dimensions' => [
                    'Key' => 'AZ|INSTANCE_TYPE|LINKED_ACCOUNT|PAYER_ACCOUNT|LINKED_ACCOUNT_NAME|OPERATION|PURCHASE_TYPE|REGION|SERVICE|SERVICE_CODE|USAGE_TYPE|USAGE_TYPE_GROUP|RECORD_TYPE|OPERATING_SYSTEM|TENANCY|SCOPE|PLATFORM|SUBSCRIPTION_ID|LEGAL_ENTITY_NAME|DEPLOYMENT_OPTION|DATABASE_ENGINE|CACHE_ENGINE|INSTANCE_TYPE_FAMILY|BILLING_ENTITY|RESERVATION_ID|RESOURCE_ID|RIGHTSIZING_TYPE|SAVINGS_PLANS_TYPE|SAVINGS_PLAN_ARN|PAYMENT_OPTION|AGREEMENT_END_DATE_TIME_AFTER|AGREEMENT_END_DATE_TIME_BEFORE|INVOICING_ENTITY|ANOMALY_TOTAL_IMPACT_ABSOLUTE|ANOMALY_TOTAL_IMPACT_PERCENTAGE',
                    'MatchOptions' => ['<string>', ...],
                    'Values' => ['<string>', ...],
                ],
                'Not' => [...], // RECURSIVE
                'Or' => [
                    [...], // RECURSIVE
                    // ...
                ],
                'Tags' => [
                    'Key' => '<string>',
                    'MatchOptions' => ['<string>', ...],
                    'Values' => ['<string>', ...],
                ],
            ],
            'Type' => 'REGULAR|INHERITED_VALUE',
            'Value' => '<string>',
        ],
        // ...
    ],
    'SplitChargeRules' => [
        [
            'Method' => 'FIXED|PROPORTIONAL|EVEN', // REQUIRED
            'Parameters' => [
                [
                    'Type' => 'ALLOCATION_PERCENTAGES', // REQUIRED
                    'Values' => ['<string>', ...], // REQUIRED
                ],
                // ...
            ],
            'Source' => '<string>', // REQUIRED
            'Targets' => ['<string>', ...], // REQUIRED
        ],
        // ...
    ],
]);
	Parameter Details
Members
- CostCategoryArn
- 
- Required: Yes
- Type: string
 The unique identifier for your Cost Category. 
- DefaultValue
- 
- Type: string
 The default value for the cost category. 
- EffectiveStart
- 
- Type: string
 The Cost Category's effective start date. It can only be a billing start date (first day of the month). If the date isn't provided, it's the first day of the current month. Dates can't be before the previous twelve months, or in the future. 
- RuleVersion
- 
- Required: Yes
- Type: string
 The rule schema version in this particular Cost Category. 
- Rules
- 
- Required: Yes
- Type: Array of CostCategoryRule structures
 The Expressionobject used to categorize costs. For more information, see CostCategoryRule .
- SplitChargeRules
- 
- Type: Array of CostCategorySplitChargeRule structures
 The split charge rules used to allocate your charges between your Cost Category values. 
Result Syntax
[
    'CostCategoryArn' => '<string>',
    'EffectiveStart' => '<string>',
]
	Result Details
Members
- CostCategoryArn
- 
- Type: string
 The unique identifier for your Cost Category. 
- EffectiveStart
- 
- Type: string
 The Cost Category's effective start date. It can only be a billing start date (first day of the month). 
Errors
- ResourceNotFoundException:
- The specified ARN in the request doesn't exist. 
- ServiceQuotaExceededException:
- You've reached the limit on the number of resources you can create, or exceeded the size of an individual resource. 
- LimitExceededException:
- You made too many calls in a short period of time. Try again later. 
Shapes
AnalysisDetails
Description
Details about the analysis.
Members
- SavingsPlansPurchaseAnalysisDetails
- 
- Type: SavingsPlansPurchaseAnalysisDetails structure
 Details about the Savings Plans purchase analysis. 
AnalysisNotFoundException
Description
The requested analysis can't be found.
Members
- Message
- 
- Type: string
 
AnalysisSummary
Description
A summary of the analysis.
Members
- AnalysisCompletionTime
- 
- Type: string
 The completion time of the analysis. 
- AnalysisId
- 
- Type: string
 The analysis ID that's associated with the commitment purchase analysis. 
- AnalysisStartedTime
- 
- Type: string
 The start time of the analysis. 
- AnalysisStatus
- 
- Type: string
 The status of the analysis. 
- CommitmentPurchaseAnalysisConfiguration
- 
- Type: CommitmentPurchaseAnalysisConfiguration structure
 The configuration for the commitment purchase analysis. 
- ErrorCode
- 
- Type: string
 The error code used for the analysis. 
- EstimatedCompletionTime
- 
- Type: string
 The estimated time for when the analysis will complete. 
Anomaly
Description
An unusual cost pattern. This consists of the detailed metadata and the current status of the anomaly object.
Members
- AnomalyEndDate
- 
- Type: string
 The last day the anomaly is detected. 
- AnomalyId
- 
- Required: Yes
- Type: string
 The unique identifier for the anomaly. 
- AnomalyScore
- 
- Required: Yes
- Type: AnomalyScore structure
 The latest and maximum score for the anomaly. 
- AnomalyStartDate
- 
- Type: string
 The first day the anomaly is detected. 
- DimensionValue
- 
- Type: string
 The dimension for the anomaly (for example, an Amazon Web Services service in a service monitor). 
- Feedback
- 
- Type: string
 The feedback value. 
- Impact
- 
- Required: Yes
- Type: Impact structure
 The dollar impact for the anomaly. 
- MonitorArn
- 
- Required: Yes
- Type: string
 The Amazon Resource Name (ARN) for the cost monitor that generated this anomaly. 
- RootCauses
- 
- Type: Array of RootCause structures
 The list of identified root causes for the anomaly. 
AnomalyDateInterval
Description
The time period for an anomaly.
Members
- EndDate
- 
- Type: string
 The last date an anomaly was observed. 
- StartDate
- 
- Required: Yes
- Type: string
 The first date an anomaly was observed. 
AnomalyMonitor
Description
This object continuously inspects your account's cost data for anomalies. It's based on MonitorType and MonitorSpecification. The content consists of detailed metadata and the current status of the monitor object. 
Members
- CreationDate
- 
- Type: string
 The date when the monitor was created. 
- DimensionalValueCount
- 
- Type: int
 The value for evaluated dimensions. 
- LastEvaluatedDate
- 
- Type: string
 The date when the monitor last evaluated for anomalies. 
- LastUpdatedDate
- 
- Type: string
 The date when the monitor was last updated. 
- MonitorArn
- 
- Type: string
 The Amazon Resource Name (ARN) value. 
- MonitorDimension
- 
- Type: string
 The dimensions to evaluate. 
- MonitorName
- 
- Required: Yes
- Type: string
 The name of the monitor. 
- MonitorSpecification
- 
- Type: Expression structure
 Use Expressionto filter in various Cost Explorer APIs.Not all Expressiontypes are supported in each API. Refer to the documentation for each specific API to see what is supported.There are two patterns: -  Simple dimension values. -  There are three types of simple dimension values: CostCategories,Tags, andDimensions.-  Specify the CostCategoriesfield to define a filter that acts on Cost Categories.
-  Specify the Tagsfield to define a filter that acts on Cost Allocation Tags.
-  Specify the Dimensionsfield to define a filter that acts on theDimensionValues.
 
-  
-  For each filter type, you can set the dimension name and values for the filters that you plan to use. -  For example, you can filter for REGION==us-east-1 OR REGION==us-west-1. ForGetRightsizingRecommendation, the Region is a full name (for example,REGION==US East (N. Virginia).
-  The corresponding Expressionfor this example is as follows:{ "Dimensions": { "Key": "REGION", "Values": [ "us-east-1", "us-west-1" ] } }
-  As shown in the previous example, lists of dimension values are combined with ORwhen applying the filter.
 
-  
-  You can also set different match options to further control how the filter behaves. Not all APIs support match options. Refer to the documentation for each specific API to see what is supported. -  For example, you can filter for linked account names that start with "a". 
-  The corresponding Expressionfor this example is as follows:{ "Dimensions": { "Key": "LINKED_ACCOUNT_NAME", "MatchOptions": [ "STARTS_WITH" ], "Values": [ "a" ] } }
 
-  
 
-  
-  Compound Expressiontypes with logical operations.-  You can use multiple Expressiontypes and the logical operatorsAND/OR/NOTto create a list of one or moreExpressionobjects. By doing this, you can filter by more advanced options.
-  For example, you can filter by ((REGION == us-east-1 OR REGION == us-west-1) OR (TAG.Type == Type1)) AND (USAGE_TYPE != DataTransfer).
-  The corresponding Expressionfor this example is as follows:{ "And": [ {"Or": [ {"Dimensions": { "Key": "REGION", "Values": [ "us-east-1", "us-west-1" ] }}, {"Tags": { "Key": "TagName", "Values": ["Value1"] } } ]}, {"Not": {"Dimensions": { "Key": "USAGE_TYPE", "Values": ["DataTransfer"] }}} ] }
 Because each Expressioncan have only one operator, the service returns an error if more than one is specified. The following example shows anExpressionobject that creates an error:{ "And": [ ... ], "Dimensions": { "Key": "USAGE_TYPE", "Values": [ "DataTransfer" ] } }The following is an example of the corresponding error message: "Expression has more than one roots. Only one root operator is allowed for each expression: And, Or, Not, Dimensions, Tags, CostCategories"
-  
 For the GetRightsizingRecommendationaction, a combination of OR and NOT isn't supported. OR isn't supported between different dimensions, or dimensions and tags. NOT operators aren't supported. Dimensions are also limited toLINKED_ACCOUNT,REGION, orRIGHTSIZING_TYPE.For the GetReservationPurchaseRecommendationaction, only NOT is supported. AND and OR aren't supported. Dimensions are limited toLINKED_ACCOUNT.
- MonitorType
- 
- Required: Yes
- Type: string
 The possible type values. 
AnomalyScore
Description
Quantifies the anomaly. The higher score means that it's more anomalous.
Members
- CurrentScore
- 
- Required: Yes
- Type: double
 The last observed score. 
- MaxScore
- 
- Required: Yes
- Type: double
 The maximum score that's observed during the AnomalyDateInterval.
AnomalySubscription
Description
An AnomalySubscription resource (also referred to as an alert subscription) sends notifications about specific anomalies that meet an alerting criteria defined by you.
You can specify the frequency of the alerts and the subscribers to notify.
Anomaly subscriptions can be associated with one or more  AnomalyMonitor  resources, and they only send notifications about anomalies detected by those associated monitors. You can also configure a threshold to further control which anomalies are included in the notifications.
Anomalies that don’t exceed the chosen threshold and therefore don’t trigger notifications from an anomaly subscription will still be available on the console and from the  GetAnomalies  API.
Members
- AccountId
- 
- Type: string
 Your unique account identifier. 
- Frequency
- 
- Required: Yes
- Type: string
 The frequency that anomaly notifications are sent. Notifications are sent either over email (for DAILY and WEEKLY frequencies) or SNS (for IMMEDIATE frequency). For more information, see Creating an Amazon SNS topic for anomaly notifications. 
- MonitorArnList
- 
- Required: Yes
- Type: Array of strings
 A list of cost anomaly monitors. 
- Subscribers
- 
- Required: Yes
- Type: Array of Subscriber structures
 A list of subscribers to notify. 
- SubscriptionArn
- 
- Type: string
 The AnomalySubscriptionAmazon Resource Name (ARN).
- SubscriptionName
- 
- Required: Yes
- Type: string
 The name for the subscription. 
- Threshold
- 
- Type: double
 (deprecated) An absolute dollar value that must be exceeded by the anomaly's total impact (see Impact for more details) for an anomaly notification to be generated. This field has been deprecated. To specify a threshold, use ThresholdExpression. Continued use of Threshold will be treated as shorthand syntax for a ThresholdExpression. One of Threshold or ThresholdExpression is required for this resource. You cannot specify both. 
- ThresholdExpression
- 
- Type: Expression structure
 An Expression object used to specify the anomalies that you want to generate alerts for. This supports dimensions and nested expressions. The supported dimensions are ANOMALY_TOTAL_IMPACT_ABSOLUTEandANOMALY_TOTAL_IMPACT_PERCENTAGE, corresponding to an anomaly’s TotalImpact and TotalImpactPercentage, respectively (see Impact for more details). The supported nested expression types areANDandOR. The match optionGREATER_THAN_OR_EQUALis required. Values must be numbers between 0 and 10,000,000,000 in string format.One of Threshold or ThresholdExpression is required for this resource. You cannot specify both. The following are examples of valid ThresholdExpressions: -  Absolute threshold: { "Dimensions": { "Key": "ANOMALY_TOTAL_IMPACT_ABSOLUTE", "MatchOptions": [ "GREATER_THAN_OR_EQUAL" ], "Values": [ "100" ] } }
-  Percentage threshold: { "Dimensions": { "Key": "ANOMALY_TOTAL_IMPACT_PERCENTAGE", "MatchOptions": [ "GREATER_THAN_OR_EQUAL" ], "Values": [ "100" ] } }
-  ANDtwo thresholds together:{ "And": [ { "Dimensions": { "Key": "ANOMALY_TOTAL_IMPACT_ABSOLUTE", "MatchOptions": [ "GREATER_THAN_OR_EQUAL" ], "Values": [ "100" ] } }, { "Dimensions": { "Key": "ANOMALY_TOTAL_IMPACT_PERCENTAGE", "MatchOptions": [ "GREATER_THAN_OR_EQUAL" ], "Values": [ "100" ] } } ] }
-  ORtwo thresholds together:{ "Or": [ { "Dimensions": { "Key": "ANOMALY_TOTAL_IMPACT_ABSOLUTE", "MatchOptions": [ "GREATER_THAN_OR_EQUAL" ], "Values": [ "100" ] } }, { "Dimensions": { "Key": "ANOMALY_TOTAL_IMPACT_PERCENTAGE", "MatchOptions": [ "GREATER_THAN_OR_EQUAL" ], "Values": [ "100" ] } } ] }
 
BackfillLimitExceededException
Description
A request to backfill is already in progress. Once the previous request is complete, you can create another request.
Members
- Message
- 
- Type: string
 
BillExpirationException
Description
The requested report expired. Update the date interval and try again.
Members
- Message
- 
- Type: string
 
BillingViewHealthStatusException
Description
 The billing view status must be HEALTHY to perform this action. Try again when the status is HEALTHY. 
Members
- Message
- 
- Type: string
 
CommitmentPurchaseAnalysisConfiguration
Description
The configuration for the commitment purchase analysis.
Members
- SavingsPlansPurchaseAnalysisConfiguration
- 
- Type: SavingsPlansPurchaseAnalysisConfiguration structure
 The configuration for the Savings Plans purchase analysis. 
ComparisonMetricValue
Description
Contains cost or usage metric values for comparing two time periods. Each value includes amounts for the baseline and comparison time periods, their difference, and the unit of measurement.
Members
- BaselineTimePeriodAmount
- 
- Type: string
 The numeric value for the baseline time period measurement. 
- ComparisonTimePeriodAmount
- 
- Type: string
 The numeric value for the comparison time period measurement. 
- Difference
- 
- Type: string
 The calculated difference between ComparisonTimePeriodAmountandBaselineTimePeriodAmount.
- Unit
- 
- Type: string
 The unit of measurement applicable to all numeric values in this comparison. 
CostAllocationTag
Description
The cost allocation tag structure. This includes detailed metadata for the CostAllocationTag object. 
Members
- LastUpdatedDate
- 
- Type: string
 The last date that the tag was either activated or deactivated. 
- LastUsedDate
- 
- Type: string
 The last month that the tag was used on an Amazon Web Services resource. 
- Status
- 
- Required: Yes
- Type: string
 The status of a cost allocation tag. 
- TagKey
- 
- Required: Yes
- Type: string
 The key for the cost allocation tag. 
- Type
- 
- Required: Yes
- Type: string
 The type of cost allocation tag. You can use AWSGeneratedorUserDefinedtype tags.AWSGeneratedtype tags are tags that Amazon Web Services defines and applies to support Amazon Web Services resources for cost allocation purposes.UserDefinedtype tags are tags that you define, create, and apply to resources.
CostAllocationTagBackfillRequest
Description
The cost allocation tag backfill request structure that contains metadata and details of a certain backfill.
Members
- BackfillFrom
- 
- Type: string
 The date the backfill starts from. 
- BackfillStatus
- 
- Type: string
 The status of the cost allocation tag backfill request. 
- CompletedAt
- 
- Type: string
 The backfill completion time. 
- LastUpdatedAt
- 
- Type: string
 The time when the backfill status was last updated. 
- RequestedAt
- 
- Type: string
 The time when the backfill was requested. 
CostAllocationTagStatusEntry
Description
The cost allocation tag status. The status of a key can either be active or inactive.
Members
- Status
- 
- Required: Yes
- Type: string
 The status of a cost allocation tag. 
- TagKey
- 
- Required: Yes
- Type: string
 The key for the cost allocation tag. 
CostAndUsageComparison
Description
Represents a comparison of cost and usage metrics between two time periods.
Members
- CostAndUsageSelector
- 
- Type: Expression structure
 Use Expressionto filter in various Cost Explorer APIs.Not all Expressiontypes are supported in each API. Refer to the documentation for each specific API to see what is supported.There are two patterns: -  Simple dimension values. -  There are three types of simple dimension values: CostCategories,Tags, andDimensions.-  Specify the CostCategoriesfield to define a filter that acts on Cost Categories.
-  Specify the Tagsfield to define a filter that acts on Cost Allocation Tags.
-  Specify the Dimensionsfield to define a filter that acts on theDimensionValues.
 
-  
-  For each filter type, you can set the dimension name and values for the filters that you plan to use. -  For example, you can filter for REGION==us-east-1 OR REGION==us-west-1. ForGetRightsizingRecommendation, the Region is a full name (for example,REGION==US East (N. Virginia).
-  The corresponding Expressionfor this example is as follows:{ "Dimensions": { "Key": "REGION", "Values": [ "us-east-1", "us-west-1" ] } }
-  As shown in the previous example, lists of dimension values are combined with ORwhen applying the filter.
 
-  
-  You can also set different match options to further control how the filter behaves. Not all APIs support match options. Refer to the documentation for each specific API to see what is supported. -  For example, you can filter for linked account names that start with "a". 
-  The corresponding Expressionfor this example is as follows:{ "Dimensions": { "Key": "LINKED_ACCOUNT_NAME", "MatchOptions": [ "STARTS_WITH" ], "Values": [ "a" ] } }
 
-  
 
-  
-  Compound Expressiontypes with logical operations.-  You can use multiple Expressiontypes and the logical operatorsAND/OR/NOTto create a list of one or moreExpressionobjects. By doing this, you can filter by more advanced options.
-  For example, you can filter by ((REGION == us-east-1 OR REGION == us-west-1) OR (TAG.Type == Type1)) AND (USAGE_TYPE != DataTransfer).
-  The corresponding Expressionfor this example is as follows:{ "And": [ {"Or": [ {"Dimensions": { "Key": "REGION", "Values": [ "us-east-1", "us-west-1" ] }}, {"Tags": { "Key": "TagName", "Values": ["Value1"] } } ]}, {"Not": {"Dimensions": { "Key": "USAGE_TYPE", "Values": ["DataTransfer"] }}} ] }
 Because each Expressioncan have only one operator, the service returns an error if more than one is specified. The following example shows anExpressionobject that creates an error:{ "And": [ ... ], "Dimensions": { "Key": "USAGE_TYPE", "Values": [ "DataTransfer" ] } }The following is an example of the corresponding error message: "Expression has more than one roots. Only one root operator is allowed for each expression: And, Or, Not, Dimensions, Tags, CostCategories"
-  
 For the GetRightsizingRecommendationaction, a combination of OR and NOT isn't supported. OR isn't supported between different dimensions, or dimensions and tags. NOT operators aren't supported. Dimensions are also limited toLINKED_ACCOUNT,REGION, orRIGHTSIZING_TYPE.For the GetReservationPurchaseRecommendationaction, only NOT is supported. AND and OR aren't supported. Dimensions are limited toLINKED_ACCOUNT.
- Metrics
- 
- Type: Associative array of custom strings keys (MetricName) to ComparisonMetricValue structures
 A mapping of metric names to their comparison values. 
CostCategory
Description
The structure of Cost Categories. This includes detailed metadata and the set of rules for the CostCategory object.
Members
- CostCategoryArn
- 
- Required: Yes
- Type: string
 The unique identifier for your Cost Category. 
- DefaultValue
- 
- Type: string
 The default value for the cost category. 
- EffectiveEnd
- 
- Type: string
 The effective end date of your Cost Category. 
- EffectiveStart
- 
- Required: Yes
- Type: string
 The effective start date of your Cost Category. 
- Name
- 
- Required: Yes
- Type: string
 The unique name of the Cost Category. 
- ProcessingStatus
- 
- Type: Array of CostCategoryProcessingStatus structures
 The list of processing statuses for Cost Management products for a specific cost category. 
- RuleVersion
- 
- Required: Yes
- Type: string
 The rule schema version in this particular Cost Category. 
- Rules
- 
- Required: Yes
- Type: Array of CostCategoryRule structures
 The rules are processed in order. If there are multiple rules that match the line item, then the first rule to match is used to determine that Cost Category value. 
- SplitChargeRules
- 
- Type: Array of CostCategorySplitChargeRule structures
 The split charge rules that are used to allocate your charges between your Cost Category values. 
CostCategoryInheritedValueDimension
Description
When you create or update a cost category, you can define the CostCategoryRule rule type as INHERITED_VALUE. This rule type adds the flexibility to define a rule that dynamically inherits the cost category value from the dimension value that's defined by CostCategoryInheritedValueDimension. For example, suppose that you want to dynamically group costs that are based on the value of a specific tag key. First, choose an inherited value rule type, and then choose the tag dimension and specify the tag key to use.
Members
- DimensionKey
- 
- Type: string
 The key to extract cost category values. 
- DimensionName
- 
- Type: string
 The name of the dimension that's used to group costs. If you specify LINKED_ACCOUNT_NAME, the cost category value is based on account name. If you specifyTAG, the cost category value is based on the value of the specified tag key.
CostCategoryProcessingStatus
Description
The list of processing statuses for Cost Management products for a specific cost category.
Members
- Component
- 
- Type: string
 The Cost Management product name of the applied status. 
- Status
- 
- Type: string
 The process status for a specific cost category. 
CostCategoryReference
Description
A reference to a Cost Category containing only enough information to identify the Cost Category.
You can use this information to retrieve the full Cost Category information using DescribeCostCategory.
Members
- CostCategoryArn
- 
- Type: string
 The unique identifier for your Cost Category. 
- DefaultValue
- 
- Type: string
 The default value for the cost category. 
- EffectiveEnd
- 
- Type: string
 The Cost Category's effective end date. 
- EffectiveStart
- 
- Type: string
 The Cost Category's effective start date. 
- Name
- 
- Type: string
 The unique name of the Cost Category. 
- NumberOfRules
- 
- Type: int
 The number of rules that are associated with a specific Cost Category. 
- ProcessingStatus
- 
- Type: Array of CostCategoryProcessingStatus structures
 The list of processing statuses for Cost Management products for a specific cost category. 
- Values
- 
- Type: Array of strings
 A list of unique cost category values in a specific cost category. 
CostCategoryRule
Description
Rules are processed in order. If there are multiple rules that match the line item, then the first rule to match is used to determine that Cost Category value.
Members
- InheritedValue
- 
- Type: CostCategoryInheritedValueDimension structure
 The value the line item is categorized as if the line item contains the matched dimension. 
- Rule
- 
- Type: Expression structure
 An Expression object used to categorize costs. This supports dimensions, tags, and nested expressions. Currently the only dimensions supported are LINKED_ACCOUNT,SERVICE_CODE,RECORD_TYPE,LINKED_ACCOUNT_NAME,REGION, andUSAGE_TYPE.RECORD_TYPEis a dimension used for Cost Explorer APIs, and is also supported for Cost Category expressions. This dimension uses different terms, depending on whether you're using the console or API/JSON editor. For a detailed comparison, see Term Comparisons in the Billing and Cost Management User Guide.
- Type
- 
- Type: string
 You can define the CostCategoryRulerule type as eitherREGULARorINHERITED_VALUE. TheINHERITED_VALUErule type adds the flexibility to define a rule that dynamically inherits the cost category value. This value is from the dimension value that's defined byCostCategoryInheritedValueDimension. For example, suppose that you want to costs to be dynamically grouped based on the value of a specific tag key. First, choose an inherited value rule type, and then choose the tag dimension and specify the tag key to use.
- Value
- 
- Type: string
 The default value for the cost category. 
CostCategorySplitChargeRule
Description
Use the split charge rule to split the cost of one Cost Category value across several other target values.
Members
- Method
- 
- Required: Yes
- Type: string
 The method that's used to define how to split your source costs across your targets. Proportional- Allocates charges across your targets based on the proportional weighted cost of each target.Fixed- Allocates charges across your targets based on your defined allocation percentage.> Even- Allocates costs evenly across all targets.
- Parameters
- 
- Type: Array of CostCategorySplitChargeRuleParameter structures
 The parameters for a split charge method. This is only required for the FIXEDmethod.
- Source
- 
- Required: Yes
- Type: string
 The Cost Category value that you want to split. That value can't be used as a source or a target in other split charge rules. To indicate uncategorized costs, you can use an empty string as the source. 
- Targets
- 
- Required: Yes
- Type: Array of strings
 The Cost Category values that you want to split costs across. These values can't be used as a source in other split charge rules. 
CostCategorySplitChargeRuleParameter
Description
The parameters for a split charge method.
Members
- Type
- 
- Required: Yes
- Type: string
 The parameter type. 
- Values
- 
- Required: Yes
- Type: Array of strings
 The parameter values. 
CostCategoryValues
Description
The Cost Categories values used for filtering the costs.
If Values and Key are not specified, the ABSENT MatchOption is applied to all Cost Categories. That is, it filters on resources that aren't mapped to any Cost Categories.
If Values is provided and Key isn't specified, the ABSENT MatchOption is applied to the Cost Categories Key only. That is, it filters on resources without the given Cost Categories key.
Members
- Key
- 
- Type: string
 The unique name of the Cost Category. 
- MatchOptions
- 
- Type: Array of strings
 The match options that you can use to filter your results. MatchOptions is only applicable for actions related to cost category. The default values for MatchOptionsisEQUALSandCASE_SENSITIVE.
- Values
- 
- Type: Array of strings
 The specific value of the Cost Category. 
CostComparisonDriver
Description
Represents a collection of cost drivers and their associated metrics for cost comparison analysis.
Members
- CostDrivers
- 
- Type: Array of CostDriver structures
 An array of cost drivers, each representing a cost difference between the baseline and comparison time periods. Each entry also includes a metric delta (for example, usage change) that contributed to the cost variance, along with the identifier and type of change. 
- CostSelector
- 
- Type: Expression structure
 Use Expressionto filter in various Cost Explorer APIs.Not all Expressiontypes are supported in each API. Refer to the documentation for each specific API to see what is supported.There are two patterns: -  Simple dimension values. -  There are three types of simple dimension values: CostCategories,Tags, andDimensions.-  Specify the CostCategoriesfield to define a filter that acts on Cost Categories.
-  Specify the Tagsfield to define a filter that acts on Cost Allocation Tags.
-  Specify the Dimensionsfield to define a filter that acts on theDimensionValues.
 
-  
-  For each filter type, you can set the dimension name and values for the filters that you plan to use. -  For example, you can filter for REGION==us-east-1 OR REGION==us-west-1. ForGetRightsizingRecommendation, the Region is a full name (for example,REGION==US East (N. Virginia).
-  The corresponding Expressionfor this example is as follows:{ "Dimensions": { "Key": "REGION", "Values": [ "us-east-1", "us-west-1" ] } }
-  As shown in the previous example, lists of dimension values are combined with ORwhen applying the filter.
 
-  
-  You can also set different match options to further control how the filter behaves. Not all APIs support match options. Refer to the documentation for each specific API to see what is supported. -  For example, you can filter for linked account names that start with "a". 
-  The corresponding Expressionfor this example is as follows:{ "Dimensions": { "Key": "LINKED_ACCOUNT_NAME", "MatchOptions": [ "STARTS_WITH" ], "Values": [ "a" ] } }
 
-  
 
-  
-  Compound Expressiontypes with logical operations.-  You can use multiple Expressiontypes and the logical operatorsAND/OR/NOTto create a list of one or moreExpressionobjects. By doing this, you can filter by more advanced options.
-  For example, you can filter by ((REGION == us-east-1 OR REGION == us-west-1) OR (TAG.Type == Type1)) AND (USAGE_TYPE != DataTransfer).
-  The corresponding Expressionfor this example is as follows:{ "And": [ {"Or": [ {"Dimensions": { "Key": "REGION", "Values": [ "us-east-1", "us-west-1" ] }}, {"Tags": { "Key": "TagName", "Values": ["Value1"] } } ]}, {"Not": {"Dimensions": { "Key": "USAGE_TYPE", "Values": ["DataTransfer"] }}} ] }
 Because each Expressioncan have only one operator, the service returns an error if more than one is specified. The following example shows anExpressionobject that creates an error:{ "And": [ ... ], "Dimensions": { "Key": "USAGE_TYPE", "Values": [ "DataTransfer" ] } }The following is an example of the corresponding error message: "Expression has more than one roots. Only one root operator is allowed for each expression: And, Or, Not, Dimensions, Tags, CostCategories"
-  
 For the GetRightsizingRecommendationaction, a combination of OR and NOT isn't supported. OR isn't supported between different dimensions, or dimensions and tags. NOT operators aren't supported. Dimensions are also limited toLINKED_ACCOUNT,REGION, orRIGHTSIZING_TYPE.For the GetReservationPurchaseRecommendationaction, only NOT is supported. AND and OR aren't supported. Dimensions are limited toLINKED_ACCOUNT.
- Metrics
- 
- Type: Associative array of custom strings keys (MetricName) to ComparisonMetricValue structures
 A mapping of metric names to their comparison values. 
CostDriver
Description
Represents factors that contribute to cost variations between the baseline and comparison time periods, including the type of driver, an identifier of the driver, and associated metrics.
Members
- Metrics
- 
- Type: Associative array of custom strings keys (MetricName) to ComparisonMetricValue structures
 A mapping of metric names to their comparison values, measuring the impact of this cost driver. 
- Name
- 
- Type: string
 The specific identifier of the cost driver. 
- Type
- 
- Type: string
 The category or classification of the cost driver. Values include: BUNDLED_DISCOUNT, CREDIT, OUT_OF_CYCLE_CHARGE, REFUND, RECURRING_RESERVATION_FEE, RESERVATION_USAGE, RI_VOLUME_DISCOUNT, SAVINGS_PLAN_USAGE, SAVINGS_PLAN_RECURRING_FEE, SUPPORT_FEE, TAX, UPFRONT_RESERVATION_FEE, USAGE_CHANGE, COMMITMENT 
Coverage
Description
The amount of instance usage that a reservation covered.
Members
- CoverageCost
- 
- Type: CoverageCost structure
 The amount of cost that the reservation covered. 
- CoverageHours
- 
- Type: CoverageHours structure
 The amount of instance usage that the reservation covered, in hours. 
- CoverageNormalizedUnits
- 
- Type: CoverageNormalizedUnits structure
 The amount of instance usage that the reservation covered, in normalized units. 
CoverageByTime
Description
Reservation coverage for a specified period, in hours.
Members
- Groups
- 
- Type: Array of ReservationCoverageGroup structures
 The groups of instances that the reservation covered. 
- TimePeriod
- 
- Type: DateInterval structure
 The period that this coverage was used over. 
- Total
- 
- Type: Coverage structure
 The total reservation coverage, in hours. 
CoverageCost
Description
How much it costs to run an instance.
Members
- OnDemandCost
- 
- Type: string
 How much an On-Demand Instance costs. 
CoverageHours
Description
How long a running instance either used a reservation or was On-Demand.
Members
- CoverageHoursPercentage
- 
- Type: string
 The percentage of instance hours that a reservation covered. 
- OnDemandHours
- 
- Type: string
 The number of instance running hours that On-Demand Instances covered. 
- ReservedHours
- 
- Type: string
 The number of instance running hours that reservations covered. 
- TotalRunningHours
- 
- Type: string
 The total instance usage, in hours. 
CoverageNormalizedUnits
Description
The amount of instance usage, in normalized units. You can use normalized units to see your EC2 usage for multiple sizes of instances in a uniform way. For example, suppose that you run an xlarge instance and a 2xlarge instance. If you run both instances for the same amount of time, the 2xlarge instance uses twice as much of your reservation as the xlarge instance, even though both instances show only one instance-hour. When you use normalized units instead of instance-hours, the xlarge instance used 8 normalized units, and the 2xlarge instance used 16 normalized units.
For more information, see Modifying Reserved Instances in the Amazon Elastic Compute Cloud User Guide for Linux Instances.
Members
- CoverageNormalizedUnitsPercentage
- 
- Type: string
 The percentage of your used instance normalized units that a reservation covers. 
- OnDemandNormalizedUnits
- 
- Type: string
 The number of normalized units that are covered by On-Demand Instances instead of a reservation. 
- ReservedNormalizedUnits
- 
- Type: string
 The number of normalized units that a reservation covers. 
- TotalRunningNormalizedUnits
- 
- Type: string
 The total number of normalized units that you used. 
CurrentInstance
Description
Context about the current instance.
Members
- CurrencyCode
- 
- Type: string
 The currency code that Amazon Web Services used to calculate the costs for this instance. 
- InstanceName
- 
- Type: string
 The name that you given an instance. This field shows as blank if you haven't given the instance a name. 
- MonthlyCost
- 
- Type: string
 The current On-Demand cost of operating this instance on a monthly basis. 
- OnDemandHoursInLookbackPeriod
- 
- Type: string
 The number of hours during the lookback period that's billed at On-Demand rates. 
- ReservationCoveredHoursInLookbackPeriod
- 
- Type: string
 The number of hours during the lookback period that's covered by reservations. 
- ResourceDetails
- 
- Type: ResourceDetails structure
 Details about the resource and utilization. 
- ResourceId
- 
- Type: string
 Resource ID of the current instance. 
- ResourceUtilization
- 
- Type: ResourceUtilization structure
 Utilization information of the current instance during the lookback period. 
- SavingsPlansCoveredHoursInLookbackPeriod
- 
- Type: string
 The number of hours during the lookback period that's covered by Savings Plans. 
- Tags
- 
- Type: Array of TagValues structures
 Cost allocation resource tags that are applied to the instance. 
- TotalRunningHoursInLookbackPeriod
- 
- Type: string
 The total number of hours that the instance ran during the lookback period. 
DataUnavailableException
Description
The requested data is unavailable.
Members
- Message
- 
- Type: string
 
DateInterval
Description
The time period of the request.
Members
- End
- 
- Required: Yes
- Type: string
 The end of the time period. The end date is exclusive. For example, if endis2017-05-01, Amazon Web Services retrieves cost and usage data from the start date up to, but not including,2017-05-01.
- Start
- 
- Required: Yes
- Type: string
 The beginning of the time period. The start date is inclusive. For example, if startis2017-01-01, Amazon Web Services retrieves cost and usage data starting at2017-01-01up to the end date. The start date must be equal to or no later than the current date to avoid a validation error.
DimensionValues
Description
The metadata that you can use to filter and group your results. You can use GetDimensionValues to find specific values.
Members
- Key
- 
- Type: string
 The names of the metadata types that you can use to filter and group your results. For example, AZreturns a list of Availability Zones.Not all dimensions are supported in each API. Refer to the documentation for each specific API to see what is supported. LINKED_ACCOUNT_NAMEandSERVICE_CODEcan only be used in CostCategoryRule.ANOMALY_TOTAL_IMPACT_ABSOLUTEandANOMALY_TOTAL_IMPACT_PERCENTAGEcan only be used in AnomalySubscriptions.
- MatchOptions
- 
- Type: Array of strings
 The match options that you can use to filter your results. MatchOptionsis only applicable for actions related to Cost Category and Anomaly Subscriptions. Refer to the documentation for each specific API to see what is supported.The default values for MatchOptionsareEQUALSandCASE_SENSITIVE.
- Values
- 
- Type: Array of strings
 The metadata values that you can use to filter and group your results. You can use GetDimensionValuesto find specific values.
DimensionValuesWithAttributes
Description
The metadata of a specific type that you can use to filter and group your results. You can use GetDimensionValues to find specific values.
Members
- Attributes
- 
- Type: Associative array of custom strings keys (AttributeType) to strings
 The attribute that applies to a specific Dimension.
- Value
- 
- Type: string
 The value of a dimension with a specific attribute. 
DiskResourceUtilization
Description
The field that contains a list of disk (local storage) metrics that are associated with the current instance.
Members
- DiskReadBytesPerSecond
- 
- Type: string
 The maximum read throughput operations per second. 
- DiskReadOpsPerSecond
- 
- Type: string
 The maximum number of read operations per second. 
- DiskWriteBytesPerSecond
- 
- Type: string
 The maximum write throughput operations per second. 
- DiskWriteOpsPerSecond
- 
- Type: string
 The maximum number of write operations per second. 
DynamoDBCapacityDetails
Description
The DynamoDB reservations that Amazon Web Services recommends that you purchase.
Members
- CapacityUnits
- 
- Type: string
 The capacity unit of the recommended reservation. 
- Region
- 
- Type: string
 The Amazon Web Services Region of the recommended reservation. 
EBSResourceUtilization
Description
The EBS field that contains a list of EBS metrics that are associated with the current instance.
Members
- EbsReadBytesPerSecond
- 
- Type: string
 The maximum size of read operations per second 
- EbsReadOpsPerSecond
- 
- Type: string
 The maximum number of read operations per second. 
- EbsWriteBytesPerSecond
- 
- Type: string
 The maximum size of write operations per second. 
- EbsWriteOpsPerSecond
- 
- Type: string
 The maximum number of write operations per second. 
EC2InstanceDetails
Description
Details about the Amazon EC2 reservations that Amazon Web Services recommends that you purchase.
Members
- AvailabilityZone
- 
- Type: string
 The Availability Zone of the recommended reservation. 
- CurrentGeneration
- 
- Type: boolean
 Determines whether the recommendation is for a current-generation instance. 
- Family
- 
- Type: string
 The instance family of the recommended reservation. 
- InstanceType
- 
- Type: string
 The type of instance that Amazon Web Services recommends. 
- Platform
- 
- Type: string
 The platform of the recommended reservation. The platform is the specific combination of operating system, license model, and software on an instance. 
- Region
- 
- Type: string
 The Amazon Web Services Region of the recommended reservation. 
- SizeFlexEligible
- 
- Type: boolean
 Determines whether the recommended reservation is size flexible. 
- Tenancy
- 
- Type: string
 Determines whether the recommended reservation is dedicated or shared. 
EC2ResourceDetails
Description
Details on the Amazon EC2 Resource.
Members
- HourlyOnDemandRate
- 
- Type: string
 The hourly public On-Demand rate for the instance type. 
- InstanceType
- 
- Type: string
 The type of Amazon Web Services instance. 
- Memory
- 
- Type: string
 The memory capacity of the Amazon Web Services instance. 
- NetworkPerformance
- 
- Type: string
 The network performance capacity of the Amazon Web Services instance. 
- Platform
- 
- Type: string
 The platform of the Amazon Web Services instance. The platform is the specific combination of operating system, license model, and software on an instance. 
- Region
- 
- Type: string
 The Amazon Web Services Region of the instance. 
- Sku
- 
- Type: string
 The SKU of the product. 
- Storage
- 
- Type: string
 The disk storage of the Amazon Web Services instance. This doesn't include EBS storage. 
- Vcpu
- 
- Type: string
 The number of VCPU cores in the Amazon Web Services instance type. 
EC2ResourceUtilization
Description
Utilization metrics for the instance.
Members
- DiskResourceUtilization
- 
- Type: DiskResourceUtilization structure
 The field that contains a list of disk (local storage) metrics that are associated with the current instance. 
- EBSResourceUtilization
- 
- Type: EBSResourceUtilization structure
 The EBS field that contains a list of EBS metrics that are associated with the current instance. 
- MaxCpuUtilizationPercentage
- 
- Type: string
 The maximum observed or expected CPU utilization of the instance. 
- MaxMemoryUtilizationPercentage
- 
- Type: string
 The maximum observed or expected memory utilization of the instance. 
- MaxStorageUtilizationPercentage
- 
- Type: string
 The maximum observed or expected storage utilization of the instance. This doesn't include EBS storage. 
- NetworkResourceUtilization
- 
- Type: NetworkResourceUtilization structure
 The network field that contains a list of network metrics that are associated with the current instance. 
EC2Specification
Description
The Amazon EC2 hardware specifications that you want Amazon Web Services to provide recommendations for.
Members
- OfferingClass
- 
- Type: string
 Indicates whether you want a recommendation for standard or convertible reservations. 
ESInstanceDetails
Description
Details about the Amazon OpenSearch Service reservations that Amazon Web Services recommends that you purchase.
Members
- CurrentGeneration
- 
- Type: boolean
 Determines whether the recommendation is for a current-generation instance. 
- InstanceClass
- 
- Type: string
 The class of instance that Amazon Web Services recommends. 
- InstanceSize
- 
- Type: string
 The size of instance that Amazon Web Services recommends. 
- Region
- 
- Type: string
 The Amazon Web Services Region of the recommended reservation. 
- SizeFlexEligible
- 
- Type: boolean
 Determines whether the recommended reservation is size flexible. 
ElastiCacheInstanceDetails
Description
Details about the Amazon ElastiCache reservations that Amazon Web Services recommends that you purchase.
Members
- CurrentGeneration
- 
- Type: boolean
 Determines whether the recommendation is for a current generation instance. 
- Family
- 
- Type: string
 The instance family of the recommended reservation. 
- NodeType
- 
- Type: string
 The type of node that Amazon Web Services recommends. 
- ProductDescription
- 
- Type: string
 The description of the recommended reservation. 
- Region
- 
- Type: string
 The Amazon Web Services Region of the recommended reservation. 
- SizeFlexEligible
- 
- Type: boolean
 Determines whether the recommended reservation is size flexible. 
Expression
Description
Use Expression to filter in various Cost Explorer APIs.
Not all Expression types are supported in each API. Refer to the documentation for each specific API to see what is supported.
There are two patterns:
-  Simple dimension values. -  There are three types of simple dimension values: CostCategories,Tags, andDimensions.-  Specify the CostCategoriesfield to define a filter that acts on Cost Categories.
-  Specify the Tagsfield to define a filter that acts on Cost Allocation Tags.
-  Specify the Dimensionsfield to define a filter that acts on theDimensionValues.
 
-  
-  For each filter type, you can set the dimension name and values for the filters that you plan to use. -  For example, you can filter for REGION==us-east-1 OR REGION==us-west-1. ForGetRightsizingRecommendation, the Region is a full name (for example,REGION==US East (N. Virginia).
-  The corresponding Expressionfor this example is as follows:{ "Dimensions": { "Key": "REGION", "Values": [ "us-east-1", "us-west-1" ] } }
-  As shown in the previous example, lists of dimension values are combined with ORwhen applying the filter.
 
-  
-  You can also set different match options to further control how the filter behaves. Not all APIs support match options. Refer to the documentation for each specific API to see what is supported. -  For example, you can filter for linked account names that start with "a". 
-  The corresponding Expressionfor this example is as follows:{ "Dimensions": { "Key": "LINKED_ACCOUNT_NAME", "MatchOptions": [ "STARTS_WITH" ], "Values": [ "a" ] } }
 
-  
 
-  
-  Compound Expressiontypes with logical operations.-  You can use multiple Expressiontypes and the logical operatorsAND/OR/NOTto create a list of one or moreExpressionobjects. By doing this, you can filter by more advanced options.
-  For example, you can filter by ((REGION == us-east-1 OR REGION == us-west-1) OR (TAG.Type == Type1)) AND (USAGE_TYPE != DataTransfer).
-  The corresponding Expressionfor this example is as follows:{ "And": [ {"Or": [ {"Dimensions": { "Key": "REGION", "Values": [ "us-east-1", "us-west-1" ] }}, {"Tags": { "Key": "TagName", "Values": ["Value1"] } } ]}, {"Not": {"Dimensions": { "Key": "USAGE_TYPE", "Values": ["DataTransfer"] }}} ] }
 Because each Expressioncan have only one operator, the service returns an error if more than one is specified. The following example shows anExpressionobject that creates an error:{ "And": [ ... ], "Dimensions": { "Key": "USAGE_TYPE", "Values": [ "DataTransfer" ] } }The following is an example of the corresponding error message: "Expression has more than one roots. Only one root operator is allowed for each expression: And, Or, Not, Dimensions, Tags, CostCategories"
-  
For the GetRightsizingRecommendation action, a combination of OR and NOT isn't supported. OR isn't supported between different dimensions, or dimensions and tags. NOT operators aren't supported. Dimensions are also limited to LINKED_ACCOUNT, REGION, or RIGHTSIZING_TYPE.
For the GetReservationPurchaseRecommendation action, only NOT is supported. AND and OR aren't supported. Dimensions are limited to LINKED_ACCOUNT.
Members
- And
- 
- Type: Array of Expression structures
 Return results that match both Dimensionobjects.
- CostCategories
- 
- Type: CostCategoryValues structure
 The filter that's based on CostCategoryvalues.
- Dimensions
- 
- Type: DimensionValues structure
 The specific Dimensionto use forExpression.
- Not
- 
- Type: Expression structure
 Return results that don't match a Dimensionobject.
- Or
- 
- Type: Array of Expression structures
 Return results that match either Dimensionobject.
- Tags
- 
- Type: TagValues structure
 The specific Tagto use forExpression.
ForecastResult
Description
The forecast that's created for your query.
Members
- MeanValue
- 
- Type: string
 The mean value of the forecast. 
- PredictionIntervalLowerBound
- 
- Type: string
 The lower limit for the prediction interval. 
- PredictionIntervalUpperBound
- 
- Type: string
 The upper limit for the prediction interval. 
- TimePeriod
- 
- Type: DateInterval structure
 The period of time that the forecast covers. 
GenerationExistsException
Description
A request to generate a recommendation or analysis is already in progress.
Members
- Message
- 
- Type: string
 
GenerationSummary
Description
The summary of the Savings Plans recommendation generation.
Members
- EstimatedCompletionTime
- 
- Type: string
 Indicates the estimated time for when the recommendation generation will complete. 
- GenerationCompletionTime
- 
- Type: string
 Indicates the completion time of the recommendation generation. 
- GenerationStartedTime
- 
- Type: string
 Indicates the start time of the recommendation generation. 
- GenerationStatus
- 
- Type: string
 Indicates whether the recommendation generation succeeded, is processing, or failed. 
- RecommendationId
- 
- Type: string
 Indicates the ID for this specific recommendation. 
Group
Description
One level of grouped data in the results.
Members
- Keys
- 
- Type: Array of strings
 The keys that are included in this group. 
- Metrics
- 
- Type: Associative array of custom strings keys (MetricName) to MetricValue structures
 The metrics that are included in this group. 
GroupDefinition
Description
Represents a group when you specify a group by criteria or in the response to a query with a specific grouping.
Members
- Key
- 
- Type: string
 The string that represents a key for a specified group. 
- Type
- 
- Type: string
 The string that represents the type of group. 
Impact
Description
The dollar value of the anomaly.
Members
- MaxImpact
- 
- Required: Yes
- Type: double
 The maximum dollar value that's observed for an anomaly. 
- TotalActualSpend
- 
- Type: double
 The cumulative dollar amount that was actually spent during the anomaly. 
- TotalExpectedSpend
- 
- Type: double
 The cumulative dollar amount that was expected to be spent during the anomaly. It is calculated using advanced machine learning models to determine the typical spending pattern based on historical data for a customer. 
- TotalImpact
- 
- Type: double
 The cumulative dollar difference between the total actual spend and total expected spend. It is calculated as TotalActualSpend - TotalExpectedSpend.
- TotalImpactPercentage
- 
- Type: double
 The cumulative percentage difference between the total actual spend and total expected spend. It is calculated as (TotalImpact / TotalExpectedSpend) * 100. WhenTotalExpectedSpendis zero, this field is omitted. Expected spend can be zero in situations such as when you start to use a service for the first time.
InstanceDetails
Description
Details about the reservations that Amazon Web Services recommends that you purchase.
Members
- EC2InstanceDetails
- 
- Type: EC2InstanceDetails structure
 The Amazon EC2 reservations that Amazon Web Services recommends that you purchase. 
- ESInstanceDetails
- 
- Type: ESInstanceDetails structure
 The Amazon OpenSearch Service reservations that Amazon Web Services recommends that you purchase. 
- ElastiCacheInstanceDetails
- 
- Type: ElastiCacheInstanceDetails structure
 The ElastiCache reservations that Amazon Web Services recommends that you purchase. 
- MemoryDBInstanceDetails
- 
- Type: MemoryDBInstanceDetails structure
 The MemoryDB reservations that Amazon Web Services recommends that you purchase. 
- RDSInstanceDetails
- 
- Type: RDSInstanceDetails structure
 The Amazon RDS reservations that Amazon Web Services recommends that you purchase. 
- RedshiftInstanceDetails
- 
- Type: RedshiftInstanceDetails structure
 The Amazon Redshift reservations that Amazon Web Services recommends that you purchase. 
InvalidNextTokenException
Description
The pagination token is invalid. Try again without a pagination token.
Members
- Message
- 
- Type: string
 
LimitExceededException
Description
You made too many calls in a short period of time. Try again later.
Members
- Message
- 
- Type: string
 
MemoryDBInstanceDetails
Description
Details about the MemoryDB reservations that Amazon Web Services recommends that you purchase.
Members
- CurrentGeneration
- 
- Type: boolean
 Determines whether the recommendation is for a current generation instance. 
- Family
- 
- Type: string
 The instance family of the recommended reservation. 
- NodeType
- 
- Type: string
 The node type of the recommended reservation. 
- Region
- 
- Type: string
 The Amazon Web Services Region of the recommended reservation. 
- SizeFlexEligible
- 
- Type: boolean
 Determines whether the recommended reservation is size flexible. 
MetricValue
Description
The aggregated value for a metric.
Members
- Amount
- 
- Type: string
 The actual number that represents the metric. 
- Unit
- 
- Type: string
 The unit that the metric is given in. 
ModifyRecommendationDetail
Description
Details for the modification recommendation.
Members
- TargetInstances
- 
- Type: Array of TargetInstance structures
 Determines whether this instance type is the Amazon Web Services default recommendation. 
NetworkResourceUtilization
Description
The network field that contains a list of network metrics that are associated with the current instance.
Members
- NetworkInBytesPerSecond
- 
- Type: string
 The network inbound throughput utilization measured in Bytes per second (Bps). 
- NetworkOutBytesPerSecond
- 
- Type: string
 The network outbound throughput utilization measured in Bytes per second (Bps). 
- NetworkPacketsInPerSecond
- 
- Type: string
 The network inbound packets that are measured in packets per second. 
- NetworkPacketsOutPerSecond
- 
- Type: string
 The network outbound packets that are measured in packets per second. 
RDSInstanceDetails
Description
Details about the Amazon RDS reservations that Amazon Web Services recommends that you purchase.
Members
- CurrentGeneration
- 
- Type: boolean
 Determines whether the recommendation is for a current-generation instance. 
- DatabaseEdition
- 
- Type: string
 The database edition that the recommended reservation supports. 
- DatabaseEngine
- 
- Type: string
 The database engine that the recommended reservation supports. 
- DeploymentOption
- 
- Type: string
 Determines whether the recommendation is for a reservation in a single Availability Zone or a reservation with a backup in a second Availability Zone. 
- Family
- 
- Type: string
 The instance family of the recommended reservation. 
- InstanceType
- 
- Type: string
 The type of instance that Amazon Web Services recommends. 
- LicenseModel
- 
- Type: string
 The license model that the recommended reservation supports. 
- Region
- 
- Type: string
 The Amazon Web Services Region of the recommended reservation. 
- SizeFlexEligible
- 
- Type: boolean
 Determines whether the recommended reservation is size flexible. 
RecommendationDetailData
Description
The details and metrics for the given recommendation.
Members
- AccountId
- 
- Type: string
 The AccountID that the recommendation is generated for. 
- AccountScope
- 
- Type: string
 The account scope that you want your recommendations for. Amazon Web Services calculates recommendations including the management account and member accounts if the value is set to PAYER. If the value is LINKED, recommendations are calculated for individual member accounts only. 
- CurrencyCode
- 
- Type: string
 The currency code that Amazon Web Services used to generate the recommendation and present potential savings. 
- CurrentAverageCoverage
- 
- Type: string
 The average value of hourly coverage over the lookback period. 
- CurrentAverageHourlyOnDemandSpend
- 
- Type: string
 The average value of hourly On-Demand spend over the lookback period of the applicable usage type. 
- CurrentMaximumHourlyOnDemandSpend
- 
- Type: string
 The highest value of hourly On-Demand spend over the lookback period of the applicable usage type. 
- CurrentMinimumHourlyOnDemandSpend
- 
- Type: string
 The lowest value of hourly On-Demand spend over the lookback period of the applicable usage type. 
- EstimatedAverageCoverage
- 
- Type: string
 The estimated coverage of the recommended Savings Plan. 
- EstimatedAverageUtilization
- 
- Type: string
 The estimated utilization of the recommended Savings Plan. 
- EstimatedMonthlySavingsAmount
- 
- Type: string
 The estimated monthly savings amount based on the recommended Savings Plan. 
- EstimatedOnDemandCost
- 
- Type: string
 The remaining On-Demand cost estimated to not be covered by the recommended Savings Plan, over the length of the lookback period. 
- EstimatedOnDemandCostWithCurrentCommitment
- 
- Type: string
 The estimated On-Demand costs you expect with no additional commitment, based on your usage of the selected time period and the Savings Plan you own. 
- EstimatedROI
- 
- Type: string
 The estimated return on investment that's based on the recommended Savings Plan that you purchased. This is calculated as estimatedSavingsAmount/estimatedSPCost*100. 
- EstimatedSPCost
- 
- Type: string
 The cost of the recommended Savings Plan over the length of the lookback period. 
- EstimatedSavingsAmount
- 
- Type: string
 The estimated savings amount that's based on the recommended Savings Plan over the length of the lookback period. 
- EstimatedSavingsPercentage
- 
- Type: string
 The estimated savings percentage relative to the total cost of applicable On-Demand usage over the lookback period. 
- ExistingHourlyCommitment
- 
- Type: string
 The existing hourly commitment for the Savings Plan type. 
- GenerationTimestamp
- 
- Type: string
 The period of time that you want the usage and costs for. 
- HourlyCommitmentToPurchase
- 
- Type: string
 The recommended hourly commitment level for the Savings Plan type and the configuration that's based on the usage during the lookback period. 
- InstanceFamily
- 
- Type: string
 The instance family of the recommended Savings Plan. 
- LatestUsageTimestamp
- 
- Type: string
 The period of time that you want the usage and costs for. 
- LookbackPeriodInDays
- 
- Type: string
 How many days of previous usage that Amazon Web Services considers when making this recommendation. 
- MetricsOverLookbackPeriod
- 
- Type: Array of RecommendationDetailHourlyMetrics structures
 The related hourly cost, coverage, and utilization metrics over the lookback period. 
- OfferingId
- 
- Type: string
 The unique ID that's used to distinguish Savings Plans from one another. 
- PaymentOption
- 
- Type: string
 The payment option for the commitment (for example, All Upfront or No Upfront). 
- Region
- 
- Type: string
 The region the recommendation is generated for. 
- SavingsPlansType
- 
- Type: string
 The requested Savings Plan recommendation type. 
- TermInYears
- 
- Type: string
 The term of the commitment in years. 
- UpfrontCost
- 
- Type: string
 The upfront cost of the recommended Savings Plan, based on the selected payment option. 
RecommendationDetailHourlyMetrics
Description
Contains the hourly metrics for the given recommendation over the lookback period.
Members
- CurrentCoverage
- 
- Type: string
 The current amount of Savings Plans eligible usage that the Savings Plan covered. 
- EstimatedCoverage
- 
- Type: string
 The estimated coverage amount based on the recommended Savings Plan. 
- EstimatedNewCommitmentUtilization
- 
- Type: string
 The estimated utilization for the recommended Savings Plan. 
- EstimatedOnDemandCost
- 
- Type: string
 The remaining On-Demand cost estimated to not be covered by the recommended Savings Plan, over the length of the lookback period. 
- StartTime
- 
- Type: string
 The period of time that you want the usage and costs for. 
RedshiftInstanceDetails
Description
Details about the Amazon Redshift reservations that Amazon Web Services recommends that you purchase.
Members
- CurrentGeneration
- 
- Type: boolean
 Determines whether the recommendation is for a current-generation instance. 
- Family
- 
- Type: string
 The instance family of the recommended reservation. 
- NodeType
- 
- Type: string
 The type of node that Amazon Web Services recommends. 
- Region
- 
- Type: string
 The Amazon Web Services Region of the recommended reservation. 
- SizeFlexEligible
- 
- Type: boolean
 Determines whether the recommended reservation is size flexible. 
RequestChangedException
Description
Your request parameters changed between pages. Try again with the old parameters or without a pagination token.
Members
- Message
- 
- Type: string
 
ReservationAggregates
Description
The aggregated numbers for your reservation usage.
Members
- AmortizedRecurringFee
- 
- Type: string
 The monthly cost of your reservation. It's amortized over the reservation period. 
- AmortizedUpfrontFee
- 
- Type: string
 The upfront cost of your reservation. It's amortized over the reservation period. 
- NetRISavings
- 
- Type: string
 How much you saved due to purchasing and utilizing reservation. Amazon Web Services calculates this by subtracting TotalAmortizedFeefromOnDemandCostOfRIHoursUsed.
- OnDemandCostOfRIHoursUsed
- 
- Type: string
 How much your reservation costs if charged On-Demand rates. 
- PurchasedHours
- 
- Type: string
 How many reservation hours that you purchased. 
- PurchasedUnits
- 
- Type: string
 The number of Amazon EC2 reservation hours that you purchased. It's converted to normalized units. Normalized units are available only for Amazon EC2 usage after November 11, 2017. 
- RICostForUnusedHours
- 
- Type: string
 The cost of unused hours for your reservation. 
- RealizedSavings
- 
- Type: string
 The realized savings because of purchasing and using a reservation. 
- TotalActualHours
- 
- Type: string
 The total number of reservation hours that you used. 
- TotalActualUnits
- 
- Type: string
 The total number of Amazon EC2 reservation hours that you used. It's converted to normalized units. Normalized units are available only for Amazon EC2 usage after November 11, 2017. 
- TotalAmortizedFee
- 
- Type: string
 The total cost of your reservation. It's amortized over the reservation period. 
- TotalPotentialRISavings
- 
- Type: string
 How much you might save if you use your entire reservation. 
- UnrealizedSavings
- 
- Type: string
 The unrealized savings because of purchasing and using a reservation. 
- UnusedHours
- 
- Type: string
 The number of reservation hours that you didn't use. 
- UnusedUnits
- 
- Type: string
 The number of Amazon EC2 reservation hours that you didn't use. It's converted to normalized units. Normalized units are available only for Amazon EC2 usage after November 11, 2017. 
- UtilizationPercentage
- 
- Type: string
 The percentage of reservation time that you used. 
- UtilizationPercentageInUnits
- 
- Type: string
 The percentage of Amazon EC2 reservation time that you used. It's converted to normalized units. Normalized units are available only for Amazon EC2 usage after November 11, 2017. 
ReservationCoverageGroup
Description
A group of reservations that share a set of attributes.
Members
- Attributes
- 
- Type: Associative array of custom strings keys (AttributeType) to strings
 The attributes for this group of reservations. 
- Coverage
- 
- Type: Coverage structure
 How much instance usage this group of reservations covered. 
ReservationPurchaseRecommendation
Description
A specific reservation that Amazon Web Services recommends for purchase.
Members
- AccountScope
- 
- Type: string
 The account scope that Amazon Web Services recommends that you purchase this instance for. For example, you can purchase this reservation for an entire organization in Amazon Web Services Organizations. 
- LookbackPeriodInDays
- 
- Type: string
 How many days of previous usage that Amazon Web Services considers when making this recommendation. 
- PaymentOption
- 
- Type: string
 The payment option for the reservation (for example, AllUpfrontorNoUpfront).
- RecommendationDetails
- 
- Type: Array of ReservationPurchaseRecommendationDetail structures
 Details about the recommended purchases. 
- RecommendationSummary
- 
- Type: ReservationPurchaseRecommendationSummary structure
 A summary about the recommended purchase. 
- ServiceSpecification
- 
- Type: ServiceSpecification structure
 Hardware specifications for the service that you want recommendations for. 
- TermInYears
- 
- Type: string
 The term of the reservation that you want recommendations for, in years. 
ReservationPurchaseRecommendationDetail
Description
Details about your recommended reservation purchase.
Members
- AccountId
- 
- Type: string
 The account that this Reserved Instance (RI) recommendation is for. 
- AverageNormalizedUnitsUsedPerHour
- 
- Type: string
 The average number of normalized units that you used in an hour during the historical period. Amazon Web Services uses this to calculate your recommended reservation purchases. 
- AverageNumberOfCapacityUnitsUsedPerHour
- 
- Type: string
 The average number of provisioned capacity units that you used in an hour during the historical period. Amazon Web Services uses this to calculate your recommended reservation purchases. 
- AverageNumberOfInstancesUsedPerHour
- 
- Type: string
 The average number of instances that you used in an hour during the historical period. Amazon Web Services uses this to calculate your recommended reservation purchases. 
- AverageUtilization
- 
- Type: string
 The average utilization of your instances. Amazon Web Services uses this to calculate your recommended reservation purchases. 
- CurrencyCode
- 
- Type: string
 The currency code that Amazon Web Services used to calculate the costs for this instance. 
- EstimatedBreakEvenInMonths
- 
- Type: string
 How long Amazon Web Services estimates that it takes for this instance to start saving you money, in months. 
- EstimatedMonthlyOnDemandCost
- 
- Type: string
 How much Amazon Web Services estimates that you spend on On-Demand Instances in a month. 
- EstimatedMonthlySavingsAmount
- 
- Type: string
 How much Amazon Web Services estimates that this specific recommendation might save you in a month. 
- EstimatedMonthlySavingsPercentage
- 
- Type: string
 How much Amazon Web Services estimates that this specific recommendation might save you in a month, as a percentage of your overall costs. 
- EstimatedReservationCostForLookbackPeriod
- 
- Type: string
 How much Amazon Web Services estimates that you might spend for all usage during the specified historical period if you had a reservation. 
- InstanceDetails
- 
- Type: InstanceDetails structure
 Details about the reservations that Amazon Web Services recommends that you purchase. 
- MaximumNormalizedUnitsUsedPerHour
- 
- Type: string
 The maximum number of normalized units that you used in an hour during the historical period. Amazon Web Services uses this to calculate your recommended reservation purchases. 
- MaximumNumberOfCapacityUnitsUsedPerHour
- 
- Type: string
 The maximum number of provisioned capacity units that you used in an hour during the historical period. Amazon Web Services uses this to calculate your recommended reservation purchases. 
- MaximumNumberOfInstancesUsedPerHour
- 
- Type: string
 The maximum number of instances that you used in an hour during the historical period. Amazon Web Services uses this to calculate your recommended reservation purchases. 
- MinimumNormalizedUnitsUsedPerHour
- 
- Type: string
 The minimum number of normalized units that you used in an hour during the historical period. Amazon Web Services uses this to calculate your recommended reservation purchases. 
- MinimumNumberOfCapacityUnitsUsedPerHour
- 
- Type: string
 The minimum number of provisioned capacity units that you used in an hour during the historical period. Amazon Web Services uses this to calculate your recommended reservation purchases. 
- MinimumNumberOfInstancesUsedPerHour
- 
- Type: string
 The minimum number of instances that you used in an hour during the historical period. Amazon Web Services uses this to calculate your recommended reservation purchases. 
- RecommendedNormalizedUnitsToPurchase
- 
- Type: string
 The number of normalized units that Amazon Web Services recommends that you purchase. 
- RecommendedNumberOfCapacityUnitsToPurchase
- 
- Type: string
 The number of reserved capacity units that Amazon Web Services recommends that you purchase. 
- RecommendedNumberOfInstancesToPurchase
- 
- Type: string
 The number of instances that Amazon Web Services recommends that you purchase. 
- RecurringStandardMonthlyCost
- 
- Type: string
 How much purchasing this instance costs you on a monthly basis. 
- ReservedCapacityDetails
- 
- Type: ReservedCapacityDetails structure
 Details about the reservations that Amazon Web Services recommends that you purchase. 
- UpfrontCost
- 
- Type: string
 How much purchasing this instance costs you upfront. 
ReservationPurchaseRecommendationMetadata
Description
Information about a recommendation, such as the timestamp for when Amazon Web Services made a specific recommendation.
Members
- AdditionalMetadata
- 
- Type: string
 Additional metadata that might be applicable to the recommendation. 
- GenerationTimestamp
- 
- Type: string
 The timestamp for when Amazon Web Services made the recommendation. 
- RecommendationId
- 
- Type: string
 The ID for the recommendation. 
ReservationPurchaseRecommendationSummary
Description
A summary about this recommendation, such as the currency code, the amount that Amazon Web Services estimates that you could save, and the total amount of reservation to purchase.
Members
- CurrencyCode
- 
- Type: string
 The currency code used for this recommendation. 
- TotalEstimatedMonthlySavingsAmount
- 
- Type: string
 The total amount that Amazon Web Services estimates that this recommendation could save you in a month. 
- TotalEstimatedMonthlySavingsPercentage
- 
- Type: string
 The total amount that Amazon Web Services estimates that this recommendation could save you in a month, as a percentage of your costs. 
ReservationUtilizationGroup
Description
A group of reservations that share a set of attributes.
Members
- Attributes
- 
- Type: Associative array of custom strings keys (AttributeType) to strings
 The attributes for this group of reservations. 
- Key
- 
- Type: string
 The key for a specific reservation attribute. 
- Utilization
- 
- Type: ReservationAggregates structure
 How much you used this group of reservations. 
- Value
- 
- Type: string
 The value of a specific reservation attribute. 
ReservedCapacityDetails
Description
Details about the reservations that Amazon Web Services recommends that you purchase.
Members
- DynamoDBCapacityDetails
- 
- Type: DynamoDBCapacityDetails structure
 The DynamoDB reservations that Amazon Web Services recommends that you purchase. 
ResourceDetails
Description
Details for the resource.
Members
- EC2ResourceDetails
- 
- Type: EC2ResourceDetails structure
 Details for the Amazon EC2 resource. 
ResourceNotFoundException
Description
The specified ARN in the request doesn't exist.
Members
- Message
- 
- Type: string
 
- ResourceName
- 
- Type: string
 
ResourceTag
Description
The tag structure that contains a tag key and value.
Tagging is supported only for the following Cost Explorer resource types:  AnomalyMonitor ,  AnomalySubscription ,  CostCategory .
Members
- Key
- 
- Required: Yes
- Type: string
 The key that's associated with the tag. 
- Value
- 
- Required: Yes
- Type: string
 The value that's associated with the tag. 
ResourceUtilization
Description
Resource utilization of current resource.
Members
- EC2ResourceUtilization
- 
- Type: EC2ResourceUtilization structure
 The utilization of current Amazon EC2 instance. 
ResultByTime
Description
The result that's associated with a time period.
Members
- Estimated
- 
- Type: boolean
 Determines whether the result is estimated. 
- Groups
- 
- Type: Array of Group structures
 The groups that this time period includes. 
- TimePeriod
- 
- Type: DateInterval structure
 The time period that the result covers. 
- Total
- 
- Type: Associative array of custom strings keys (MetricName) to MetricValue structures
 The total amount of cost or usage accrued during the time period. 
RightsizingRecommendation
Description
Recommendations to rightsize resources.
Members
- AccountId
- 
- Type: string
 The account that this recommendation is for. 
- CurrentInstance
- 
- Type: CurrentInstance structure
 Context regarding the current instance. 
- FindingReasonCodes
- 
- Type: Array of strings
 The list of possible reasons why the recommendation is generated, such as under- or over-utilization of specific metrics (for example, CPU, Memory, Network). 
- ModifyRecommendationDetail
- 
- Type: ModifyRecommendationDetail structure
 The details for the modification recommendations. 
- RightsizingType
- 
- Type: string
 A recommendation to either terminate or modify the resource. 
- TerminateRecommendationDetail
- 
- Type: TerminateRecommendationDetail structure
 The details for termination recommendations. 
RightsizingRecommendationConfiguration
Description
You can use RightsizingRecommendationConfiguration to customize recommendations across two attributes. You can choose to view recommendations for instances within the same instance families or across different instance families. You can also choose to view your estimated savings that are associated with recommendations with consideration of existing Savings Plans or Reserved Instance (RI) benefits, or neither. 
Members
- BenefitsConsidered
- 
- Required: Yes
- Type: boolean
 The option to consider RI or Savings Plans discount benefits in your savings calculation. The default value is TRUE.
- RecommendationTarget
- 
- Required: Yes
- Type: string
 The option to see recommendations within the same instance family or recommendations for instances across other families. The default value is SAME_INSTANCE_FAMILY.
RightsizingRecommendationMetadata
Description
Metadata for a recommendation set.
Members
- AdditionalMetadata
- 
- Type: string
 Additional metadata that might be applicable to the recommendation. 
- GenerationTimestamp
- 
- Type: string
 The timestamp for when Amazon Web Services made the recommendation. 
- LookbackPeriodInDays
- 
- Type: string
 The number of days of previous usage that Amazon Web Services considers when making the recommendation. 
- RecommendationId
- 
- Type: string
 The ID for the recommendation. 
RightsizingRecommendationSummary
Description
The summary of rightsizing recommendations
Members
- EstimatedTotalMonthlySavingsAmount
- 
- Type: string
 The estimated total savings resulting from modifications, on a monthly basis. 
- SavingsCurrencyCode
- 
- Type: string
 The currency code that Amazon Web Services used to calculate the savings. 
- SavingsPercentage
- 
- Type: string
 The savings percentage based on the recommended modifications. It's relative to the total On-Demand costs that are associated with these instances. 
- TotalRecommendationCount
- 
- Type: string
 The total number of instance recommendations. 
RootCause
Description
The combination of Amazon Web Services service, linked account, linked account name, Region, and usage type where a cost anomaly is observed, along with the dollar and percentage amount of the anomaly impact. The linked account name will only be available when the account name can be identified.
Members
- Impact
- 
- Type: RootCauseImpact structure
 The dollar impact for the root cause. 
- LinkedAccount
- 
- Type: string
 The member account value that's associated with the cost anomaly. 
- LinkedAccountName
- 
- Type: string
 The member account name value that's associated with the cost anomaly. 
- Region
- 
- Type: string
 The Amazon Web Services Region that's associated with the cost anomaly. 
- Service
- 
- Type: string
 The Amazon Web Services service name that's associated with the cost anomaly. 
- UsageType
- 
- Type: string
 The UsageTypevalue that's associated with the cost anomaly.
RootCauseImpact
Description
The dollar value of the root cause.
Members
- Contribution
- 
- Required: Yes
- Type: double
 The dollar amount that this root cause contributed to the anomaly's TotalImpact. 
SavingsPlans
Description
The Savings Plans commitment details.
Members
- InstanceFamily
- 
- Type: string
 The instance family of the Savings Plans commitment. 
- OfferingId
- 
- Type: string
 The unique ID that's used to distinguish Savings Plans commitments from one another. 
- PaymentOption
- 
- Type: string
 The payment option for the Savings Plans commitment. 
- Region
- 
- Type: string
 The Region associated with the Savings Plans commitment. 
- SavingsPlansCommitment
- 
- Type: double
 The Savings Plans commitment. 
- SavingsPlansType
- 
- Type: string
 The Savings Plans type. 
- TermInYears
- 
- Type: string
 The term that you want the Savings Plans commitment for. 
SavingsPlansAmortizedCommitment
Description
The amortized amount of Savings Plans purchased in a specific account during a specific time interval.
Members
- AmortizedRecurringCommitment
- 
- Type: string
 The amortized amount of your Savings Plans commitment that was purchased with either a Partialor aNoUpfront.
- AmortizedUpfrontCommitment
- 
- Type: string
 The amortized amount of your Savings Plans commitment that was purchased with an UpfrontorPartialUpfrontSavings Plans.
- TotalAmortizedCommitment
- 
- Type: string
 The total amortized amount of your Savings Plans commitment, regardless of your Savings Plans purchase method. 
SavingsPlansCoverage
Description
The amount of Savings Plans eligible usage that's covered by Savings Plans. All calculations consider the On-Demand equivalent of your Savings Plans usage.
Members
- Attributes
- 
- Type: Associative array of custom strings keys (AttributeType) to strings
 The attribute that applies to a specific Dimension.
- Coverage
- 
- Type: SavingsPlansCoverageData structure
 The amount of Savings Plans eligible usage that the Savings Plans covered. 
- TimePeriod
- 
- Type: DateInterval structure
 The time period of the request. 
SavingsPlansCoverageData
Description
Specific coverage percentage, On-Demand costs, and spend covered by Savings Plans, and total Savings Plans costs for an account.
Members
- CoveragePercentage
- 
- Type: string
 The percentage of your existing Savings Plans covered usage, divided by all of your eligible Savings Plans usage in an account (or set of accounts). 
- OnDemandCost
- 
- Type: string
 The cost of your Amazon Web Services usage at the public On-Demand rate. 
- SpendCoveredBySavingsPlans
- 
- Type: string
 The amount of your Amazon Web Services usage that's covered by a Savings Plans. 
- TotalCost
- 
- Type: string
 The total cost of your Amazon Web Services usage, regardless of your purchase option. 
SavingsPlansDetails
Description
The attribute details on a specific Savings Plan.
Members
- InstanceFamily
- 
- Type: string
 A group of instance types that Savings Plans applies to. 
- OfferingId
- 
- Type: string
 The unique ID that's used to distinguish Savings Plans from one another. 
- Region
- 
- Type: string
 A collection of Amazon Web Services resources in a geographic area. Each Amazon Web Services Region is isolated and independent of the other Regions. 
SavingsPlansPurchaseAnalysisConfiguration
Description
The configuration for the Savings Plans purchase analysis.
Members
- AccountId
- 
- Type: string
 The account that the analysis is for. 
- AccountScope
- 
- Type: string
 The account scope that you want your analysis for. 
- AnalysisType
- 
- Required: Yes
- Type: string
 The type of analysis. 
- LookBackTimePeriod
- 
- Required: Yes
- Type: DateInterval structure
 The time period associated with the analysis. 
- SavingsPlansToAdd
- 
- Required: Yes
- Type: Array of SavingsPlans structures
 Savings Plans to include in the analysis. 
- SavingsPlansToExclude
- 
- Type: Array of strings
 Savings Plans to exclude from the analysis. 
SavingsPlansPurchaseAnalysisDetails
Description
Details about the Savings Plans purchase analysis.
Members
- AdditionalMetadata
- 
- Type: string
 Additional metadata that might be applicable to the commitment. 
- CurrencyCode
- 
- Type: string
 The currency code used for the analysis. 
- CurrentAverageCoverage
- 
- Type: string
 The average value of hourly coverage over the lookback period. 
- CurrentAverageHourlyOnDemandSpend
- 
- Type: string
 The average value of hourly On-Demand spend over the lookback period. 
- CurrentMaximumHourlyOnDemandSpend
- 
- Type: string
 The highest value of hourly On-Demand spend over the lookback period. 
- CurrentMinimumHourlyOnDemandSpend
- 
- Type: string
 The lowest value of hourly On-Demand spend over the lookback period. 
- CurrentOnDemandSpend
- 
- Type: string
 The current total On-Demand spend over the lookback period. 
- EstimatedAverageCoverage
- 
- Type: string
 The estimated coverage of the Savings Plan. 
- EstimatedAverageUtilization
- 
- Type: string
 The estimated utilization of the Savings Plan. 
- EstimatedCommitmentCost
- 
- Type: string
 The estimated cost of the Savings Plan over the length of the lookback period. 
- EstimatedMonthlySavingsAmount
- 
- Type: string
 The estimated monthly savings amount based on the Savings Plan. 
- EstimatedOnDemandCost
- 
- Type: string
 The remaining On-Demand cost estimated to not be covered by the Savings Plan over the length of the lookback period. 
- EstimatedOnDemandCostWithCurrentCommitment
- 
- Type: string
 The estimated On-Demand cost you expect with no additional commitment based on your usage of the selected time period and the Savings Plan you own. 
- EstimatedROI
- 
- Type: string
 The estimated return on investment that's based on the Savings Plan and estimated savings. This is calculated as estimatedSavingsAmount/estimatedSPCost*100. 
- EstimatedSavingsAmount
- 
- Type: string
 The estimated savings amount that's based on the Savings Plan over the length of the lookback period. 
- EstimatedSavingsPercentage
- 
- Type: string
 The estimated savings percentage relative to the total cost over the cost calculation lookback period. 
- ExistingHourlyCommitment
- 
- Type: string
 The existing hourly commitment for the Savings Plan type. 
- HourlyCommitmentToPurchase
- 
- Type: string
 The recommended or custom hourly commitment. 
- LatestUsageTimestamp
- 
- Type: string
 The date and time of the last hour that went into the analysis. 
- LookbackPeriodInHours
- 
- Type: string
 The lookback period in hours that's used to generate the analysis. 
- MetricsOverLookbackPeriod
- 
- Type: Array of RecommendationDetailHourlyMetrics structures
 The related hourly cost, coverage, and utilization metrics over the lookback period. 
- UpfrontCost
- 
- Type: string
 The upfront cost of the Savings Plan based on the selected payment option. 
SavingsPlansPurchaseRecommendation
Description
Contains your request parameters, Savings Plan Recommendations Summary, and Details.
Members
- AccountScope
- 
- Type: string
 The account scope that you want your recommendations for. Amazon Web Services calculates recommendations that include the management account and member accounts if the value is set to PAYER. If the value isLINKED, recommendations are calculated for individual member accounts only.
- LookbackPeriodInDays
- 
- Type: string
 The lookback period in days that's used to generate the recommendation. 
- PaymentOption
- 
- Type: string
 The payment option that's used to generate the recommendation. 
- SavingsPlansPurchaseRecommendationDetails
- 
- Type: Array of SavingsPlansPurchaseRecommendationDetail structures
 Details for the Savings Plans that we recommend that you purchase to cover existing Savings Plans eligible workloads. 
- SavingsPlansPurchaseRecommendationSummary
- 
- Type: SavingsPlansPurchaseRecommendationSummary structure
 Summary metrics for your Savings Plans Recommendations. 
- SavingsPlansType
- 
- Type: string
 The requested Savings Plans recommendation type. 
- TermInYears
- 
- Type: string
 The Savings Plans recommendation term in years. It's used to generate the recommendation. 
SavingsPlansPurchaseRecommendationDetail
Description
Details for your recommended Savings Plans.
Members
- AccountId
- 
- Type: string
 The AccountIDthe recommendation is generated for.
- CurrencyCode
- 
- Type: string
 The currency code that Amazon Web Services used to generate the recommendations and present potential savings. 
- CurrentAverageHourlyOnDemandSpend
- 
- Type: string
 The average value of hourly On-Demand spend over the lookback period of the applicable usage type. 
- CurrentMaximumHourlyOnDemandSpend
- 
- Type: string
 The highest value of hourly On-Demand spend over the lookback period of the applicable usage type. 
- CurrentMinimumHourlyOnDemandSpend
- 
- Type: string
 The lowest value of hourly On-Demand spend over the lookback period of the applicable usage type. 
- EstimatedAverageUtilization
- 
- Type: string
 The estimated utilization of the recommended Savings Plans. 
- EstimatedMonthlySavingsAmount
- 
- Type: string
 The estimated monthly savings amount based on the recommended Savings Plans. 
- EstimatedOnDemandCost
- 
- Type: string
 The remaining On-Demand cost estimated to not be covered by the recommended Savings Plans, over the length of the lookback period. 
- EstimatedOnDemandCostWithCurrentCommitment
- 
- Type: string
 The estimated On-Demand costs you expect with no additional commitment, based on your usage of the selected time period and the Savings Plans you own. 
- EstimatedROI
- 
- Type: string
 The estimated return on investment that's based on the recommended Savings Plans that you purchased. This is calculated as estimatedSavingsAmount/estimatedSPCost*100.
- EstimatedSPCost
- 
- Type: string
 The cost of the recommended Savings Plans over the length of the lookback period. 
- EstimatedSavingsAmount
- 
- Type: string
 The estimated savings amount that's based on the recommended Savings Plans over the length of the lookback period. 
- EstimatedSavingsPercentage
- 
- Type: string
 The estimated savings percentage relative to the total cost of applicable On-Demand usage over the lookback period. 
- HourlyCommitmentToPurchase
- 
- Type: string
 The recommended hourly commitment level for the Savings Plans type and the configuration that's based on the usage during the lookback period. 
- RecommendationDetailId
- 
- Type: string
 Contains detailed information about a specific Savings Plan recommendation. 
- SavingsPlansDetails
- 
- Type: SavingsPlansDetails structure
 Details for your recommended Savings Plans. 
- UpfrontCost
- 
- Type: string
 The upfront cost of the recommended Savings Plans, based on the selected payment option. 
SavingsPlansPurchaseRecommendationMetadata
Description
Metadata about your Savings Plans Purchase Recommendations.
Members
- AdditionalMetadata
- 
- Type: string
 Additional metadata that might be applicable to the recommendation. 
- GenerationTimestamp
- 
- Type: string
 The timestamp that shows when the recommendations were generated. 
- RecommendationId
- 
- Type: string
 The unique identifier for the recommendation set. 
SavingsPlansPurchaseRecommendationSummary
Description
Summary metrics for your Savings Plans Purchase Recommendations.
Members
- CurrencyCode
- 
- Type: string
 The currency code that Amazon Web Services used to generate the recommendations and present potential savings. 
- CurrentOnDemandSpend
- 
- Type: string
 The current total on demand spend of the applicable usage types over the lookback period. 
- DailyCommitmentToPurchase
- 
- Type: string
 The recommended Savings Plans cost on a daily (24 hourly) basis. 
- EstimatedMonthlySavingsAmount
- 
- Type: string
 The estimated monthly savings amount that's based on the recommended Savings Plans purchase. 
- EstimatedOnDemandCostWithCurrentCommitment
- 
- Type: string
 The estimated On-Demand costs you expect with no additional commitment. It's based on your usage of the selected time period and the Savings Plans you own. 
- EstimatedROI
- 
- Type: string
 The estimated return on investment that's based on the recommended Savings Plans and estimated savings. 
- EstimatedSavingsAmount
- 
- Type: string
 The estimated total savings over the lookback period, based on the purchase of the recommended Savings Plans. 
- EstimatedSavingsPercentage
- 
- Type: string
 The estimated savings relative to the total cost of On-Demand usage, over the lookback period. This is calculated as estimatedSavingsAmount/CurrentOnDemandSpend*100.
- EstimatedTotalCost
- 
- Type: string
 The estimated total cost of the usage after purchasing the recommended Savings Plans. This is a sum of the cost of Savings Plans during this term, and the remaining On-Demand usage. 
- HourlyCommitmentToPurchase
- 
- Type: string
 The recommended hourly commitment that's based on the recommendation parameters. 
- TotalRecommendationCount
- 
- Type: string
 The aggregate number of Savings Plans recommendations that exist for your account. 
SavingsPlansSavings
Description
The amount of savings that you're accumulating, against the public On-Demand rate of the usage accrued in an account.
Members
- NetSavings
- 
- Type: string
 The savings amount that you're accumulating for the usage that's covered by a Savings Plans, when compared to the On-Demand equivalent of the same usage. 
- OnDemandCostEquivalent
- 
- Type: string
 How much the amount that the usage would have cost if it was accrued at the On-Demand rate. 
SavingsPlansUtilization
Description
The measurement of how well you're using your existing Savings Plans.
Members
- TotalCommitment
- 
- Type: string
 The total amount of Savings Plans commitment that's been purchased in an account (or set of accounts). 
- UnusedCommitment
- 
- Type: string
 The amount of your Savings Plans commitment that wasn't consumed from Savings Plans eligible usage in a specific period. 
- UsedCommitment
- 
- Type: string
 The amount of your Savings Plans commitment that was consumed from Savings Plans eligible usage in a specific period. 
- UtilizationPercentage
- 
- Type: string
 The amount of UsedCommitmentdivided by theTotalCommitmentfor your Savings Plans.
SavingsPlansUtilizationAggregates
Description
The aggregated utilization metrics for your Savings Plans usage.
Members
- AmortizedCommitment
- 
- Type: SavingsPlansAmortizedCommitment structure
 The total amortized commitment for a Savings Plans. This includes the sum of the upfront and recurring Savings Plans fees. 
- Savings
- 
- Type: SavingsPlansSavings structure
 The amount that's saved by using existing Savings Plans. Savings returns both net savings from Savings Plans and also the onDemandCostEquivalentof the Savings Plans when considering the utilization rate.
- Utilization
- 
- Required: Yes
- Type: SavingsPlansUtilization structure
 A ratio of your effectiveness of using existing Savings Plans to apply to workloads that are Savings Plans eligible. 
SavingsPlansUtilizationByTime
Description
The amount of Savings Plans utilization (in hours).
Members
- AmortizedCommitment
- 
- Type: SavingsPlansAmortizedCommitment structure
 The total amortized commitment for a Savings Plans. This includes the sum of the upfront and recurring Savings Plans fees. 
- Savings
- 
- Type: SavingsPlansSavings structure
 The amount that's saved by using existing Savings Plans. Savings returns both net savings from Savings Plans and also the onDemandCostEquivalentof the Savings Plans when considering the utilization rate.
- TimePeriod
- 
- Required: Yes
- Type: DateInterval structure
 The time period of the request. 
- Utilization
- 
- Required: Yes
- Type: SavingsPlansUtilization structure
 A ratio of your effectiveness of using existing Savings Plans to apply to workloads that are Savings Plans eligible. 
SavingsPlansUtilizationDetail
Description
A single daily or monthly Savings Plans utilization rate and details for your account. A management account in an organization have access to member accounts. You can use GetDimensionValues to determine the possible dimension values. 
Members
- AmortizedCommitment
- 
- Type: SavingsPlansAmortizedCommitment structure
 The total amortized commitment for a Savings Plans. Includes the sum of the upfront and recurring Savings Plans fees. 
- Attributes
- 
- Type: Associative array of custom strings keys (AttributeType) to strings
 The attribute that applies to a specific Dimension.
- Savings
- 
- Type: SavingsPlansSavings structure
 The amount saved by using existing Savings Plans. Savings returns both net savings from savings plans and also the onDemandCostEquivalentof the Savings Plans when considering the utilization rate.
- SavingsPlanArn
- 
- Type: string
 The unique Amazon Resource Name (ARN) for a particular Savings Plan. 
- Utilization
- 
- Type: SavingsPlansUtilization structure
 A ratio of your effectiveness of using existing Savings Plans to apply to workloads that are Savings Plans eligible. 
ServiceQuotaExceededException
Description
You've reached the limit on the number of resources you can create, or exceeded the size of an individual resource.
Members
- Message
- 
- Type: string
 
ServiceSpecification
Description
Hardware specifications for the service that you want recommendations for.
Members
- EC2Specification
- 
- Type: EC2Specification structure
 The Amazon EC2 hardware specifications that you want Amazon Web Services to provide recommendations for. 
SortDefinition
Description
The details for how to sort the data.
Members
- Key
- 
- Required: Yes
- Type: string
 The key that's used to sort the data. 
- SortOrder
- 
- Type: string
 The order that's used to sort the data. 
Subscriber
Description
The recipient of AnomalySubscription notifications. 
Members
- Address
- 
- Type: string
 The email address or SNS Amazon Resource Name (ARN). This depends on the Type.
- Status
- 
- Type: string
 Indicates if the subscriber accepts the notifications. 
- Type
- 
- Type: string
 The notification delivery channel. 
TagValues
Description
The values that are available for a tag.
If Values and Key aren't specified, the ABSENT MatchOption is applied to all tags. That is, it's filtered on resources with no tags.
If Key is provided and Values isn't specified, the ABSENT MatchOption is applied to the tag Key only. That is, it's filtered on resources without the given tag key.
Members
- Key
- 
- Type: string
 The key for the tag. 
- MatchOptions
- 
- Type: Array of strings
 The match options that you can use to filter your results. MatchOptionsis only applicable for actions related to Cost Category. The default values forMatchOptionsareEQUALSandCASE_SENSITIVE.
- Values
- 
- Type: Array of strings
 The specific value of the tag. 
TargetInstance
Description
Details on recommended instance.
Members
- CurrencyCode
- 
- Type: string
 The currency code that Amazon Web Services used to calculate the costs for this instance. 
- DefaultTargetInstance
- 
- Type: boolean
 Determines whether this recommendation is the defaulted Amazon Web Services recommendation. 
- EstimatedMonthlyCost
- 
- Type: string
 The expected cost to operate this instance type on a monthly basis. 
- EstimatedMonthlySavings
- 
- Type: string
 The estimated savings that result from modification, on a monthly basis. 
- ExpectedResourceUtilization
- 
- Type: ResourceUtilization structure
 The expected utilization metrics for target instance type. 
- PlatformDifferences
- 
- Type: Array of strings
 Explains the actions that you might need to take to successfully migrate your workloads from the current instance type to the recommended instance type. 
- ResourceDetails
- 
- Type: ResourceDetails structure
 Details on the target instance type. 
TerminateRecommendationDetail
Description
Details on termination recommendation.
Members
- CurrencyCode
- 
- Type: string
 The currency code that Amazon Web Services used to calculate the costs for this instance. 
- EstimatedMonthlySavings
- 
- Type: string
 The estimated savings that result from modification, on a monthly basis. 
TooManyTagsException
Description
Can occur if you specify a number of tags for a resource greater than the maximum 50 user tags per resource.
Members
- Message
- 
- Type: string
 
- ResourceName
- 
- Type: string
 
TotalImpactFilter
Description
Filters cost anomalies based on the total impact.
Members
- EndValue
- 
- Type: double
 The upper bound dollar value that's used in the filter. 
- NumericOperator
- 
- Required: Yes
- Type: string
 The comparing value that's used in the filter. 
- StartValue
- 
- Required: Yes
- Type: double
 The lower bound dollar value that's used in the filter. 
UnknownMonitorException
Description
The cost anomaly monitor does not exist for the account.
Members
- Message
- 
- Type: string
 
UnknownSubscriptionException
Description
The cost anomaly subscription does not exist for the account.
Members
- Message
- 
- Type: string
 
UnresolvableUsageUnitException
Description
Cost Explorer was unable to identify the usage unit. Provide UsageType/UsageTypeGroup filter selections that contain matching units, for example: hours.
Members
- Message
- 
- Type: string
 
UpdateCostAllocationTagsStatusError
Description
Gives a detailed description of the result of an action. It's on each cost allocation tag entry in the request.
Members
- Code
- 
- Type: string
 An error code representing why the action failed on this entry. 
- Message
- 
- Type: string
 A message explaining why the action failed on this entry. 
- TagKey
- 
- Type: string
 The key for the cost allocation tag. 
UtilizationByTime
Description
The amount of utilization, in hours.
Members
- Groups
- 
- Type: Array of ReservationUtilizationGroup structures
 The groups that this utilization result uses. 
- TimePeriod
- 
- Type: DateInterval structure
 The period of time that this utilization was used for. 
- Total
- 
- Type: ReservationAggregates structure
 The total number of reservation hours that were used.