Speed
Output tokens / second
Custom pricing for production workloads
MiniMax-M2.1 is an updated Minimax model with a 200K context window optimized for conversational and reasoning tasks.
Engineered for speed and precision, it delivers top-tier multilingual code generation with clean, actionable outputs.
minimax/m2-1https://api.aimlapi.com/v1MiniMax-M2.1 is a cutting-edge large language model built for high-performance code generation, refactoring, and cross-language reasoning. Optimized for real-world developer workflows, it supports languages such as Rust, Java, Go, C++, TypeScript, and JavaScript, offering fast, clean, and reliable outputs.
Evaluated using rigorous internal frameworks (e.g., OctoCodingbench, SWE Review), with results averaged over 4 runs.
vs. Claude Sonnet 4.5: M2.1 matches or exceeds Sonnet 4.5 in coding-specific benchmarks while using far fewer activated parameters. Offers significantly lower inference cost and latency, making it ideal for high-throughput coding agents.
vs. DeepSeek-Coder: M2.1 demonstrates stronger instruction following in complex, multi-step coding scenarios (e.g., full-stack feature implementation). Excels in real-world tool integration and stateful reasoning, critical for IDE plugins and autonomous agents.
See how MiniMax-M2.1 compares in generation speed and latency. Data retrieved Nov 3, 2026.
Output tokens / second
Compare 12 models available on AI/ML API across 5 independent benchmarks.
Expert-written questions across academic subjects.
Graduate-level science questions written to resist web search.
Reasoning across long documents of about 100k tokens.
Following precise instructions about the shape of the answer.
Customer support agent tasks with tool calls.
| Usage | Price | Unit |
|---|---|---|
| Input | $0.3 | 1M tokens |
| Output | $1.2 | 1M tokens |
| Cached input | $0.3 | 1M tokens |
Prices from the AI/ML API price list, checked on Nov 4, 2026.
AI/ML API input and output rates for 5 models, per million tokens.
| Model | Input | Output |
|---|---|---|
| $0.3 | $1.2 | |
| $0.15 | $0.6 | |
| $0.3 | $1.2 | |
| $0.6 | $2.4 | |
| $0.6 | $2.4 |
Give your agent the model details, code and documentation.
export AIMLAPI_KEY="8f2b4c7d9a1e6b3f…"curl 'https://api.aimlapi.com/v1/chat/completions' \
-H "Authorization: Bearer $AIMLAPI_KEY" \
-H 'Content-Type: application/json' \
-d '{
"model": "minimax/m2-1",
"messages": [
{
"role": "user",
"content": "Write a haiku about the ocean."
}
]
}'import os
import requests
headers = {
"Authorization": f"Bearer {os.environ['AIMLAPI_KEY']}",
"Content-Type": "application/json",
}
payload = {
"model": "minimax/m2-1",
"messages": [
{
"role": "user",
"content": "Write a haiku about the ocean."
}
]
}
response = requests.post("https://api.aimlapi.com/v1/chat/completions", headers=headers, json=payload, timeout=120)
response.raise_for_status()
print(response.json())const response = await fetch("https://api.aimlapi.com/v1/chat/completions", {
method: "POST",
headers: {
Authorization: `Bearer ${process.env.AIMLAPI_KEY}`,
"Content-Type": "application/json",
},
body: JSON.stringify({
"model": "minimax/m2-1",
"messages": [
{
"role": "user",
"content": "Write a haiku about the ocean."
}
]
}),
});
if (!response.ok) throw new Error(`HTTP ${response.status}`);
console.log(await response.json());MiniMax-M2.1 has a 204,000 tokens context window and can return up to 204,000 tokens.
MiniMax-M2.1 takes image, text as input and returns text.
Use minimax/m2-1 as the model id. Requests go to https://api.aimlapi.com/v1/chat/completions.
MiniMax-M2.1 costs $0.3 input and $1.2 output per 1M tokens on AI/ML API, billed as you go with no subscription.
Yes, MiniMax-M2.1 can stream responses as they are generated.
Yes, MiniMax-M2.1 accepts image input alongside text.
MiniMax-M2.1 was built by MiniMax.