wan-video
Compare original and translation side by side
🇺🇸
Original
English🇨🇳
Translation
ChineseWan Video Generation
Wan视频生成
Generate AI videos through AceDataCloud's Wan (Alibaba) API.
Setup: See authentication for token setup.
通过AceDataCloud的阿里Wan API生成AI视频。
设置: 请查看身份验证了解令牌设置。
Quick Start
快速开始
bash
curl -X POST https://api.acedata.cloud/wan/videos \
-H "Authorization: Bearer $ACEDATACLOUD_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{"action": "text2video", "prompt": "a dolphin jumping through ocean waves at golden hour", "model": "wan2.6-t2v"}'Async: See async task polling. Poll viawithPOST /wan/tasks.{"id": "..."}
bash
curl -X POST https://api.acedata.cloud/wan/videos \
-H "Authorization: Bearer $ACEDATACLOUD_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{"action": "text2video", "prompt": "a dolphin jumping through ocean waves at golden hour", "model": "wan2.6-t2v"}'异步处理: 请查看异步任务轮询。通过接口并传入POST /wan/tasks进行轮询。{"id": "..."}
Models
模型
| Model | Type | Best For |
|---|---|---|
| Text-to-Video | Creating video from text description |
| Image-to-Video | Animating a still image into video |
| Reference Video-to-Video | Character extraction and transfer from reference video |
| Image-to-Video (Fast) | Quick image-to-video generation |
| 模型 | 类型 | 适用场景 |
|---|---|---|
| 文本转视频 | 根据文本描述创建视频 |
| 图片转视频 | 将静态图片动效化为视频 |
| 参考视频转视频 | 从参考视频中提取角色并迁移 |
| 图片转视频(快速版) | 快速生成图片转视频内容 |
Workflows
工作流
1. Text-to-Video
1. 文本转视频
json
POST /wan/videos
{
"action": "text2video",
"prompt": "a time-lapse of flowers blooming in a meadow",
"model": "wan2.6-t2v",
"resolution": "720P",
"duration": 5
}json
POST /wan/videos
{
"action": "text2video",
"prompt": "a time-lapse of flowers blooming in a meadow",
"model": "wan2.6-t2v",
"resolution": "720P",
"duration": 5
}2. Image-to-Video
2. 图片转视频
Animate a still image into a video clip.
json
POST /wan/videos
{
"action": "image2video",
"prompt": "gentle wind blows through the scene",
"model": "wan2.6-i2v",
"image_url": "https://example.com/landscape.jpg",
"resolution": "720P",
"duration": 5
}将静态图片动效化为视频片段。
json
POST /wan/videos
{
"action": "image2video",
"prompt": "gentle wind blows through the scene",
"model": "wan2.6-i2v",
"image_url": "https://example.com/landscape.jpg",
"resolution": "720P",
"duration": 5
}3. Image-to-Video (Flash)
3. 图片转视频(快速版)
Faster image-to-video generation with reduced latency.
json
POST /wan/videos
{
"action": "image2video",
"prompt": "camera slowly pans across the landscape",
"model": "wan2.6-i2v-flash",
"image_url": "https://example.com/scene.jpg"
}以更低延迟快速生成图片转视频内容。
json
POST /wan/videos
{
"action": "image2video",
"prompt": "camera slowly pans across the landscape",
"model": "wan2.6-i2v-flash",
"image_url": "https://example.com/scene.jpg"
}4. Reference Video Transfer
4. 参考视频迁移
Extract characters or timbres from a reference video and transfer them into a new generation.
json
POST /wan/videos
{
"action": "text2video",
"prompt": "the character walks through a futuristic city at night",
"model": "wan2.6-r2v",
"reference_video_urls": ["https://example.com/reference.mp4"]
}从参考视频中提取角色或音色,并迁移到新生成的视频中。
json
POST /wan/videos
{
"action": "text2video",
"prompt": "the character walks through a futuristic city at night",
"model": "wan2.6-r2v",
"reference_video_urls": ["https://example.com/reference.mp4"]
}5. Multi-Cut Editing
5. 多镜头剪辑
Generate a video with multiple shots rather than a single continuous take.
json
POST /wan/videos
{
"action": "text2video",
"prompt": "a chef preparing a meal in a busy kitchen",
"model": "wan2.6-t2v",
"shot_type": "multi",
"duration": 10
}生成包含多个镜头而非单一连续镜头的视频。
json
POST /wan/videos
{
"action": "text2video",
"prompt": "a chef preparing a meal in a busy kitchen",
"model": "wan2.6-t2v",
"shot_type": "multi",
"duration": 10
}6. Video with Audio
6. 带音频的视频
Enable audio generation alongside the video.
json
POST /wan/videos
{
"action": "text2video",
"prompt": "ocean waves crashing on a rocky shore",
"model": "wan2.6-t2v",
"audio": true
}生成视频的同时启用音频生成功能。
json
POST /wan/videos
{
"action": "text2video",
"prompt": "ocean waves crashing on a rocky shore",
"model": "wan2.6-t2v",
"audio": true
}Parameters
参数说明
| Parameter | Required | Values | Description |
|---|---|---|---|
| Yes | | Action type |
| Yes | string | Scene description |
| Yes | | Model |
| For image2video | string | Source image URL (required for image-to-video) |
| No | string (max 500 chars) | Content to exclude from generation |
| For r2v | array of strings | Reference videos for character/timbre extraction |
| No | | Continuous shot or multi-cut editing |
| No | boolean | Enable audio in the generated video |
| No | string | Reference audio URL |
| No | | Output resolution (default: 720P) |
| No | string | The size of the generated video |
| No | | Video duration in seconds |
| No | boolean | Enable LLM-based prompt rewriting |
| No | string | Async webhook notification URL |
| 参数 | 是否必填 | 可选值 | 描述 |
|---|---|---|---|
| 是 | | 操作类型 |
| 是 | 字符串 | 场景描述 |
| 是 | | 模型 |
| 图片转视频场景必填 | 字符串 | 源图片URL(图片转视频场景必填) |
| 否 | 字符串(最多500字符) | 生成时需要排除的内容 |
| r2v模型必填 | 字符串数组 | 用于提取角色/音色的参考视频 |
| 否 | | 单一连续镜头或多镜头剪辑 |
| 否 | 布尔值 | 启用生成视频中的音频 |
| 否 | 字符串 | 参考音频URL |
| 否 | | 输出分辨率(默认:720P) |
| 否 | 字符串 | 生成视频的尺寸 |
| 否 | | 视频时长(秒) |
| 否 | 布尔值 | 启用基于LLM的提示词重写 |
| 否 | 字符串 | 异步回调通知URL |
Gotchas
注意事项
- is required for
image_urlandwan2.6-i2vmodelswan2.6-i2v-flash - is used only with
reference_video_urlsfor character/timbre transferwan2.6-r2v - has a maximum length of 500 characters
negative_prompt - Supported durations are 5, 10, or 15 seconds only
- Default resolution is 720P; use 1080P for higher quality at increased cost
- produces multi-cut edits rather than a single continuous shot
shot_type: "multi"
MCP:| Hosted:pip install mcp-wan| See all MCP servershttps://wan.mcp.acedata.cloud/mcp
- 使用和
wan2.6-i2v模型时,wan2.6-i2v-flash为必填项image_url - 仅在使用
reference_video_urls模型进行角色/音色迁移时生效wan2.6-r2v - 的最大长度为500字符
negative_prompt - 仅支持5、10或15秒的视频时长
- 默认分辨率为720P;使用1080P可获得更高画质,但成本会增加
- 将生成多镜头剪辑视频,而非单一连续镜头
shot_type: "multi"
MCP:| 托管地址:pip install mcp-wan| 查看所有MCP服务器https://wan.mcp.acedata.cloud/mcp