Image Editing
Upload an original image to /v1/images/edits and edit it locally (inpainting, masked modifications) guided by a prompt. For available models and prices see the Model Plaza (look for image model names containing edit); below we use qwen-image-edit-plus.
Important distinction — confirm which endpoint you need first:
/v1/images/edits: localized image editing, masked inpainting. Requiresmultipart/form-data;application/jsonis not supported, and passing an image HTTP URL is not supported — the image must be uploaded as a form file./v1/images/generations: text-to-image and whole-image redraws. Accepts a JSON body and public image URLs directly. If you want a whole-image redraw / image-to-image without localized masking, use this endpoint — see Text-to-Image & Image-to-Image.
Endpoint
POST /v1/images/edits
Authentication
Pass the Bearer token in the request header:
Request Body
Request Examples
Response Notes
The endpoint is multipart/form-data; JSON bodies are forbidden, the image parameter must be a local file upload, and direct https links are not supported. When debugging in Apifox, switch Body to form-data and set the image field type to File to upload a file.
The response may return binary image content directly instead of JSON (the -o flag in the cURL example saves the image locally) — use the response header Content-Type to tell them apart.
The common error convert_request_failed: image is required indicates a malformed request, usually caused by mistakenly passing an image URL in JSON — switch to a form file upload; for whole-image redraws use /v1/images/generations instead, see Text-to-Image & Image-to-Image.
