Skip to main content
POST

Introduction

Universal text chat interface supporting OpenAI-compatible large language models. Through a unified API, you can access OpenAI, Claude, DeepSeek, Grok, Qwen, and many other mainstream models via MixRoute

Authentication

Bearer Token, e.g., Bearer sk-xxxxxxxxxx

Request Parameters

string
required
Model identifier, corresponding to the Model Marketplace.
MixRoute supports multiple models. See the complete list at Model Marketplace.
array
required
Array of conversation messages, each containing role (user/system/assistant) and content
number
Randomness control, 0-2. Higher values produce more random responses
boolean
Enable streaming output, returns SSE format chunked data
integer
Maximum tokens to generate, controls response length
object
Output format, supports text or json_object / json_schema
number
Nucleus sampling parameter, 0-1, alternative to temperature. Lower values make sampling more conservative
number
Frequency penalty, -2 to 2. Positive values reduce repetition of frequent tokens
number
Presence penalty, -2 to 2. Positive values encourage discussing new topics
string | array
Stop sequences, generation stops when specified strings are encountered
integer
Random seed. Same seed makes results more consistent
string
End-user identifier for monitoring and rate-limiting
integer
Number of response candidates per prompt, defaults to 1
object
Token bias, maps token IDs to bias values (-100 to 100)
array
Tools definition list, each tool must include type and function
string
Tool selection strategy: "auto" / "none" / "required", or specify a tool name

Basic Examples

Advanced Features

Supports OpenAI-compatible tool calling format:

Response Format

Error Handling