Skip to main content
GET
Get AI usage

Authorizations

Authorization
string
header
required

Boat bearer token in the form boat_.... Service API keys authenticate sandbox operations.

Headers

X-Boat-Org
string

Same as the org query parameter. Query wins when both are set.

Query Parameters

days
integer
default:30

Days of history, today included.

Required range: 1 <= x <= 365
profile
string

A credential profile id. Counts that profile's requests instead of a wallet's.

org
string

Billing wallet for this request: an organization you belong to, by id (team_…) or by name as GET /orgs lists it (case-insensitive), or personal. Omitted, the account's active wallet applies (PATCH /orgs/active; personal until set). Two organizations sharing the name answer 409 ambiguous_org and need the id. Sandboxes and snapshots stay creator-private. On /environments routes, only this query parameter selects the organization's shared environments; the X-Boat-Org header and the active wallet do not apply there. Members read them, owners and admins change them.

Response

The usage.

ok
boolean
required
Example:

true

type
string
required

Stable success envelope discriminator added by v1.

accountId
string | null
required

The wallet the usage is charged to. Null with profile.

profileId
string | null
required

The credential profile whose requests are counted. Null without profile.

since
string<date>
required

First UTC day included.

sandboxes
object[]
required
usage
object[]
required
totals
object
required

Token counts are the numbers the provider reports in its replies.

dollars
number
required