Skip to main content
POST
Create an Anthropic Messages-compatible response

Headers

Authorization
string | null

Bearer API key.

x-api-key
string | null

API key alternative for Anthropic-compatible clients. Authorization takes precedence when both headers are present.

Body

application/json

Anthropic Messages-compatible request.

model
string
required
Minimum string length: 1
max_tokens
integer
required
Required range: 1 <= x <= 999990
messages
AnthropicMessage · object[]
required
Minimum array length: 1
system
stream
boolean
default:false
temperature
number | null
Required range: 0 <= x <= 1
top_p
number | null
Required range: 0 <= x <= 1
top_k
integer | null
Required range: x >= 0
stop_sequences
string[] | null
tools
Tools · object[] | null
tool_choice
AnthropicToolChoice · object | null
thinking
AnthropicThinking · object | null
output_config
AnthropicOutputConfig · object | null
context_management
AnthropicContextManagement · object | null

Supported beta context-management subset.

keep=all does not remove any replayed thinking blocks, so it can be safely consumed at the compatibility boundary and omitted from the vLLM provider payload.

metadata
Metadata · object | null
service_tier
enum<string> | null
Available options:
auto,
standard_only
flagged_categories
enum<string>[]
Available options:
harassment,
harassment/threatening,
hate,
hate/threatening,
illicit,
illicit/violent,
self-harm,
self-harm/intent,
self-harm/instructions,
sexual,
sexual/minors,
violence,
violence/graphic

Response

Successful Response

id
string
required
Pattern: ^msg_
content
Content · object[]
required
model
string
required
stop_reason
enum<string> | null
required
Available options:
end_turn,
max_tokens,
stop_sequence,
tool_use
usage
AnthropicUsage · object
required
type
string
default:message
Allowed value: "message"
role
string
default:assistant
Allowed value: "assistant"
stop_sequence
string | null
Last modified on August 11, 2026