Skip to content

Returns the per-billing-month allocation history for credits applied to an Amazon Web Services account's bills

Description

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.

Usage

billing_get_credit_allocation_history(accountId, creditId, startDate,
  endDate, nextToken, maxResults)

Arguments

  • accountId

[required] The Amazon Web Services account ID whose allocation history to retrieve. Must be a 12-digit numeric string.

  • creditId

Filters the result to a single credit. When omitted, returns allocation entries for all credits.

  • startDate

[required] Inclusive start date as Unix epoch seconds. Must be on or before endDate. The range from startDate to endDate cannot exceed 24 billing months.

  • endDate

[required] Inclusive end date as Unix epoch seconds.

  • nextToken

Pagination token from a previous response. Pass the value returned in nextToken to retrieve the next page of results.

  • maxResults

The maximum number of records to return per page. Range: 1 to 1000. Default: 100.

Value

A list with the following syntax:

list(
  creditAllocationHistoryList = list(
    list(
      creditId = "string",
      creditAmount = list(
        currencyCode = "string",
        currencyAmount = "string"
      ),
      description = "string",
      accountId = "string",
      appliedServiceName = "string",
      billingMonth = "string",
      isEstimatedBill = TRUE|FALSE
    )
  ),
  partialResults = TRUE|FALSE,
  failedMonths = list(
    "string"
  ),
  nextToken = "string"
)

Request syntax

svc$get_credit_allocation_history(
  accountId = "string",
  creditId = 123,
  startDate = as.POSIXct(
    "2015-01-01"
  ),
  endDate = as.POSIXct(
    "2015-01-01"
  ),
  nextToken = "string",
  maxResults = 123
)