SandBase is live — $1 in free credits on signupStart free ›

Alibaba modelsimage generation api

alibaba/qwen-image-edit/inpaint

Qwen Image Edit Inpaint is Alibaba's intelligent image editing model. Transform, retouch, and reimagine existing images using text prompts - from background replacement to artistic style conversion.

Input
The prompt to generate the image with

PNG, JPEG, WebP, or GIF · 20 MiB maximum

The URL of the image to edit.

PNG, JPEG, WebP, or GIF · 20 MiB maximum

The URL of the mask for inpainting
0.011
Strength of noising process for inpainting Range: 0.01 to 1.
The format of the generated image. Allowed values: jpeg, png.
The aspect ratio of the generated image. Allowed values: 21:9, 16:9, 3:2, 4:3, 5:4, 1:1, 4:5, 3:4, 2:3, 9:16.
The same seed and the same prompt given to the same version of the model will output the same image every time.
Idle

Example output — click Run to generate your own

API README

Qwen Image Edit Inpaint

Qwen Image Edit Inpaint is a Qwen Image masked reconstruction route that combines visual-semantic understanding with image synthesis. It interprets subjects, spatial relationships, typography, and appearance as connected parts of one design, allowing the generated or revised image to follow a detailed creative brief instead of merely matching isolated keywords or request settings.

Use this exact route when the production task calls for masked reconstruction. Describe the subject and intended result first, then specify composition, viewpoint, text content, material, lighting, and visual finish. For edits, identify what must change and what must remain untouched; for adapted or layered work, explain the role of each source and the consistency expected across the final asset.

Highlights

  • Masked region reconstruction. Regenerates only the selected area while using the surrounding image to infer plausible content.
  • Context-aware boundary blending. Matches perspective, texture, color, and illumination across the edge of the edited region.
  • Semantic object replacement. Can remove, add, or transform content according to a natural-language instruction.
  • Preservation beyond the mask. Retains unselected regions so localized edits do not become uncontrolled full-image regeneration.

Pricing

ConfigurationBilling unitPrice
Base generationPer request$0.03

When to Use

✅ Good fit❌ Consider alternatives
The project needs this exact named workflowThe intended task belongs to another media route
All required reference or control media is availableNecessary assets or rights are unavailable
The brief can state transformation and preservation goalsOutput must be deterministic at pixel or frame level
Supported duration, resolution, and format fit deliveryFinal placement requires unsupported specifications
An asynchronous generated result fits productionA live frame-synchronous response is mandatory

Prompt Guide

Identify the primary subject and every source or condition, state the intended transformation or action, then describe composition, camera or viewpoint, lighting, materials, pacing, atmosphere, and exact preservation requirements. Refer to multiple inputs in their schema order.

{
  "prompt": "A precisely directed composition with explicit subject, transformation, camera or viewpoint, lighting, material, and preservation requirements",
  "image": "https://example.com/reference.png",
  "mask": "https://example.com/reference.png",
  "seed": 1,
  "strength": 0.93
}

Technical Specs

SpecValue
Model IDalibaba/qwen-image-edit/inpaint
Input fieldsmask (string)<br>seed (integer)<br>image (string)<br>prompt (string)<br>strength (number)<br>aspect_ratio (string; 21:9, 16:9, 3:2, 4:3, 5:4, 1:1, 4:5, 3:4, 2:3, 9:16)<br>output_format (string; jpeg, png)
Required inputprompt, image
Output fieldsurl, content_type
ExecutionAsynchronous job

Related Models

  • alibaba/qwen-image
  • alibaba/qwen-image/edit
  • alibaba/qwen-image/max

Related Models

alibaba/qwen-image-editQwen Image Edit is Alibaba's intelligent image editing model. Transform, retouch, and reimagine existing images using text prompts - from background replacement to artistic style conversion.alibaba/qwen-image-edit/2509-lora-gallery/add-backgroundQwen Image Edit 2509 Lora Gallery Add Background by Alibaba - AI-powered image editing, style transfer, and transformation. Edit photos with natural language instructions, remove backgrounds, change styles, and enhance images effortlessly.alibaba/qwen-image-edit/2509-lora-gallery/face-to-full-portraitQwen Image Edit 2509 Lora Gallery Face To Full Portrait is Alibaba's intelligent image editing model. Transform, retouch, and reimagine existing images using text prompts - from background replacement to artistic style conversion.alibaba/qwen-image-edit/2509-lora-gallery/integrate-productQwen Image Edit 2509 Lora Gallery Integrate Product is Alibaba's intelligent image editing model. Transform, retouch, and reimagine existing images using text prompts - from background replacement to artistic style conversion.alibaba/qwen-image-edit/2509-lora-gallery/lighting-restorationQwen Image Edit 2509 Lora Gallery Lighting Restoration by Alibaba - AI-powered image editing, style transfer, and transformation. Edit photos with natural language instructions, remove backgrounds, change styles, and enhance images effortlessly.alibaba/qwen-image-edit/2509/loraQwen Image Edit 2509 Lora is Alibaba's intelligent image editing model. Transform, retouch, and reimagine existing images using text prompts - from background replacement to artistic style conversion.alibaba/qwen-image-edit/2511Qwen Image Edit 2511 by Alibaba - AI-powered image editing, style transfer, and transformation. Edit photos with natural language instructions, remove backgrounds, change styles, and enhance images effortlessly.alibaba/qwen-image-edit/2511/loraQwen Image Edit 2511 Lora is Alibaba's intelligent image editing model. Transform, retouch, and reimagine existing images using text prompts - from background replacement to artistic style conversion.