Skip to main content

credit_allocation_histories

Creates, updates, deletes, gets or lists a credit_allocation_histories resource.

Overview

Namecredit_allocation_histories
TypeResource
Idaws.billing.credit_allocation_histories

Fields

The following fields are returned by SELECT queries:

NameDatatypeDescription
account_idstringThe Amazon Web Services account the credit was applied to. (pattern: <code>[0-9]{12}</code>)
applied_service_namestringThe Amazon Web Services service the credit was applied to.
billing_monthstringThe billing month of the application in YYYY-MM format.
credit_amountobjectThe amount of credit applied. Negative values represent credits that reduced the bill.
credit_idstringThe identifier of the credit that was applied. (pattern: <code>[0-9]+</code>)
descriptionstringA human-readable description of the credit allocation.
is_estimated_billbooleantrue when the entry was applied to an in-flight bill that has not yet been finalized.

Methods

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
get_credit_allocation_historyselectregionReturns the per-billing-month allocation history for credits applied to an Amazon Web Services account's bills. Traverses the consolidated billing family to capture cross-account credit applications. Supports pagination and optional filtering to a single credit.

Parameters

Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.

NameDatatypeDescription
regionstringAWS region (default: us-east-1)

SELECT examples

Returns the per-billing-month allocation history for credits applied to an Amazon Web Services account's bills. Traverses the consolidated billing family to capture cross-account credit applications. Supports pagination and optional filtering to a single credit.

SELECT
account_id,
applied_service_name,
billing_month,
credit_amount,
credit_id,
description,
is_estimated_bill
FROM aws.billing.credit_allocation_histories
WHERE region = '{{ region }}' -- required
;