Single Image/First and Last Frame Video Generation VQ2PF
/api/v1/video/generationHeader Parameters
Format: Authorization: Bearer sk-xxxxxx
Request Body
application/json
Fixed value i2v
Model name, supported: viduq2-pro-fast
Resolution, supported: 720p, 1080p
Random Seed
Whether to enable background music, defaults to false
Image Information (supported only in single image-to-video mode)
Image Link
Generated prompt text
Video duration, in seconds, supported: (Single image-to-video mode) [1,10] (First and last frame-to-video mode) [1,8]
Whether to enable audio, default is false (only supported in single image-to-video mode)
Voice ID (only supported in single-image-to-video mode)
First and Last Frame Image Information (supported only in First and Last Frame to Video mode)
First Frame Image Information
Image Link
Last Frame Image Information
Image Link
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" }, "prompt": "string", "headtailImages": {} }'{
"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"
}