AgentSession

A request or response body; the type column links to the schemas it refers to.

AgentSession

FieldTypeRequiredDescription
idstring (uuid)yes

The session's id.

titlestringyes

Shown in the session list.

model_idstringyes

The model the agent runs on.

model_labelstringyes—
thinking_levelstringyes

one of "low" | "medium" | "high" | "xhigh" | "max"

statusstringyes

`running` while a turn is in progress; `failed` when the last turn ended in an error.

one of "idle" | "running" | "failed"

previewstring | nullyes

The latest reply, shortened.

last_errorstring | nullyes

What went wrong in the last turn, when it failed.

has_sandboxbooleanyes

Whether the session has a sandbox yet.

created_atstring (date-time)yes

When the session was started.

last_activity_atstring (date-time)yes

When a turn last ended.

archived_atstring (date-time) | nullyes

When the session was archived; null while it is open. An archived session keeps its transcript but takes no new messages until it is restored.

granted_scopesarray of string | nullyes

The scopes the session's agent was granted when the session was started. Each turn it is delegated these, cut down to what the role limits still allow and the caller's token carries. Null for a session started before grants, which follows the role limits; empty for one granted no scope, whose agent works in its sandbox alone.

jsonExample
{
  "id": "8d3f2c3e-0c4b-4f8e-9a51-2d8c6f0b1a7e",
  "title": "Overdue forklift certifications",
  "model_id": "claude-opus-5-5",
  "model_label": "Claude Opus 5.5",
  "thinking_level": "high",
  "status": "idle",
  "preview": "string",
  "last_error": "string",
  "has_sandbox": true,
  "created_at": "2026-11-08T12:00:00.000Z",
  "last_activity_at": "2026-11-08T12:00:00.000Z",
  "archived_at": null,
  "granted_scopes": [
    "records:read",
    "certifications:read"
  ]
}