Jimeng Video Generation
curl --request POST \
--url https://www.token-nova.com/v1/videos \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"model": "<string>",
"prompt": "<string>",
"seconds": "<string>",
"size": "<string>"
}
'import requests
url = "https://www.token-nova.com/v1/videos"
payload = {
"model": "<string>",
"prompt": "<string>",
"seconds": "<string>",
"size": "<string>"
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({model: '<string>', prompt: '<string>', seconds: '<string>', size: '<string>'})
};
fetch('https://www.token-nova.com/v1/videos', 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://www.token-nova.com/v1/videos",
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([
'model' => '<string>',
'prompt' => '<string>',
'seconds' => '<string>',
'size' => '<string>'
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$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://www.token-nova.com/v1/videos"
payload := strings.NewReader("{\n \"model\": \"<string>\",\n \"prompt\": \"<string>\",\n \"seconds\": \"<string>\",\n \"size\": \"<string>\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://www.token-nova.com/v1/videos")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"model\": \"<string>\",\n \"prompt\": \"<string>\",\n \"seconds\": \"<string>\",\n \"size\": \"<string>\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://www.token-nova.com/v1/videos")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"model\": \"<string>\",\n \"prompt\": \"<string>\",\n \"seconds\": \"<string>\",\n \"size\": \"<string>\"\n}"
response = http.request(request)
puts response.read_body{
"id": "video_123",
"task_id": "video_123",
"object": "video",
"model": "jimeng-video-3.0",
"status": "queued",
"progress": 0,
"created_at": 1712697600
}
OpenAI Format
Jimeng Video Generation
Use POST /v1/videos to call the Jimeng model and submit asynchronous video tasks.
POST
https://www.token-nova.com
/
v1
/
videos
Jimeng Video Generation
curl --request POST \
--url https://www.token-nova.com/v1/videos \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"model": "<string>",
"prompt": "<string>",
"seconds": "<string>",
"size": "<string>"
}
'import requests
url = "https://www.token-nova.com/v1/videos"
payload = {
"model": "<string>",
"prompt": "<string>",
"seconds": "<string>",
"size": "<string>"
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({model: '<string>', prompt: '<string>', seconds: '<string>', size: '<string>'})
};
fetch('https://www.token-nova.com/v1/videos', 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://www.token-nova.com/v1/videos",
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([
'model' => '<string>',
'prompt' => '<string>',
'seconds' => '<string>',
'size' => '<string>'
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$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://www.token-nova.com/v1/videos"
payload := strings.NewReader("{\n \"model\": \"<string>\",\n \"prompt\": \"<string>\",\n \"seconds\": \"<string>\",\n \"size\": \"<string>\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://www.token-nova.com/v1/videos")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"model\": \"<string>\",\n \"prompt\": \"<string>\",\n \"seconds\": \"<string>\",\n \"size\": \"<string>\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://www.token-nova.com/v1/videos")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"model\": \"<string>\",\n \"prompt\": \"<string>\",\n \"seconds\": \"<string>\",\n \"size\": \"<string>\"\n}"
response = http.request(request)
puts response.read_body{
"id": "video_123",
"task_id": "video_123",
"object": "video",
"model": "jimeng-video-3.0",
"status": "queued",
"progress": 0,
"created_at": 1712697600
}
Jimeng Video Generation
OpenAI-format entry point. If you need to use the unified videoPOST /v1/video/create, see Generate Video.
Jimeng currently uses POST /v1/videos to submit tasks, primarily via multipart/form-data.
- The route entry is
POST /v1/videos. - Currently submitted via
multipart/form-data. - The reference image is passed as a single file through the
input_referencefield. - After a successful submission, the task
idandstatusare returned, and you can later poll the result via Task Status Query.
Supported Models
jimeng-video-3.0jimeng-video-2.0
Method and Path
POST /v1/videos
Request Example
curl -X POST https://www.token-nova.com/v1/videos \
-H "Authorization: Bearer YOUR_API_KEY" \
-F "model=jimeng-video-3.0" \
-F "prompt=猫咪在草地上追逐蝴蝶" \
-F "seconds=5" \
-F "size=1280x720"
import requests
resp = requests.post(
"https://www.token-nova.com/v1/videos",
headers={"Authorization": "Bearer YOUR_API_KEY"},
data={
"model": "jimeng-video-3.0",
"prompt": "猫咪在草地上追逐蝴蝶",
"seconds": "5",
"size": "1280x720",
},
timeout=60,
)
print(resp.json())
Image-to-Video Example
# 带参考图的请求示例
curl -X POST https://www.token-nova.com/v1/videos \
-H "Authorization: Bearer YOUR_API_KEY" \
-F "model=jimeng-video-3.0" \
-F "prompt=让人物向前走并微笑" \
-F "seconds=5" \
-F "size=720x1280" \
-F "input_reference=@/path/to/image.png"
# 带参考图的请求示例
import requests
with open("image.png", "rb") as f:
resp = requests.post(
"https://www.token-nova.com/v1/videos",
headers={"Authorization": "Bearer YOUR_API_KEY"},
data={
"model": "jimeng-video-3.0",
"prompt": "让人物向前走并微笑",
"seconds": "5",
"size": "720x1280",
},
files={"input_reference": f},
timeout=60,
)
print(resp.json())
Response Example
{
"id": "video_123",
"task_id": "video_123",
"object": "video",
"model": "jimeng-video-3.0",
"status": "queued",
"progress": 0,
"created_at": 1712697600
}
Authentication
Authorization: Bearer YOUR_API_KEY
Body
string
required
Model name. Supports
jimeng-video-3.0 and jimeng-video-2.0.string
required
Prompt describing the video content. Supports Chinese and English.
file
Reference image. Upload a single image file for image-to-video scenarios. Supported image formats include png, jpeg, jpg, and webp.
string
Video duration in seconds. Available values:
5, 10, 15.string
Video size. Available values:
720x1280 (portrait), 1280x720 (landscape). Defaults to 720x1280.Current Rules
| Item | Rule |
|---|---|
| Default duration | If not explicitly provided, defaults to 5 seconds |
| Default size | If not explicitly provided, defaults to 720x1280 |
| Reference image | Upload a single image file via input_reference |
| Reference image formats | Supports png, jpeg, jpg, and webp |
