Registry / llm-agents / mmx-cli

mmx-cli

JSON →
library1.0.11jsnpmunverified

The `mmx-cli` package provides the official command-line interface for interacting with the MiniMax AI Platform, enabling users and AI agents to programmatically access various AI capabilities. This robust CLI, currently at version 1.0.11, supports a wide array of generative AI tasks including multi-turn text chat with streaming and JSON output, text-to-image generation with aspect ratio controls, asynchronous video generation with progress tracking, text-to-speech with over 30 voices, and text-to-music generation including lyrical and instrumental modes. It also features image understanding (vision) and web search integration. Designed for both direct terminal use and integration into AI agents (e.g., OpenClaw, Cursor, Claude Code), it emphasizes ease of use for rapid prototyping and deployment of AI-powered workflows. The CLI offers seamless support for both Global (`api.minimax.io`) and CN (`api.minimaxi.com`) platform regions. While a specific release cadence isn't published, the frequent updates to generative AI models suggest active development and maintenance.

npm install mmx-cli
INSTALL
IMPORT
SIG · MMX-CLI
M
mmx-cli
llm-agentsjavascriptv1.0.11
Install
Import
Disk
Pass rate
0/ 6
Env Coverage0 / 6
glibc
1822
musl
1822
Install & Compatibility
Where this runs
tested against v? · npm install
Install × environment matrix
Each cell = how many times install + import succeeded across repeated harness runs. Partial = flaky.
glibc = Debian/Ubuntu slim · musl = Alpine Linux
musl
node 18226 runs
build_error
glibc
node 18226 runs
build_error
Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

mmx
npm install -g mmx-cli
import { mmx } from 'mmx-cli'
The `mmx` command is made globally available by installing the package. This tool is primarily a CLI and not designed for direct programmatic import into JavaScript/TypeScript applications.
npx mmx
npx mmx text chat --message "Hello"
const mmx = require('mmx-cli')
The `npx` utility allows executing `mmx-cli` commands without a global installation, ensuring the latest version is used on demand and avoiding global package pollution.
skills add MiniMax-AI/cli
npx skills add MiniMax-AI/cli -y -g
For AI agents (e.g., OpenClaw, Cursor, Claude Code), `mmx-cli` can be integrated as a skill via `npx skills`, making its capabilities accessible within the agent's environment.

Demonstrates authentication, text, image, speech, video, music, search, and vision generation, plus quota checking using the `mmx` CLI, showcasing its core functionalities.

# Authenticate with your API key mmx auth login --api-key sk-xxxxx-YOUR_API_KEY_HERE # Generate text: What is MiniMax? mmx text chat --message "What is MiniMax?" # Generate an image: A cat in a spacesuit mmx image "A cat in a spacesuit" # Synthesize speech: "Hello!" to an MP3 file mmx speech synthesize --text "Hello!" --out hello.mp3 # Generate video: Ocean waves at sunset mmx video generate --prompt "Ocean waves at sunset" # Generate music: Upbeat pop with lyrics mmx music generate --prompt "Upbeat pop" --lyrics "[verse] La da dee, sunny day" # Perform a web search: MiniMax AI latest news mmx search "MiniMax AI latest news" # Analyze an image (replace photo.jpg with your image path) mmx vision photo.jpg # Check your current quota usage mmx quota
mmx --version
Debug
Known issues
gotchaThe `mmx-cli` requires Node.js version 18 or higher to function correctly. Older Node.js versions may lead to installation failures or runtime errors.
fix
Upgrade Node.js to version 18 or newer. Use a Node.js version manager like `nvm` (e.g., `nvm install 18 && nvm use 18`).
affects: <18.0.0
gotchaA MiniMax API key is mandatory for using any of the AI capabilities provided by the CLI. Attempts to use commands without prior authentication will result in authorization errors.
fix
Obtain an API key from the MiniMax platform and authenticate using `mmx auth login --api-key sk-xxxxx`. Ensure your token plan is active.
affects: >=1.0.0
gotchaWhile `npm install -g mmx-cli` makes the `mmx` command globally available, it can lead to versioning conflicts if multiple projects require different CLI versions. Using `npx mmx ...` ensures you always run the latest or a project-specific version without global installation.
fix
For project-specific use or to avoid global pollution, prefer `npx mmx <command>` instead of global installation. If global installation is desired, periodically update with `npm update -g mmx-cli`.
affects: >=1.0.0
Errors
Common errors & fixes
mmx: command not found
The `mmx-cli` package is not installed globally or is not in your system's PATH, or you are trying to run it without `npx`.
fix
Install globally with `npm install -g mmx-cli` or execute on demand using `npx mmx <command>`.
Error: Unauthorized - Invalid API Key or missing authentication.
The MiniMax API key is either not set, incorrect, or expired. The CLI could not authenticate with the MiniMax platform.
fix
Authenticate using `mmx auth login --api-key sk-xxxxx` with a valid and active API key. Ensure your token plan has sufficient quota.
Error: Invalid model specified. Available models are: [list of models]
The `--model` flag was used with a model name that is not supported by the MiniMax API or the specified command.
fix
Consult the MiniMax documentation or use `mmx text chat --help` to find available models for the specific command, or use a default model.
Upgrade
Version history
1.0.11latest on npm
Audit
Dependencies

No dependency data recorded yet.

Agent activity
57 hits · last 30 days
node
56
OpenAI (training)
1
Resources
mmx-cli — npm install mmx-cli · libregistry