Qwen Image 2.0 Pro API
/v1/tasks All models are called through the Unified Async API POST /v1/tasks endpoint; only the input fields differ (see input parameters below).
Model summary
| Model name | qwen-image-2.0-pro |
|---|---|
| Type | Image generation (text-to-image) |
| Endpoint | POST /v1/tasks |
| Pricing | See HiAPI Pricing |
The professional tier of Alibaba Qwen Image 2.0: stronger in-image text rendering, finer photorealistic detail and better adherence, up to 2048x2048, billed per image.
Production guidance
- For production, pass callback.url at the top level of the request body so HiAPI can notify your service when the task reaches a terminal state.
- GET /v1/tasks/:id is better for local debugging, low-volume jobs, or fallback reconciliation if a callback is missed.
- Use callback.when=final. Both success and fail are terminal states, so your service should deduplicate by taskId.
Best suited for
Plaques, couplets and labels render accurately — the Pro tier speciality, verified in real runs.
promptprompt_extendSkin texture, metal reflections and material detail clearly beat the base tier — built for portraits and product shots.
promptStronger semantic adherence gets multi-element compositions (subject + text + mood) right in one pass.
promptsizeFree width*height between 512x512 and 2048x2048 total pixels, with five recommended presets.
sizeRequest parameters
model string required Fixed value qwen-image-2.0-pro.
input object required Business parameters. Put Qwen Image 2.0 Pro-specific configuration here.
prompt string required Text description of the image. Chinese and English both work well; spell out any text you want rendered.
size enum optional Output size in width*height. Total pixels between 512x512 and 2048x2048.
negative_prompt string optional Describe what to avoid in the generated image.
prompt_extend boolean optional Automatically optimize the prompt for better results. Adds slight latency.
watermark boolean optional Add an AI-generated watermark to the output.
seed integer optional Random seed for reproducible generation, 0 to 2147483647.
callback object optional Optional callback configuration. When set, HiAPI notifies your service when the task reaches a terminal state.
url string required Required when callback is set; HTTPS URL that receives terminal task notifications.
when enum optional Callback trigger timing. Use final.
Example requests
16:9 scene with calligraphy plaque — text + atmosphere.
{
"model": "qwen-image-2.0-pro",
"input": {
"prompt": "一座悬浮在云海之上的中式空中茶馆,飞檐翘角挂满暖黄灯笼,木质牌匾上写着「云顶茶居」四个楷书大字,一条木栈道从云中延伸至茶馆,晨光穿透云层,电影感构图,戏剧性定向打光,暖金与云白统一色调,超高细节,商业级质感,细微胶片颗粒",
"size": "2688*1536",
"prompt_extend": false
}
}3:4 portrait — skin texture and shallow depth of field.
{
"model": "qwen-image-2.0-pro",
"input": {
"prompt": "A photorealistic portrait of an elderly Miao silversmith, weathered hands chiseling a silver butterfly, silver shavings and tools on the workbench, soft window light on his focused profile, lifelike skin texture and silver reflections, shallow depth of field, cinematic composition, ultra-detailed",
"size": "1728*2368",
"prompt_extend": false
}
}9:16 commercial shot with a bilingual label.
{
"model": "qwen-image-2.0-pro",
"input": {
"prompt": "A neo-Chinese perfume product shot: an amber glass bottle standing in shallow water, its label clearly printed with 沉香 and AGARWOOD, ink-wash mountains behind, ripple reflections, morning mist, cinematic composition, amber and ink color grade, ultra-detailed, premium commercial finish",
"size": "1536*2688",
"prompt_extend": false
}
}Getting the result
- The response returns a taskId immediately without waiting for generation to finish.
- In production, prefer waiting for callback.url to receive the terminal notification. For local debugging, poll GET /v1/tasks/:id.
- When status=success, download the generated image from output[].url.
- When status=fail, fix the request based on the returned error instead of retrying the same invalid payload.
FAQ
Pro vs base qwen-image-2.0 — which one?
Pro is stronger at text rendering, photorealism and adherence, at a higher unit price. Iterate on the base tier, deliver on Pro — the parameters are identical, so switching is free.
Does it support 4K?
No. Pro tops out at 2048x2048 total pixels. For native 4K, use wan2.7-image/text-to-image or seedream-5.0-lite.
When should I turn off prompt_extend?
prompt_extend (on by default) rewrites and enriches your prompt. Always set it to false when the image must contain exact text (plaques, couplets, labels) so your wording is preserved; keep it on for pure scene prompts.
How do I get the generated image?
The request returns a taskId immediately. When the task reaches a terminal state, download the image from output[].url. In production, pass callback.url at the top level of the request body instead of polling.