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

# Qwen Edit

> This endpoint allows you to edit images using Qwen model.

![Qwen Edit endpoint result](https://assets.modelslab.ai/generations/cc18442d-6dc0-4eb2-9c40-27fa7c59dce4.jpg)

## Request

Make a `POST` request to below endpoint and pass the required parameters as a request body to the endpoint.

```curl curl theme={null}
--request POST 'https://modelslab.com/api/v6/image_editing/qwen_edit' \
```

<Note>
  The `init_image` parameter can accept a string if editing a single image or an array of strings if editing multiple images. Maximum number of images to be passed is 4.
</Note>

## Body

```json json theme={null}
{
  "key":"",
  "prompt": "The girl holding a Pepsi can from image 2 in her left hand.",
  "init_image": [
    "https://assets.modelslab.ai/generations/9398f98f-8b37-4d2b-98b8-04e0d22167e3.jpg",
    "https://assets.modelslab.ai/generations/57df2bbf-512a-4a9a-bf99-35cde14113e7.jpg"
  ],
  "safety_checker": true,
  "model_id": "qwen-edit-2509",
  "base64": false,
  "webhook": null,
  "track_id": null
}
```


## OpenAPI

````yaml POST /image_editing/qwen_edit
openapi: 3.1.0
info:
  title: ModelsLab Image Editing API
  description: >-
    Image editing endpoints for ModelsLab API including background removal,
    super resolution, face generation, fashion try-on, and various image
    manipulation tools
  license:
    name: MIT
  version: 6.0.0
servers:
  - url: https://modelslab.com/api/v6
    description: Image Editing API v6 server
security: []
paths:
  /image_editing/qwen_edit:
    post:
      summary: Qwen Edit
      description: This endpoint allows you to edit images using Qwen model
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/QwenRequest'
      responses:
        '200':
          description: Qwen Edit response
          content:
            application/json:
              schema:
                oneOf:
                  - $ref: '#/components/schemas/ImageEditingSuccessResponse'
                  - $ref: '#/components/schemas/ImageEditingProcessingResponse'
                  - $ref: '#/components/schemas/ImageEditingErrorResponse'
components:
  schemas:
    QwenRequest:
      type: object
      required:
        - key
        - prompt
        - init_image
      properties:
        key:
          type: string
          description: Your API Key used for request authorization
        prompt:
          type: string
          description: >-
            The text prompt describing the content you want in the generated
            image
        init_image:
          type: array
          items:
            type: string
          description: Link the image you want your generations to  edit and manipulate
        safety_checker:
          type: boolean
          description: Whether to run the safety checker
        base64:
          type: boolean
          default: false
          description: Set to true for base64 response
        webhook:
          type: string
          format: uri
          description: URL to receive POST API call when complete
        track_id:
          type: integer
          description: ID for webhook identification
        model_id:
          type: string
          enum:
            - qwen-edit-2509
            - qwen-edit-2511
          default: qwen-edit-2509
          description: The model version to use for image editing
    ImageEditingSuccessResponse:
      type: object
      properties:
        status:
          type: string
          enum:
            - success
        generationTime:
          type: number
          description: Time taken to generate the image in seconds
        id:
          type: integer
          description: Unique identifier for the generation request
        output:
          type: array
          items:
            type: string
            format: uri
          description: Array of generated image URLs
        proxy_links:
          type: array
          items:
            type: string
            format: uri
          description: Array of proxy image URLs
        meta:
          type: object
          description: Metadata about the generation process
          additionalProperties: true
    ImageEditingProcessingResponse:
      type: object
      properties:
        status:
          type: string
          enum:
            - processing
        tip:
          type: string
          description: Information about the processing status
        eta:
          type: integer
          description: Estimated time remaining in seconds
        message:
          type: string
          description: Processing status message
        fetch_result:
          type: string
          format: uri
          description: URL to fetch the result when ready
        id:
          type: integer
          description: Unique identifier for the generation request
        output:
          type: array
          items:
            type: string
          description: Empty array during processing
        future_links:
          type: array
          items:
            type: string
            format: uri
          description: Array of future image URLs
        proxy_links:
          type: array
          items:
            type: string
            format: uri
          description: Array of proxy image URLs
        meta:
          type: object
          description: Metadata about the generation process
          additionalProperties: true
    ImageEditingErrorResponse:
      type: object
      properties:
        status:
          type: string
          enum:
            - error
        message:
          type: string
          description: Error message describing what went wrong

````