Icon

AWS Cost Explorer (version v1.*.*)

get_cost_and_usage

Retrieves cost and usage metrics 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. Master accounts in an organization in AWS Organizations have access to all member accounts.

Parameters

$body

Type: object

{
"Metrics" : [ "string" ],
"GroupBy" : [ {
"Type" : "The string that represents the type of group.",
"Key" : "The string that represents a key for a specified group."
} ],
"Filter" : {
"Not" : {
"Not" : "Expression",
"Or" : [ {
"Not" : "Expression",
"Or" : "Expressions",
"And" : [ {
"Not" : "Expression",
"Or" : "Expressions",
"And" : "Expressions",
"Dimensions" : {
"Values" : [ "string" ],
"Key" : "The names of the metadata types that you can use to filter and group your results. For example, AZ returns a list of Availability Zones."
},
"Tags" : {
"Values" : [ "string" ],
"Key" : "The key for the tag."
}
} ],
"Dimensions" : {
"Values" : [ "string" ],
"Key" : "The names of the metadata types that you can use to filter and group your results. For example, AZ returns a list of Availability Zones."
},
"Tags" : {
"Values" : [ "string" ],
"Key" : "The key for the tag."
}
} ],
"And" : [ {
"Not" : "Expression",
"Or" : [ {
"Not" : "Expression",
"Or" : "Expressions",
"And" : "Expressions",
"Dimensions" : {
"Values" : [ "string" ],
"Key" : "The names of the metadata types that you can use to filter and group your results. For example, AZ returns a list of Availability Zones."
},
"Tags" : {
"Values" : [ "string" ],
"Key" : "The key for the tag."
}
} ],
"And" : "Expressions",
"Dimensions" : {
"Values" : [ "string" ],
"Key" : "The names of the metadata types that you can use to filter and group your results. For example, AZ returns a list of Availability Zones."
},
"Tags" : {
"Values" : [ "string" ],
"Key" : "The key for the tag."
}
} ],
"Dimensions" : {
"Values" : [ "string" ],
"Key" : "The names of the metadata types that you can use to filter and group your results. For example, AZ returns a list of Availability Zones."
},
"Tags" : {
"Values" : [ "string" ],
"Key" : "The key for the tag."
}
},
"Or" : [ {
"Not" : {
"Not" : "Expression",
"Or" : "Expressions",
"And" : [ {
"Not" : "Expression",
"Or" : "Expressions",
"And" : "Expressions",
"Dimensions" : {
"Values" : [ "string" ],
"Key" : "The names of the metadata types that you can use to filter and group your results. For example, AZ returns a list of Availability Zones."
},
"Tags" : {
"Values" : [ "string" ],
"Key" : "The key for the tag."
}
} ],
"Dimensions" : {
"Values" : [ "string" ],
"Key" : "The names of the metadata types that you can use to filter and group your results. For example, AZ returns a list of Availability Zones."
},
"Tags" : {
"Values" : [ "string" ],
"Key" : "The key for the tag."
}
},
"Or" : "Expressions",
"And" : [ {
"Not" : {
"Not" : "Expression",
"Or" : "Expressions",
"And" : "Expressions",
"Dimensions" : {
"Values" : [ "string" ],
"Key" : "The names of the metadata types that you can use to filter and group your results. For example, AZ returns a list of Availability Zones."
},
"Tags" : {
"Values" : [ "string" ],
"Key" : "The key for the tag."
}
},
"Or" : "Expressions",
"And" : "Expressions",
"Dimensions" : {
"Values" : [ "string" ],
"Key" : "The names of the metadata types that you can use to filter and group your results. For example, AZ returns a list of Availability Zones."
},
"Tags" : {
"Values" : [ "string" ],
"Key" : "The key for the tag."
}
} ],
"Dimensions" : {
"Values" : [ "string" ],
"Key" : "The names of the metadata types that you can use to filter and group your results. For example, AZ returns a list of Availability Zones."
},
"Tags" : {
"Values" : [ "string" ],
"Key" : "The key for the tag."
}
} ],
"And" : [ {
"Not" : {
"Not" : "Expression",
"Or" : [ {
"Not" : "Expression",
"Or" : "Expressions",
"And" : "Expressions",
"Dimensions" : {
"Values" : [ "string" ],
"Key" : "The names of the metadata types that you can use to filter and group your results. For example, AZ returns a list of Availability Zones."
},
"Tags" : {
"Values" : [ "string" ],
"Key" : "The key for the tag."
}
} ],
"And" : "Expressions",
"Dimensions" : {
"Values" : [ "string" ],
"Key" : "The names of the metadata types that you can use to filter and group your results. For example, AZ returns a list of Availability Zones."
},
"Tags" : {
"Values" : [ "string" ],
"Key" : "The key for the tag."
}
},
"Or" : [ {
"Not" : {
"Not" : "Expression",
"Or" : "Expressions",
"And" : "Expressions",
"Dimensions" : {
"Values" : [ "string" ],
"Key" : "The names of the metadata types that you can use to filter and group your results. For example, AZ returns a list of Availability Zones."
},
"Tags" : {
"Values" : [ "string" ],
"Key" : "The key for the tag."
}
},
"Or" : "Expressions",
"And" : "Expressions",
"Dimensions" : {
"Values" : [ "string" ],
"Key" : "The names of the metadata types that you can use to filter and group your results. For example, AZ returns a list of Availability Zones."
},
"Tags" : {
"Values" : [ "string" ],
"Key" : "The key for the tag."
}
} ],
"And" : "Expressions",
"Dimensions" : {
"Values" : [ "string" ],
"Key" : "The names of the metadata types that you can use to filter and group your results. For example, AZ returns a list of Availability Zones."
},
"Tags" : {
"Values" : [ "string" ],
"Key" : "The key for the tag."
}
} ],
"Dimensions" : {
"Values" : [ "string" ],
"Key" : "The names of the metadata types that you can use to filter and group your results. For example, AZ returns a list of Availability Zones."
},
"Tags" : {
"Values" : [ "string" ],
"Key" : "The key for the tag."
}
},
"TimePeriod" : {
"Start" : "The beginning of the time period that you want the usage and costs for. The start date is inclusive. For example, if start is 2017-01-01, AWS retrieves cost and usage data starting at 2017-01-01 up to the end date.",
"End" : "The end of the time period that you want the usage and costs for. The end date is exclusive. For example, if end is 2017-05-01, AWS retrieves cost and usage data from the start date up to, but not including, 2017-05-01."
},
"NextPageToken" : "The token to retrieve the next set of results. AWS provides the token when the response from a previous call has more results than the maximum page size.",
"Granularity" : "Sets the AWS cost granularity to MONTHLY or DAILY. If Granularity isn't set, the response object doesn't include the Granularity, either MONTHLY or DAILY. \nThe GetCostAndUsageRequest operation supports only DAILY and MONTHLY granularities."
}

get_cost_forecast

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.

Parameters

$body

Type: object

{
"Filter" : {
"Not" : {
"Not" : "Expression",
"Or" : [ {
"Not" : "Expression",
"Or" : "Expressions",
"And" : [ {
"Not" : "Expression",
"Or" : "Expressions",
"And" : "Expressions",
"Dimensions" : {
"Values" : [ "string" ],
"Key" : "The names of the metadata types that you can use to filter and group your results. For example, AZ returns a list of Availability Zones."
},
"Tags" : {
"Values" : [ "string" ],
"Key" : "The key for the tag."
}
} ],
"Dimensions" : {
"Values" : [ "string" ],
"Key" : "The names of the metadata types that you can use to filter and group your results. For example, AZ returns a list of Availability Zones."
},
"Tags" : {
"Values" : [ "string" ],
"Key" : "The key for the tag."
}
} ],
"And" : [ {
"Not" : "Expression",
"Or" : [ {
"Not" : "Expression",
"Or" : "Expressions",
"And" : "Expressions",
"Dimensions" : {
"Values" : [ "string" ],
"Key" : "The names of the metadata types that you can use to filter and group your results. For example, AZ returns a list of Availability Zones."
},
"Tags" : {
"Values" : [ "string" ],
"Key" : "The key for the tag."
}
} ],
"And" : "Expressions",
"Dimensions" : {
"Values" : [ "string" ],
"Key" : "The names of the metadata types that you can use to filter and group your results. For example, AZ returns a list of Availability Zones."
},
"Tags" : {
"Values" : [ "string" ],
"Key" : "The key for the tag."
}
} ],
"Dimensions" : {
"Values" : [ "string" ],
"Key" : "The names of the metadata types that you can use to filter and group your results. For example, AZ returns a list of Availability Zones."
},
"Tags" : {
"Values" : [ "string" ],
"Key" : "The key for the tag."
}
},
"Or" : [ {
"Not" : {
"Not" : "Expression",
"Or" : "Expressions",
"And" : [ {
"Not" : "Expression",
"Or" : "Expressions",
"And" : "Expressions",
"Dimensions" : {
"Values" : [ "string" ],
"Key" : "The names of the metadata types that you can use to filter and group your results. For example, AZ returns a list of Availability Zones."
},
"Tags" : {
"Values" : [ "string" ],
"Key" : "The key for the tag."
}
} ],
"Dimensions" : {
"Values" : [ "string" ],
"Key" : "The names of the metadata types that you can use to filter and group your results. For example, AZ returns a list of Availability Zones."
},
"Tags" : {
"Values" : [ "string" ],
"Key" : "The key for the tag."
}
},
"Or" : "Expressions",
"And" : [ {
"Not" : {
"Not" : "Expression",
"Or" : "Expressions",
"And" : "Expressions",
"Dimensions" : {
"Values" : [ "string" ],
"Key" : "The names of the metadata types that you can use to filter and group your results. For example, AZ returns a list of Availability Zones."
},
"Tags" : {
"Values" : [ "string" ],
"Key" : "The key for the tag."
}
},
"Or" : "Expressions",
"And" : "Expressions",
"Dimensions" : {
"Values" : [ "string" ],
"Key" : "The names of the metadata types that you can use to filter and group your results. For example, AZ returns a list of Availability Zones."
},
"Tags" : {
"Values" : [ "string" ],
"Key" : "The key for the tag."
}
} ],
"Dimensions" : {
"Values" : [ "string" ],
"Key" : "The names of the metadata types that you can use to filter and group your results. For example, AZ returns a list of Availability Zones."
},
"Tags" : {
"Values" : [ "string" ],
"Key" : "The key for the tag."
}
} ],
"And" : [ {
"Not" : {
"Not" : "Expression",
"Or" : [ {
"Not" : "Expression",
"Or" : "Expressions",
"And" : "Expressions",
"Dimensions" : {
"Values" : [ "string" ],
"Key" : "The names of the metadata types that you can use to filter and group your results. For example, AZ returns a list of Availability Zones."
},
"Tags" : {
"Values" : [ "string" ],
"Key" : "The key for the tag."
}
} ],
"And" : "Expressions",
"Dimensions" : {
"Values" : [ "string" ],
"Key" : "The names of the metadata types that you can use to filter and group your results. For example, AZ returns a list of Availability Zones."
},
"Tags" : {
"Values" : [ "string" ],
"Key" : "The key for the tag."
}
},
"Or" : [ {
"Not" : {
"Not" : "Expression",
"Or" : "Expressions",
"And" : "Expressions",
"Dimensions" : {
"Values" : [ "string" ],
"Key" : "The names of the metadata types that you can use to filter and group your results. For example, AZ returns a list of Availability Zones."
},
"Tags" : {
"Values" : [ "string" ],
"Key" : "The key for the tag."
}
},
"Or" : "Expressions",
"And" : "Expressions",
"Dimensions" : {
"Values" : [ "string" ],
"Key" : "The names of the metadata types that you can use to filter and group your results. For example, AZ returns a list of Availability Zones."
},
"Tags" : {
"Values" : [ "string" ],
"Key" : "The key for the tag."
}
} ],
"And" : "Expressions",
"Dimensions" : {
"Values" : [ "string" ],
"Key" : "The names of the metadata types that you can use to filter and group your results. For example, AZ returns a list of Availability Zones."
},
"Tags" : {
"Values" : [ "string" ],
"Key" : "The key for the tag."
}
} ],
"Dimensions" : {
"Values" : [ "string" ],
"Key" : "The names of the metadata types that you can use to filter and group your results. For example, AZ returns a list of Availability Zones."
},
"Tags" : {
"Values" : [ "string" ],
"Key" : "The key for the tag."
}
},
"TimePeriod" : {
"Start" : "The beginning of the time period that you want the usage and costs for. The start date is inclusive. For example, if start is 2017-01-01, AWS retrieves cost and usage data starting at 2017-01-01 up to the end date.",
"End" : "The end of the time period that you want the usage and costs for. The end date is exclusive. For example, if end is 2017-05-01, AWS retrieves cost and usage data from the start date up to, but not including, 2017-05-01."
},
"Metric" : "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?. \nValid values for a GetCostForecast call are the following: \n AMORTIZED_COST \n BLENDED_COST \n NET_AMORTIZED_COST \n NET_UNBLENDED_COST \n UNBLENDED_COST ",
"Granularity" : "How granular you want the forecast to be. You can get 3 months of DAILY forecasts or 12 months of MONTHLY forecasts. \nThe GetCostForecast operation supports only DAILY and MONTHLY granularities.",
"PredictionIntervalLevel" : "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."
}

get_dimension_values

Retrieves all available filter values for a specified filter over a period of time. You can search the dimension values for an arbitrary string.

Parameters

$body

Type: object

{
"Context" : "The context for the call to GetDimensionValues. This can be RESERVATIONS or COST_AND_USAGE. The default value is COST_AND_USAGE. If the context is set to RESERVATIONS, the resulting dimension values can be used in the GetReservationUtilization operation. If the context is set to COST_AND_USAGE, the resulting dimension values can be used in the GetCostAndUsage operation. \nIf you set the context to COST_AND_USAGE, you can use the following dimensions for searching: \n AZ - The Availability Zone. An example is us-east-1a. \n DATABASE_ENGINE - The Amazon Relational Database Service database. Examples are Aurora or MySQL. \n INSTANCE_TYPE - The type of Amazon EC2 instance. An example is m4.xlarge. \n LEGAL_ENTITY_NAME - The name of the organization that sells you AWS services, such as Amazon Web Services. \n LINKED_ACCOUNT - The description in the attribute map that includes the full name of the member account. The value field contains the AWS ID of the member account. \n OPERATING_SYSTEM - The operating system. Examples are Windows or Linux. \n OPERATION - The action performed. Examples include RunInstance and CreateBucket. \n PLATFORM - The Amazon EC2 operating system. Examples are Windows or Linux. \n PURCHASE_TYPE - The reservation type of the purchase to which this usage is related. Examples include On-Demand Instances and Standard Reserved Instances. \n SERVICE - The AWS service such as Amazon DynamoDB. \n USAGE_TYPE - The type of usage. An example is DataTransfer-In-Bytes. The response for the GetDimensionValues operation includes a unit attribute. Examples include GB and Hrs. \n 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. \n RECORD_TYPE - The different types of charges such as RI fees, usage costs, tax refunds, and credits. \nIf you set the context to RESERVATIONS, you can use the following dimensions for searching: \n AZ - The Availability Zone. An example is us-east-1a. \n CACHE_ENGINE - The Amazon ElastiCache operating system. Examples are Windows or Linux. \n DEPLOYMENT_OPTION - The scope of Amazon Relational Database Service deployments. Valid values are SingleAZ and MultiAZ. \n INSTANCE_TYPE - The type of Amazon EC2 instance. An example is m4.xlarge. \n LINKED_ACCOUNT - The description in the attribute map that includes the full name of the member account. The value field contains the AWS ID of the member account. \n PLATFORM - The Amazon EC2 operating system. Examples are Windows or Linux. \n REGION - The AWS Region. \n SCOPE (Utilization only) - The scope of a Reserved Instance (RI). Values are regional or a single Availability Zone. \n TAG (Coverage only) - The tags that are associated with a Reserved Instance (RI). \n TENANCY - The tenancy of a resource. Examples are shared or dedicated. ",
"TimePeriod" : {
"Start" : "The beginning of the time period that you want the usage and costs for. The start date is inclusive. For example, if start is 2017-01-01, AWS retrieves cost and usage data starting at 2017-01-01 up to the end date.",
"End" : "The end of the time period that you want the usage and costs for. The end date is exclusive. For example, if end is 2017-05-01, AWS retrieves cost and usage data from the start date up to, but not including, 2017-05-01."
},
"NextPageToken" : "The token to retrieve the next set of results. AWS provides the token when the response from a previous call has more results than the maximum page size.",
"Dimension" : "The name of the dimension. Each Dimension is available for a different Context. For more information, see Context.",
"SearchString" : "The value that you want to search the filter values for."
}

get_reservation_coverage

Retrieves the reservation coverage for your account. This enables you 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 master account can see the coverage of the associated member accounts. 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.

Parameters

$body

You can use the following request parameters to query for how much of your instance usage a reservation covered.

Type: object

{
"Metrics" : [ "string" ],
"GroupBy" : [ {
"Type" : "The string that represents the type of group.",
"Key" : "The string that represents a key for a specified group."
} ],
"Filter" : {
"Not" : {
"Not" : "Expression",
"Or" : [ {
"Not" : "Expression",
"Or" : "Expressions",
"And" : [ {
"Not" : "Expression",
"Or" : "Expressions",
"And" : "Expressions",
"Dimensions" : {
"Values" : [ "string" ],
"Key" : "The names of the metadata types that you can use to filter and group your results. For example, AZ returns a list of Availability Zones."
},
"Tags" : {
"Values" : [ "string" ],
"Key" : "The key for the tag."
}
} ],
"Dimensions" : {
"Values" : [ "string" ],
"Key" : "The names of the metadata types that you can use to filter and group your results. For example, AZ returns a list of Availability Zones."
},
"Tags" : {
"Values" : [ "string" ],
"Key" : "The key for the tag."
}
} ],
"And" : [ {
"Not" : "Expression",
"Or" : [ {
"Not" : "Expression",
"Or" : "Expressions",
"And" : "Expressions",
"Dimensions" : {
"Values" : [ "string" ],
"Key" : "The names of the metadata types that you can use to filter and group your results. For example, AZ returns a list of Availability Zones."
},
"Tags" : {
"Values" : [ "string" ],
"Key" : "The key for the tag."
}
} ],
"And" : "Expressions",
"Dimensions" : {
"Values" : [ "string" ],
"Key" : "The names of the metadata types that you can use to filter and group your results. For example, AZ returns a list of Availability Zones."
},
"Tags" : {
"Values" : [ "string" ],
"Key" : "The key for the tag."
}
} ],
"Dimensions" : {
"Values" : [ "string" ],
"Key" : "The names of the metadata types that you can use to filter and group your results. For example, AZ returns a list of Availability Zones."
},
"Tags" : {
"Values" : [ "string" ],
"Key" : "The key for the tag."
}
},
"Or" : [ {
"Not" : {
"Not" : "Expression",
"Or" : "Expressions",
"And" : [ {
"Not" : "Expression",
"Or" : "Expressions",
"And" : "Expressions",
"Dimensions" : {
"Values" : [ "string" ],
"Key" : "The names of the metadata types that you can use to filter and group your results. For example, AZ returns a list of Availability Zones."
},
"Tags" : {
"Values" : [ "string" ],
"Key" : "The key for the tag."
}
} ],
"Dimensions" : {
"Values" : [ "string" ],
"Key" : "The names of the metadata types that you can use to filter and group your results. For example, AZ returns a list of Availability Zones."
},
"Tags" : {
"Values" : [ "string" ],
"Key" : "The key for the tag."
}
},
"Or" : "Expressions",
"And" : [ {
"Not" : {
"Not" : "Expression",
"Or" : "Expressions",
"And" : "Expressions",
"Dimensions" : {
"Values" : [ "string" ],
"Key" : "The names of the metadata types that you can use to filter and group your results. For example, AZ returns a list of Availability Zones."
},
"Tags" : {
"Values" : [ "string" ],
"Key" : "The key for the tag."
}
},
"Or" : "Expressions",
"And" : "Expressions",
"Dimensions" : {
"Values" : [ "string" ],
"Key" : "The names of the metadata types that you can use to filter and group your results. For example, AZ returns a list of Availability Zones."
},
"Tags" : {
"Values" : [ "string" ],
"Key" : "The key for the tag."
}
} ],
"Dimensions" : {
"Values" : [ "string" ],
"Key" : "The names of the metadata types that you can use to filter and group your results. For example, AZ returns a list of Availability Zones."
},
"Tags" : {
"Values" : [ "string" ],
"Key" : "The key for the tag."
}
} ],
"And" : [ {
"Not" : {
"Not" : "Expression",
"Or" : [ {
"Not" : "Expression",
"Or" : "Expressions",
"And" : "Expressions",
"Dimensions" : {
"Values" : [ "string" ],
"Key" : "The names of the metadata types that you can use to filter and group your results. For example, AZ returns a list of Availability Zones."
},
"Tags" : {
"Values" : [ "string" ],
"Key" : "The key for the tag."
}
} ],
"And" : "Expressions",
"Dimensions" : {
"Values" : [ "string" ],
"Key" : "The names of the metadata types that you can use to filter and group your results. For example, AZ returns a list of Availability Zones."
},
"Tags" : {
"Values" : [ "string" ],
"Key" : "The key for the tag."
}
},
"Or" : [ {
"Not" : {
"Not" : "Expression",
"Or" : "Expressions",
"And" : "Expressions",
"Dimensions" : {
"Values" : [ "string" ],
"Key" : "The names of the metadata types that you can use to filter and group your results. For example, AZ returns a list of Availability Zones."
},
"Tags" : {
"Values" : [ "string" ],
"Key" : "The key for the tag."
}
},
"Or" : "Expressions",
"And" : "Expressions",
"Dimensions" : {
"Values" : [ "string" ],
"Key" : "The names of the metadata types that you can use to filter and group your results. For example, AZ returns a list of Availability Zones."
},
"Tags" : {
"Values" : [ "string" ],
"Key" : "The key for the tag."
}
} ],
"And" : "Expressions",
"Dimensions" : {
"Values" : [ "string" ],
"Key" : "The names of the metadata types that you can use to filter and group your results. For example, AZ returns a list of Availability Zones."
},
"Tags" : {
"Values" : [ "string" ],
"Key" : "The key for the tag."
}
} ],
"Dimensions" : {
"Values" : [ "string" ],
"Key" : "The names of the metadata types that you can use to filter and group your results. For example, AZ returns a list of Availability Zones."
},
"Tags" : {
"Values" : [ "string" ],
"Key" : "The key for the tag."
}
},
"TimePeriod" : {
"Start" : "The beginning of the time period that you want the usage and costs for. The start date is inclusive. For example, if start is 2017-01-01, AWS retrieves cost and usage data starting at 2017-01-01 up to the end date.",
"End" : "The end of the time period that you want the usage and costs for. The end date is exclusive. For example, if end is 2017-05-01, AWS retrieves cost and usage data from the start date up to, but not including, 2017-05-01."
},
"NextPageToken" : "The token to retrieve the next set of results. AWS provides the token when the response from a previous call has more results than the maximum page size.",
"Granularity" : "The granularity of the AWS cost data for the reservation. Valid values are MONTHLY and DAILY. \nIf GroupBy is set, Granularity can't be set. If Granularity isn't set, the response object doesn't include Granularity, either MONTHLY or DAILY. \nThe GetReservationCoverage operation supports only DAILY and MONTHLY granularities."
}

get_reservation_purchase_recommendation

Gets recommendations for which reservations to purchase. These recommendations could help you reduce your costs. Reservations provide a discounted hourly rate (up to 75%) compared to On-Demand pricing.
AWS 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 AWS has these categories, it simulates every combination of reservations in each category of usage to identify the best number of each type of RI to purchase to maximize your estimated savings.
For example, AWS 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. AWS recommends the smallest size instance in an instance family. This makes it easier to purchase a size-flexible RI. AWS also shows the equal number of normalized units so that you can purchase any instance size that you want. For this example, your RI recommendation would be for c4.large because that is the smallest size instance in the c4 instance family.

Parameters

$body

Type: object

{
"ServiceSpecification" : {
"EC2Specification" : {
"OfferingClass" : "Whether you want a recommendation for standard or convertible reservations."
}
},
"AccountId" : "The account ID that is associated with the recommendation. ",
"PageSize" : "The number of recommendations that you want returned in a single response object.",
"LookbackPeriodInDays" : "The number of previous days that you want AWS to consider when it calculates your recommendations.",
"NextPageToken" : "The pagination token that indicates the next set of results that you want to retrieve.",
"Service" : "The specific service that you want recommendations for.",
"PaymentOption" : "The reservation purchase option that you want recommendations for.",
"TermInYears" : "The reservation term that you want recommendations for.",
"AccountScope" : "The account scope that you want recommendations for. PAYER means that AWS includes the master account and any member accounts when it calculates its recommendations. LINKED means that AWS includes only member accounts when it calculates its recommendations. \nValid values are PAYER and LINKED."
}

get_reservation_utilization

Retrieves the reservation utilization for your account. Master accounts 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.

Parameters

$body

Type: object

{
"GroupBy" : [ {
"Type" : "The string that represents the type of group.",
"Key" : "The string that represents a key for a specified group."
} ],
"Filter" : {
"Not" : {
"Not" : "Expression",
"Or" : [ {
"Not" : "Expression",
"Or" : "Expressions",
"And" : [ {
"Not" : "Expression",
"Or" : "Expressions",
"And" : "Expressions",
"Dimensions" : {
"Values" : [ "string" ],
"Key" : "The names of the metadata types that you can use to filter and group your results. For example, AZ returns a list of Availability Zones."
},
"Tags" : {
"Values" : [ "string" ],
"Key" : "The key for the tag."
}
} ],
"Dimensions" : {
"Values" : [ "string" ],
"Key" : "The names of the metadata types that you can use to filter and group your results. For example, AZ returns a list of Availability Zones."
},
"Tags" : {
"Values" : [ "string" ],
"Key" : "The key for the tag."
}
} ],
"And" : [ {
"Not" : "Expression",
"Or" : [ {
"Not" : "Expression",
"Or" : "Expressions",
"And" : "Expressions",
"Dimensions" : {
"Values" : [ "string" ],
"Key" : "The names of the metadata types that you can use to filter and group your results. For example, AZ returns a list of Availability Zones."
},
"Tags" : {
"Values" : [ "string" ],
"Key" : "The key for the tag."
}
} ],
"And" : "Expressions",
"Dimensions" : {
"Values" : [ "string" ],
"Key" : "The names of the metadata types that you can use to filter and group your results. For example, AZ returns a list of Availability Zones."
},
"Tags" : {
"Values" : [ "string" ],
"Key" : "The key for the tag."
}
} ],
"Dimensions" : {
"Values" : [ "string" ],
"Key" : "The names of the metadata types that you can use to filter and group your results. For example, AZ returns a list of Availability Zones."
},
"Tags" : {
"Values" : [ "string" ],
"Key" : "The key for the tag."
}
},
"Or" : [ {
"Not" : {
"Not" : "Expression",
"Or" : "Expressions",
"And" : [ {
"Not" : "Expression",
"Or" : "Expressions",
"And" : "Expressions",
"Dimensions" : {
"Values" : [ "string" ],
"Key" : "The names of the metadata types that you can use to filter and group your results. For example, AZ returns a list of Availability Zones."
},
"Tags" : {
"Values" : [ "string" ],
"Key" : "The key for the tag."
}
} ],
"Dimensions" : {
"Values" : [ "string" ],
"Key" : "The names of the metadata types that you can use to filter and group your results. For example, AZ returns a list of Availability Zones."
},
"Tags" : {
"Values" : [ "string" ],
"Key" : "The key for the tag."
}
},
"Or" : "Expressions",
"And" : [ {
"Not" : {
"Not" : "Expression",
"Or" : "Expressions",
"And" : "Expressions",
"Dimensions" : {
"Values" : [ "string" ],
"Key" : "The names of the metadata types that you can use to filter and group your results. For example, AZ returns a list of Availability Zones."
},
"Tags" : {
"Values" : [ "string" ],
"Key" : "The key for the tag."
}
},
"Or" : "Expressions",
"And" : "Expressions",
"Dimensions" : {
"Values" : [ "string" ],
"Key" : "The names of the metadata types that you can use to filter and group your results. For example, AZ returns a list of Availability Zones."
},
"Tags" : {
"Values" : [ "string" ],
"Key" : "The key for the tag."
}
} ],
"Dimensions" : {
"Values" : [ "string" ],
"Key" : "The names of the metadata types that you can use to filter and group your results. For example, AZ returns a list of Availability Zones."
},
"Tags" : {
"Values" : [ "string" ],
"Key" : "The key for the tag."
}
} ],
"And" : [ {
"Not" : {
"Not" : "Expression",
"Or" : [ {
"Not" : "Expression",
"Or" : "Expressions",
"And" : "Expressions",
"Dimensions" : {
"Values" : [ "string" ],
"Key" : "The names of the metadata types that you can use to filter and group your results. For example, AZ returns a list of Availability Zones."
},
"Tags" : {
"Values" : [ "string" ],
"Key" : "The key for the tag."
}
} ],
"And" : "Expressions",
"Dimensions" : {
"Values" : [ "string" ],
"Key" : "The names of the metadata types that you can use to filter and group your results. For example, AZ returns a list of Availability Zones."
},
"Tags" : {
"Values" : [ "string" ],
"Key" : "The key for the tag."
}
},
"Or" : [ {
"Not" : {
"Not" : "Expression",
"Or" : "Expressions",
"And" : "Expressions",
"Dimensions" : {
"Values" : [ "string" ],
"Key" : "The names of the metadata types that you can use to filter and group your results. For example, AZ returns a list of Availability Zones."
},
"Tags" : {
"Values" : [ "string" ],
"Key" : "The key for the tag."
}
},
"Or" : "Expressions",
"And" : "Expressions",
"Dimensions" : {
"Values" : [ "string" ],
"Key" : "The names of the metadata types that you can use to filter and group your results. For example, AZ returns a list of Availability Zones."
},
"Tags" : {
"Values" : [ "string" ],
"Key" : "The key for the tag."
}
} ],
"And" : "Expressions",
"Dimensions" : {
"Values" : [ "string" ],
"Key" : "The names of the metadata types that you can use to filter and group your results. For example, AZ returns a list of Availability Zones."
},
"Tags" : {
"Values" : [ "string" ],
"Key" : "The key for the tag."
}
} ],
"Dimensions" : {
"Values" : [ "string" ],
"Key" : "The names of the metadata types that you can use to filter and group your results. For example, AZ returns a list of Availability Zones."
},
"Tags" : {
"Values" : [ "string" ],
"Key" : "The key for the tag."
}
},
"TimePeriod" : {
"Start" : "The beginning of the time period that you want the usage and costs for. The start date is inclusive. For example, if start is 2017-01-01, AWS retrieves cost and usage data starting at 2017-01-01 up to the end date.",
"End" : "The end of the time period that you want the usage and costs for. The end date is exclusive. For example, if end is 2017-05-01, AWS retrieves cost and usage data from the start date up to, but not including, 2017-05-01."
},
"NextPageToken" : "The token to retrieve the next set of results. AWS provides the token when the response from a previous call has more results than the maximum page size.",
"Granularity" : "If GroupBy is set, Granularity can't be set. If Granularity isn't set, the response object doesn't include Granularity, either MONTHLY or DAILY. If both GroupBy and Granularity aren't set, GetReservationUtilization defaults to DAILY. \nThe GetReservationUtilization operation supports only DAILY and MONTHLY granularities."
}

get_rightsizing_recommendation

Creates recommendations that helps 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 details on calculation and function, see Optimizing Your Cost with Rightsizing Recommendations.

Parameters

$body

Type: object

{
"PageSize" : "The number of recommendations that you want returned in a single response object.",
"Filter" : {
"Not" : {
"Not" : "Expression",
"Or" : [ {
"Not" : "Expression",
"Or" : "Expressions",
"And" : [ {
"Not" : "Expression",
"Or" : "Expressions",
"And" : "Expressions",
"Dimensions" : {
"Values" : [ "string" ],
"Key" : "The names of the metadata types that you can use to filter and group your results. For example, AZ returns a list of Availability Zones."
},
"Tags" : {
"Values" : [ "string" ],
"Key" : "The key for the tag."
}
} ],
"Dimensions" : {
"Values" : [ "string" ],
"Key" : "The names of the metadata types that you can use to filter and group your results. For example, AZ returns a list of Availability Zones."
},
"Tags" : {
"Values" : [ "string" ],
"Key" : "The key for the tag."
}
} ],
"And" : [ {
"Not" : "Expression",
"Or" : [ {
"Not" : "Expression",
"Or" : "Expressions",
"And" : "Expressions",
"Dimensions" : {
"Values" : [ "string" ],
"Key" : "The names of the metadata types that you can use to filter and group your results. For example, AZ returns a list of Availability Zones."
},
"Tags" : {
"Values" : [ "string" ],
"Key" : "The key for the tag."
}
} ],
"And" : "Expressions",
"Dimensions" : {
"Values" : [ "string" ],
"Key" : "The names of the metadata types that you can use to filter and group your results. For example, AZ returns a list of Availability Zones."
},
"Tags" : {
"Values" : [ "string" ],
"Key" : "The key for the tag."
}
} ],
"Dimensions" : {
"Values" : [ "string" ],
"Key" : "The names of the metadata types that you can use to filter and group your results. For example, AZ returns a list of Availability Zones."
},
"Tags" : {
"Values" : [ "string" ],
"Key" : "The key for the tag."
}
},
"Or" : [ {
"Not" : {
"Not" : "Expression",
"Or" : "Expressions",
"And" : [ {
"Not" : "Expression",
"Or" : "Expressions",
"And" : "Expressions",
"Dimensions" : {
"Values" : [ "string" ],
"Key" : "The names of the metadata types that you can use to filter and group your results. For example, AZ returns a list of Availability Zones."
},
"Tags" : {
"Values" : [ "string" ],
"Key" : "The key for the tag."
}
} ],
"Dimensions" : {
"Values" : [ "string" ],
"Key" : "The names of the metadata types that you can use to filter and group your results. For example, AZ returns a list of Availability Zones."
},
"Tags" : {
"Values" : [ "string" ],
"Key" : "The key for the tag."
}
},
"Or" : "Expressions",
"And" : [ {
"Not" : {
"Not" : "Expression",
"Or" : "Expressions",
"And" : "Expressions",
"Dimensions" : {
"Values" : [ "string" ],
"Key" : "The names of the metadata types that you can use to filter and group your results. For example, AZ returns a list of Availability Zones."
},
"Tags" : {
"Values" : [ "string" ],
"Key" : "The key for the tag."
}
},
"Or" : "Expressions",
"And" : "Expressions",
"Dimensions" : {
"Values" : [ "string" ],
"Key" : "The names of the metadata types that you can use to filter and group your results. For example, AZ returns a list of Availability Zones."
},
"Tags" : {
"Values" : [ "string" ],
"Key" : "The key for the tag."
}
} ],
"Dimensions" : {
"Values" : [ "string" ],
"Key" : "The names of the metadata types that you can use to filter and group your results. For example, AZ returns a list of Availability Zones."
},
"Tags" : {
"Values" : [ "string" ],
"Key" : "The key for the tag."
}
} ],
"And" : [ {
"Not" : {
"Not" : "Expression",
"Or" : [ {
"Not" : "Expression",
"Or" : "Expressions",
"And" : "Expressions",
"Dimensions" : {
"Values" : [ "string" ],
"Key" : "The names of the metadata types that you can use to filter and group your results. For example, AZ returns a list of Availability Zones."
},
"Tags" : {
"Values" : [ "string" ],
"Key" : "The key for the tag."
}
} ],
"And" : "Expressions",
"Dimensions" : {
"Values" : [ "string" ],
"Key" : "The names of the metadata types that you can use to filter and group your results. For example, AZ returns a list of Availability Zones."
},
"Tags" : {
"Values" : [ "string" ],
"Key" : "The key for the tag."
}
},
"Or" : [ {
"Not" : {
"Not" : "Expression",
"Or" : "Expressions",
"And" : "Expressions",
"Dimensions" : {
"Values" : [ "string" ],
"Key" : "The names of the metadata types that you can use to filter and group your results. For example, AZ returns a list of Availability Zones."
},
"Tags" : {
"Values" : [ "string" ],
"Key" : "The key for the tag."
}
},
"Or" : "Expressions",
"And" : "Expressions",
"Dimensions" : {
"Values" : [ "string" ],
"Key" : "The names of the metadata types that you can use to filter and group your results. For example, AZ returns a list of Availability Zones."
},
"Tags" : {
"Values" : [ "string" ],
"Key" : "The key for the tag."
}
} ],
"And" : "Expressions",
"Dimensions" : {
"Values" : [ "string" ],
"Key" : "The names of the metadata types that you can use to filter and group your results. For example, AZ returns a list of Availability Zones."
},
"Tags" : {
"Values" : [ "string" ],
"Key" : "The key for the tag."
}
} ],
"Dimensions" : {
"Values" : [ "string" ],
"Key" : "The names of the metadata types that you can use to filter and group your results. For example, AZ returns a list of Availability Zones."
},
"Tags" : {
"Values" : [ "string" ],
"Key" : "The key for the tag."
}
},
"NextPageToken" : "The pagination token that indicates the next set of results that you want to retrieve.",
"Service" : "The specific service that you want recommendations for."
}

get_tags

Queries for available tag keys and tag values for a specified period. You can search the tag values for an arbitrary string.

Parameters

$body

Type: object

{
"TimePeriod" : {
"Start" : "The beginning of the time period that you want the usage and costs for. The start date is inclusive. For example, if start is 2017-01-01, AWS retrieves cost and usage data starting at 2017-01-01 up to the end date.",
"End" : "The end of the time period that you want the usage and costs for. The end date is exclusive. For example, if end is 2017-05-01, AWS retrieves cost and usage data from the start date up to, but not including, 2017-05-01."
},
"NextPageToken" : "The token to retrieve the next set of results. AWS provides the token when the response from a previous call has more results than the maximum page size.",
"TagKey" : "The key of the tag that you want to return values for.",
"SearchString" : "The value that you want to search for."
}

get_usage_forecast

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.

Parameters

$body

Type: object

{
"Filter" : {
"Not" : {
"Not" : "Expression",
"Or" : [ {
"Not" : "Expression",
"Or" : "Expressions",
"And" : [ {
"Not" : "Expression",
"Or" : "Expressions",
"And" : "Expressions",
"Dimensions" : {
"Values" : [ "string" ],
"Key" : "The names of the metadata types that you can use to filter and group your results. For example, AZ returns a list of Availability Zones."
},
"Tags" : {
"Values" : [ "string" ],
"Key" : "The key for the tag."
}
} ],
"Dimensions" : {
"Values" : [ "string" ],
"Key" : "The names of the metadata types that you can use to filter and group your results. For example, AZ returns a list of Availability Zones."
},
"Tags" : {
"Values" : [ "string" ],
"Key" : "The key for the tag."
}
} ],
"And" : [ {
"Not" : "Expression",
"Or" : [ {
"Not" : "Expression",
"Or" : "Expressions",
"And" : "Expressions",
"Dimensions" : {
"Values" : [ "string" ],
"Key" : "The names of the metadata types that you can use to filter and group your results. For example, AZ returns a list of Availability Zones."
},
"Tags" : {
"Values" : [ "string" ],
"Key" : "The key for the tag."
}
} ],
"And" : "Expressions",
"Dimensions" : {
"Values" : [ "string" ],
"Key" : "The names of the metadata types that you can use to filter and group your results. For example, AZ returns a list of Availability Zones."
},
"Tags" : {
"Values" : [ "string" ],
"Key" : "The key for the tag."
}
} ],
"Dimensions" : {
"Values" : [ "string" ],
"Key" : "The names of the metadata types that you can use to filter and group your results. For example, AZ returns a list of Availability Zones."
},
"Tags" : {
"Values" : [ "string" ],
"Key" : "The key for the tag."
}
},
"Or" : [ {
"Not" : {
"Not" : "Expression",
"Or" : "Expressions",
"And" : [ {
"Not" : "Expression",
"Or" : "Expressions",
"And" : "Expressions",
"Dimensions" : {
"Values" : [ "string" ],
"Key" : "The names of the metadata types that you can use to filter and group your results. For example, AZ returns a list of Availability Zones."
},
"Tags" : {
"Values" : [ "string" ],
"Key" : "The key for the tag."
}
} ],
"Dimensions" : {
"Values" : [ "string" ],
"Key" : "The names of the metadata types that you can use to filter and group your results. For example, AZ returns a list of Availability Zones."
},
"Tags" : {
"Values" : [ "string" ],
"Key" : "The key for the tag."
}
},
"Or" : "Expressions",
"And" : [ {
"Not" : {
"Not" : "Expression",
"Or" : "Expressions",
"And" : "Expressions",
"Dimensions" : {
"Values" : [ "string" ],
"Key" : "The names of the metadata types that you can use to filter and group your results. For example, AZ returns a list of Availability Zones."
},
"Tags" : {
"Values" : [ "string" ],
"Key" : "The key for the tag."
}
},
"Or" : "Expressions",
"And" : "Expressions",
"Dimensions" : {
"Values" : [ "string" ],
"Key" : "The names of the metadata types that you can use to filter and group your results. For example, AZ returns a list of Availability Zones."
},
"Tags" : {
"Values" : [ "string" ],
"Key" : "The key for the tag."
}
} ],
"Dimensions" : {
"Values" : [ "string" ],
"Key" : "The names of the metadata types that you can use to filter and group your results. For example, AZ returns a list of Availability Zones."
},
"Tags" : {
"Values" : [ "string" ],
"Key" : "The key for the tag."
}
} ],
"And" : [ {
"Not" : {
"Not" : "Expression",
"Or" : [ {
"Not" : "Expression",
"Or" : "Expressions",
"And" : "Expressions",
"Dimensions" : {
"Values" : [ "string" ],
"Key" : "The names of the metadata types that you can use to filter and group your results. For example, AZ returns a list of Availability Zones."
},
"Tags" : {
"Values" : [ "string" ],
"Key" : "The key for the tag."
}
} ],
"And" : "Expressions",
"Dimensions" : {
"Values" : [ "string" ],
"Key" : "The names of the metadata types that you can use to filter and group your results. For example, AZ returns a list of Availability Zones."
},
"Tags" : {
"Values" : [ "string" ],
"Key" : "The key for the tag."
}
},
"Or" : [ {
"Not" : {
"Not" : "Expression",
"Or" : "Expressions",
"And" : "Expressions",
"Dimensions" : {
"Values" : [ "string" ],
"Key" : "The names of the metadata types that you can use to filter and group your results. For example, AZ returns a list of Availability Zones."
},
"Tags" : {
"Values" : [ "string" ],
"Key" : "The key for the tag."
}
},
"Or" : "Expressions",
"And" : "Expressions",
"Dimensions" : {
"Values" : [ "string" ],
"Key" : "The names of the metadata types that you can use to filter and group your results. For example, AZ returns a list of Availability Zones."
},
"Tags" : {
"Values" : [ "string" ],
"Key" : "The key for the tag."
}
} ],
"And" : "Expressions",
"Dimensions" : {
"Values" : [ "string" ],
"Key" : "The names of the metadata types that you can use to filter and group your results. For example, AZ returns a list of Availability Zones."
},
"Tags" : {
"Values" : [ "string" ],
"Key" : "The key for the tag."
}
} ],
"Dimensions" : {
"Values" : [ "string" ],
"Key" : "The names of the metadata types that you can use to filter and group your results. For example, AZ returns a list of Availability Zones."
},
"Tags" : {
"Values" : [ "string" ],
"Key" : "The key for the tag."
}
},
"TimePeriod" : {
"Start" : "The beginning of the time period that you want the usage and costs for. The start date is inclusive. For example, if start is 2017-01-01, AWS retrieves cost and usage data starting at 2017-01-01 up to the end date.",
"End" : "The end of the time period that you want the usage and costs for. The end date is exclusive. For example, if end is 2017-05-01, AWS retrieves cost and usage data from the start date up to, but not including, 2017-05-01."
},
"Metric" : "Which metric Cost Explorer uses to create your forecast. \nValid values for a GetUsageForecast call are the following: \n USAGE_QUANTITY \n NORMALIZED_USAGE_AMOUNT ",
"Granularity" : "How granular you want the forecast to be. You can get 3 months of DAILY forecasts or 12 months of MONTHLY forecasts. \nThe GetUsageForecast operation supports only DAILY and MONTHLY granularities.",
"PredictionIntervalLevel" : "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."
}