Skip to content

Qwen image generation ​

Qwen is Alibaba's image-generation family. The orchestrator exposes three invocation paths, covering different versions of the model family:

engineModelBest forNotes
sdcpp (ecosystem qwen)20bDefault — Qwen-Image 20B on Civitai workerscreateImage / createVariant / editImage. Version picker (latest, 2509, 2512, 2511). LoRA support.
qwen3.0-pro, 2.0-pro, 2.0The full Alibaba-hosted catalog, including the newest releasescreateImage / editImage. Explicit width/height. No LoRA support.
falqwen2The Qwen-Image-2 tier under a stable, FAL-shaped requestcreateImage / proCreateImage / editImage / proEditImage. imageSize enum instead of width/height. No LoRA support.

Default choice: engine: "sdcpp", ecosystem: "qwen", model: "20b". Reach for engine: "qwen" when you want a model Civitai doesn't host itself — Qwen-Image 3.0 Pro or 2.0 Pro.

Prerequisites ​

  • For editImage / createVariant: one or more source image URLs, data URLs, or Base64 strings

sdcpp — Qwen-Image 20B (default path) ​

Text-to-image (createImage) ​

http
POST https://orchestration.civitai.com/v2/consumer/workflows?wait=60
Authorization: Bearer <your-token>
Content-Type: application/json

{
  "steps": [{
    "$type": "imageGen",
    "input": {
      "engine": "sdcpp",
      "ecosystem": "qwen",
      "model": "20b",
      "operation": "createImage",
      "version": "latest",
      "prompt": "A photorealistic portrait of a woman with flowers in her hair, golden hour lighting, highly detailed",
      "width": 1024,
      "height": 1024,
      "cfgScale": 2.5,
      "steps": 20
    }
  }]
}
POST/v2/consumer/workflows
Set your Civitai API token via the Token button in the navbar to enable Try It.
Request body — edit to customize (e.g. swap the image URL or prompt)
Valid JSON

Common sdcpp-qwen parameters:

FieldDefaultRangeNotes
model— ✅20bCurrently only 20b is exposed.
versionlatestlatest / 2509 / 2512 (create + variant) / 2511 (edit)Model release snapshot. latest follows whichever is current.
prompt— ✅≤ 10 000 charsNatural-language works well on Qwen.
negativePrompt(none)≤ 10 000 charsOptional.
width / height102464–2048, divisible by 8Qwen-Image 20B is trained at 1024². Well-behaved aspect ratios stay near that pixel count. On editImage / createVariant, width/height are inferred from the source image if omitted; you may still supply them explicitly.
cfgScale2.50–30Lower than most image models — 2–4 is the sweet spot.
steps201–15020–30 typical.
sampleMethodeulerenumSdCppSampleMethod.
schedulesimpleenumSdCppSchedule.
loras{}{ airUrn: strength }Stack multiple; 0.6–1.0 strengths typical.
quantity11–12Number of images per call.
seedrandomint64Pin for reproducibility.

Picking a version ​

versionAvailable onNotes
latestall opsFollows whatever release Civitai is currently pinning to. Recommended unless you need reproducibility against a specific release.
2509all opsSeptember 2025 release snapshot.
2512create / variantDecember 2025 release.
2511editNovember 2025 release — edit-specific snapshot.
json
{
  "steps": [{
    "$type": "imageGen",
    "input": {
      "engine": "sdcpp",
      "ecosystem": "qwen",
      "model": "20b",
      "operation": "createImage",
      "version": "2512",
      "prompt": "A majestic mountain landscape at sunrise, cinematic composition",
      "width": 1024,
      "height": 1024,
      "cfgScale": 2.5,
      "steps": 20
    }
  }]
}
POST/v2/consumer/workflows
Set your Civitai API token via the Token button in the navbar to enable Try It.
Request body — edit to customize (e.g. swap the image URL or prompt)
Valid JSON

Pin to a specific version when you need reproducible output or are comparing generations across a larger experiment; stick to latest for day-to-day use.

With LoRAs ​

LoRAs are a map of AIR URN → strength:

json
{
  "steps": [{
    "$type": "imageGen",
    "input": {
      "engine": "sdcpp",
      "ecosystem": "qwen",
      "model": "20b",
      "operation": "createImage",
      "prompt": "A detailed anime character in a magical forest, ethereal lighting",
      "width": 1024,
      "height": 1024,
      "cfgScale": 2.5,
      "steps": 20,
      "loras": {
        "urn:air:qwen:lora:civitai:123456@789012": 0.8
      }
    }
  }]
}
POST/v2/consumer/workflows
Set your Civitai API token via the Token button in the navbar to enable Try It.
Request body — edit to customize (e.g. swap the image URL or prompt)
Valid JSON

Only Qwen-tagged LoRAs work on the qwen ecosystem. Browse the Civitai Qwen LoRA catalog for AIR URNs.

Image-to-image (createVariant) ​

Pass a single source image and a prompt; the model re-imagines it. strength controls how much of the source to preserve — 0.0 returns the source unchanged, 1.0 discards it entirely. Width and height are inferred from the source.

json
{
  "steps": [{
    "$type": "imageGen",
    "input": {
      "engine": "sdcpp",
      "ecosystem": "qwen",
      "model": "20b",
      "operation": "createVariant",
      "prompt": "Turn it into a winter scene with snow falling",
      "image": "https://image.civitai.com/.../source.jpeg",
      "strength": 0.7
    }
  }]
}
POST/v2/consumer/workflows
Set your Civitai API token via the Token button in the navbar to enable Try It.
Request body — edit to customize (e.g. swap the image URL or prompt)
Valid JSON

Note image is a plain string URL (not a { url: ... } wrapper), and the field is strength (default 0.7).

Edit image (editImage) ​

Pass up to 10 reference images via images[] — Qwen-Image's edit variant accepts more sources than most edit pipelines:

json
{
  "steps": [{
    "$type": "imageGen",
    "input": {
      "engine": "sdcpp",
      "ecosystem": "qwen",
      "model": "20b",
      "operation": "editImage",
      "prompt": "Add a rainbow in the sky",
      "images": [
        "https://image.civitai.com/.../source.jpeg"
      ]
    }
  }]
}
POST/v2/consumer/workflows
Set your Civitai API token via the Token button in the navbar to enable Try It.
Request body — edit to customize (e.g. swap the image URL or prompt)
Valid JSON

Width/height are inferred from the source image(s) when omitted.

qwen — the Alibaba-hosted catalog ​

engine: "qwen" reaches Alibaba Model Studio directly, which is where the newest Qwen image models land first. Two operations — createImage and editImage — with the model chosen by model:

json
{
  "steps": [{
    "$type": "imageGen",
    "input": {
      "engine": "qwen",
      "model": "2.0",
      "operation": "createImage",
      "prompt": "A photorealistic portrait of a woman with flowers in her hair, golden hour lighting",
      "width": 1328,
      "height": 1328
    }
  }]
}
POST/v2/consumer/workflows
Set your Civitai API token via the Token button in the navbar to enable Try It.
Request body — edit to customize (e.g. swap the image URL or prompt)
Valid JSON

Picking a model ​

modelOperationsSizingquantityNotes
3.0-procreate, edit512–2048 per side1–6Newest generation. Lowest throughput of the family — reserve it for hero shots.
2.0-procreate, edit512–2048 per side1–6Strongest generally-available tier: text rendering, realistic texture, prompt adherence.
2.0create, edit512–2048 per side1–6Default for createImage and editImage. Accelerated; balances quality and throughput.

Legacy models are retired

max, plus, edit-max, edit-plus and edit were retired on 2026-10-09 16:00 UTC. A request using one is rejected with a 400 that names the replacement: 2.0-pro for max and edit-max, 2.0 for the others. editImage defaults to 2.0.

Omit width and height entirely to let the model choose: on createImage it infers a resolution from the prompt, and on editImage it matches the input image's aspect ratio at roughly 1024².

Parameters ​

FieldDefaultRangeNotes
prompt— ✅≤ 5 000 charsNatural-language works well on Qwen.
negativePrompt(none)≤ 500 charsOptional.
width / height(model chooses)512–2048 eachSee the sizing rules above.
quantity11–6
promptExtendtruebooleanModel-side prompt rewriting. On by default, and it dominates latency — measured on 3.0-pro at 2048×1152: 11 s off vs 98 s on. Set false to send your prompt verbatim and generate far faster.
watermarkfalsebooleanAdds Alibaba's "Qwen-Image" watermark bottom-right.
seedrandomint32Pin for reproducibility.
images— ✅ on editImage1–3Referenced in prompts as "Image 1", "Image 2", "Image 3" — order matters.

Text-to-image on the pro tier ​

json
{
  "steps": [{
    "$type": "imageGen",
    "input": {
      "engine": "qwen",
      "model": "2.0-pro",
      "operation": "createImage",
      "prompt": "An epic fantasy battle scene with dragons, cinematic lighting, intricate details",
      "width": 2048,
      "height": 1152
    }
  }]
}
POST/v2/consumer/workflows
Set your Civitai API token via the Token button in the navbar to enable Try It.
Request body — edit to customize (e.g. swap the image URL or prompt)
Valid JSON

Edit image (editImage) ​

json
{
  "steps": [{
    "$type": "imageGen",
    "input": {
      "engine": "qwen",
      "model": "2.0",
      "operation": "editImage",
      "prompt": "Make it daytime",
      "images": [
        "https://image.civitai.com/.../source.jpeg"
      ]
    }
  }]
}
POST/v2/consumer/workflows
Set your Civitai API token via the Token button in the navbar to enable Try It.
Request body — edit to customize (e.g. swap the image URL or prompt)
Valid JSON

With multiple references, name them in the prompt — e.g. "Put the jacket from Image 2 on the person in Image 1".

fal — Qwen-Image-2 under the FAL request shape ​

The commercial Qwen-Image-2 tier, including Pro via the proCreateImage and proEditImage operations, using engine: "fal", model: "qwen2":

json
{
  "steps": [{
    "$type": "imageGen",
    "input": {
      "engine": "fal",
      "model": "qwen2",
      "operation": "createImage",
      "prompt": "A photorealistic portrait of a woman with flowers in her hair, golden hour lighting",
      "imageSize": "square_hd"
    }
  }]
}
POST/v2/consumer/workflows
Set your Civitai API token via the Token button in the navbar to enable Try It.
Request body — edit to customize (e.g. swap the image URL or prompt)
Valid JSON

Now served by Alibaba

This path executes on Alibaba Model Studio rather than FAL. Nothing about the request, the response, or the price changed — but if you're starting fresh, engine: "qwen" above exposes the same models with explicit dimensions and a wider catalog.

FAL-specific parameters ​

FieldDefaultRangeNotes
prompt— ✅≥ 1 charNatural-language works well on Qwen.
negativePrompt(none)≤ 500 charsMuch tighter limit than sdcpp's 10 000.
imageSizesquare_hdsquare_hd / square / portrait_4_3 / portrait_16_9 / landscape_4_3 / landscape_16_9Enum, not width/height. FAL doesn't accept arbitrary dimensions on Qwen2.
quantity11–10Slightly lower ceiling than sdcpp's 12.
enablePromptExpansiontruebooleanModel-side prompt expansion — Qwen rewrites your prompt before generation. On by default.
enableSafetyCheckerfalsebooleanFAL's safety filter. Off by default.
seedrandomint32Pin for reproducibility.

FAL Qwen2 does not support LoRAs or uCache — use the sdcpp path when you need either.

Pro tier (proCreateImage / proEditImage) ​

The Pro tier keeps the same input shape but routes to a higher-quality backing model. Swap the operation to proCreateImage for text-to-image or proEditImage for editing:

json
{
  "steps": [{
    "$type": "imageGen",
    "input": {
      "engine": "fal",
      "model": "qwen2",
      "operation": "proCreateImage",
      "prompt": "An epic fantasy battle scene with dragons, cinematic lighting, intricate details",
      "imageSize": "landscape_16_9"
    }
  }]
}
POST/v2/consumer/workflows
Set your Civitai API token via the Token button in the navbar to enable Try It.
Request body — edit to customize (e.g. swap the image URL or prompt)
Valid JSON

Pro costs more and is slower, but delivers stronger prompt adherence and finer detail. Use for hero shots where quality matters more than throughput.

Edit image (FAL) ​

FAL's edit operation accepts 1–3 reference images (vs sdcpp's 10):

json
{
  "steps": [{
    "$type": "imageGen",
    "input": {
      "engine": "fal",
      "model": "qwen2",
      "operation": "editImage",
      "prompt": "Make it daytime",
      "images": [
        "https://image.civitai.com/.../source.jpeg"
      ]
    }
  }]
}
POST/v2/consumer/workflows
Set your Civitai API token via the Token button in the navbar to enable Try It.
Request body — edit to customize (e.g. swap the image URL or prompt)
Valid JSON

Swap to proEditImage for the Pro tier variant.

Reading the result ​

Standard imageGen output: an images[] array, one entry per quantity (shape and URL expiry).

Runtime ​

PathTypical wall time per 1024×1024 imagewait recommendation
sdcpp Qwen-Image 20B15–35 swait=60 usually fine for quantity: 1
qwen, promptExtend: false10–15 swait=60 usually fine
qwen, promptExtend: true (default)60–100 sPrompt rewriting adds ~60–90 s. Submit with wait=0 and poll, or turn it off
fal Qwen2 (create / edit)10–30 swait=60 usually fine
fal Qwen2 Pro (proCreateImage / proEditImage)20–60 swait=60 sometimes; fall back to wait=0 on busy periods

Large quantity or atypical aspect ratios can outlast your HTTP client's timeout — submit with wait=0 and poll.

Cost ​

Preview the exact charge with whatif=true (Payments (Buzz)).

sdcpp Qwen-Image 20B — per-pixel + per-step scaling, with editImage carrying a flat higher base:

createImage / createVariant:
  total = 30 × (width × height / 1328²) × (steps / 20) × quantity

editImage:
  total = 40 × (width × height / 1024²) × (steps / 20) × (1 + (numImages − 1) × 0.1) × quantity
ShapeBuzz
createImage, 1024²/steps: 20/quantity: 1~18
createImage, 1328²/steps: 20/quantity: 1~30
createImage, 1024²/steps: 20/quantity: 4~72
editImage, 1 ref, 1024²/steps: 2040
editImage, 3 refs, 1024²/steps: 2048

Alibaba-hosted models (engine: "qwen") — flat per generated image, no pixel or step scaling:

total = base × quantity
modelBuzz per image
2.045.5
3.0-pro, 2.0-pro97.5

FAL Qwen2 (engine: "fal") — fixed per operation, per image. createImage / editImage are cheapest; proCreateImage / proEditImage cost meaningfully more. Use whatif=true to confirm pricing for your shape.

Troubleshooting ​

Timeouts, moderation blocks and expired blob URLs: see Common troubleshooting. Timeouts here usually mean the Pro tier on a busy queue.

SymptomLikely causeFix
400 with "ecosystem must be qwen"TypoLowercase "qwen" — not "Qwen" or "qwen2" (that's the fal model, not the sdcpp ecosystem).
400 with "version must be one of"Picked a version that isn't valid for that operationEdit supports latest/2509/2511; create + variant support latest/2509/2512.
400 with unexpected "width/height" error on edit/variantDimensions conflict with source resolutionOmit width/height; they auto-populate from the source.
400 with "imageSize must be one of" on falArbitrary dimensions on the fal pathThe fal path uses the enum — pick square_hd, landscape_16_9, etc. Use engine: "qwen" or the sdcpp path for arbitrary dimensions.
400 "Model '…' was retired on …" on engine: "qwen"A retired model (max, plus, edit-max, edit-plus, edit)Use the replacement the message names (2.0 or 2.0-pro).
Prompt visibly rewritten before generationpromptExtend defaults to true on engine: "qwen"Set promptExtend: false to send it verbatim.
400 with "images maxItems"More than 10 source images on sdcpp editImage, or more than 3 on fal editImageTrim the array.
LoRA has no effectOnly the sdcpp path supports LoRAsSwitch to engine: "sdcpp", ecosystem: "qwen".
Output ignores the promptcfgScale too low (Qwen wants ~2.5, far below SD1/SDXL's 7) or enablePromptExpansion rewriting your carefully-tuned textBump cfgScale toward 4 on sdcpp; set enablePromptExpansion: false on fal.

Civitai Developer Documentation