- 无界AI企业服务
- 无界AI企业智能客服
- 更新日志
- 公告
- API接入指南
- 作画指南
- AI专业版作画
- AI普通版作画
- AI视频生视频
- AI咒语解析
- 付费开通API
- AI化身&个性相机
- 提升作画效率
- 自定义镜像
- 用户账户
- LLM对话聊天
- OpenAI Image
- 实验室
图片创建
POST
https://gate.wujieai.net/wj-open/v1/ai/wj/images/generations
OpenAI Image
请求参数
Body 参数application/json
prompt
string <string>
提示词
示例值:
9qf86g
model
string <string>
必需
示例值:
iy5fgy
n
integer <int32>
可选
可选范围1-10,dall-e-3为固定值1
示例值:
629
output_compression
integer <int32>
可选
示例值:
45
quality
string <string>
可选
auto(默认值)将自动为给定模型选择 最佳质量。
gpt-image-1 支持high、medium、low三种质量。
dall-e-3 支持 hd 和 standard。
dall-e-2 仅支持 standard。
Validate[regexp: low|medium|high; ]
示例值:
9ax966
size
string <string>
可选
1024x1024
1536x1024
1024x1536
auto(默认)
256x256
512x512
1024x1024
dall-e-3 可选范围:
1024x1024
1792x1024
1024x1792
注意:不同尺寸消耗不同
Validate[regexp: 1024x1024|1536x1024|1024x1536; ]
示例值:
saquri
background
string <string>
可选
此参数仅适用于 gpt-image-1。可选值 transparent、opaque 或 auto(默认)之一。使用 auto 时,模型将自动确定图像的最佳背景。
示例值:
cqa0ya
moderation
string <string>
可选
示例值:
jgxvhg
output_format
string <string>
可选
示例值:
7bljoh
style
string <string>
可选
可选值:
示例值:
exj0hg
示例
{
"prompt": "qlrc0m",
"model": "ai9lhp",
"n": 194,
"output_compression": 598,
"quality": "ye0i2f",
"size": "gp4n4a",
"background": "3k3ndg",
"moderation": "i04ixz",
"output_format": "w6xxgq",
"style": "a3z4kv"
}
示例代码
Shell
JavaScript
Java
Swift
Go
PHP
Python
HTTP
C
C#
Objective-C
Ruby
OCaml
Dart
R
请求示例请求示例
Shell
JavaScript
Java
Swift
curl --location --request POST 'https://gate.wujieai.net/wj-open/v1/ai/wj/images/generations' \
--header 'Content-Type: application/json' \
--data-raw '{
"prompt": "qlrc0m",
"model": "ai9lhp",
"n": 194,
"output_compression": 598,
"quality": "ye0i2f",
"size": "gp4n4a",
"background": "3k3ndg",
"moderation": "i04ixz",
"output_format": "w6xxgq",
"style": "a3z4kv"
}'
返回响应
🟢200成功
*/*
Body
code
string <string>
响应code
示例值:
200
message
string <string>
失败信息
示例值:
success
data
object (OpenAiImageKeyVO_response)
可选
key
string <string>
image key
示例值:
3E46BF62A51256A96EEFB73079BD55E2
示例
{
"code": "200",
"message": "success",
"data": {
"key": "3E46BF62A51256A96EEFB73079BD55E2"
}
}
修改于 2025-06-19 08:48:06