Midjourney
Create a Midjourney modal task
Use POST /mj/submit/modal to submit Midjourney modal output from zoom or area redesign and continue the next image editing step in CometAPI.
POST
cURL
Overview
Submit additional input when an Action task returnsstatus: "MODAL". This is required for operations that need extra data, such as inpainting masks or custom zoom prompts.
When to use
| Operation | What to Submit |
|---|---|
| Vary (Region) / Inpaint | maskBase64 (PNG mask) + prompt |
| Custom Zoom | prompt (e.g., “your prompt —zoom 2”) |
Authorizations
Bearer token authentication. Use your CometAPI key.
Body
application/json
Task id from the parent task whose modal action you are continuing.
The button customId that opened the modal, such as MJ::Inpaint::1::xxxx::SOLO from the Vary (Region) button. Required.
Base64-encoded mask image for partial inpainting. White areas are repainted; black areas are preserved.
Text prompt describing the desired change for the selected region.