/v1/messages directly. These mappings are for routing it through /v1/chat/completions instead.
system field is not read on Chat Completions.
Accepted roles: system, user, assistant, tool, developer. Anthropic tool use maps to Chat Completions tool calling. Token counting on Chat Completions comes from usage; /v1/messages/count_tokens exists for a dedicated call.
Differences
system_fingerprintis alwaysnull.- The error envelope is
{"error": {"message", "code", "param"}}with notype. - Exactly one choice.
- End-to-end encryption runs on Chat Completions only, with extra headers. See Enabling End-to-End Encryption.
Related
SDKs
Overview.
Anthropic SDK Drop-in
Quickstart.
Base URL Swap
Two paths in.
Tool Calling
Function calls.
Chat Completions
The endpoint.
How Privacy Works
Privacy-preserving hardware on every call.

