Seedance MCP
Click on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@Seedance MCP Generate a video of a sunset over mountains"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
Seedance MCP
火山方舟 Seedance 2.0 视频生成 MCP Server,支持 Claude Code 和 Codex。
项目真实测试经验、故障判断和 Prompt 约定见 PROJECT_KNOWLEDGE.md。
工具列表
工具 | 功能 |
| 创建视频生成任务 |
| 查询任务状态 |
| 轮询等待任务完成或超时 |
| 下载生成视频到本地 |
| 一步创建 + 等待完成 |
Related MCP server: PixVerse MCP
API 格式
通过 SEEDANCE_API_FORMAT 支持两种 API 格式:
格式 | 适用场景 | 创建路径 | 请求体 | 成功状态 |
| tokease.cn 等 OpenAI 兼容代理 |
|
|
|
| 火山方舟官方 API |
|
|
|
未设置 SEEDANCE_API_FORMAT 时,根据 SEEDANCE_BASE_URL 自动推断(含 tokease → openai,否则 → volcengine)。
环境变量
变量 | 必填 | 默认值 | 说明 |
| 是 | — | API Key |
| 否 |
| API 基础 URL |
| 否 |
| 模型 ID |
| 否 | 自动推断 |
|
| 否 |
| httpx 是否读取系统代理/证书环境变量 |
| 否 |
| HTTP 请求超时(秒) |
| 否 |
| 视频下载目录(建议使用绝对路径) |
| 否 |
| 轮询间隔(秒) |
| 否 |
| 最大等待超时(秒) |
⚠️ 下载目录建议:
SEEDANCE_DOWNLOAD_DIR为相对路径时,产物位置取决于 MCP 宿主的当前工作目录,不同宿主可能下载到不同位置。建议在配置中显式指定绝对路径,例如"SEEDANCE_DOWNLOAD_DIR": "D:/Neo/Neo/seedance-mcp/outputs"。
安装
cd D:/Neo/Neo/seedance-mcp
pip install -e ".[dev]"配置
Claude Code(推荐:绝对 Python 路径)
{
"mcpServers": {
"seedance": {
"command": "C:/Users/13056/AppData/Local/Programs/Python/Python314/python.exe",
"args": ["-m", "seedance_mcp"],
"cwd": "D:/Neo/Neo/seedance-mcp",
"env": {
"SEEDANCE_API_KEY": "YOUR_API_KEY",
"SEEDANCE_BASE_URL": "https://www.tokease.cn",
"SEEDANCE_MODEL": "Seedance 2.0/uP",
"SEEDANCE_API_FORMAT": "openai",
"SEEDANCE_TRUST_ENV": "false",
"SEEDANCE_DOWNLOAD_DIR": "D:/Neo/Neo/seedance-mcp/outputs"
}
}
}
}Codex(TOML 配置)
添加到 ~/.codex/config.toml:
[mcp_servers.seedance]
command = "C:/Users/13056/AppData/Local/Programs/Python/Python314/python.exe"
args = ["-m", "seedance_mcp"]
cwd = "D:/Neo/Neo/seedance-mcp"
[mcp_servers.seedance.env]
SEEDANCE_API_KEY = "YOUR_API_KEY"
SEEDANCE_BASE_URL = "https://www.tokease.cn"
SEEDANCE_MODEL = "Seedance 2.0/uP"
SEEDANCE_API_FORMAT = "openai"
SEEDANCE_TRUST_ENV = "false"
SEEDANCE_DOWNLOAD_DIR = "D:/Neo/Neo/seedance-mcp/outputs"火山方舟官方 API
切换 SEEDANCE_API_FORMAT 和 SEEDANCE_BASE_URL:
{
"SEEDANCE_BASE_URL": "https://ark.cn-beijing.volces.com/api/v3",
"SEEDANCE_MODEL": "doubao-seedance-2-0-260128",
"SEEDANCE_API_FORMAT": "volcengine"
}验证状态
能力 | 状态 |
文生视频(tokease + openai 格式) | ✅ 已通过真实 API 验证 |
文生视频(火山官方 volcengine 格式) | ⏳ 待验证(需要官方 key) |
图生视频(openai 格式) | ✅ 已通过真实 API 验证(task |
图生视频(volcengine 格式) | ⏳ 待验证 |
⚠️ 图生视频超时提示:图生视频生成耗时约 130-150 秒,可能超过 MCP 宿主默认工具调用超时。调用
seedance_create_and_wait时建议显式传timeout_seconds=180或更高,并确认宿主自身 tool timeout 足够长。代码层面SEEDANCE_WAIT_TIMEOUT默认 600 秒,不存在代码默认 120 秒的问题。
图生视频可选冒烟测试
默认不运行图生视频真实测试,避免消耗额度。需要时可手动触发:
Linux / macOS:
SEEDANCE_RUN_IMAGE_API=1 \
SEEDANCE_TEST_IMAGE_URL=https://upload.wikimedia.org/wikipedia/commons/thumb/4/47/PNG_transparency_demonstration_1.png/280px-PNG_transparency_demonstration_1.png \
SEEDANCE_API_KEY=sk-xxx \
SEEDANCE_RUN_REAL_API=1 \
python test_official_api.pyWindows PowerShell:
$env:SEEDANCE_API_KEY = "sk-xxx"
$env:SEEDANCE_RUN_REAL_API = "1"
$env:SEEDANCE_RUN_IMAGE_API = "1"
$env:SEEDANCE_TEST_IMAGE_URL = "https://upload.wikimedia.org/wikipedia/commons/thumb/4/47/PNG_transparency_demonstration_1.png/280px-PNG_transparency_demonstration_1.png"
python test_official_api.py参数 | 说明 |
| 设为 |
| 测试用图片 URL |
输出文件名 |
|
推荐超时 |
|
安全
API Key 不完整打印(遮蔽为
abcd...wxyz)API Key 不写入 README 示例(使用
YOUR_API_KEY占位)API Key 不出现在测试快照中
__repr__()遮蔽 key下载文件名经过清洗:阻止路径穿越,强制
.mp4扩展名.mcp.json在.gitignore中,不会提交真实 key
故障排除
错误 | 原因 | 修复方式 |
| API Key 无效或缺失 | 检查 env 配置中的 |
| 请求频率超限 | 等待后重试,或减少并发请求 |
| 网络或 API 响应慢 | 增大 |
stdout 污染 | 服务端日志泄露到 stdout | 所有日志走 stderr;如 MCP 异常,检查是否有 |
| API Key 无模型权限 | 在火山方舟控制台启用 Seedance 模型 |
| API 响应格式变更 | 检查响应中的 |
| uv 缓存目录不可写 | 改用绝对 Python 路径配置 |
| SSL/代理不匹配或 base URL 错误 | 设置 |
| terminal_states 过期 | 确保 |
视频下载到意外目录 |
| 配置中显式指定绝对路径 |
运行测试
cd D:/Neo/Neo/seedance-mcp
pip install -e ".[dev]"
pytest tests/ -vMCP 验证
使用 MCP Inspector 验证(推荐绝对 Python 路径):
npx @modelcontextprotocol/inspector C:/Users/13056/AppData/Local/Programs/Python/Python314/python.exe -m seedance_mcp预期:服务启动,tools/list 返回 5 个工具,mock 调用返回清晰错误而不崩溃。
项目结构
D:\Neo\Neo\seedance-mcp\
pyproject.toml
README.md
.gitignore
.mcp.json # 本地专用,已 gitignore
.mcp.example.json # 可安全提交
src/seedance_mcp/
__init__.py
__main__.py # python -m seedance_mcp
server.py # FastMCP + 工具注册
config.py # 环境变量读取 + api_format 推断
client.py # HTTP 客户端 + 响应解析(双格式)
tools.py # 业务逻辑 + 终态处理
safe_path.py # 下载路径清洗
tests/
test_config.py
test_client_payload.py
test_response_parsing.py
test_safe_path.py
test_tools_schema.py # 含 completed 状态回归测试
test_mcp_smoke.py
test_download.py
test_http_requests.py
test_api_format.py # 双格式测试
test_wrapper_calls.py冒烟测试产物
真实 API 冒烟测试会生成 outputs/test_smoke.mp4(文生视频)和 outputs/test_image_to_video.mp4(图生视频)。outputs/ 目录已在 .gitignore 中,可手动删除整个 outputs 目录,或用命令:
Remove-Item -LiteralPath "outputs" -Recurse -ForceAvailable Tools
6 toolsseedance_create_and_waitA
Create a Seedance video task and wait for completion in one call.
Args: prompt: Text description of the video to generate. Required. model: Model ID override. ratio: Aspect ratio, e.g. "16:9". resolution: Resolution, e.g. "720p". duration: Video duration in seconds. camera_fixed: Whether to fix camera movement. image_url: Optional reference image URL. callback_url: Optional callback URL. extra_args: Additional request parameters. interval_seconds: Polling interval (default: SEEDANCE_POLL_INTERVAL). timeout_seconds: Max wait time (default: SEEDANCE_WAIT_TIMEOUT).
Returns: JSON with ok, task_id, status, video_url, error, and raw responses.
Inputs: prompt (required), model, ratio, duration, +7 more. Returns: result
seedance_create_videoA
Create a Seedance 2.0 video generation task.
Args: prompt: Text description of the video to generate. Required. model: Model ID override (default: SEEDANCE_MODEL env var). ratio: Aspect ratio, e.g. "16:9". resolution: Resolution, e.g. "720p". duration: Video duration in seconds. camera_fixed: Whether to fix camera movement. image_url: Optional reference image URL. callback_url: Optional callback URL for task completion. extra_args: Additional parameters merged into request body.
Returns: JSON with ok, task_id and raw API response.
Inputs: prompt (required), model, ratio, duration, +5 more. Returns: result
seedance_download_videoA
Download a generated video to local disk.
Args: video_url: URL of the video to download. filename: Optional filename (sanitized, .mp4 enforced).
Returns: JSON with ok, local file path and source URL.
Inputs: video_url (required), filename. Returns: result
seedance_get_configA
Return runtime Seedance MCP config diagnostics (API key masked).
Use this tool to verify which config the running MCP process is using. Returns base_url, model, api_format, download directories, cwd, and masked api_key.
Returns: JSON with runtime config fields. API key is always masked.
Inputs: no named parameters. Returns: result
seedance_get_taskB
Query a Seedance video generation task status.
Args: task_id: The task ID returned by create_video.
Returns: JSON with ok, task_id, status, video_url, error, and raw response.
Inputs: task_id (required). Returns: result
seedance_wait_taskA
Poll a Seedance task until completion or timeout.
Args: task_id: The task ID to poll. interval_seconds: Polling interval in seconds (default: SEEDANCE_POLL_INTERVAL). timeout_seconds: Maximum wait time in seconds (default: SEEDANCE_WAIT_TIMEOUT).
Returns: JSON with ok, task_id, status, video_url, error, and raw response.
Inputs: task_id (required), timeout_seconds, interval_seconds. Returns: result
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
TDQS
Scored across 6 tools
Each tool has a distinct purpose: creating videos (two variants for combined vs. separate steps), downloading, querying status, waiting for completion, and retrieving configuration. No overlap.
All tools follow a consistent 'seedance_verb_noun' pattern (e.g., seedance_create_video, seedance_download_video), making predictions easy.
6 tools cover the essential workflow for a video generation service without being excessive or insufficient.
Covers the main create-poll-download cycle and config diagnostics. Missing a cancel or list operation, but the core lifecycle is well-supported.
Maintenance
Related MCP Connectors
Generate images and videos with Seedance, Veo, Wan, Grok, GPT-Image and Nano Banana via one MCP.
1AI video generation MCP server for Kling, MiniMax, Luma & Hunyuan with prompt blueprints.
Plan, compare, price, generate, and recover AI video from compatible MCP clients.
AI image, video, voice and music generation over MCP, routed to Veo 3.1, Seedance 2.5 and more.
Related MCP Servers
- AlicenseAqualityDmaintenanceExposes Volcengine ARK Seedance 2.0 video generation capabilities via MCP tools, enabling text-to-video, image-to-video, and multimodal reference generation locally.39MIT

PixVerse MCPofficial
AlicenseNot gradedqualityDmaintenanceEnables video generation from text, images, and more through MCP-compatible apps like Claude and Cursor.55MIT- FlicenseAqualityDmaintenanceProvides a audio/video creation toolbox via MCP protocol, enabling natural language-based video editing tasks such as image-to-video, video merging, subtitle extraction, and more.93-
- FlicenseAqualityBmaintenanceEnables AI agents to generate videos from text prompts, monitor job status, retrieve completed videos, and cancel ongoing generation tasks through stdio-based MCP tools.4-