Skip to main content
POST
アプリケーション、SDK、またはエージェントが Anthropic Messages のリクエストとレスポンス形式を期待する場合は、このエンドポイントを使ってください。 modelmessagesmax_tokens を含む標準の Messages ペイロードを送信します。Capriole AI は上流へ送る前に latest エイリアスを選択した上流 Claude モデルに解決し、systemtoolsthinkingstream などの互換フィールドを転送し、上流の JSON または SSE ストリームをそのまま返します。 POST /v1/messagesclaude-latestclaude-fable-5claude-opus-5claude-opus-4-8claude-opus-4-7claude-opus-4-6claude-sonnet-4-6 を受け付けます。設定を変えずに Fable 5 を選ぶには、claude-latest を使ってください。 POST /v1/messages/count_tokens は、Anthropic 互換のトークンカウント確認のために同じ Claude モデル ID を受け付けます。選択した上流のトークンカウント応答またはエラーを返します。 シンプルな Capriole ネイティブのテキスト生成には POST /v1/chat を使ってください。Anthropic Messages のワイヤ動作が必要な場合は POST /v1/messages を使ってください。

承認

Authorization
string
header
必須

Use an API key created in the Capriole AI page. Send it as Authorization: Bearer sk-....

ボディ

application/json
model
enum<string>
必須

Public Anthropic Messages model identifier or Claude latest alias

利用可能なオプション:
claude-latest,
claude-fable-5,
claude-opus-5,
claude-opus-4-8,
claude-opus-4-7,
claude-opus-4-6,
claude-sonnet-4-6
messages
object[]
必須

Anthropic-compatible conversation messages.

max_tokens
integer
必須

Maximum number of output tokens.

system

Optional Anthropic-compatible system prompt.

tools
object[]

Anthropic-compatible tool definitions.

thinking
object

Anthropic-compatible thinking options.

stream
boolean
デフォルト:false

Stream the response as Anthropic-compatible server-sent events.

レスポンス

Anthropic Messages-compatible JSON response or SSE stream

Anthropic Messages-compatible response body.

最終更新日 2026年8月18日