POST Chat

Create a chat completion

OpenAI ChatCompletion-compatible endpoint. Set `stream: true` to receive a Server-Sent Events stream where each `data:` line is a `chat.completion.chunk` payload terminated by `data: [DONE]`. Model id is the API-platform id from `GET /v1/models`.

Endpoint

post/v1/chat/completions

Responses

200

Chat completion (non-stream) or SSE event stream when `stream: true`

400

Invalid request

401

Missing or invalid API key

402

Insufficient balance