minimax-h3 model, supporting text-to-video, first-frame, last-frame, first-and-last-frame, and image, video, and audio references. All outputs render at 768P for 1–15 seconds and are billed per output second.768P, 16:9 video:id field in the response is your video task ID:{
"id": "task_xxxxxxxxxxxxxxxxxxxxxxxx",
"object": "video",
"model": "minimax-h3",
"status": "queued",
"progress": 0
}metadata.url or download via the content endpoint as described in "Retrieving Results" below.| Parameter | Type | Required | Description |
|---|---|---|---|
prompt | string | Yes | Describes the scene, subjects, motion, camera work, and visual style. When using reference assets, cite them with tags such as <Picture 1> (see below). |
model | string | Yes | Set to minimax-h3. |
duration | integer | Yes | Video duration in integer seconds (1–15). |
resolution | string | Yes | Must be 768P. |
ratio | string | Yes | Aspect ratio; see allowed values below. |
ref | object[] | No | First/last frames or reference assets; see rules below. |
prompt_optimizer | boolean | No | When true, rewrites the prompt into H3's recommended format before generation. Defaults to false (no rewriting). |
400.ratio | Output Dimensions |
|---|---|
21:9 | 1536×672 |
16:9 | 1344×768 |
4:3 | 1024×768 |
1:1 | 768×768 |
3:4 | 768×1024 |
9:16 | 768×1344 |
adaptive | Automatically determined from the input asset's aspect ratio; available only when passing a first frame, last frame, reference image, or reference video |
ratio is required in every scenario. When passing only reference audio (without any image or video), you must specify a fixed aspect ratio rather than adaptive.| Scenario | duration | ref |
|---|---|---|
| Text-to-video | 1–15 | Omit or pass an empty array |
| First / last / first-and-last frame | 1–15 | 1 first frame, 1 last frame, or first frame followed by last frame |
| Multimodal reference | 1–15 | Reference images, videos, and audio clips used individually or in combination |
resolution other than 768P or a duration outside 1–15 immediately returns a 400 parameter error.ref array.ref Format{
"url": "https://example.com/reference.jpg",
"type": "image",
"role": "reference_image"
}| Field | Type | Required | Description |
|---|---|---|---|
url | string | Yes | Publicly accessible HTTPS media file URL. Base64 and data URIs are not supported. |
type | string | Yes | Asset type: image, video, or audio. |
role | string | By scenario | Allowed values are listed below; when omitted for general reference assets, inferred from type. |
type | role | Purpose |
|---|---|---|
image | first_frame | Video opening frame; place as the first item in ref when paired with a last frame. |
image | last_frame | Video closing frame; can be used alone or paired with first_frame (place as the second item). |
image | reference_image | Reference for character, scene, object, or style. |
video | reference_video | Reference for motion, camera work, or pacing. |
audio | reference_audio | Reference for voice, timbre, rhythm, or ambience. |
role is omitted, image, video, and audio default to reference_image, reference_video, and reference_audio, respectively—they are never inferred as first_frame or last_frame. Always pass role explicitly when using first or last frames.first_frame and last_frame cannot appear in the same request as any reference_* asset. When using both a first frame and a last frame, their aspect ratios must differ by no more than 2%.ref (images, videos, and audio clips maintain separate counters). Reference them in your prompt with literal tags such as <Picture 1>, <Video 1>, and <Audio 1>, specifying what each asset controls (face, clothing, scene, motion, timbre, etc.):The woman in <Picture 1> walks into the shop in <Picture 2> following the motion in <Video 1>, with voice timbre matching <Audio 1>.ref changes these numbers. Shorthand forms such as 图1 or @图片 (literal Chinese tags used by other models) are not recognized as asset references.| Asset | Per-Request Limit | File Requirements |
|---|---|---|
| First / last frame | 1 first frame, 1 last frame, or first + last frame | Static JPG/JPEG, PNG, WebP, HEIC, or HEIF; max 30 MB per image |
| Reference images | Up to 9 images | Same as above |
| Reference videos | Up to 3 clips | MP4 or MOV (H.264 or H.265, optional AAC/MP3 audio track); max 50 MB per clip |
| Reference audio | Up to 3 clips | WAV, MP3, or M4A/AAC; max 15 MB per clip |
| Total reference assets | Up to 12 items combined | Each item must satisfy the limits for its modality |
failed.{
"prompt": "Keep the character and outfit from the first frame consistent as the subject turns and walks toward the camera while the camera pulls back smoothly",
"model": "minimax-h3",
"duration": 4,
"resolution": "768P",
"ratio": "adaptive",
"ref": [
{ "url": "https://example.com/first-frame.jpg", "type": "image", "role": "first_frame" }
]
}{
"prompt": "Smooth transition from an indoor daytime scene to an urban nightscape with continuous subject motion and a natural camera push-in",
"model": "minimax-h3",
"duration": 6,
"resolution": "768P",
"ratio": "16:9",
"ref": [
{ "url": "https://example.com/first-frame.jpg", "type": "image", "role": "first_frame" },
{ "url": "https://example.com/last-frame.jpg", "type": "image", "role": "last_frame" }
]
}first_frame item from the example above.{
"prompt": "The character in <Picture 1> walks following the motion in <Video 1>, with voice timbre matching <Audio 1>, cinematic short film",
"model": "minimax-h3",
"duration": 8,
"resolution": "768P",
"ratio": "adaptive",
"prompt_optimizer": true,
"ref": [
{ "url": "https://example.com/character.jpg", "type": "image", "role": "reference_image" },
{ "url": "https://example.com/motion.mp4", "type": "video", "role": "reference_video" },
{ "url": "https://example.com/voice.mp3", "type": "audio", "role": "reference_audio" }
]
}GET /v1/videos/{task_id} with the task ID to fetch its latest status.| Status | Description |
|---|---|
queued | Accepted; downloading assets, running moderation, or waiting in queue. |
in_progress | Video generation is in progress. |
completed | Video has been generated. |
failed | Task has ended; read error for details. |
status is completed and metadata.url is non-empty (result_url holds the same value as a fallback).{
"id": "task_xxxxxxxxxxxxxxxxxxxxxxxx",
"status": "completed",
"progress": 100,
"metadata": {
"url": "https://example.com/result.mp4"
}
}metadata.url, or download it via the content endpoint:duration. Result URLs expire—download and save the video promptly upon completion.duration in seconds, with no extra fee for the number of reference assets. Failed tasks (including asset download failures and content moderation rejections) receive a full refund.status, and error.message together.| HTTP Status | Common Cause |
|---|---|
400 | Invalid parameters (e.g., resolution other than 768P, duration outside 1–15, or unsupported fields); querying a non-existent task also returns 400 with code set to task_not_exist |
401 | Missing or invalid API key |
403 | Insufficient balance/quota, or no permission for the requested model |
429 | Rate limit exceeded |
503 | Service temporarily unavailable |
500 / 502 | Transient service error |
failed and reports the cause in error.message:| Cause | Recommended Action |
|---|---|
| Asset download failed or URL unreachable | Confirm the URL is publicly accessible and has not expired |
| Unsupported format or dimensions | Adjust assets per "Count & File Requirements" |
| Invalid reference video or audio duration | Each clip must be at least 2 seconds, and combined duration per modality must not exceed 15 seconds |
| First/last frame aspect ratio mismatch | Ensure the two images differ in aspect ratio by no more than 2% |
| Content moderation rejected | Modify the prompt or input assets and resubmit |
| Service busy | Resubmit later |