Перейти к содержимому
Главная

Vidu Q2 Pro - Reference to Video

viduq2-pro-reference2video

Vidu Q2 Pro - Reference to Video supports both image and video references to generate high-quality videos with subject consistency

POST /v1/queue/viduq2-pro-reference2video # Создать задачу
GET /v1/queue/viduq2-pro-reference2video/requests/{request_id}/status # Проверить статус
GET /v1/queue/viduq2-pro-reference2video/requests/{request_id}/response # Получить результат
PUT /v1/queue/viduq2-pro-reference2video/requests/{request_id}/cancel # Отменить задачу
Окно терминала
curl --request 'POST' 'https://odirouter.ai/model/v1/queue/viduq2-pro-reference2video' \
--header 'Authorization: Bearer YOUR_API_KEY' \
--header 'Content-Type: application/json' \
--location \
--data-raw '{
"prompt": "A golden retriever running happily on a green grass field",
"images": [
"https://www.gstatic.com/webp/gallery/2.jpg"
],
"duration": 5,
"aspect_ratio": "16:9",
"resolution": "720p"
}'

Image references. Supports uploading 1 to 7 images. The model uses subjects from these images to generate videos with subject consistency.

Note 1: For this model, if no video is uploaded, 1 to 7 images are supported. If video is uploaded, 1 to 4 images are supported. Note 2: Supports image Base64 input or image URL input (must be accessible). Note 3: Supported image formats: png, jpeg, jpg, webp. Note 4: Image resolution must be at least 128x128, aspect ratio must be less than 1:4 or 4:1, and file size must not exceed 50MB. Note 5: HTTP request post body must not exceed 20MB, and encoding must include a proper content-type prefix, for example: data:image/png;base64,{base64_encode}.


Video references. Supports uploading 1 to 2 videos. The model uses these videos as references to generate videos with subject consistency.

Note 1: With video reference enabled, at most 1 video of 8 seconds or 2 videos of 5 seconds are supported. Note 2: Supported video formats: mp4, avi, mov. Note 3: Video resolution must be at least 128x128, aspect ratio must be less than 1:4 or 4:1, and file size must not exceed 100MB. Note 4: Base64 decoded byte length must be less than 20MB, and encoding must include a proper content-type prefix, for example: data:video/mp4;base64,{base64_encode}.


Text prompt describing the video to generate.

Limit: Maximum 5000 characters.


Whether to add background music to the generated video.

If set to true, the system automatically selects and adds suitable music from the preset BGM library. If omitted or set to false, no BGM is added. BGM has no duration limit and is automatically adapted to video duration. Note: In this model, when duration is 9 or 10, bgm does not take effect.

Options: true, false

Default: false


Video duration parameter.

Options: 0 to 10 (0 means auto duration selection)

Default: 5


Random seed. If omitted or set to 0, a random value is used. If set manually, the provided seed is used.


Aspect ratio.

Options: 16:9, 9:16, 4:3, 3:4, 1:1

Resolution parameter.

Options: 540p, 720p, 1080p

Default: 720p


Pass-through parameter. No processing is performed, only data transfer.

Limit: Maximum 1048576 characters.


Note: Temporarily unavailable

Off-peak mode.

true: Generate video in off-peak mode. false: Generate video immediately.

Note 1: Off-peak mode consumes fewer credits. Note 2: Tasks submitted in off-peak mode are generated within 48 hours. Unfinished tasks are automatically canceled and credits are refunded. Note 3: You can also manually cancel off-peak tasks. Note 4: Audio-video direct output does not support off-peak mode.

Options: true, false

Default: false


Whether to add watermark.

true: Add watermark. false: Do not add watermark.

Note 1: Current watermark content is fixed and AI-generated, and is disabled by default. Note 2: You can obtain watermarked video content through the watermarked_url field.

Options: true, false

Default: false


Watermark position.

1: Top-left 2: Top-right 3: Bottom-right 4: Bottom-left

Default: 3


Watermark image URL. If omitted, the default watermark is used (AI-generated).


Metadata identifier.


Callback URL.

{
"request_id": "task_01hxyz...",
"response_url": "https://odirouter.ai/model/v1/queue/viduq2-pro-reference2video/requests/task_01hxyz.../response",
"status_url": "https://odirouter.ai/model/v1/queue/viduq2-pro-reference2video/requests/task_01hxyz.../status",
"cancel_url": "https://odirouter.ai/model/v1/queue/viduq2-pro-reference2video/requests/task_01hxyz.../cancel",
"queue_position": 0
}
ПолеТипОписание
request_idstringИдентификатор задачи для последующей проверки статуса, получения результата и отмены.
response_urlstringURL для получения итогового результата.
status_urlstringURL для проверки статуса задачи.
cancel_urlstringURL для отмены задачи.
queue_positionintТекущая позиция в очереди.