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

# Wan 3.0 — 图生视频

> 使用阿里巴巴 Wan 3.0 或 Wan 3.0 Prime，让首帧动起来（可选过渡到尾帧），生成 2–30 秒、带音频的视频。

| | |
| - | - |
| **模型 ID** | `alibaba/wan-3-0-i2v`（Wan 3.0）、`alibaba/wan-3-0-prime-i2v`（Wan 3.0 Prime） |
| **系列** | `wan-3-0`、`wan-3-0-prime` |
| **任务** | `image-to-video` |
| **模态** | 视频 |
| **上游** | Alibaba Wan 3.0 |

> [!NOTE]
>
> 两个模型 ID 接受相同的参数。Prime 端到端生成更快，每秒价格更高。按实际生成的视频秒数计费，
> 详见 [Wan 3.0 快速入门](https://docs.vibetoken.cn/zh/alibaba-wan-3-0-api/quickstart.md)与[定价页](https://vibetoken.cn/pricing)。
>
> 首帧/尾帧不能与参考图片、视频或音频组合使用。如需用参考素材引导视频，请使用
> [参考生视频](https://docs.vibetoken.cn/zh/alibaba-wan-3-0-api/reference-to-video.md)。

## 端点

```http theme={null}
POST https://vibetoken.cn/v1/videos/generations
```

异步接口 — 返回 `{id, status: "pending"}`；轮询
`GET /v1/videos/generations/{id}` 直到状态为 `success` 或 `failed`。

## 参数

**image\_urls** `string[]` *required*

单元素数组，内含首帧图片 URL（公网 HTTPS）。

**last\_frame\_url** `string`

尾帧的公网 HTTPS URL。视频会从首帧过渡到这一帧。

**prompt** `string`

可选的文本提示词，描述运动方式，也可描述音轨中想要的声音或台词。最多 20000 个字符。

**resolution** `"480P" | "720P" | "1080P"` (default: "1080P")

输出分辨率。每档各有独立的每秒费率。

**ratio** `"adaptive" | "16:9" | "9:16" | "1:1" | "4:3" | "3:4" | "21:9"` (default: "adaptive")

生成视频的宽高比。`adaptive` 沿用首帧的宽高比。

**duration** `integer` (default: 5)

片段时长（秒），取值范围 `[2, 30]`。

**audio** `boolean` (default: true)

生成音轨。设为 `false` 可得到无声片段。

**seed** `integer`

随机种子，取值范围 `[0, 2147483647]`。以相同请求复用同一种子，可更接近地复现结果。

**prompt\_extend** `boolean` (default: true)

生成前由模型扩写提示词。设为 `false` 则按原样使用提示词。

**watermark** `boolean` (default: false)

在视频上添加 AI 生成水印。

该模型不支持的选项不会转发给它。

## 示例

```bash theme={null}
curl https://vibetoken.cn/v1/videos/generations \
  -H "Authorization: Bearer $VIBETOKEN_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "model": "alibaba/wan-3-0-i2v",
    "prompt": "晨光洒满桌面，花苞缓缓绽放",
    "image_urls": ["https://example.com/first-frame.png"],
    "last_frame_url": "https://example.com/last-frame.png",
    "resolution": "720P",
    "duration": 5
  }'
```

使用 Prime 档位时，将 `"model"` 改为 `"alibaba/wan-3-0-prime-i2v"`，请求体其余部分不变。

```json theme={null}
{ "id": "task_abc123…", "status": "pending", "model": "alibaba/wan-3-0-i2v" }
```

轮询直到进入终态：

```bash theme={null}
curl https://vibetoken.cn/v1/videos/generations/task_abc123… \
  -H "Authorization: Bearer $VIBETOKEN_API_KEY"
```

```json theme={null}
{
  "id": "task_abc123…",
  "status": "success",
  "data": [{ "url": "https://…mp4" }]
}
```


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.