v2

latestOpenAPI 3.0.02026-08-051996591.2 MB
Agent Analytics

List agent traces

Lists agent traces with optional filtering by agent, session, status, and time range.

get/v2/agent_analytics/traces

Query parameters

agent_keystring

Filter traces by agent key.

session_keystring

Filter traces by session key.

status'ok' | 'error'

Filter traces by status.

error_type'context_limit_exceeded' | 'step_transition_limit_exceeded' | 'actions_limit_reached' | 'llm_generation_error' | 'stream_error' | 'internal'

Filter to traces containing a span with this exact error type.

operation'invoke_agent' | 'chat' | 'execute_tool' | 'thinking' | 'output' | 'step_transition' | 'image_read' | 'compaction'

Filter to traces containing at least one span with this operation.

tool_namestring

Filter to traces containing a tool execution span with this exact tool name.

tool_error_type'invalid_input' | 'not_found' | 'forbidden' | 'invalid_configuration' | 'timeout' | 'execution_error' | 'dependency_failed'

Filter to traces containing a tool span with this exact error type.

started_afterstring date-time

Return only traces started after this time (ISO 8601).

started_beforestring date-time

Return only traces started before this time (ISO 8601).

min_duration_msinteger

Return only traces with duration at or above this threshold in milliseconds.

max_duration_msinteger

Return only traces with duration at or below this threshold in milliseconds.

limitinteger

The maximum number of traces to return.

page_keystring

The opaque cursor returned in metadata.page_key of the previous response. Omit it to fetch the first page.

Headers

Request-Timeoutinteger

The platform makes a best effort to complete the request in the specified seconds, or it times out.

Request-Timeout-Millisinteger

The platform makes a best effort to complete the request in the specified milliseconds, or it times out.

Response

List of agent traces.

Example response

{
  "traces": [
    {
      "trace_id": "0af7651916cd43dd8448eb211c80319c",
      "agent_key": "customer_support",
      "session_key": "customer_support_chat"
    }
  ],
  "metadata": {
    "page_key": "eyJvZmZzZXQiOjF9"
  }
}