Response fields request_id stringRequest identifierdata.query_range objectActual aligned range for the entire query; the same on every page, not the start and end of the current pagedata.query_range.start_time stringStart time of the entire query, inclusive, in the +08:00 time zonedata.query_range.end_time stringEnd time of the entire query, exclusive, in the +08:00 time zonedata.data_updated_at string / nullLatest known update time among the usage records returned on the current page; null if there are no records or the update time is unknown. Values may differ between pagesdata.granularity stringActual granularity used: hour, day, or monthdata.points arrayPeriods on the current page, in ascending start_time order; [] if there are no recordsdata.points[].start_time stringStart time of the period, inclusive, in the +08:00 time zonedata.points[].end_time stringEnd time of the period, exclusive, in the +08:00 time zonedata.points[].usage objectUsage of the period, including total, models, and tools; see Usage objectdata.has_more booleanWhether another page existsdata.next_page_token string / nullCursor for the next page. A non-empty string when has_more=true; null on the last page | Response example A successful request returns HTTP 200. The request above actually covers 10:00—15:00 UTC+8. The following example assumes that only 10:00—11:00 and 13:00—14:00 have summary records in this range; the first page returns the first period:{
"request_id": "req_trend_example",
"data": {
"query_range": {
"start_time": "2026-11-02T10:00:00+08:00",
"end_time": "2026-11-02T15:00:00+08:00"
},
"data_updated_at": "2026-11-02T11:05:00+08:00",
"granularity": "hour",
"points": [
{
"start_time": "2026-11-02T10:00:00+08:00",
"end_time": "2026-11-02T11:00:00+08:00",
"usage": {
"total": {
"input_tokens": {"value": 600, "unit": "tokens"},
"output_tokens": {"value": 120, "unit": "tokens"},
"total_tokens": {"value": 720, "unit": "tokens"},
"cache_read_tokens": {"value": 240, "unit": "tokens"},
"cache_creation_tokens": {"value": 60, "unit": "tokens"},
"cache_hit_ratio": {"value": 0.4, "unit": "ratio"},
"model_call_count": {"value": 3, "unit": "count"},
"tool_call_count": {"value": 2, "unit": "count"},
"builtin_tool_call_count": {"value": 0, "unit": "count"},
"mcp_tool_call_count": {"value": 2, "unit": "count"},
"custom_tool_call_count": {"value": 0, "unit": "count"},
"turns": {"value": 1, "unit": "count"},
"steps": {"value": 5, "unit": "count"},
"interrupt_error_count": {"value": 0, "unit": "count"},
"model_failed_count": {"value": 1, "unit": "count"},
"tool_failed_count": {"value": 1, "unit": "count"},
"runtime_ms": {"value": 36000, "unit": "ms"}
},
"models": [
{
"model_name": "qwen-plus",
"usage": {
"input_tokens": {"value": 600, "unit": "tokens"},
"output_tokens": {"value": 120, "unit": "tokens"},
"total_tokens": {"value": 720, "unit": "tokens"},
"cache_read_tokens": {"value": 240, "unit": "tokens"},
"cache_creation_tokens": {"value": 60, "unit": "tokens"},
"cache_hit_ratio": {"value": 0.4, "unit": "ratio"},
"call_count": {"value": 3, "unit": "count"},
"failed_count": {"value": 1, "unit": "count"}
}
}
],
"tools": [
{
"source": "mcp",
"tool_name": "web_search",
"usage": {
"call_count": {"value": 2, "unit": "count"},
"failed_count": {"value": 1, "unit": "count"}
}
}
]
}
}
],
"has_more": true,
"next_page_token": "v1_0123456789abcdef0123456789abcdef"
}
}
|