Create Video (Wan 3.0)
Generate a video with Wan 3.0, Alibaba’s unified video model. One endpoint covers every mode, chosen by the fields you send:
- Text-to-video:
promptonly. - First/last frame:
start_image_url, optionally withend_image_url(a last frame needs a first frame). - References: up to 10
image_urls, 5video_urlsand 5audio_urlsfor characters, motion, voice or style. Not combinable with keyframes.
Output: one MP4 video of 2 to 30 seconds at 480p, 720p or 1080p (the
short side is 480, 720 or 1080 px, e.g. 854x480 at 16:9), with native
audio by default. The finished task carries the video URL in its
generated array.
Credits: priced per second by resolution. The billed seconds are
duration plus the combined duration of the video_urls, capped at 15
seconds. Images and audios do not change the price.
The request is processed asynchronously: the endpoint returns a task_id
immediately. Retrieve the result by polling
GET /v1/ai/video/wan-3-0/{task-id} or by providing an optional webhook_url.
Authorizations
Your Magnific API key. Required for authentication. Learn how to obtain an API key
Body
Wan 3.0, Alibaba's unified video model. One request covers text-to-video, first/last frame image-to-video and reference-guided generation from images, videos and audios. The mode follows from the fields you send.
References (image_urls, video_urls, audio_urls) and keyframes
(start_image_url, end_image_url) are mutually exclusive: a request
that mixes them is rejected.
Reference videos are billed. The provider charges this model as the output duration PLUS the combined duration of the reference videos, capped at 15 seconds, and that is what the API charges. Reference images and audios add nothing to the price.
Text description of the video to generate, including action and
dialogue. Chinese and English are supported. Refer to references by
their position in each list: "Image 1" is the first item of
image_urls, "Video 1" the first item of video_urls, "Audio 1" the
first item of audio_urls.
1 - 20000"Image 1 walks along a beach at sunset while the waves roll in, saying 'What a day'"
Optional callback URL that will receive asynchronous notifications whenever the task changes status. The payload sent to this URL is the same as the corresponding GET endpoint response, but without the data field.
"https://www.example.com/webhook"
Up to 10 reference images for characters, objects, scenes or style.
Each item is a public HTTPS URL, a base64-encoded image or an upload
id (upl_...). JPEG, PNG (no alpha channel), BMP or WEBP, at most
20 MB, 240 to 8000 px per side, aspect ratio up to 8:1. Mutually
exclusive with start_image_url and end_image_url.
10Up to 5 reference videos for motion, appearance or voice. Each item is
a public HTTPS URL or a video upload id (upl_vid_...). MP4 or MOV,
1 to 15 seconds each and at most 15 seconds combined, at most 100 MB,
240 to 4096 px per side, aspect ratio up to 8:1. The combined
duration plus duration must not exceed 30 seconds. Mutually
exclusive with start_image_url and end_image_url.
These are billed: their combined duration is added to the output duration, capped at 15 seconds.
5Up to 5 reference audios for voice timbre or soundtrack. Each item is
a public HTTPS URL. WAV or MP3, 1 to 15 seconds each and at most 15
seconds combined, at most 15 MB. Mutually exclusive with
start_image_url and end_image_url. Adds nothing to the price.
5Optional first frame of the video. A public HTTPS URL, a base64-encoded
image or an upload id (upl_...). When supplied, the output follows
the aspect ratio of this image and aspect_ratio is ignored. JPEG,
PNG (no alpha channel), BMP or WEBP, at most 20 MB, 240 to 8000 px
per side. Mutually exclusive with every reference field.
"https://example.com/start-frame.jpg"
Optional last frame of the video. Requires start_image_url: the
provider rejects a last frame with no first frame. Same formats and limits as
start_image_url. Mutually exclusive with every reference field.
"https://example.com/end-frame.jpg"
Output video aspect ratio. Defaults to 16:9 when not specified.
Ignored when start_image_url is supplied: the output then follows the
aspect ratio of that image.
16:9: Landscape (widescreen)9:16: Portrait (vertical, mobile-optimized)1:1: Square4:3: Standard landscape3:4: Standard portrait
16:9, 9:16, 1:1, 4:3, 3:4 Output video resolution. It sets the price per second. The value is the short side of the MP4; the long side follows the aspect ratio.
480P: 480p SD (854x480 at 16:9)720P: 720p HD1080P: 1080p Full HD
480P, 720P, 1080P Duration of the output video in seconds. It sets the price together with resolution.
2 <= x <= 305
Whether to generate a synchronized audio track (dialogue, sound effects, music) with the video. It does not affect the price.
true
Random seed for reproducible generation. Fixing it improves reproducibility but does not guarantee identical results.
0 <= x <= 214748364712345
Response
OK - The request has succeeded and the Wan 3.0 process has started.