Chuyển đến nội dung chính
POST
/
mj
/
submit
/
blend
Blend (image -> image)
curl --request POST \
  --url https://api.cometapi.com/mj/submit/blend \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "base64Array": [
    "data:image/png;base64,xxx1",
    "data:image/png;base64,xxx2"
  ]
}
'
{
  "code": 123,
  "description": "<string>",
  "properties": {},
  "result": 123
}
Sử dụng endpoint này để blend 2 đến 5 image nguồn thành một bố cục Midjourney mới. Đây là một điểm vào trực tiếp và không yêu cầu tác vụ imagine trước đó.

Trước khi gọi

  • Chuẩn bị 2 đến 5 image nguồn
  • Giữ bài kiểm tra đầu tiên ở mức nhỏ và bỏ qua các tùy chọn định tuyến tài khoản bổ sung trừ khi bạn cần chúng
  • Lưu task id được trả về, vì quá trình blend vẫn là bất đồng bộ

Luồng tác vụ

1

Gửi tác vụ blend

Gửi các image nguồn qua endpoint blend và lưu task id được trả về.
2

Thăm dò tác vụ

Sử dụng Fetch Single Task cho đến khi tác vụ đạt trạng thái kết thúc.
3

Tiếp tục từ kết quả

Khi các nút hành động xuất hiện, sử dụng Action để upscale, variation hoặc thực hiện các bước tiếp theo khác.

Ủy quyền

Authorization
string
header
bắt buộc

Bearer token authentication. Use your CometAPI key.

Nội dung

application/json
base64Array
string[]
bắt buộc

Two or more base64-encoded images to blend. Each item should be a data URI such as data:image/png;base64,xxx.

dimensions
enum<string>

Output aspect ratio.

Tùy chọn có sẵn:
PORTRAIT,
SQUARE,
LANDSCAPE
notifyHook
string

Webhook URL to receive task status updates. Falls back to your account-level webhook if omitted.

state
string

Custom state string. Returned as-is in the task result and webhook callback for your own tracking.

botType
enum<string>

Bot type to use. MID_JOURNEY for Midjourney (default), NIJI_JOURNEY for Niji.

Tùy chọn có sẵn:
MID_JOURNEY,
NIJI_JOURNEY

Phản hồi

200 - application/json

Success

code
integer
bắt buộc

Status code

description
string
bắt buộc

Human-readable description message corresponding to the status code

properties
object
bắt buộc

Additional properties or metadata

result
integer
bắt buộc

Returned task ID