Skip to main content
GET
Typescript (SDK)

Authorizations

Authorization
string
header
required

API key in the format: Bearer {api_token}

Query Parameters

period
enum<string>

A named spend window in your time zone, instead of start_time and end_time (which it cannot be combined with): cycle (the current billing cycle, the default), today, last_7_days and last_30_days (each ending today), this_month or last_month.

Available options:
cycle,
today,
last_7_days,
last_30_days,
this_month,
last_month
start_time
string<date-time>

Start of the spend window, inclusive, as an ISO 8601 timestamp. Defaults to the start of the current billing cycle (the calendar month without a subscription).

end_time
string<date-time>

End of the spend window, exclusive, as an ISO 8601 timestamp. Defaults to the end of the current billing cycle. The window cannot exceed 366 days. credits, plan and forecast always describe the current billing cycle.

Response

Account usage

object
string
required
plan
required

ID by default, full object when expanded

credits
required

ID by default, full object when expanded

spend
required

ID by default, full object when expanded

forecast
required

ID by default, full object when expanded