---
title: "Stream Events"
method: GET
path: "/v1/sessions/{session_id}/events/stream?beta=true"
---

# Stream Events

`GET /v1/sessions/{session_id}/events/stream?beta=true`

## Path parameters

- `session_id` string, required

## Headers

- `x-api-key` string
- `anthropic-version` string
- `anthropic-beta` string

## Response `200`

Successful response (OK)

- union — Server-sent event in the session stream.
  - object — A user message event in the session conversation.
    - `type` 'user.message', required
    - `id` string, required — Unique identifier for this event.
    - `content` BetaManagedAgentsUserContentBlock[], required — Array of content blocks comprising the user message.
      - union — Content block in a user message. Can be `text`, `image`, or `document`.
        - object — Regular text content.
          - `type` 'text', required
          - `text` string, required — The text content.
        - object — Image content specified directly as base64 data or as a reference via a URL.
          - `type` 'image', required
          - `source` union, required — Union type for image source variants.
            - object — Base64-encoded image data.
              - …
            - object — Image referenced by URL.
              - …
            - object — Image referenced by file ID.
              - …
        - object — Document content, either specified directly as base64 data, as text, or as a reference via a URL.
          - `type` 'document', required
          - `source` union, required — Union type for document source variants.
            - object — Base64-encoded document data.
              - …
            - object — Plain text document content.
              - …
            - object — Document referenced by URL.
              - …
            - object — Document referenced by file ID.
              - …
          - `title` string, nullable — The title of the document.
          - `context` string, nullable — Additional context about the document for the model.
    - `processed_at` string, date-time — A timestamp in RFC 3339 format
  - object — An interrupt event that pauses agent execution and returns control to the user.
    - `type` 'user.interrupt', required
    - `id` string, required — Unique identifier for this event.
    - `processed_at` string, date-time — A timestamp in RFC 3339 format
    - `session_thread_id` string, nullable — If absent, interrupts every non-archived thread in a multiagent session (or the primary alone in a single-agent session). If present, interrupts only the named thread.
  - object — A tool confirmation event that approves or denies a pending tool execution.
    - `type` 'user.tool_confirmation', required
    - `id` string, required — Unique identifier for this event.
    - `tool_use_id` string, required — The id of the `agent.tool_use` or `agent.mcp_tool_use` event this result corresponds to, which can be found in the last `session.status_idle` [event's](https://platform.claude.com/docs/en/api/beta/sessions/events/list#beta_managed_agents_session_requires_action.event_ids) `stop_reason.event_ids` field.
    - `result` 'allow' | 'deny', required — UserToolConfirmationResult enum
    - `deny_message` string, nullable — Optional message providing context for a 'deny' decision. Only allowed when result is 'deny'.
    - `processed_at` string, date-time — A timestamp in RFC 3339 format
    - `session_thread_id` string, nullable — When set, the confirmation routes to this subagent's thread rather than the primary. Echo this from the `session_thread_id` on the `agent.tool_use` or `agent.mcp_tool_use` event that prompted the approval.
  - object — Event sent by the client providing the result of a custom tool execution.
    - `type` 'user.custom_tool_result', required
    - `id` string, required — Unique identifier for this event.
    - `custom_tool_use_id` string, required — The id of the `agent.custom_tool_use` event this result corresponds to, which can be found in the last `session.status_idle` [event's](https://platform.claude.com/docs/en/api/beta/sessions/events/list#beta_managed_agents_session_requires_action.event_ids) `stop_reason.event_ids` field.
    - `content` BetaManagedAgentsToolResultContentBlock[] — The result content returned by the tool.
      - union — Content block in a tool result. Can be `text`, `image`, `document`, or `search_result`.
        - object — Regular text content.
          - `type` 'text', required
          - `text` string, required — The text content.
        - object — Image content specified directly as base64 data or as a reference via a URL.
          - `type` 'image', required
          - `source` union, required — Union type for image source variants.
            - object — Base64-encoded image data.
              - …
            - object — Image referenced by URL.
              - …
            - object — Image referenced by file ID.
              - …
        - object — Document content, either specified directly as base64 data, as text, or as a reference via a URL.
          - `type` 'document', required
          - `source` union, required — Union type for document source variants.
            - object — Base64-encoded document data.
              - …
            - object — Plain text document content.
              - …
            - object — Document referenced by URL.
              - …
            - object — Document referenced by file ID.
              - …
          - `title` string, nullable — The title of the document.
          - `context` string, nullable — Additional context about the document for the model.
        - object — A block containing a web search result.
          - `type` 'search_result', required
          - `source` string, required — The URL source of the search result.
          - `title` string, required — The title of the search result.
          - `content` BetaManagedAgentsSearchResultContent[], required — Array of text content blocks from the search result.
            - `type` 'text', required
            - `text` string, required — The text content.
          - `citations` BetaManagedAgentsSearchResultCitations, required — Citation settings for a search result.
            - `enabled` boolean, required — Whether citations are enabled for this search result.
    - `is_error` boolean, nullable — Whether the tool execution resulted in an error.
    - `processed_at` string, date-time — A timestamp in RFC 3339 format
    - `session_thread_id` string, nullable — Routes this result to a subagent thread. Copy from the `agent.custom_tool_use` event's `session_thread_id`.
  - object — Event emitted when the agent calls a custom tool. The session goes idle until the client sends a `user.custom_tool_result` event with the result.
    - `type` 'agent.custom_tool_use', required
    - `id` string, required — Unique identifier for this event.
    - `name` string, required — Name of the custom tool being called.
    - `input` BetaManagedAgentsStruct, required
    - `processed_at` string, date-time, required — A timestamp in RFC 3339 format
    - `session_thread_id` string, nullable — When set, this event was cross-posted from a subagent's thread to surface its custom tool use on the primary thread's stream. Empty on the thread's own events. Echo this on a `user.custom_tool_result` event to route the result back.
  - object — An agent response event in the session conversation.
    - `type` 'agent.message', required
    - `id` string, required — Unique identifier for this event.
    - `content` BetaManagedAgentsTextBlock[], required — Array of text blocks comprising the agent response.
      - `type` 'text', required
      - `text` string, required — The text content.
    - `processed_at` string, date-time, required — A timestamp in RFC 3339 format
  - object — Indicates the agent is making forward progress via extended thinking. A progress signal, not a content carrier.
    - `type` 'agent.thinking', required
    - `id` string, required — Unique identifier for this event.
    - `processed_at` string, date-time, required — A timestamp in RFC 3339 format
  - object — Event emitted when the agent invokes a tool provided by an MCP server.
    - `type` 'agent.mcp_tool_use', required
    - `id` string, required — Unique identifier for this event.
    - `name` string, required — Name of the MCP tool being used.
    - `mcp_server_name` string, required — Name of the MCP server providing the tool.
    - `input` BetaManagedAgentsStruct, required
    - `processed_at` string, date-time, required — A timestamp in RFC 3339 format
    - `evaluated_permission` 'allow' | 'ask' | 'deny' — AgentEvaluatedPermission enum
    - `session_thread_id` string, nullable — When set, this event was cross-posted from a subagent's thread to surface its permission request on the primary thread's stream. Empty on the thread's own events. Echo this on a `user.tool_confirmation` event to route the approval back.
  - object — Event representing the result of an MCP tool execution.
    - `type` 'agent.mcp_tool_result', required
    - `id` string, required — Unique identifier for this event.
    - `mcp_tool_use_id` string, required — The id of the `agent.mcp_tool_use` event this result corresponds to.
    - `content` BetaManagedAgentsToolResultContentBlock[] — The result content returned by the tool.
      - union — Content block in a tool result. Can be `text`, `image`, `document`, or `search_result`.
        - object — Regular text content.
          - `type` 'text', required
          - `text` string, required — The text content.
        - object — Image content specified directly as base64 data or as a reference via a URL.
          - `type` 'image', required
          - `source` union, required — Union type for image source variants.
            - object — Base64-encoded image data.
              - …
            - object — Image referenced by URL.
              - …
            - object — Image referenced by file ID.
              - …
        - object — Document content, either specified directly as base64 data, as text, or as a reference via a URL.
          - `type` 'document', required
          - `source` union, required — Union type for document source variants.
            - object — Base64-encoded document data.
              - …
            - object — Plain text document content.
              - …
            - object — Document referenced by URL.
              - …
            - object — Document referenced by file ID.
              - …
          - `title` string, nullable — The title of the document.
          - `context` string, nullable — Additional context about the document for the model.
        - object — A block containing a web search result.
          - `type` 'search_result', required
          - `source` string, required — The URL source of the search result.
          - `title` string, required — The title of the search result.
          - `content` BetaManagedAgentsSearchResultContent[], required — Array of text content blocks from the search result.
            - `type` 'text', required
            - `text` string, required — The text content.
          - `citations` BetaManagedAgentsSearchResultCitations, required — Citation settings for a search result.
            - `enabled` boolean, required — Whether citations are enabled for this search result.
    - `is_error` boolean, nullable — Whether the tool execution resulted in an error.
    - `processed_at` string, date-time, required — A timestamp in RFC 3339 format
  - object — Event emitted when the agent invokes a built-in agent tool.
    - `type` 'agent.tool_use', required
    - `id` string, required — Unique identifier for this event.
    - `name` string, required — Name of the agent tool being used.
    - `input` BetaManagedAgentsStruct, required
    - `processed_at` string, date-time, required — A timestamp in RFC 3339 format
    - `evaluated_permission` 'allow' | 'ask' | 'deny' — AgentEvaluatedPermission enum
    - `session_thread_id` string, nullable — When set, this event was cross-posted from a subagent's thread to surface its permission request on the primary thread's stream. Empty on the thread's own events. Echo this on a `user.tool_confirmation` event to route the approval back.
  - object — Event representing the result of an agent tool execution.
    - `type` 'agent.tool_result', required
    - `id` string, required — Unique identifier for this event.
    - `tool_use_id` string, required — The id of the `agent.tool_use` event this result corresponds to.
    - `content` BetaManagedAgentsToolResultContentBlock[] — The result content returned by the tool.
      - union — Content block in a tool result. Can be `text`, `image`, `document`, or `search_result`.
        - object — Regular text content.
          - `type` 'text', required
          - `text` string, required — The text content.
        - object — Image content specified directly as base64 data or as a reference via a URL.
          - `type` 'image', required
          - `source` union, required — Union type for image source variants.
            - object — Base64-encoded image data.
              - …
            - object — Image referenced by URL.
              - …
            - object — Image referenced by file ID.
              - …
        - object — Document content, either specified directly as base64 data, as text, or as a reference via a URL.
          - `type` 'document', required
          - `source` union, required — Union type for document source variants.
            - object — Base64-encoded document data.
              - …
            - object — Plain text document content.
              - …
            - object — Document referenced by URL.
              - …
            - object — Document referenced by file ID.
              - …
          - `title` string, nullable — The title of the document.
          - `context` string, nullable — Additional context about the document for the model.
        - object — A block containing a web search result.
          - `type` 'search_result', required
          - `source` string, required — The URL source of the search result.
          - `title` string, required — The title of the search result.
          - `content` BetaManagedAgentsSearchResultContent[], required — Array of text content blocks from the search result.
            - `type` 'text', required
            - `text` string, required — The text content.
          - `citations` BetaManagedAgentsSearchResultCitations, required — Citation settings for a search result.
            - `enabled` boolean, required — Whether citations are enabled for this search result.
    - `is_error` boolean, nullable — Whether the tool execution resulted in an error.
    - `processed_at` string, date-time, required — A timestamp in RFC 3339 format
  - object — Delivery event written to the target thread's input stream when an agent-to-agent message arrives.
    - `type` 'agent.thread_message_received', required
    - `id` string, required — Unique identifier for this event.
    - `processed_at` string, date-time, required — A timestamp in RFC 3339 format
    - `from_agent_name` string, nullable — Name of the callable agent this message came from. Absent when received from the primary agent.
    - `content` BetaManagedAgentsUserContentBlock[], required — Message content blocks.
      - union — Content block in a user message. Can be `text`, `image`, or `document`.
        - object — Regular text content.
          - `type` 'text', required
          - `text` string, required — The text content.
        - object — Image content specified directly as base64 data or as a reference via a URL.
          - `type` 'image', required
          - `source` union, required — Union type for image source variants.
            - object — Base64-encoded image data.
              - …
            - object — Image referenced by URL.
              - …
            - object — Image referenced by file ID.
              - …
        - object — Document content, either specified directly as base64 data, as text, or as a reference via a URL.
          - `type` 'document', required
          - `source` union, required — Union type for document source variants.
            - object — Base64-encoded document data.
              - …
            - object — Plain text document content.
              - …
            - object — Document referenced by URL.
              - …
            - object — Document referenced by file ID.
              - …
          - `title` string, nullable — The title of the document.
          - `context` string, nullable — Additional context about the document for the model.
    - `from_session_thread_id` string, required — Public `sthr_` ID of the thread that sent the message.
  - object — Observability event emitted to the sender's output stream when an agent-to-agent message is sent.
    - `type` 'agent.thread_message_sent', required
    - `id` string, required — Unique identifier for this event.
    - `processed_at` string, date-time, required — A timestamp in RFC 3339 format
    - `to_agent_name` string, nullable — Name of the callable agent this message was sent to. Absent when sent to the primary agent.
    - `content` BetaManagedAgentsUserContentBlock[], required — Message content blocks.
      - union — Content block in a user message. Can be `text`, `image`, or `document`.
        - object — Regular text content.
          - `type` 'text', required
          - `text` string, required — The text content.
        - object — Image content specified directly as base64 data or as a reference via a URL.
          - `type` 'image', required
          - `source` union, required — Union type for image source variants.
            - object — Base64-encoded image data.
              - …
            - object — Image referenced by URL.
              - …
            - object — Image referenced by file ID.
              - …
        - object — Document content, either specified directly as base64 data, as text, or as a reference via a URL.
          - `type` 'document', required
          - `source` union, required — Union type for document source variants.
            - object — Base64-encoded document data.
              - …
            - object — Plain text document content.
              - …
            - object — Document referenced by URL.
              - …
            - object — Document referenced by file ID.
              - …
          - `title` string, nullable — The title of the document.
          - `context` string, nullable — Additional context about the document for the model.
    - `to_session_thread_id` string, required — Public `sthr_` ID of the thread the message was sent to.
  - object — Indicates that context compaction (summarization) occurred during the session.
    - `type` 'agent.thread_context_compacted', required
    - `id` string, required — Unique identifier for this event.
    - `processed_at` string, date-time, required — A timestamp in RFC 3339 format
  - object — An error event indicating a problem occurred during session execution.
    - `type` 'session.error', required
    - `id` string, required — Unique identifier for this event.
    - `processed_at` string, date-time, required — A timestamp in RFC 3339 format
    - `error` union, required
      - object — An unknown or unexpected error occurred during session execution. A fallback variant; clients that don't recognize a new error code can match on `retry_status` and `message` alone.
        - `type` 'unknown_error', required
        - `message` string, required — Human-readable error description.
        - `retry_status` union, required — What the client should do next in response to this error.
          - object — The server is retrying automatically. Client should wait; the same error type may fire again as retrying, then once as exhausted when the retry budget runs out.
            - `type` 'retrying', required
          - object — This turn is dead; queued inputs are flushed and the session returns to idle. Client may send a new prompt.
            - `type` 'exhausted', required
          - object — The session encountered a terminal error and will transition to `terminated` state.
            - `type` 'terminal', required
      - object — The model is currently overloaded. Emitted after automatic retries are exhausted.
        - `type` 'model_overloaded_error', required
        - `message` string, required — Human-readable error description.
        - `retry_status` union, required — What the client should do next in response to this error.
          - object — The server is retrying automatically. Client should wait; the same error type may fire again as retrying, then once as exhausted when the retry budget runs out.
            - `type` 'retrying', required
          - object — This turn is dead; queued inputs are flushed and the session returns to idle. Client may send a new prompt.
            - `type` 'exhausted', required
          - object — The session encountered a terminal error and will transition to `terminated` state.
            - `type` 'terminal', required
      - object — The model request was rate-limited.
        - `type` 'model_rate_limited_error', required
        - `message` string, required — Human-readable error description.
        - `retry_status` union, required — What the client should do next in response to this error.
          - object — The server is retrying automatically. Client should wait; the same error type may fire again as retrying, then once as exhausted when the retry budget runs out.
            - `type` 'retrying', required
          - object — This turn is dead; queued inputs are flushed and the session returns to idle. Client may send a new prompt.
            - `type` 'exhausted', required
          - object — The session encountered a terminal error and will transition to `terminated` state.
            - `type` 'terminal', required
      - object — A model request failed for a reason other than overload or rate-limiting.
        - `type` 'model_request_failed_error', required
        - `message` string, required — Human-readable error description.
        - `retry_status` union, required — What the client should do next in response to this error.
          - object — The server is retrying automatically. Client should wait; the same error type may fire again as retrying, then once as exhausted when the retry budget runs out.
            - `type` 'retrying', required
          - object — This turn is dead; queued inputs are flushed and the session returns to idle. Client may send a new prompt.
            - `type` 'exhausted', required
          - object — The session encountered a terminal error and will transition to `terminated` state.
            - `type` 'terminal', required
      - object — Failed to connect to an MCP server.
        - `type` 'mcp_connection_failed_error', required
        - `message` string, required — Human-readable error description.
        - `retry_status` union, required — What the client should do next in response to this error.
          - object — The server is retrying automatically. Client should wait; the same error type may fire again as retrying, then once as exhausted when the retry budget runs out.
            - `type` 'retrying', required
          - object — This turn is dead; queued inputs are flushed and the session returns to idle. Client may send a new prompt.
            - `type` 'exhausted', required
          - object — The session encountered a terminal error and will transition to `terminated` state.
            - `type` 'terminal', required
        - `mcp_server_name` string, required — Name of the MCP server that failed to connect.
      - object — Authentication to an MCP server failed.
        - `type` 'mcp_authentication_failed_error', required
        - `message` string, required — Human-readable error description.
        - `retry_status` union, required — What the client should do next in response to this error.
          - object — The server is retrying automatically. Client should wait; the same error type may fire again as retrying, then once as exhausted when the retry budget runs out.
            - `type` 'retrying', required
          - object — This turn is dead; queued inputs are flushed and the session returns to idle. Client may send a new prompt.
            - `type` 'exhausted', required
          - object — The session encountered a terminal error and will transition to `terminated` state.
            - `type` 'terminal', required
        - `mcp_server_name` string, required — Name of the MCP server that failed authentication.
      - object — The caller's organization or workspace cannot make model requests — out of credits or spend limit reached. Retrying with the same credentials will not succeed; the caller must resolve the billing state.
        - `type` 'billing_error', required
        - `message` string, required — Human-readable error description.
        - `retry_status` union, required — What the client should do next in response to this error.
          - object — The server is retrying automatically. Client should wait; the same error type may fire again as retrying, then once as exhausted when the retry budget runs out.
            - `type` 'retrying', required
          - object — This turn is dead; queued inputs are flushed and the session returns to idle. Client may send a new prompt.
            - `type` 'exhausted', required
          - object — The session encountered a terminal error and will transition to `terminated` state.
            - `type` 'terminal', required
  - object — Indicates the session is recovering from an error state and is rescheduled for execution.
    - `type` 'session.status_rescheduled', required
    - `id` string, required — Unique identifier for this event.
    - `processed_at` string, date-time, required — A timestamp in RFC 3339 format
  - object — Indicates the session is actively running and the agent is working.
    - `type` 'session.status_running', required
    - `id` string, required — Unique identifier for this event.
    - `processed_at` string, date-time, required — A timestamp in RFC 3339 format
  - object — Indicates the agent has paused and is awaiting user input.
    - `type` 'session.status_idle', required
    - `id` string, required — Unique identifier for this event.
    - `processed_at` string, date-time, required — A timestamp in RFC 3339 format
    - `stop_reason` union, required
      - object — The agent completed its turn naturally and is ready for the next user message.
        - `type` 'end_turn', required
      - object — The agent is idle waiting on one or more blocking user-input events (tool confirmation, custom tool result, etc.). Resolving all of them transitions the session back to running.
        - `type` 'requires_action', required
        - `event_ids` string[], required — The ids of events the agent is blocked on. Resolving fewer than all re-emits `session.status_idle` with the remainder.
      - object — The turn ended because the retry budget was exhausted (`max_iterations` hit or an error escalated to `retry_status: 'exhausted'`).
        - `type` 'retries_exhausted', required
  - object — Indicates the session has terminated, either due to an error or completion.
    - `type` 'session.status_terminated', required
    - `id` string, required — Unique identifier for this event.
    - `processed_at` string, date-time, required — A timestamp in RFC 3339 format
  - object — Emitted when a subagent is spawned as a new thread. Written to the parent thread's output stream so clients observing the session see child creation.
    - `type` 'session.thread_created', required
    - `id` string, required — Unique identifier for this event.
    - `processed_at` string, date-time, required — A timestamp in RFC 3339 format
    - `agent_name` string, required — Name of the callable agent the thread runs.
    - `session_thread_id` string, required — Public `sthr_` ID of the newly created thread.
  - object — Emitted when an outcome evaluation cycle begins.
    - `type` 'span.outcome_evaluation_start', required
    - `id` string, required — Unique identifier for this event.
    - `processed_at` string, date-time, required — A timestamp in RFC 3339 format
    - `iteration` integer, required — 0-indexed revision cycle. 0 is the first evaluation; 1 is the re-evaluation after the first revision; etc.
    - `outcome_id` string, required — The `outc_` ID of the outcome being evaluated.
  - object — Emitted when an outcome evaluation cycle completes. Carries the verdict and aggregate token usage. A verdict of `needs_revision` means another evaluation cycle follows; `satisfied`, `max_iterations_reached`, `failed`, or `interrupted` are terminal — no further evaluation cycles follow.
    - `type` 'span.outcome_evaluation_end', required
    - `id` string, required — Unique identifier for this event.
    - `processed_at` string, date-time, required — A timestamp in RFC 3339 format
    - `outcome_evaluation_start_id` string, required — The id of the corresponding `span.outcome_evaluation_start` event.
    - `iteration` integer, required — 0-indexed revision cycle, matching the corresponding `span.outcome_evaluation_start`.
    - `result` string, required — Evaluation verdict. 'satisfied': criteria met, session goes idle. 'needs_revision': criteria not met, another revision cycle follows. 'max_iterations_reached': evaluation budget exhausted with criteria still unmet — one final acknowledgment turn follows before the session goes idle, but no further evaluation runs. 'failed': grader determined the rubric does not apply to the deliverables. 'interrupted': user sent an interrupt while evaluation was in progress.
    - `explanation` string, required — Human-readable explanation of the verdict. For `needs_revision`, describes which criteria failed and why.
    - `usage` BetaManagedAgentsSpanModelUsage, required — Token usage for a single model request.
      - `input_tokens` integer, required — Input tokens consumed by this request.
      - `output_tokens` integer, required — Output tokens generated by this request.
      - `cache_creation_input_tokens` integer, required — Tokens used to create prompt cache in this request.
      - `cache_read_input_tokens` integer, required — Tokens read from prompt cache in this request.
      - `speed` 'standard' | 'fast' — Inference speed mode. `fast` provides significantly faster output token generation at premium pricing. Not all models support `fast`; invalid combinations are rejected at create time.
    - `outcome_id` string, required — The `outc_` ID of the outcome being evaluated.
  - object — Emitted when a model request is initiated by the agent.
    - `type` 'span.model_request_start', required
    - `id` string, required — Unique identifier for this event.
    - `processed_at` string, date-time, required — A timestamp in RFC 3339 format
  - object — Emitted when a model request completes.
    - `type` 'span.model_request_end', required
    - `id` string, required — Unique identifier for this event.
    - `processed_at` string, date-time, required — A timestamp in RFC 3339 format
    - `is_error` boolean, nullable, required — Whether the model request resulted in an error.
    - `model_usage` BetaManagedAgentsSpanModelUsage, required — Token usage for a single model request.
      - `input_tokens` integer, required — Input tokens consumed by this request.
      - `output_tokens` integer, required — Output tokens generated by this request.
      - `cache_creation_input_tokens` integer, required — Tokens used to create prompt cache in this request.
      - `cache_read_input_tokens` integer, required — Tokens read from prompt cache in this request.
      - `speed` 'standard' | 'fast' — Inference speed mode. `fast` provides significantly faster output token generation at premium pricing. Not all models support `fast`; invalid combinations are rejected at create time.
    - `model_request_start_id` string, required — The id of the corresponding `span.model_request_start` event.
  - object — Periodic heartbeat emitted while an outcome evaluation cycle is in progress. Distinguishes 'evaluation is actively running' from 'evaluation is stuck' between the corresponding `span.outcome_evaluation_start` and `span.outcome_evaluation_end` events.
    - `type` 'span.outcome_evaluation_ongoing', required
    - `id` string, required — Unique identifier for this event.
    - `processed_at` string, date-time, required — A timestamp in RFC 3339 format
    - `iteration` integer, required — 0-indexed revision cycle, matching the corresponding `span.outcome_evaluation_start`.
    - `outcome_id` string, required — The `outc_` ID of the outcome being evaluated.
  - object — Echo of a `user.define_outcome` input event. Carries the server-generated `outcome_id` that subsequent `span.outcome_evaluation_*` events reference.
    - `type` 'user.define_outcome', required
    - `id` string, required — Unique identifier for this event.
    - `processed_at` string, date-time, required — A timestamp in RFC 3339 format
    - `outcome_id` string, required — Server-generated `outc_` ID for this outcome. Referenced by `span.outcome_evaluation_*` events and the session's `outcome_evaluations` list.
    - `description` string, required — What the agent should produce. Copied from the input event.
    - `max_iterations` integer, nullable, required — Evaluate-then-revise cycles before giving up. Default 3, max 20.
    - `rubric` union, required — Rubric for grading the quality of an outcome.
      - BetaManagedAgentsFileRubric — Rubric referenced by a file uploaded via the Files API.
        - `type` 'file', required
        - `file_id` string, required — ID of the rubric file.
      - BetaManagedAgentsTextRubric — Rubric content provided inline as text.
        - `type` 'text', required
        - `content` string, required — Rubric content. Plain text or markdown — the grader treats it as freeform text.
  - object — Emitted when a session has been deleted. Terminates any active event stream — no further events will be emitted for this session.
    - `type` 'session.deleted', required
    - `id` string, required — Unique identifier for this event.
    - `processed_at` string, date-time, required — A timestamp in RFC 3339 format
  - object — A session thread has begun executing. Emitted on the thread's own stream and cross-posted to the primary stream for child threads.
    - `type` 'session.thread_status_running', required
    - `id` string, required — Unique identifier for this event.
    - `session_thread_id` string, required — Public sthr_ ID of the thread that started running.
    - `processed_at` string, date-time, required — A timestamp in RFC 3339 format
    - `agent_name` string, required — Name of the agent the thread runs.
  - object — A session thread has yielded and is awaiting input. Emitted on the thread's own stream and cross-posted to the primary stream for child threads.
    - `type` 'session.thread_status_idle', required
    - `id` string, required — Unique identifier for this event.
    - `session_thread_id` string, required — Public sthr_ ID of the thread that went idle.
    - `processed_at` string, date-time, required — A timestamp in RFC 3339 format
    - `agent_name` string, required — Name of the agent the thread runs.
    - `stop_reason` union, required
      - object — The agent completed its turn naturally and is ready for the next user message.
        - `type` 'end_turn', required
      - object — The agent is idle waiting on one or more blocking user-input events (tool confirmation, custom tool result, etc.). Resolving all of them transitions the session back to running.
        - `type` 'requires_action', required
        - `event_ids` string[], required — The ids of events the agent is blocked on. Resolving fewer than all re-emits `session.status_idle` with the remainder.
      - object — The turn ended because the retry budget was exhausted (`max_iterations` hit or an error escalated to `retry_status: 'exhausted'`).
        - `type` 'retries_exhausted', required
  - object — A session thread has terminated and will accept no further input. Emitted on the thread's own stream and cross-posted to the primary stream for child threads.
    - `type` 'session.thread_status_terminated', required
    - `id` string, required — Unique identifier for this event.
    - `session_thread_id` string, required — Public sthr_ ID of the thread that terminated.
    - `processed_at` string, date-time, required — A timestamp in RFC 3339 format
    - `agent_name` string, required — Name of the agent the thread runs.
  - object — Event sent by the client providing the result of an agent-toolset tool execution. Only valid on `self_hosted` environments, where sandbox-routed tools are executed by the client rather than the server.
    - `type` 'user.tool_result', required
    - `id` string, required — Unique identifier for this event.
    - `tool_use_id` string, required — The id of the `agent.tool_use` event this result corresponds to, which can be found in the last `session.status_idle` [event's](https://platform.claude.com/docs/en/api/beta/sessions/events/list#beta_managed_agents_session_requires_action.event_ids) `stop_reason.event_ids` field.
    - `content` BetaManagedAgentsToolResultContentBlock[] — The result content returned by the tool.
      - union — Content block in a tool result. Can be `text`, `image`, `document`, or `search_result`.
        - object — Regular text content.
          - `type` 'text', required
          - `text` string, required — The text content.
        - object — Image content specified directly as base64 data or as a reference via a URL.
          - `type` 'image', required
          - `source` union, required — Union type for image source variants.
            - object — Base64-encoded image data.
              - …
            - object — Image referenced by URL.
              - …
            - object — Image referenced by file ID.
              - …
        - object — Document content, either specified directly as base64 data, as text, or as a reference via a URL.
          - `type` 'document', required
          - `source` union, required — Union type for document source variants.
            - object — Base64-encoded document data.
              - …
            - object — Plain text document content.
              - …
            - object — Document referenced by URL.
              - …
            - object — Document referenced by file ID.
              - …
          - `title` string, nullable — The title of the document.
          - `context` string, nullable — Additional context about the document for the model.
        - object — A block containing a web search result.
          - `type` 'search_result', required
          - `source` string, required — The URL source of the search result.
          - `title` string, required — The title of the search result.
          - `content` BetaManagedAgentsSearchResultContent[], required — Array of text content blocks from the search result.
            - `type` 'text', required
            - `text` string, required — The text content.
          - `citations` BetaManagedAgentsSearchResultCitations, required — Citation settings for a search result.
            - `enabled` boolean, required — Whether citations are enabled for this search result.
    - `is_error` boolean, nullable — Whether the tool execution resulted in an error.
    - `processed_at` string, date-time — A timestamp in RFC 3339 format
    - `session_thread_id` string, nullable — Routes this result to a subagent thread. Copy from the `agent.tool_use` event's `session_thread_id`.
  - object — A session thread hit a transient error and is retrying automatically. Emitted on the thread's own stream and cross-posted to the primary stream for child threads.
    - `type` 'session.thread_status_rescheduled', required
    - `id` string, required — Unique identifier for this event.
    - `session_thread_id` string, required — Public sthr_ ID of the thread that is retrying.
    - `processed_at` string, date-time, required — A timestamp in RFC 3339 format
    - `agent_name` string, required — Name of the agent the thread runs.
  - object — Emitted when an UpdateSession request changed at least one field. Carries only the fields that changed; absent fields were not part of the update. The new configuration applies from the next turn.
    - `type` 'session.updated', required
    - `id` string, required — Unique identifier for this event.
    - `processed_at` string, date-time, required — A timestamp in RFC 3339 format
    - `title` string, nullable — The session's new title. Present only when the update changed it.
    - `metadata` object — The session's full metadata bag after the update. Present when the update set non-empty metadata; absent when metadata was unchanged or cleared to empty.
    - `agent` BetaManagedAgentsSessionAgent — Resolved `agent` definition for a `session`. Snapshot of the `agent` at `session` creation time.
      - `type` 'agent', required
      - `id` string, required
      - `version` integer, required
      - `name` string, required
      - `description` string, nullable, required
      - `model` BetaManagedAgentsModelConfig, required — Model identifier and configuration.
        - `id` union, required — The model that will power your agent.\n\nSee [models](https://docs.anthropic.com/en/docs/models-overview) for additional details and options.
          - string
          - 'claude-opus-4-7' — Frontier intelligence for long-running agents and coding
          - 'claude-opus-4-6' — Most intelligent model for building agents and coding
          - 'claude-sonnet-4-6' — Best combination of speed and intelligence
          - 'claude-haiku-4-5' — Fastest model with near-frontier intelligence
          - 'claude-haiku-4-5-20251001' — Fastest model with near-frontier intelligence
          - 'claude-opus-4-5' — Premium model combining maximum intelligence with practical performance
          - 'claude-opus-4-5-20251101' — Premium model combining maximum intelligence with practical performance
          - 'claude-sonnet-4-5' — High-performance model for agents and coding
          - 'claude-sonnet-4-5-20250929' — High-performance model for agents and coding
        - `speed` 'standard' | 'fast' — Inference speed mode. `fast` provides significantly faster output token generation at premium pricing. Not all models support `fast`; invalid combinations are rejected at create time.
      - `system` string, nullable, required
      - `tools` BetaManagedAgentsAgentTool[], required
        - union — Union type for tool configurations returned in API responses.
          - object
            - `type` 'agent_toolset_20260401', required
            - `default_config` BetaManagedAgentsAgentToolsetDefaultConfig, required — Resolved default configuration for agent tools.
              - …
            - `configs` BetaManagedAgentsAgentToolConfig[], required
              - …
          - object
            - `type` 'mcp_toolset', required
            - `mcp_server_name` string, required
            - `default_config` BetaManagedAgentsMCPToolsetDefaultConfig, required — Resolved default configuration for all tools from an MCP server.
              - …
            - `configs` BetaManagedAgentsMCPToolConfig[], required
              - …
          - object — A custom tool as returned in API responses.
            - `type` 'custom', required
            - `name` string, required
            - `description` string, required
            - `input_schema` BetaManagedAgentsCustomToolInputSchema, required — JSON Schema for custom tool input parameters.
              - …
      - `mcp_servers` BetaManagedAgentsMCPServer[], required
        - `type` 'url', required
        - `name` string, required
        - `url` string, required
      - `skills` BetaManagedAgentsSkill[], required
        - union — Resolved skill as returned in API responses.
          - BetaManagedAgentsAnthropicSkill — A resolved Anthropic-managed skill.
            - `type` 'anthropic', required
            - `skill_id` string, required
            - `version` string, required
          - BetaManagedAgentsCustomSkill — A resolved user-created custom skill.
            - `type` 'custom', required
            - `skill_id` string, required
            - `version` string, required
      - `multiagent` BetaManagedAgentsSessionMultiagent, required — Resolved coordinator topology with full agent definitions for each roster member.
        - `type` 'coordinator', required
        - `agents` BetaManagedAgentsSessionThreadAgent[], required — Full `agent` definitions the coordinator may spawn as session threads.
          - `type` 'agent', required
          - `id` string, required
          - `version` integer, required
          - `name` string, required
          - `description` string, nullable, required
          - `model` BetaManagedAgentsModelConfig, required — Model identifier and configuration.
            - `id` union, required — The model that will power your agent.\n\nSee [models](https://docs.anthropic.com/en/docs/models-overview) for additional details and options.
              - …
            - `speed` 'standard' | 'fast' — Inference speed mode. `fast` provides significantly faster output token generation at premium pricing. Not all models support `fast`; invalid combinations are rejected at create time.
          - `system` string, nullable, required
          - `tools` BetaManagedAgentsAgentTool[], required
            - union — Union type for tool configurations returned in API responses.
              - …
          - `mcp_servers` BetaManagedAgentsMCPServer[], required
            - `type` 'url', required
            - `name` string, required
            - `url` string, required
          - `skills` BetaManagedAgentsSkill[], required
            - union — Resolved skill as returned in API responses.
              - …

## Other responses

- `400` — Invalid argument - The client specified an invalid argument
- `401` — Unauthenticated - The request does not have valid authentication credentials
- `403` — Permission denied - The caller does not have permission to execute the specified operation
- `404` — Not found - Some requested entity was not found
- `408` — Deadline exceeded - The deadline expired before the operation could complete
- `409` — Aborted - The operation was aborted due to concurrency issue
- `412` — Failed precondition - Operation was rejected because the system is not in required state
- `413` — Out of range - Operation was attempted past the valid range
- `429` — Resource exhausted - Some resource has been exhausted (rate limiting)
- `431` — Request header fields too large - Request metadata was too large
- `499` — Cancelled - The operation was cancelled by the client
- `500` — Internal - Internal server error
- `501` — Unimplemented - The operation is not implemented or supported
- `503` — Unavailable - The service is currently unavailable
- `504` — Deadline exceeded - Upstream service did not respond in time

## Changes

- **2026-05-19** `40e330aba8bc` — 1 breaking, 1 info
  - added `#/components/schemas/BetaManagedAgentsUserToolResultEvent, #/components/schemas/BetaManagedAgentsSessionUpdatedEvent` to the response body `oneOf` list for the response status `200`
  - added `user.tool_result, session.updated` mapping keys to the response discriminator for the response status `200`
- **2026-05-13** `88ef81f4f457` — 3 breaking
  - removed the required property `oneOf[#/components/schemas/BetaManagedAgentsAgentMcpToolResultEvent]/content/items/oneOf[#/components/schemas/BetaManagedAgentsSearchResultBlock]/tool_use_id` from the response with the `200` status
  - removed the required property `oneOf[#/components/schemas/BetaManagedAgentsAgentToolResultEvent]/content/items/oneOf[#/components/schemas/BetaManagedAgentsSearchResultBlock]/tool_use_id` from the response with the `200` status
  - removed the required property `oneOf[#/components/schemas/BetaManagedAgentsUserCustomToolResultEvent]/content/items/oneOf[#/components/schemas/BetaManagedAgentsSearchResultBlock]/tool_use_id` from the response with the `200` status
- …earlier changes not shown

[Full history](https://skmtc.dev/anthropics/apis/anthropic-api/changes/v1/sessions/:session_id/events/stream?beta=true/get.md)

---

[API](https://skmtc.dev/anthropics/apis/anthropic-api.md) · [All operations](https://skmtc.dev/anthropics/apis/anthropic-api/llms.txt) · [OpenAPI document](https://skmtc.dev/anthropics/apis/anthropic-api/revisions/478045ff0f4f?raw)
