Guides
Anthropic Messages SDK
Drop-in for the Anthropic Python/TS packages: same Messages shape, Rodium key, Claude models.
POST
https://api.rodiumai.io/v1/messagesPrefer this path when your app already uses the Anthropic SDK. OpenAI-compatible chat still works for Claude via /v1/chat/completions.
Auth & base URL
Pass api_key=rd_sk_… (SDK sends x-api-key). Bearer Authorization is also accepted. Base URL:
https://api.rodiumai.ioAnthropic SDK vs OpenAI SDK
OpenAI clients use base_url https://api.rodiumai.io/v1 and chat.completions. Anthropic clients use base_url https://api.rodiumai.io (no /v1) and messages.create. Same rd_sk_… secret; never send Anthropic’s server key to clients.
Install
…First message
…Streaming (native Anthropic SSE)
…Claude-first MVP
Only anthropic/* models are routed on /v1/messages today. Multi-provider Messages bridging is planned later.
Request parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| model | string | Required | Anthropic catalogue id (e.g. anthropic/claude-sonnet-4-6). Claude-first MVP. |
| messages | array | Required | Anthropic Messages array (role + content blocks or text). |
| max_tokens | integer | Required | Maximum output tokens (required by Anthropic Messages). |
| system | string | array | Optional | Optional system prompt. |
| stream | boolean | Optional | When true, returns native Anthropic SSE (message_start, content_block_delta, …). |
| temperature | number | Optional | Sampling temperature when supported. |
| tools | array | Optional | Anthropic tool definitions (non-stream recommended for tool rounds). |