Integrations
Integrates with Hugging Face for model hosting and distribution, with links to MiniMax AI models on the platform.
Provides integration with WeChat for accessing MiniMax services through the WeChat platform.
MiniMax MCP JS
JavaScript/TypeScript implementation of MiniMax MCP, providing image generation, video generation, text-to-speech, and more.
Documentation
- 中文文档
- Python Version - Official Python implementation of MiniMax MCP
Features
- Text-to-Speech (TTS)
- Image Generation
- Video Generation
- Voice Cloning
- Dynamic configuration (supports both environment variables and request parameters)
- Compatible with MCP platform hosting (ModelScope and other MCP platforms)
Installation
Quick Start
MiniMax MCP JS implements the Model Context Protocol (MCP) specification and can be used as a server to interact with MCP-compatible clients (such as Claude AI).
Quickstart with MCP Client
- Get your API key from MiniMax International Platform.
- Make sure that you already installed Node.js and npm
- Important: API HOST&KEY are different in different region, they must match, otherwise you will receive an
Invalid API key
error.
Region | Global | Mainland |
---|---|---|
MINIMAX_API_KEY | go get from MiniMax Global | go get from MiniMax |
MINIMAX_API_HOST | https://api.minimaxi.chat (note the extra "i") | https://api.minimax.chat |
Using with MCP Clients (Recommended)
Configure your MCP client:
Claude Desktop
Go to Claude > Settings > Developer > Edit Config > claude_desktop_config.json
to include:
Cursor
Go to Cursor → Preferences → Cursor Settings → MCP → Add new global MCP Server
to add the above config.
⚠️ Note: If you encounter a "No tools found" error when using MiniMax MCP JS with Cursor, please update your Cursor to the latest version. For more information, see this discussion thread.
That's it. Your MCP client can now interact with MiniMax through these tools.
For local development:
When developing locally, you can use npm link
to test your changes:
Then configure Claude Desktop or Cursor to use npx as shown above. This will automatically use your linked version.
⚠️ Note: The API key needs to match the host address. Different hosts are used for global and mainland China versions:
- Global Host:
https://api.minimaxi.chat
(note the extra "i") - Mainland China Host:
https://api.minimaxi.chat
Transport Modes
MiniMax MCP JS supports three transport modes:
Feature | stdio (default) | REST | SSE |
---|---|---|---|
Environment | Local only | Local or cloud deployment | Local or cloud deployment |
Communication | Via standard I/O | Via HTTP requests | Via server-sent events |
Use Cases | Local MCP client integration | API services, cross-language calls | Applications requiring server push |
Input Restrictions | Supports local files or URL resources | When deployed in cloud, URL input recommended | When deployed in cloud, URL input recommended |
Configuration
MiniMax-MCP-JS provides multiple flexible configuration methods to adapt to different use cases. The configuration priority from highest to lowest is as follows:
1. Request Parameter Configuration (Highest Priority)
In platform hosting environments (like ModelScope or other MCP platforms), you can provide an independent configuration for each request via the meta.auth
object in the request parameters:
This method enables multi-tenant usage, where each request can use different API keys and configurations.
2. API Configuration
When used as a module in other projects, you can pass configuration through the startMiniMaxMCP
function:
3. Command Line Arguments
- Install the CLI tool globally:
- When used as a CLI tool, you can provide configuration via command line arguments:
4. Environment Variables (Lowest Priority)
The most basic configuration method is through environment variables:
Configuration Priority
When multiple configuration methods are used, the following priority order applies (from highest to lowest):
- Request-level configuration (via
meta.auth
in each API request) - Command line arguments
- Environment variables
- Configuration file
- Default values
This prioritization ensures flexibility across different deployment scenarios while maintaining per-request configuration capabilities for multi-tenant environments.
Configuration Parameters
Parameter | Description | Default Value |
---|---|---|
apiKey | MiniMax API Key | None (Required) |
apiHost | MiniMax API Host | Global Host - https://api.minimaxi.chat, Mainland Host - https://api.minimax.chat |
basePath | Base path for output files | User's desktop |
resourceMode | Resource handling mode, 'url' or 'local' | url |
⚠️ Note: The API key needs to match the host address. Different hosts are used for global and mainland China versions:
- Global Host:
https://api.minimaxi.chat
(note the extra "i") - Mainland China Host:
https://api.minimax.chat
Example usage
⚠️ Warning: Using these tools may incur costs.
1. broadcast a segment of the evening news
2. clone a voice
3. generate a video
4. generate images
Available Tools
Text to Audio
Convert text to speech audio file.
Tool Name: text_to_audio
Parameters:
text
: Text to convert (required)model
: Model version, options are 'speech-02-hd', 'speech-02-turbo', 'speech-01-hd', 'speech-01-turbo', 'speech-01-240228', 'speech-01-turbo-240228', default is 'speech-02-hd'voiceId
: Voice ID, default is 'male-qn-qingse'speed
: Speech speed, range 0.5-2.0, default is 1.0vol
: Volume, range 0.1-10.0, default is 1.0pitch
: Pitch, range -12 to 12, default is 0emotion
: Emotion, options are 'happy', 'sad', 'angry', 'fearful', 'disgusted', 'surprised', 'neutral', default is 'happy'. Note: This parameter only works with 'speech-02-hd', 'speech-02-turbo', 'speech-01-turbo', 'speech-01-hd' modelsformat
: Audio format, options are 'mp3', 'pcm', 'flac', 'wav', default is 'mp3'sampleRate
: Sample rate (Hz), options are 8000, 16000, 22050, 24000, 32000, 44100, default is 32000bitrate
: Bitrate (bps), options are 64000, 96000, 128000, 160000, 192000, 224000, 256000, 320000, default is 128000channel
: Audio channels, options are 1 or 2, default is 1languageBoost
: Language boost, default is 'auto'latexRead
: Enable LaTeX formula readingpronunciationDict
: Pronunciation dictionarystream
: Enable streaming outputsubtitleEnable
: Enable subtitle generationoutputDirectory
: Directory to save the output file (optional)outputFile
: Path to save the output file (optional, auto-generated if not provided)
Play Audio
Play an audio file. Supports WAV and MP3 formats. Does not support video.
Tool Name: play_audio
Parameters:
inputFilePath
: Path to the audio file to play (required)isUrl
: Whether the audio file is a URL, default is false
Voice Clone
Clone a voice from an audio file.
Tool Name: voice_clone
Parameters:
audioFile
: Path to audio file (required)voiceId
: Voice ID (required)text
: Text for demo audio (optional)outputDirectory
: Directory to save the output file (optional)
Text to Image
Generate images based on text prompts.
Tool Name: text_to_image
Parameters:
prompt
: Image description (required)model
: Model version, default is 'image-01'aspectRatio
: Aspect ratio, default is '1:1', options are '1:1', '16:9','4:3', '3:2', '2:3', '3:4', '9:16', '21:9'n
: Number of images to generate, range 1-9, default is 1promptOptimizer
: Whether to optimize the prompt, default is truesubjectReference
: Path to local image file or public URL for character reference (optional)outputDirectory
: Directory to save the output file (optional)outputFile
: Path to save the output file (optional, auto-generated if not provided)asyncMode
: Whether to use async mode. Defaults to False. If True, the video generation task will be submitted asynchronously and the response will return a task_id. Should usequery_video_generation
tool to check the status of the task and get the result. (optional)
Generate Video
Generate videos based on text prompts.
Tool Name: generate_video
Parameters:
prompt
: Video description (required)model
: Model version, options are 'T2V-01', 'T2V-01-Director', 'I2V-01', 'I2V-01-Director', 'I2V-01-live', 'S2V-01', default is 'T2V-01'firstFrameImage
: Path to first frame image (optional)outputDirectory
: Directory to save the output file (optional)outputFile
: Path to save the output file (optional, auto-generated if not provided)asyncMode
: Whether to use async mode. Defaults to False. If True, the video generation task will be submitted asynchronously and the response will return a task_id. Should usequery_video_generation
tool to check the status of the task and get the result. (optional)
Query Video Generation Status
Query the status of a video generation task.
Tool Name: query_video_generation
Parameters:
taskId
: The Task ID to query. Should be the task_id returned bygenerate_video
tool ifasync_mode
is True. (required)outputDirectory
: Directory to save the output file (optional)
FAQ
1. How to use generate_video
in async-mode
Define completion rules before starting: Alternatively, these rules can be configured in your IDE settings (e.g., Cursor):
Development
Setup
Build
Run
License
MIT
You must be authenticated.
hybrid server
The server is able to function both locally and remotely, depending on the configuration or use case.
JavaScript implementation of MiniMax MCP that enables interaction with MiniMax AI services for image generation, video generation, text-to-speech, and voice cloning through MCP-compatible clients.
Related MCP Servers
- AsecurityAlicenseAqualityA MCP server that enables Claude and other MCP-compatible assistants to generate images from text prompts using Together AI's image generation models.Last updated -12TypeScriptMIT License
- AsecurityAlicenseAqualityAn MCP Server that integrates with Stability AI's API to provide high-quality image generation, editing, and manipulation capabilities including background removal, outpainting, search-and-replace, and upscaling.Last updated -133555TypeScriptMIT License
- AsecurityAlicenseAqualityAn MCP server implementation that integrates with Minimax API to provide AI-powered image generation and text-to-speech functionality in editors like Windsurf and Cursor.Last updated -21921JavaScriptMIT License
ElevenLabs MCP Serverofficial
AsecurityAlicenseAqualityAn official Model Context Protocol (MCP) server that enables AI clients to interact with ElevenLabs' Text to Speech and audio processing APIs, allowing for speech generation, voice cloning, audio transcription, and other audio-related tasks.Last updated -19633PythonMIT License