VIDU Q2 Pro Multi-frame to Video
curl --request POST \
--url https://api.myrouter.ai/v3/async/vidu-q2-pro-multiframe \
--header 'Authorization: <authorization>' \
--header 'Content-Type: <content-type>' \
--data '
{
"wm_url": "<string>",
"payload": "<string>",
"meta_data": "<string>",
"watermark": true,
"resolution": "<string>",
"start_image": "<string>",
"wm_position": "<string>",
"image_settings": [
{
"prompt": "<string>",
"duration": 123,
"key_image": "<string>"
}
]
}
'import requests
url = "https://api.myrouter.ai/v3/async/vidu-q2-pro-multiframe"
payload = {
"wm_url": "<string>",
"payload": "<string>",
"meta_data": "<string>",
"watermark": True,
"resolution": "<string>",
"start_image": "<string>",
"wm_position": "<string>",
"image_settings": [
{
"prompt": "<string>",
"duration": 123,
"key_image": "<string>"
}
]
}
headers = {
"Content-Type": "<content-type>",
"Authorization": "<authorization>"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'Content-Type': '<content-type>', Authorization: '<authorization>'},
body: JSON.stringify({
wm_url: '<string>',
payload: '<string>',
meta_data: '<string>',
watermark: true,
resolution: '<string>',
start_image: '<string>',
wm_position: '<string>',
image_settings: [{prompt: '<string>', duration: 123, key_image: '<string>'}]
})
};
fetch('https://api.myrouter.ai/v3/async/vidu-q2-pro-multiframe', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.myrouter.ai/v3/async/vidu-q2-pro-multiframe",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'wm_url' => '<string>',
'payload' => '<string>',
'meta_data' => '<string>',
'watermark' => true,
'resolution' => '<string>',
'start_image' => '<string>',
'wm_position' => '<string>',
'image_settings' => [
[
'prompt' => '<string>',
'duration' => 123,
'key_image' => '<string>'
]
]
]),
CURLOPT_HTTPHEADER => [
"Authorization: <authorization>",
"Content-Type: <content-type>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.myrouter.ai/v3/async/vidu-q2-pro-multiframe"
payload := strings.NewReader("{\n \"wm_url\": \"<string>\",\n \"payload\": \"<string>\",\n \"meta_data\": \"<string>\",\n \"watermark\": true,\n \"resolution\": \"<string>\",\n \"start_image\": \"<string>\",\n \"wm_position\": \"<string>\",\n \"image_settings\": [\n {\n \"prompt\": \"<string>\",\n \"duration\": 123,\n \"key_image\": \"<string>\"\n }\n ]\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Content-Type", "<content-type>")
req.Header.Add("Authorization", "<authorization>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.myrouter.ai/v3/async/vidu-q2-pro-multiframe")
.header("Content-Type", "<content-type>")
.header("Authorization", "<authorization>")
.body("{\n \"wm_url\": \"<string>\",\n \"payload\": \"<string>\",\n \"meta_data\": \"<string>\",\n \"watermark\": true,\n \"resolution\": \"<string>\",\n \"start_image\": \"<string>\",\n \"wm_position\": \"<string>\",\n \"image_settings\": [\n {\n \"prompt\": \"<string>\",\n \"duration\": 123,\n \"key_image\": \"<string>\"\n }\n ]\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.myrouter.ai/v3/async/vidu-q2-pro-multiframe")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Content-Type"] = '<content-type>'
request["Authorization"] = '<authorization>'
request.body = "{\n \"wm_url\": \"<string>\",\n \"payload\": \"<string>\",\n \"meta_data\": \"<string>\",\n \"watermark\": true,\n \"resolution\": \"<string>\",\n \"start_image\": \"<string>\",\n \"wm_position\": \"<string>\",\n \"image_settings\": [\n {\n \"prompt\": \"<string>\",\n \"duration\": 123,\n \"key_image\": \"<string>\"\n }\n ]\n}"
response = http.request(request)
puts response.read_body{
"task_id": "<string>",
"provider_request_id": "<string>"
}Video
VIDU Q2 Pro Multi-frame to Video
POST
/
v3
/
async
/
vidu-q2-pro-multiframe
VIDU Q2 Pro Multi-frame to Video
curl --request POST \
--url https://api.myrouter.ai/v3/async/vidu-q2-pro-multiframe \
--header 'Authorization: <authorization>' \
--header 'Content-Type: <content-type>' \
--data '
{
"wm_url": "<string>",
"payload": "<string>",
"meta_data": "<string>",
"watermark": true,
"resolution": "<string>",
"start_image": "<string>",
"wm_position": "<string>",
"image_settings": [
{
"prompt": "<string>",
"duration": 123,
"key_image": "<string>"
}
]
}
'import requests
url = "https://api.myrouter.ai/v3/async/vidu-q2-pro-multiframe"
payload = {
"wm_url": "<string>",
"payload": "<string>",
"meta_data": "<string>",
"watermark": True,
"resolution": "<string>",
"start_image": "<string>",
"wm_position": "<string>",
"image_settings": [
{
"prompt": "<string>",
"duration": 123,
"key_image": "<string>"
}
]
}
headers = {
"Content-Type": "<content-type>",
"Authorization": "<authorization>"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'Content-Type': '<content-type>', Authorization: '<authorization>'},
body: JSON.stringify({
wm_url: '<string>',
payload: '<string>',
meta_data: '<string>',
watermark: true,
resolution: '<string>',
start_image: '<string>',
wm_position: '<string>',
image_settings: [{prompt: '<string>', duration: 123, key_image: '<string>'}]
})
};
fetch('https://api.myrouter.ai/v3/async/vidu-q2-pro-multiframe', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.myrouter.ai/v3/async/vidu-q2-pro-multiframe",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'wm_url' => '<string>',
'payload' => '<string>',
'meta_data' => '<string>',
'watermark' => true,
'resolution' => '<string>',
'start_image' => '<string>',
'wm_position' => '<string>',
'image_settings' => [
[
'prompt' => '<string>',
'duration' => 123,
'key_image' => '<string>'
]
]
]),
CURLOPT_HTTPHEADER => [
"Authorization: <authorization>",
"Content-Type: <content-type>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.myrouter.ai/v3/async/vidu-q2-pro-multiframe"
payload := strings.NewReader("{\n \"wm_url\": \"<string>\",\n \"payload\": \"<string>\",\n \"meta_data\": \"<string>\",\n \"watermark\": true,\n \"resolution\": \"<string>\",\n \"start_image\": \"<string>\",\n \"wm_position\": \"<string>\",\n \"image_settings\": [\n {\n \"prompt\": \"<string>\",\n \"duration\": 123,\n \"key_image\": \"<string>\"\n }\n ]\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Content-Type", "<content-type>")
req.Header.Add("Authorization", "<authorization>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.myrouter.ai/v3/async/vidu-q2-pro-multiframe")
.header("Content-Type", "<content-type>")
.header("Authorization", "<authorization>")
.body("{\n \"wm_url\": \"<string>\",\n \"payload\": \"<string>\",\n \"meta_data\": \"<string>\",\n \"watermark\": true,\n \"resolution\": \"<string>\",\n \"start_image\": \"<string>\",\n \"wm_position\": \"<string>\",\n \"image_settings\": [\n {\n \"prompt\": \"<string>\",\n \"duration\": 123,\n \"key_image\": \"<string>\"\n }\n ]\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.myrouter.ai/v3/async/vidu-q2-pro-multiframe")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Content-Type"] = '<content-type>'
request["Authorization"] = '<authorization>'
request.body = "{\n \"wm_url\": \"<string>\",\n \"payload\": \"<string>\",\n \"meta_data\": \"<string>\",\n \"watermark\": true,\n \"resolution\": \"<string>\",\n \"start_image\": \"<string>\",\n \"wm_position\": \"<string>\",\n \"image_settings\": [\n {\n \"prompt\": \"<string>\",\n \"duration\": 123,\n \"key_image\": \"<string>\"\n }\n ]\n}"
response = http.request(request)
puts response.read_body{
"task_id": "<string>",
"provider_request_id": "<string>"
}Generate coherent videos from multiple keyframe images. Supports 540p, 720p, and 1080p resolutions.
This is an async API that only returns the task_id of the async task. Use the task_id to call the Get Async Task Result API to retrieve the generated result.
Request Headers
string
required
Enum:
application/jsonstring
required
Bearer authentication format: Bearer {{API Key}}.
Request Body
string
Watermark image URL. When watermark is enabled but no custom watermark URL is provided, the default watermark is used. This parameter has no effect if watermark is disabled.
string
Pass-through parameter. No processing is performed; data is transmitted as-is. Maximum 1,048,576 characters.
string
Metadata identifier as a JSON-formatted string. Pass-through field.
boolean
default:false
Whether to add a watermark. true: add watermark. false: no watermark. Default: no watermark.
string
default:"720p"
Video resolution. Default: 720p.Possible values:
540p, 720p, 1080pstring
required
First frame image. Supports Base64-encoded images or image URLs. Only 1 image is supported. Supported formats: png, jpeg, jpg, webp. Image aspect ratio must be less than 1:4 or 4:1. Image size must not exceed 50 MB.
string
default:"bottom_left"
Watermark position. Default: bottom-left. This parameter has no effect if watermark is disabled.Possible values:
top_left, top_right, bottom_right, bottom_leftarray
required
Keyframe configuration array. Each task requires a minimum of 2 keyframes and a maximum of 9 keyframes.Array length: 2 - 9
Hide properties
Hide properties
string
Prompt for extending the previous image, used to control the extended video content.
integer
default:5
Multi-frame duration. Video duration between different keyframes. Default: 5s. Options: 2-7s.Range: [2, 7]
string
required
Reference image for the intermediate frame. The model uses this image as the end frame to generate the video. Supports Base64-encoded images or image URLs. Only 1 image is supported. Input order corresponds to timeline order (from first frame to last frame). Supported formats: png, jpeg, jpg, webp. Image aspect ratio must be less than 1:4 or 4:1. Image size must not exceed 50 MB.
Response
string
required
Use the task_id to call the Get Async Task Result API to retrieve the generated output.
string
Provider request ID (optional)
⌘I