Skip to main content
POST
Image-01 text-to-image

Authorizations

Authorization
string
header
required

Pass Authorization: Bearer <token> in the request header.

Body

application/json
model
enum<string>
required

Model name for this capability.

Available options:
image-01
prompt
string
required

Image generation prompt.

Maximum string length: 1500
aspect_ratio
enum<string>

Target aspect ratio.

Available options:
1:1,
16:9,
4:3,
3:2,
2:3,
3:4,
9:16,
21:9
width
integer

Generated image width (pixels). Only effective when model is image-01. Note: width and height must be set together, range [512, 2048], and must be multiples of 8. If set together with aspect_ratio, aspect_ratio takes priority.

Required range: 512 <= x <= 2048Must be a multiple of 8
height
integer

Generated image height (pixels). Only effective when model is image-01. Note: width and height must be set together, range [512, 2048], and must be multiples of 8. If set together with aspect_ratio, aspect_ratio takes priority.

Required range: 512 <= x <= 2048Must be a multiple of 8
response_format
enum<string>

Response format. Use url to get a temporary download link, or base64 to get Base64-encoded content.

Available options:
url,
base64
seed
integer<int64>

Random seed. Explicitly passing 0 will be preserved.

n
integer

Number of images to generate.

Required range: 1 <= x <= 9
prompt_optimizer
boolean

Whether to enable prompt optimization. Explicitly passing false will be preserved.

Response

Success. Returns the unified image response structure.

created
integer<int64>
data
object[]
metadata
object