How to Use the Qwen Image 2.1 Turbo Edit API: image to image integration guide (2026)

2 min · Updated 2026-07-11 · By the NamiFusion team

Learn how to call the Qwen Image 2.1 Turbo Edit API on NamiFusion: parameters, pricing (from ≈$0.016) and runnable copy-paste code — try it in the playground first.

Qwen Image 2.1 Turbo Edit is an image to image model by Alibaba: Edit images with a prompt and 1–10 reference images; generate 1–6 output images. On NamiFusion you can try it in the playground (exact quote shown before you submit), then call it through one unified REST API — about $0.016 per typical run.

TL;DR

· Task type: image to image, provided by Alibaba

· Pricing: about $0.016 per typical run ($1 = 100 credits), pay-as-you-go

· Getting started: playground (exact quote before submit) → create an API key → one POST request

· Tunable parameters: 7 (see the table below)

· No platform watermark; commercial use allowed (per the Terms of Service)

What can you build with Qwen Image 2.1 Turbo Edit?

Social media visuals and covers: batch-generate on-theme images and schedule them straight away.

E-commerce and ad creatives: product scenes, banner backgrounds, and multi-variant visuals for A/B tests.

Concept art and ideation: characters, environments and style boards, iterated cheaply and fast.

Pipeline chaining: outputs feed directly into image-to-video or face swap as source material.

How do you call this API?

  1. Sign up on NamiFusion and create a key on the API Keys page (signup bonus credits can only be used on selected models).
  2. Submit a task with the cURL example below, passing your key as a Bearer token.
  3. Poll the task status with the returned task_uuid and read the output URLs when completed.
Submit a task
# 1) Submit — returns { "task_uuid": "..." }
curl -X POST "https://www.namifusion.com/api/v1/marketplace/run/alibaba/qwen-image-2.1-turbo/edit" \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
  "input": {
    "prompt": "Use image 1 as the base photo. Replace the background with a clean, bright modern kitchen interior lit by soft natural morning light. Keep the person exactly recognizable with the same face, hairstyle, pose, and clothing, preserving realistic skin texture and proportions. Improve overall sharpness and color balance, add subtle depth of field, and keep the result photorealistic. Remove any distracting objects from the original background, no text, no watermark, no logo.",
    "images": [
      "https://d1s3annbwribom.cloudfront.net/marketplace/examples/261013/default/905tpxijklp9.jpeg"
    ],
    "n": 1,
    "size": "2048*2048",
    "prompt_extend": true,
    "enable_thinking": true,
    "seed": 12345
  }
}'

# 2) Poll until status is "completed", then read the output URLs
curl "https://www.namifusion.com/api/v1/marketplace/run/tasks/TASK_UUID" \
  -H "Authorization: Bearer YOUR_API_KEY"

What parameters does it take?

prompt (Prompt): required

images (Reference Images): required

n (Number of Images): optional, default 1

size (Size): optional

prompt_extend (Prompt Extend): optional, default true

enable_thinking (Thinking Mode): optional, default true

seed (Seed): optional

How do you write prompts for Qwen Image 2.1 Turbo Edit?

  1. Subject first: lead with the actor and action, then add environment, lighting and style ("an astronaut sprinting through a neon street in the rain, cinematic, shallow depth of field").
  2. Concrete nouns beat stacked adjectives: "85mm portrait lens, golden-hour backlight" works far better than "very beautiful, ultra high quality".
  3. Change one variable per iteration: pin the seed to reproduce a result, tweak a single phrase at a time so you know what actually moved the output.
  4. State negatives positively: instead of "no blur", ask for "sharp focus, crisp details".

How much does it cost?

Pay-per-use in credits. About $0.016 per typical run ($1 = 100 credits); the exact price varies with parameters like resolution or duration, and the playground shows the exact quote before you submit.

Qwen Image 2.1 Turbo Edit

alibaba/qwen-image-2.1-turbo/edit

Edit images with a prompt and 1–10 reference images; generate 1–6 output images.

Parameters

ParameterTypeRequiredDefaultDescription
promptstringtrue—Text prompt describing the desired edit, supports Chinese and English; up to about 4500 tokens is recommended. Negative prompts are not supported, so state anything to avoid directly in the prompt (e.g. "no text"). Ask for a cutout or transparent background and the model outputs a PNG with an alpha channel.; max 5000 characters
imagesarraytrue—Reference images for editing, 1-10 images. Up to 10MB each, 1-8000px per side (384-2048px recommended), aspect ratio up to 10:1. Order defines image 1, image 2 ... image 10 in the prompt.; 1–10 URLs
nintegerfalse1Generate 1-6 images per request, billed per successfully generated image [1, 6]
sizestringfalse—Output size in widthheight format. Total pixels from 512512 to 20482048, aspect ratio between 1:8 and 8:1. Recommended: 20482048 (1:1), 26881536 (16:9), 15362688 (9:16), 23681728 (4:3), 17282368 (3:4). Leave empty to let the model auto-select.; max 16 characters
prompt_extendbooleanfalsetrueAutomatically expands and optimizes the prompt. Recommended; most useful for short prompts.
enable_thinkingbooleanfalsetrueEnhances reasoning to improve image quality at the cost of longer generation time. Only takes effect when Prompt Extend is on.
seedintegerfalse—For reproducibility, 0-2147483647. Leave empty for random. [0, 2.14748e+09]

Pricing

$0.016 per successfully generated image (1.6 credits). Precharge = unit price × requested n; settlement uses the actual successful output image count. Input reference images, output size and prompt expansion add no charge. Default n=1.

size uses width*height; total pixels 512²–2048², aspect ratio 1:8–8:1. Omit size for automatic selection. Omit seed for random generation. enable_thinking only applies when prompt_extend=true.

Alibaba International standard USD list prices. USD 1 = 100 credits. Account discounts are applied separately.

API

curl -X POST https://www.namifusion.com/api/v1/marketplace/run/alibaba/qwen-image-2.1-turbo/edit \
  -H "Authorization: Bearer $API_KEY" \
  -H 'Content-Type: application/json' \
  -d '{
  "input": {
    "n": 1,
    "seed": 12345,
    "size": "2048*2048",
    "images": [
      "https://d1s3annbwribom.cloudfront.net/marketplace/examples/261013/default/905tpxijklp9.jpeg"
    ],
    "prompt": "Use image 1 as the base photo. Replace the background with a clean, bright modern kitchen interior lit by soft natural morning light. Keep the person exactly recognizable with the same face, hairstyle, pose, and clothing, preserving realistic skin texture and proportions. Improve overall sharpness and color balance, add subtle depth of field, and keep the result photorealistic. Remove any distracting objects from the original background, no text, no watermark, no logo.",
    "prompt_extend": true,
    "enable_thinking": true
  }
}'
curl 'https://www.namifusion.com/api/v1/marketplace/run/tasks/TASK_UUID' \
  -H "Authorization: Bearer $API_KEY"

Poll task_uuid until completed or failed. On success, output.images contains output URL strings.

Alibaba official pricing

FAQ

Can I try it for free first?+

Signup bonus credits can only be used on selected models, and eligibility may change. The playground shows the exact quote before submission.

Can I use the output commercially? Is there a watermark?+

Yes, outputs are yours to use commercially, and NamiFusion adds no platform watermark — subject to the Terms of Service and applicable law.

What is the content policy?+

Pornographic content, sexualized content involving a minor, unauthorized use of real people, deceptive impersonation, fraud and false endorsements are prohibited. Lawful, consensual, non-explicit adult themes may be permitted; see the Terms of Service.

How long does a Qwen Image 2.1 Turbo Edit task take?+

It depends on parameters — images usually take seconds, videos tens of seconds to minutes. The API returns a task_uuid for polling.

What are the resolution and duration limits?+

See the parameter table above — each model lists its available resolution and duration options there and in the playground.