Endpoint
Headers
Request body
string
required
Model identifier. See Supported Models for the full list.Examples:
gpt-4o, claude-sonnet-4-6, gemini-2.5-proarray
required
Array of message objects. Each message has a
role and content.Supported roles: system, user, assistantboolean
default:"false"
If
true, returns a stream of server-sent events.number
Sampling temperature (0-2). Passed through to the model.
integer
Maximum tokens to generate. Passed through to the model.
number
Nucleus sampling parameter. Passed through to the model.
string | array
Stop sequences. Passed through to the model.
frequency_penalty, presence_penalty, logprobs, tools, tool_choice, etc.) are passed through to the upstream model.
Response
string
Unique identifier for this completion.
string
Always
"chat.completion".integer
Unix timestamp of when the completion was created.
string
The model used, matching your request.
array
Array of completion choices.
object
Token usage statistics.