APIAPI reference
Calls in a billing period
GET /v1/usage
GET /v1/usage
Needs usage:read; readable with a web-app session, an API key or an OAuth token, for that credential's account. Member names and e-mails are included only for web-app sessions.
Authorization
This operation requires a bearer credential. The description defines additional role, scope or first-party-session restrictions; an API key does not grant those permissions by itself.
Parameters
| Property | Type | Required | Details |
|---|---|---|---|
period (query) | string ∣ null | no | YYYY-MM; defaults to the current month |
Request body
No request body.
Responses
| HTTP | Details | Type |
|---|---|---|
| 200 | Successful Response | application/json: Usage |
| 401 | Unauthorized | application/problem+json: ProblemDetails |
| 403 | Forbidden | application/problem+json: ProblemDetails |
| 404 | Not Found | application/problem+json: ProblemDetails |
| 422 | Unprocessable Entity | application/problem+json: ProblemDetails |
Response: Usage
| Property | Type | Required | Details |
|---|---|---|---|
account_id | string | yes | |
period | string | yes | Calendar month in UTC, YYYY-MM. |
period_start | string | yes | |
period_end | string | yes | Exclusive. |
plan | string | yes | |
included_calls | integer | yes | |
used_calls | integer | yes | Successful or reserved live calls; sandbox calls are separate. |
test_calls | integer | yes | |
test_included_calls | integer | yes | |
billed_microusd | integer | yes | Actual net prepaid spend, USD millionths, including in-flight reservations. |
credit_balance_microusd | integer | yes | |
trial_eligible | boolean | yes | |
recent_calls | CallLog[] | yes | Last 50 live and sandbox attempts; no request bodies or secrets. |
overage_calls | integer | yes | |
overage_usd_per_1000 | number | yes | |
estimated_overage_usd | number | yes | |
hard_limit | integer ∣ null | yes | Live count funded by allowance and remaining credits; null for internal accounts. |
by_day | DayUsage[] | yes | |
by_tool | ToolUsage[] | yes | |
by_channel | ChannelUsage[] | yes | |
by_user | UserUsage[] | yes | |
by_key | KeyUsage[] | yes | Calls made with API keys. |
by_connection | ConnectionUsage[] | yes | Calls made through OAuth clients (ChatGPT, Claude…). |
Full schema
{
"properties": {
"account_id": {
"type": "string",
"title": "Account Id"
},
"period": {
"type": "string",
"title": "Period",
"description": "Calendar month in UTC, YYYY-MM."
},
"period_start": {
"type": "string",
"format": "date",
"title": "Period Start"
},
"period_end": {
"type": "string",
"format": "date",
"title": "Period End",
"description": "Exclusive."
},
"plan": {
"type": "string",
"title": "Plan"
},
"included_calls": {
"type": "integer",
"title": "Included Calls"
},
"used_calls": {
"type": "integer",
"title": "Used Calls",
"description": "Successful or reserved live calls; sandbox calls are separate."
},
"test_calls": {
"type": "integer",
"title": "Test Calls"
},
"test_included_calls": {
"type": "integer",
"title": "Test Included Calls"
},
"billed_microusd": {
"type": "integer",
"title": "Billed Microusd",
"description": "Actual net prepaid spend, USD millionths, including in-flight reservations."
},
"credit_balance_microusd": {
"type": "integer",
"title": "Credit Balance Microusd"
},
"trial_eligible": {
"type": "boolean",
"title": "Trial Eligible"
},
"recent_calls": {
"items": {
"$ref": "#/components/schemas/CallLog"
},
"type": "array",
"title": "Recent Calls",
"description": "Last 50 live and sandbox attempts; no request bodies or secrets."
},
"overage_calls": {
"type": "integer",
"title": "Overage Calls"
},
"overage_usd_per_1000": {
"type": "number",
"title": "Overage Usd Per 1000"
},
"estimated_overage_usd": {
"type": "number",
"title": "Estimated Overage Usd"
},
"hard_limit": {
"anyOf": [
{
"type": "integer"
},
{
"type": "null"
}
],
"title": "Hard Limit",
"description": "Live count funded by allowance and remaining credits; null for internal accounts."
},
"by_day": {
"items": {
"$ref": "#/components/schemas/DayUsage"
},
"type": "array",
"title": "By Day"
},
"by_tool": {
"items": {
"$ref": "#/components/schemas/ToolUsage"
},
"type": "array",
"title": "By Tool"
},
"by_channel": {
"items": {
"$ref": "#/components/schemas/ChannelUsage"
},
"type": "array",
"title": "By Channel"
},
"by_user": {
"items": {
"$ref": "#/components/schemas/UserUsage"
},
"type": "array",
"title": "By User"
},
"by_key": {
"items": {
"$ref": "#/components/schemas/KeyUsage"
},
"type": "array",
"title": "By Key",
"description": "Calls made with API keys."
},
"by_connection": {
"items": {
"$ref": "#/components/schemas/ConnectionUsage"
},
"type": "array",
"title": "By Connection",
"description": "Calls made through OAuth clients (ChatGPT, Claude…)."
}
},
"type": "object",
"required": [
"account_id",
"period",
"period_start",
"period_end",
"plan",
"included_calls",
"used_calls",
"test_calls",
"test_included_calls",
"billed_microusd",
"credit_balance_microusd",
"trial_eligible",
"recent_calls",
"overage_calls",
"overage_usd_per_1000",
"estimated_overage_usd",
"hard_limit",
"by_day",
"by_tool",
"by_channel",
"by_user",
"by_key",
"by_connection"
],
"title": "Usage"
}This page is generated from OpenAPI; examples are schemas, not a fabricated successful response.