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

# Wan 2.7 Image

> Wan 2.7 Image Generation and Editing Model supports text-to-image, text-to-image, image-to-image , image editing, and multi-image reference generation.

## Query Task Status

After submitting a task, use the unified query endpoint to check progress and retrieve results:

<Card title="Get Task Info" icon="magnifying-glass" href="/models/common/get-task-info">
  Learn how to query task status and retrieve generation results
</Card>

<Tip>
  For production use, we recommend using the `callback_url` parameter to receive automatic notifications when generation completes, rather than polling the status endpoint.
</Tip>

## Related Resources

<CardGroup cols={2}>
  <Card title="Models Overview" icon="store" href="/models/quickstart">
    Explore all available models
  </Card>

  <Card title="Common API" icon="gear" href="/common-api/get-account-credits">
    Check credits and account usage
  </Card>
</CardGroup>


## OpenAPI

````yaml models/wan/wan-2-7-image.json post /api/v1/client/job/CreateTask
openapi: 3.0.0
info:
  title: Crun Wan 2.7 Image API
  description: crun.ai Wan 2.7 Image API Documentation
  version: 1.0.0
  contact:
    name: Technical Support
    email: support@crun.ai
servers:
  - url: https://api.crun.ai
    description: API Server
security:
  - ApiKeyAuth: []
paths:
  /api/v1/client/job/CreateTask:
    post:
      summary: wan 2.6 image image generation
      operationId: wan/2-7-image
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              required:
                - model
                - input
              properties:
                model:
                  type: string
                  enum:
                    - wan/2-7-image
                  description: |-
                    The model name to use for generation. Required field.

                    - Must be `wan/2-7-image` for this endpoint
                callback_url:
                  type: string
                  format: uri
                  description: >-
                    Optional. Callback URL for receiving task completion
                    notifications.


                    - System will POST task status and results to this URL when
                    generation completes

                    - Callback payloads structure is consistent with the `data`
                    object returned by the task status query

                    - Your callback endpoint should accept POST requests with
                    JSON payload containing results

                    - It returns an HTTP 200 status code upon successful receipt
                  example: https://your-domain.com/api/callback
                input:
                  type: object
                  description: >-
                    Input parameters for the Wan 2.7 image generation and
                    editing model.
                  properties:
                    prompt:
                      type: string
                      description: >-
                        The text prompt describing the image generation or
                        editing request.
                      minLength: 1
                      maxLength: 5000
                      example: >-
                        A futuristic cyberpunk city street at night with neon
                        lights reflecting on wet pavement.
                    img_urls:
                      type: array
                      description: >-
                        Reference images used for image editing, style transfer,
                        or subject-consistent generation.


                        **Image Restrictions**:


                        - **Supported Formats**: JPEG, JPG, PNG (transparent
                        channel not supported), BMP, WEBP.

                        - **Image Resolution**: Width and height must both be
                        between 240 and 8000 pixels.

                        - **Aspect Ratio**: Must be within the range of 1:8 to
                        8:1.

                        - **File Size**: Maximum 20 MB per image.
                      items:
                        type: string
                        format: uri
                      maxItems: 9
                      example:
                        - https://example.com/reference-image.jpg
                    resolution:
                      type: string
                      description: The output resolution preset for image generation.
                      enum:
                        - 1K
                        - 2K
                      default: 1K
                      example: 2K
                    aspect_ratio:
                      type: string
                      description: The aspect ratio for the generated image.
                      enum:
                        - '16:9'
                        - '9:16'
                        - '4:3'
                        - '3:4'
                        - '1:1'
                        - auto
                      default: '16:9'
                      example: '1:1'
                    region:
                      type: string
                      description: >-
                        Service region. mainland: China Mainland, global:
                        International
                      enum:
                        - mainland
                        - global
                      nullable: true
                      default: null
                      example: global
                    num_outputs:
                      type: integer
                      description: >-
                        Number of images to generate in a single request.


                        - When `enable_sequential=false`, the supported range is
                        1 to 4.

                        - When `enable_sequential=true`, up to 12 outputs are
                        supported. The actual outputs is determined by the model
                        and shall not exceed `num_outputs`.
                      minimum: 1
                      maximum: 12
                      default: 1
                      example: 4
                    enable_sequential:
                      type: boolean
                      description: |-
                        Enable sequential group-image generation mode.

                        When enabled:
                        - `color_palette` is not supported.
                        - Supports generating up to 12 images in sequence.
                      default: false
                      example: true
                    color_palette:
                      type: array
                      description: >-
                        Custom color theme configuration.


                        An array of color objects containing a HEX color value
                        and its composition ratio.


                        Requirements:

                        - Must contain between 3 and 10 colors.

                        - Using around 8 colors is recommended.

                        - Only available when `enable_sequential=false`.
                      minItems: 3
                      maxItems: 10
                      items:
                        type: object
                        properties:
                          hex:
                            type: string
                            description: HEX color code.
                            example: '#FF5733'
                          ratio:
                            type: number
                            description: Color composition ratio.
                            example: 0.25
                        required:
                          - hex
                          - ratio
                      example:
                        - hex: '#FF5733'
                          ratio: 0.3
                        - hex: '#33C1FF'
                          ratio: 0.25
                        - hex: '#222222'
                          ratio: 0.45
                    bbox_list:
                      type: array
                      description: >-
                        Interactive editing bounding box regions.


                        The length of this list must match the number of input
                        images in `img_urls`.


                        For images that do not require editing, pass an empty
                        array `[]`.


                        Each bounding box uses the coordinate format:

                        `[x1, y1, x2, y2]`


                        Where:

                        - `x1`, `y1` = top-left corner coordinates

                        - `x2`, `y2` = bottom-right corner coordinates

                        - Coordinates use absolute pixel positions based on the
                        original image.

                        - The origin `(0,0)` is the top-left corner of the
                        image.


                        Restrictions:

                        - Each image supports a maximum of 2 bounding boxes.

                        - Each bounding box must contain exactly 4 integer
                        values.
                      items:
                        type: array
                        items:
                          type: array
                          items:
                            type: integer
                          minItems: 4
                          maxItems: 4
                        maxItems: 2
                      example:
                        - - - 0
                            - 0
                            - 12
                            - 12
                          - - 25
                            - 25
                            - 100
                            - 100
                        - []
                        - - - 10
                            - 10
                            - 50
                            - 50
                    input_compliance:
                      type: string
                      nullable: true
                      description: >-
                        Optional input compliance check switch. Use `enable` to
                        turn input checks on, `disable` to turn them off, or
                        omit/pass `null` to use the default setting.
                      enum:
                        - disable
                        - enable
                      default: null
                      example: enable
                    output_compliance:
                      type: string
                      nullable: true
                      description: >-
                        Optional output compliance check switch. Use `enable` to
                        turn output checks on, `disable` to turn them off, or
                        omit/pass `null` to use the default setting.
                      enum:
                        - disable
                        - enable
                      default: null
                      example: enable
                  required:
                    - prompt
            example:
              model: wan/2-7-image
              callback_url: https://your-domain.com/api/callback
              input:
                prompt: >-
                  A fantasy castle floating above the clouds at sunset,
                  cinematic lighting, ultra detailed.
                img_urls:
                  - https://example.com/reference-1.jpg
                  - https://example.com/reference-2.jpg
                resolution: 2K
                aspect_ratio: '16:9'
                region: global
                num_outputs: 2
                enable_sequential: false
                input_compliance: enable
                output_compliance: enable
      responses:
        '200':
          description: Request successful
          content:
            application/json:
              schema:
                allOf:
                  - $ref: '#/components/schemas/ApiResponse'
                  - type: object
                    properties:
                      data:
                        type: object
                        properties:
                          task_id:
                            type: string
                            description: >-
                              Task ID, can be used with Get Task Details
                              endpoint to query task status
                            example: task_12345678
              example:
                code: 200
                message: success
                data:
                  task_id: task_12345678
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                allOf:
                  - $ref: '#/components/schemas/ApiResponse'
                  - type: object
                    properties:
                      errors:
                        type: array
                        description: Detailed validation error messages
                        items:
                          type: string
                        example:
                          - specific error field message
              example:
                code: 422
                message: Missing Params or Type Error
                errors:
                  - specific error field message
        '500':
          $ref: '#/components/responses/Error'
components:
  schemas:
    ApiResponse:
      type: object
      properties:
        code:
          type: integer
          enum:
            - 200
            - 401
            - 402
            - 404
            - 422
            - 429
            - 455
            - 500
            - 501
            - 505
          description: >-
            Response status code


            - **200**: Success - Request has been processed successfully

            - **401**: Unauthorized - Authentication credentials are missing or
            invalid

            - **402**: Insufficient Credits - Account does not have enough
            credits to perform the operation

            - **404**: Not Found - The requested resource or endpoint does not
            exist

            - **422**: Validation Error - The request parameters failed
            validation checks

            - **429**: Rate Limited - Request limit has been exceeded for this
            resource

            - **455**: Service Unavailable - System is currently undergoing
            maintenance

            - **500**: Server Error - An unexpected error occurred while
            processing the request

            - **501**: Generation Failed - Content generation task failed

            - **505**: Feature Disabled - The requested feature is currently
            disabled
        message:
          type: string
          description: Response message, error description when failed
          example: success
  responses:
    Error:
      description: Server Error
  securitySchemes:
    ApiKeyAuth:
      type: apiKey
      in: header
      name: x-api-key
      description: >-
        All APIs require authentication via API Key.


        Get API Key:

        1. Visit [API Key Management Page](https://crun.ai/user-api-key) to get
        your API Key


        Usage:

        Add to request header:


        x-api-key: YOUR_API_KEY


        Note:

        - Keep your API Key secure and do not share it with others

        - If you suspect your API Key has been compromised, reset it immediately
        in the management page

````