# MiniMax H3 AI Video Generator: Text to Video, Image to Video (`deapi/minimax-video-generator`) Actor

Generate realistic AI videos with sound with MiniMax H3: text to video, image to video, and reference-to-video that keeps your product or character from up to 2 images. 5 or 10 s, HD or SD, 16:9, 9:16 or 1:1 MP4. From $0.144 per video.

- **URL**: https://apify.com/deapi/minimax-video-generator.md
- **Developed by:** [deAPI](https://apify.com/deapi) (community)
- **Categories:** AI, Videos, Social media
- **Stats:** 1 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $205.00 / 1,000 5-second hd ai videos

This Actor is paid per event. You are not charged for the Apify platform usage, but only a fixed price for specific events.

Learn more: https://docs.apify.com/actors/running/actors-in-store.md#pay-per-event

## What's an Apify Actor?

An Actor is a serverless cloud program that runs on the Apify platform. It has two run modes.
In Batch mode, an Actor accepts a well-defined JSON input, performs an action which can take anything from a few seconds to a few hours,
and optionally produces a well-defined JSON output, datasets with results, or files in key-value store.
In Standby mode, an Actor provides a web server which can be used as a website, API, or an MCP server.

Apify vocabulary and the platform model are defined once, in the agent quickstart at https://apify.com/agents.md.

## How to integrate an Actor?

If asked about integration, you help developers integrate Actors into their projects.
You adapt to their stack and deliver integrations that are safe, well-documented, and production-ready.

Do not guess an integration path. Every one of them is in the agent quickstart at https://apify.com/agents.md: the Apify MCP server, Agent Skills with the Apify CLI, the JavaScript and Python clients, the REST API, and the account-free path for an agent with no human to sign in. It also carries the rule on stating cost before the first paid run.

For examples already wired to this Actor's own input schema, see the [API](#api) section below.

Each client library has reference documentation the quickstart does not restate: [JavaScript/TypeScript](https://docs.apify.com/api/client/js/docs.md) (`npm install apify-client`) and [Python](https://docs.apify.com/api/client/python/docs.md) (`pip install apify-client`).

# README

## MiniMax H3 AI Video Generator: Text to Video, Image to Video

**Generate realistic AI videos with sound** with **MiniMax H3**, from a text prompt, from a photo, or from up to **2 reference images** of your product or character. You get a 5- or 10-second **MP4 with audio** in 16:9, 9:16 or 1:1, in **HD (1344 × 768)** or SD. It is a **text to video and image to video API** you can call from the Console, Python, JavaScript, Make, Zapier or n8n, with no GPU, no AI provider account and no subscription. It costs **$0.205 per 5-second HD video** ($0.133 in SD), about a third less than MiniMax elsewhere on Apify, and videos stopped before generation starts cost nothing.

**deAPI AI tools**

- Need cheaper clips, or a free try? → [LTX-2.5 AI Video Generator: Text to Video & Image to Video](https://apify.com/deapi/ltx-video-generator)
- Need a clean product cutout first? → [AI Background Remover API: Remove BG to Transparent PNG](https://apify.com/deapi/background-remover)
- Photos too small? → [AI Image Upscaler 4x: Upscale Images to 4K & 8K in Bulk](https://apify.com/deapi/image-upscaler-4x)

### What does MiniMax H3 AI Video Generator do?

It is an **AI video generator** built on the MiniMax H3 video model, known for lifelike motion and detail. For each video you ask for, the Actor:

1. Reads your prompt, and downloads and checks your images if you gave any.
2. Has MiniMax H3 generate the video, **picture and sound together**, at 24 frames per second.
3. Saves the MP4 to your Apify storage. It comes back as a download link with its resolution, length, seed and what was billed.

There are three modes:

- **Text to video.** You describe the scene and the model invents it.
- **Image to video.** Your picture becomes the first frame and the prompt says how it moves. You can also give an end frame, and the video moves from one picture to the other.
- **Reference to video.** Give up to 2 pictures, for example a product and a person, or a character and a place. The model keeps them recognizable in a new scene that you describe with `<Picture 1>` and `<Picture 2>`.

### Why use it?

- **Realistic motion and detail.** MiniMax H3 handles people, animals and products with lifelike movement.
- **Keep your product or character.** Reference to video puts the same mug, sneaker or mascot into any scene, which suits ads and product videos.
- **Video with sound.** Ambience, effects and music are generated with the picture.
- **HD or SD.** HD for final videos; SD costs about 35 % less, for drafts and tests.
- **Every format for social.** 16:9 for YouTube, 9:16 for TikTok, Reels and Shorts, and 1:1 for feeds.
- **Batch up to 10 videos per run**, each with its own prompt, images and settings.
- **Pay per video, no subscription.** You pay when a video starts generating; inputs refused before that cost nothing.

### What data can you get?

| Data | Details |
|---|---|
| 🎬 **Video** | A download link (`videoUrl`) to the MP4 in your run's key-value store. |
| 📐 **Format** | `quality`, `aspectRatio`, `width`, `height`, `durationSeconds`, `fps`. |
| 🔊 **Sound** | `hasAudio`: whether the file has a sound track. |
| 🎲 **Seed** | The seed used, so you can reproduce the video. |
| 🧭 **Mode** | `text-to-video`, `image-to-video` or `reference-to-video`, plus the image links you gave. |
| 💵 **Billing** | `billedEvent`: the charge for this video. |

### How to generate a video with MiniMax H3

1. Open the Actor and write a **prompt**: the subject, what happens, the setting, the camera and the light.
2. Optionally add a **start image** to animate a picture, or **reference images** to keep a product or character.
3. Pick the **quality** (HD or SD), the **duration** (5 or 10 s) and the **aspect ratio**.
4. Click **Start**. A 5-second HD video usually takes about one minute.
5. Open the **Output** tab and download the MP4.

#### Writing a good prompt

- **Describe one shot**, not a story: "a red fox trotting through fresh snow in a pine forest at sunrise".
- **Name the camera**: "slow push in", "the camera orbits the product", "aerial drone shot".
- **Name the light and the mood**: "soft golden light", "neon reflections on wet asphalt".
- **With reference images**, say what each picture does: "`<Picture 1>` standing on a wooden table in a cozy cafe, rain on the window".

#### Sizes and lengths

| Aspect ratio | HD | SD | For |
|---|---|---|---|
| 16:9 | 1344 × 768 | 896 × 512 | YouTube, websites, presentations |
| 9:16 | 768 × 1344 | 512 × 896 | TikTok, Instagram Reels, YouTube Shorts |
| 1:1 | 992 × 992 | 640 × 640 | Instagram and Facebook feeds |

Videos are **5 or 10 seconds** at 24 fps, with sound, in H.264 MP4. **Auto** takes the shape of your start (or first reference) image, or 16:9 for text to video.

#### How fast is it?

In our tests a 5-second HD video took about **70 s**, a 5-second SD video **35–50 s**, and a 10-second HD video **about 2.5 minutes**. A run keeps two videos in progress at a time. When many people generate at once, a video can wait in a queue first.

### Input

| Field | Type | Description |
|---|---|---|
| `prompt` | string | What the video shows. Up to 2,500 characters. |
| `imageUrl` | string | Optional start image (image to video): JPG, PNG or WebP, at least 64 px a side, up to 25 MB. |
| `lastFrameUrl` | string | Optional end image, with a start image only. |
| `referenceImageUrls` | array | Optional, instead of a start image: up to 2 reference pictures, `<Picture 1>` and `<Picture 2>` in the prompt. |
| `quality` | `hd` / `sd` | Default `hd`. |
| `duration` | `"5"` / `"10"` | Length in seconds. Default `"5"`. |
| `aspectRatio` | `auto` / `16:9` / `9:16` / `1:1` | Default `auto`. |
| `seed` | integer | Optional, for a reproducible video. |
| `videos` | array | Optional batch: up to 10 objects with `prompt` and any of the fields above. |

```json
{
    "videos": [
        {"prompt": "<Picture 1> on a marble kitchen counter, morning light, the camera slowly orbits", "referenceImageUrls": ["https://example.com/product.jpg"]},
        {"prompt": "Steam rising from the coffee mug, slow push in", "imageUrl": "https://example.com/mug.jpg"},
        {"prompt": "Waves rolling onto a beach at dusk, aerial shot", "duration": "10", "aspectRatio": "9:16", "quality": "sd"}
    ]
}
```

### Output

One row per video, in the order of the input:

```json
{
    "prompt": "<Picture 1> standing on a wooden table in a cozy cafe, rain on the window behind, the camera slowly orbits the mug",
    "mode": "reference-to-video",
    "referenceImageUrls": ["https://upload.wikimedia.org/wikipedia/commons/thumb/1/1f/Coffee_Mug_%28Unsplash%29.jpg/1280px-Coffee_Mug_%28Unsplash%29.jpg"],
    "status": "success",
    "videoUrl": "https://api.apify.com/v2/key-value-stores/.../records/01-picture-1-standing-on-a-wooden-table-in-a-cozy-caf.mp4",
    "kvsKey": "01-picture-1-standing-on-a-wooden-table-in-a-cozy-caf.mp4",
    "model": "MiniMax H3",
    "quality": "sd",
    "aspectRatio": "16:9",
    "width": 896,
    "height": 512,
    "durationSeconds": 5.21,
    "fps": 24,
    "hasAudio": true,
    "seed": 11,
    "fileMB": 0.54,
    "generationSeconds": 47,
    "billedEvent": "video-sd-5s",
    "error": null
}
```

A video that could not be made has `"status": "failed"` and an `error` that says why. One that was left out, for example by the per-run limit, has `"status": "skipped"` and is not charged. A video whose generation had already started is charged even if it then fails; its `error` says so.

### How much does it cost?

You pay per video delivered. There is no subscription and no minimum.

| Video | HD | SD |
|---|---|---|
| 5 seconds | **$0.205** | **$0.133** |
| 10 seconds | **$0.312** | **$0.204** |

- Text to video, image to video and reference to video cost the same.
- For comparison, other MiniMax video Actors on Apify charge about $0.30 per 5 seconds.
- You pay when a video starts generating. Anything stopped before that is free: an image that can't be used, a prompt refused on submit, a free-plan or per-run limit, or your budget. Once generation has started the video is charged, even if you abort the run.
- **This Actor runs on paid Apify plans only.** To try AI video for free, use the [LTX-2.5 AI Video Generator](https://apify.com/deapi/ltx-video-generator).
- At most 10 videos per run.

### Use cases

- **Product videos and ads**: put your product into any scene with reference images, in 9:16 for social ads.
- **Social media content**: realistic vertical clips for TikTok, Reels and Shorts.
- **Character consistency**: the same mascot or character across a series of clips.
- **Animate photos**: bring product shots, portraits and landscapes to life.
- **Automated pipelines**: write prompts with an LLM, then generate videos in bulk through the API.

### Tutorial: generate videos with the API

#### 1. One video in the Console

Write a prompt, click **Start**, and download the MP4 from the **Output** tab.

#### 2. A product video from reference images

Add a product photo to **Reference images** and write a prompt such as "`<Picture 1>` on a marble kitchen counter, morning light, the camera slowly orbits".

#### 3. From Python

```python
from apify_client import ApifyClient

client = ApifyClient("<YOUR_APIFY_TOKEN>")
run = client.actor("deapi/minimax-video-generator").call(run_input={
    "prompt": "<Picture 1> on a marble kitchen counter, morning light, the camera slowly orbits",
    "referenceImageUrls": ["https://example.com/product.jpg"],
    "quality": "hd",
    "aspectRatio": "9:16",
})
for item in client.dataset(run["defaultDatasetId"]).iterate_items():
    print(item["status"], item.get("videoUrl"), item.get("error"))
```

#### 4. From JavaScript or cURL

```javascript
import { ApifyClient } from 'apify-client';

const client = new ApifyClient({ token: '<YOUR_APIFY_TOKEN>' });
const run = await client.actor('deapi/minimax-video-generator').call({
    prompt: 'A golden retriever running through a sunflower field, slow motion, warm light',
    duration: '10',
});
const { items } = await client.dataset(run.defaultDatasetId).listItems();
console.log(items[0].videoUrl);
```

```bash
curl -X POST "https://api.apify.com/v2/acts/deapi~minimax-video-generator/run-sync-get-dataset-items?token=<YOUR_APIFY_TOKEN>" \
  -H "Content-Type: application/json" \
  -d '{"prompt": "Waves rolling onto a beach at dusk, aerial shot", "quality": "sd"}'
```

### MiniMax video API and integrations

Run it from **Make**, **Zapier**, **n8n** or a webhook, or chain it after another Actor: write prompts with an LLM, or animate the product images another Actor collected. The MP4 links in the dataset can be downloaded by any tool. The [Apify API](https://docs.apify.com/api/v2) and the [Python](https://docs.apify.com/api/client/python) and [JavaScript](https://docs.apify.com/api/client/js) clients work with it as they do with any Actor.

### FAQ

#### How do I make a video with MiniMax?

Write a prompt, optionally add a start image or reference images, pick HD or SD, 5 or 10 seconds and an aspect ratio, and click Start. The MP4 is in the Output tab after a minute or two.

#### What is reference to video?

You give the model up to 2 pictures and it keeps what they show, such as a product, a character or a place, in a new scene. Address them in the prompt as `<Picture 1>` and `<Picture 2>`, in the order you listed them.

#### How do I turn a picture into a video?

Paste a direct link to the picture in **Start image URL** and describe how it moves. The picture becomes the first frame of the video.

#### Does the video have sound?

Yes. MiniMax H3 generates the sound with the picture: ambience, effects and music that fit the scene.

#### How much does a MiniMax video cost?

$0.205 for 5 seconds and $0.312 for 10 seconds in HD; $0.133 and $0.204 in SD. Videos stopped before generation starts cost nothing.

#### Is there a free trial?

This Actor runs on paid Apify plans only, because every video is expensive to generate. The [LTX-2.5 AI Video Generator](https://apify.com/deapi/ltx-video-generator) has a small free allowance on the free plan.

#### Do I need an API key or a GPU?

No. You need only an Apify account on a paid plan. The Actor runs the model for you.

#### MiniMax H3 or LTX-2.5?

**MiniMax H3** gives more realistic motion and detail, and keeps products and characters consistent from reference images. **[LTX-2.5](https://apify.com/deapi/ltx-video-generator)** is about half the price and has a small free allowance, good for drafts, B-roll and social clips.

#### Can I make vertical videos for TikTok and Reels?

Yes. Set the aspect ratio to **9:16** for a 768 × 1344 HD or 512 × 896 SD video.

#### Can I use the videos commercially?

The videos are yours to use. Check that your prompt and images don't copy someone else's brand, character or likeness.

#### What content is not allowed?

Don't ask for sexual content, graphic violence or videos of real public figures. Such prompts may be refused; a prompt refused before generation starts is not charged.

#### How long are the videos kept?

In your run's key-value store, for your Apify plan's data retention period. Download the files you want to keep.

#### Can I make several videos at once?

Yes. Put up to 10 objects in **Batch of videos**, each with its own prompt, images and settings. A batch of 10 takes roughly 12 minutes (5 s HD) to 25 minutes (10 s HD). For more, start several runs.

#### Can I make a 30-second or 1-minute AI video?

Not in one clip: each video is 5 or 10 seconds. Generate several clips and join them in any video editor; reference images help keep the product or character the same across clips.

#### What resolution are the videos? Is it 1080p or 4K?

HD is 1344 × 768 (16:9), 768 × 1344 (9:16) or 992 × 992 (1:1); SD is 896 × 512, 512 × 896 or 640 × 640. All at 24 fps. There is no watermark.

#### Can I add my own voiceover or music?

No. The sound is generated with the picture; you can steer it in the prompt. Add your own audio in a video editor.

#### Is it an alternative to Kling, Runway, Sora or Veo?

For short clips, yes: you pay per video with no subscription, and you can call it as an API. Those tools offer longer videos and editing features this Actor does not have.

#### Can I use it from ChatGPT, Claude or another AI agent?

Yes. Every Apify Actor is available through the Apify MCP server, so an AI agent can generate videos with it.

#### Why did a video fail?

The `error` field says why: an image that could not be downloaded or read, a reference picture that was too long and thin (over 4:1), a prompt that was refused, or a service that was busy. A video that failed before its generation started is not charged; one that failed after is, and the error says which.

### Support / feedback

Found a problem or need a feature? Open an issue on the **Issues** tab. We usually answer within a day.

# Actor input Schema

## `prompt` (type: `string`):

Describe the video: the subject, what happens, the setting, the camera and the light. English works best. Sound (ambience, effects, music) is generated with the picture. With reference images, address them as `<Picture 1>` and `<Picture 2>`. Up to 2,500 characters. To make several videos in one run, use **Batch of videos** below instead.

## `imageUrl` (type: `string`):

Optional. A direct link to a JPG, PNG or WebP picture that becomes the **first frame** of the video (image to video): the prompt then describes how it moves. Leave empty for text to video. At least 64 px a side, up to 25 MB.

## `lastFrameUrl` (type: `string`):

Optional, with a start image only (not with reference images). A picture the video should end on, for a transition between two frames.

## `referenceImageUrls` (type: `array`):

Optional, instead of a start image. Up to **2** pictures of a product, a character or a place that the video should keep, in a new scene. Address them in the prompt in order: `<Picture 1>`, `<Picture 2>` — for example `<Picture 1> walks into the cafe from <Picture 2>`. Each picture must be no more than 4 times longer than it is wide.

## `quality` (type: `string`):

Resolution of the video. HD is 1344 x 768 (768 x 1344 vertical, 992 x 992 square); SD is 896 x 512 (512 x 896, 640 x 640).

## `duration` (type: `string`):

Length of each video. 24 frames per second, with sound.

## `aspectRatio` (type: `string`):

Shape of the video; the resolution depends on Quality.

## `seed` (type: `integer`):

Optional. The same prompt, settings and seed give the same video again. Leave empty for a random seed; the seed used is in the output.

## `videos` (type: `array`):

Optional. Up to **10 videos per run**, each an object with `prompt` and optionally `imageUrl`, `lastFrameUrl`, `referenceImageUrls`, `quality`, `duration`, `aspectRatio` and `seed` (the settings above are the defaults). When this list is filled, the single prompt above is ignored. Example: `[{"prompt": "A paper boat drifting down a rainy street"}, {"prompt": "Waves at dusk", "duration": "10"}]`. **Paid Apify plans only; to try AI video for free, use the LTX-2.5 AI Video Generator.**

## Actor input object example

```json
{
  "prompt": "A red fox trotting through fresh snow in a pine forest at sunrise, cinematic tracking shot, soft golden light, snow crunching underfoot",
  "quality": "hd",
  "duration": "5",
  "aspectRatio": "auto"
}
```

# Actor output Schema

## `videos` (type: `string`):

One row per requested video: a download link to the MP4 (videoUrl), the prompt, mode (text-to-video or image-to-video), aspect ratio, resolution, length, whether it has sound, the seed and file size, and what was billed. Videos that could not be made carry status 'failed' with an 'error' field; they are charged only if their generation had already started, and the error says so. Videos left out by a free-plan allowance, the per-run limit or a run cost limit carry status 'skipped' and are not charged.

## `files` (type: `string`):

The MP4 videos, stored in the run's key-value store under keys like 01-a-red-fox-trotting-through-fresh-snow.mp4.

# API

You can run this Actor programmatically using our API. Below are code examples in JavaScript, Python, and CLI, as well as the OpenAPI specification and MCP server setup.

## JavaScript example

```javascript
import { ApifyClient } from 'apify-client';

// Initialize the ApifyClient with your Apify API token
// Replace the '<YOUR_API_TOKEN>' with your token
const client = new ApifyClient({
    token: '<YOUR_API_TOKEN>',
});

// Prepare Actor input
const input = {
    "prompt": "A red fox trotting through fresh snow in a pine forest at sunrise, cinematic tracking shot, soft golden light, snow crunching underfoot"
};

// Run the Actor and wait for it to finish
const run = await client.actor("deapi/minimax-video-generator").call(input);

// Fetch and print Actor results from the run's dataset (if any)
console.log('Results from dataset');
console.log(`💾 Check your data here: https://console.apify.com/storage/datasets/${run.defaultDatasetId}`);
const { items } = await client.dataset(run.defaultDatasetId).listItems();
items.forEach((item) => {
    console.dir(item);
});

// 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/js/docs

```

## Python example

```python
from apify_client import ApifyClient

# Initialize the ApifyClient with your Apify API token
# Replace '<YOUR_API_TOKEN>' with your token.
client = ApifyClient("<YOUR_API_TOKEN>")

# Prepare the Actor input
run_input = { "prompt": "A red fox trotting through fresh snow in a pine forest at sunrise, cinematic tracking shot, soft golden light, snow crunching underfoot" }

# Run the Actor and wait for it to finish
run = client.actor("deapi/minimax-video-generator").call(run_input=run_input)

# Fetch and print Actor results from the run's dataset (if there are any)
print(f"💾 Check your data here: https://console.apify.com/storage/datasets/{run.default_dataset_id}")
for item in client.dataset(run.default_dataset_id).iterate_items():
    print(item)

# 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/python/docs/quick-start

```

## CLI example

```bash
echo '{
  "prompt": "A red fox trotting through fresh snow in a pine forest at sunrise, cinematic tracking shot, soft golden light, snow crunching underfoot"
}' |
apify call deapi/minimax-video-generator --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,deapi/minimax-video-generator"
        }
    }
}
```

The hosted server signs you in with OAuth on first connect, so no API token belongs in this config. Clients without OAuth support can send an `Authorization: Bearer <APIFY_API_TOKEN>` header instead, using a token from API & Integrations in Apify Console (https://console.apify.com/settings/integrations).

## OpenAPI specification

Download the OpenAPI definition: https://api.apify.com/v2/actors/RW0JFb20wDFtc6qkU/builds/DixtKTm7kmJGcorHV/openapi.json
