v2

latestOpenAPI 3.1.02026-07-26262762.2 KB
Models

Inpaint an image with FLUX.1 Fill [pro] using an input image and mask

Submits an image generation task with the FLUX.1 Fill [pro] model using an input image and mask. Mask can be applied to alpha channel or submitted as a separate image.

post/v1/flux-pro-1.0-fill

Request body

imagestring required

A Base64-encoded string representing the image you wish to modify. Can contain alpha mask if desired.

maskstring nullable

A Base64-encoded string representing a mask for the areas you want to modify in the image. The mask should be the same dimensions as the image and in black and white. Black areas (0%) indicate no modification, while white areas (100%) specify areas for inpainting. Optional if you provide an alpha mask in the original image. Validation: The endpoint verifies that the dimensions of the mask match the original image.

promptstring nullable

The description of the changes you want to make. This text guides the inpainting process, allowing you to specify features, styles, or modifications for the masked area.

stepsinteger nullable

Number of steps for the image generation process

prompt_upsamplingboolean nullable

Whether to perform upsampling on the prompt. If active, automatically modifies the prompt for more creative generation

seedinteger nullable

Optional seed for reproducibility

guidancenumber nullable

Guidance strength for the image generation process

output_format'jpeg' | 'png' | 'webp'
safety_toleranceinteger

Tolerance level for input and output moderation. Between 0 and 6, 0 being most strict, 6 being least strict.

webhook_urlstring uri nullable

URL to receive webhook notifications

webhook_secretstring nullable

Optional secret for webhook signature verification

Example request

{
  "prompt": "ein fantastisches bild",
  "steps": 50,
  "safety_tolerance": 2
}

Response

Successful Response

OR