Claude Platform Docs

Threads

List Session Threads
$client->beta->sessions->threads->list(string sessionID, ?int limit, ?string page, ?list<ManagedAgentsSessionThreadStatus> statuses, ?list<AnthropicBeta> betas, ?string workspaceID): PageCursor<ManagedAgentsSessionThread>
GET/v1/sessions/{session_id}/threads
Requires anthropic-beta: managed-agents-2026-04-01. How to send beta headers
Get Session Thread
$client->beta->sessions->threads->retrieve(string threadID, string sessionID, ?list<AnthropicBeta> betas, ?string workspaceID): ManagedAgentsSessionThread
GET/v1/sessions/{session_id}/threads/{thread_id}
Requires anthropic-beta: managed-agents-2026-04-01. How to send beta headers
Archive Session Thread
$client->beta->sessions->threads->archive(string threadID, string sessionID, ?list<AnthropicBeta> betas, ?string workspaceID): ManagedAgentsSessionThread
POST/v1/sessions/{session_id}/threads/{thread_id}/archive
Requires anthropic-beta: managed-agents-2026-04-01. How to send beta headers
Models
class ManagedAgentsInlineAgent { $type = 'inline'; $description; $executionIdentity; /* 6 more */ }
"inline" type
?string description

The session's execution principal.

Model identifier and configuration.

string name

The name that the agent's definition gave, or one that the server assigned.

list<Skill> skills
?string system
list<Tool> tools
class ManagedAgentsSessionThread { $type = 'session_thread'; $id; $agent; /* 9 more */ }
class ManagedAgentsSessionThreadStats { $activeSeconds; $durationSeconds; $startupSeconds; }
?float activeSeconds

Cumulative time in seconds the thread spent actively running. Excludes idle time.

?float durationSeconds

Elapsed time since thread creation in seconds. For archived threads, frozen at the final update.

?float startupSeconds

Time in seconds for the thread to begin running. Zero for child threads, which start immediately.

One of the following:
"running"
"idle"
"rescheduling"
"terminated"
class ManagedAgentsSessionThreadUsage { $activeSeconds; $cacheCreation; $cacheReadInputTokens; /* 4 more */ }
?float activeSeconds

Cumulative time in seconds this thread spent in running status. Equal to stats.active_seconds; surfaced here so a thread's usage carries every quantity its cost is priced on.

Tokens used to create prompt cache entries, broken down by cache TTL.

?int cacheReadInputTokens

Total tokens read from prompt cache.

?int inputTokens

Total input tokens consumed across all turns.

?BetaMonetaryAmount listCost

Cumulative list cost of this thread across all turns, priced at public list rates. Absent until cost tracking is available for the thread. Each figure is rounded to the nearest cent independently and the session's aggregate usage.list_cost additionally includes session runtime, so per-thread costs do not sum exactly to the session figure; the session figure is authoritative and is what a budget is enforced against.

?int outputTokens

Total output tokens generated across all turns.

Cumulative server-executed tool usage across all turns of this thread. Absent until server-tool tracking is available for the thread.

One of the following:

ThreadsEvents

List Session Thread Events
$client->beta->sessions->threads->events->list(string threadID, string sessionID, ?int limit, ?string page, ?list<AnthropicBeta> betas, ?string workspaceID): PageCursor<ManagedAgentsSessionEvent>
GET/v1/sessions/{session_id}/threads/{thread_id}/events
Requires anthropic-beta: managed-agents-2026-04-01. How to send beta headers
Stream Session Thread Events
$client->beta->sessions->threads->events->streamStream(string threadID, string sessionID, ?list<BetaManagedAgentsDeltaType> eventDeltas, ?list<AnthropicBeta> betas, ?string workspaceID): BaseStream<ManagedAgentsStreamSessionThreadEvents>
GET/v1/sessions/{session_id}/threads/{thread_id}/stream
Requires anthropic-beta: managed-agents-2026-04-01. How to send beta headers