MiniMax M3.1 Flash API

minimax/minimax-m3.1-flash
This M-series model offers a 1M-token context window and supports text, image, and video inputs for advanced reasoning tasks.
Context
1M tokens
Input
$0.195 / 1M tokens
Output
$0.78 / 1M tokens
Released
Oct 19, 2026

Overview

What Is MiniMax M3.1 Flash API?

MiniMax M3.1 Flash is a reasoning model developed by Minimax AI. It is designed to handle diverse inputs including text, images, and video to provide comprehensive analysis.

The model is engineered for high-performance tasks such as coding and agent workflows. It provides flexible reasoning capabilities and supports a large context window for complex data processing.

What MiniMax M3.1 Flash Brings to the Table

Reasoning Capabilities

The model always reasons, allowing users to adjust the reasoning effort from low to max.

Multimodal Input

It accepts text, image, and video inputs to generate text-based responses.

Large Context Window

The model supports a 1M-token context window for processing extensive information.

Tool Integration

It supports structured output and tools to enhance integration into various workflows.

Use cases

Accelerating complex coding projects through advanced reasoning.

Executing multi-step agent workflows efficiently.

Analyzing visual content from images and videos.

Processing large documents within the 1M-token context window.

How to use MiniMax M3.1 Flash API

Install any OpenAI-compatible SDK, point it at api.aimlapi.com/v1, and set the model to minimax/minimax-m3.1-flash.
import requests

r = requests.post(
    "https://api.aimlapi.com/v1/chat/completions",
    headers={"Authorization": "Bearer " + AIMLAPI_KEY},
    json={
      "model": "minimax/minimax-m3.1-flash",
      "messages": [
        {
          "role": "user",
          "content": "Hello!"
        }
      ]
    },
)
print(r.json())
const r = 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/minimax-m3.1-flash",
    "messages": [
      {
        "role": "user",
        "content": "Hello!"
      }
    ]
  }),
});
console.log(await r.json());
curl -X POST https://api.aimlapi.com/v1/chat/completions \
  -H "Authorization: Bearer $AIMLAPI_KEY" \
  -H "Content-Type: application/json" \
  -d '{"model":"minimax/minimax-m3.1-flash","messages":[{"role":"user","content":"Hello!"}]}'

OpenAI-compatible — swap the base URL and it works with your existing SDK.

MiniMax M3.1 Flash API Pricing

TypePrice
Input
$0.195 / 1M tokens
Output
$0.78 / 1M tokens
Cached input
$0.0195 / 1M tokens

Billed per token: $0.195 / 1M input tokens, $0.0195 / 1M cached input tokens and $0.78 / 1M output tokens. Reasoning tokens are billed as output.

Use cases

Accelerating complex coding projects through advanced reasoning.

Executing multi-step agent workflows efficiently.

Analyzing visual content from images and videos.

Processing large documents within the 1M-token context window.

MiniMax M3.1 Flash vs other models

ModelInputOutputContextBest for
$0.195 / 1M tokens
$0.78 / 1M tokens
1M tokens
Coding, agent workflows, and visual understanding.
$0.26 / 1M tokens
$1.43 / 1M tokens
1M tokens
Coding + agents
$0.26 / 1M tokens
$1.43 / 1M tokens
1M tokens
Coding + agents
$0.39 / 1M tokens
$1.56 / 1M tokens
1M tokens
Coding + agents
$0.13 / 1M tokens
$0.65 / 1M tokens
1M tokens
High-volume, low-latency tasks

Frequently asked questions

MiniMax M3.1 Flash costs $0.195 / 1M tokens for input and $0.78 / 1M tokens for output on AI/ML API. Cached input is billed at $0.0195 / 1M tokens.

The model supports text, image, and video inputs.

Yes, the reasoning effort can be adjusted from low to max, with max being the default.

The model features a 1M-token context window.

The model supports a maximum output of 524,288 tokens.

Start building with MiniMax M3.1 Flash

Get API Key
1000+ models, one API.