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

# Wan 2.7 Video LoRA

> Image-to-video API with optional generated sound or supplied audio

## Overview

Wan 2.7 Video LoRA is an asynchronous image-to-video model that animates one starting image and can generate sound or use one supplied audio track.

| Capability | Value                                          |
| ---------- | ---------------------------------------------- |
| Model ID   | `wan-2-7-video-LoRA`                           |
| Mode       | `image-to-video` (required)                    |
| Images     | Exactly 1 first-frame image                    |
| Audio      | Up to 1 optional audio URL                     |
| Duration   | Any integer from `2` through `15` seconds      |
| Resolution | `720p` or `1080p`                              |
| Output     | MP4 video URL array in `resultJson.resultUrls` |

## Endpoint and authentication

Base URL:

```text theme={null}
https://api.apixo.ai/api/v1
```

| Method | Endpoint                                         | Purpose                               |
| ------ | ------------------------------------------------ | ------------------------------------- |
| `POST` | `/generateTask/wan-2-7-video-LoRA`               | Submit an image-to-video task         |
| `GET`  | `/statusTask/wan-2-7-video-LoRA?taskId={taskId}` | Poll task status and retrieve results |

All requests require your APIXO API key:

```http theme={null}
Authorization: Bearer YOUR_API_KEY
```

## Copy-paste async quickstart

```bash theme={null}
curl -X POST "https://api.apixo.ai/api/v1/generateTask/wan-2-7-video-LoRA" \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "request_type": "async",
    "input": {
      "mode": "image-to-video",
      "prompt": "a dancer performs under dramatic stage lighting",
      "image_urls": ["https://example.com/first-frame.png"],
      "sound": true,
      "duration": 8,
      "resolution": "720p",
      "prompt_extend": true
    }
  }'
```

The response contains a `taskId`. Save it and poll the status endpoint until `state` becomes `success` or `failed`.

## Request with supplied audio

When `audio_urls` is present, `sound` must be `true` or omitted.

```json theme={null}
{
  "request_type": "async",
  "input": {
    "mode": "image-to-video",
    "prompt": "subtle natural movement synchronized with the music",
    "negative_prompt": "blurry, unstable motion",
    "image_urls": ["https://example.com/first-frame.png"],
    "audio_urls": ["https://example.com/music.mp3"],
    "sound": true,
    "duration": 10,
    "resolution": "1080p",
    "prompt_extend": true,
    "seed": 12345
  }
}
```

## Parameters

<ParamField body="request_type" type="string" default="async">
  Result delivery mode. Use `async` for polling with `statusTask`, or `callback` for webhook delivery.
</ParamField>

<ParamField body="callback_url" type="string">
  Required when `request_type` is `callback`. Must be a public HTTPS URL that can receive the final task payload. See [Webhooks](/docs/api-reference/webhooks).
</ParamField>

<ParamField body="input" type="object" required>
  Wan 2.7 Video LoRA input parameters.

  <Expandable title="properties">
    <ParamField body="mode" type="string" required>
      Generation mode. The only supported value is `image-to-video`.
    </ParamField>

    <ParamField body="prompt" type="string" required>
      Non-empty text describing the desired video.
    </ParamField>

    <ParamField body="negative_prompt" type="string">
      Optional description of content to avoid. Empty text is ignored.
    </ParamField>

    <ParamField body="image_urls" type="string[]" required>
      Exactly one public first-frame image URL.
    </ParamField>

    <ParamField body="audio_urls" type="string[]">
      At most one public audio URL. When supplied, `sound` must be `true` or omitted.
    </ParamField>

    <ParamField body="sound" type="boolean" default="true">
      Whether the output should include sound. `sound: false` cannot be combined with `audio_urls`.
    </ParamField>

    <ParamField body="duration" type="integer" default="5">
      Output duration in seconds. Supports any integer from `2` through `15`.
    </ParamField>

    <ParamField body="resolution" type="string" default="720p">
      Output resolution. Supported values: `720p`, `1080p`.
    </ParamField>

    <ParamField body="prompt_extend" type="boolean" default="true">
      Whether to rewrite and enrich the prompt before generation.
    </ParamField>

    <ParamField body="seed" type="integer">
      Optional random seed from `0` through `2147483647`.
    </ParamField>
  </Expandable>
</ParamField>

## Poll for result

```bash theme={null}
curl -X GET "https://api.apixo.ai/api/v1/statusTask/wan-2-7-video-LoRA?taskId=task_12345678" \
  -H "Authorization: Bearer YOUR_API_KEY"
```

After `state` becomes `success`, parse `resultJson` and read its `resultUrls` array.

```json theme={null}
{
  "code": 200,
  "message": "success",
  "data": {
    "taskId": "task_12345678",
    "state": "success",
    "resultJson": "{\"resultUrls\":[\"https://file.apixo.ai/video.mp4\"]}"
  }
}
```

## Billing

Billing is based on output duration: `720p` costs `$0.143/second`; `1080p` costs `$0.22/second`.

## Tips

* All media URLs must be publicly accessible by the API.
* Start polling about 60 seconds after task creation, then poll every 10 seconds.
* Use callback delivery for long-running production workflows.
