Skip to main content
GET
Usage of an API key
Requires an ADMIN key. An API key gets 403 with code: insufficient_permissions — see API Keys.
Return the cost, number of requests and number of errors of any key of the account, over a time window — the same report as Get Current Key Usage.

Authorizations

Authorization
string
header
required

Sanctum personal access token, sent as Authorization: Bearer <token>. The token is opaque — it carries no claims and no embedded expiry, so do not attempt to decode it. Issue and revoke tokens from your account dashboard.

Headers

Accept
enum<string>
default:application/json
required
Available options:
application/json

Path Parameters

id
integer
required

Query Parameters

from
string<date-time>

Start of the range, UTC, inclusive. Default: 7 days before to. Cannot be older than the data retention (90 days).

Example:

"2026-09-15T00:00:00Z"

to
string<date-time>

End of the range, UTC, exclusive. Default: now. An hourly breakdown covers at most 31 days.

Example:

"2026-09-22T00:00:00Z"

group_by
enum<string>
default:day
Available options:
day,
hour,
type,
model

Response

The report.

data
object