Midjourney Inpaint
Image
Midjourney Inpaint
POST
Midjourney Inpaint
Use the Midjourney Inpaint feature to repaint a specified region of a generated image. Supports specifying the repaint region via polygon areas or black-and-white mask images. This endpoint uses async processing; the client needs to query the final result using the task_id.
Request Headers
Enum:
application/jsonBearer authentication format: Bearer {{API Key}}.
Request Body
Image number, used to specify which image to inpaint.Range: 0~3
The unique identifier of the original image generation task.
Inpaint region prompt, used to describe the desired content for the repainted region.Length limit: 1-8192 characters.
Repaint region configuration, replaces the area parameter, and supports multi-region inpainting. Choose either areas or url.
Single polygon region configuration (use either this or the mask parameter).
Response
The task_id of the async task. Use the task_id to call the Get Async Task Result API to retrieve the generated result.