For a complete guide on handling SSE responses, see the Chat Overview.
Bearer token obtained from the authenticate endpoint.
Set to
text/event-stream to receive SSE responses.The natural language message to send.
ID of an existing chat to continue the conversation. Omit to create a new chat.
ID of the database integration to query. Required for database queries.
Custom title for new chats. If omitted, a title is generated automatically.
Response
The response is a stream of Server-Sent Events. See Chat Overview for details on handling the stream.Event types
| Event | Data | Description |
|---|---|---|
chat_metadata | {"id": "chat_..."} | New chat ID (only for new chats) |
processing | {"status": "thinking"} | AI is processing the request |
visualization | {"id": "viz_..."} | A chart was generated |
message | {"content": "...", "id": "msg_..."} | The final response |
error | {"error": "..."} | An error occurred |