[Integrations](https://spiral.ai/integrations) › [Codex](https://spiral.ai/integrations/codex) › [H3 Max Extend Video](https://spiral.ai/integrations/codex/h3-max-extend-video)

# How to Use H3 Max Extend Video in Codex

H3 Max Extend Video adds a directed next action to footage you already have. Use it to finish a scene or lengthen a shot, with output up to 2K.

|  |  |
| --- | --- |
| Model | H3 Max Extend Video |
| Available through | fal |
| Category | Video |
| Price | Up to $10.943504 per run at the default inputs for 60 seconds of input. `resolution`: 480P $10.748504, 768P (default) $10.943504, 1080P $11.463504, 2K $12.503504. $26.00 per 1M input tokens. |
| Returns | video |
| Runs | In the background |
| Setup | About 2 minutes, no API key |

## Prompts to try with H3 Max Extend Video in Codex

- Use H3 Max Extend Video on public/videos/product-reveal.mp4 to add 5 seconds: the product finishes its turn, then holds still as the camera settles. Save the result as a new asset.
- Use H3 Max Extend Video to continue assets/teaser.mp4 for 5 seconds: the character reaches the doorway and pauses with one hand on the handle. Keep the next action to this single beat.
- Use H3 Max Extend Video on public/videos/coast.mp4 to add 5 seconds of waves rolling toward shore while the camera continues its existing movement. Request 2K output.
- Use H3 Max Extend Video to make two endings for assets/cyclist.mp4, adding 5 seconds each. In one, the cyclist stops beside the gate; in the other, the cyclist rides through it. Save both for review.
- Use H3 Max Extend Video on assets/closing-shot.mp4 to add 5 seconds of the subject walking away. Request the separate continuation and account for its 1.625-second repeated opening when adding it to the project timeline.

## How to set up H3 Max Extend Video in Codex

Pick the way that suits you. Each takes about two minutes.

### Use Spiral's MCP server

1. **Add the hosted server**

```bash
codex mcp add spiral --url https://api.spiral.ai/mcp
```

2. **Sign in**: Codex opens the browser: sign in to Spiral and click Authorize. No API key. `codex mcp list` then shows Spiral.

```bash
codex mcp login spiral
```

### Use the Spiral skill

1. **Send Codex this message**: Your agent reads Spiral's skill and sets itself up.

```
set up https://spiral.ai/SKILL.md
```

2. **Sign in or paste a key**: Approve Spiral in the browser, or give the agent a key from the console.

### Use the Spiral CLI

1. **Install and sign in**: Installs the Spiral CLI, signs you in and adds its skill to your coding agents.

```bash
npx -y spiral-cli@latest init
```

### Call the Spiral API

1. **Create an API key**: In the console, under API keys.

2. **Run H3 Max Extend Video**: One request; the result comes back by polling or a webhook.

```bash
curl https://api.spiral.ai/v1/runs \
  -H "Authorization: Bearer $SPIRAL_API_KEY" \
  -H "Content-Type: application/json" \
  -H "Idempotency-Key: $(uuidgen)" \
  -d '{
    "provider": "fal",
    "model": "minimax/h3-max/extend-video",
    "input": {
      "video_url": "https://storage.googleapis.com/falserverless/example_inputs/flux-3-red-panda.mp4",
      "prompt": "The red panda keeps walking along the log, then looks up at a bird."
    }
  }'
```

Then paste one of the prompts above: Codex finds H3 Max Extend Video on Spiral, shows the price and runs it.

Setup guide in the docs: https://spiral.ai/docs/quickstarts/codex

## H3 Max Extend Video tools and prices

- [H3 Max Extend Video](https://spiral.ai/tools/fal/minimax/h3-max/extend-video) (fal): Up to $10.943504 per run at the default inputs for 60 seconds of input. `resolution`: 480P $10.748504, 768P (default) $10.943504, 1080P $11.463504, 2K $12.503504. $26.00 per 1M input tokens.

## Settings you can ask for

| Setting | Allowed values | Default | Description |
| --- | --- | --- | --- |
| reference_audio_urls |  | — | Optional audio references for the continuation (2–15 seconds each, 15 seconds combined). The full extended video retains its original source soundtrack, and its ending still conditions the transition. These clips guide the newly generated audio instead of using that soundtrack as an audio reference. Assign each clip a role in the prompt, such as 'Audio 1 for the voice' and 'Audio 2 for background music'. |
| enable_prompt_expansion |  | true | Automatically enhance the prompt using the source video to help keep the continuation consistent. May increase processing time. |
| duration | 0.71 to 15 | 5 | Seconds of new footage to add. The continuation clip also includes 1.625 seconds from the source's ending and may be longer because of frame rounding. |
| resolution | 480P, 768P, 1080P, 2K | 768P | Output video resolution. |
| aspect_ratio | auto, 21:9, 16:9, 4:3, 1:1, 3:4, 9:16 | auto | Output aspect ratio. 'auto' follows the source video. Other values crop the video to fit the selected ratio. |
| seed |  | — | Seed for the continuation. Random when omitted. |

## What can you do with H3 Max Extend Video in Codex?

Extend video assets in your project to finish actions or add room at the end of a shot. A coding agent can prepare continuation briefs and account for the repeated opening when assembling the result.

### Finish a product reveal

Continue an existing product shot so the object finishes turning and the camera settles on the final view.

### Complete a character action

Extend a scene so a character reaches the door, sets down an object, or walks out of frame.

### Lengthen scenic footage

Add more footage after a landscape shot, directing the next movement of clouds, water, or the camera.

### Give an ending room to breathe

Continue a closing shot with restrained motion so an editor has more footage beneath narration or end titles.

### Explore alternate scene endings

Start from the same source clip and request different next actions to compare possible endings.

### Continue an animated game teaser

Extend existing teaser footage with another short action, such as a character reaching a checkpoint or approaching a doorway.

## Overview

- [fal](https://spiral.ai/providers/fal)
- [All Codex guides](https://spiral.ai/integrations/codex)

## H3 Max Extend Video in other agents

- [Amp](https://spiral.ai/integrations/amp/h3-max-extend-video)
- [ChatGPT](https://spiral.ai/integrations/chatgpt/h3-max-extend-video)
- [Claude](https://spiral.ai/integrations/claude-desktop/h3-max-extend-video)
- [Claude Code](https://spiral.ai/integrations/claude-code/h3-max-extend-video)
- [Cline](https://spiral.ai/integrations/cline/h3-max-extend-video)
- [Cursor](https://spiral.ai/integrations/cursor/h3-max-extend-video)
- [Devin](https://spiral.ai/integrations/devin/h3-max-extend-video)
- [dots](https://spiral.ai/integrations/dots/h3-max-extend-video)
- [Factory Droid](https://spiral.ai/integrations/factory-droid/h3-max-extend-video)
- [Gemini](https://spiral.ai/integrations/gemini/h3-max-extend-video)
- [Gemini CLI](https://spiral.ai/integrations/gemini-cli/h3-max-extend-video)
- [Google Antigravity](https://spiral.ai/integrations/antigravity/h3-max-extend-video)
- [goose](https://spiral.ai/integrations/goose/h3-max-extend-video)
- [Grok](https://spiral.ai/integrations/grok/h3-max-extend-video)
- [Grok Build](https://spiral.ai/integrations/grok-build/h3-max-extend-video)
- [Hermes](https://spiral.ai/integrations/hermes/h3-max-extend-video)
- [Instinct](https://spiral.ai/integrations/instinct/h3-max-extend-video)
- [Manus](https://spiral.ai/integrations/manus/h3-max-extend-video)
- [Muse](https://spiral.ai/integrations/muse/h3-max-extend-video)
- [Muse Code](https://spiral.ai/integrations/muse-code/h3-max-extend-video)
- [n8n](https://spiral.ai/integrations/n8n/h3-max-extend-video)
- [Notion](https://spiral.ai/integrations/notion/h3-max-extend-video)
- [OpenClaw](https://spiral.ai/integrations/openclaw/h3-max-extend-video)
- [opencode](https://spiral.ai/integrations/opencode/h3-max-extend-video)
- [Perplexity](https://spiral.ai/integrations/perplexity/h3-max-extend-video)
- [Raycast](https://spiral.ai/integrations/raycast/h3-max-extend-video)
- [VS Code](https://spiral.ai/integrations/vscode/h3-max-extend-video)
- [Windsurf](https://spiral.ai/integrations/windsurf/h3-max-extend-video)
- [Zapier](https://spiral.ai/integrations/zapier/h3-max-extend-video)

## More Codex guides

- [H3 Max Camera Controls](https://spiral.ai/integrations/codex/h3-max-camera-controls)
- [H3 Max Image to Video](https://spiral.ai/integrations/codex/h3-max-image-to-video)
- [H3 Max 3D to Video](https://spiral.ai/integrations/codex/h3-max-3d-to-video)
- [H3 Max Lip Sync](https://spiral.ai/integrations/codex/h3-max-lip-sync)
- [Grok Imagine Video 1.5 Text to Video](https://spiral.ai/integrations/codex/grok-imagine-video-1-5-text-to-video)
- [H3 Max Reference to Video](https://spiral.ai/integrations/codex/h3-max-reference-to-video)

## Questions about H3 Max Extend Video in Codex

**Can Codex use H3 Max Extend Video?**

Yes. Add Spiral to Codex as an MCP server, and Codex can find and run H3 Max Extend Video like any built-in tool.

**How much does H3 Max Extend Video cost in Codex?**

Up to $10.943504 per run at the default inputs for 60 seconds of input. `resolution`: 480P $10.748504, 768P (default) $10.943504, 1080P $11.463504, 2K $12.503504. $26.00 per 1M input tokens. You pay from your Spiral balance as you go, with no subscription, and a failed run is not charged. Your Codex plan is separate.

**Do I need a fal account to use H3 Max Extend Video in Codex?**

No. Spiral runs H3 Max Extend Video on its own fal account. You sign in to Spiral once and never paste a key.

**How long does it take to set up H3 Max Extend Video in Codex?**

About two minutes: add the hosted server, then sign in.

**Does Codex wait while H3 Max Extend Video runs?**

H3 Max Extend Video runs in the background. Codex starts the run, checks on it and gives you the video when it's ready.

**What is H3 Max Extend Video useful for?**

Use it when existing footage needs another action or a longer ending. Examples include letting a subject leave the frame, finishing a camera move, or giving a product shot more time.

**Can H3 Max Extend Video start from text alone?**

It needs an existing video to continue. The text directs the footage added after that video.

**How should I write a continuation prompt?**

Describe the next action instead of retelling the source video. For example: 'The cyclist keeps moving forward, brakes beside the gate, and puts one foot on the ground.'

**Does the separate continuation clip contain any original footage?**

Yes. It starts with 1.625 seconds repeated from the source ending, so account for that overlap when placing it after the original in an editor.

**How high can the output resolution go?**

H3 Max Extend Video supports output up to 2K. Its supported resolution range starts at 480p.

