Request
array
required
An array of message objects forming the conversation. Each object requires a
role (system, developer, user, or assistant) and a content string. Content must be plain text. Multimodal arrays are rejected.number
Sampling temperature between
0 and 2. Higher values produce more varied output; lower values produce more focused, deterministic output. Support varies per model.number
Nucleus sampling probability mass. The model considers only the tokens comprising the top
top_p probability mass. Support varies per model.integer
Kyara extension. Limits sampling to the top
k most likely tokens. Accepted by many models beyond the OpenAI standard.integer
Maximum number of tokens to generate. You can use
max_completion_tokens interchangeably.integer
Alias for
max_tokens. Maximum number of tokens to generate in the completion.boolean
Set to
true to receive the response as Server-Sent Events, token by token. Defaults to false.object
Controls reasoning behaviour for models that support it. Pass an object with either or both of:
effort(string), for example"low","medium", or"high"max_tokens(integer), the maximum tokens to spend on reasoning
reasoning_effort is also accepted and is folded into reasoning.effort. If you set both, reasoning.effort takes precedence.integer
Number of completion choices to generate. Only
1 is supported; any other value returns a 400 error. Defaults to 1.string | array
Up to four sequences where the model will stop generating further tokens.
integer
A seed for deterministic sampling. Passing the same seed and request parameters should produce the same result, though determinism is not guaranteed.
Response
A successful request returns a JSON object matching the OpenAI chat completions schema.string
A unique identifier for the completion, prefixed with
chatcmpl-.string
Always
"chat.completion" for non-streaming responses.string
The model ID that was used to generate the response.
array
An array of completion choices.
object
Token usage for the request.
Streaming
Set"stream": true to receive the response as Server-Sent Events. Kyara sends one data: event per token and terminates the stream with data: [DONE].
curl
"stream_options": { "include_usage": true } to your request.
Model IDs and pricing can change during early access. Use the models page as the current source of truth for available models.
Features such as tool calling, structured outputs, vision, and embeddings are not supported. See Unsupported Features for the complete list.