Model providers
Using MiniMax with OpenClaw
Browse more in Model providers.
All model providers guides →This guide walks you through configuring MiniMax as a model provider in OpenClaw, including both OAuth-based Coding Plan access and direct API key setups. You’ll wire MiniMax into OpenClaw’s model catalog, set it as a default for chat, image, music, and video generation, and verify everything with the CLI.
7 and related media models through a single unified config.
Prerequisites
- ✓An active MiniMax Coding Plan or MiniMax API key so you can authenticate either via OAuth or direct API.
- ✓An OpenClaw installation new enough to include the MiniMax provider and `openclaw onboard` / `openclaw configure` commands.
- ✓Access to `api.minimax.io` or `api.minimaxi.com` from your environment, depending on whether you use the international or China endpoints.
Steps
- 1
Decide between OAuth Coding Plan and API key auth
Pick whether you want to connect MiniMax via the Coding Plan OAuth flow or via a direct API key. OAuth is best when you use the MiniMax Coding Plan and don’t want to manage raw keys; API key mode is better when you already have an Anthropic-compatible MiniMax key and want explicit control over base URLs.
- 2
Run MiniMax onboarding with global OAuth
If you use the international MiniMax Coding Plan, run the global OAuth onboarding flow. 7`.
bashopenclaw onboard --auth-choice minimax-global-oauth - 3
Run MiniMax onboarding with China OAuth
If your account is in the China region, use the China OAuth onboarding flow instead. com` and still exposes models through the `minimax-portal` provider id.
bashopenclaw onboard --auth-choice minimax-cn-oauth - 4
Run MiniMax onboarding with a global API key
For direct API key setups in the international region, use the global API onboarding choice. 7`.
bashopenclaw onboard --auth-choice minimax-global-api - 5
Run MiniMax onboarding with a China API key
If your MiniMax API key targets the China region, run the China API onboarding flow. com` as the base URL for the `minimax` provider.
bashopenclaw onboard --auth-choice minimax-cn-api - 6
Verify MiniMax models are registered for your auth path
After onboarding, confirm that OpenClaw sees the MiniMax models under the correct provider id. Use `minimax-portal` for OAuth setups and `minimax` for API-key setups so you don’t chase case or provider-id issues later.
bashopenclaw models list --provider minimax-portal - 7
Verify MiniMax models for API key setups
If you configured MiniMax via API key, list models under the `minimax` provider. This is also a quick sanity check that your `MINIMAX_API_KEY` or related auth is wired correctly.
bashopenclaw models list --provider minimax - 8
Configure MiniMax provider and default chat model
Add an explicit MiniMax provider block so you control base URLs, APIs, pricing metadata, and which models OpenClaw exposes. 7` as the default agent model.
json{ env: { MINIMAX_API_KEY: "sk-..." }, agents: { defaults: { model: { primary: "minimax/MiniMax-M2.7" } } }, models: { mode: "merge", providers: { minimax: { baseUrl: "https://api.minimax.io/anthropic", apiKey: "${MINIMAX_API_KEY}", api: "anthropic-messages", models: [ { id: "MiniMax-M2.7", name: "MiniMax M2.7", reasoning: true, input: ["text", "image"], cost: { input: 0.3, output: 1.2, cacheRead: 0.06, cacheWrite: 0.375 }, contextWindow: 204800, maxTokens: 131072, }, { id: "MiniMax-M2.7-highspeed", name: "MiniMax M2.7 Highspeed", reasoning: true, input: ["text", "image"], cost: { input: 0.6, output: 2.4, cacheRead: 0.06, cacheWrite: 0.375 }, contextWindow: 204800, maxTokens: 131072, }, ], }, }, }, } - 9
Set MiniMax as the default image generation provider
If you want OpenClaw’s `image_generate` tool to use MiniMax, set the default image generation model to `minimax/image-01`. The MiniMax plugin reuses the same auth as your text models, so you don’t need extra keys for image generation.
json{ agents: { defaults: { imageGenerationModel: { primary: "minimax/image-01" }, }, }, } - 10
Set MiniMax as the default music generation provider
5+`. 0` explicitly if you need older tiers.
json{ agents: { defaults: { musicGenerationModel: { primary: "minimax/music-2.5+", }, }, }, } - 11
Set MiniMax as the default video generation provider
3`. This enables text-to-video and single-image reference flows through the shared `video_generate` tool.
json{ agents: { defaults: { videoGenerationModel: { primary: "minimax/MiniMax-Hailuo-2.3", }, }, }, } - 12
Configure MiniMax as a failover model
If you already use another primary model (for example Anthropic Opus), you can keep it as primary and add MiniMax as a fallback. 7` when the primary fails.
json{ env: { MINIMAX_API_KEY: "sk-..." }, agents: { defaults: { models: { "anthropic/claude-opus-4-6": { alias: "primary" }, "minimax/MiniMax-M2.7": { alias: "minimax" }, }, model: { primary: "anthropic/claude-opus-4-6", fallbacks: ["minimax/MiniMax-M2.7"], }, }, }, } - 13
Use the interactive configure wizard for MiniMax
If you prefer not to edit JSON by hand, use `openclaw configure` to set MiniMax auth and defaults. The wizard lets you pick a MiniMax auth choice and default model from a menu, then writes the config for you.
bashopenclaw configure
Configuration
| Option | Description | Example |
|---|---|---|
| MINIMAX_API_KEY | MiniMax API key used for API-key setups on the `minimax` provider and as a compatibility fallback for Coding Plan search when it already points at a coding-plan token. | sk-... |
| MINIMAX_CODE_PLAN_KEY | Preferred MiniMax Coding Plan key used by the MiniMax web search integration for the `web_search` tool. | sk-coding-plan-... |
| MINIMAX_CODING_API_KEY | Accepted alias for the MiniMax Coding Plan key used by the MiniMax web search integration. | sk-coding-api-... |
| models.providers.minimax.baseUrl | Base URL for MiniMax API calls; prefer the Anthropic-compatible endpoint for `anthropic-messages`. | https://api.minimax.io/anthropic |
| models.providers.minimax.api | API protocol OpenClaw uses for MiniMax; prefer `anthropic-messages` or optionally `openai-completions`. | anthropic-messages |
| models.providers.minimax.apiKey | Config key that points to your MiniMax API key, typically wired from `MINIMAX_API_KEY`. | ${MINIMAX_API_KEY} |
| models.providers.minimax.models | Array of MiniMax model definitions including id, name, reasoning, contextWindow, maxTokens, and cost. | [{ id: "MiniMax-M2.7", name: "MiniMax M2.7" }] |
| agents.defaults.model.primary | Default primary chat model for agents, which you can set to a MiniMax model reference. | minimax/MiniMax-M2.7 |
| agents.defaults.imageGenerationModel.primary | Default image generation model for the `image_generate` tool, which you can set to MiniMax image-01. | minimax/image-01 |
| agents.defaults.musicGenerationModel.primary | Default music generation model for the `music_generate` tool, which you can set to MiniMax music-2.5+. | minimax/music-2.5+ |
| agents.defaults.videoGenerationModel.primary | Default video generation model for the `video_generate` tool, which you can set to MiniMax Hailuo 2.3. | minimax/MiniMax-Hailuo-2.3 |
| models.mode | Controls how MiniMax models merge with built-ins; keep `merge` to add MiniMax alongside existing providers. | merge |
| plugins.entries.minimax.config.webSearch.region | Region setting MiniMax web search uses when resolving which MiniMax endpoint to call. | global |
Troubleshooting
"Unknown model: minimax/MiniMax-M2.7"
This usually means the MiniMax provider is not configured at all, so OpenClaw can’t match the model ref to a provider. minimax-portal` block, or set `MINIMAX_API_KEY`, `MINIMAX_OAUTH_TOKEN`, or a MiniMax auth profile so the provider can be injected.
7`.
openclaw models listMiniMax model references work for text but image understanding or media tools don’t trigger MiniMax
The bundled provider catalog exposes MiniMax chat refs as text-only metadata until you have an explicit MiniMax provider config. 3` for media tools.
` models you want.
Frequently asked questions
Powered by Mem0
Add persistent memory to OpenClaw
Official Mem0 plugin for OpenClaw keeps context across chats and tools. Smaller prompts, lower cost, better continuity for your agents.