种子MCP
](https://pypi.org/project/mcp-seedance/) ](https://pypi.org/project/mcp-seedance/)   
A. 模型上下文协议(MCP) 用于AI视频生成的服务器 字节跳动种子 穿过 AceDataCloud API.
直接从Claude、VS Code或任何兼容MCP的客户端生成AI视频。
特性
- 文本转视频 -根据文本提示创建AI生成的视频
- 图像转视频 -使用第一帧、最后一帧和参考图像控件为图像设置动画
- 多种型号 -支持Seedance 1.5 Pro、1.0 Pro、1.0 Pro-Fast、1.0 Lite T2V/I2V
- 多分辨率 -480p、720p(默认)和1080p输出
- 灵活的纵横比 -16:9、9:16、1:1、4:3、3:4、21:9和自适应
- 音频生成 -为视频生成同步音频(1.5 Pro)
- 服务级别 -默认(优先级)和Flex(经济高效)处理
- 任务跟踪 -监控生成进度并检索结果
工具参考
| 工具 | 说明 |
|---|---|
seedance_generate_video | 使用ByteDance Seedance从文本提示生成AI视频。 |
seedance_generate_video_from_image | 使用ByteDance Seedance的参考图像生成AI视频。 |
seedance_get_task | 查询视频生成任务的状态和结果。 |
seedance_get_tasks_batch | 一次查询多个视频生成任务。 |
seedance_list_models | 列出所有可用的Seedance型号及其功能和定价。 |
seedance_list_resolutions | 列出Seedance的所有可用分辨率和纵横比。 |
seedance_list_actions | 列出所有可用的Seedance API操作和相应的工具。 |
快速开始
1.获取您的API代币
- 注册地址: AceDataCloud平台
- 去 API文档页
- 点击 “收购” 获取您的API令牌
- 复制令牌以在下面使用
2.使用托管服务器(推荐)
AceDataCloud托管托管MCP服务器-- 无需本地安装.
端点: https://seedance.mcp.acedata.cloud/mcp
所有请求都需要一个Bearer令牌。使用步骤1中的API令牌。
Claude.ai
直接连接 Claude.ai 使用OAuth-- 不需要API令牌:
- 转到Claude.ai 设置→ 集成→ 添加更多
- 输入服务器URL:
https://seedance.mcp.acedata.cloud/mcp - 完成OAuth登录流程
- 开始在对话中使用工具
克劳德桌面版
添加到您的配置(~/Library/Application Support/Claude/claude_desktop_config.json 在macOS上):
{
"mcpServers": {
"seedance": {
"type": "streamable-http",
"url": "https://seedance.mcp.acedata.cloud/mcp",
"headers": {
"Authorization": "Bearer YOUR_API_TOKEN"
}
}
}
}光标/风帆
添加到MCP配置(.cursor/mcp.json 或 .windsurf/mcp.json):
{
"mcpServers": {
"seedance": {
"type": "streamable-http",
"url": "https://seedance.mcp.acedata.cloud/mcp",
"headers": {
"Authorization": "Bearer YOUR_API_TOKEN"
}
}
}
}VS代码(副本)
添加到您的VS代码MCP配置中(.vscode/mcp.json):
{
"servers": {
"seedance": {
"type": "streamable-http",
"url": "https://seedance.mcp.acedata.cloud/mcp",
"headers": {
"Authorization": "Bearer YOUR_API_TOKEN"
}
}
}
}或安装 Ace数据云MCP扩展 对于VS Code,它通过一键设置捆绑了所有15个MCP服务器。
JetBrains 集成开发环境
- 首选 设置→ 工具→ AI助手→ 模型上下文协议(MCP)
- 点击 添加 → 超文本传输协议
- 粘贴:
{
"mcpServers": {
"seedance": {
"url": "https://seedance.mcp.acedata.cloud/mcp",
"headers": {
"Authorization": "Bearer YOUR_API_TOKEN"
}
}
}
}克劳德代码
Claude Code原生支持MCP服务器:
claude mcp add seedance --transport http https://seedance.mcp.acedata.cloud/mcp \
-h "Authorization: Bearer YOUR_API_TOKEN"或添加到您的项目 .mcp.json:
{
"mcpServers": {
"seedance": {
"type": "streamable-http",
"url": "https://seedance.mcp.acedata.cloud/mcp",
"headers": {
"Authorization": "Bearer YOUR_API_TOKEN"
}
}
}
}克莱恩
添加到Cline的MCP设置(.cline/mcp_settings.json):
{
"mcpServers": {
"seedance": {
"type": "streamable-http",
"url": "https://seedance.mcp.acedata.cloud/mcp",
"headers": {
"Authorization": "Bearer YOUR_API_TOKEN"
}
}
}
}亚马逊Q开发者
添加到MCP配置中:
{
"mcpServers": {
"seedance": {
"type": "streamable-http",
"url": "https://seedance.mcp.acedata.cloud/mcp",
"headers": {
"Authorization": "Bearer YOUR_API_TOKEN"
}
}
}
}Roo代码
添加到Roo Code MCP设置:
{
"mcpServers": {
"seedance": {
"type": "streamable-http",
"url": "https://seedance.mcp.acedata.cloud/mcp",
"headers": {
"Authorization": "Bearer YOUR_API_TOKEN"
}
}
}
}Continue.dev
添加 .continue/config.yaml:
mcpServers:
- name: seedance
type: streamable-http
url: https://seedance.mcp.acedata.cloud/mcp
headers:
Authorization: "Bearer YOUR_API_TOKEN"泽德
添加到Zed的设置中(~/.config/zed/settings.json):
{
"language_models": {
"mcp_servers": {
"seedance": {
"url": "https://seedance.mcp.acedata.cloud/mcp",
"headers": {
"Authorization": "Bearer YOUR_API_TOKEN"
}
}
}
}
}cURL测试
# Health check (no auth required)
curl https://seedance.mcp.acedata.cloud/health
# MCP initialize
curl -X POST https://seedance.mcp.acedata.cloud/mcp \
-H "Content-Type: application/json" \
-H "Accept: application/json" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-d '{"jsonrpc":"2.0","id":1,"method":"initialize","params":{"protocolVersion":"2025-03-26","capabilities":{},"clientInfo":{"name":"test","version":"1.0"}}}'3.或在本地运行(替代方案)
如果您更喜欢在自己的计算机上运行服务器:
# Install from PyPI
pip install mcp-seedance
# or
uvx mcp-seedance
# Set your API token
export ACEDATACLOUD_API_TOKEN="your_token_here"
# Run (stdio mode for Claude Desktop / local clients)
mcp-seedance
# Run (HTTP mode for remote access)
mcp-seedance --transport http --port 8000克劳德桌面(本地)
{
"mcpServers": {
"seedance": {
"command": "uvx",
"args": ["mcp-seedance"],
"env": {
"ACEDATACLOUD_API_TOKEN": "your_token_here"
}
}
}
}Docker(自托管)
docker pull ghcr.io/acedatacloud/mcp-seedance:latest
docker run -p 8000:8000 ghcr.io/acedatacloud/mcp-seedance:latest客户端使用自己的Bearer令牌进行连接——服务器从每个请求中提取令牌 Authorization 头球
可用工具
视频生成
| 工具 | 说明 |
|---|---|
seedance_generate_video | 从文本提示生成视频 |
seedance_generate_video_from_image | 使用参考/开始/结束图像生成视频 |
任务
| 工具 | 说明 |
|---|---|
seedance_get_task | 查询单个任务状态 |
seedance_get_tasks_batch | 一次查询多个任务 |
信息
| 工具 | 说明 |
|---|---|
seedance_list_models | 列出可用的Seedance型号 |
seedance_list_resolutions | 列出可用的输出分辨率 |
seedance_list_actions | 列出可用的API操作 |
使用示例
从Prompt生成视频
User: Create a video of a cat playing with a ball of yarn
Claude: I'll generate a video for you.
[Calls seedance_generate_video with prompt="A cute cat playfully batting a ball of yarn"]为图像制作动画
User: Turn this image into a video: https://example.com/landscape.jpg
Claude: I'll create a video from your image.
[Calls seedance_generate_video_from_image with first_frame_url and appropriate prompt]使用音频生成
User: Create a video of rain falling with sound
Claude: I'll generate a video with synchronized audio.
[Calls seedance_generate_video with prompt="Rain falling on a quiet street" and generate_audio=True, model="doubao-seedance-1-5-pro-251215"]可用型号
| 型号 | 描述 | 功能 |
|---|---|---|
doubao-seedance-2-0-260128 | 2.0 | 最新一代质量 |
doubao-seedance-2-0-fast-260128 | 2.0快 | 最新一代快 |
doubao-seedance-1-5-pro-251215 | 1.5 Pro | 音频生成,T2V,I2V |
doubao-seedance-1-0-pro-250528 | 1.0 Pro(默认) | 高品质T2V、I2V |
doubao-seedance-1-0-pro-fast-251015 | 1.0 Pro Fast | 更快的生成速度 |
doubao-seedance-1-0-lite-t2v-250428 | 1.0 Lite T2V | 轻量级文本到视频 |
doubao-seedance-1-0-lite-i2v-250428 | 1.0 Lite I2V | 轻量级图像到视频 |
可用纵横比
| 纵横比 | 描述 | 用例 |
|---|---|---|
16:9 | 横向(默认) | YouTube、电视、演示文稿 |
9:16 | 肖像 | 品味,instagram转轴 |
1:1 | Square | Instagram帖子 |
4:3 | 传统 | 经典视频格式 |
3:4 | 肖像传统 | 肖像内容 |
21:9 | 超宽 | 电影内容 |
adaptive | 自适应 | 从图像中自动检测 |
配置
环境变量
| 变量 | 描述 | 默认值 |
|---|---|---|
ACEDATACLOUD_API_TOKEN | 来自AceDataCloud的API令牌 | 必需 |
ACEDATACLOUD_API_BASE_URL | API基本URL | https://api.acedata.cloud |
ACEDATACLOUD_OAUTH_CLIENT_ID | OAuth客户端ID(托管模式) | -- |
ACEDATACLOUD_PLATFORM_BASE_URL | 平台基础URL | https://platform.acedata.cloud |
SEEDANCE_DEFAULT_MODEL | 默认型号 | doubao-seedance-1-0-pro-250528 |
SEEDANCE_DEFAULT_RESOLUTION | 默认分辨率 | 720p |
SEEDANCE_DEFAULT_RATIO | 默认纵横比 | 16:9 |
SEEDANCE_DEFAULT_DURATION | 默认持续时间(秒) | 5 |
SEEDANCE_REQUEST_TIMEOUT | 请求超时(秒) | 1800 |
LOG_LEVEL | 日志记录级别 | INFO |
命令行选项
mcp-seedance --help
Options:
--version Show version
--transport Transport mode: stdio (default) or http
--port Port for HTTP transport (default: 8000)发展
设置开发环境
# Clone repository
git clone https://github.com/AceDataCloud/SeedanceMCP.git
cd SeedanceMCP
# Create virtual environment
python -m venv .venv
source .venv/bin/activate # or `.venv\Scripts\activate` on Windows
# Install with dev dependencies
pip install -e ".[dev,test]"运行测试
# Run unit tests
pytest
# Run with coverage
pytest --cov=core --cov=tools
# Run integration tests (requires API token)
pytest tests/test_integration.py -m integration代码质量
# Format code
ruff format .
# Lint code
ruff check .
# Type check
mypy core tools构建和发布
# Install build dependencies
pip install -e ".[release]"
# Build package
python -m build
# Upload to PyPI
twine upload dist/*项目结构
SeedanceMCP/
├── core/ # Core modules
│ ├── __init__.py
│ ├── client.py # HTTP client for Seedance API
│ ├── config.py # Configuration management
│ ├── exceptions.py # Custom exceptions
│ ├── server.py # MCP server initialization
│ ├── types.py # Type definitions
│ └── utils.py # Utility functions
├── tools/ # MCP tool definitions
│ ├── __init__.py
│ ├── video_tools.py # Video generation tools
│ ├── task_tools.py # Task query tools
│ └── info_tools.py # Information tools
├── prompts/ # MCP prompts
│ └── __init__.py # Prompt templates
├── tests/ # Test suite
│ ├── conftest.py
│ ├── test_client.py
│ ├── test_config.py
│ ├── test_integration.py
│ └── test_utils.py
├── deploy/ # Deployment configs
│ └── production/
│ ├── deployment.yaml
│ ├── ingress.yaml
│ └── service.yaml
├── .env.example # Environment template
├── .gitignore
├── CHANGELOG.md
├── Dockerfile # Docker image for HTTP mode
├── docker-compose.yaml # Docker Compose config
├── LICENSE
├── main.py # Entry point
├── pyproject.toml # Project configuration
└── README.mdAPI 参考
此服务器包装 AceDataCloud种子API:
贡献
欢迎投稿!拜托:
- 分叉存储库
- 创建要素分支(
git checkout -b feature/amazing) - 提交您的更改(
git commit -m 'Add amazing feature') - 推到分支(
git push origin feature/amazing) - 打开拉取请求
许可证
MIT许可证-请参阅 许可证 了解详情。
链接
______________________________________________________________________
用爱制作 AceDataCloud
