Quick Start
1. Install AI SDK and MiniMax Provider
2. Configure Environment Variables
3. Call API
TypeScript
4. Important Note
In multi-turn function call conversations, the complete model response (i.e., the assistant message) must be appended to the conversation history to maintain the continuity of the reasoning chain.- Append the full
result.response.messagesto the message history (includes all assistant and tool messages)
Supported Models
When using the AI SDK, theMiniMax-M3 MiniMax-M2.7 MiniMax-M2.7-highspeed MiniMax-M2.5 MiniMax-M2.5-highspeed MiniMax-M2.1 MiniMax-M2.1-highspeed MiniMax-M2 models are supported:
For details on how tps (Tokens Per Second) is calculated, please refer to FAQ > About APIs.
The AI SDK compatibility interface currently supports the
MiniMax-M3 MiniMax-M2.7 MiniMax-M2.7-highspeed MiniMax-M2.5 MiniMax-M2.5-highspeed MiniMax-M2.1 MiniMax-M2.1-highspeed MiniMax-M2 models. For other models, please use the standard MiniMax API
interface.Compatibility
Supported Parameters
When using the AI SDK, we support the following input parameters:Messages Field Support
Examples
Streaming Response
TypeScript