Chat API
The Chat API provides direct access to Squad’s intelligence engine through REST endpoints with real-time SSE streaming.
Endpoints
| Method | Endpoint | Description |
|---|---|---|
POST | /api/v1/chat | Create a new chat session (rate limited: 60/min) |
POST | /api/v1/chat/{session_id}/message | Send a message (rate limited: 30/min) |
GET | /api/v1/chat/{session_id}/stream | SSE event stream for real-time progress |
GET | /api/v1/chat/{session_id}/events | Historical event trace for a session |
GET | /api/v1/chat/{session_id}/status | Session status |
POST | /api/v1/chat/{session_id}/disambiguate | Send disambiguation response |
POST | /api/v1/chat/{session_id}/review | Submit review response |
GET | /api/v1/chat/{session_id}/history | Get session message history |
GET | /api/v1/chat/history | List all chat sessions |
Live Stream vs Historical Events
/streamdelivers Server-Sent Events in real time as AIM processes a query. Connect when you send a message and listen for progress updates./eventsreturns the full event trace for a session after processing completes. Use this to replay or inspect what happened during a previous interaction.
Next Steps
- API Overview: authentication, error codes, and base URL
- Queries API: query curation endpoints