Qwen Image 2.0
Qwen Image 2.0 costs $0.04 per image on LLM API. It generates images from text.
Pricing
Served by Together AI, the only provider.
| Image | $0.04/ image | per image |
|---|
Specifications
- ModesGenerate
- Output formatsJPEG, PNG
Call Qwen Image 2.0
POST /v1/images/generationsSet LLMAPI_KEY to your LLM API key.Generate docs
import base64
import os
from openai import OpenAI
client = OpenAI(
base_url="https://api.llmapi.ai/v1",
api_key=os.environ["LLMAPI_KEY"],
)
result = client.images.generate(
model="qwen-image-2.0",
prompt="A lighthouse at dawn, watercolor",
response_format="b64_json",
)
with open(f"image.{result.output_format}", "wb") as f:
f.write(base64.b64decode(result.data[0].b64_json))import fs from "node:fs";
import OpenAI from "openai";
const client = new OpenAI({
baseURL: "https://api.llmapi.ai/v1",
apiKey: process.env.LLMAPI_KEY,
});
const result = await client.images.generate({
model: "qwen-image-2.0",
prompt: "A lighthouse at dawn, watercolor",
response_format: "b64_json",
});
fs.writeFileSync(`image.${result.output_format}`, Buffer.from(result.data![0].b64_json!, "base64"));curl https://api.llmapi.ai/v1/images/generations \
-H "Authorization: Bearer $LLMAPI_KEY" \
-H "Content-Type: application/json" \
-d '{
"model": "qwen-image-2.0",
"prompt": "A lighthouse at dawn, watercolor",
"response_format": "b64_json"
}'More from Alibaba
All Alibaba image models
Qwen Image 2.0 Proqwen-image-2.0-pro$0.08per image
Qwen Image Max 2025-12-30qwen-image-max-2025-12-30$0.0375per image
Qwen Imageqwen-image$0.035per image
Prices synced .