はじめに
重要な規約
- タスク送信時には、ヘッダー
Authorization: Bearer hk-あなたのキーに置き換えまたはMj-Api-Secret: hk-あなたのキーに置き換えを含める必要があります - Midjourney APIアドレス
https://api.openai-hk.com Imagineタスクの送信をDEMOとして クイック接続を見る
タスク送信
モード接続ポイント
- ハイブリッドモード(削除予定)
https://api.openai-hk.com - fastモード
https://api.openai-hk.com/fast - relaxモード
https://api.openai-hk.com/relax - 各モードの価格は異なります。コンソール->キー購入で価格を確認してください
アクション実行
APIアドレス:/mj/submit/action
リクエスト方式:POST
リクエストデータ型:application/json
レスポンスデータ型:*/*
API説明:
リクエスト例:
{
"customId": "MJ::JOB::upsample::2::3dbbd469-36af-4a0f-8f02-df6c579e7011",
"notifyHook": "",
"state": "",
"taskId": "14001934816969359"
}{
"customId": "MJ::JOB::upsample::2::3dbbd469-36af-4a0f-8f02-df6c579e7011",
"notifyHook": "",
"state": "",
"taskId": "14001934816969359"
}リクエストパラメータ:
| パラメータ名 | 説明 | リクエスト型 | 必須 | データ型 | schema |
|---|---|---|---|---|---|
| actionDTO | actionDTO | body | true | アクション実行パラメータ | アクション実行パラメータ |
| customId | アクション識別子 | true | string | ||
| notifyHook | コールバックアドレス、空の場合はグローバルnotifyHookを使用 | false | string | ||
| state | カスタムパラメータ | false | string | ||
| taskId | タスクID | true | string |
レスポンスステータス:
| ステータスコード | 説明 | schema |
|---|---|---|
| 200 | OK | 送信結果 |
| 201 | Created | |
| 401 | Unauthorized | |
| 403 | Forbidden | |
| 404 | Not Found |
レスポンスパラメータ:
| パラメータ名 | 説明 | 型 | schema |
|---|---|---|---|
| code | ステータスコード: 1(送信成功), 22(待機中), other(エラー) | integer(int32) | integer(int32) |
| description | 説明 | string | |
| properties | 拡張フィールド | object | |
| result | タスクID | string |
レスポンス例:
{
"code": 1,
"description": "提交成功",
"properties": {},
"result": 1320098173412546
}{
"code": 1,
"description": "提交成功",
"properties": {},
"result": 1320098173412546
}Blendタスクの送信
APIアドレス:/mj/submit/blend
リクエスト方式:POST
リクエストデータ型:application/json
レスポンスデータ型:*/*
API説明:
リクエスト例:
{
"base64Array": ["data:image/png;base64,xxx1", "data:image/png;base64,xxx2"],
"dimensions": "SQUARE",
"instanceId": "",
"modes": [],
"notifyHook": "",
"remix": true,
"state": ""
}{
"base64Array": ["data:image/png;base64,xxx1", "data:image/png;base64,xxx2"],
"dimensions": "SQUARE",
"instanceId": "",
"modes": [],
"notifyHook": "",
"remix": true,
"state": ""
}リクエストパラメータ:
| パラメータ名 | 説明 | リクエスト型 | 必須 | データ型 | schema |
|---|---|---|---|---|---|
| blendDTO | blendDTO | body | true | Blend送信パラメータ | Blend送信パラメータ |
| base64Array | 画像base64配列 | true | array | string | |
| dimensions | 比率: PORTRAIT(2:3); SQUARE(1:1); LANDSCAPE(3:2),使用可能値:PORTRAIT,SQUARE,LANDSCAPE | false | string | ||
| instanceId | アカウントインスタンスID、指定アカウントでタスク実行 | false | string | ||
| modes | アカウントモード、アカウントを絞り込んでタスク実行 | false | array | string | |
| notifyHook | コールバックアドレス、空の場合はグローバルnotifyHookを使用 | false | string | ||
| remix | アカウントremix、アカウントを絞り込んでタスク実行 | false | boolean | ||
| state | カスタムパラメータ | false | string |
レスポンスステータス:
| ステータスコード | 説明 | schema |
|---|---|---|
| 200 | OK | 送信結果 |
| 201 | Created | |
| 401 | Unauthorized | |
| 403 | Forbidden | |
| 404 | Not Found |
レスポンスパラメータ:
| パラメータ名 | 説明 | 型 | schema |
|---|---|---|---|
| code | ステータスコード: 1(送信成功), 22(待機中), other(エラー) | integer(int32) | integer(int32) |
| description | 説明 | string | |
| properties | 拡張フィールド | object | |
| result | タスクID | string |
レスポンス例:
{
"code": 1,
"description": "提交成功",
"properties": {},
"result": 1320098173412546
}{
"code": 1,
"description": "提交成功",
"properties": {},
"result": 1320098173412546
}画像からテキスト生成タスクの送信
APIアドレス:/mj/submit/describe
リクエスト方式:POST
リクエストデータ型:application/json
レスポンスデータ型:*/*
API説明:
リクエスト例:
{
"base64": "data:image/png;base64,xxx",
"instanceId": "",
"modes": [],
"notifyHook": "",
"remix": true,
"state": ""
}{
"base64": "data:image/png;base64,xxx",
"instanceId": "",
"modes": [],
"notifyHook": "",
"remix": true,
"state": ""
}リクエストパラメータ:
| パラメータ名 | 説明 | リクエスト型 | 必須 | データ型 | schema |
|---|---|---|---|---|---|
| describeDTO | describeDTO | body | true | Describe送信パラメータ | Describe送信パラメータ |
| base64 | 画像base64 | true | string | ||
| instanceId | アカウントインスタンスID、指定アカウントでタスク実行 | false | string | ||
| modes | アカウントモード、アカウントを絞り込んでタスク実行 | false | array | string | |
| notifyHook | コールバックアドレス、空の場合はグローバルnotifyHookを使用 | false | string | ||
| remix | アカウントremix、アカウントを絞り込んでタスク実行 | false | boolean | ||
| state | カスタムパラメータ | false | string |
レスポンスステータス:
| ステータスコード | 説明 | schema |
|---|---|---|
| 200 | OK | 送信結果 |
| 201 | Created | |
| 401 | Unauthorized | |
| 403 | Forbidden | |
| 404 | Not Found |
レスポンスパラメータ:
| パラメータ名 | 説明 | 型 | schema |
|---|---|---|---|
| code | ステータスコード: 1(送信成功), 22(待機中), other(エラー) | integer(int32) | integer(int32) |
| description | 説明 | string | |
| properties | 拡張フィールド | object | |
| result | タスクID | string |
レスポンス例:
{
"code": 1,
"description": "提交成功",
"properties": {},
"result": 1320098173412546
}{
"code": 1,
"description": "提交成功",
"properties": {},
"result": 1320098173412546
}Imagineタスクの送信
APIアドレス:/mj/submit/imagine
リクエスト方式:POST
リクエストデータ型:application/json
レスポンスデータ型:*/*
API説明:
リクエスト例:
{
"base64Array": [],
"instanceId": "",
"modes": [],
"notifyHook": "",
"prompt": "Cat",
"remix": true,
"state": ""
}{
"base64Array": [],
"instanceId": "",
"modes": [],
"notifyHook": "",
"prompt": "Cat",
"remix": true,
"state": ""
}リクエストパラメータ:
| パラメータ名 | 説明 | リクエスト型 | 必須 | データ型 | schema |
|---|---|---|---|---|---|
| imagineDTO | imagineDTO | body | true | Imagine送信パラメータ | Imagine送信パラメータ |
| base64Array | ベース画像base64配列 | false | array | string | |
| instanceId | アカウントインスタンスID、指定アカウントでタスク実行 | false | string | ||
| modes | アカウントモード、アカウントを絞り込んでタスク実行 | false | array | string | |
| notifyHook | コールバックアドレス、空の場合はグローバルnotifyHookを使用 | false | string | ||
| prompt | プロンプト | true | string | ||
| remix | アカウントremix、アカウントを絞り込んでタスク実行 | false | boolean | ||
| state | カスタムパラメータ | false | string |
レスポンスステータス:
| ステータスコード | 説明 | schema |
|---|---|---|
| 200 | OK | 送信結果 |
| 201 | Created | |
| 401 | Unauthorized | |
| 403 | Forbidden | |
| 404 | Not Found |
レスポンスパラメータ:
| パラメータ名 | 説明 | 型 | schema |
|---|---|---|---|
| code | ステータスコード: 1(送信成功), 22(待機中), other(エラー) | integer(int32) | integer(int32) |
| description | 説明 | string | |
| properties | 拡張フィールド | object | |
| result | タスクID | string |
レスポンス例:
{
"code": 1,
"description": "提交成功",
"properties": {},
"result": 1320098173412546
}{
"code": 1,
"description": "提交成功",
"properties": {},
"result": 1320098173412546
}Modalの送信
APIアドレス:/mj/submit/modal
リクエスト方式:POST
リクエストデータ型:application/json
レスポンスデータ型:*/*
API説明:
リクエスト例:
{
"maskBase64": "",
"prompt": "",
"taskId": "14001934816969359"
}{
"maskBase64": "",
"prompt": "",
"taskId": "14001934816969359"
}リクエストパラメータ:
| パラメータ名 | 説明 | リクエスト型 | 必須 | データ型 | schema |
|---|---|---|---|---|---|
| modalDTO | modalDTO | body | true | Modal送信パラメータ | Modal送信パラメータ |
| maskBase64 | 部分再描画のマスクbase64 | false | string | ||
| prompt | プロンプト | false | string | ||
| taskId | タスクID | true | string |
レスポンスステータス:
| ステータスコード | 説明 | schema |
|---|---|---|
| 200 | OK | 送信結果 |
| 201 | Created | |
| 401 | Unauthorized | |
| 403 | Forbidden | |
| 404 | Not Found |
レスポンスパラメータ:
| パラメータ名 | 説明 | 型 | schema |
|---|---|---|---|
| code | ステータスコード: 1(送信成功), 22(待機中), other(エラー) | integer(int32) | integer(int32) |
| description | 説明 | string | |
| properties | 拡張フィールド | object | |
| result | タスクID | string |
レスポンス例:
{
"code": 1,
"description": "提交成功",
"properties": {},
"result": 1320098173412546
}{
"code": 1,
"description": "提交成功",
"properties": {},
"result": 1320098173412546
}swap_face 顔交換タスクの送信
APIアドレス:/mj/insight-face/swap
リクエスト方式:POST
リクエストデータ型:application/json
レスポンスデータ型:*/*
API説明:
リクエスト例:
{
"sourceBase64": "data:image/png;base64,xxx1",
"targetBase64": "data:image/png;base64,xxx2",
"accountFilter": {
"instanceId": ""
},
"notifyHook": "",
"state": ""
}{
"sourceBase64": "data:image/png;base64,xxx1",
"targetBase64": "data:image/png;base64,xxx2",
"accountFilter": {
"instanceId": ""
},
"notifyHook": "",
"state": ""
}リクエストパラメータ:
リクエストパラメータ:
| パラメータ名 | 説明 | リクエスト型 | 必須 | データ型 | schema |
|---|---|---|---|---|---|
| swapFaceDTO | swapFaceDTO | body | true | SwapFace送信パラメータ | SwapFace送信パラメータ |
| sourceBase64 | 顔ソース画像base64 | true | string | ||
| targetBase64 | ターゲット画像base64 | true | string | ||
| accountFilter | アカウントを絞り込んでタスク実行、不要な場合はnullまたはこのパラメータを削除 | false | Filter | Filter | |
| instanceId | アカウントインスタンスID | false | string | ||
| notifyHook | コールバックアドレス、空の場合はグローバルnotifyHookを使用 | false | string | ||
| state | カスタムパラメータ | false | string |
レスポンスステータス:
| ステータスコード | 説明 | schema |
|---|---|---|
| 200 | OK | Message«string» |
| 201 | Created | |
| 401 | Unauthorized | |
| 403 | Forbidden | |
| 404 | Not Found |
レスポンスパラメータ:
| パラメータ名 | 説明 | 型 | schema |
|---|---|---|---|
| code | integer(int32) | integer(int32) | |
| description | string | ||
| result | string |
レスポンス例:
{
"code": 0,
"description": "",
"result": ""
}{
"code": 0,
"description": "",
"result": ""
}Shortenタスクの送信
APIアドレス:/mj/submit/shorten
リクエスト方式:POST
リクエストデータ型:application/json
レスポンスデータ型:*/*
API説明:
リクエスト例:
{
"instanceId": "",
"modes": [],
"notifyHook": "",
"prompt": "Cat",
"remix": true,
"state": ""
}{
"instanceId": "",
"modes": [],
"notifyHook": "",
"prompt": "Cat",
"remix": true,
"state": ""
}リクエストパラメータ:
| パラメータ名 | 説明 | リクエスト型 | 必須 | データ型 | schema |
|---|---|---|---|---|---|
| shortenDTO | shortenDTO | body | true | Shorten送信パラメータ | Shorten送信パラメータ |
| instanceId | アカウントインスタンスID、指定アカウントでタスク実行 | false | string | ||
| modes | アカウントモード、アカウントを絞り込んでタスク実行 | false | array | string | |
| notifyHook | コールバックアドレス、空の場合はグローバルnotifyHookを使用 | false | string | ||
| prompt | プロンプト | true | string | ||
| remix | アカウントremix、アカウントを絞り込んでタスク実行 | false | boolean | ||
| state | カスタムパラメータ | false | string |
レスポンスステータス:
| ステータスコード | 説明 | schema |
|---|---|---|
| 200 | OK | 送信結果 |
| 201 | Created | |
| 401 | Unauthorized | |
| 403 | Forbidden | |
| 404 | Not Found |
レスポンスパラメータ:
| パラメータ名 | 説明 | 型 | schema |
|---|---|---|---|
| code | ステータスコード: 1(送信成功), 22(待機中), other(エラー) | integer(int32) | integer(int32) |
| description | 説明 | string | |
| properties | 拡張フィールド | object | |
| result | タスクID | string |
レスポンス例:
{
"code": 1,
"description": "提交成功",
"properties": {},
"result": 1320098173412546
}{
"code": 1,
"description": "提交成功",
"properties": {},
"result": 1320098173412546
}動画タスクの作成
APIアドレス:/mj/submit/video
リクエスト方式:POST
リクエストデータ型:application/json
リクエスト例:
imageはbase64またはurlをサポートvideoTypeデフォルトはvid_1.1_i2v_480価格は画像生成価格の7.5倍- 高画質動画は
videoType=vid_1.1_i2v_720が必要、価格は画像生成価格の26倍
{
"prompt": "飞来一只蜜蜂",
"motion": "low",
"image": "https://cdn.discordapp.com/attachments/1372468820912115716/1388566717961338880/hyper_realistic_3d_rendering_pink_tulip_style_686021570d5ec4451c1c120a.jpg?ex=68617307&is=68602187&hm=f939f10d79de24e3ed0f2c4dc1453c902ee6b383d13d9a1787eacfccfadb9488&",
"notifyHook": "https://sse.open-hk.com/openai/mjapi/9-8/",
"videoType": "vid_1.1_i2v_480"
}{
"prompt": "飞来一只蜜蜂",
"motion": "low",
"image": "https://cdn.discordapp.com/attachments/1372468820912115716/1388566717961338880/hyper_realistic_3d_rendering_pink_tulip_style_686021570d5ec4451c1c120a.jpg?ex=68617307&is=68602187&hm=f939f10d79de24e3ed0f2c4dc1453c902ee6b383d13d9a1787eacfccfadb9488&",
"notifyHook": "https://sse.open-hk.com/openai/mjapi/9-8/",
"videoType": "vid_1.1_i2v_480"
}レスポンス本文:
{
"code": 1,
"description": "Submit Success",
"result": "1751352955547075"
}{
"code": 1,
"description": "Submit Success",
"result": "1751352955547075"
}resultで結果を取得1751352955547075- get
https://api.openai-hk.com/mj/task/1751275590720680/fetch
タスク結果の返却:
- 結果は
videoUrlsに4つの動画リンクを含む
{
"id": "1751275590720680",
"action": "VIDEO",
"customId": "",
"botType": "",
"prompt": "缠斗",
"promptEn": "",
"description": "Submit Success",
"state": "",
"mode": "",
"proxy": "",
"submitTime": 1751275590720,
"startTime": 1751275590720,
"finishTime": 1751275670864,
"imageUrl": "https://abc.om/upload_1751275589663574690.jpg",
"imageUrls": null,
"imageHeight": 624,
"imageWidth": 624,
"videoUrl": "",
"videoUrls": [
{
"url": "https://cdn.discordapp.com/video/5938067e-b820-4938-b3ad-69d81778cbc4/0_0.mp4"
},
{
"url": "https://cdn.discordapp.com/video/5938067e-b820-4938-b3ad-69d81778cbc4/0_1.mp4"
},
{
"url": "https://cdn.discordapp.com/video/5938067e-b820-4938-b3ad-69d81778cbc4/0_2.mp4"
},
{
"url": "https://cdn.discordapp.com/video/5938067e-b820-4938-b3ad-69d81778cbc4/0_3.mp4"
}
],
"status": "SUCCESS",
"progress": "100%",
"failReason": "",
"buttons": [],
"maskBase64": "",
"properties": {
"notifyHook": "",
"flags": 0,
"messageId": "",
"messageHash": "5938067e-b820-4938-b3ad-69d81778cbc4",
"nonce": "",
"customId": "",
"finalPrompt": "https://cdn.discordapp.com/upload_1751275589663574690.jpg 缠斗 --ar 1:1 --v 7 --stylize 100 --relax",
"progressMessageId": "",
"messageContent": "",
"discordInstanceId": "1372468820912115716",
"discordChannelId": "1372468820912115716"
}
}{
"id": "1751275590720680",
"action": "VIDEO",
"customId": "",
"botType": "",
"prompt": "缠斗",
"promptEn": "",
"description": "Submit Success",
"state": "",
"mode": "",
"proxy": "",
"submitTime": 1751275590720,
"startTime": 1751275590720,
"finishTime": 1751275670864,
"imageUrl": "https://abc.om/upload_1751275589663574690.jpg",
"imageUrls": null,
"imageHeight": 624,
"imageWidth": 624,
"videoUrl": "",
"videoUrls": [
{
"url": "https://cdn.discordapp.com/video/5938067e-b820-4938-b3ad-69d81778cbc4/0_0.mp4"
},
{
"url": "https://cdn.discordapp.com/video/5938067e-b820-4938-b3ad-69d81778cbc4/0_1.mp4"
},
{
"url": "https://cdn.discordapp.com/video/5938067e-b820-4938-b3ad-69d81778cbc4/0_2.mp4"
},
{
"url": "https://cdn.discordapp.com/video/5938067e-b820-4938-b3ad-69d81778cbc4/0_3.mp4"
}
],
"status": "SUCCESS",
"progress": "100%",
"failReason": "",
"buttons": [],
"maskBase64": "",
"properties": {
"notifyHook": "",
"flags": 0,
"messageId": "",
"messageHash": "5938067e-b820-4938-b3ad-69d81778cbc4",
"nonce": "",
"customId": "",
"finalPrompt": "https://cdn.discordapp.com/upload_1751275589663574690.jpg 缠斗 --ar 1:1 --v 7 --stylize 100 --relax",
"progressMessageId": "",
"messageContent": "",
"discordInstanceId": "1372468820912115716",
"discordChannelId": "1372468820912115716"
}
}video
サーバー側を設定
トリガーエントリ

プロンプトを入力

結果として4つの動画を取得

画像編集タスクの作成
APIアドレス:/mj/submit/edits
リクエスト方式:POST
リクエストデータ型:application/json
リクエスト例:
imageはbase64またはurlをサポート
{
"prompt": "改为白色背景",
"image": "https://cdn.discordapp.com/attachments/1372468820912115716/1388566717961338880/hyper_realistic_3d_rendering_pink_tulip_style_686021570d5ec4451c1c120a.jpg?ex=68617307&is=68602187&hm=f939f10d79de24e3ed0f2c4dc1453c902ee6b383d13d9a1787eacfccfadb9488&",
"notifyHook": "https://yourback.com/",
"state": "abc"
}{
"prompt": "改为白色背景",
"image": "https://cdn.discordapp.com/attachments/1372468820912115716/1388566717961338880/hyper_realistic_3d_rendering_pink_tulip_style_686021570d5ec4451c1c120a.jpg?ex=68617307&is=68602187&hm=f939f10d79de24e3ed0f2c4dc1453c902ee6b383d13d9a1787eacfccfadb9488&",
"notifyHook": "https://yourback.com/",
"state": "abc"
}レスポンス本文:
{
"code": 1,
"description": "Submit Success",
"result": "1751342042863641"
}{
"code": 1,
"description": "Submit Success",
"result": "1751342042863641"
}resultで結果を取得1751342042863641- get
https://api.openai-hk.com/mj/task/1751342042863641/fetch
タスク結果の返却:
- 結果は
imageUrlsに4つの画像リンクを含む
{
"id": "1751342042863641",
"action": "EDITS",
"customId": "",
"botType": "",
"prompt": "Change to a white background.",
"promptEn": "Change to a white background.",
"description": "Submit Success",
"state": "9",
"submitTime": 1751342042863,
"startTime": 1751342044141,
"finishTime": 1751342065872,
"imageUrl": "https://mjimg.open-hk.com/attachments/1372468820912115716/1389454090576072754/change_white_background_1651da63-85c6-45c7-9679-f42381c73c78.png?ex=6864ad76&is=68635bf6&hm=88ef2edb071faa5821250879489a3ea348b4f5504a73614ff30a81f05b1dee44&",
"status": "SUCCESS",
"progress": "100%",
"failReason": "",
"buttons": [],
"imageUrls": [
{
"url": "https://cdn.midjourney.com/1651da63-85c6-45c7-9679-f42381c73c78/0_0.png"
},
{
"url": "https://cdn.midjourney.com/1651da63-85c6-45c7-9679-f42381c73c78/0_1.png"
},
{
"url": "https://cdn.midjourney.com/1651da63-85c6-45c7-9679-f42381c73c78/0_2.png"
},
{
"url": "https://cdn.midjourney.com/1651da63-85c6-45c7-9679-f42381c73c78/0_3.png"
}
],
"videoUrls": null,
"videoUrl": "",
"maskBase64": "",
"properties": {
"finalPrompt": "Change to a white background. --ar 1:1 --v 7 --stylize 100 --fast --dref https://mjimg.open-hk.com/upload_1751342040607222256.png--fast",
"finalZhPrompt": ""
}
}{
"id": "1751342042863641",
"action": "EDITS",
"customId": "",
"botType": "",
"prompt": "Change to a white background.",
"promptEn": "Change to a white background.",
"description": "Submit Success",
"state": "9",
"submitTime": 1751342042863,
"startTime": 1751342044141,
"finishTime": 1751342065872,
"imageUrl": "https://mjimg.open-hk.com/attachments/1372468820912115716/1389454090576072754/change_white_background_1651da63-85c6-45c7-9679-f42381c73c78.png?ex=6864ad76&is=68635bf6&hm=88ef2edb071faa5821250879489a3ea348b4f5504a73614ff30a81f05b1dee44&",
"status": "SUCCESS",
"progress": "100%",
"failReason": "",
"buttons": [],
"imageUrls": [
{
"url": "https://cdn.midjourney.com/1651da63-85c6-45c7-9679-f42381c73c78/0_0.png"
},
{
"url": "https://cdn.midjourney.com/1651da63-85c6-45c7-9679-f42381c73c78/0_1.png"
},
{
"url": "https://cdn.midjourney.com/1651da63-85c6-45c7-9679-f42381c73c78/0_2.png"
},
{
"url": "https://cdn.midjourney.com/1651da63-85c6-45c7-9679-f42381c73c78/0_3.png"
}
],
"videoUrls": null,
"videoUrl": "",
"maskBase64": "",
"properties": {
"finalPrompt": "Change to a white background. --ar 1:1 --v 7 --stylize 100 --fast --dref https://mjimg.open-hk.com/upload_1751342040607222256.png--fast",
"finalZhPrompt": ""
}
}タスククエリ
指定IDでタスクを取得
APIアドレス:/mj/task/{id}/fetch
リクエスト方式:GET
リクエストデータ型:application/x-www-form-urlencoded
レスポンスデータ型:*/*
API説明:
リクエストパラメータ:
| パラメータ名 | 説明 | リクエスト型 | 必須 | データ型 | schema |
|---|---|---|---|---|---|
| id | タスクID | path | false | string |
レスポンスステータス:
| ステータスコード | 説明 | schema |
|---|---|---|
| 200 | OK | タスク |
| 401 | Unauthorized | |
| 403 | Forbidden | |
| 404 | Not Found |
レスポンスパラメータ:
| パラメータ名 | 説明 | 型 | schema |
|---|---|---|---|
| action | タスクタイプ,使用可能値:IMAGINE,UPSCALE,VARIATION,ZOOM,PAN,DESCRIBE,BLEND,SHORTEN | string | |
| buttons | array | 実行可能ボタン | |
| customId | アクション識別子 | string | |
| emoji | アイコン | string | |
| label | テキスト | string | |
| style | スタイル: 2(Primary)、3(Green) | integer(int32) | |
| type | タイプ、システム内部使用 | integer(int32) | |
| description | タスク説明 | string | |
| failReason | 失敗理由 | string | |
| finishTime | 終了時間 | integer(int64) | integer(int64) |
| id | ID | string | |
| imageUrl | 画像url | string | |
| progress | タスク進行状況 | string | |
| prompt | プロンプト | string | |
| promptEn | プロンプト-英語 | string | |
| properties | object | ||
| startTime | 実行開始時間 | integer(int64) | integer(int64) |
| state | カスタムパラメータ | string | |
| status | タスクステータス,使用可能値:NOT_START,SUBMITTED,MODAL,IN_PROGRESS,FAILURE,SUCCESS | string | |
| submitTime | 送信時間 | integer(int64) | integer(int64) |
レスポンス例:
{
"action": "",
"buttons": [
{
"customId": "",
"emoji": "",
"label": "",
"style": 0,
"type": 0
}
],
"description": "",
"failReason": "",
"finishTime": 0,
"id": "",
"imageUrl": "",
"progress": "",
"prompt": "",
"promptEn": "",
"properties": {},
"startTime": 0,
"state": "",
"status": "",
"submitTime": 0
}{
"action": "",
"buttons": [
{
"customId": "",
"emoji": "",
"label": "",
"style": 0,
"type": 0
}
],
"description": "",
"failReason": "",
"finishTime": 0,
"id": "",
"imageUrl": "",
"progress": "",
"prompt": "",
"promptEn": "",
"properties": {},
"startTime": 0,
"state": "",
"status": "",
"submitTime": 0
}タスク画像のseedを取得
APIアドレス:/mj/task/{id}/image-seed
リクエスト方式:GET
リクエストデータ型:application/x-www-form-urlencoded
レスポンスデータ型:*/*
API説明:
リクエストパラメータ:
| パラメータ名 | 説明 | リクエスト型 | 必須 | データ型 | schema |
|---|---|---|---|---|---|
| id | タスクID | path | false | string |
レスポンスステータス:
| ステータスコード | 説明 | schema |
|---|---|---|
| 200 | OK | Message«string» |
| 401 | Unauthorized | |
| 403 | Forbidden | |
| 404 | Not Found |
レスポンスパラメータ:
| パラメータ名 | 説明 | 型 | schema |
|---|---|---|---|
| code | integer(int32) | integer(int32) | |
| description | string | ||
| result | string |
レスポンス例:
{
"code": 0,
"description": "",
"result": ""
}{
"code": 0,
"description": "",
"result": ""
}IDリストによるタスククエリ
APIアドレス:/mj/task/list-by-condition
リクエスト方式:POST
リクエストデータ型:application/json
レスポンスデータ型:*/*
API説明:
リクエスト例:
{
"ids": []
}{
"ids": []
}リクエストパラメータ:
| パラメータ名 | 説明 | リクエスト型 | 必須 | データ型 | schema |
|---|---|---|---|---|---|
| conditionDTO | conditionDTO | body | true | タスククエリパラメータ | タスククエリパラメータ |
| ids | タスクID配列 | false | array | string |
レスポンスステータス:
| ステータスコード | 説明 | schema |
|---|---|---|
| 200 | OK | タスク |
| 201 | Created | |
| 401 | Unauthorized | |
| 403 | Forbidden | |
| 404 | Not Found |
レスポンスパラメータ:
| パラメータ名 | 説明 | 型 | schema |
|---|---|---|---|
| action | タスクタイプ,使用可能値:IMAGINE,UPSCALE,VARIATION,ZOOM,PAN,DESCRIBE,BLEND,SHORTEN | string | |
| buttons | array | 実行可能ボタン | |
| customId | アクション識別子 | string | |
| emoji | アイコン | string | |
| label | テキスト | string | |
| style | スタイル: 2(Primary)、3(Green) | integer(int32) | |
| type | タイプ、システム内部使用 | integer(int32) | |
| description | タスク説明 | string | |
| failReason | 失敗理由 | string | |
| finishTime | 終了時間 | integer(int64) | integer(int64) |
| id | ID | string | |
| imageUrl | 画像url | string | |
| progress | タスク進行状況 | string | |
| prompt | プロンプト | string | |
| promptEn | プロンプト-英語 | string | |
| properties | object | ||
| startTime | 実行開始時間 | integer(int64) | integer(int64) |
| state | カスタムパラメータ | string | |
| status | タスクステータス,使用可能値:NOT_START,SUBMITTED,MODAL,IN_PROGRESS,FAILURE,SUCCESS | string | |
| submitTime | 送信時間 | integer(int64) | integer(int64) |
レスポンス例:
[
{
"action": "",
"buttons": [
{
"customId": "",
"emoji": "",
"label": "",
"style": 0,
"type": 0
}
],
"description": "",
"failReason": "",
"finishTime": 0,
"id": "",
"imageUrl": "",
"progress": "",
"prompt": "",
"promptEn": "",
"properties": {},
"startTime": 0,
"state": "",
"status": "",
"submitTime": 0
}
][
{
"action": "",
"buttons": [
{
"customId": "",
"emoji": "",
"label": "",
"style": 0,
"type": 0
}
],
"description": "",
"failReason": "",
"finishTime": 0,
"id": "",
"imageUrl": "",
"progress": "",
"prompt": "",
"promptEn": "",
"properties": {},
"startTime": 0,
"state": "",
"status": "",
"submitTime": 0
}
]
OpenAi-HK