For new integrations, use Video Generation and the unified
/ai/v1/videos protocol for creation, task queries, Webhooks, and errors. The /v1/videos compatibility interface and model adapters on this page remain available. Before calling a model, query the Model Schema API, select the protocol by the returned path, and read that entry’s request.schema; do not rely on array order.Current model inventory
This inventory shows models that are currently available. It does not mean that every model accepts the same fields. Select the endpoint by
path in the model Schema response and read that entry’s request.schema.API Details
Request Headers
Create a Video Generation Task
Request Body
Response formats vary slightly across models, but all include theid(video_id) andstatusfields. Just usestatusto determine task progress.
Example Response (Tongyi Wanxiang / Veo / Jimeng AI)
Common Status Values
Query Video Status
Example Response (Generation Complete - Tongyi Wanxiang)
Example Response (Generation Complete - Sora)
All models usestatus == "completed"to determine the completion state, then call the/contentendpoint to download.
Download Video Content
completed, call this endpoint to download the MP4 video file.
Response: Returns the video binary stream directly (Content-Type: video/mp4).
Note: Video download links usually have a 24-hour validity period, so download and save them promptly.
Delete a Video Task
This endpoint is used to delete an already-created video task.Per-Model Parameter Details
OpenAI Sora
Tip: TheExamplesecondsparameter for all models is always passed as a string (e.g."8").
Google Veo
Example
Image field notes:
- First-frame precedence:
first_frame>input_reference(OpenAI-compatible single frame). - Each element of
first_frame/last_frame/reference_imagesaccepts: a public URL, a base64 data URL (data:image/png;base64,...), or a{"mime_type":"image/png","data":"<base64>"}object. - The OpenRouter-style
frame_images(elements withframe_type: first_frame | last_frame) andinput_referencesaliases are also accepted. - Up to 3 reference images; exceeding that returns 400.
Tip: Veo supports native audio generation; you can describe sound effects in the prompt, such as “the sound of birds chirping in the background” or “a piano melody”.
Tongyi Wanxiang
Duration Supported by Each Model
Supported Resolutions (width*height)
Note: wan2.6 supports only 720P and 1080P; wan2.5 supports 480P, 720P, and 1080P; wan2.2 supports only 480P and 1080P.Example
Tip: wan2.5 and above generate videos with sound by default (automatic dubbing); Chinese prompts work better.
Doubao Seedance
Before using real-person assets, complete asset group creation, personal verification, and asset registration; existing compatibility clients can refer directly to the real-person asset compatibility example.
Reference Types Supported by
extra_body.content
Example
Seedance 2.0 / 2.0 Fast
Kling
This inventory shows models that are currently available. It does not mean that every model accepts the same fields. Select the endpoint by
path in the model Schema response and read that entry’s request.schema.Complete Invocation Examples
FAQ
How long does video generation take?
Video generation usually takes 1-5 minutes, depending on the model, resolution, and duration. We recommend setting a 15-second polling interval.How do I use the input_reference parameter?
input_reference is used in image-to-video scenarios and supports three ways of passing input:
How long is the video download link valid?
Generated video download links usually have a 24-hour validity period, so download and save them promptly.What are the differences in the seconds parameter across models?
> Tip: The
seconds parameter for all models is always passed as a string (e.g. "8"), and the API handles it automatically.
What are the differences in the size parameter format across models?
What is the difference between seconds and duration?
The two have the same meaning, both representing the video duration. The API supports both parameter names (except Sora, which only accepts seconds). We recommend using seconds consistently.
How do I write better prompts?
- Describe specific scenes: include subject, action, environment, lighting, atmosphere
- Specify camera language: such as “close-up”, “aerial shot”, “push-in shot”, “slow motion”
- Describe style: such as “cinematic”, “documentary style”, “animation style”
- Chinese models work better with Chinese prompts: Tongyi Wanxiang is optimized for Chinese
- Veo supports audio descriptions: you can describe sounds in the prompt, such as “birds chirping” or “a piano melody”
Error Responses and Compatibility Error Codes
This section applies to the Legacy/v1/videos/* endpoints on this page. The new
/ai/v1/videos/* endpoints use a separate
video error contract. Handle the
response structures and error codes of the two interfaces separately.
A general HTTP error response from a Legacy video endpoint has the following
structure. Ordinary errors usually omit code and param, and tid is usually
appended to the end of message:
Submit HTTP 5xx error feedback
Only when a request returns HTTP
5xx, submit feedback and include the tid from message.HTTP 200 + status=failed
A successful query can still return HTTP 200 when the video task is failed. In
that case, error contains a dynamic message from the model provider; ordinary
task failures do not have a stable code:
Last updated: 2026-09-01