> ## Documentation Index
> Fetch the complete documentation index at: https://docs.xhuoapi.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# Seedream MCP Integration Guide

> seedream MCP 服务器集成

[MCP (Model Context Protocol)](https://modelcontextprotocol.io) is a model context protocol launched by Anthropic that allows AI models (such as Claude, GPT, etc.) to call external tools through a standardized interface. With the Seedream MCP Server provided by XHuoAPI, you can directly use ByteDance Seedream to generate and edit AI images in AI clients like Claude Desktop, VS Code, Cursor, and more.

## Feature Overview

Seedream MCP Server offers the following core features:

* **Text-to-Image Generation** — Generate high-quality images from text prompts (supports both Chinese and English prompts)
* **Image Editing** — Modify existing images’ style, background, attributes, etc.
* **Virtual Try-On** — Virtually wear clothes on person photos
* **Multi-Model Support** — Supports Seedream v4.5, v4.0, v3.0 T2I, SeedEdit v3.0 I2I, and other models
* **Multiple Resolutions** — Supports 1K, 2K, 4K, and adaptive resolutions
* **Seed Control** — Achieve reproducible generation results via the seed parameter
* **Task Query** — Monitor generation progress and retrieve results

## Prerequisites

Before use, you need to obtain an XHuoAPI API Token:

1. Register or log in to the [XHuoAPI Platform](https://api.xhuoapi.ai)
2. Go to the [Seedream Images API](https://api.xhuoapi.ai/documents/seedream-images) page
3. Click "Acquire" to get your API Token (first-time applicants receive free quota)

## Installation and Configuration

### Method 1: pip Installation (Recommended)

```bash theme={null}
pip install mcp-seedream-pro
```

### Method 2: Source Installation

```bash theme={null}
git clone https://github.com/XHuoAPI/SeedreamMCP.git
cd SeedreamMCP
pip install -e .
```

After installation, you can start the service using the `mcp-seedream-pro` command.

## Usage in Claude Desktop

Edit the Claude Desktop configuration file:

* **macOS**: `~/Library/Application Support/Claude/claude_desktop_config.json`
* **Windows**: `%APPDATA%\Claude\claude_desktop_config.json`

Add the following configuration:

```json theme={null}
{
  "mcpServers": {
    "seedream": {
      "command": "mcp-seedream-pro",
      "env": {
        "XHuoAPI_API_TOKEN": "your API Token"
      }
    }
  }
}
```

If using `uvx` (no need to pre-install packages):

```json theme={null}
{
  "mcpServers": {
    "seedream": {
      "command": "uvx",
      "args": ["mcp-seedream-pro"],
      "env": {
        "XHuoAPI_API_TOKEN": "your API Token"
      }
    }
  }
}
```

Save the configuration and restart Claude Desktop to use Seedream-related tools in conversations.

## Usage in VS Code / Cursor

Create `.vscode/mcp.json` in the project root:

```json theme={null}
{
  "servers": {
    "seedream": {
      "command": "mcp-seedream-pro",
      "env": {
        "XHuoAPI_API_TOKEN": "your API Token"
      }
    }
  }
}
```

Or use `uvx`:

```json theme={null}
{
  "servers": {
    "seedream": {
      "command": "uvx",
      "args": ["mcp-seedream-pro"],
      "env": {
        "XHuoAPI_API_TOKEN": "your API Token"
      }
    }
  }
}
```

## Available Tools

| Tool Name                  | Description                                       |
| -------------------------- | ------------------------------------------------- |
| `seedream_generate_image`  | Generate images from text prompts                 |
| `seedream_edit_image`      | Edit or modify existing images                    |
| `seedream_get_task`        | Query the status of a single task                 |
| `seedream_get_tasks_batch` | Batch query task statuses                         |
| `seedream_list_models`     | List all available models and their capabilities  |
| `seedream_list_sizes`      | List available image sizes and resolution options |

## Usage Examples

After configuration, you can directly invoke these features in AI clients using natural language, for example:

* "Help me generate a landscape painting in ink wash style using Seedream"
* "Change the background of this photo to a starry sky"
* "Generate a 4K high-definition portrait using Seedream v4.5"
* "Virtually try this clothing on the person in this photo"

## More Information

* GitHub Repository: [XHuoAPI/SeedreamMCP](https://github.com/XHuoAPI/SeedreamMCP)
* PyPI Package: [mcp-seedream-pro](https://pypi.org/project/mcp-seedream-pro/)
* API Documentation: [Seedream Image Generation API](https://api.xhuoapi.ai/documents/seedream)
