Wan 2.5 Text to Video Preview
curl --request POST \
--url https://api.myrouter.ai/v3/async/wan-2.5-t2v-preview \
--header 'Authorization: <authorization>' \
--header 'Content-Type: <content-type>' \
--data '
{
"input": {
"prompt": "<string>",
"negative_prompt": "<string>"
},
"model": "<string>",
"parameters": {
"seed": 123,
"size": "<string>",
"duration": 123,
"watermark": true,
"prompt_extend": true
}
}
'import requests
url = "https://api.myrouter.ai/v3/async/wan-2.5-t2v-preview"
payload = {
"input": {
"prompt": "<string>",
"negative_prompt": "<string>"
},
"model": "<string>",
"parameters": {
"seed": 123,
"size": "<string>",
"duration": 123,
"watermark": True,
"prompt_extend": True
}
}
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({
input: {prompt: '<string>', negative_prompt: '<string>'},
model: '<string>',
parameters: {
seed: 123,
size: '<string>',
duration: 123,
watermark: true,
prompt_extend: true
}
})
};
fetch('https://api.myrouter.ai/v3/async/wan-2.5-t2v-preview', 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/wan-2.5-t2v-preview",
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([
'input' => [
'prompt' => '<string>',
'negative_prompt' => '<string>'
],
'model' => '<string>',
'parameters' => [
'seed' => 123,
'size' => '<string>',
'duration' => 123,
'watermark' => true,
'prompt_extend' => true
]
]),
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/wan-2.5-t2v-preview"
payload := strings.NewReader("{\n \"input\": {\n \"prompt\": \"<string>\",\n \"negative_prompt\": \"<string>\"\n },\n \"model\": \"<string>\",\n \"parameters\": {\n \"seed\": 123,\n \"size\": \"<string>\",\n \"duration\": 123,\n \"watermark\": true,\n \"prompt_extend\": true\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/wan-2.5-t2v-preview")
.header("Content-Type", "<content-type>")
.header("Authorization", "<authorization>")
.body("{\n \"input\": {\n \"prompt\": \"<string>\",\n \"negative_prompt\": \"<string>\"\n },\n \"model\": \"<string>\",\n \"parameters\": {\n \"seed\": 123,\n \"size\": \"<string>\",\n \"duration\": 123,\n \"watermark\": true,\n \"prompt_extend\": true\n }\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.myrouter.ai/v3/async/wan-2.5-t2v-preview")
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 \"input\": {\n \"prompt\": \"<string>\",\n \"negative_prompt\": \"<string>\"\n },\n \"model\": \"<string>\",\n \"parameters\": {\n \"seed\": 123,\n \"size\": \"<string>\",\n \"duration\": 123,\n \"watermark\": true,\n \"prompt_extend\": true\n }\n}"
response = http.request(request)
puts response.read_body{
"task_id": "<string>",
"provider_request_id": "<string>"
}Video
Wan 2.5 Text to Video Preview
POST
/
v3
/
async
/
wan-2.5-t2v-preview
Wan 2.5 Text to Video Preview
curl --request POST \
--url https://api.myrouter.ai/v3/async/wan-2.5-t2v-preview \
--header 'Authorization: <authorization>' \
--header 'Content-Type: <content-type>' \
--data '
{
"input": {
"prompt": "<string>",
"negative_prompt": "<string>"
},
"model": "<string>",
"parameters": {
"seed": 123,
"size": "<string>",
"duration": 123,
"watermark": true,
"prompt_extend": true
}
}
'import requests
url = "https://api.myrouter.ai/v3/async/wan-2.5-t2v-preview"
payload = {
"input": {
"prompt": "<string>",
"negative_prompt": "<string>"
},
"model": "<string>",
"parameters": {
"seed": 123,
"size": "<string>",
"duration": 123,
"watermark": True,
"prompt_extend": True
}
}
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({
input: {prompt: '<string>', negative_prompt: '<string>'},
model: '<string>',
parameters: {
seed: 123,
size: '<string>',
duration: 123,
watermark: true,
prompt_extend: true
}
})
};
fetch('https://api.myrouter.ai/v3/async/wan-2.5-t2v-preview', 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/wan-2.5-t2v-preview",
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([
'input' => [
'prompt' => '<string>',
'negative_prompt' => '<string>'
],
'model' => '<string>',
'parameters' => [
'seed' => 123,
'size' => '<string>',
'duration' => 123,
'watermark' => true,
'prompt_extend' => true
]
]),
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/wan-2.5-t2v-preview"
payload := strings.NewReader("{\n \"input\": {\n \"prompt\": \"<string>\",\n \"negative_prompt\": \"<string>\"\n },\n \"model\": \"<string>\",\n \"parameters\": {\n \"seed\": 123,\n \"size\": \"<string>\",\n \"duration\": 123,\n \"watermark\": true,\n \"prompt_extend\": true\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/wan-2.5-t2v-preview")
.header("Content-Type", "<content-type>")
.header("Authorization", "<authorization>")
.body("{\n \"input\": {\n \"prompt\": \"<string>\",\n \"negative_prompt\": \"<string>\"\n },\n \"model\": \"<string>\",\n \"parameters\": {\n \"seed\": 123,\n \"size\": \"<string>\",\n \"duration\": 123,\n \"watermark\": true,\n \"prompt_extend\": true\n }\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.myrouter.ai/v3/async/wan-2.5-t2v-preview")
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 \"input\": {\n \"prompt\": \"<string>\",\n \"negative_prompt\": \"<string>\"\n },\n \"model\": \"<string>\",\n \"parameters\": {\n \"seed\": 123,\n \"size\": \"<string>\",\n \"duration\": 123,\n \"watermark\": true,\n \"prompt_extend\": true\n }\n}"
response = http.request(request)
puts response.read_body{
"task_id": "<string>",
"provider_request_id": "<string>"
}Wan 2.5 Text-to-Video API that generates high-quality videos with native audio synchronization from text descriptions.
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
object
required
string
Model name for video generation, e.g. wan2.5-t2v-preview.
object
Optional parameters for controlling video generation.
Hide properties
Hide properties
integer
Random seed for reproducible generation.Range: [0, 2147483647]
string
Video resolution in width*height format. Supports 480P/720P/1080P tiers.Possible values:
832*480, 480*832, 624*624, 1280*720, 720*1280, 960*960, 1088*832, 832*1088, 1920*1080, 1080*1920, 1440*1440, 1632*1248, 1248*1632integer
Duration of the generated video (seconds).Possible values:
5, 10boolean
Whether to add an “AI Generated” watermark. Default: false.
boolean
Whether to enable LLM automatic prompt enhancement. Default: true.
Response
string
Use the task_id to call the Get Async Task Result API to retrieve the generated output.
string
Unique request identifier from the service provider.
⌘I