list logs
list_logsInspect logged chat exchanges with filters for model, tag, segment, finish reason, cache hit, and time range to review real traffic before grading, building datasets, or running evals.
Instructions
Browse the workspace's logged chat exchanges (request messages + assistant reply, secret-scrubbed) with filters for model, tag, auto-detected traffic segment, finish reason, cache hit and time range — use it to inspect real traffic before grading, building datasets, or running evals. GET /v1/logs (API-key scope: read). Returns: JSON { object: 'list', total: integer, limit, offset, data: [ { request_id, created_at (Unix seconds), model, tag, segment (prompt family id), segment_exact (exact system-prompt hash), trace_id, finish_reason, streamed: boolean, cache_hit: boolean, fallback_from: string|null, prompt_tokens, completion_tokens, messages: parsed JSON array of request messages (null if unparseable), response: parsed assistant message object (null if unparseable) } ] }. Newest first, successful (non-aborted) exchanges only. Notes: Request logging is opt-in per workspace: returns 409 { error: { message, type: 'invalid_request_error', code: 'logging_disabled' } } when it is off — an empty list would otherwise read as 'no traffic'. Offset pagination: repeat with offset += limit until offset >= total. Pass a row's segment back as ?segment= or into an eval's sample_filters.segment to slice by that application surface.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| end | No | Upper bound, Unix seconds (positive integer; other values ignored). | |
| tag | No | Exact request tag filter. | |
| limit | No | Page size, clamped 1..100. Default 25. Default: 25. | |
| model | No | Exact model name filter. | |
| start | No | Inclusive lower bound, Unix seconds (positive integer; other values ignored). | |
| offset | No | Rows to skip (offset pagination). Default 0. Default: 0. | |
| segment | No | Auto-detected traffic segment: the FAMILY of system prompts sharing one template (value of a row's `segment` field; the reserved value "none" is the no-system-prompt segment). Exact match. | |
| cache_hit | No | "true" or "false" — filter to cached / uncached responses. Any other value = no filter. | |
| finish_reason | No | Exact finish-reason filter (e.g. stop, length, tool_calls). |