Skip to main content
Qwen Image Editing
Edit reference images with Qwen Image using one user message containing text and image blocks. POST https://api.mixroute.ai/v1/images/generations

Models

Use Qwen Image generation for qwen-image, qwen-image-plus, qwen-image-2.0, qwen-image-2.0-pro, and qwen-image-max.

Request Parameters

Put text and image in separate content blocks. Reference images must use public HTTPS URLs accessible to the upstream service. Use input.messages rather than input.prompt; do not send a top-level prompt, multipart files, Base64 data URIs, or a metadata wrapper.

Request Examples

Set MIXROUTE_API_KEY and replace the reference-image placeholder with a public HTTPS image URL.

Python

Response

Read image URLs from output.choices[].message.content[].image. usage.image_count, usage.height, and usage.width describe the output. This response does not use the basic text-to-image output.results structure.

Errors

HTTP 400 can indicate missing reference images, an invalid model name, or an unsupported size. HTTP 429 indicates rate or concurrency limits; reduce request frequency before retrying.