Platform Chat API
The Platform Chat API creates chat responses for applications that want to use Glean's knowledge and AI capabilities through the modern Platform API surface.
Use Cases
Grounded Answers
Send a user request and receive a response grounded in your Glean instance.
Streaming Responses
Receive the response as server-sent events so your application can render it as it arrives.
API Endpoints
| Method | Endpoint | Purpose |
|---|---|---|
| POST | /api/chat | Create a chat response |
| POST | /api/chat | Create a streaming chat response |
The default response is JSON. To stream, set stream to true in the JSON body. An Accept: text/event-stream header does not replace stream.
Configure the bearer credential with the Platform API authentication guide.
For error responses, see Platform API Errors for the shared ProblemDetail code reference and remediation guidance.