Get Account Usage
get_account_usageRetrieve account-wide cost, request, and error totals for a chosen time window and group them by day, hour, job type, model, or key. Requires an admin API key.
Instructions
Get the whole account's cost, requests and errors over a time window (the Usage screen of the dashboard). With group_by=key, 'panel' means jobs from the dashboard itself and 'deleted' all keys deleted since. Needs an ADMIN key.
Tool call template
This tool declares no required parameters. Add optional parameters from the input schema as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {},
"name": "get_account_usage"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| to_date | No | Start or end of the window, YYYY-MM-DD (or YYYY-MM-DDTHH:MM). Optional | |
| group_by | No | Split the figures by day, hour, job type, model or key. Optional | |
| from_date | No | Start or end of the window, YYYY-MM-DD (or YYYY-MM-DDTHH:MM). Optional |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||