根据任务ID 查询任务状态
GET
/mj/task/1730621826053455/fetch请求参数
Header 参数
Authorization
string
可选
示例值:
Bearer {{YOUR_API_KEY}}
Body 参数application/json
prompt
string
必需
所需图像的文本描述。最大长度为 1000 个字符。
model
string
可选
用于图像生成的模型。
n
integer
可选
要生成的图像数。必须介于 1 和 10 之间。
quality
string
可选
将生成的图像的质量。hd
创建具有更精细细节和更高一致性的图像。此参数仅支持dall-e-3
.
response_format
string
可选
返回生成的图像的格式。必须是 或url之一b64_json。
style
string
可选
生成图像的大小。必须是256x256
、512x512
或1024x1024
for之一dall-e-2
。对于模型来说,必须是1024x1024
、1792x1024
、 或之一。1024x1792``dall-e-3
user
string
可选
生成图像的风格。必须是 或vivid
之一natural
。生动使模型倾向于生成超真实和戏剧性的图像。自然使模型生成更自然、不太真实的图像。此参数仅支持dall-e-3
.
size
string
可选
生成图像的大小。必须是256x256、512x512或 1024x1024之一。
示例
{
"prompt": "string",
"model": "string",
"n": 0,
"quality": "string",
"response_format": "string",
"style": "string",
"user": "string",
"size": "string"
}
示例代码
返回响应
成功(200)
HTTP 状态码: 200
内容格式: JSONapplication/json
数据结构
id
string
必需
action
string
必需
customId
string
必需
botType
string
必需
prompt
string
必需
promptEn
string
必需
description
string
必需
state
string
必需
submitTime
integer
必需
startTime
integer
必需
finishTime
integer
必需
imageUrl
string
必需
status
string
必需
progress
string
必需
failReason
string
必需
buttons
array [object {5}]
必需
customId
string
必需
emoji
string
必需
label
string
必需
type
integer
必需
style
integer
必需
maskBase64
string
必需
properties
object
必需
finalPrompt
string
必需
finalZhPrompt
string
必需
示例
{
"id": "1730621826053455",
"action": "IMAGINE",
"customId": "",
"botType": "",
"prompt": "pig --v 6.1",
"promptEn": "pig --v 6.1",
"description": "Submit success",
"state": "",
"submitTime": 1730621826053,
"startTime": 1730621828024,
"finishTime": 1730621855817,
"imageUrl": "https://cdnmjp.oneabc.org/attachments/1300842274347028520/1302547211321741343/kennedyhernandez46715_74108_pig_3785da15-4f70-4034-9128-f3ff1ac634fa.png?ex=6728831f&is=6727319f&hm=f6d701914d608e4da9298d2290b3616317264a70635fbf08a37ca6c1bb671b50&",
"status": "SUCCESS",
"progress": "100%",
"failReason": "",
"buttons": [
{
"customId": "MJ::JOB::upsample::1::3785da15-4f70-4034-9128-f3ff1ac634fa",
"emoji": "",
"label": "U1",
"type": 2,
"style": 2
},
{
"customId": "MJ::JOB::upsample::2::3785da15-4f70-4034-9128-f3ff1ac634fa",
"emoji": "",
"label": "U2",
"type": 2,
"style": 2
},
{
"customId": "MJ::JOB::upsample::3::3785da15-4f70-4034-9128-f3ff1ac634fa",
"emoji": "",
"label": "U3",
"type": 2,
"style": 2
},
{
"customId": "MJ::JOB::upsample::4::3785da15-4f70-4034-9128-f3ff1ac634fa",
"emoji": "",
"label": "U4",
"type": 2,
"style": 2
},
{
"customId": "MJ::JOB::reroll::0::3785da15-4f70-4034-9128-f3ff1ac634fa::SOLO",
"emoji": "🔄",
"label": "",
"type": 2,
"style": 2
},
{
"customId": "MJ::JOB::variation::1::3785da15-4f70-4034-9128-f3ff1ac634fa",
"emoji": "",
"label": "V1",
"type": 2,
"style": 2
},
{
"customId": "MJ::JOB::variation::2::3785da15-4f70-4034-9128-f3ff1ac634fa",
"emoji": "",
"label": "V2",
"type": 2,
"style": 2
},
{
"customId": "MJ::JOB::variation::3::3785da15-4f70-4034-9128-f3ff1ac634fa",
"emoji": "",
"label": "V3",
"type": 2,
"style": 2
},
{
"customId": "MJ::JOB::variation::4::3785da15-4f70-4034-9128-f3ff1ac634fa",
"emoji": "",
"label": "V4",
"type": 2,
"style": 2
}
],
"maskBase64": "",
"properties": {
"finalPrompt": "pig --v 6.1",
"finalZhPrompt": ""
}
}
最后修改时间: 20 天前