Single Image/First and Last Frames/Intelligent Multi-Frame Video Generation VQ2T
/api/v1/video/generationHeader Parameters
Format: Authorization: Bearer sk-xxxxxx
Request Body
application/json
Fixed value i2v
Model name, supported: viduq2-turbo
Resolution, supported: 360p, 720p, 1080p
Random Seed
Whether to enable background music, default is false
Image Information (Image-to-Video only)
Image Link
First and Last Frame Image Information (Only supported for video generation from first and last frames)
First Frame Image Information
Image Link
Last Frame Image Information
Image Link
First frame image, supporting PNG, JPEG, JPG, and WebP formats, with a file size not exceeding 50 MB and an aspect ratio of less than 1:4 or 4:1 (only supported by Intelligent Multi-Frame Video Generation).
Image Link
Smart multi-frame configuration, with a minimum of 2 frames and a maximum of 9 frames per task (only supported for smart multi-frame video generation)
Keyframe image, serving as the last frame of the current video segment or the first frame of the next segment.
Image Link
Extension prompt, used to control the extended video content, with a maximum length of 1,500 characters.
Multi-frame duration, the video duration between different keyframes, defaults to 5 seconds, with options ranging from 2 to 7 seconds.
Generated prompt text (supported only in single-image and first-last frame modes)
Video duration, in seconds (supported only in single-image and first-last-frame modes). Image-to-video: [1,10]. First-last-frame-to-video: [1,8].
Metadata identifier, JSON-formatted string, pass-through field (supported only by intelligent multi-frame video generation)
Callback URL (Only supported for Smart Multi-frame Video Generation)
Pass-through parameters without any processing, for data transmission only, up to 1,048,576 characters (supported only by intelligent multi-frame video generation)
Response Body
application/json
Success
TypeScript Definitions
Use the response body type in TypeScript.
Status Code
Data Object
Result Set
Usage Information
Number of Images
Video Duration in Seconds
Input token count
Total Tokens
Output Token Count
Validity Period
Task ID
Task Status
Status Information
Request ID
curl -X POST "https://api.ygw.ai/api/v1/video/generation" \ -H "Authorization: string" \ -H "Content-Type: application/json" \ -d '{ "_action": "string", "model": "string", "image": { "imageUrl": "string" }, "headtailImages": { "headImage": { "imageUrl": "string" }, "tailImage": { "imageUrl": "string" } }, "startImage": { "imageUrl": "string" }, "imageSettings": [ { "keyImage": { "imageUrl": "string" } } ], "prompt": "string" }'{
"code": 0,
"data": {
"urls": [
"string"
],
"usage": {
"images": 0,
"seconds": 0,
"input_tokens": 0,
"total_tokens": 0,
"output_tokens": 0
},
"expired": "string",
"task_id": "string",
"task_status": "string"
},
"message": "string",
"request_id": "string"
}