Request Logs
GET /logs?range=<range>&after=<ts>&after_id=<id>&errors=<bool>&limit=<n>Returns the full per-request log for your organization, ordered newest-first.
Query parameters
Section titled “Query parameters”| Parameter | Type | Required | Description |
|---|---|---|---|
range | string | No | 15m, 1h, 6h, 24h, 7days, 30days. Default: 24h. |
after | RFC3339 | No | Pagination cursor — timestamp of the last row of the previous page. |
after_id | string | No | Pagination cursor — request_id of the last row, breaks timestamp ties. |
errors | boolean | No | If true, only non-2xx requests. |
limit | integer | No | Page size. Capped at 100. Default: 50. |
Response
Section titled “Response”{ "data": [ { "id": "...", "model": "...", "api_key": "sk-...abcd", "status_code": 200, "ttft_ms": 210, "latency_ms": 420, "input_tokens": 123, "output_tokens": 45, "cached_tokens": 64, "cost": "0.00420000", "currency": "usd", "created_at": "2026-05-18 12:34:56.123456+00" } ], "has_more": true, "next_after": "2026-05-18 12:34:55.654321+00", "next_after_id": "..."}cost is denominated in currency — the org’s billing currency (usd or jpy); it is never a bare USD figure. When has_more is false, you’ve reached the end of the available range.
cached_tokens is the portion of input_tokens that was billed at the discounted cached input rate — a repeated prompt prefix. It is 0 when there was no cache hit and null on models without a cached rate.
Pagination
Section titled “Pagination”Pass next_after and next_after_id from the previous page as after and after_id. Using after alone is unsafe — multiple requests can share a millisecond timestamp.
API key or JWT + X-Org-ID. See Authentication.