Skip to main content

Overview

Qwen Image is Alibaba’s image generation family. It includes a multi-angle model for generating different viewpoints of an object, and a general-purpose generation/editing model.
Model IDCapabilityCredits~Cost
qwen-anglesMulti-angle from reference8$0.08
qwen-image-2Text-to-image + editing8$0.08

Quick start

Multi-angle generation

Generate multiple camera angles from a single reference image:
import { createVarg } from "vargai/ai"

const varg = createVarg({ apiKey: process.env.VARG_API_KEY! })

const result = await varg.imageModel("qwen-angles").generate({
  prompt: "product shot from a 45-degree elevated angle",
  imageUrl: "https://example.com/product.jpg",
})

Unified generation/editing

Qwen Image 2 auto-routes between generation and editing based on whether images are provided:
cURL
# Text-to-image (no files)
curl -X POST https://api.varg.ai/v1/image \
  -H "Authorization: Bearer $VARG_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "model": "qwen-image-2",
    "prompt": "a serene Japanese garden with cherry blossoms"
  }'

# Image editing (with files)
curl -X POST https://api.varg.ai/v1/image \
  -H "Authorization: Bearer $VARG_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "model": "qwen-image-2",
    "prompt": "add autumn colors to the trees",
    "files": [{ "url": "https://example.com/garden.jpg" }]
  }'

Parameters

prompt
string
required
Text description. Supports both Chinese and English prompts.
aspect_ratio
string
default:"1:1"
Output aspect ratio.
files
array
Reference images. qwen-angles uses this for the source viewpoint. qwen-image-2 triggers editing mode when images are present. Up to 6 images.
provider_options
object
qwen-angles supports azimuth/elevation camera adjustments. qwen-image-2 supports prompt_expansion and image dimensions (512-2048px).

Pricing

ModelCreditsUSD
qwen-angles8$0.08
qwen-image-28$0.08

Tips

  • Multi-angle is great for product photography — generate multiple viewpoints from a single product photo.
  • Qwen Image 2 supports bilingual prompts (Chinese + English), useful for localized content.
  • Camera angle parameters (azimuth, elevation) give precise control over the viewing angle.

Nano Banana

More versatile for general editing. Same price range.

Phota

Identity-preserving generation with profile support.