Return the public-timeline steps for a task.
Pulls all :class:TraceEvent rows for the task in DB order, then
collapses them via :func:map_trace_events_to_public_steps into
the 4 stable public step types: thinking, tool_call,
agent_delegation, message.
The internal trace event taxonomy has ~32 event_type strings
today; SDK callers see only the 4 types listed above. Internal
events not on the public allow-list (LLM calls, memory ops,
visualization ticks, DAG bookkeeping) are silently dropped —
intentionally, so internal trace evolution doesn’t break the SDK
contract.
Args:
task_id: Path parameter; the target task’s primary key.
authed: (Agent, AgentApiKey) tuple resolved by the auth
dependency. The agent here is the key-bound agent.
db: SQLAlchemy session.
Returns:
:class:StepsResponse with task_id, agent_id, and the
steps array in started_at ascending order. In-flight steps
appear with status='running' and completed_at=null so
SDK clients can poll this endpoint and observe progress.
Raises: V1ApiError 401: missing / invalid / revoked key. V1ApiError 404: task missing or not owned by the calling agent.
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Successful Response
GET /v1/chat/tasks/{task_id}/steps response body.
Steps are returned in monotonic started_at order. The endpoint
is a polling primitive: each call returns the full known history
so far (including any still-running steps as status='running')
so SDK clients can resume after a network blip without state.