tools feature in their catalog entry. The request and response shapes match the OpenAI Chat Completions API.
Defining tools
Response
When the model decides to call a tool, the response carriestool_calls and finish_reason: "tool_calls":
Returning tool results
Append the assistant’s tool call and your tool’s output tomessages, then call the API again:
tool_choice
Default is "auto" — the model decides whether to call a tool. Other modes:
"none"— disable tool calling for this request"required"— force a tool call{"type": "function", "function": {"name": "..."}}— force a specific tool
Streaming tool calls
Withstream: true, tool call arguments arrive as deltas. Concatenate delta.tool_calls[i].function.arguments strings across chunks to reconstruct the full JSON.
Model support
Not every model in our catalog supports tools. Checksupported_features in /v1/models — only models that include "tools" will reliably call functions. See Models.