Agent usage
curl --request GET \ --url http://127.0.0.1:8004/api/telemetry \ --header 'Authorization: Bearer <token>'Tokens, cost, requests, and tool calls per agent and model, per minute, for the last 24 hours, as agent view’s Usage tab shows them.
Authorizations
Section titled “Authorizations”Responses
Section titled “Responses”Each agent’s usage
object
Over all retained history and models.
object
Input includes cache reads and writes; cached tokens are a subset.
Reasoning is a subset of output tokens.
Most tokens first; an update holds only models with changed minutes.
object
None is usage reported without a model, such as Claude’s tool calls.
Over all retained history, even when buckets holds only changed minutes.
object
Input includes cache reads and writes; cached tokens are a subset.
Reasoning is a subset of output tokens.
object
Unix seconds, rounded down to a minute.
object
Input includes cache reads and writes; cached tokens are a subset.
Reasoning is a subset of output tokens.
Example generated
[ { "pane_id": "2489E9AD-2EE2-8E00-8EC9-32D5F69181C0", "updated_at": 1, "totals": { "input_tokens": 1, "output_tokens": 1, "cached_tokens": 1, "cache_write_tokens": 1, "reasoning_tokens": 1, "requests": 1, "tool_calls": 1, "duration_ms": 1, "cost_usd": 1 }, "models": [ { "agent": "example", "model": "example", "totals": { "input_tokens": 1, "output_tokens": 1, "cached_tokens": 1, "cache_write_tokens": 1, "reasoning_tokens": 1, "requests": 1, "tool_calls": 1, "duration_ms": 1, "cost_usd": 1 }, "buckets": [ { "timestamp": 1, "usage": { "input_tokens": 1, "output_tokens": 1, "cached_tokens": 1, "cache_write_tokens": 1, "reasoning_tokens": 1, "requests": 1, "tool_calls": 1, "duration_ms": 1, "cost_usd": 1 } } ] } ] }]Missing or wrong access token
The request’s Host or Origin isn’t allowed, or the caller can’t use this route (a guest token, or btmux connect)