生成图像
OpenAI
GPT Image 1.5
使用 GPT Image 1.5 模型从文本提示生成图像。
POST
生成图像
Authorizations
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Body
application/json
模型 ID
Available options:
gpt-image-1.5 Example:
"gpt-image-1.5"
图像描述文本
Example:
"一只穿着太空服漂浮在银河中的可爱猫咪"
生成图片数量
Required range:
1 <= x <= 4Example:
1
输出图片尺寸
Available options:
1024x1024, 1536x1024, 1024x1536, auto Example:
"1024x1024"
图片质量
Available options:
low, medium, high Example:
"high"
输出图片格式
Available options:
png, webp, jpeg Example:
"png"
背景设置,transparent 为透明背景,opaque 为不透明背景
Available options:
transparent, opaque Example:
"opaque"
内容审核级别
Available options:
auto, low Example:
"auto"
jpeg 和 webp 格式的压缩级别(0-100%)
Required range:
0 <= x <= 100Example:
80
Response
图像生成成功。
生成的图片数组

