MiniMax M3.1 Flash
MiniMax M3.1 Flash is MiniMax's model for coding, tool-using agents and long-context work. It accepts text, image and video input, and its reasoning depth is set with reasoning_effort. On LLMTR it is called through /v1/chat/completions.
| Model | Context | Input / Cache Read / Output ($/1M) |
|---|---|---|
minimax/minimax-m3.1-flash |
1,000,000 | 0.135 / 0.0135 / 0.54 |
The price is the same across the whole context window; there is no separate tier for long prompts. A single response is at most 524,288 tokens.
Thanks to LLMTR's agreement with MiniMax, the LLMTR price is 10% below MiniMax's list price (0.15 / 0.015 / 0.6).
curl "$LLMTR_BASE_URL/v1/chat/completions" \ -H "Authorization: Bearer llmtr-your_key" \ -H "Content-Type: application/json" \ -d '{ "model": "minimax/minimax-m3.1-flash", "messages": [ { "role": "system", "content": "You are a senior software engineer." }, { "role": "user", "content": "Find the bug in this function." } ], "reasoning_effort": "medium", "max_tokens": 8192 }'from openai import OpenAI
client = OpenAI(base_url="https://llmtr.com/v1", api_key="llmtr-your_key")
response = client.chat.completions.create( model="minimax/minimax-m3.1-flash", messages=[{"role": "user", "content": "Find the bug in this function."}], reasoning_effort="medium", max_tokens=8192,)print(response.choices[0].message.content)Reasoning effort
Section titled “Reasoning effort”Reasoning cannot be turned off; you choose its depth with the reasoning_effort field, one of five levels: low, medium, high, xhigh, max. When the field is omitted, MiniMax's default, max, applies. Pick a lower level to reduce latency and output tokens.
The level can also be given as a suffix on the model id:
minimax/minimax-m3.1-flash -> default (max)minimax/minimax-m3.1-flash:low -> least reasoningminimax/minimax-m3.1-flash:mediumminimax/minimax-m3.1-flash:highminimax/minimax-m3.1-flash:xhighminimax/minimax-m3.1-flash:max -> most reasoningnone,minimaland invalid values are refused with400; the error message lists the supported levels."reasoning": false,"reasoning": { "enabled": false }and"thinking": { "type": "disabled" }also return400. For the least reasoning, send"reasoning_effort": "low".- The model adjusts its reasoning to the difficulty of the request; on simple requests no reasoning trace may come back at all.
- The reasoning trace arrives in
choices[].message.reasoning_content, and inchoices[].delta.reasoning_contentwhen streaming;contentcarries only the answer.reasoning_split: falseis not supported.
Reasoning tokens are counted in completion_tokens and billed at the output price. They also consume the max_tokens budget: leave room for reasoning even on requests where you expect a short answer. Treat a response with finish_reason: "length" as incomplete; raise max_tokens or pick a lower level.
For how reasoning effort works in general, see the reasoning effort page.
Tool calling
Section titled “Tool calling”The model supports tool/function calling. When you return the tool's result in a role: "tool" message, the model completes its answer. In multi-step tool loops, send the assistant message that holds the tool call back together with its reasoning_content field; MiniMax recommends keeping the reasoning trace for the next turn.
curl "$LLMTR_BASE_URL/v1/chat/completions" \ -H "Authorization: Bearer llmtr-your_key" \ -H "Content-Type: application/json" \ -d '{ "model": "minimax/minimax-m3.1-flash", "messages": [{ "role": "user", "content": "What is the weather in Ankara?" }], "tools": [ { "type": "function", "function": { "name": "get_weather", "description": "Gets the current weather for a city", "parameters": { "type": "object", "properties": { "city": { "type": "string" } }, "required": ["city"] } } } ], "tool_choice": "auto", "reasoning_effort": "low" }'The assistant message on the second turn:
{ "role": "assistant", "content": "", "reasoning_content": "The user asks for the weather in Ankara, so I should call the tool.", "tool_calls": [ { "id": "call_1", "type": "function", "function": { "name": "get_weather", "arguments": "{\"city\": \"Ankara\"}" } } ]}Image and video input
Section titled “Image and video input”Alongside text, the model accepts image and video input.
- Image: an
image_urlpart; a base64 data URL or a remote https address. - Video: a
video_urlpart; send it as a base64 data URL.
Audio input is not supported.
curl "$LLMTR_BASE_URL/v1/chat/completions" \ -H "Authorization: Bearer llmtr-your_key" \ -H "Content-Type: application/json" \ -d '{ "model": "minimax/minimax-m3.1-flash", "messages": [ { "role": "user", "content": [ { "type": "text", "text": "What colour is the clothing the person in this image is wearing?" }, { "type": "image_url", "image_url": { "url": "data:image/png;base64,iVBORw0KGgo..." } } ] } ], "reasoning_effort": "low" }'A video part:
{ "type": "video_url", "video_url": { "url": "data:video/mp4;base64,AAAAIGZ0eXA..." } }Image and video tokens are counted in prompt_tokens and billed at the input price.
JSON output
Section titled “JSON output”response_format: { "type": "json_object" } returns a valid JSON object. A strict json_schema is not enforced; validate the shape on your side.
curl "$LLMTR_BASE_URL/v1/chat/completions" \ -H "Authorization: Bearer llmtr-your_key" \ -H "Content-Type: application/json" \ -d '{ "model": "minimax/minimax-m3.1-flash", "messages": [{ "role": "user", "content": "Return the capital of Turkey as a JSON object with the key \"capital\"." }], "response_format": { "type": "json_object" }, "reasoning_effort": "low" }'Prompt cache
Section titled “Prompt cache”When you send the same prompt prefix again, tokens read from the cache are billed at 0.0135 $/1M. The number of tokens read from the cache comes back in prompt_tokens_details.cached_tokens. The cache is a discount, not a guarantee; putting a long, unchanging system prompt or document at the start of the messages improves the hit rate.
Streaming
Section titled “Streaming”stream: true is supported. If you send stream_options: { "include_usage": true }, usage arrives in the last chunk.
Moving from the preview
Section titled “Moving from the preview”Requests to the minimax/minimax-m3.1-flash-preview and minimax/minimax-m3.1-free ids return an error that names this model. Change the id to minimax/minimax-m3.1-flash; this model is metered and is charged to your balance.