Skip to main content
POST

Authorizations

Authorization
string
header
required

Pass Authorization: Bearer <token> in the request header.

Body

application/json
model
enum<string>
required

Model name. Available value: wan2.7-i2v.

Available options:
wan2.7-i2v
media
object[]
required

List of media assets (images, audio, video) for video generation. Each element is a media object with type and url.

Supported combinations (invalid combinations will return an error):

  • First frame only: first_frame
  • First frame + audio: first_frame + driving_audio

Each type can appear at most once in the array.

prompt
string

Text prompt describing the desired video content and visual characteristics. Supports Chinese and English, up to 5000 characters (each character or letter counts as one). Excess characters will be automatically truncated.

size
enum<string>
default:1080P

Specifies the output resolution tier for controlling video clarity (total pixels).

The model automatically scales to a similar total pixel count based on the selected resolution tier. The video aspect ratio will attempt to stay consistent with the input material (first frame or first clip).

Available options:
720P,
1080P
seconds
enum<string>
default:5

Video duration as a string. Supports integer strings from 2 to 15.

Available options:
2,
3,
4,
5,
6,
7,
8,
9,
10,
11,
12,
13,
14,
15
negative_prompt
string

Negative prompt describing content you do not want in the video. Supports Chinese and English, up to 500 characters. Excess characters will be automatically truncated. Example: low resolution, worst quality, deformed, extra fingers, bad proportions.

prompt_extend
boolean

Whether to enable intelligent prompt rewriting. When enabled, a large language model rewrites the input prompt intelligently, significantly improving results for short prompts but increasing processing time. true (default): enable. false: disable.

watermark
boolean
default:false

Whether to add a watermark. The watermark is positioned at the bottom-right corner with the text 'AI生成'. false (default): no watermark. true: add watermark.

seed
integer

Random seed, range [0, 2147483647]. When unspecified, the system auto-generates a random seed. For better reproducibility, set a fixed seed. Note: due to the probabilistic nature of model generation, the same seed does not guarantee identical results every time.

Required range: 0 <= x <= 2147483647

Response

Submitted successfully. Returns an OpenAI-compatible video task object.

id
string

Public task ID.

task_id
string

Backward-compatible alias for the public task ID.

object
string
Example:

"video"

model
string

Model name.

status
enum<string>

Unified video task status.

Available options:
queued,
in_progress,
completed,
failed,
unknown
progress
integer

Task progress percentage.

created_at
integer<int64>

Creation time as a Unix timestamp (seconds).