Given a first frame (optionally a last frame too), generate a video that starts from the first frame and transitions toward the last: the opening frame ≈ first_image, the closing frame ≈ last_image, with a smooth transition in between.
💡 When to use:Use to precisely control the opening frame; add a last frame to also control the ending and produce a transition. Note: first/last-frame mode is mutually exclusive with image_urls / audio_urls / reference_videos — you cannot also pass reference images, audio or reference video; max duration is 10 seconds.
This page has been rewritten for the unified API: create with POST /v1/videos, poll with GET /v1/videos/{id}, authenticate with Authorization: Bearer <key>, errors use the OpenAI format. See the video guide for the common parts. Video guide
Submit task
POST/ v1/ videos
Query Result
GET/ v1/ videos/ {id}
Download the video
GET/ v1/ videos/ {id}/ content
⏱ Recommended polling interval:Creating returns a video object right away (status: queued). Poll GET /v1/videos/{id} until status is completed or failed; when done, url is the result address, and you can also download it with GET /v1/videos/{id}/content.
Authorization
AuthorizationstringheaderRequired
API key, sent as a Bearer token in the Authorization header.
Request body
application/json
modelstring
Fixed minimax-h3
workflow_idstring
Workflow; this page uses fl2v (omit to infer from inputs: first_image->fl2v, image_urls->multi-reference, none->text-to-video; CF super-res / 4-image / flexible-multi-ref / MJ cannot be inferred and must be set explicitly)
promptstringRequired
Required. Text description (the new engine always requires prompt — including image-to-video and first/last-frame, e.g. "gentle camera push-in, soft light")
first_imagestringRequired
First-frame keyframe image URL (required, alias: first_frame_image); first-only pins the opening frame, the model free-runs the ending
last_imagestring
Last-frame keyframe image URL (optional, alias: last_frame_image); must accompany first_image — passing last only returns invalid_request
ratiostring
Aspect ratio, 1 of 8: 16:9 / 9:16 / 1:1 / 4:3 / 3:4 / 3:2 / 2:3 / 21:9, default 16:9 (ratio x resolution tier determine the output size; see the size table)
resolutionstring
Resolution tier (case-insensitive): 480P / 768P / 1080P, default 1080P; the unit price varies by tier — see the pricing page
Prompt enhancement (optional, boolean); defaults to on if omitted
model, prompt, seconds, size and input_reference are the common fields of the unified interface. The other fields in the table are specific to this model channel and go in the same request body under their own names. seconds and size (which must be WIDTHxHEIGHT, for example 1280x720) are only translated into channel fields when you did not send the matching channel field yourself.
Response fields
idstring
Task ID, starts with video_; used to query and download.
objectstring
Always video.
modelstring
The model passed when creating.
statusstring
queued, in_progress, completed or failed.
progressinteger
Progress percent; 100 when done.
created_atinteger
Creation time (Unix seconds).
completed_atinteger | null
Completion time; null until finished.
expires_atinteger | null
Expiry time; currently null.
secondsstring
Returned only if seconds was sent when creating.
sizestring
Returned only if size was sent when creating.
errorobject | null
{code, message} on failure; code is video_generation_failed.
urlstring
Extension field: the result address once completed.