Qwen Image 2.1 Pro
qwen-image-2.1-pro
ImageQwenQwen Image 2.1 Proqwen-image-2.1-pro
Qwen-Image 2.1 Pro (qwen-image-2.1-pro) is Alibaba Qwen's text-to-image model. The full Qwen-Image 2.1 model, with better quality, detail and text rendering than Turbo. It renders Chinese and English text well. Qwen-Image 2.1 Turbo in the same series is faster and cheaper. For image editing or multi-image composition use Qwen-Image 3.0. The endpoint is OpenAI Images compatible and works with the official OpenAI SDKs.
Authentication
- Base URL
https://api.dreamto.ai- Authorization
Authorization: Bearer YOUR_API_KEY- Content-Type
application/json- Model name (model)
qwen-image-2.1-pro
Setup
| DreamTo | |
|---|---|
| Base URL | https://api.dreamto.ai/v1 |
| API key | An API key from the DreamTo console, in the Authorization: Bearer header |
Endpoints
| Endpoint | Purpose |
|---|---|
POST /v1/images/generations | Create image |
Parameters
| Field | Values |
|---|---|
prompt | Required, any language; put text that should appear in the image in quotes |
size | WIDTHxHEIGHT, total pixels 512×512 to 2048×2048, aspect ratio 1:8 to 8:1; when omitted the model picks a size for the prompt |
n | 1 to 6, default 1 |
Common sizes:
size |
|---|
1024x1024 |
1536x1024 |
1024x1536 |
1472x1104 |
1104x1472 |
1664x928 |
928x1664 |
2048x2048 |
Pricing
Billed per image, $0.04 per image; see the model catalog and the console for current prices. Invalid requests and failed generations are not charged.
Quick start
$DREAMTO_API_KEY in the examples is your API key.
cURLbash
curl -X POST "https://api.dreamto.ai/v1/images/generations" \
-H "Authorization: Bearer $DREAMTO_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"model": "qwen-image-2.1-pro",
"prompt": "A cinematic city-at-night poster with the title \"NIGHT RIDE\" at the top",
"size": "1024x1024"
}'Notes
data[].urlin the response is an image link; download and keep it promptly.usagereturnsimage_count(billed per image) and the imagewidth/height.- Text-to-image only;
negative_prompt, image editing and reference images are not supported. - Errors use the DreamTo error format (see the error examples on the endpoint).