Endpoint
Headers
| Header | Required | Description |
|---|---|---|
Authorization | Yes | Bearer sk-occ-your-key-here |
Content-Type | Yes | application/json |
Request body
Model identifier. See Supported Models for the full list.Examples:
gpt-4o, claude-sonnet-4-6, gemini-2.5-proArray of message objects. Each message has a
role and content.Supported roles: system, user, assistantIf
true, returns a stream of server-sent events.Sampling temperature (0-2). Passed through to the model.
Maximum tokens to generate. Passed through to the model.
Nucleus sampling parameter. Passed through to the model.
Stop sequences. Passed through to the model.
frequency_penalty, presence_penalty, logprobs, tools, tool_choice, etc.) are passed through to the upstream model.
Response
Unique identifier for this completion.
Always
"chat.completion".Unix timestamp of when the completion was created.
The model used, matching your request.
Array of completion choices.
Token usage statistics.