mirror of
https://github.com/MiniMax-AI/cli.git
synced 2026-09-18 08:48:06 +08:00
1.8 KiB
1.8 KiB
mmx CLI Design
Command Grammar
All commands follow resource + verb:
mmx <resource> <verb> [flags]
Command Tree
mmx
├── auth
│ ├── login Authenticate via OAuth or API key
│ ├── status Show current authentication state
│ ├── refresh Manually refresh OAuth token
│ └── logout Revoke tokens and clear stored credentials
├── text
│ └── chat Send a chat completion (M3)
├── speech
│ └── synthesize Synchronous TTS, ≤10k chars
├── image
│ └── generate Generate images (image-01)
├── video
│ ├── generate Create a video generation task
│ ├── task
│ │ └── get Query video task status
│ └── download Download a completed video by file ID
├── quota
│ └── show Display Token Plan usage and remaining quotas
└── config
├── show Display current configuration
└── set Set a config value
Exit Codes
| Code | Meaning |
|---|---|
| 0 | Success |
| 1 | General / server error |
| 2 | Usage error (bad flags) |
| 3 | Authentication error |
| 4 | Rate limit or quota exceeded |
| 5 | Timeout |
| 10 | Content sensitivity filter |
Authentication
Credential resolution order:
--api-keyflag$MINIMAX_API_KEYenv var~/.mmx/credentials.json(OAuth)api_keyin~/.mmx/config.yaml
Configuration
Config precedence: flag > env var > config file > default.
Config file: ~/.mmx/config.yaml