# MeiGen AI Design MCP

> An MCP server that lets Claude Code, Cursor, Codex and other AI assistants generate images, videos and ecommerce assets

- Category: Multimodal Generation / Image Generation
- Language: TypeScript
- Licence: MIT
- Repository: https://github.com/jau123/MeiGen-AI-Design-MCP
- Canonical page: https://ai-tldr.dev/tools/meigen-ai-design-mcp/
- Updated: 2026-09-26

## In short

MeiGen AI Design MCP is an open-source Model Context Protocol server that lets an AI assistant create images, videos and ecommerce assets from inside the tool you already work in. It sits in the Image Generation category of the Multimodal Generation tools and is open-source, written in TypeScript and licensed MIT.

## Overview

MeiGen AI Design MCP is an open-source Model Context Protocol server that lets an AI assistant create images, videos and ecommerce assets from inside the tool you already work in. It is written in TypeScript, published on npm as `meigen`, and works in Claude Code, Cursor, Codex, Windsurf, Roo Code, OpenClaw, Hermes Agent and other MCP-compatible hosts. You ask in plain language — for example, for four product display images of a perfume — and the assistant uploads the reference, writes distinct prompts and runs the generations in parallel.

There are two ways to connect. A remote Streamable HTTP endpoint at `https://www.meigen.ai/api/mcp` exposes 14 tools with nothing to install; the local npm server exposes the same 14 plus three local-only tools (prompt enhancement, preferences and ComfyUI workflow management) for 17 in total, and adds automatic preparation of local reference files. The same package also ships a one-shot `gen` command, so shell scripts and CI pipelines can generate images without any MCP host.

For general image generation the local server supports three backends: MeiGen Cloud (hosted models such as GPT Image 2, Nanobanana 2 and Seedream 5.0), any OpenAI-compatible image API you bring your own key for, or a local ComfyUI instance running on your own GPU. Version 2.0 added five guided Skills — background removal, product detail images, marketing posters, AI backgrounds and upscaling — which run only on MeiGen Cloud and require a MeiGen account with purchased credits. Gallery search over a bundled library of 1,446 curated prompts, model listing and prompt enhancement work without an API key.

## What it does

- Remote MCP endpoint (14 tools, OAuth or API key) or local npm server over stdio (17 tools, including ComfyUI workflow management and local prompt enhancement)
- Three image backends on the local server: MeiGen Cloud, any OpenAI-compatible image API (Together AI, Fireworks AI, DeepInfra, SiliconFlow or your own endpoint), and local ComfyUI with auto-detection of KSampler, CLIPTextEncode, EmptyLatentImage and LoadImage nodes
- Five guided ecommerce Skills on MeiGen Cloud: background removal, product detail image sets (1–6 modules), marketing posters, AI backgrounds and upscaling
- Video generation through `generate_video`, with first-frame images plus reference videos and reference audio
- 1,446 bundled curated prompt templates with gallery search and style-aware prompt enhancement
- Claude Code plugin with slash commands (`/meigen:gen`, `/meigen:find`, `/meigen:models`, `/meigen:setup`), prompt-crafter and gallery-researcher sub-agents, and output styles
- Standalone `meigen gen` CLI with model, aspect-ratio, reference-image, `--no-wait` and `--json` flags for scripts and CI
- Recoverable jobs: persist a `requestId` and resume interrupted image, video or Skill runs with `check_generation` / `check_skill` instead of paying for a resubmission

## Getting started

Pick ONE connection per host: the remote endpoint (no install, MeiGen Cloud only) or the local npm server (adds local files, ComfyUI and OpenAI-compatible providers). Gallery search and model listing work without a key; MeiGen Cloud generation and the five Skills need a private API key from meigen.ai and purchased credits. Node.js 22 or newer is recommended for the local server.

1. Remote endpoint in Claude Code

   Add the Streamable HTTP server and sign in with OAuth. If automatic login is not available for your client, use a private `Authorization: Bearer <MeiGen API key>` header instead.

```bash
claude mcp add --transport http meigen https://www.meigen.ai/api/mcp
claude mcp login meigen
```

2. Remote endpoint in Codex

   Codex CLI, the IDE extension and the desktop app on the same host share this configuration. For longer Skills, set `tool_timeout_sec = 240` in the entry.

```bash
codex mcp add meigen --url https://www.meigen.ai/api/mcp
codex mcp login meigen
```

3. Or install the Claude Code plugin (local tools)

   The plugin adds the slash commands, agents, output styles and hooks on top of the local npm server. Restart Claude Code afterwards, then run `/meigen:setup` to choose MeiGen Cloud, ComfyUI or an OpenAI-compatible API.

```text
/plugin marketplace add jau123/MeiGen-AI-Design-MCP
/plugin install meigen@meigen-marketplace
```

4. Or configure Cursor, VS Code, Windsurf or Roo Code

   `init` writes the MCP config file in the right format and path for each tool, merging MeiGen in without overwriting your other servers.

```bash
npx -y meigen@2.0.2 init cursor      # Cursor
npx -y meigen@2.0.2 init vscode      # VS Code / GitHub Copilot
npx -y meigen@2.0.2 init windsurf    # Windsurf
npx -y meigen@2.0.2 init roo         # Roo Code
```

5. Any other MCP host

   Add the local server to the host's MCP config, such as `.mcp.json` or `claude_desktop_config.json`.

```json
{
  "mcpServers": {
    "meigen": {
      "command": "npx",
      "args": ["-y", "meigen@2.0.2"],
      "env": {
        "MEIGEN_API_TOKEN": "meigen_sk_..."
      }
    }
  }
}
```

6. Bring your own image API or use ComfyUI

   Instead of MeiGen Cloud, the local server's `generate_image` can call any OpenAI-compatible endpoint, or a ComfyUI server (`comfyuiUrl`, for example `http://localhost:8188`). Settings live in `~/.config/meigen/config.json`; environment variables such as `OPENAI_API_KEY`, `OPENAI_BASE_URL`, `OPENAI_MODEL` and `COMFYUI_URL` take priority. The five Skills still need MeiGen Cloud.

```json
{
  "openaiApiKey": "sk-...",
  "openaiBaseUrl": "https://api.together.xyz/v1",
  "openaiModel": "black-forest-labs/FLUX.1-schnell"
}
```

7. Generate from the shell without an MCP host

   The same package ships a `gen` command. Images are saved to `~/Pictures/meigen/` unless `MEIGEN_OUTPUT_DIR` is set; `meigen gen --help` lists every flag.

```bash
export MEIGEN_API_TOKEN=meigen_sk_...
npx -y meigen@2.0.2 gen --prompt "a calico cat in a sunlit kitchen"
npx -y meigen@2.0.2 gen -p "tech logo" -m midjourney-v8.1 -r 1:1
npx -y meigen@2.0.2 gen -p "product hero shot" --ref ~/Desktop/bottle.jpg
npx -y meigen@2.0.2 gen -p "..." --json | jq -r '.imageUrls[0]'
```

## When to use it

- Produce several creative directions for a product shot in parallel from one chat request inside your coding assistant
- Build ecommerce asset sets — cutouts, product detail images, new backgrounds, upscales and campaign posters — without leaving the editor
- Wire image or first-frame-to-video generation into shell scripts and CI with the standalone `gen` CLI and `--json` output
- Drive your own local ComfyUI workflows, or any OpenAI-compatible image API, from an MCP host instead of a separate UI

## Version history

- 2026-09-26 v2.0.2: Gallery search and inspiration lookups return standard MCP image previews and resource links, completed image and video results add typed resource links, and tools carry side-effect annotations; npm `meigen@2.0.2`.
