qwen-image-3
Alibaba Qwen Image 3.0 on reAPI — async text-to-image and image-to-image editing, prompts up to 4.5k tokens, whole-page layouts, text legible to 10px, 1K/2K on Standard and Pro tiers.
Alibaba's third-generation Qwen image model on reAPI — one async endpoint for
generation and editing. Prompts up to ~4.5k tokens compose whole-page
layouts (newspapers, storyboards, exam papers, infographic grids) in a single
pass, with text legible down to 10px across 12 languages. Two tiers:
qwen-image-3.0 (1K and 2K cost the same) and qwen-image-3.0-pro (tuned for
dense text and layout; 2K costs twice 1K).
Quick example
curl https://reapi.ai/api/v1/images/generations \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"model": "qwen-image-3.0-pro",
"prompt": "A cafe menu board, three columns - appetizers, mains, desserts - five dishes each with prices, serif headings, cream paper background",
"size": "3:4",
"resolution": "2K",
"n": 1
}'import requests
resp = requests.post(
"https://reapi.ai/api/v1/images/generations",
headers={
"Authorization": "Bearer YOUR_API_KEY",
"Content-Type": "application/json",
},
json={
"model": "qwen-image-3.0-pro",
"prompt": "A cafe menu board, three columns - appetizers, mains, desserts - five dishes each with prices, serif headings, cream paper background",
"size": "3:4",
"resolution": "2K",
"n": 1,
},
timeout=30,
)
print(resp.json())const r = await fetch("https://reapi.ai/api/v1/images/generations", {
method: "POST",
headers: {
Authorization: "Bearer YOUR_API_KEY",
"Content-Type": "application/json",
},
body: JSON.stringify({
model: "qwen-image-3.0-pro",
prompt: "A cafe menu board, three columns - appetizers, mains, desserts - five dishes each with prices, serif headings, cream paper background",
size: "3:4",
resolution: "2K",
n: 1,
}),
});
console.log(await r.json());package main
import (
"bytes"
"encoding/json"
"fmt"
"io"
"net/http"
)
func main() {
body, _ := json.Marshal(map[string]any{
"model": "qwen-image-3.0-pro",
"prompt": "A cafe menu board, three columns - appetizers, mains, desserts - five dishes each with prices, serif headings, cream paper background",
"size": "3:4",
"resolution": "2K",
"n": 1,
})
req, _ := http.NewRequest("POST",
"https://reapi.ai/api/v1/images/generations", bytes.NewReader(body))
req.Header.Set("Authorization", "Bearer YOUR_API_KEY")
req.Header.Set("Content-Type", "application/json")
resp, _ := http.DefaultClient.Do(req)
defer resp.Body.Close()
out, _ := io.ReadAll(resp.Body)
fmt.Println(string(out))
}Submit response
{
"id": "task_018f5a3a1b6e7d9f8c2b4d6e8f0a2c4e",
"model": "qwen-image-3.0-pro",
"status": "processing",
"created_at": 1735000000
}Poll GET /api/v1/tasks/{id} (see the Tasks reference) until
status === "completed". The completed payload's output.image_urls holds the
generated image URLs.
Authentication
Every call needs a Bearer token. Generate keys at reapi.ai/settings/apikeys.
Authorization: Bearer YOUR_API_KEYEndpoint
POST /api/v1/images/generations
GET /api/v1/tasks/{id}Submission is async. The POST returns immediately with a task_id; the task
endpoint returns the same envelope until completion. Polling does not consume
credits.
Tiers
Two model ids share one parameter shape:
| Model id | Tier | Resolution pricing |
|---|---|---|
qwen-image-3.0 | Standard | 1K and 2K cost the same |
qwen-image-3.0-pro | Pro | 2K costs twice 1K |
Pick Pro for dense text and layout work — menus, newspapers, storyboards, exam papers. Standard is the cheaper general-purpose tier and is the better default when the output is a single illustration or photo.
Modes
The mode is implicit in the request shape — there is no mode field:
| Inputs | Mode |
|---|---|
prompt only | Text-to-image |
prompt + image_urls | Image-to-image / editing (1-3 references) |
Reference images are not billed, so an edit costs the same as a generation at the same tier and resolution.
Request body
model — string, required
qwen-image-3.0 or qwen-image-3.0-pro. See Tiers.
prompt — string, required
What to draw or how to edit. The upstream model accepts roughly 4.5k tokens, which is enough to describe a full multi-column page in one request. The limit is counted in tokens rather than characters, so an over-long prompt is rejected upstream rather than by a character count on reAPI's side.
image_urls — array, optional
1-3 public image URLs to edit or draw from. Supplying them switches the request to image-to-image.
Public http(s) URLs only. Base64 payloads and data: URIs are rejected by
reAPI on every model.
Accepted source formats: JPG / JPEG / PNG / BMP / TIFF / WEBP / GIF, up to 10 MB each.
n — integer, default 1
How many images to return, 1-6. Every delivered image is billed, so n: 6
costs six images.
size — string, default 1:1
Aspect ratio, or an explicit pixel size. Documented ratios:
1:1, 4:3, 3:4, 16:9, 9:16, 3:2, 2:3
The field also accepts 16x9 style and explicit pixels such as 1600x900. For
custom pixels each edge must be 512-2048 and the aspect ratio must fall
between 1:8 and 8:1.
Ratio and tier combine as follows:
| Resolution | 1:1 | 4:3 | 3:4 | 16:9 | 9:16 | 3:2 | 2:3 |
|---|---|---|---|---|---|---|---|
| 1K | 1024×1024 | 1152×864 | 864×1152 | 1280×720 | 720×1280 | 1248×832 | 832×1248 |
| 2K | 2048×2048 | 2048×1536 | 1536×2048 | 2048×1152 | 1152×2048 | 2048×1360 | 1360×2048 |
A raw pixel size whose area exceeds 2.25M pixels is billed at the 2K
rate even if you did not send resolution. On the Pro tier that is twice the 1K
rate — name the tier explicitly if you want to control the bill.
resolution — string, default 1K
1K or 2K (lowercase is accepted and normalised). On qwen-image-3.0 both
tiers cost the same; on qwen-image-3.0-pro 2K costs twice 1K.
negative_prompt — string, optional
Content to keep out of the image.
prompt_extend — boolean, default false
Enables intelligent prompt rewriting before generation. Note this defaults to false here — the 2.0 series defaulted to true. Turn it on for terse prompts; leave it off when you have written a precise layout brief you want followed literally.
prompt_extend_mode — string, optional
How aggressively the prompt is rewritten. Requires prompt_extend: true.
| Value | Behaviour |
|---|---|
direct | Works for both text-to-image and image-to-image |
agent | More aggressive rewrite; text-to-image only |
Sending prompt_extend_mode without prompt_extend: true, or agent together
with image_urls, returns a 400.
Pricing
Qwen Image 3.0 bills per successfully generated image. Total charge is the
per-image rate for the selected tier and resolution, times n:
credits = ceil(per_image_usd × n × 1000)where 1 credit = $0.001 USD. The rate depends on the model id and, on Pro, the
resolution tier:
| Model id | Rate dimension |
|---|---|
qwen-image-3.0 | One rate for every resolution |
qwen-image-3.0-pro | One rate for 1K, a higher one for 2K |
Reference images are free — an edit costs the same as a generation. Failed and rejected requests are not charged.
The exact per-image credit cost for each row surfaces on the model page and through the playground estimator before submit.
Response
The poll envelope returns image URLs in output.image_urls:
{
"id": "task_019dfd44b7fd74168541552a3260a623",
"model": "qwen-image-3.0-pro",
"status": "completed",
"output": {
"image_urls": [
"https://cdn.reapi.ai/...png"
]
}
}For n > 1, image_urls holds every delivered image. Mirror the URLs to your
own storage if you need long-term retention.
Errors
Failures return the standard reAPI envelope { error: { code, message, request_id } }. Common cases:
- Invalid input (
noutside 1-6, more than 3image_urls, a custom pixel edge outside 512-2048, an invalid ratio,prompt_extend_modewithoutprompt_extend: true,agentmode withimage_urls, a non-HTTPS media URL) →400. - Insufficient credits →
402. - Rate limited →
429.
See the full catalog at /docs/api/errors.
Tips
- The mode is decided by your inputs, not a flag — omit
image_urlsfor pure generation, include it to edit. - Spend the prompt budget. This model is built for long, structural briefs: describe the masthead, each column, the captions and the sidebar in one request instead of generating pieces and assembling them.
- Draft at
1Kand re-run only the winner at2K. On the Pro tier that halves the cost of iteration. - Leave
prompt_extendoff when your prompt is already a precise layout spec — rewriting can restructure a brief you wrote deliberately. - Reach for
qwen-image-3.0-prowhen the image has to carry a lot of small text; useqwen-image-3.0for general illustration and photography.