Skip to main content
GET
Get session thread

Authorizations

Authorization
string
header
required

A Recursion API key, created in the console under API keys.

Headers

x-tenant-id
string

Optional tenant consistency check. When present, it must name the tenant bound to the API key, including when x-organization-id is default.

Minimum string length: 1
x-organization-id
string

Organization in which to act. Required for a tenant-scoped API key. Optional for an organization-scoped key, where it must name that same organization. The value may be an organization id or default.

Minimum string length: 1

Path Parameters

sessionId
string<uuid>
required

Any session id (UUID) in the tree; the read resolves to its root session.

threadId
string
required

Thread id as returned by managedAgentsListSessionThreads. Threads the runtime creates carry the sub-session's UUID; an imported transcript may carry the source system's own thread id.

Minimum string length: 1

Response

OK

agentId
string
required

Agent this thread runs (UUID).

createdAt
string<date-time>
required

RFC 3339 timestamp of when this record was created. Server-assigned.

role
string
required

What the thread exists to do within the tree, for example subagent, grader, or advisor. Not a chat message role.

rootSessionId
string
required

Root session of the multi-agent tree this thread belongs to (UUID). Equal to sessionId for a root session.

sessionId
string
required

Session this thread belongs to (UUID).

sessionPath
string
required

Slash-joined ancestry of session ids from the tree root down to the session whose events this thread's events are stored under, for example "/root-id/child-id".

status
string
required

Thread lifecycle: running (executing now), idle (awaiting more input), or terminated (finished; see stop_reason).

threadId
string
required

Identifier for this thread within its session tree (UUID). Server-assigned. For a subagent thread it is the child session id, so the thread and the session carrying its events resolve each other directly.

threadPath
string
required

Slash-joined ancestry of this thread within the tree, used to order threads for display. Defaults to session_path when the thread has no deeper nesting of its own.

updatedAt
string<date-time>
required

RFC 3339 timestamp of the last change to this record. Server-assigned.

agentVersionId
string

Agent version this thread runs (UUID). Absent when the thread was not pinned to a specific version.

archivedAt
string<date-time>

RFC 3339 timestamp of when this thread was archived and stopped appearing as an active stream. Absent while the thread is not archived.

name
string

Human-readable label for this thread, supplied when it was spawned. Optional and never interpreted by the service.

parentSessionId
string

Session the spawning thread belongs to (UUID). Absent on the tree's top-level thread.

parentThreadId
string

Thread that spawned this one (UUID). Absent on the tree's top-level thread.

stopReason
object

Structured reason the thread last stopped, forwarded from the agent loop, for example {"type": "end_turn"} or {"type": "error", "message": ...}. Absent while the thread has not stopped.