Qwen Image 3 API (Pro & Standard), Qwen Image Max API, Qwen Image API: Pricing, Documentation

by Alibaba

Qwen Image by Alibaba offers comprehensive AI image generation and editing capabilities with multiple specialized variants. Through Pixazo's API, developers can access text-to-image generation, image editing, layered image creation, and LoRA training features. The API represents Alibaba's advanced AI research applied to visual content creation, suitable for both consumer applications and enterprise workflows.

Get API Key
Qwen AI API

Models Version

WELCOME BONUS

Get 10% Cashback on Your First Payment (up to $500)

Add funds and get 10% cashback on your first payment (up to $500).

Claim Your Cashback →

Qwen Image 3.0 Standard API Documentation

https://gateway.pixazo.ai/qwen-image-3-0/v1/text-to-image

Authentication

All requests require an API key passed via header.

HeaderTypeRequiredDescription
Ocp-Apim-Subscription-KeystringYesYour API subscription key

Text to Image - Qwen Image 3.0

Request Code

POST https://gateway.pixazo.ai/qwen-image-3-0/v1/text-to-image
Content-Type: application/json
Cache-Control: no-cache
Ocp-Apim-Subscription-Key: YOUR_SUBSCRIPTION_KEY

{
  "prompt": "A majestic white tiger resting on a mossy rock beside a waterfall in a tropical rainforest, photorealistic"
}
import requests

url = "https://gateway.pixazo.ai/qwen-image-3-0/v1/text-to-image"
headers = {
    "Content-Type": "application/json",
    "Cache-Control": "no-cache",
    "Ocp-Apim-Subscription-Key": "YOUR_SUBSCRIPTION_KEY"
}
data = {
    "prompt": "A majestic white tiger resting on a mossy rock beside a waterfall in a tropical rainforest, photorealistic"
}

response = requests.post(url, json=data, headers=headers)
print(response.json())
const url = "https://gateway.pixazo.ai/qwen-image-3-0/v1/text-to-image";
const headers = {
  "Content-Type": "application/json",
  "Cache-Control": "no-cache",
  "Ocp-Apim-Subscription-Key": "YOUR_SUBSCRIPTION_KEY"
};
const data = {
  prompt: "A majestic white tiger resting on a mossy rock beside a waterfall in a tropical rainforest, photorealistic"
};

fetch(url, {
  method: "POST",
  headers: headers,
  body: JSON.stringify(data)
})
.then(response => response.json())
.then(data => console.log(data))
.catch(error => console.error("Error:", error));
curl -X POST "https://gateway.pixazo.ai/qwen-image-3-0/v1/text-to-image" \
  -H "Content-Type: application/json" \
  -H "Cache-Control: no-cache" \
  -H "Ocp-Apim-Subscription-Key: YOUR_SUBSCRIPTION_KEY" \
  --data-raw '{
    "prompt": "A majestic white tiger resting on a mossy rock beside a waterfall in a tropical rainforest, photorealistic"
  }'

Output

{
  "request_id": "qwen-image-3-0_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
  "status": "QUEUED",
  "polling_url": "https://gateway.pixazo.ai/v2/requests/status/qwen-image-3-0_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"
}

Webhook (Optional)

Add the X-Webhook-URL header to your submit request to receive a POST callback when the job completes — no polling required.

Using curl? These are HTTP request headers — pass each with -H, e.g. -H "X-Webhook-URL: https://your-server.com/webhook/callback". Do not paste them as bare lines, and end every line of a multi-line command with \.

Webhook Headers

HeaderRequiredDefaultDescription
X-Webhook-URLYes (to enable)—HTTPS endpoint on your server that will receive the POST callback. Must respond 2xx within a few seconds (process async if needed).
X-Webhook-ModeNoterminalterminal — fires once at the final status (COMPLETED/FAILED/ERROR). sync — fires on every poll cycle plus the terminal event, and caps the queue’s polling delay at 15s for tighter progress updates.

Example: enable webhook

X-Webhook-URL: https://your-server.com/webhook/callback
X-Webhook-Mode: terminal

Callback Payload

Your endpoint receives a POST application/json with the same shape as the GET /v2/requests/status/{request_id} response. Example terminal callback (mode terminal):

{
  "request_id": "qwen-image-3-0_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
  "status": "COMPLETED",
  "model_id": "qwen-image-3-0",
  "error": null,
  "output": {
    "media_url": [
      "https://pub-582b7213209642b9b995c96c95a30381.r2.dev/v1/qwen-image-3-0_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx/output.png"
    ],
    "media_type": "image/png"
  },
  "created_at": "2026-07-23T10:00:00.000Z",
  "updated_at": "2026-07-23 10:00:15",
  "completed_at": "2026-07-23 10:00:15"
}

Failure callback shape

{
  "request_id": "qwen-image-3-0_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
  "status": "ERROR",
  "model_id": "qwen-image-3-0",
  "error": "Description of the error",
  "output": null,
  "created_at": "...",
  "updated_at": "...",
  "completed_at": "..."
}

Delivery semantics

  • terminal mode (default) — exactly one POST when the request reaches a terminal status. No callback during PROCESSING.
  • sync mode — POST on every status poll (with delay capped at ~15s) plus a final POST at terminal status. Use when you want progress updates.
  • Idempotency — use request_id as your idempotency key. Network retries can deliver the same callback more than once; your handler must tolerate duplicates.
  • Response — respond 200 OK within a few seconds. The queue does not block on slow handlers, but persistent failures may stop further deliveries.
  • HTTPS required — plain http:// URLs are rejected.

Request Parameters - Text to Image

Requests that set n > 1 are billed per image.

ParameterRequiredTypeDefaultAllowed values / range
promptYesrequiredstring——
A detailed text description of the desired image. Be specific about subjects, style, lighting, and composition.
sizeNostringautoauto · aspect ratio · WIDTHxHEIGHT
Output resolution. Accepts auto (default — the model chooses a size), an aspect-ratio string (1:1, 4:3, 3:4, 16:9, 9:16, 3:2, 2:3, 21:9), or an explicit WIDTHxHEIGHT with each side 512–2048 px (e.g. 1024x1024, 1536x1024, 1328x1328). Also works with n > 1.
nNointeger11–6
Number of images to generate in a single request. Billed per image — n images cost n × the per-image price.
negative_promptNostring——
A description of elements to avoid in the generated image. Helps steer the model away from unwanted features.
seedNointeger——
Random seed for reproducibility. Reuse the same seed with identical inputs to reproduce a result; omit for a random seed each request.
watermarkNobooleanfalsetrue, false
When true, adds a small "Qwen-Image" watermark to the bottom-right corner. Defaults to false (no watermark).
prompt_extendNobooleantruetrue, false
Automatically rewrites and enriches your prompt with an LLM before generation to improve results. Enabled by default.

Minimum Request

{
  "prompt": "A majestic white tiger resting on a mossy rock beside a waterfall in a tropical rainforest, photorealistic"
}

Full Request (all options)

{
  "prompt": "A majestic white tiger resting on a mossy rock beside a waterfall in a tropical rainforest, photorealistic",
  "size": "1024x1024",
  "n": 1,
  "negative_prompt": "low resolution, error, worst quality, low quality, deformed",
  "seed": 42,
  "watermark": false,
  "prompt_extend": true
}

Response

{
  "request_id": "qwen-image-3-0_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
  "status": "QUEUED",
  "polling_url": "https://gateway.pixazo.ai/v2/requests/status/qwen-image-3-0_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"
}

Request Headers

HeaderValue
Content-Typeapplication/json
Cache-Controlno-cache
Ocp-Apim-Subscription-KeyYour API subscription key

Response Handling

Common status codes for Text to Image.

CodeMeaning
202Accepted — Request queued
Bad Request
401Unauthorized
402Insufficient Balance
403Forbidden
Too Many Requests
500Internal Server Error

Error Responses

Queue system errors and model validation errors.

Queue System Errors

// 402 — Insufficient balance
{
  "error": "Insufficient Balance",
  "message": "Your wallet does not have enough balance."
}
// 400 — Model not found
{
  "error": "Model not found",
  "message": "Model 'qwen-image-3-0' not found or is disabled"
}

Error via Status/Webhook

{
  "request_id": "qwen-image-3-0_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
  "status": "ERROR",
  "model_id": "qwen-image-3-0",
  "error": "Description of the error",
  "output": null
}

Retrieving Results

Poll the universal status endpoint to check progress and retrieve results.

Endpoint

GET https://gateway.pixazo.ai/v2/requests/status/{request_id}
Ocp-Apim-Subscription-Key: YOUR_API_KEY

cURL Example

curl -H "Ocp-Apim-Subscription-Key: YOUR_API_KEY" \
  "https://gateway.pixazo.ai/v2/requests/status/qwen-image-3-0_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"

Response (Completed)

{
  "request_id": "qwen-image-3-0_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
  "status": "COMPLETED",
  "model_id": "qwen-image-3-0",
  "error": null,
  "output": {
    "media_url": [
      "https://pub-582b7213209642b9b995c96c95a30381.r2.dev/v1/qwen-image-3-0_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx/output.png"
    ],
    "media_type": "image/png"
  },
  "created_at": "2026-07-23T10:00:00.000Z",
  "updated_at": "2026-07-23 10:00:15",
  "completed_at": "2026-07-23 10:00:15"
}

Response Fields

FieldTypeDescription
request_idstringUnique request identifier
statusstringQUEUED, PROCESSING, COMPLETED, FAILED, or ERROR
model_idstringModel that processed the request
errorstring|nullError message if failed
output.media_urlarrayURLs to generated images (R2 CDN)
output.media_typestringMIME type of the output (image/png)
created_atstringWhen request was created
completed_atstring|nullWhen request completed
polling_urlstringStatus URL (initial response only)

Status Values

StatusDescription
QUEUEDRequest accepted, waiting to be processed
PROCESSINGBeing processed by the model
COMPLETEDDone — output contains the result
FAILEDFailed — check error field
ERRORSystem error (e.g. bad inputs) — not charged

Status Flow

QUEUED → PROCESSING → COMPLETED
                    → FAILED
                    → ERROR

Typical Workflow

  1. Send a text to image request to the API endpoint
  2. Save the request_id from the response
  3. Poll every 5-10 seconds: GET /v2/requests/status/{request_id}
  4. When status is "COMPLETED", download from output.media_url

Tip: Use X-Webhook-URL header to get a callback instead of polling.

Qwen Image 3.0 Standard API Pricing

Your request will cost $0.039 per image.
Image to Image (Editing)

Qwen Image 3.0 Standard API Documentation

https://gateway.pixazo.ai/qwen-image-3-0/v1/image-to-image/editing

Authentication

All requests require an API key passed via header.

HeaderTypeRequiredDescription
Ocp-Apim-Subscription-KeystringYesYour API subscription key

Image to Image Editing - Qwen Image 3.0

Request Code

POST https://gateway.pixazo.ai/qwen-image-3-0/v1/image-to-image/editing
Content-Type: application/json
Cache-Control: no-cache
Ocp-Apim-Subscription-Key: YOUR_SUBSCRIPTION_KEY

{
  "image_url": "https://pub-582b7213209642b9b995c96c95a30381.r2.dev/doc-assets/images/input.jpg",
  "prompt": "Change the background to a snowy mountain landscape at golden hour"
}
import requests

url = "https://gateway.pixazo.ai/qwen-image-3-0/v1/image-to-image/editing"
headers = {
    "Content-Type": "application/json",
    "Cache-Control": "no-cache",
    "Ocp-Apim-Subscription-Key": "YOUR_SUBSCRIPTION_KEY"
}
data = {
    "image_url": "https://pub-582b7213209642b9b995c96c95a30381.r2.dev/doc-assets/images/input.jpg",
    "prompt": "Change the background to a snowy mountain landscape at golden hour"
}

response = requests.post(url, json=data, headers=headers)
print(response.json())
const url = "https://gateway.pixazo.ai/qwen-image-3-0/v1/image-to-image/editing";
const headers = {
  "Content-Type": "application/json",
  "Cache-Control": "no-cache",
  "Ocp-Apim-Subscription-Key": "YOUR_SUBSCRIPTION_KEY"
};
const data = {
  image_url: "https://pub-582b7213209642b9b995c96c95a30381.r2.dev/doc-assets/images/input.jpg",
  prompt: "Change the background to a snowy mountain landscape at golden hour"
};

fetch(url, {
  method: "POST",
  headers: headers,
  body: JSON.stringify(data)
})
.then(response => response.json())
.then(data => console.log(data))
.catch(error => console.error("Error:", error));
curl -X POST "https://gateway.pixazo.ai/qwen-image-3-0/v1/image-to-image/editing" \
  -H "Content-Type: application/json" \
  -H "Cache-Control: no-cache" \
  -H "Ocp-Apim-Subscription-Key: YOUR_SUBSCRIPTION_KEY" \
  --data-raw '{
    "image_url": "https://pub-582b7213209642b9b995c96c95a30381.r2.dev/doc-assets/images/input.jpg",
    "prompt": "Change the background to a snowy mountain landscape at golden hour"
  }'

Output

{
  "request_id": "qwen-image-3-0_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
  "status": "QUEUED",
  "polling_url": "https://gateway.pixazo.ai/v2/requests/status/qwen-image-3-0_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"
}

Webhook (Optional)

Add the X-Webhook-URL header to your submit request to receive a POST callback when the job completes — no polling required.

Using curl? These are HTTP request headers — pass each with -H, e.g. -H "X-Webhook-URL: https://your-server.com/webhook/callback". Do not paste them as bare lines, and end every line of a multi-line command with \.

Webhook Headers

HeaderRequiredDefaultDescription
X-Webhook-URLYes (to enable)—HTTPS endpoint on your server that will receive the POST callback. Must respond 2xx within a few seconds (process async if needed).
X-Webhook-ModeNoterminalterminal — fires once at the final status (COMPLETED/FAILED/ERROR). sync — fires on every poll cycle plus the terminal event, and caps the queue’s polling delay at 15s for tighter progress updates.

Example: enable webhook

X-Webhook-URL: https://your-server.com/webhook/callback
X-Webhook-Mode: terminal

Callback Payload

Your endpoint receives a POST application/json with the same shape as the GET /v2/requests/status/{request_id} response. Example terminal callback (mode terminal):

{
  "request_id": "qwen-image-3-0_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
  "status": "COMPLETED",
  "model_id": "qwen-image-3-0",
  "error": null,
  "output": {
    "media_url": [
      "https://pub-582b7213209642b9b995c96c95a30381.r2.dev/v1/qwen-image-3-0_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx/output.png"
    ],
    "media_type": "image/png"
  },
  "created_at": "2026-07-23T10:00:00.000Z",
  "updated_at": "2026-07-23 10:00:15",
  "completed_at": "2026-07-23 10:00:15"
}

Failure callback shape

{
  "request_id": "qwen-image-3-0_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
  "status": "ERROR",
  "model_id": "qwen-image-3-0",
  "error": "Description of the error",
  "output": null,
  "created_at": "...",
  "updated_at": "...",
  "completed_at": "..."
}

Delivery semantics

  • terminal mode (default) — exactly one POST when the request reaches a terminal status. No callback during PROCESSING.
  • sync mode — POST on every status poll (with delay capped at ~15s) plus a final POST at terminal status. Use when you want progress updates.
  • Idempotency — use request_id as your idempotency key. Network retries can deliver the same callback more than once; your handler must tolerate duplicates.
  • Response — respond 200 OK within a few seconds. The queue does not block on slow handlers, but persistent failures may stop further deliveries.
  • HTTPS required — plain http:// URLs are rejected.

Request Parameters - Image to Image Editing

Requests that set n > 1 are billed per image.

ParameterRequiredTypeDefaultAllowed values / range
image_urlYesrequiredstring——
Publicly accessible HTTP/HTTPS URL of the single source image to edit (exactly one). Accepted formats: JPG, JPEG, PNG, BMP, TIFF, WEBP, GIF. Width & height 384–2048 px (recommended for best results); file size up to 10 MB.
promptYesrequiredstring——
A detailed description of the edit to apply to the source image.
sizeNostringautoauto · aspect ratio · WIDTHxHEIGHT
Output resolution. Accepts auto (default — the model chooses a size), an aspect-ratio string (1:1, 4:3, 3:4, 16:9, 9:16, 3:2, 2:3, 21:9), or an explicit WIDTHxHEIGHT with each side 512–2048 px (e.g. 1024x1024, 1536x1024, 1328x1328). Also works with n > 1.
nNointeger11–6
Number of images to generate in a single request. Billed per image — n images cost n × the per-image price.
negative_promptNostring——
A description of elements to avoid in the generated image. Helps steer the model away from unwanted features.
seedNointeger——
Random seed for reproducibility. Reuse the same seed with identical inputs to reproduce a result; omit for a random seed each request.
watermarkNobooleanfalsetrue, false
When true, adds a small "Qwen-Image" watermark to the bottom-right corner. Defaults to false (no watermark).
prompt_extendNobooleantruetrue, false
Automatically rewrites and enriches your prompt with an LLM before generation to improve results. Enabled by default.

Minimum Request

{
  "image_url": "https://pub-582b7213209642b9b995c96c95a30381.r2.dev/doc-assets/images/input.jpg",
  "prompt": "Change the background to a snowy mountain landscape at golden hour"
}

Full Request (all options)

{
  "image_url": "https://pub-582b7213209642b9b995c96c95a30381.r2.dev/doc-assets/images/input.jpg",
  "prompt": "Change the background to a snowy mountain landscape at golden hour",
  "size": "1024x1024",
  "n": 1,
  "negative_prompt": "low resolution, artifacts, distorted",
  "seed": 42,
  "watermark": false,
  "prompt_extend": true
}

Response

{
  "request_id": "qwen-image-3-0_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
  "status": "QUEUED",
  "polling_url": "https://gateway.pixazo.ai/v2/requests/status/qwen-image-3-0_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"
}

Request Headers

HeaderValue
Content-Typeapplication/json
Cache-Controlno-cache
Ocp-Apim-Subscription-KeyYour API subscription key

Response Handling

Common status codes for Image to Image Editing.

CodeMeaning
202Accepted — Request queued
Bad Request
401Unauthorized
402Insufficient Balance
403Forbidden
Too Many Requests
500Internal Server Error

Error Responses

Queue system errors and model validation errors.

Queue System Errors

// 402 — Insufficient balance
{
  "error": "Insufficient Balance",
  "message": "Your wallet does not have enough balance."
}
// 400 — Model not found
{
  "error": "Model not found",
  "message": "Model 'qwen-image-3-0' not found or is disabled"
}

Error via Status/Webhook

{
  "request_id": "qwen-image-3-0_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
  "status": "ERROR",
  "model_id": "qwen-image-3-0",
  "error": "Description of the error",
  "output": null
}

Retrieving Results

Poll the universal status endpoint to check progress and retrieve results.

Endpoint

GET https://gateway.pixazo.ai/v2/requests/status/{request_id}
Ocp-Apim-Subscription-Key: YOUR_API_KEY

cURL Example

curl -H "Ocp-Apim-Subscription-Key: YOUR_API_KEY" \
  "https://gateway.pixazo.ai/v2/requests/status/qwen-image-3-0_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"

Response (Completed)

{
  "request_id": "qwen-image-3-0_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
  "status": "COMPLETED",
  "model_id": "qwen-image-3-0",
  "error": null,
  "output": {
    "media_url": [
      "https://pub-582b7213209642b9b995c96c95a30381.r2.dev/v1/qwen-image-3-0_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx/output.png"
    ],
    "media_type": "image/png"
  },
  "created_at": "2026-07-23T10:00:00.000Z",
  "updated_at": "2026-07-23 10:00:15",
  "completed_at": "2026-07-23 10:00:15"
}

Response Fields

FieldTypeDescription
request_idstringUnique request identifier
statusstringQUEUED, PROCESSING, COMPLETED, FAILED, or ERROR
model_idstringModel that processed the request
errorstring|nullError message if failed
output.media_urlarrayURLs to generated images (R2 CDN)
output.media_typestringMIME type of the output (image/png)
created_atstringWhen request was created
completed_atstring|nullWhen request completed
polling_urlstringStatus URL (initial response only)

Status Values

StatusDescription
QUEUEDRequest accepted, waiting to be processed
PROCESSINGBeing processed by the model
COMPLETEDDone — output contains the result
FAILEDFailed — check error field
ERRORSystem error (e.g. bad inputs) — not charged

Status Flow

QUEUED → PROCESSING → COMPLETED
                    → FAILED
                    → ERROR

Typical Workflow

  1. Send a image to image editing request to the API endpoint
  2. Save the request_id from the response
  3. Poll every 5-10 seconds: GET /v2/requests/status/{request_id}
  4. When status is "COMPLETED", download from output.media_url

Tip: Use X-Webhook-URL header to get a callback instead of polling.

Qwen Image 3.0 Standard API Pricing

Your request will cost $0.039 per image.
Image to Image (Fusion)

Qwen Image 3.0 Standard API Documentation

https://gateway.pixazo.ai/qwen-image-3-0/v1/image-to-image/fusion

Authentication

All requests require an API key passed via header.

HeaderTypeRequiredDescription
Ocp-Apim-Subscription-KeystringYesYour API subscription key

Image to Image Fusion - Qwen Image 3.0

Request Code

POST https://gateway.pixazo.ai/qwen-image-3-0/v1/image-to-image/fusion
Content-Type: application/json
Cache-Control: no-cache
Ocp-Apim-Subscription-Key: YOUR_SUBSCRIPTION_KEY

{
  "image_urls": [
    "https://pub-582b7213209642b9b995c96c95a30381.r2.dev/doc-assets/images/fusion-a.jpg",
    "https://pub-582b7213209642b9b995c96c95a30381.r2.dev/doc-assets/images/fusion-b.jpg"
  ],
  "prompt": "Blend the two portraits into a single cinematic double-exposure composition"
}
import requests

url = "https://gateway.pixazo.ai/qwen-image-3-0/v1/image-to-image/fusion"
headers = {
    "Content-Type": "application/json",
    "Cache-Control": "no-cache",
    "Ocp-Apim-Subscription-Key": "YOUR_SUBSCRIPTION_KEY"
}
data = {
    "image_urls": [
        "https://pub-582b7213209642b9b995c96c95a30381.r2.dev/doc-assets/images/fusion-a.jpg",
        "https://pub-582b7213209642b9b995c96c95a30381.r2.dev/doc-assets/images/fusion-b.jpg"
    ],
    "prompt": "Blend the two portraits into a single cinematic double-exposure composition"
}

response = requests.post(url, json=data, headers=headers)
print(response.json())
const url = "https://gateway.pixazo.ai/qwen-image-3-0/v1/image-to-image/fusion";
const headers = {
  "Content-Type": "application/json",
  "Cache-Control": "no-cache",
  "Ocp-Apim-Subscription-Key": "YOUR_SUBSCRIPTION_KEY"
};
const data = {
  image_urls: [
    "https://pub-582b7213209642b9b995c96c95a30381.r2.dev/doc-assets/images/fusion-a.jpg",
    "https://pub-582b7213209642b9b995c96c95a30381.r2.dev/doc-assets/images/fusion-b.jpg"
  ],
  prompt: "Blend the two portraits into a single cinematic double-exposure composition"
};

fetch(url, {
  method: "POST",
  headers: headers,
  body: JSON.stringify(data)
})
.then(response => response.json())
.then(data => console.log(data))
.catch(error => console.error("Error:", error));
curl -X POST "https://gateway.pixazo.ai/qwen-image-3-0/v1/image-to-image/fusion" \
  -H "Content-Type: application/json" \
  -H "Cache-Control: no-cache" \
  -H "Ocp-Apim-Subscription-Key: YOUR_SUBSCRIPTION_KEY" \
  --data-raw '{
    "image_urls": [
      "https://pub-582b7213209642b9b995c96c95a30381.r2.dev/doc-assets/images/fusion-a.jpg",
      "https://pub-582b7213209642b9b995c96c95a30381.r2.dev/doc-assets/images/fusion-b.jpg"
    ],
    "prompt": "Blend the two portraits into a single cinematic double-exposure composition"
  }'

Output

{
  "request_id": "qwen-image-3-0_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
  "status": "QUEUED",
  "polling_url": "https://gateway.pixazo.ai/v2/requests/status/qwen-image-3-0_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"
}

Webhook (Optional)

Add the X-Webhook-URL header to your submit request to receive a POST callback when the job completes — no polling required.

Using curl? These are HTTP request headers — pass each with -H, e.g. -H "X-Webhook-URL: https://your-server.com/webhook/callback". Do not paste them as bare lines, and end every line of a multi-line command with \.

Webhook Headers

HeaderRequiredDefaultDescription
X-Webhook-URLYes (to enable)—HTTPS endpoint on your server that will receive the POST callback. Must respond 2xx within a few seconds (process async if needed).
X-Webhook-ModeNoterminalterminal — fires once at the final status (COMPLETED/FAILED/ERROR). sync — fires on every poll cycle plus the terminal event, and caps the queue’s polling delay at 15s for tighter progress updates.

Example: enable webhook

X-Webhook-URL: https://your-server.com/webhook/callback
X-Webhook-Mode: terminal

Callback Payload

Your endpoint receives a POST application/json with the same shape as the GET /v2/requests/status/{request_id} response. Example terminal callback (mode terminal):

{
  "request_id": "qwen-image-3-0_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
  "status": "COMPLETED",
  "model_id": "qwen-image-3-0",
  "error": null,
  "output": {
    "media_url": [
      "https://pub-582b7213209642b9b995c96c95a30381.r2.dev/v1/qwen-image-3-0_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx/output.png"
    ],
    "media_type": "image/png"
  },
  "created_at": "2026-07-23T10:00:00.000Z",
  "updated_at": "2026-07-23 10:00:15",
  "completed_at": "2026-07-23 10:00:15"
}

Failure callback shape

{
  "request_id": "qwen-image-3-0_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
  "status": "ERROR",
  "model_id": "qwen-image-3-0",
  "error": "Description of the error",
  "output": null,
  "created_at": "...",
  "updated_at": "...",
  "completed_at": "..."
}

Delivery semantics

  • terminal mode (default) — exactly one POST when the request reaches a terminal status. No callback during PROCESSING.
  • sync mode — POST on every status poll (with delay capped at ~15s) plus a final POST at terminal status. Use when you want progress updates.
  • Idempotency — use request_id as your idempotency key. Network retries can deliver the same callback more than once; your handler must tolerate duplicates.
  • Response — respond 200 OK within a few seconds. The queue does not block on slow handlers, but persistent failures may stop further deliveries.
  • HTTPS required — plain http:// URLs are rejected.

Request Parameters - Image to Image Fusion

Requests that set n > 1 are billed per image.

ParameterRequiredTypeDefaultAllowed values / range
image_urlsYesrequiredarray of strings—2–3 URLs
An array of 2 to 3 publicly accessible HTTP/HTTPS image URLs to fuse into a single output image (array order defines the composition sequence). Each image — formats JPG, JPEG, PNG, BMP, TIFF, WEBP, GIF, width & height 384–2048 px (recommended), up to 10 MB.
promptYesrequiredstring——
A detailed description of how the input images should be fused or composed together.
sizeNostringautoauto · aspect ratio · WIDTHxHEIGHT
Output resolution. Accepts auto (default — the model chooses a size), an aspect-ratio string (1:1, 4:3, 3:4, 16:9, 9:16, 3:2, 2:3, 21:9), or an explicit WIDTHxHEIGHT with each side 512–2048 px (e.g. 1024x1024, 1536x1024, 1328x1328). Also works with n > 1.
nNointeger11–6
Number of images to generate in a single request. Billed per image — n images cost n × the per-image price.
negative_promptNostring——
A description of elements to avoid in the generated image. Helps steer the model away from unwanted features.
seedNointeger——
Random seed for reproducibility. Reuse the same seed with identical inputs to reproduce a result; omit for a random seed each request.
watermarkNobooleanfalsetrue, false
When true, adds a small "Qwen-Image" watermark to the bottom-right corner. Defaults to false (no watermark).
prompt_extendNobooleantruetrue, false
Automatically rewrites and enriches your prompt with an LLM before generation to improve results. Enabled by default.

Minimum Request

{
  "image_urls": [
    "https://pub-582b7213209642b9b995c96c95a30381.r2.dev/doc-assets/images/fusion-a.jpg",
    "https://pub-582b7213209642b9b995c96c95a30381.r2.dev/doc-assets/images/fusion-b.jpg"
  ],
  "prompt": "Blend the two portraits into a single cinematic double-exposure composition"
}

Full Request (all options)

{
  "image_urls": [
    "https://pub-582b7213209642b9b995c96c95a30381.r2.dev/doc-assets/images/fusion-a.jpg",
    "https://pub-582b7213209642b9b995c96c95a30381.r2.dev/doc-assets/images/fusion-b.jpg"
  ],
  "prompt": "Blend the two portraits into a single cinematic double-exposure composition",
  "size": "1024x1024",
  "n": 1,
  "negative_prompt": "low resolution, artifacts, distorted",
  "seed": 42,
  "watermark": false,
  "prompt_extend": true
}

Response

{
  "request_id": "qwen-image-3-0_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
  "status": "QUEUED",
  "polling_url": "https://gateway.pixazo.ai/v2/requests/status/qwen-image-3-0_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"
}

Request Headers

HeaderValue
Content-Typeapplication/json
Cache-Controlno-cache
Ocp-Apim-Subscription-KeyYour API subscription key

Response Handling

Common status codes for Image to Image Fusion.

CodeMeaning
202Accepted — Request queued
Bad Request
401Unauthorized
402Insufficient Balance
403Forbidden
Too Many Requests
500Internal Server Error

Error Responses

Queue system errors and model validation errors.

Queue System Errors

// 402 — Insufficient balance
{
  "error": "Insufficient Balance",
  "message": "Your wallet does not have enough balance."
}
// 400 — Model not found
{
  "error": "Model not found",
  "message": "Model 'qwen-image-3-0' not found or is disabled"
}

Error via Status/Webhook

{
  "request_id": "qwen-image-3-0_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
  "status": "ERROR",
  "model_id": "qwen-image-3-0",
  "error": "Description of the error",
  "output": null
}

Retrieving Results

Poll the universal status endpoint to check progress and retrieve results.

Endpoint

GET https://gateway.pixazo.ai/v2/requests/status/{request_id}
Ocp-Apim-Subscription-Key: YOUR_API_KEY

cURL Example

curl -H "Ocp-Apim-Subscription-Key: YOUR_API_KEY" \
  "https://gateway.pixazo.ai/v2/requests/status/qwen-image-3-0_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"

Response (Completed)

{
  "request_id": "qwen-image-3-0_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
  "status": "COMPLETED",
  "model_id": "qwen-image-3-0",
  "error": null,
  "output": {
    "media_url": [
      "https://pub-582b7213209642b9b995c96c95a30381.r2.dev/v1/qwen-image-3-0_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx/output.png"
    ],
    "media_type": "image/png"
  },
  "created_at": "2026-07-23T10:00:00.000Z",
  "updated_at": "2026-07-23 10:00:15",
  "completed_at": "2026-07-23 10:00:15"
}

Response Fields

FieldTypeDescription
request_idstringUnique request identifier
statusstringQUEUED, PROCESSING, COMPLETED, FAILED, or ERROR
model_idstringModel that processed the request
errorstring|nullError message if failed
output.media_urlarrayURLs to generated images (R2 CDN)
output.media_typestringMIME type of the output (image/png)
created_atstringWhen request was created
completed_atstring|nullWhen request completed
polling_urlstringStatus URL (initial response only)

Status Values

StatusDescription
QUEUEDRequest accepted, waiting to be processed
PROCESSINGBeing processed by the model
COMPLETEDDone — output contains the result
FAILEDFailed — check error field
ERRORSystem error (e.g. bad inputs) — not charged

Status Flow

QUEUED → PROCESSING → COMPLETED
                    → FAILED
                    → ERROR

Typical Workflow

  1. Send a image to image fusion request to the API endpoint
  2. Save the request_id from the response
  3. Poll every 5-10 seconds: GET /v2/requests/status/{request_id}
  4. When status is "COMPLETED", download from output.media_url

Tip: Use X-Webhook-URL header to get a callback instead of polling.

Qwen Image 3.0 Standard API Pricing

Your request will cost $0.039 per image.
2. Qwen Image 3.0 Pro

Qwen Image 3.0 Pro API Documentation

https://gateway.pixazo.ai/qwen-image-3-0-pro/v1/text-to-image

Authentication

All requests require an API key passed via header.

HeaderTypeRequiredDescription
Ocp-Apim-Subscription-KeystringYesYour API subscription key

Text to Image - Qwen Image 3.0 Pro

Request Code

POST https://gateway.pixazo.ai/qwen-image-3-0-pro/v1/text-to-image
Content-Type: application/json
Cache-Control: no-cache
Ocp-Apim-Subscription-Key: YOUR_SUBSCRIPTION_KEY

{
  "prompt": "A majestic white tiger resting on a mossy rock beside a waterfall in a tropical rainforest, photorealistic"
}
import requests

url = "https://gateway.pixazo.ai/qwen-image-3-0-pro/v1/text-to-image"
headers = {
    "Content-Type": "application/json",
    "Cache-Control": "no-cache",
    "Ocp-Apim-Subscription-Key": "YOUR_SUBSCRIPTION_KEY"
}
data = {
    "prompt": "A majestic white tiger resting on a mossy rock beside a waterfall in a tropical rainforest, photorealistic"
}

response = requests.post(url, json=data, headers=headers)
print(response.json())
const url = "https://gateway.pixazo.ai/qwen-image-3-0-pro/v1/text-to-image";
const headers = {
  "Content-Type": "application/json",
  "Cache-Control": "no-cache",
  "Ocp-Apim-Subscription-Key": "YOUR_SUBSCRIPTION_KEY"
};
const data = {
  prompt: "A majestic white tiger resting on a mossy rock beside a waterfall in a tropical rainforest, photorealistic"
};

fetch(url, {
  method: "POST",
  headers: headers,
  body: JSON.stringify(data)
})
.then(response => response.json())
.then(data => console.log(data))
.catch(error => console.error("Error:", error));
curl -X POST "https://gateway.pixazo.ai/qwen-image-3-0-pro/v1/text-to-image" \
  -H "Content-Type: application/json" \
  -H "Cache-Control: no-cache" \
  -H "Ocp-Apim-Subscription-Key: YOUR_SUBSCRIPTION_KEY" \
  --data-raw '{
    "prompt": "A majestic white tiger resting on a mossy rock beside a waterfall in a tropical rainforest, photorealistic"
  }'

Output

{
  "request_id": "qwen-image-3-0-pro_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
  "status": "QUEUED",
  "polling_url": "https://gateway.pixazo.ai/v2/requests/status/qwen-image-3-0-pro_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"
}

Webhook (Optional)

Add the X-Webhook-URL header to your submit request to receive a POST callback when the job completes — no polling required.

Using curl? These are HTTP request headers — pass each with -H, e.g. -H "X-Webhook-URL: https://your-server.com/webhook/callback". Do not paste them as bare lines, and end every line of a multi-line command with \.

Webhook Headers

HeaderRequiredDefaultDescription
X-Webhook-URLYes (to enable)—HTTPS endpoint on your server that will receive the POST callback. Must respond 2xx within a few seconds (process async if needed).
X-Webhook-ModeNoterminalterminal — fires once at the final status (COMPLETED/FAILED/ERROR). sync — fires on every poll cycle plus the terminal event, and caps the queue’s polling delay at 15s for tighter progress updates.

Example: enable webhook

X-Webhook-URL: https://your-server.com/webhook/callback
X-Webhook-Mode: terminal

Callback Payload

Your endpoint receives a POST application/json with the same shape as the GET /v2/requests/status/{request_id} response. Example terminal callback (mode terminal):

{
  "request_id": "qwen-image-3-0-pro_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
  "status": "COMPLETED",
  "model_id": "qwen-image-3-0-pro",
  "error": null,
  "output": {
    "media_url": [
      "https://pub-582b7213209642b9b995c96c95a30381.r2.dev/v1/qwen-image-3-0-pro_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx/output.png"
    ],
    "media_type": "image/png"
  },
  "created_at": "2026-07-23T10:00:00.000Z",
  "updated_at": "2026-07-23 10:00:15",
  "completed_at": "2026-07-23 10:00:15"
}

Failure callback shape

{
  "request_id": "qwen-image-3-0-pro_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
  "status": "ERROR",
  "model_id": "qwen-image-3-0-pro",
  "error": "Description of the error",
  "output": null,
  "created_at": "...",
  "updated_at": "...",
  "completed_at": "..."
}

Delivery semantics

  • terminal mode (default) — exactly one POST when the request reaches a terminal status. No callback during PROCESSING.
  • sync mode — POST on every status poll (with delay capped at ~15s) plus a final POST at terminal status. Use when you want progress updates.
  • Idempotency — use request_id as your idempotency key. Network retries can deliver the same callback more than once; your handler must tolerate duplicates.
  • Response — respond 200 OK within a few seconds. The queue does not block on slow handlers, but persistent failures may stop further deliveries.
  • HTTPS required — plain http:// URLs are rejected.

Request Parameters - Text to Image

Requests that set n > 1 are billed per image.

ParameterRequiredTypeDefaultAllowed values / range
promptYesrequiredstring——
A detailed text description of the desired image. Be specific about subjects, style, lighting, and composition.
sizeNostringautoauto · aspect ratio · WIDTHxHEIGHT
Output resolution. Accepts auto (default — the model chooses a size), an aspect-ratio string (1:1, 4:3, 3:4, 16:9, 9:16, 3:2, 2:3, 21:9), or an explicit WIDTHxHEIGHT with each side 512–2048 px (e.g. 1024x1024, 1536x1024, 1328x1328). Also works with n > 1.
nNointeger11–6
Number of images to generate in a single request. Billed per image — n images cost n × the per-image price.
negative_promptNostring——
A description of elements to avoid in the generated image. Helps steer the model away from unwanted features.
seedNointeger——
Random seed for reproducibility. Reuse the same seed with identical inputs to reproduce a result; omit for a random seed each request.
watermarkNobooleanfalsetrue, false
When true, adds a small "Qwen-Image" watermark to the bottom-right corner. Defaults to false (no watermark).
prompt_extendNobooleantruetrue, false
Automatically rewrites and enriches your prompt with an LLM before generation to improve results. Enabled by default.

Minimum Request

{
  "prompt": "A majestic white tiger resting on a mossy rock beside a waterfall in a tropical rainforest, photorealistic"
}

Full Request (all options)

{
  "prompt": "A majestic white tiger resting on a mossy rock beside a waterfall in a tropical rainforest, photorealistic",
  "size": "1024x1024",
  "n": 1,
  "negative_prompt": "low resolution, error, worst quality, low quality, deformed",
  "seed": 42,
  "watermark": false,
  "prompt_extend": true
}

Response

{
  "request_id": "qwen-image-3-0-pro_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
  "status": "QUEUED",
  "polling_url": "https://gateway.pixazo.ai/v2/requests/status/qwen-image-3-0-pro_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"
}

Request Headers

HeaderValue
Content-Typeapplication/json
Cache-Controlno-cache
Ocp-Apim-Subscription-KeyYour API subscription key

Response Handling

Common status codes for Text to Image.

CodeMeaning
202Accepted — Request queued
Bad Request
401Unauthorized
402Insufficient Balance
403Forbidden
Too Many Requests
500Internal Server Error

Error Responses

Queue system errors and model validation errors.

Queue System Errors

// 402 — Insufficient balance
{
  "error": "Insufficient Balance",
  "message": "Your wallet does not have enough balance."
}
// 400 — Model not found
{
  "error": "Model not found",
  "message": "Model 'qwen-image-3-0-pro' not found or is disabled"
}

Error via Status/Webhook

{
  "request_id": "qwen-image-3-0-pro_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
  "status": "ERROR",
  "model_id": "qwen-image-3-0-pro",
  "error": "Description of the error",
  "output": null
}

Retrieving Results

Poll the universal status endpoint to check progress and retrieve results.

Endpoint

GET https://gateway.pixazo.ai/v2/requests/status/{request_id}
Ocp-Apim-Subscription-Key: YOUR_API_KEY

cURL Example

curl -H "Ocp-Apim-Subscription-Key: YOUR_API_KEY" \
  "https://gateway.pixazo.ai/v2/requests/status/qwen-image-3-0-pro_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"

Response (Completed)

{
  "request_id": "qwen-image-3-0-pro_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
  "status": "COMPLETED",
  "model_id": "qwen-image-3-0-pro",
  "error": null,
  "output": {
    "media_url": [
      "https://pub-582b7213209642b9b995c96c95a30381.r2.dev/v1/qwen-image-3-0-pro_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx/output.png"
    ],
    "media_type": "image/png"
  },
  "created_at": "2026-07-23T10:00:00.000Z",
  "updated_at": "2026-07-23 10:00:15",
  "completed_at": "2026-07-23 10:00:15"
}

Response Fields

FieldTypeDescription
request_idstringUnique request identifier
statusstringQUEUED, PROCESSING, COMPLETED, FAILED, or ERROR
model_idstringModel that processed the request
errorstring|nullError message if failed
output.media_urlarrayURLs to generated images (R2 CDN)
output.media_typestringMIME type of the output (image/png)
created_atstringWhen request was created
completed_atstring|nullWhen request completed
polling_urlstringStatus URL (initial response only)

Status Values

StatusDescription
QUEUEDRequest accepted, waiting to be processed
PROCESSINGBeing processed by the model
COMPLETEDDone — output contains the result
FAILEDFailed — check error field
ERRORSystem error (e.g. bad inputs) — not charged

Status Flow

QUEUED → PROCESSING → COMPLETED
                    → FAILED
                    → ERROR

Typical Workflow

  1. Send a text to image request to the API endpoint
  2. Save the request_id from the response
  3. Poll every 5-10 seconds: GET /v2/requests/status/{request_id}
  4. When status is "COMPLETED", download from output.media_url

Tip: Use X-Webhook-URL header to get a callback instead of polling.

Qwen Image 3.0 Pro API Pricing

Your request will cost $0.084 per image.
Image to Image (Editing)

Qwen Image 3.0 Pro API Documentation

https://gateway.pixazo.ai/qwen-image-3-0-pro/v1/image-to-image/editing

Authentication

All requests require an API key passed via header.

HeaderTypeRequiredDescription
Ocp-Apim-Subscription-KeystringYesYour API subscription key

Image to Image Editing - Qwen Image 3.0 Pro

Request Code

POST https://gateway.pixazo.ai/qwen-image-3-0-pro/v1/image-to-image/editing
Content-Type: application/json
Cache-Control: no-cache
Ocp-Apim-Subscription-Key: YOUR_SUBSCRIPTION_KEY

{
  "image_url": "https://pub-582b7213209642b9b995c96c95a30381.r2.dev/doc-assets/images/input.jpg",
  "prompt": "Change the background to a snowy mountain landscape at golden hour"
}
import requests

url = "https://gateway.pixazo.ai/qwen-image-3-0-pro/v1/image-to-image/editing"
headers = {
    "Content-Type": "application/json",
    "Cache-Control": "no-cache",
    "Ocp-Apim-Subscription-Key": "YOUR_SUBSCRIPTION_KEY"
}
data = {
    "image_url": "https://pub-582b7213209642b9b995c96c95a30381.r2.dev/doc-assets/images/input.jpg",
    "prompt": "Change the background to a snowy mountain landscape at golden hour"
}

response = requests.post(url, json=data, headers=headers)
print(response.json())
const url = "https://gateway.pixazo.ai/qwen-image-3-0-pro/v1/image-to-image/editing";
const headers = {
  "Content-Type": "application/json",
  "Cache-Control": "no-cache",
  "Ocp-Apim-Subscription-Key": "YOUR_SUBSCRIPTION_KEY"
};
const data = {
  image_url: "https://pub-582b7213209642b9b995c96c95a30381.r2.dev/doc-assets/images/input.jpg",
  prompt: "Change the background to a snowy mountain landscape at golden hour"
};

fetch(url, {
  method: "POST",
  headers: headers,
  body: JSON.stringify(data)
})
.then(response => response.json())
.then(data => console.log(data))
.catch(error => console.error("Error:", error));
curl -X POST "https://gateway.pixazo.ai/qwen-image-3-0-pro/v1/image-to-image/editing" \
  -H "Content-Type: application/json" \
  -H "Cache-Control: no-cache" \
  -H "Ocp-Apim-Subscription-Key: YOUR_SUBSCRIPTION_KEY" \
  --data-raw '{
    "image_url": "https://pub-582b7213209642b9b995c96c95a30381.r2.dev/doc-assets/images/input.jpg",
    "prompt": "Change the background to a snowy mountain landscape at golden hour"
  }'

Output

{
  "request_id": "qwen-image-3-0-pro_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
  "status": "QUEUED",
  "polling_url": "https://gateway.pixazo.ai/v2/requests/status/qwen-image-3-0-pro_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"
}

Webhook (Optional)

Add the X-Webhook-URL header to your submit request to receive a POST callback when the job completes — no polling required.

Using curl? These are HTTP request headers — pass each with -H, e.g. -H "X-Webhook-URL: https://your-server.com/webhook/callback". Do not paste them as bare lines, and end every line of a multi-line command with \.

Webhook Headers

HeaderRequiredDefaultDescription
X-Webhook-URLYes (to enable)—HTTPS endpoint on your server that will receive the POST callback. Must respond 2xx within a few seconds (process async if needed).
X-Webhook-ModeNoterminalterminal — fires once at the final status (COMPLETED/FAILED/ERROR). sync — fires on every poll cycle plus the terminal event, and caps the queue’s polling delay at 15s for tighter progress updates.

Example: enable webhook

X-Webhook-URL: https://your-server.com/webhook/callback
X-Webhook-Mode: terminal

Callback Payload

Your endpoint receives a POST application/json with the same shape as the GET /v2/requests/status/{request_id} response. Example terminal callback (mode terminal):

{
  "request_id": "qwen-image-3-0-pro_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
  "status": "COMPLETED",
  "model_id": "qwen-image-3-0-pro",
  "error": null,
  "output": {
    "media_url": [
      "https://pub-582b7213209642b9b995c96c95a30381.r2.dev/v1/qwen-image-3-0-pro_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx/output.png"
    ],
    "media_type": "image/png"
  },
  "created_at": "2026-07-23T10:00:00.000Z",
  "updated_at": "2026-07-23 10:00:15",
  "completed_at": "2026-07-23 10:00:15"
}

Failure callback shape

{
  "request_id": "qwen-image-3-0-pro_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
  "status": "ERROR",
  "model_id": "qwen-image-3-0-pro",
  "error": "Description of the error",
  "output": null,
  "created_at": "...",
  "updated_at": "...",
  "completed_at": "..."
}

Delivery semantics

  • terminal mode (default) — exactly one POST when the request reaches a terminal status. No callback during PROCESSING.
  • sync mode — POST on every status poll (with delay capped at ~15s) plus a final POST at terminal status. Use when you want progress updates.
  • Idempotency — use request_id as your idempotency key. Network retries can deliver the same callback more than once; your handler must tolerate duplicates.
  • Response — respond 200 OK within a few seconds. The queue does not block on slow handlers, but persistent failures may stop further deliveries.
  • HTTPS required — plain http:// URLs are rejected.

Request Parameters - Image to Image Editing

Requests that set n > 1 are billed per image.

ParameterRequiredTypeDefaultAllowed values / range
image_urlYesrequiredstring——
Publicly accessible HTTP/HTTPS URL of the single source image to edit (exactly one). Accepted formats: JPG, JPEG, PNG, BMP, TIFF, WEBP, GIF. Width & height 384–2048 px (recommended for best results); file size up to 10 MB.
promptYesrequiredstring——
A detailed description of the edit to apply to the source image.
sizeNostringautoauto · aspect ratio · WIDTHxHEIGHT
Output resolution. Accepts auto (default — the model chooses a size), an aspect-ratio string (1:1, 4:3, 3:4, 16:9, 9:16, 3:2, 2:3, 21:9), or an explicit WIDTHxHEIGHT with each side 512–2048 px (e.g. 1024x1024, 1536x1024, 1328x1328). Also works with n > 1.
nNointeger11–6
Number of images to generate in a single request. Billed per image — n images cost n × the per-image price.
negative_promptNostring——
A description of elements to avoid in the generated image. Helps steer the model away from unwanted features.
seedNointeger——
Random seed for reproducibility. Reuse the same seed with identical inputs to reproduce a result; omit for a random seed each request.
watermarkNobooleanfalsetrue, false
When true, adds a small "Qwen-Image" watermark to the bottom-right corner. Defaults to false (no watermark).
prompt_extendNobooleantruetrue, false
Automatically rewrites and enriches your prompt with an LLM before generation to improve results. Enabled by default.

Minimum Request

{
  "image_url": "https://pub-582b7213209642b9b995c96c95a30381.r2.dev/doc-assets/images/input.jpg",
  "prompt": "Change the background to a snowy mountain landscape at golden hour"
}

Full Request (all options)

{
  "image_url": "https://pub-582b7213209642b9b995c96c95a30381.r2.dev/doc-assets/images/input.jpg",
  "prompt": "Change the background to a snowy mountain landscape at golden hour",
  "size": "1024x1024",
  "n": 1,
  "negative_prompt": "low resolution, artifacts, distorted",
  "seed": 42,
  "watermark": false,
  "prompt_extend": true
}

Response

{
  "request_id": "qwen-image-3-0-pro_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
  "status": "QUEUED",
  "polling_url": "https://gateway.pixazo.ai/v2/requests/status/qwen-image-3-0-pro_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"
}

Request Headers

HeaderValue
Content-Typeapplication/json
Cache-Controlno-cache
Ocp-Apim-Subscription-KeyYour API subscription key

Response Handling

Common status codes for Image to Image Editing.

CodeMeaning
202Accepted — Request queued
Bad Request
401Unauthorized
402Insufficient Balance
403Forbidden
Too Many Requests
500Internal Server Error

Error Responses

Queue system errors and model validation errors.

Queue System Errors

// 402 — Insufficient balance
{
  "error": "Insufficient Balance",
  "message": "Your wallet does not have enough balance."
}
// 400 — Model not found
{
  "error": "Model not found",
  "message": "Model 'qwen-image-3-0-pro' not found or is disabled"
}

Error via Status/Webhook

{
  "request_id": "qwen-image-3-0-pro_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
  "status": "ERROR",
  "model_id": "qwen-image-3-0-pro",
  "error": "Description of the error",
  "output": null
}

Retrieving Results

Poll the universal status endpoint to check progress and retrieve results.

Endpoint

GET https://gateway.pixazo.ai/v2/requests/status/{request_id}
Ocp-Apim-Subscription-Key: YOUR_API_KEY

cURL Example

curl -H "Ocp-Apim-Subscription-Key: YOUR_API_KEY" \
  "https://gateway.pixazo.ai/v2/requests/status/qwen-image-3-0-pro_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"

Response (Completed)

{
  "request_id": "qwen-image-3-0-pro_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
  "status": "COMPLETED",
  "model_id": "qwen-image-3-0-pro",
  "error": null,
  "output": {
    "media_url": [
      "https://pub-582b7213209642b9b995c96c95a30381.r2.dev/v1/qwen-image-3-0-pro_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx/output.png"
    ],
    "media_type": "image/png"
  },
  "created_at": "2026-07-23T10:00:00.000Z",
  "updated_at": "2026-07-23 10:00:15",
  "completed_at": "2026-07-23 10:00:15"
}

Response Fields

FieldTypeDescription
request_idstringUnique request identifier
statusstringQUEUED, PROCESSING, COMPLETED, FAILED, or ERROR
model_idstringModel that processed the request
errorstring|nullError message if failed
output.media_urlarrayURLs to generated images (R2 CDN)
output.media_typestringMIME type of the output (image/png)
created_atstringWhen request was created
completed_atstring|nullWhen request completed
polling_urlstringStatus URL (initial response only)

Status Values

StatusDescription
QUEUEDRequest accepted, waiting to be processed
PROCESSINGBeing processed by the model
COMPLETEDDone — output contains the result
FAILEDFailed — check error field
ERRORSystem error (e.g. bad inputs) — not charged

Status Flow

QUEUED → PROCESSING → COMPLETED
                    → FAILED
                    → ERROR

Typical Workflow

  1. Send a image to image editing request to the API endpoint
  2. Save the request_id from the response
  3. Poll every 5-10 seconds: GET /v2/requests/status/{request_id}
  4. When status is "COMPLETED", download from output.media_url

Tip: Use X-Webhook-URL header to get a callback instead of polling.

Qwen Image 3.0 Pro API Pricing

Your request will cost $0.084 per image.
Image to Image (Fusion)

Qwen Image 3.0 Pro API Documentation

https://gateway.pixazo.ai/qwen-image-3-0-pro/v1/image-to-image/fusion

Authentication

All requests require an API key passed via header.

HeaderTypeRequiredDescription
Ocp-Apim-Subscription-KeystringYesYour API subscription key

Image to Image Fusion - Qwen Image 3.0 Pro

Request Code

POST https://gateway.pixazo.ai/qwen-image-3-0-pro/v1/image-to-image/fusion
Content-Type: application/json
Cache-Control: no-cache
Ocp-Apim-Subscription-Key: YOUR_SUBSCRIPTION_KEY

{
  "image_urls": [
    "https://pub-582b7213209642b9b995c96c95a30381.r2.dev/doc-assets/images/fusion-a.jpg",
    "https://pub-582b7213209642b9b995c96c95a30381.r2.dev/doc-assets/images/fusion-b.jpg"
  ],
  "prompt": "Blend the two portraits into a single cinematic double-exposure composition"
}
import requests

url = "https://gateway.pixazo.ai/qwen-image-3-0-pro/v1/image-to-image/fusion"
headers = {
    "Content-Type": "application/json",
    "Cache-Control": "no-cache",
    "Ocp-Apim-Subscription-Key": "YOUR_SUBSCRIPTION_KEY"
}
data = {
    "image_urls": [
        "https://pub-582b7213209642b9b995c96c95a30381.r2.dev/doc-assets/images/fusion-a.jpg",
        "https://pub-582b7213209642b9b995c96c95a30381.r2.dev/doc-assets/images/fusion-b.jpg"
    ],
    "prompt": "Blend the two portraits into a single cinematic double-exposure composition"
}

response = requests.post(url, json=data, headers=headers)
print(response.json())
const url = "https://gateway.pixazo.ai/qwen-image-3-0-pro/v1/image-to-image/fusion";
const headers = {
  "Content-Type": "application/json",
  "Cache-Control": "no-cache",
  "Ocp-Apim-Subscription-Key": "YOUR_SUBSCRIPTION_KEY"
};
const data = {
  image_urls: [
    "https://pub-582b7213209642b9b995c96c95a30381.r2.dev/doc-assets/images/fusion-a.jpg",
    "https://pub-582b7213209642b9b995c96c95a30381.r2.dev/doc-assets/images/fusion-b.jpg"
  ],
  prompt: "Blend the two portraits into a single cinematic double-exposure composition"
};

fetch(url, {
  method: "POST",
  headers: headers,
  body: JSON.stringify(data)
})
.then(response => response.json())
.then(data => console.log(data))
.catch(error => console.error("Error:", error));
curl -X POST "https://gateway.pixazo.ai/qwen-image-3-0-pro/v1/image-to-image/fusion" \
  -H "Content-Type: application/json" \
  -H "Cache-Control: no-cache" \
  -H "Ocp-Apim-Subscription-Key: YOUR_SUBSCRIPTION_KEY" \
  --data-raw '{
    "image_urls": [
      "https://pub-582b7213209642b9b995c96c95a30381.r2.dev/doc-assets/images/fusion-a.jpg",
      "https://pub-582b7213209642b9b995c96c95a30381.r2.dev/doc-assets/images/fusion-b.jpg"
    ],
    "prompt": "Blend the two portraits into a single cinematic double-exposure composition"
  }'

Output

{
  "request_id": "qwen-image-3-0-pro_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
  "status": "QUEUED",
  "polling_url": "https://gateway.pixazo.ai/v2/requests/status/qwen-image-3-0-pro_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"
}

Webhook (Optional)

Add the X-Webhook-URL header to your submit request to receive a POST callback when the job completes — no polling required.

Using curl? These are HTTP request headers — pass each with -H, e.g. -H "X-Webhook-URL: https://your-server.com/webhook/callback". Do not paste them as bare lines, and end every line of a multi-line command with \.

Webhook Headers

HeaderRequiredDefaultDescription
X-Webhook-URLYes (to enable)—HTTPS endpoint on your server that will receive the POST callback. Must respond 2xx within a few seconds (process async if needed).
X-Webhook-ModeNoterminalterminal — fires once at the final status (COMPLETED/FAILED/ERROR). sync — fires on every poll cycle plus the terminal event, and caps the queue’s polling delay at 15s for tighter progress updates.

Example: enable webhook

X-Webhook-URL: https://your-server.com/webhook/callback
X-Webhook-Mode: terminal

Callback Payload

Your endpoint receives a POST application/json with the same shape as the GET /v2/requests/status/{request_id} response. Example terminal callback (mode terminal):

{
  "request_id": "qwen-image-3-0-pro_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
  "status": "COMPLETED",
  "model_id": "qwen-image-3-0-pro",
  "error": null,
  "output": {
    "media_url": [
      "https://pub-582b7213209642b9b995c96c95a30381.r2.dev/v1/qwen-image-3-0-pro_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx/output.png"
    ],
    "media_type": "image/png"
  },
  "created_at": "2026-07-23T10:00:00.000Z",
  "updated_at": "2026-07-23 10:00:15",
  "completed_at": "2026-07-23 10:00:15"
}

Failure callback shape

{
  "request_id": "qwen-image-3-0-pro_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
  "status": "ERROR",
  "model_id": "qwen-image-3-0-pro",
  "error": "Description of the error",
  "output": null,
  "created_at": "...",
  "updated_at": "...",
  "completed_at": "..."
}

Delivery semantics

  • terminal mode (default) — exactly one POST when the request reaches a terminal status. No callback during PROCESSING.
  • sync mode — POST on every status poll (with delay capped at ~15s) plus a final POST at terminal status. Use when you want progress updates.
  • Idempotency — use request_id as your idempotency key. Network retries can deliver the same callback more than once; your handler must tolerate duplicates.
  • Response — respond 200 OK within a few seconds. The queue does not block on slow handlers, but persistent failures may stop further deliveries.
  • HTTPS required — plain http:// URLs are rejected.

Request Parameters - Image to Image Fusion

Requests that set n > 1 are billed per image.

ParameterRequiredTypeDefaultAllowed values / range
image_urlsYesrequiredarray of strings—2–3 URLs
An array of 2 to 3 publicly accessible HTTP/HTTPS image URLs to fuse into a single output image (array order defines the composition sequence). Each image — formats JPG, JPEG, PNG, BMP, TIFF, WEBP, GIF, width & height 384–2048 px (recommended), up to 10 MB.
promptYesrequiredstring——
A detailed description of how the input images should be fused or composed together.
sizeNostringautoauto · aspect ratio · WIDTHxHEIGHT
Output resolution. Accepts auto (default — the model chooses a size), an aspect-ratio string (1:1, 4:3, 3:4, 16:9, 9:16, 3:2, 2:3, 21:9), or an explicit WIDTHxHEIGHT with each side 512–2048 px (e.g. 1024x1024, 1536x1024, 1328x1328). Also works with n > 1.
nNointeger11–6
Number of images to generate in a single request. Billed per image — n images cost n × the per-image price.
negative_promptNostring——
A description of elements to avoid in the generated image. Helps steer the model away from unwanted features.
seedNointeger——
Random seed for reproducibility. Reuse the same seed with identical inputs to reproduce a result; omit for a random seed each request.
watermarkNobooleanfalsetrue, false
When true, adds a small "Qwen-Image" watermark to the bottom-right corner. Defaults to false (no watermark).
prompt_extendNobooleantruetrue, false
Automatically rewrites and enriches your prompt with an LLM before generation to improve results. Enabled by default.

Minimum Request

{
  "image_urls": [
    "https://pub-582b7213209642b9b995c96c95a30381.r2.dev/doc-assets/images/fusion-a.jpg",
    "https://pub-582b7213209642b9b995c96c95a30381.r2.dev/doc-assets/images/fusion-b.jpg"
  ],
  "prompt": "Blend the two portraits into a single cinematic double-exposure composition"
}

Full Request (all options)

{
  "image_urls": [
    "https://pub-582b7213209642b9b995c96c95a30381.r2.dev/doc-assets/images/fusion-a.jpg",
    "https://pub-582b7213209642b9b995c96c95a30381.r2.dev/doc-assets/images/fusion-b.jpg"
  ],
  "prompt": "Blend the two portraits into a single cinematic double-exposure composition",
  "size": "1024x1024",
  "n": 1,
  "negative_prompt": "low resolution, artifacts, distorted",
  "seed": 42,
  "watermark": false,
  "prompt_extend": true
}

Response

{
  "request_id": "qwen-image-3-0-pro_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
  "status": "QUEUED",
  "polling_url": "https://gateway.pixazo.ai/v2/requests/status/qwen-image-3-0-pro_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"
}

Request Headers

HeaderValue
Content-Typeapplication/json
Cache-Controlno-cache
Ocp-Apim-Subscription-KeyYour API subscription key

Response Handling

Common status codes for Image to Image Fusion.

CodeMeaning
202Accepted — Request queued
Bad Request
401Unauthorized
402Insufficient Balance
403Forbidden
Too Many Requests
500Internal Server Error

Error Responses

Queue system errors and model validation errors.

Queue System Errors

// 402 — Insufficient balance
{
  "error": "Insufficient Balance",
  "message": "Your wallet does not have enough balance."
}
// 400 — Model not found
{
  "error": "Model not found",
  "message": "Model 'qwen-image-3-0-pro' not found or is disabled"
}

Error via Status/Webhook

{
  "request_id": "qwen-image-3-0-pro_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
  "status": "ERROR",
  "model_id": "qwen-image-3-0-pro",
  "error": "Description of the error",
  "output": null
}

Retrieving Results

Poll the universal status endpoint to check progress and retrieve results.

Endpoint

GET https://gateway.pixazo.ai/v2/requests/status/{request_id}
Ocp-Apim-Subscription-Key: YOUR_API_KEY

cURL Example

curl -H "Ocp-Apim-Subscription-Key: YOUR_API_KEY" \
  "https://gateway.pixazo.ai/v2/requests/status/qwen-image-3-0-pro_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"

Response (Completed)

{
  "request_id": "qwen-image-3-0-pro_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
  "status": "COMPLETED",
  "model_id": "qwen-image-3-0-pro",
  "error": null,
  "output": {
    "media_url": [
      "https://pub-582b7213209642b9b995c96c95a30381.r2.dev/v1/qwen-image-3-0-pro_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx/output.png"
    ],
    "media_type": "image/png"
  },
  "created_at": "2026-07-23T10:00:00.000Z",
  "updated_at": "2026-07-23 10:00:15",
  "completed_at": "2026-07-23 10:00:15"
}

Response Fields

FieldTypeDescription
request_idstringUnique request identifier
statusstringQUEUED, PROCESSING, COMPLETED, FAILED, or ERROR
model_idstringModel that processed the request
errorstring|nullError message if failed
output.media_urlarrayURLs to generated images (R2 CDN)
output.media_typestringMIME type of the output (image/png)
created_atstringWhen request was created
completed_atstring|nullWhen request completed
polling_urlstringStatus URL (initial response only)

Status Values

StatusDescription
QUEUEDRequest accepted, waiting to be processed
PROCESSINGBeing processed by the model
COMPLETEDDone — output contains the result
FAILEDFailed — check error field
ERRORSystem error (e.g. bad inputs) — not charged

Status Flow

QUEUED → PROCESSING → COMPLETED
                    → FAILED
                    → ERROR

Typical Workflow

  1. Send a image to image fusion request to the API endpoint
  2. Save the request_id from the response
  3. Poll every 5-10 seconds: GET /v2/requests/status/{request_id}
  4. When status is "COMPLETED", download from output.media_url

Tip: Use X-Webhook-URL header to get a callback instead of polling.

Qwen Image 3.0 Pro API Pricing

Your request will cost $0.084 per image.
3. Qwen Image Max Edit

Qwen Image Max Edit API Documentation

https://gateway.pixazo.ai/qwen-image-max-edit/v1/qwen-image-max-edit-request

Authentication

All requests require an API key passed via header.

Header Type Required Description
Ocp-Apim-Subscription-Key string Yes Your API subscription key

Qwen Image Max Edit generate request - Qwen Image Max Edit

Request Code

POST https://gateway.pixazo.ai/qwen-image-max-edit/v1/qwen-image-max-edit-request
Content-Type: application/json
Cache-Control: no-cache
Ocp-Apim-Subscription-Key: YOUR_SUBSCRIPTION_KEY

{
  "prompt": "Transform the background into a serene mountain landscape with snow-capped peaks and a clear blue sky",
  "image_urls": [
    "https://imagesai.appypie.com/7686410/JUEOHp2Y3FDjmXwOQJVy_017731476841749.png"
  ]
}
import requests

url = "https://gateway.pixazo.ai/qwen-image-max-edit/v1/qwen-image-max-edit-request"
headers = {
    "Content-Type": "application/json",
    "Cache-Control": "no-cache",
    "Ocp-Apim-Subscription-Key": "YOUR_SUBSCRIPTION_KEY"
}
data = {
    "prompt": "Transform the background into a serene mountain landscape with snow-capped peaks and a clear blue sky",
    "image_urls": [
        "https://imagesai.appypie.com/7686410/JUEOHp2Y3FDjmXwOQJVy_017731476841749.png"
    ]
}

response = requests.post(url, json=data, headers=headers)
print(response.json())
const url = 'https://gateway.pixazo.ai/qwen-image-max-edit/v1/qwen-image-max-edit-request';

const headers = {
  'Content-Type': 'application/json',
  'Cache-Control': 'no-cache',
  'Ocp-Apim-Subscription-Key': 'YOUR_SUBSCRIPTION_KEY'
};

const data = {
  prompt: 'Transform the background into a serene mountain landscape with snow-capped peaks and a clear blue sky',
  image_urls: [
    'https://imagesai.appypie.com/7686410/JUEOHp2Y3FDjmXwOQJVy_017731476841749.png'
  ]
};

fetch(url, {
  method: 'POST',
  headers: headers,
  body: JSON.stringify(data)
})
.then(response => response.json())
.then(data => console.log(data))
.catch(error => console.error('Error:', error));
curl -X POST "https://gateway.pixazo.ai/qwen-image-max-edit/v1/qwen-image-max-edit-request" \
  -H "Content-Type: application/json" \
  -H "Cache-Control: no-cache" \
  -H "Ocp-Apim-Subscription-Key: YOUR_SUBSCRIPTION_KEY" \
  --data-raw '{
    "prompt": "Transform the background into a serene mountain landscape with snow-capped peaks and a clear blue sky",
    "image_urls": [
      "https://imagesai.appypie.com/7686410/JUEOHp2Y3FDjmXwOQJVy_017731476841749.png"
    ]
  }'

Output

{
  "request_id": "qwen-image-max-edit_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
  "status": "QUEUED",
  "polling_url": "https://gateway.pixazo.ai/v2/requests/status/qwen-image-max-edit_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"
}

Webhook (Optional)

Add the X-Webhook-URL header to your submit request to receive a POST callback when the job completes — no polling required.

Using curl? These are HTTP request headers — pass each with -H, e.g. -H "X-Webhook-URL: https://your-server.com/webhook/callback". Do not paste them as bare lines, and end every line of a multi-line command with \.

Webhook Headers

HeaderRequiredDefaultDescription
X-Webhook-URLYes (to enable)—HTTPS endpoint on your server that will receive the POST callback. Must respond 2xx within a few seconds (process async if needed).
X-Webhook-ModeNoterminalterminal — fires once at the final status (COMPLETED/FAILED/ERROR). sync — fires on every poll cycle plus the terminal event, and caps the queue’s polling delay at 15s for tighter progress updates.

Example: enable webhook

X-Webhook-URL: https://your-server.com/webhook/callback
X-Webhook-Mode: terminal

Callback Payload

Your endpoint receives a POST application/json with the same shape as the GET /v2/requests/status/{request_id} response. Example terminal callback (mode terminal):

{
  "request_id": "qwen-image-max-edit_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
  "status": "COMPLETED",
  "model_id": "qwen-image-max-edit",
  "error": null,
  "output": {
    "media_url": [
      "https://pub-582b7213209642b9b995c96c95a30381.r2.dev/v1/qwen-image-max-edit_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx/output.png"
    ],
    "media_type": "image/png"
  },
  "created_at": "2026-05-22T13:17:32.110Z",
  "updated_at": "2026-05-22 13:19:23",
  "completed_at": "2026-05-22 13:19:23"
}

Failure callback shape

{
  "request_id": "qwen-image-max-edit_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
  "status": "ERROR",
  "model_id": "qwen-image-max-edit",
  "error": "Description of the error",
  "output": null,
  "created_at": "...",
  "updated_at": "...",
  "completed_at": "..."
}

Delivery semantics

  • terminal mode (default) — exactly one POST when the request reaches a terminal status. No callback during PROCESSING.
  • sync mode — POST on every status poll (with delay capped at ~15s) plus a final POST at terminal status. Use when you want progress updates.
  • Idempotency — use request_id as your idempotency key. Network retries can deliver the same callback more than once; your handler must tolerate duplicates.
  • Response — respond 200 OK within a few seconds. The queue does not block on slow handlers, but persistent failures may stop further deliveries.
  • HTTPS required — plain http:// URLs are rejected.

Request Parameters - Qwen Image Max Edit generate request

ParameterRequiredTypeDefaultAllowed values / range
promptYesrequiredstring—Max 800 characters
Text prompt describing the desired edit. Supports Chinese and English. Be specific about the change (subject, context, lighting, environment).
negative_promptNostring""Max 500 characters
Describes unwanted elements or artifacts to avoid in the output. Improves quality by exclusion.
image_sizeNostring or object—square_hd, square, portrait_4_3, portrait_16_9, landscape_4_3, landscape_16_9, or a custom {width, height} object
Dimensions of the generated image. If omitted, the size of the input image is used.
enable_prompt_expansionNobooleantruetrue, false
Automatically rewrites and enriches your prompt with extra detail before generation to improve results.
seedNointeger—0–2147483647
Random seed for reproducible results. Reuse the same seed with the same inputs to regenerate a similar image.
enable_safety_checkerNobooleantruetrue, false
Turns on automatic filtering of unsafe or explicit (NSFW) content. Leave enabled unless you have a specific reason to disable it.
sync_modeNobooleanfalsetrue, false
When true, the image is returned inline as a data URI in the response instead of a hosted URL, and the output is not saved to your request history.
num_imagesNointeger11–6
Number of edited images to generate. Must be between 1 and 6.
output_formatNostringpngpng, jpeg, webp
Output image format. Supported values: png, jpeg, webp.
image_urlsYesrequiredarray of strings—1–3 image URLs
Public URLs of the reference image(s) to edit (1–3 images). Order matters — the first URL is image 1, the second image 2, and so on; reference them by position in your prompt. Each image 384–5000px per dimension, max 10 MB; JPG, PNG (no alpha), or WEBP.

Content Item Types & Limits

TypeMaxFormat / SizeDescription
image—JPG, PNG, WEBP · < 10 MBImage(s) to edit.

Minimum Request

{
  "prompt": "Transform the background into a serene mountain landscape with snow-capped peaks and a clear blue sky",
  "image_urls": [
    "https://imagesai.appypie.com/7686410/JUEOHp2Y3FDjmXwOQJVy_017731476841749.png"
  ]
}

Full Request (all options)

{
  "prompt": "Transform the background into a serene mountain landscape with snow-capped peaks and a clear blue sky",
  "negative_prompt": "low resolution, error, worst quality, low quality, deformed",
  "enable_prompt_expansion": true,
  "enable_safety_checker": true,
  "num_images": 1,
  "output_format": "png",
  "image_urls": [
    "https://imagesai.appypie.com/7686410/JUEOHp2Y3FDjmXwOQJVy_017731476841749.png"
  ]
}

Response

{
  "request_id": "qwen-image-max-edit_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
  "status": "QUEUED",
  "polling_url": "https://gateway.pixazo.ai/v2/requests/status/qwen-image-max-edit_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"
}

Request Headers

Header Value
Content-Type application/json
Cache-Control no-cache
Ocp-Apim-Subscription-Key Your API subscription key

Response Handling

Common status codes for Qwen Image Max Edit generate request.

Code Meaning
202 Accepted — Request queued
Bad Request
401 Unauthorized
403 Forbidden
404 Not Found
Too Many Requests
500 Internal Server Error

Notes & Tips

  1. Poll the results endpoint every 2–3 seconds until status is COMPLETED or FAILED
  2. Implement exponential backoff for retry logic on 500 or 429 responses
  3. Use clear, specific prompts that describe the desired change in context, lighting, or environment
  4. Avoid overly vague prompts like “make it better”; specify elements such as “replace sky with sunset”
  5. Validate image URLs are publicly accessible and use HTTPS before submission
  6. Limit num_images to 1 unless multiple variations are required to

    Error Responses

    Queue system errors and model validation errors.

    Queue System Errors

    // 402 — Insufficient balance
    {
      "error": "Insufficient Balance",
      "message": "Your wallet does not have enough balance."
    }
    // 400 — Model not found
    {
      "error": "Model not found",
      "message": "Model 'qwen-image-max-edit' not found or is disabled"
    }

    Error via Status/Webhook

    {
      "request_id": "qwen-image-max-edit_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
      "status": "ERROR",
      "model_id": "qwen-image-max-edit",
      "error": "Description of the error",
      "output": null
    }

    Retrieving Results

    Poll the universal status endpoint to check progress and retrieve results.

    Endpoint

    GET https://gateway.pixazo.ai/v2/requests/status/{request_id}
    Ocp-Apim-Subscription-Key: YOUR_API_KEY

    cURL Example

    curl -H "Ocp-Apim-Subscription-Key: YOUR_API_KEY" \
      "https://gateway.pixazo.ai/v2/requests/status/qwen-image-max-edit_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"

    Response (Completed)

    {
      "request_id": "qwen-image-max-edit_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
      "status": "COMPLETED",
      "model_id": "qwen-image-max-edit",
      "error": null,
      "output": {
        "media_url": [
          "https://pub-582b7213209642b9b995c96c95a30381.r2.dev/v1/qwen-image-max-edit_019dxxxx-xxxx/output.ext"
        ],
        "media_type": "application/octet-stream"
      },
      "created_at": "2026-03-31T10:00:00.000Z",
      "updated_at": "2026-03-31T10:00:15.000Z",
      "completed_at": "2026-03-31T10:00:15.000Z"
    }

    Response Fields

    FieldTypeDescription
    request_idstringUnique request identifier
    statusstringQUEUED, PROCESSING, COMPLETED, FAILED, or ERROR
    model_idstringModel that processed the request
    errorstring|nullError message if failed
    output.media_urlarrayURLs to generated media (R2 CDN)
    output.media_typestringMIME type of the output
    created_atstringWhen request was created
    completed_atstring|nullWhen request completed
    polling_urlstringStatus URL (initial response only)

    Status Values

    StatusDescription
    QUEUEDRequest accepted, waiting to be processed
    PROCESSINGBeing processed by the model
    COMPLETEDDone — output contains the result
    FAILEDFailed — check error field
    ERRORSystem error — not charged

    Status Flow

    QUEUED → PROCESSING → COMPLETED
                        → FAILED
                        → ERROR

    Typical Workflow

    1. Send a generate request to the API endpoint
    2. Save the request_id from the response
    3. Poll every 5-10 seconds: GET /v2/requests/status/{request_id}
    4. When status is "COMPLETED", download from output.media_url

    Tip: Use X-Webhook-URL header to get a callback instead of polling.

Qwen Image Max Edit API Pricing

Your request will cost $0.075 per image.
4. Qwen Image Max t2i

Qwen Image Max t2i API Documentation

https://gateway.pixazo.ai/qwen-image-max/v1/qwen-image-max-request

Authentication

All requests require an API key passed via header.

Header Type Required Description
Ocp-Apim-Subscription-Key string Yes Your API subscription key

Qwen Image Max generate request - Qwen Image Max

Request Code

POST https://gateway.pixazo.ai/qwen-image-max/v1/qwen-image-max-request
Content-Type: application/json
Cache-Control: no-cache
Ocp-Apim-Subscription-Key: YOUR_SUBSCRIPTION_KEY

{
  "prompt": "A majestic white tiger resting on a mossy rock beside a waterfall in a tropical rainforest, photorealistic"
}
import requests

url = "https://gateway.pixazo.ai/qwen-image-max/v1/qwen-image-max-request"
headers = {
    "Content-Type": "application/json",
    "Cache-Control": "no-cache",
    "Ocp-Apim-Subscription-Key": "YOUR_SUBSCRIPTION_KEY"
}
data = {
    "prompt": "A majestic white tiger resting on a mossy rock beside a waterfall in a tropical rainforest, photorealistic"
}

response = requests.post(url, json=data, headers=headers)
print(response.json())
const url = "https://gateway.pixazo.ai/qwen-image-max/v1/qwen-image-max-request";
const headers = {
  "Content-Type": "application/json",
  "Cache-Control": "no-cache",
  "Ocp-Apim-Subscription-Key": "YOUR_SUBSCRIPTION_KEY"
};
const data = {
  prompt: "A majestic white tiger resting on a mossy rock beside a waterfall in a tropical rainforest, photorealistic"
};

fetch(url, {
  method: "POST",
  headers: headers,
  body: JSON.stringify(data)
})
.then(response => response.json())
.then(data => console.log(data))
.catch(error => console.error("Error:", error));
curl -X POST "https://gateway.pixazo.ai/qwen-image-max/v1/qwen-image-max-request" \
  -H "Content-Type: application/json" \
  -H "Cache-Control: no-cache" \
  -H "Ocp-Apim-Subscription-Key: YOUR_SUBSCRIPTION_KEY" \
  --data-raw '{
    "prompt": "A majestic white tiger resting on a mossy rock beside a waterfall in a tropical rainforest, photorealistic"
  }'

Output

{
  "request_id": "qwen-image-max_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
  "status": "QUEUED",
  "polling_url": "https://gateway.pixazo.ai/v2/requests/status/qwen-image-max_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"
}

Webhook (Optional)

Add the X-Webhook-URL header to your submit request to receive a POST callback when the job completes — no polling required.

Using curl? These are HTTP request headers — pass each with -H, e.g. -H "X-Webhook-URL: https://your-server.com/webhook/callback". Do not paste them as bare lines, and end every line of a multi-line command with \.

Webhook Headers

HeaderRequiredDefaultDescription
X-Webhook-URLYes (to enable)—HTTPS endpoint on your server that will receive the POST callback. Must respond 2xx within a few seconds (process async if needed).
X-Webhook-ModeNoterminalterminal — fires once at the final status (COMPLETED/FAILED/ERROR). sync — fires on every poll cycle plus the terminal event, and caps the queue’s polling delay at 15s for tighter progress updates.

Example: enable webhook

X-Webhook-URL: https://your-server.com/webhook/callback
X-Webhook-Mode: terminal

Callback Payload

Your endpoint receives a POST application/json with the same shape as the GET /v2/requests/status/{request_id} response. Example terminal callback (mode terminal):

{
  "request_id": "qwen-image-max_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
  "status": "COMPLETED",
  "model_id": "qwen-image-max",
  "error": null,
  "output": {
    "media_url": [
      "https://pub-582b7213209642b9b995c96c95a30381.r2.dev/v1/qwen-image-max_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx/output.png"
    ],
    "media_type": "image/png"
  },
  "created_at": "2026-05-22T13:17:32.110Z",
  "updated_at": "2026-05-22 13:19:23",
  "completed_at": "2026-05-22 13:19:23"
}

Failure callback shape

{
  "request_id": "qwen-image-max_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
  "status": "ERROR",
  "model_id": "qwen-image-max",
  "error": "Description of the error",
  "output": null,
  "created_at": "...",
  "updated_at": "...",
  "completed_at": "..."
}

Delivery semantics

  • terminal mode (default) — exactly one POST when the request reaches a terminal status. No callback during PROCESSING.
  • sync mode — POST on every status poll (with delay capped at ~15s) plus a final POST at terminal status. Use when you want progress updates.
  • Idempotency — use request_id as your idempotency key. Network retries can deliver the same callback more than once; your handler must tolerate duplicates.
  • Response — respond 200 OK within a few seconds. The queue does not block on slow handlers, but persistent failures may stop further deliveries.
  • HTTPS required — plain http:// URLs are rejected.

Request Parameters - Qwen Image Max generate request

ParameterRequiredTypeDefaultAllowed values / range
promptYesrequiredstring——
A detailed text description of the desired image. Supports English and Chinese; up to 800 characters. Be specific about subjects, styles, lighting, and composition.
negative_promptNostring——
A description of elements to avoid in the generated image (up to 500 characters). Helps refine output quality by excluding unwanted features.
image_sizeNostringsquare_hdsquare_hd, square, portrait_4_3, portrait_16_9, landscape_4_3, landscape_16_9
The resolution and aspect ratio of the output image. Choose one of the preset enum values, or pass a custom {width, height} object.
enable_prompt_expansionNobooleantruetrue, false
Automatically rewrites and enriches your prompt with an LLM before generation to improve results.
enable_safety_checkerNobooleantruetrue, false
Turns on automatic filtering of unsafe or explicit (NSFW) content. Leave enabled unless you have a specific reason to disable it.
seedNointeger—0–2147483647
Random seed for reproducibility. Reuse the same seed with identical inputs to reproduce a result; omit for a random seed each request.
num_imagesNointeger11–4
Number of images to generate in a single request.
output_formatNostringpngpng, jpeg, webp
The file format of the generated image. Supported values: png, jpeg, webp.

Minimum Request

{
  "prompt": "A majestic white tiger resting on a mossy rock beside a waterfall in a tropical rainforest, photorealistic"
}

Full Request (all options)

{
  "prompt": "A majestic white tiger resting on a mossy rock beside a waterfall in a tropical rainforest, photorealistic",
  "negative_prompt": "low resolution, error, worst quality, low quality, deformed",
  "image_size": "square_hd",
  "enable_prompt_expansion": true,
  "enable_safety_checker": true,
  "num_images": 1,
  "output_format": "png"
}

Response

{
  "request_id": "qwen-image-max_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
  "status": "QUEUED",
  "polling_url": "https://gateway.pixazo.ai/v2/requests/status/qwen-image-max_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"
}

Request Headers

Header Value
Content-Type application/json
Cache-Control no-cache
Ocp-Apim-Subscription-Key Your API subscription key

Response Handling

Common status codes for Qwen Image Max generate request.

Code Meaning
202 Accepted — Request queued
Bad Request
401 Unauthorized
403 Forbidden
404 Not Found
Too Many Requests
500 Internal Server Error

Error Responses

Queue system errors and model validation errors.

Queue System Errors

// 402 — Insufficient balance
{
  "error": "Insufficient Balance",
  "message": "Your wallet does not have enough balance."
}
// 400 — Model not found
{
  "error": "Model not found",
  "message": "Model 'qwen-image-max' not found or is disabled"
}

Error via Status/Webhook

{
  "request_id": "qwen-image-max_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
  "status": "ERROR",
  "model_id": "qwen-image-max",
  "error": "Description of the error",
  "output": null
}

Retrieving Results

Poll the universal status endpoint to check progress and retrieve results.

Endpoint

GET https://gateway.pixazo.ai/v2/requests/status/{request_id}
Ocp-Apim-Subscription-Key: YOUR_API_KEY

cURL Example

curl -H "Ocp-Apim-Subscription-Key: YOUR_API_KEY" \
  "https://gateway.pixazo.ai/v2/requests/status/qwen-image-max_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"

Response (Completed)

{
  "request_id": "qwen-image-max_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
  "status": "COMPLETED",
  "model_id": "qwen-image-max",
  "error": null,
  "output": {
    "media_url": [
      "https://pub-582b7213209642b9b995c96c95a30381.r2.dev/v1/qwen-image-max_019dxxxx-xxxx/output.ext"
    ],
    "media_type": "application/octet-stream"
  },
  "created_at": "2026-03-31T10:00:00.000Z",
  "updated_at": "2026-03-31T10:00:15.000Z",
  "completed_at": "2026-03-31T10:00:15.000Z"
}

Response Fields

FieldTypeDescription
request_idstringUnique request identifier
statusstringQUEUED, PROCESSING, COMPLETED, FAILED, or ERROR
model_idstringModel that processed the request
errorstring|nullError message if failed
output.media_urlarrayURLs to generated media (R2 CDN)
output.media_typestringMIME type of the output
created_atstringWhen request was created
completed_atstring|nullWhen request completed
polling_urlstringStatus URL (initial response only)

Status Values

StatusDescription
QUEUEDRequest accepted, waiting to be processed
PROCESSINGBeing processed by the model
COMPLETEDDone — output contains the result
FAILEDFailed — check error field
ERRORSystem error — not charged

Status Flow

QUEUED → PROCESSING → COMPLETED
                    → FAILED
                    → ERROR

Typical Workflow

  1. Send a generate request to the API endpoint
  2. Save the request_id from the response
  3. Poll every 5-10 seconds: GET /v2/requests/status/{request_id}
  4. When status is "COMPLETED", download from output.media_url

Tip: Use X-Webhook-URL header to get a callback instead of polling.

Qwen Image Max t2i API Pricing

Your request will cost $0.075 per image.
5. Qwen Image Edit 2509 Relight

Qwen Image Edit 2509 Relight API Documentation

Re-light a photo from a description of the light you want: its direction, colour, softness and time of day (for example warm sunset light from the left, soft daylight through a window, or neon pink and blue). The people, objects and composition stay the same; shadows, highlights and colour follow the new light. Built on Qwen-Image-Edit-2509 with a relighting LoRA. Prompts in English work. Asynchronous: submit returns a request_id; poll the status endpoint until the request is COMPLETED.

POST https://gateway.pixazo.ai/qwen-image-edit-2509-relight/v1/relight

Authentication

All requests require an API key passed via header.

HeaderTypeRequiredDescription
Ocp-Apim-Subscription-KeystringYesYour API subscription key

Relight - Qwen Image Edit 2509 Relight

Request Code

POST https://gateway.pixazo.ai/qwen-image-edit-2509-relight/v1/relight
Content-Type: application/json
Ocp-Apim-Subscription-Key: YOUR_SUBSCRIPTION_KEY

{
  "prompt": "Relight the photo with warm golden sunset light coming from the left side",
  "image_urls": [
    "https://pub-582b7213209642b9b995c96c95a30381.r2.dev/doc-assets/images/input.jpg"
  ]
}
import requests

url = "https://gateway.pixazo.ai/qwen-image-edit-2509-relight/v1/relight"
headers = {
    "Content-Type": "application/json",
    "Ocp-Apim-Subscription-Key": "YOUR_SUBSCRIPTION_KEY"
}
data = {
  "prompt": "Relight the photo with warm golden sunset light coming from the left side",
  "image_urls": [
    "https://pub-582b7213209642b9b995c96c95a30381.r2.dev/doc-assets/images/input.jpg"
  ]
}

resp = requests.post(url, json=data, headers=headers)
print(resp.json())
const res = await fetch("https://gateway.pixazo.ai/qwen-image-edit-2509-relight/v1/relight", {
  method: "POST",
  headers: {
    "Content-Type": "application/json",
    "Ocp-Apim-Subscription-Key": "YOUR_SUBSCRIPTION_KEY"
  },
  body: JSON.stringify({
  "prompt": "Relight the photo with warm golden sunset light coming from the left side",
  "image_urls": [
    "https://pub-582b7213209642b9b995c96c95a30381.r2.dev/doc-assets/images/input.jpg"
  ]
})
});
console.log(await res.json());
curl -X POST 'https://gateway.pixazo.ai/qwen-image-edit-2509-relight/v1/relight' \
  -H 'Content-Type: application/json' \
  -H 'Ocp-Apim-Subscription-Key: YOUR_SUBSCRIPTION_KEY' \
  --data-raw '{"prompt": "Relight the photo with warm golden sunset light coming from the left side", "image_urls": ["https://pub-582b7213209642b9b995c96c95a30381.r2.dev/doc-assets/images/input.jpg"]}'

Output

{
  "request_id": "qwen-image-edit-2509-relight_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
  "status": "QUEUED",
  "polling_url": "https://gateway.pixazo.ai/v2/requests/status/qwen-image-edit-2509-relight_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"
}

Webhook (Optional)

Instead of polling, you can receive a Webhook callback when the request reaches a terminal state. Provide a Webhook URL via header on the submit request.

HeaderRequiredDescription
X-Webhook-URLTo enableHTTPS URL to receive the Webhook callback.
X-Webhook-ModeNoterminal (default, one callback on COMPLETED/ERROR) or sync (per-poll callbacks).

Callback Payload (success)

{
  "request_id": "qwen-image-edit-2509-relight_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
  "status": "COMPLETED",
  "model_id": "qwen-image-edit-2509-relight",
  "error": null,
  "output": {
    "media_url": [
      "https://pub-582b7213209642b9b995c96c95a30381.r2.dev/v1/qwen-image-edit-2509-relight_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx/output.png"
    ],
    "media_type": "image/png"
  },
  "created_at": "2026-11-18T06:41:04.645Z",
  "updated_at": "2026-11-18 06:43:52",
  "completed_at": "2026-11-18 06:43:51"
}

Failure callback shape

{
  "request_id": "qwen-image-edit-2509-relight_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
  "status": "ERROR",
  "model_id": "qwen-image-edit-2509-relight",
  "error": "Generation failed: the request was rejected (image_urls[0]: Failed to load the image. Please ensure the image file is not corrupted and is in a supported format).",
  "output": null,
  "created_at": "2026-11-18T06:41:06.174Z",
  "updated_at": "2026-11-18 06:43:54",
  "completed_at": "2026-11-18 06:43:54"
}

Callbacks are idempotent on request_id — de-duplicate on it. Respond 200 within a few seconds; the Webhook endpoint must be HTTPS.

Request Parameters

ParameterRequiredTypeDefaultAllowed values / range
promptYesrequiredstring—1 to 2,000 characters
The light you want: source, direction, colour, softness, time of day. See Writing the prompt below.
image_urlsYesrequiredarray of strings—Exactly 1 public http(s) URL; JPEG or PNG
The photo to re-light.
image_sizeNostringthe photo's own shape, about 1 megapixelsquare_hd, square, portrait_4_3, portrait_16_9, landscape_4_3, landscape_16_9
Output size. Leave it out to keep the photo's shape. See Sizes below.
num_imagesNointeger11 to 4
How many versions to make; each is billed.
negative_promptNostring—up to 2,000 characters
What to avoid in the result.
seedNointegerrandom0 or more
Fix it to make a result easier to reproduce.
num_inference_stepsNointeger282 to 50
More steps can add detail and take longer.
guidance_scaleNonumber40 to 20
How closely the result follows the prompt.
accelerationNostringregularnone, regular
none is slower and can be slightly cleaner.
output_formatNostringpngpng, jpeg
Format of the returned image.
enable_safety_checkerNobooleantruetrue, false
Screen the result for unsafe content.

How usage is measured

Billed per output image by its size, counted in started megapixels of 1024×1024 pixels. An image of up to 1024×1024 pixels (1,048,576) is one unit: most results, for example 832×1248 from a portrait photo, and every image_size preset. A larger result is two units: a very large wide photo comes back at 1376×768. num_images multiplies the charge. The rates are in the pricing panel on this page. Nothing is charged for a request that fails.

Parameters not supported

Rejected with 400

Checked when you submit: the request is rejected before it is queued.

ParameterWhyUse instead
lorasThis API always applies its relighting LoRA; other LoRAs are not accepted.—
image_size as {width, height}, or another presetOnly the listed sizes are offered.A listed preset, or leave it out
Two or more image_urlsOne photo per request.One request per photo
image_urlNot accepted by this endpoint.image_urls (an array with one URL)
n, count, batch_size, number_of_images; num_images outside 1–4Use num_images.num_images 1 to 4
sync_modeResults are returned as image URLs.—

Accepted, then the request fails

These pass the submit check, so the submit returns 202, but the request then fails with status: "ERROR" and an error that names the problem. Nothing is charged.

ParameterWhen the request fails
image_urlsThe image cannot be downloaded or is not a usable image.

Writing the prompt

Describe the light, not the subject: the subject is kept. Name the source, its direction and colour, how hard or soft it is, and the mood. For example:

PromptEffect
Relight the photo with warm golden sunset light coming from the left sideLow warm sun from the left, rim light on hair and shoulders
Relight with soft cool morning light from a window on the rightGentle daylight from the right, soft shadows
Relight with dramatic neon pink and blue lightColoured club-style light from two sides
Relight the scene with cool blue moonlightDim, cool night light

The model was also trained with the Chinese trigger “重新照明” (relight); adding it at the start of the prompt is optional.

Sizes

Without image_size, the result keeps the photo’s shape at about 1 megapixel (for example 853×1280 in, 832×1248 out; 1344×768 stays 1344×768; a 5461×3072 photo comes back at 1376×768). With image_size, the result has that exact size:

image_sizeOutput
square_hd1024×1024
square512×512
portrait_4_3768×1024
portrait_16_9576×1024
landscape_4_31024×768
landscape_16_91024×576

A preset with a different shape from the photo crops or reframes it; leave image_size out to keep the framing.

Timing

A relight usually takes about 40 seconds when the model is already running, and up to about 5 minutes for the first requests after a quiet period, while it starts up. Polling the status endpoint every 5 seconds is enough, or use a Webhook.

Example Request

{
  "prompt": "Relight the photo with warm golden sunset light coming from the left side",
  "image_urls": [
    "https://pub-582b7213209642b9b995c96c95a30381.r2.dev/doc-assets/images/input.jpg"
  ]
}

Example Response

{
  "request_id": "qwen-image-edit-2509-relight_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
  "status": "QUEUED",
  "polling_url": "https://gateway.pixazo.ai/v2/requests/status/qwen-image-edit-2509-relight_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"
}

Request Headers

HeaderRequiredDescription
Content-TypeYesapplication/json
Ocp-Apim-Subscription-KeyYesYour API subscription key.
X-Webhook-URLNoEnable Webhook callbacks (see Webhook section).

Response Handling

Status CodeMeaning
202Accepted — request queued; returns request_id and polling_url.
400Bad request — the body failed the submit check (see Request Parameters) and was not queued.
401Unauthorized — missing or invalid subscription key.
402Insufficient balance.
403Forbidden.
429Too many requests.
500Internal server error.

Error Responses

A 400 names every rejected parameter in violations:

{
  "error": "Invalid request parameters",
  "message": "'image_urls' must have at most 1 item (got 2)",
  "violations": [
    "'image_urls' must have at most 1 item (got 2)"
  ]
}

Retrieving Results

Poll the status endpoint with the request_id until status is COMPLETED or ERROR, then download the image from output.media_url.

curl 'https://gateway.pixazo.ai/v2/requests/status/qwen-image-edit-2509-relight_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx' \
  -H 'Ocp-Apim-Subscription-Key: YOUR_SUBSCRIPTION_KEY'

Completed response

Captured from a real Qwen Image Edit 2509 Relight request at launch; the request id is masked.

{
  "request_id": "qwen-image-edit-2509-relight_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
  "status": "COMPLETED",
  "model_id": "qwen-image-edit-2509-relight",
  "error": null,
  "output": {
    "media_url": [
      "https://pub-582b7213209642b9b995c96c95a30381.r2.dev/v1/qwen-image-edit-2509-relight_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx/output.png"
    ],
    "media_type": "image/png"
  },
  "created_at": "2026-11-18T06:41:04.645Z",
  "updated_at": "2026-11-18 06:43:52",
  "completed_at": "2026-11-18 06:43:51"
}

Response Fields

FieldTypeDescription
request_idstringUnique request identifier.
statusstringQUEUED, PROCESSING, COMPLETED or ERROR.
model_idstringThe model that handled the request.
errorstring or nullError message when status is ERROR; otherwise null.
output.media_urlarray of stringsURL of each image (num_images of them). Download them and keep your own copies.
output.media_typestringThe image MIME type, image/png by default.
created_atstringRequest creation timestamp.
updated_atstringLast status change timestamp.
completed_atstringCompletion timestamp.
polling_urlstringStatus URL for this request (in the submit response).

Status Values & Flow

QUEUED → PROCESSING → COMPLETED (success) or ERROR (failure). Treat any status other than QUEUED, PROCESSING or COMPLETED as a failure.

Qwen Image Edit 2509 Relight API Pricing

Billed per output image by its size, in started megapixels of 1024×1024: most results (up to 1024×1024 pixels) are one unit; a larger result, such as a very large wide photo returned at 1376×768, is two. num_images multiplies the charge. Nothing is charged for a request that fails.

Output imagePrice (USD)
Output up to 1024×1024 pixels (most results, e.g. 832×1248 from a portrait)$0.03675 per image
Output over 1024×1024 pixels (e.g. 1376×768 from a very large wide photo)$0.0735 per image
Relighting a portrait photo returns 832×1248, billed at the first row.
6. Qwen LoRA v1

Qwen LoRA v1 API Documentation

https://gateway.pixazo.ai/qwen-image-edit-plus/v1/qwen-image-edit-plus-lora/generate

Authentication

All requests require an API key passed via header.

HeaderTypeRequiredDescription
Ocp-Apim-Subscription-KeystringYesYour API subscription key

Generate Image Edit Request - Qwen Image Edit Plus Lora API

Request Code

POST https://gateway.pixazo.ai/qwen-image-edit-plus/v1/qwen-image-edit-plus-lora/generate
Content-Type: application/json

{
  "prompt": "Close shot of a woman standing next to this car on this highway",
  "image_urls": [
    "https://pub-582b7213209642b9b995c96c95a30381.r2.dev/doc-assets/images/input.jpg",
    "https://pub-582b7213209642b9b995c96c95a30381.r2.dev/doc-assets/images/scene-end.jpg",
    "https://pub-582b7213209642b9b995c96c95a30381.r2.dev/doc-assets/images/input.jpg"
  ]
}
import requests

url = "https://gateway.pixazo.ai/qwen-image-edit-plus/v1/qwen-image-edit-plus-lora/generate"
headers = {
    "Content-Type": "application/json"
}
data = {
    "prompt": "Close shot of a woman standing next to this car on this highway",
    "image_urls": [
        "https://pub-582b7213209642b9b995c96c95a30381.r2.dev/doc-assets/images/input.jpg",
        "https://pub-582b7213209642b9b995c96c95a30381.r2.dev/doc-assets/images/scene-end.jpg",
        "https://pub-582b7213209642b9b995c96c95a30381.r2.dev/doc-assets/images/input.jpg"
    ]
}

response = requests.post(url, json=data, headers=headers)
print(response.json())
const url = 'https://gateway.pixazo.ai/qwen-image-edit-plus/v1/qwen-image-edit-plus-lora/generate';

const data = {
  prompt: 'Close shot of a woman standing next to this car on this highway',
  image_urls: [
    'https://pub-582b7213209642b9b995c96c95a30381.r2.dev/doc-assets/images/input.jpg',
    'https://pub-582b7213209642b9b995c96c95a30381.r2.dev/doc-assets/images/scene-end.jpg',
    'https://pub-582b7213209642b9b995c96c95a30381.r2.dev/doc-assets/images/input.jpg'
  ]
};

fetch(url, {
  method: 'POST',
  headers: {
    'Content-Type': 'application/json'
  },
  body: JSON.stringify(data)
})
.then(response => response.json())
.then(data => console.log(data))
.catch(error => console.error('Error:', error));
curl -X POST https://gateway.pixazo.ai/qwen-image-edit-plus/v1/qwen-image-edit-plus-lora/generate \
  -H "Content-Type: application/json" \
  -d '{
    "prompt": "Close shot of a woman standing next to this car on this highway",
    "image_urls": [
      "https://pub-582b7213209642b9b995c96c95a30381.r2.dev/doc-assets/images/input.jpg",
      "https://pub-582b7213209642b9b995c96c95a30381.r2.dev/doc-assets/images/scene-end.jpg",
      "https://pub-582b7213209642b9b995c96c95a30381.r2.dev/doc-assets/images/input.jpg"
    ]
  }'

Output

{
  "request_id": "qwen-image-edit-plus-lora_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
  "status": "QUEUED",
  "polling_url": "https://gateway.pixazo.ai/v2/requests/status/qwen-image-edit-plus-lora_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"
}

Webhook (Optional)

Add the X-Webhook-URL header to your submit request to receive a POST callback when the job completes — no polling required.

Using curl? These are HTTP request headers — pass each with -H, e.g. -H "X-Webhook-URL: https://your-server.com/webhook/callback". Do not paste them as bare lines, and end every line of a multi-line command with \.

Webhook Headers

HeaderRequiredDefaultDescription
X-Webhook-URLYes (to enable)—HTTPS endpoint on your server that will receive the POST callback. Must respond 2xx within a few seconds (process async if needed).
X-Webhook-ModeNoterminalterminal — fires once at the final status (COMPLETED/FAILED/ERROR). sync — fires on every poll cycle plus the terminal event, and caps the queue’s polling delay at 15s for tighter progress updates.

Example: enable webhook

X-Webhook-URL: https://your-server.com/webhook/callback
X-Webhook-Mode: terminal

Callback Payload

Your endpoint receives a POST application/json with the same shape as the GET /v2/requests/status/{request_id} response. Example terminal callback (mode terminal):

{
  "request_id": "qwen-image-edit-plus-lora_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
  "status": "COMPLETED",
  "model_id": "qwen-image-edit-plus-lora",
  "error": null,
  "output": {
    "media_url": [
      "https://pub-582b7213209642b9b995c96c95a30381.r2.dev/v1/qwen-image-edit-plus-lora_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx/output.png"
    ],
    "media_type": "image/png"
  },
  "created_at": "2026-05-22T13:17:32.110Z",
  "updated_at": "2026-05-22 13:19:23",
  "completed_at": "2026-05-22 13:19:23"
}

Failure callback shape

{
  "request_id": "qwen-image-edit-plus-lora_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
  "status": "ERROR",
  "model_id": "qwen-image-edit-plus-lora",
  "error": "Description of the error",
  "output": null,
  "created_at": "...",
  "updated_at": "...",
  "completed_at": "..."
}

Delivery semantics

  • terminal mode (default) — exactly one POST when the request reaches a terminal status. No callback during PROCESSING.
  • sync mode — POST on every status poll (with delay capped at ~15s) plus a final POST at terminal status. Use when you want progress updates.
  • Idempotency — use request_id as your idempotency key. Network retries can deliver the same callback more than once; your handler must tolerate duplicates.
  • Response — respond 200 OK within a few seconds. The queue does not block on slow handlers, but persistent failures may stop further deliveries.
  • HTTPS required — plain http:// URLs are rejected.

Request Parameters - Generate Image Edit Request

ParameterRequiredTypeDefaultAllowed values / range
promptYesrequiredstring——
The text instruction describing the edit you want applied to the input image(s).
image_urlsYesrequiredarray——
Publicly accessible URLs of the images to edit. Provide one or more reference images (or Base64 data URIs).
lorasNoarray[] (no LoRA)up to 3 entries
LoRA weights to apply on top of the base model. Each entry is an object with path (required — URL of the LoRA weights) and scale (number, default 1, range 0-4). Up to 3 LoRAs are merged together for the final image.
image_sizeNostring or objectsize of the final input imagesquare_hd, square, portrait_4_3, portrait_16_9, landscape_4_3, landscape_16_9, or a custom {"width": …, "height": …} object (1-14142 px per side)
Size of the generated image. If omitted, the size of the final input image is used.
num_inference_stepsNointeger282-50
Number of refinement steps the model runs while generating. Higher values refine detail and quality but increase processing time; lower values are faster.
seedNointeger——
Random seed that controls the generation's randomness. Reuse the same seed with identical settings to reproduce the same result; leave it empty for a different output each time.
guidance_scaleNonumber40-20
CFG scale — controls how closely the output follows your prompt (prompt adherence). Higher values stick more strictly to the prompt; lower values allow more creative variation.
num_imagesNointeger11-4
Number of images to generate in a single request.
output_formatNostringpngpng, jpeg
The file format of the generated image.
negative_promptNostring" " (a single space)—
A description of elements to avoid in the generated image.
accelerationNostringregularnone, regular
Acceleration level for image generation. "regular" balances speed and quality; "none" disables acceleration.
enable_safety_checkerNobooleantruetrue, false
Turns on automatic filtering of unsafe or explicit (NSFW) content. Leave enabled unless you have a specific reason to disable it.
webhookNostring——
Webhook URL for async notifications
webhook_events_filterNoarray——
Event types to receive: ["start"], ["complete"], ["*"]

Content Item Types & Limits

TypeMaxFormat / SizeDescription
image—JPG, PNG, WEBP · < 10 MBImage(s) to edit.

Example Request

{
  "prompt": "Close shot of a woman standing next to this car on this highway",
  "image_urls": [
    "https://pub-582b7213209642b9b995c96c95a30381.r2.dev/doc-assets/images/input.jpg",
    "https://pub-582b7213209642b9b995c96c95a30381.r2.dev/doc-assets/images/scene-end.jpg",
    "https://pub-582b7213209642b9b995c96c95a30381.r2.dev/doc-assets/images/input.jpg"
  ],
  "image_size": "square_hd",
  "num_inference_steps": 50,
  "guidance_scale": 4,
  "num_images": 1,
  "output_format": "png",
  "negative_prompt": " ",
  "acceleration": "regular",
  "enable_safety_checker": true
}

Response

{
  "request_id": "qwen-image-edit-plus-lora_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
  "status": "QUEUED",
  "polling_url": "https://gateway.pixazo.ai/v2/requests/status/qwen-image-edit-plus-lora_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"
}

Request Headers

Header Value
Content-Typeapplication/json

Response Handling

Common status codes.

CodeMeaning
202Accepted — Request queued
Bad Request
401Unauthorized
402Insufficient Balance
403Forbidden
Too Many Requests
500Internal Server Error

Error Responses

Queue system errors and model validation errors.

Queue System Errors

// 402 — Insufficient balance
{
  "error": "Insufficient Balance",
  "message": "Your wallet does not have enough balance."
}
// 400 — Model not found
{
  "error": "Model not found",
  "message": "Model 'qwen-image-edit-plus-lora' not found or is disabled"
}

Error via Status/Webhook

{
  "request_id": "qwen-image-edit-plus-lora_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
  "status": "ERROR",
  "model_id": "qwen-image-edit-plus-lora",
  "error": "Description of the error",
  "output": null
}

Retrieving Results

Poll the universal status endpoint to check progress and retrieve results.

Endpoint

GET https://gateway.pixazo.ai/v2/requests/status/{request_id}
Ocp-Apim-Subscription-Key: YOUR_API_KEY

cURL Example

curl -H "Ocp-Apim-Subscription-Key: YOUR_API_KEY" \
  "https://gateway.pixazo.ai/v2/requests/status/qwen-image-edit-plus-lora_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"

Response (Completed)

{
  "request_id": "qwen-image-edit-plus-lora_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
  "status": "COMPLETED",
  "model_id": "qwen-image-edit-plus-lora",
  "error": null,
  "output": {
    "media_url": [
      "https://pub-582b7213209642b9b995c96c95a30381.r2.dev/v1/qwen-image-edit-plus-lora_019dxxxx-xxxx/output.ext"
    ],
    "media_type": "application/octet-stream"
  },
  "created_at": "2026-03-31T10:00:00.000Z",
  "updated_at": "2026-03-31T10:00:15.000Z",
  "completed_at": "2026-03-31T10:00:15.000Z"
}

Response Fields

FieldTypeDescription
request_idstringUnique request identifier
statusstringQUEUED, PROCESSING, COMPLETED, FAILED, or ERROR
model_idstringModel that processed the request
errorstring|nullError message if failed
output.media_urlarrayURLs to generated media (R2 CDN)
output.media_typestringMIME type of the output
created_atstringWhen request was created
completed_atstring|nullWhen request completed
polling_urlstringStatus URL (initial response only)

Status Values

StatusDescription
QUEUEDRequest accepted, waiting to be processed
PROCESSINGBeing processed by the model
COMPLETEDDone — output contains the result
FAILEDFailed — check error field
ERRORSystem error — not charged

Status Flow

QUEUED → PROCESSING → COMPLETED
                    → FAILED
                    → ERROR

Typical Workflow

  1. Send a generate request to the API endpoint
  2. Save the request_id from the response
  3. Poll every 5-10 seconds: GET /v2/requests/status/{request_id}
  4. When status is "COMPLETED", download from output.media_url

Tip: Use X-Webhook-URL header to get a callback instead of polling.

Qwen LoRA v1 API Pricing

Your request will cost $0.0478 per megapixel of output.
Billed on the generated output size × number of images. Example: one 1024x1024 image (1.05 MP) costs about $0.050.
Image to Image (LoRA Trainer)

Qwen LoRA v1 API Documentation

https://gateway.pixazo.ai/qwen-image-edit-plus-trainer/v1/qwen-image-edit-plus-trainer/generate

Authentication

All requests require an API key passed via header.

HeaderTypeRequiredDescription
Ocp-Apim-Subscription-KeystringYesYour API subscription key

Training Request - Qwen Image Edit Plus Trainer API

Request Code

POST https://gateway.pixazo.ai/qwen-image-edit-plus-trainer/v1/qwen-image-edit-plus-trainer/generate
Content-Type: application/json
Ocp-Apim-Subscription-Key: your-subscription-key

{
  "image_data_url": "https://pub-582b7213209642b9b995c96c95a30381.r2.dev/doc-assets/trainers/flux-i2i-demo-dataset.zip",
  "steps": 1000
}
import requests

url = "https://gateway.pixazo.ai/qwen-image-edit-plus-trainer/v1/qwen-image-edit-plus-trainer/generate"
headers = {
    "Content-Type": "application/json",
    "Ocp-Apim-Subscription-Key": "your-subscription-key"
}
data = {
    "image_data_url": "https://pub-582b7213209642b9b995c96c95a30381.r2.dev/doc-assets/trainers/flux-i2i-demo-dataset.zip",
    "steps": 1000
}

response = requests.post(url, json=data, headers=headers)
print(response.json())
const url = 'https://gateway.pixazo.ai/qwen-image-edit-plus-trainer/v1/qwen-image-edit-plus-trainer/generate';
const headers = {
  'Content-Type': 'application/json',
  'Ocp-Apim-Subscription-Key': 'your-subscription-key'
};
const data = {
  image_data_url: 'https://pub-582b7213209642b9b995c96c95a30381.r2.dev/doc-assets/trainers/flux-i2i-demo-dataset.zip',
  steps: 1000
};

fetch(url, {
  method: 'POST',
  headers: headers,
  body: JSON.stringify(data)
})
.then(response => response.json())
.then(data => console.log(data))
.catch(error => console.error('Error:', error));
curl -X POST https://gateway.pixazo.ai/qwen-image-edit-plus-trainer/v1/qwen-image-edit-plus-trainer/generate \
  -H "Content-Type: application/json" \
  -H "Ocp-Apim-Subscription-Key: your-subscription-key" \
  -d '{
    "image_data_url": "https://pub-582b7213209642b9b995c96c95a30381.r2.dev/doc-assets/trainers/flux-i2i-demo-dataset.zip",
    "steps": 1000
  }'

Output

{
  "request_id": "qwen-image-edit-plus-trainer_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
  "status": "QUEUED",
  "polling_url": "https://gateway.pixazo.ai/v2/requests/status/qwen-image-edit-plus-trainer_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"
}

Webhook (Optional)

Add the X-Webhook-URL header to your submit request to receive a POST callback when the job completes — no polling required.

Using curl? These are HTTP request headers — pass each with -H, e.g. -H "X-Webhook-URL: https://your-server.com/webhook/callback". Do not paste them as bare lines, and end every line of a multi-line command with \.

Webhook Headers

HeaderRequiredDefaultDescription
X-Webhook-URLYes (to enable)—HTTPS endpoint on your server that will receive the POST callback. Must respond 2xx within a few seconds (process async if needed).
X-Webhook-ModeNoterminalterminal — fires once at the final status (COMPLETED/FAILED/ERROR). sync — fires on every poll cycle plus the terminal event, and caps the queue’s polling delay at 15s for tighter progress updates.

Example: enable webhook

X-Webhook-URL: https://your-server.com/webhook/callback
X-Webhook-Mode: terminal

Callback Payload

Your endpoint receives a POST application/json with the same shape as the GET /v2/requests/status/{request_id} response. Example terminal callback (mode terminal):

{
  "request_id": "qwen-image-edit-plus-trainer_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
  "status": "COMPLETED",
  "model_id": "qwen-image-edit-plus-trainer",
  "error": null,
  "output": {
    "media_url": [
      "https://pub-582b7213209642b9b995c96c95a30381.r2.dev/v1/qwen-image-edit-plus-trainer_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx/output.png"
    ],
    "media_type": "image/png"
  },
  "created_at": "2026-05-22T13:17:32.110Z",
  "updated_at": "2026-05-22 13:19:23",
  "completed_at": "2026-05-22 13:19:23"
}

Failure callback shape

{
  "request_id": "qwen-image-edit-plus-trainer_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
  "status": "ERROR",
  "model_id": "qwen-image-edit-plus-trainer",
  "error": "Description of the error",
  "output": null,
  "created_at": "...",
  "updated_at": "...",
  "completed_at": "..."
}

Delivery semantics

  • terminal mode (default) — exactly one POST when the request reaches a terminal status. No callback during PROCESSING.
  • sync mode — POST on every status poll (with delay capped at ~15s) plus a final POST at terminal status. Use when you want progress updates.
  • Idempotency — use request_id as your idempotency key. Network retries can deliver the same callback more than once; your handler must tolerate duplicates.
  • Response — respond 200 OK within a few seconds. The queue does not block on slow handlers, but persistent failures may stop further deliveries.
  • HTTPS required — plain http:// URLs are rejected.

Request Parameters - Training Request

ParameterRequiredTypeDefaultAllowed values / range
image_data_urlYesrequiredstring——
URL to the ZIP archive of training data. The ZIP holds image pairs named ROOT_start.EXT / ROOT_end.EXT (e.g. photo_start.jpg and photo_end.jpg). Extra reference images per pair are named ROOT_start2.EXT, ROOT_start3.EXT, … and an optional ROOT.txt per pair supplies that pair's edit instruction.
learning_rateNonumber0.0001—
Learning rate for the LoRA parameters. Lower values train more slowly but more reliably; higher values train faster but risk instability.
stepsNointeger10001-30000
Number of training steps to run. More steps generally improve fidelity but increase training time and cost.
default_captionNostring——
Caption used for any image pair that has no ROOT.txt caption file. If it is omitted and a caption file is missing, the training run fails.
reference_image_countNointeger——
Number of reference images supplied per training pair in the ZIP archive (the ROOT_start2/ROOT_start3 files).
webhookNostring——
Webhook URL for training completion notifications
webhook_events_filterNoarray——
Event types to receive ("*" for all)

Example Request

{
  "image_data_url": "https://pub-582b7213209642b9b995c96c95a30381.r2.dev/doc-assets/trainers/flux-i2i-demo-dataset.zip",
  "learning_rate": 0.0002,
  "steps": 2000,
  "default_caption": "professional cinematic lighting with dramatic shadows",
  "reference_image_count": 2,
  "webhook": "https://your-domain.com/training-complete"
}

Response

{
  "request_id": "qwen-image-edit-plus-trainer_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
  "status": "QUEUED",
  "polling_url": "https://gateway.pixazo.ai/v2/requests/status/qwen-image-edit-plus-trainer_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"
}

Request Headers

Header Value
Content-Typeapplication/json
Ocp-Apim-Subscription-KeyYour subscription key

Response Handling

Common status codes.

CodeMeaning
202Accepted — Request queued
Bad Request
401Unauthorized
402Insufficient Balance
403Forbidden
Too Many Requests
500Internal Server Error

Error Responses

Queue system errors and model validation errors.

Queue System Errors

// 402 — Insufficient balance
{
  "error": "Insufficient Balance",
  "message": "Your wallet does not have enough balance."
}
// 400 — Model not found
{
  "error": "Model not found",
  "message": "Model 'qwen-image-edit-plus-trainer' not found or is disabled"
}

Error via Status/Webhook

{
  "request_id": "qwen-image-edit-plus-trainer_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
  "status": "ERROR",
  "model_id": "qwen-image-edit-plus-trainer",
  "error": "Description of the error",
  "output": null
}

Retrieving Results

Poll the universal status endpoint to check progress and retrieve results.

Endpoint

GET https://gateway.pixazo.ai/v2/requests/status/{request_id}
Ocp-Apim-Subscription-Key: YOUR_API_KEY

cURL Example

curl -H "Ocp-Apim-Subscription-Key: YOUR_API_KEY" \
  "https://gateway.pixazo.ai/v2/requests/status/qwen-image-edit-plus-trainer_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"

Response (Completed)

{
  "request_id": "qwen-image-edit-plus-trainer_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
  "status": "COMPLETED",
  "model_id": "qwen-image-edit-plus-trainer",
  "error": null,
  "output": {
    "media_url": [
      "https://pub-582b7213209642b9b995c96c95a30381.r2.dev/v1/qwen-image-edit-plus-trainer_019dxxxx-xxxx/output.ext"
    ],
    "media_type": "application/octet-stream"
  },
  "created_at": "2026-03-31T10:00:00.000Z",
  "updated_at": "2026-03-31T10:00:15.000Z",
  "completed_at": "2026-03-31T10:00:15.000Z"
}

Response Fields

FieldTypeDescription
request_idstringUnique request identifier
statusstringQUEUED, PROCESSING, COMPLETED, FAILED, or ERROR
model_idstringModel that processed the request
errorstring|nullError message if failed
output.media_urlarrayURLs to generated media (R2 CDN)
output.media_typestringMIME type of the output
created_atstringWhen request was created
completed_atstring|nullWhen request completed
polling_urlstringStatus URL (initial response only)

Status Values

StatusDescription
QUEUEDRequest accepted, waiting to be processed
PROCESSINGBeing processed by the model
COMPLETEDDone — output contains the result
FAILEDFailed — check error field
ERRORSystem error — not charged

Status Flow

QUEUED → PROCESSING → COMPLETED
                    → FAILED
                    → ERROR

Typical Workflow

  1. Send a generate request to the API endpoint
  2. Save the request_id from the response
  3. Poll every 5-10 seconds: GET /v2/requests/status/{request_id}
  4. When status is "COMPLETED", download from output.media_url

Tip: Use X-Webhook-URL header to get a callback instead of polling.

Qwen LoRA v1 API Pricing

Your request will cost $0.04 per LoRA training job.
Image to Image (Image Editing — Layered)

Qwen LoRA v1 API Documentation

https://gateway.pixazo.ai/qwen-image-layered/v1/qwen-image-layered-request

Authentication

All requests require an API key passed via header.

HeaderTypeRequiredDescription
Ocp-Apim-Subscription-KeystringYesYour API subscription key

Qwen Image Layered generate request - Qwen Image Layered API

Request Code

POST https://gateway.pixazo.ai/qwen-image-layered/v1/qwen-image-layered-request
Content-Type: application/json
Cache-Control: no-cache
Ocp-Apim-Subscription-Key: YOUR_SUBSCRIPTION_KEY

{
  "image_url": "https://pub-582b7213209642b9b995c96c95a30381.r2.dev/car_race.jpeg",
  "num_inference_steps": 28,
  "guidance_scale": 5.0,
  "num_images": 1,
  "enable_safety_checker": true,
  "output_format": "png",
  "acceleration": "regular"
}
import requests

url = "https://gateway.pixazo.ai/qwen-image-layered/v1/qwen-image-layered-request"
headers = {
    "Content-Type": "application/json",
    "Cache-Control": "no-cache",
    "Ocp-Apim-Subscription-Key": "YOUR_SUBSCRIPTION_KEY"
}
data = {
    "image_url": "https://pub-582b7213209642b9b995c96c95a30381.r2.dev/car_race.jpeg",
    "num_inference_steps": 28,
    "guidance_scale": 5.0,
    "num_images": 1,
    "enable_safety_checker": True,
    "output_format": "png",
    "acceleration": "regular"
}

response = requests.post(url, json=data, headers=headers)
print(response.json())
const url = 'https://gateway.pixazo.ai/qwen-image-layered/v1/qwen-image-layered-request';
const headers = {
  'Content-Type': 'application/json',
  'Cache-Control': 'no-cache',
  'Ocp-Apim-Subscription-Key': 'YOUR_SUBSCRIPTION_KEY'
};
const data = {
  image_url: 'https://pub-582b7213209642b9b995c96c95a30381.r2.dev/car_race.jpeg',
  num_inference_steps: 28,
  guidance_scale: 5.0,
  num_images: 1,
  enable_safety_checker: true,
  output_format: 'png',
  acceleration: 'regular'
};

fetch(url, {
  method: 'POST',
  headers: headers,
  body: JSON.stringify(data)
})
.then(response => response.json())
.then(data => console.log(data))
.catch(error => console.error('Error:', error));
curl -X POST "https://gateway.pixazo.ai/qwen-image-layered/v1/qwen-image-layered-request" \
  -H "Content-Type: application/json" \
  -H "Cache-Control: no-cache" \
  -H "Ocp-Apim-Subscription-Key: YOUR_SUBSCRIPTION_KEY" \
  --data-raw '{
    "image_url": "https://pub-582b7213209642b9b995c96c95a30381.r2.dev/car_race.jpeg",
    "num_inference_steps": 28,
    "guidance_scale": 5.0,
    "num_images": 1,
    "enable_safety_checker": true,
    "output_format": "png",
    "acceleration": "regular"
  }'

Output

{
  "request_id": "qwen-image-layered_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
  "status": "QUEUED",
  "polling_url": "https://gateway.pixazo.ai/v2/requests/status/qwen-image-layered_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"
}

Webhook (Optional)

Add the X-Webhook-URL header to your submit request to receive a POST callback when the job completes — no polling required.

Using curl? These are HTTP request headers — pass each with -H, e.g. -H "X-Webhook-URL: https://your-server.com/webhook/callback". Do not paste them as bare lines, and end every line of a multi-line command with \.

Webhook Headers

HeaderRequiredDefaultDescription
X-Webhook-URLYes (to enable)—HTTPS endpoint on your server that will receive the POST callback. Must respond 2xx within a few seconds (process async if needed).
X-Webhook-ModeNoterminalterminal — fires once at the final status (COMPLETED/FAILED/ERROR). sync — fires on every poll cycle plus the terminal event, and caps the queue’s polling delay at 15s for tighter progress updates.

Example: enable webhook

X-Webhook-URL: https://your-server.com/webhook/callback
X-Webhook-Mode: terminal

Callback Payload

Your endpoint receives a POST application/json with the same shape as the GET /v2/requests/status/{request_id} response. Example terminal callback (mode terminal):

{
  "request_id": "qwen-image-layered_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
  "status": "COMPLETED",
  "model_id": "qwen-image-layered",
  "error": null,
  "output": {
    "media_url": [
      "https://pub-582b7213209642b9b995c96c95a30381.r2.dev/v1/qwen-image-layered_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx/output_0.png",
      "https://pub-582b7213209642b9b995c96c95a30381.r2.dev/v1/qwen-image-layered_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx/output_1.png",
      "https://pub-582b7213209642b9b995c96c95a30381.r2.dev/v1/qwen-image-layered_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx/output_2.png",
      "https://pub-582b7213209642b9b995c96c95a30381.r2.dev/v1/qwen-image-layered_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx/output_3.png"
    ],
    "media_type": "image/png"
  },
  "created_at": "2026-05-22T13:17:32.110Z",
  "updated_at": "2026-05-22 13:19:23",
  "completed_at": "2026-05-22 13:19:23"
}

Failure callback shape

{
  "request_id": "qwen-image-layered_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
  "status": "ERROR",
  "model_id": "qwen-image-layered",
  "error": "Description of the error",
  "output": null,
  "created_at": "...",
  "updated_at": "...",
  "completed_at": "..."
}

Delivery semantics

  • terminal mode (default) — exactly one POST when the request reaches a terminal status. No callback during PROCESSING.
  • sync mode — POST on every status poll (with delay capped at ~15s) plus a final POST at terminal status. Use when you want progress updates.
  • Idempotency — use request_id as your idempotency key. Network retries can deliver the same callback more than once; your handler must tolerate duplicates.
  • Response — respond 200 OK within a few seconds. The queue does not block on slow handlers, but persistent failures may stop further deliveries.
  • HTTPS required — plain http:// URLs are rejected.

Request Parameters - Qwen Image Layered generate request

ParameterRequiredTypeDefaultAllowed values / range
image_urlYesrequiredstring——
The input image to be decomposed into layers. Must be a publicly accessible URL reachable by the server.
promptNostring——
Optional caption describing the input image. A short, accurate caption helps the model separate the layers more reliably.
num_layersNointeger41-10
Number of layers to decompose the input image into. The response returns one image URL per layer in media_url (output_0 … output_N-1); index 0 is the opaque base layer and the remaining layers carry transparency.
num_inference_stepsNointeger281-50
Number of refinement steps the model runs while generating. Higher values refine detail and quality but increase processing time; lower values are faster.
guidance_scaleNonumber51-20
Controls how closely the output follows your prompt (prompt adherence). Higher values stick more strictly to the prompt; lower values allow more creative variation.
num_imagesNointeger11
Number of layer sets to generate (currently only 1 is supported).
negative_promptNostring"" (empty)—
A description of elements to avoid in the generated layers.
seedNointeger——
Random seed that controls the generation's randomness. Reuse the same seed with identical settings to reproduce the same result; leave it empty for a different output each time.
accelerationNostringregularnone, regular, high
Acceleration level for generation. "high" is fastest, "regular" balances speed and quality, "none" disables acceleration.
enable_safety_checkerNobooleantruetrue, false
Turns on automatic filtering of unsafe or explicit (NSFW) content. Leave enabled unless you have a specific reason to disable it.
output_formatNostringpngpng, webp
The file format of the generated layers. Use png to preserve transparency.

Content Item Types & Limits

TypeMaxFormat / SizeDescription
image1JPG, PNG, WEBP · < 10 MBImage to decompose into layers.

Example Request

{
  "image_url": "https://pub-582b7213209642b9b995c96c95a30381.r2.dev/car_race.jpeg",
  "num_inference_steps": 28,
  "guidance_scale": 5.0,
  "num_images": 1,
  "enable_safety_checker": true,
  "output_format": "png",
  "acceleration": "regular"
}

Response

{
  "request_id": "qwen-image-layered_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
  "status": "QUEUED",
  "polling_url": "https://gateway.pixazo.ai/v2/requests/status/qwen-image-layered_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"
}

Request Headers

Header Value
Content-Typeapplication/json
Cache-Controlno-cache
Ocp-Apim-Subscription-KeyYOUR_SUBSCRIPTION_KEY

Response Handling

Common status codes.

CodeMeaning
202Accepted — Request queued
Bad Request
401Unauthorized
402Insufficient Balance
403Forbidden
Too Many Requests
500Internal Server Error

Error Responses

Queue system errors and model validation errors.

Queue System Errors

// 402 — Insufficient balance
{
  "error": "Insufficient Balance",
  "message": "Your wallet does not have enough balance."
}
// 400 — Model not found
{
  "error": "Model not found",
  "message": "Model 'qwen-image-layered' not found or is disabled"
}

Error via Status/Webhook

{
  "request_id": "qwen-image-layered_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
  "status": "ERROR",
  "model_id": "qwen-image-layered",
  "error": "Description of the error",
  "output": null
}

Retrieving Results

Poll the universal status endpoint to check progress and retrieve results.

Endpoint

GET https://gateway.pixazo.ai/v2/requests/status/{request_id}
Ocp-Apim-Subscription-Key: YOUR_API_KEY

cURL Example

curl -H "Ocp-Apim-Subscription-Key: YOUR_API_KEY" \
  "https://gateway.pixazo.ai/v2/requests/status/qwen-image-layered_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"

Response (Completed)

{
  "request_id": "qwen-image-layered_019dxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
  "status": "COMPLETED",
  "model_id": "qwen-image-layered",
  "error": null,
  "output": {
    "media_url": [
      "https://pub-582b7213209642b9b995c96c95a30381.r2.dev/v1/qwen-image-layered_019dxxxx-xxxx/output.ext"
    ],
    "media_type": "application/octet-stream"
  },
  "created_at": "2026-03-31T10:00:00.000Z",
  "updated_at": "2026-03-31T10:00:15.000Z",
  "completed_at": "2026-03-31T10:00:15.000Z"
}

Response Fields

FieldTypeDescription
request_idstringUnique request identifier
statusstringQUEUED, PROCESSING, COMPLETED, FAILED, or ERROR
model_idstringModel that processed the request
errorstring|nullError message if failed
output.media_urlarrayURLs to generated media (R2 CDN)
output.media_typestringMIME type of the output
created_atstringWhen request was created
completed_atstring|nullWhen request completed
polling_urlstringStatus URL (initial response only)

Status Values

StatusDescription
QUEUEDRequest accepted, waiting to be processed
PROCESSINGBeing processed by the model
COMPLETEDDone — output contains the result
FAILEDFailed — check error field
ERRORSystem error — not charged

Status Flow

QUEUED → PROCESSING → COMPLETED
                    → FAILED
                    → ERROR

Typical Workflow

  1. Send a generate request to the API endpoint
  2. Save the request_id from the response
  3. Poll every 5-10 seconds: GET /v2/requests/status/{request_id}
  4. When status is "COMPLETED", download from output.media_url

Tip: Use X-Webhook-URL header to get a callback instead of polling.

Qwen LoRA v1 API Pricing

Your request will cost $0.05 per image.

⚡ Performance

Live usage measured on Pixazo's gateway, split by model version. Generation time is how long a generation takes end-to-end (lower is better). Success rate is the percent of generations that complete (higher is better).

Show data for the last
Generations
11,100last 30d
~370 per day
Success rate
83.8%
of completed generations
Generation time
83.1savg
p95 109.5s
Requests
Nov 1max 2,300Nov 30
Qwen Image 3.0 ProAvg 187/day
Qwen Image 3.0 StandardAvg 143/day
Qwen Image Edit 2509 RelightAvg 37/day
Qwen Image Max t2iAvg 3/day
Generation Time
Nov 1max 2.7minNov 30
Qwen Image 3.0 ProAvg 87.4s
Qwen Image 3.0 StandardAvg 65.6s
Qwen Image Edit 2509 RelightAvg 2.7min
Qwen Image Max t2iAvg —
Error Rate
Nov 1max 100.0%Nov 30
Qwen Image 3.0 ProAvg 21.4%
Qwen Image 3.0 StandardAvg 9.3%
Qwen Image Edit 2509 RelightAvg 9.1%
Qwen Image Max t2iAvg 100.0%

〰 Uptime

Percent of generations that succeeded over the selected period, per model version.

Avg. Success Rate (30d)
83.78%
across all generations of this model family
Uptime
Nov 1max 100%Nov 30
Qwen Image 3.0 ProAvg 78.57%
Qwen Image 3.0 StandardAvg 90.70%
Qwen Image Edit 2509 RelightAvg 90.91%
Qwen Image Max t2iAvg 0.00%