Bria AI Edit & Auto Download

Autonomously executes Bria AI operations, polls the status, and downloads the generated image

Generative Fill

AI-generated

Summary

Generate a completed image via Bria AI's generative fill endpoint, polling for status and returning the result as binary image data with response metadata.

Inputs

  • imageUrl (required) — The URL of the image. Alternatively, you can pass a base64 encoded string.
  • instruction (required) — The text prompt, instruction, color, season, or style to apply.
  • mask (required) — The URL of the mask image (white=erase, black=keep).
  • version — Version of the generative fill model, default 2.
  • maxRetries — Maximum number of times to poll the status URL, default 30.
  • waitTime — Time to wait between polling attempts in milliseconds, default 3000.

Output shape

items with json and binary fields

Returns the final Bria AI response object as json and the generated image as PNG binary data under the 'data' key. Throws if generation does not complete within maxRetries.

Links

Discussion