> ## Documentation Index
> Fetch the complete documentation index at: https://developers.apob.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# Extend a video

> Continue existing footage with a prompt, an extension duration, and optional end-frame or voice references.

`extendVideoSimplify` returns `Content!` for an asynchronous video extension.
Use [API key authentication](/api-reference/authentication), a ready image
model, and an accessible source video.

## Submit an extension

```graphql ExtendVideo theme={null}
mutation ExtendVideo($metadata: SimpleExtendVideoContentMetadata!) {
  extendVideoSimplify(metadata: $metadata) {
    id
    task {
      id
      status
      progress { finishCode }
    }
  }
}
```

```json Variables theme={null}
{
  "metadata": {
    "modelId": "<IMAGE_MODEL_ID>",
    "srcVideoMediaId": "<VIDEO_MEDIA_ID>",
    "inputPrompt": "Continue the walk and camera movement into the courtyard, preserving the subject and lighting.",
    "extendDurationInMilliseconds": 5000,
    "outputQuality": "ultra",
    "resolution": "FHD"
  }
}
```

## Metadata

| Field | Type / default | Meaning |
| - | - | - |
| `modelId` | `ID!` | Required image model ID. |
| `srcVideoMediaId` | `ID` | Existing video source. Supply a source through this or an accepted uploaded/remix input. |
| `inputVideo` | `UploadedVideoFileInput` | Uploaded video alternative. |
| `remixVideo` | `RemixUploadedVideoFileInput` | Remix video alternative. |
| `inputPrompt` | `String` | Continuation, camera, scene, and dialogue instructions. |
| `extendDurationInMilliseconds` | `Long`, `5000` when omitted | Duration of the added footage, in milliseconds. |
| `outputQuality` | `OutputQuality!`, `high` | `high`, `ultra`, or `ultraS`; `best` is unsupported. |
| `resolution` | `VideoResolution` | Optional target resolution; `UHD` requires `ultra` or `ultraS`. |
| `endImageMediaId` | `ID` | Existing end-frame image where supported. |
| `inputEndImage` | `UploadedImageFileInput` | Uploaded end-frame alternative. |
| `remixEndImage` | `RemixUploadedImageFileInput` | Remix end-frame alternative. |
| `multiShotPrompt` | `[SingleShotPrompt!]` | Structured shot prompts where supported. |
| `elementIds` | `[ID!]` | Additional permitted visual or audio references. |
| `enableBgm` | `Boolean!`, `false` | Request background audio where supported. |
| `voiceModelId` | `ID` | A selected reference voice. |
| `voiceModelIds` | `[ID!]` | Additional ordered reference voices where supported. |

The extension duration is additional footage, not the source video's duration.
Check the final output's duration after completion. Quality, duration, source
properties, and reference choices must form a supported combination.

Write dialogue in `inputPrompt` or shot prompts with the
[voice-section notation](/api-reference/image-to-video#dialogue-and-voice-references).
Voice selection and prompt dialogue are separate inputs.
Choose `ultra` or `ultraS` for selected voice references; `high` does not support
nonempty `voiceModelId` or `voiceModelIds` selections.

Save the returned content and task IDs. Poll the existing content using
[tasks and results](/api-reference/tasks-and-results); do not submit another
extension merely because the first request timed out.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.