# Muse Video API (https://wanapi.app/docs/muse-video)





Muse Video generates one 720p MP4 clip with synchronized AAC sound from a text prompt and up to 9 optional reference image URLs. Clip duration runs from 10 to 60 seconds in 10-second increments.

[Try the Playground](/models/muse-video#playground) · [OpenAPI JSON](/models/muse-video/openapi.json) · [Integration tutorial](/blog/muse-video-api-guide)

## Authentication and endpoints [#authentication-and-endpoints]

Pass your Wan API customer key as a Bearer token. One key accesses all available models and groups automatically.

| Method | URL                                                       | Purpose                                      |
| ------ | --------------------------------------------------------- | -------------------------------------------- |
| POST   | `https://api.wanapi.app/muse-video/v1/videos/generations` | Submit one Muse Video task                   |
| GET    | `https://api.wanapi.app/muse-video/v1/tasks/{id}`         | Poll that task until `completed` or `failed` |

The model ID is &#x2A;*`muse-video`**. Both endpoints follow an asynchronous task contract: submit the POST payload once, persist the returned `id`, and poll the GET route until the task finishes. Do not automatically repeat a POST request after a client timeout.

## Submit a text-to-video task [#submit-a-text-to-video-task]

```bash
curl https://api.wanapi.app/muse-video/v1/videos/generations \
  -H "Authorization: Bearer $WAN_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "model": "muse-video",
    "prompt": "Slow motion close-up of a ruby-throated hummingbird hovering at a red trumpet flower during light rain, droplets sparkling in soft backlight, gentle camera drift. Natural ambience: rain patter and wing hum. No text.",
    "aspect_ratio": "16:9",
    "duration": 10
  }'
```

An accepted submission returns a processing task immediately rather than video bytes:

```json
{"id":"task_example","model":"muse-video","status":"processing","created_at":1795900800}
```

Poll that `id` every 5 to 10 seconds:

```bash
curl https://api.wanapi.app/muse-video/v1/tasks/task_example \
  -H "Authorization: Bearer $WAN_API_KEY"
```

Keep `task_example` in durable storage if your worker restarts so polling can resume without creating a duplicate task.

## Request parameters [#request-parameters]

| Parameter                     | Type              | Default     | Rules                                                                                                                                                                   |
| ----------------------------- | ----------------- | ----------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `model`                       | string            | required    | Must be `muse-video`.                                                                                                                                                   |
| `prompt`                      | string            | required    | Non-empty string up to 20,000 characters. Required even when `image_urls` is supplied.                                                                                  |
| `image_urls`                  | URL array         | none        | 0 to 9 public `http(s)` URLs (PNG, JPEG or WebP, ≤11 MB combined). Base64, data URIs and file uploads are rejected.                                                     |
| `aspect_ratio`                | string            | auto (omit) | One of `1:1`, `16:9`, `9:16`, `4:3`, `3:4`, `3:2`, `2:3`. Omit the field for auto framing; `"auto"` is rejected here.                                                   |
| `size`                        | string            | none        | Framing alias accepting the 7 ratios above or `"auto"`. Pixel strings such as `1280x720` are rejected. If both `aspect_ratio` and `size` are sent, `aspect_ratio` wins. |
| `duration`                    | integer or string | `10`        | `10`, `20`, `30`, `40`, `50` or `60` (strings such as `"10"` or `"10s"` are also accepted).                                                                             |
| `seconds`, `duration_seconds` | integer or string | none        | Aliases of `duration`. When multiple duration fields are sent together, their resolved values must match.                                                               |
| `resolution`                  | string            | `"720p"`    | Optional; only `"720p"` is accepted. `480p`, `1080p` and `4K` are rejected.                                                                                             |
| `audio`                       | boolean           | `true`      | Optional; only `true` is accepted because every Muse Video output includes native sound.                                                                                |
| `n`                           | integer           | `1`         | Optional; only `1` is accepted.                                                                                                                                         |

Muse Video has no `nsfw_checker`, `content_filter`, `seed`, `first_frame`, `last_frame`, `reference_videos` or `reference_audios` field.

## Reference images and framing rules [#reference-images-and-framing-rules]

Pass 1 to 9 public HTTP(S) URLs in `image_urls` without URL credentials (`user:pass@`), backslashes or login walls. Keep the combined payload of all referenced images within **11 MB** in PNG, JPEG or WebP format.

```json
{
  "model": "muse-video",
  "prompt": "The camera glides slowly along the misty lantern canal between floating market boats, lanterns swaying gently, ripples spreading across the water. Ambient water and soft market chatter. No text.",
  "image_urls": [
    "https://your-cdn.example/canal-source.webp"
  ],
  "duration": 10
}
```

When `image_urls` is non-empty:

* At **10, 30, 40, 50 or 60 seconds**, omitting `aspect_ratio` lets the model select framing automatically from the prompt and source image.
* At **20 seconds**, pass an explicit `aspect_ratio` (for example `"16:9"` or `"9:16"`).

## Completed and failed task responses [#completed-and-failed-task-responses]

When generation finishes, `status` changes to `"completed"` and `output.video_url` points to the stored MP4 clip:

```json
{
  "id": "task_example",
  "model": "muse-video",
  "status": "completed",
  "created_at": 1795900800,
  "finished_at": 1795900894,
  "output": {
    "video_url": "https://media.wanapi.app/flexible/v1/expires/2026-12/20261229T14/wanapi-task_example/video.mp4?token=EXAMPLE&expires=1798552800"
  }
}
```

Download and archive the MP4 if you need permanent retention beyond the signed storage window. Deleting a completed task via `DELETE /v1/tasks/{id}` purges its stored video artifact and CDN cache entry.

If generation fails, `status` is `"failed"` with an `error` object (`code` and `message`), and the reserved quota is refunded automatically.

## Pricing [#pricing]

<MuseVideoModelPricing />

Muse Video is billed strictly by requested clip duration in 10-second steps:

```text
clip cost = (duration / 10) × live 10-second rate
```

Reference images (`image_urls`), aspect ratio choice and native audio do not add extra charges. Submission reserves the exact clip cost using the live gateway tariff snapshot; completion settles that exact amount, and failed tasks refund the reservation in full.

## Errors and retry safety [#errors-and-retry-safety]

Validation errors (`400 invalid_request`), authentication errors (`401`/`403`), insufficient quota (`402 insufficient_balance`) and rate limits (`429 rate_limited`) stop before creating a billable task.

Poll `GET /muse-video/v1/tasks/{id}` safely on transient `429` or `5xx` responses. &#x2A;*Never auto-retry `POST /muse-video/v1/videos/generations`** when a connection drops or returns `submission_unknown`: check Task logs first. Accepted tasks wait for normal upstream completion; if a task receives no normal upstream status or delivery for three continuous hours, it fails and refunds automatically.

See the [Muse Video API tutorial](/blog/muse-video-api-guide) for a complete `curl` + Python polling workflow.
