Anthropic Messages API Reference
Send Anthropic Messages API requests to Claude models with the official Anthropic SDKs, without guardrails.
Guide: Anthropic Messages
Authorizations
Headers
Optional. If sent, must be 2023-06-01.
2023-06-01 Comma-separated beta features. Supported: context-management-2025-06-27, thinking-display-updates-2026-08-18, interleaved-thinking-2025-05-14, fine-grained-tool-streaming-2025-05-14. Any other value is dropped and named in x-gloo-ignored-betas.
Body
An Anthropic Messages request. Fields are as defined by Anthropic's Messages API. Any other top-level field is dropped and named in x-gloo-ignored-params.
A Claude model: a Gloo model ID such as gloo-anthropic-claude-opus-5.5, or Anthropic's ID such as claude-opus-5-5.
"gloo-anthropic-claude-opus-5.5"
Maximum output tokens, including thinking. Above the model's output limit it is lowered to that limit. Above 21,333 requires stream: true.
x >= 1The conversation. Roles are user and assistant. Content is a string or an array of blocks: text, image (base64 or URL source), document (base64, text, content or URL source), search_result, tool_use, tool_result, thinking, redacted_thinking, and server_tool_use / web_search_tool_result when the web search tool is in tools. thinking and redacted_thinking blocks are accepted but not passed to the model; the x-gloo-ignored-params header lists messages.thinking when any were sent.
1System prompt: a string or an array of text blocks.
Stream the response as Server-Sent Events.
Your own tools, plus the Anthropic-defined web search (web_search_*), bash (bash_*) and text editor (text_editor_*) tools. Other tool types return 400.
Thinking configuration, sent as written, for example {"type": "adaptive", "display": "summarized"}.
Output configuration, sent as written, for example {"effort": "high"}.
Automatic prompt caching, for example {"type": "ephemeral"}.
Context editing. Requires the context-management-2025-06-27 beta; otherwise dropped.
Only user_id is used, and it is not passed to the model provider as sent.
Response
The model's message. With stream: true, a Server-Sent Events stream of Anthropic's Messages events (message_start, content_block_start, content_block_delta, content_block_stop, message_delta, message_stop, ping). A failure after the stream starts ends it with an error event.

