MuAPI Claude Code MCP Server
# MuAPI – Claude Code Plugin
A Claude Code plugin that gives Claude the power to generate images, create videos, edit visuals, and more — all powered by [MuAPI](https://muapi.ai).
Simply install the plugin and start asking Claude to generate media for you.
## Related Projects
- [MuAPI](https://muapi.ai) — Unified API for image, video, and audio generation across hundreds of AI models. Install [agent skills](https://muapi.ai/docs/agent-skills), connect through [MCP](https://muapi.ai/docs/mcp), or create [access keys](https://muapi.ai/access-keys).
- [muapi-cli](https://github.com/SamurAIGPT/muapi-cli) — Run the same generation workflows from a terminal or MCP client.
## ✨ What It Can Do
| Tool | Description |
|------|-------------|
| `generate_image` | Generate images from text prompts |
| `generate_video` | Generate videos from text prompts |
| `edit_image` | Edit an existing image with instructions |
| `image_to_video` | Convert a still image into a video |
| `upload_file` | Upload files to MuAPI for processing |
| `list_models` | Browse available model categories |
| `model_details` | Get details about a specific model |
| `get_prediction` | Track the status of an async prediction |
| `account_balance` | Check your MuAPI account balance |
## 🚀 Installation
### Install as a Claude Code Plugin
```bash
claude plugin add muapi
```
Or install directly from GitHub:
```bash
claude plugin add https://github.com/SamurAIGPT/muapi-claude-code.git
```
### Configure Your API Key
Set your MuAPI API key:
```bash
claude config set plugins.muapi.env.MUAPI_API_KEY your_api_key_here
```
Get your API key from [muapi.ai](https://muapi.ai/access-keys).
## 💡 Usage
Once installed, just ask Claude naturally:
**Image Generation**
```
Generate an image of a futuristic city at sunset
```
**Video Generation**
```
Generate a cinematic drone shot over mountains
```
**Image Editing**
```
Edit this image to add a rainbow in the sky
```
**Image to Video**
```
Convert this image into a slow zoom-in video
```
## 🔧 Slash Commands
After installing, you can invoke skills directly:
| Command | What it does |
|---------|-------------|
| `/muapi:generate-image <prompt>` | Generate an image from a text prompt |
| `/muapi:generate-video <prompt>` | Generate a video from a text prompt |
| `/muapi:edit-image <instructions>` | Edit an existing image |
| `/muapi:image-to-video <image url>` | Animate a still image into a video |
| `/muapi:media-help` | Explore available models and get recommendations |
## 🛠 Development
If you want to run the plugin locally for development:
```bash
git clone https://github.com/SamurAIGPT/muapi-claude-code.git
cd muapi-claude-code
npm install
```
Create a `.env` file:
```env
MUAPI_API_KEY=your_api_key_here
```
Run the MCP server directly:
```bash
node src/index.js
```
## 📁 Project Structure
```
muapi-claude-code/
├── .claude-plugin/
│ └── plugin.json # Claude Code plugin manifest
├── src/
│ ├── index.js # MCP server entry point
│ └── tools/
│ ├── generateImage.js # Image generation
│ ├── generateVideo.js # Video generation
│ ├── editImage.js # Image editing
│ ├── imageToVideo.js # Image-to-video conversion
│ ├── uploadFile.js # File upload
│ ├── listModels.js # Model listing
│ ├── modelDetails.js # Model details
│ ├── getPrediction.js # Prediction tracking
│ └── accountBalance.js # Account balance
├── .mcp.json # MCP server config
├── package.json
└── .env # API key (not committed)
```
## 📄 License
ISC
TDQS
Scored across 9 tools
Each tool targets a distinct resource and action. While generate_video and image_to_video both produce videos, one is a general generation and the other explicitly converts an image, making them clearly separable. get_prediction, account_balance, list_models, model_details, upload_file, and edit_image each serve a unique purpose.
Most tools follow a verb_noun pattern (generate_image, get_prediction, list_models, edit_image, upload_file). However, account_balance and model_details are noun phrases without a verb, and image_to_video uses a noun_to_noun structure, which are minor deviations from the dominant convention.
The server has 9 tools, which is well within the ideal 3-15 range for a domain-specific MCP server. Each tool covers a necessary aspect of MuAPI's image/video generation workflow without being redundant or excessive.
The tools cover core workflows: account access, model exploration, file upload, image generation and editing, video generation and conversion, and result retrieval. Minor gaps exist, such as no listing of past predictions or cancellation of in-progress tasks, but these are not critical for the server's primary purpose.