Documentation Index
Fetch the complete documentation index at: https://docs.apiyi.com/llms.txt
Use this file to discover all available pages before exploring further.
开始接入 阿里云旗下的视频生成模型 wan2.7
这是 KEY ,我们中转站的
测试模型列表
wan2.7-videoedit,wan2.7-image-pro,wan2.7-r2v,wan2.7-i2v,wan2.7-t2v,wan2.6-r2v,wan2.6-t2v,wan2.6-i2v,wan2.6-r2v-flash
最小示例代码
curl --request POST \
--url https://api.apiyi.com/v1/videos \
--header 'Authorization: Bearer sk-你的apiyi-key' \
--header 'Content-Type: application/json' \
--data '
{
"model": "wan2.7-t2v",
"prompt": "黄昏海边的灯塔,镜头缓慢推进,海浪轻拍礁石,海鸟叫声,电影级光影,稳定运镜"
}
'
输出为
{"created_at":1779444755,"id":"5fc55285-fe33-44e7-8f45-42660940ef26","model":"wan2.7-t2v","object":"video","output":{"task_id":"5fc55285-fe33-44e7-8f45-42660940ef26","task_status":"PENDING"},"request_id":"b7917824-649b-99e9-8790-51214a57ccc1","status":"submitted"}
原来请求端点是这个
新的请求示例
curl --location 'https://api.apiyi.com/wan/api/v1/services/aigc/video-generation/video-synthesis' \
-H 'X-DashScope-Async: enable' \
-H "Authorization: Bearer sk-你的apiyi-key" \
-H 'Content-Type: application/json' \
-d '{
"model": "wan2.7-videoedit",
"input": {
"prompt": "将视频中女孩的衣服替换为图片中的衣服",
"media": [
{
"type": "video",
"url": "https://help-static-aliyun-doc.aliyuncs.com/file-manage-files/zh-CN/20260403/nlspwm/T2VA_22.mp4"
},
{
"type": "reference_image",
"url": "https://help-static-aliyun-doc.aliyuncs.com/file-manage-files/zh-CN/20260402/fwjpqf/wan2.7-videoedit-change-clothes.png"
}
]
},
"parameters": {
"resolution": "720P",
"prompt_extend": true,
"watermark": true
}
}'
输出
{"output":{"task_id":"3b216861-6a5f-441d-a438-602ab2c0d103","task_status":"PENDING"},"request_id":"ac977190-8751-9736-a9d4-4a5df09aa2f9"}
附一个任务详情
{
"action": "video_edit",
"channel_id": 763,
"created": 1779466665,
"data": {
"input": {
"media": [
{
"type": "video",
"url": "https://help-static-aliyun-doc.aliyuncs.com/file-manage-files/zh-CN/20260403/nlspwm/T2VA_22.mp4"
},
{
"type": "reference_image",
"url": "https://help-static-aliyun-doc.aliyuncs.com/file-manage-files/zh-CN/20260402/fwjpqf/wan2.7-videoedit-change-clothes.png"
}
],
"prompt": "将视频中女孩的衣服替换为图片中的衣服"
},
"model": "wan2.7-videoedit",
"parameters": {
"prompt_extend": true,
"resolution": "720P",
"watermark": true
}
},
"finish_time": 1779466827,
"id": "3b216861-6a5f-441d-a438-602ab2c0d103",
"model_name": "wan2.7-videoedit",
"object": "task",
"platform": "wan",
"progress": "100%",
"quota": 3750000,
"result_url": "https://dashscope-a717.oss-accelerate.aliyuncs.com/1d/45/20260523/378e4e30/36654129-metadata_user_817f0b9484bda5d6_watermark.mp4?Expires=1779553221&OSSAccessKeyId=LTAI5tPxpiCM2hjmWrFXrym1&Signature=yYVrbmZ47Tvf467vJKZFZr%2BBtTY%3D",
"start_time": 1779466705,
"status": "completed",
"submit_time": 1779466665,
"task_id": "3b216861-6a5f-441d-a438-602ab2c0d103",
"task_type": "video_edit",
"token_id": 92322,
"user_id": 1,
"username": "root"
}
同样为阿里云旗下的视频模型
happyhorse-1.0-i2v
HappyHorse-1.0-I2V支持图生视频,具备高度还原的动态画面生成能力,能够精准理解文本语义,输出流畅自然、细节丰富的高质量视频。
happyhorse-1.0-t2v
HappyHorse-1.0-T2V支持文生视频,具备高度还原的动态画面生成能力,能够精准理解文本语义,输出流畅自然、细节丰富的高质量视频。
happyhorse-1.0-r2v
HappyHorse-1.0-R2V支持参考生视频,更加稳定的主体与场景参考,支持最多9张图片参考,能够精准保持创作意图,实现更强表现能力。
happyhorse-1.0-video-edit
HappyHorse-1.0-Video-Edit支持视频编辑,自然语言指令编辑视频,可参考最多5张图片局部或全局编辑视频元素,能够精准复刻视频动态过程,实现更强表现能力。
curl --location 'https://dashscope.aliyuncs.com/api/v1/services/aigc/video-generation/video-synthesis' \
-H 'X-DashScope-Async: enable' \
-H "Authorization: Bearer $DASHSCOPE_API_KEY" \
-H 'Content-Type: application/json' \
-d '{
"model": "happyhorse-1.0-i2v",
"input": {
"prompt": "一只猫在草地上奔跑",
"media": [
{
"type": "first_frame",
"url": "https://cdn.translate.alibaba.com/r/wanx-demo-1.png"
}
]
},
"parameters": {
"resolution": "720P",
"duration": 5
}
}'