POST
This is OpenAI’s original and most widely used chat protocol. It currently has the best compatibility, and almost every provider and SDK supports it.
However, its capabilities are relatively limited. Many new features of OpenAI’s newer models are offered in the Responses protocol instead. If you only need lightweight chat and basic streaming output, this protocol is sufficient.
https://api.poixe.com/v1/chat/completionsAuthentication and request headers
Every API request must include your API key in the HTTP headers.Request parameters
The following are the core parameters most commonly used when building a chat request.Whether to stream the output. When enabled, the server sends tokens incrementally via SSE (Server-Sent Events).
Sampling temperature (0 to 2). Lower values (such as 0.2) make the output more focused and deterministic; higher values (such as 0.8) make it more creative and random.
The maximum number of tokens the model can generate (including reasoning tokens). Recommended as a replacement for the deprecated
max_tokens.Presence penalty (-2 to 2): encourages the model to introduce new topics (less repetition).
Frequency penalty (-2 to 2): reduces the likelihood of repeating the same words or sentences.
Response structure
The endpoint returns an object containing the generated result and usage statistics.Official docs: Create chat completion
View OpenAI’s official parameter descriptions and examples.