Usage

Retrieve usage for this account

What this account has consumed and what remains. A hosted generation can cost more than one unit: a project generating TypeScript, Python, and Go consumes three, so callers that would otherwise discover the limit by receiving a 402 can check first.

GET
/usage

What this account has consumed and what remains. A hosted generation can cost more than one unit: a project generating TypeScript, Python, and Go consumes three, so callers that would otherwise discover the limit by receiving a 402 can check first.

AuthorizationBearer <token>

API key from the console, ak_....

In: header

Response Body

application/json

application/json

curl -X GET "https://example.com/usage"
{  "object": "usage",  "hosted_generations": {    "used": 0,    "included": 0,    "remaining": 0  },  "included_endpoints": 0,  "requests": {    "days": 0,    "requests": 0,    "by_surface": {      "property1": 0,      "property2": 0    },    "by_harness": {      "property1": 0,      "property2": 0    },    "agent_share": 0  }}