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

# Wan 2.6 Image-To-Video Generation

> Generate videos from images using the wan2.6-i2v model.

<Note>
  This API supports Alibaba Tongyi Wanxiang (Wan2) video generation models. Please refer to Alibaba Cloud's [official documentation](https://www.alibabacloud.com/help/en/model-studio/text-to-video-api-reference) for more details.
</Note>

## Overview

Generate videos from images using the wan2.6-i2v model with support for longer durations, multi-shot generation, and optional last frame specification.

## Key Features

* Image-to-video generation with audio support
* Multiple resolution options (720P/1080P)
* 5s, 10s, or 15s duration
* Single or multi-shot generation
* Optional first and last frame specification

## Image Requirements

| Property       | Requirement                                   |
| -------------- | --------------------------------------------- |
| **Formats**    | JPEG, JPG, PNG (no transparency), BMP, WEBP   |
| **Dimensions** | \[360, 2000] pixels for both width and height |
| **File Size**  | Max 10MB                                      |
| **Input**      | Public URL or Base64 encoded data             |

## Example Requests

### Basic Image-to-Video

```json theme={null}
{
  "prompt": "A black cat looks curiously at the sky, camera gradually rises from eye-level to overhead",
  "image": "https://example.com/first_frame.jpg",
  "resolution": "720P",
  "duration": 5
}
```

### With Last Frame (Interpolation)

```json theme={null}
{
  "prompt": "Character starts walking, expression changes naturally",
  "image": "https://example.com/person.jpg",
  "last_frame": "https://example.com/person_end.jpg",
  "resolution": "1080P",
  "duration": 10,
  "audio": true
}
```

### Multi-shot Video

```json theme={null}
{
  "prompt": "Scene transition with smooth camera movement",
  "image": "https://example.com/scene.jpg",
  "resolution": "1080P",
  "duration": 15,
  "prompt_extend": true,
  "multi_shots": "multi"
}
```

## Parameters

### last\_frame

* **Optional**: Yes
* **Description**: End frame image for video interpolation between first and last frame
* **Use case**: Create smooth transitions between two specific frames

### multi\_shots

* **Default**: single
* **Effect**: When prompt rewriting is enabled, controls whether the output is single-shot or multi-shot
* **Only effective when**: `prompt_extend` is enabled


## OpenAPI

````yaml api-reference/endpoint/alibaba/wan2.6-i2v/wan2.6-i2v.yaml POST /vendors/alibaba/v1/wan2.6-i2v/generation
openapi: 3.1.0
info:
  title: Wan2.6-i2v API
  description: Wan2.6 Image-to-Video Model API
  license:
    name: MIT
  version: 1.0.0
servers:
  - url: https://api.mulerouter.ai/
security:
  - bearerAuth: []
paths:
  /vendors/alibaba/v1/wan2.6-i2v/generation:
    post:
      summary: Create Generation Task
      description: Generate videos from images using the wan2.6-i2v model.
      operationId: wan26_i2v_generation
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/Wan26I2VRequest'
        required: true
      responses:
        '202':
          description: Accepted - Task created successfully
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/TaskCreatedResponse'
components:
  schemas:
    Wan26I2VRequest:
      type: object
      additionalProperties: false
      properties:
        prompt:
          type: string
          description: Motion/story description for the video (max 2000 characters).
          maxLength: 2000
        negative_prompt:
          anyOf:
            - type: string
            - type: 'null'
          description: Negative prompt describing unwanted content (max 500 characters).
          maxLength: 500
        image:
          type: string
          description: >-
            First-frame image (URL or Base64). Supported formats:
            JPEG/JPG/PNG/BMP/WEBP, 360-2000px, ≤10MB.
        resolution:
          type: string
          description: |-
            Output resolution tier:
            - 720P
            - 1080P
          enum:
            - 720P
            - 1080P
          default: 720P
        duration:
          type: integer
          description: Video duration in seconds. Supported values 5, 10, or 15.
          enum:
            - 5
            - 10
            - 15
        prompt_extend:
          type: boolean
          description: >-
            Enable intelligent prompt rewriting (slightly longer latency, better
            detail).
          default: true
        shot_type:
          anyOf:
            - type: string
              enum:
                - single
                - multi
            - type: 'null'
          description: |-
            Specifies the shot type for video generation.

            Only takes effect when prompt_extend is enabled.

            - single: Default value, outputs single-shot video
            - multi: Outputs multi-shot video
          default: single
        audio:
          anyOf:
            - type: boolean
            - type: 'null'
          description: >-
            Enable automatic audio generation. Set to false to force a silent
            output.
          default: true
        audio_url:
          anyOf:
            - type: string
              format: uri
            - type: 'null'
          description: >-
            Custom audio file URL (wav/mp3, 3-30s, ≤15MB). Overrides the audio
            flag.
        seed:
          type: integer
          description: Random seed [0, 2147483647].
          minimum: 0
          maximum: 2147483647
        safety_filter:
          anyOf:
            - type: boolean
            - type: 'null'
          description: >-
            Enable content safety filter. Defaults to true. Set to false to
            disable content safety inspection.
          default: true
      required:
        - prompt
        - image
    TaskCreatedResponse:
      type: object
      additionalProperties: true
      properties:
        task_info:
          $ref: '#/components/schemas/TaskInfoCreated'
    TaskInfoCreated:
      type: object
      additionalProperties: true
      properties:
        id:
          type: string
          description: UUID of the task
          format: uuid
        status:
          type: string
          description: Task status (pending when created)
          enum:
            - pending
        created_at:
          type: string
          description: Task creation timestamp (ISO 8601)
          format: date-time
        updated_at:
          type: string
          description: Task last update timestamp (ISO 8601)
          format: date-time
      required:
        - id
        - status
        - created_at
        - updated_at
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer

````