Skip to main content
POST
/
api
/
v3
/
alibaba
/
wan-2.5
/
text-to-image
Text to Image
curl --request POST \
  --url https://gptproto.com/api/v3/alibaba/wan-2.5/text-to-image \
  --header 'Authorization: <authorization>' \
  --header 'Content-Type: application/json' \
  --data '{
  "prompt": "<string>",
  "size": "<string>",
  "enable_prompt_expansion": true,
  "negative_prompt": "<string>",
  "seed": 123
}'
{
  "error": {
    "message": "Invalid signature",
    "type": "401"
  }
}

Overview

Alibaba WAN 2.5 is a cutting-edge text-to-image model on Alibaba Cloud’s DashScope. It generates high-quality, detailed images directly from text prompts and supports multiple output resolutions.

Supported inputs & outputs :

Inputs: Text Outputs: Text and image

Authentication

This endpoint requires authentication using a Bearer token.
Authorization
string
default:"sk-***********"
required
Your API key in the format: YOUR_API_KEY

Request Body

prompt
string
default:"a blue cat"
required
The positive prompt for the generation.
size
string
default:"1024*1024"
768 ~ 1440 per dimension . The size of the generated image in pixels (width*height).
enable_prompt_expansion
boolean
default:"1024*1024"
If set to true, the prompt optimizer will be enabled.
negative_prompt
string
The negative prompt for the generation.
seed
integer
default:"-1"
-1 ~ 2147483647. The random seed to use for the generation. -1 means a random seed will be used.
curl -X POST "https://gptproto.com/api/v3/alibaba/wan-2.5/text-to-image" \
  -H "Authorization: YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
  "prompt": "a blue cat",
  "enable_prompt_expansion": false,
  "size": "1024*1024",
  "negative_prompt": "",
  "seed": -1

}'

Response

data.id
string
Unique identifier for the prediction, Task Id
data.status
string
Status of the task: created, processing, completed, or failed
{
  "data": {
    "id": "5d87273c75ea40f19a34dea994276673",
    "model": "alibaba/wan-2.5/text-to-image",
    "outputs": [],
    "urls": {
      "get": "https://gptproto.com/api/v3/predictions/5d87273c75ea40f19a34dea994276673/result"
    },
    "hasNsfwContents": [],
    "status": "created",
    "createdAt": "2025-11-10T09:50:05.977Z",
    "error": "",
    "executionTime": 0,
    "timings": {
      "inference": 0
    }
  },
  "message": "success",
  "code": 200
}
{
  "error": {
    "message": "Invalid signature",
    "type": "401"
  }
}