APIMart
Qwen Image 2.0 model icon
Image

Qwen Image 2.0 API

Qwen Image 2.0 (qwen-image-2.0) is Alibaba's Qwen image model for text to image and image editing in one model. Use the Qwen Image API to render readable text in posters, infographics and slides, or edit a photo with a plain-language instruction, at 1K or 2K.

Image GenerationText to Image

Service Highlights

  • Official Discounts
  • Pay-as-you-go
  • Fast & Low Latency
Input
172 / 800 characters
Output
Generated 1

Image link valid for 72 hours

Qwen Image 2.0 API Pricing

Transparent pricing with no hidden fees. Pay only for what you use.

VariantTierGoldCurrent pricePlatinumDiamondOfficialYour savings
qwen-image-2.01K/2K0.2Credits(~$0.02)/pic0.19Credits(~$0.019)/pic0.18Credits(~$0.018)/pic0.25Credits(~$0.025)/pic20%

* Actual costs are subject to final output.

Qwen Image 2.0 API - Text-Rich Images and Natural-Language Editing

Qwen Image 2.0 API by Alibaba: create posters, infographics and slides with readable in-image text, then edit images by describing the change in plain language. One endpoint handles text to image and image to image, with 1–6 images per request at 1K or 2K. Save 20% or more with membership.

50K+

Active Users

99.9%

Uptime

2x

Faster

20%

Cost Savings

Qwen Image 2.0 API Example: Text to Image and Image Editing

Call qwen-image-2.0 on APIMart with one POST request. Generation is asynchronous: submit a task, then poll the task endpoint for the Qwen Image 2.0 image URL.

  1. 1

    Authenticate Qwen Image API requests

    Save the key you created above in the APIMART_API_KEY environment variable and send it as Authorization: Bearer <key> on every request.

  2. 2

    Submit a Qwen Image 2.0 task

    POST /v1/images/generations with model qwen-image-2.0, your prompt, size and resolution. Add image_urls to edit an existing image. The response returns a task_id.

  3. 3

    Get the Qwen Image 2.0 result

    Send GET /v1/tasks/{task_id} until status is completed, then read the image URL from data.result.images[0].url[0]. Generated images are mirrored to the APIMart CDN. Failed tasks are not charged.

    See the Qwen Image 2.0 API reference for every parameter and response field.

POST /v1/images/generations
curl -X POST https://api.apimart.ai/v1/images/generations \
  -H "Authorization: Bearer $APIMART_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "model": "qwen-image-2.0",
    "prompt": "A minimalist coffee shop poster with the headline OPEN LATE and the line Fresh espresso until 2 AM, warm brown tones, clean sans-serif type",
    "n": 1,
    "size": "3:4",
    "resolution": "2K"
  }'

Qwen Image 2.0 API Parameters

ParameterTypeRequiredDefaultDescription
modelstringRequiredDefault: qwen-image-2.0Model ID. Use qwen-image-2.0; qwen-image-2.0-pro takes the same parameters.
promptstringRequiredDefault: —Text description of the image, or the edit instruction when image_urls is set. Up to 800 characters.
sizestringOptionalDefault: 1:1Aspect ratio: 1:1, 4:3, 3:4, 16:9, 9:16, 3:2 or 2:3.
resolutionstringOptionalDefault: 1KResolution tier: 1K or 2K. For example, 16:9 is 1280×720 in 1K and 2048×1152 in 2K.
nintegerOptionalDefault: 1Number of images to generate, 1–6.
negative_promptstringOptionalDefault: —Content you do not want in the image. Up to 500 characters.
image_urlsarrayOptionalDefault: —Reference images for image to image editing, up to 3. Must be publicly accessible URLs; base64 is not supported.
nsfw_checkbooleanOptionalDefault: falseSet to true to moderate the prompt and input images before the task is submitted.

Guides, comparisons and pricing analysis from the APIMart blog.