Create a chat completion
Sends a request for a model response for the given chat conversation. Supports both streaming and non-streaming modes.
Authentication
AuthorizationBearer
API key as bearer token in Authorization header
Request
Chat completion request parameters
messages
provider
When multiple model providers are available, optionally indicate your routing preference.
plugins
Plugins you want to enable for this request, including their settings.
route
Routing strategy for multiple models: “fallback” (default) uses secondary models as backups, “sort” sorts all endpoints together by routing criteria.
Allowed values:
user
session_id
A unique identifier for grouping related requests (e.g., a conversation or agent workflow) for observability. If provided in both the request body and the x-session-id header, the body value takes precedence. Maximum of 128 characters.
model
models
frequency_penalty
logit_bias
logprobs
top_logprobs
max_completion_tokens
max_tokens
metadata
presence_penalty
reasoning
response_format
seed
stop
stream
stream_options
temperature
tool_choice
tools
top_p
debug
Response
Successful chat completion response
id
choices
created
model
object
system_fingerprint
usage