List models
sorat-agent entry.
Response
Create chat completion
Headers
| Header | Description |
|---|---|
X-Session-ID | Optional session UUID. Auto-creates a session if not provided. |
Authorization | Bearer <token> |
Request body
Non-streaming response
Streaming response (SSE)
Whenstream: true, the response is a Server-Sent Events stream:
Session management
- If
X-Session-IDis provided, messages are appended to that session - If not provided, a new session is created automatically
- Sessions are persisted to disk (
~/.sorat/sessions/) - Session titles are generated asynchronously after the first response
Example with curl
Tool calls
The agent can make multiple tool calls per request (up tomax_iterations, default 30). Tool calls and their results are handled internally by the ADK runner — you receive the final text response.
In streaming mode, tool call names appear in the delta: