Skip to content
EN

执行动作(所有的关联按钮动作UPSCALE; VARIATION; REROLL; ZOOM等)

方法: POST路径: /mj/submit/action

回调地址, 为空时使用全局notifyHook

请求参数

Header 参数

text
Authorization
string
可选
默认值:
Bearer {{YOUR_API_KEY}}

Body 参数 application/json

text
customId
string
动作标识
必需
示例:
MJ::JOB::upsample::2::3dbbd469-36af-4a0f-8f02-df6c579e7011
taskId
string
任务ID
必需
示例:
14001934816969359
notifyHook
string
可选
回调地址, 为空时使用全局notifyHook
示例
{
"customId"
:
"MJ::JOB::upsample::2::3dbbd469-36af-4a0f-8f02-df6c579e7011"
,
"taskId"
:
"14001934816969359"
,
"notifyHook"
:
"string"
}

请求示例代码

Shell

bash
curl --location --request POST '/mj/submit/action' \
--header 'Authorization: Bearer {{YOUR_API_KEY}}' \
--header 'Content-Type: application/json' \
--data-raw '{
    "customId": "MJ::JOB::upsample::2::3dbbd469-36af-4a0f-8f02-df6c579e7011",
    "taskId": "14001934816969359",
    "notifyHook": "string"
}'

返回响应

🟢 200 OK

内容类型: application/json

响应结构

text
code
integer
<int32>
必需
状态码: 1(提交成功), 21(已存在), 22(排队中), other(错误)
示例:
1
description
string
描述
必需
示例:
提交成功
properties
object
扩展字段
可选
result
string
任务ID
可选
示例:
1320098173412546

示例

json
{
    "code": 1,
    "description": "提交成功",
    "properties": {},
    "result": 1320098173412546
}

🟢 201 Created

🟠 401 Unauthorized

🟠 403 Forbidden

🟠 404 Not Found