Actions23
- Add Object by Text
- Blend Images
- Blur Background
- Colorize
- Crop out Foreground
- Enhance Image
- Erase (Mask-based)
- Erase Foreground
- Erase Object by Text
- Expand Image (Outpainting)
- Generate Structured Instruction
- Generative Fill
- Image Edit by Text (FIBO)
- Increase Resolution (Upscaling)
- Relight Image
- Remove Background
- Replace Background
- Replace Object by Text
- Reseason Image
- Restore Old Images
- Restyle Image
- Rewrite (Text in Image)
- Sketch to Image
Replace Background
AI-generatedSummary
Replace the background of an input image using a text prompt, with optional mode selection, poll for generation completion, and return the resulting image binary and final data.
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.
- mode — Control mode for the background replacement. Options: high_control (recommended), base, fast.
- maxRetries — Maximum number of times to poll the status URL.
- waitTime — Time to wait between polling attempts in milliseconds.
Output shape
Each input item produces one output item with json and binary fields.
The json field contains the final Bria AI response metadata. The binary field contains the generated image as a PNG binary buffer, retrieved via a pre-signed URL without authentication.
Examples
Example 1: Replace the background of a product photo with a 'golden hour studio lighting' prompt using high control mode.
Set imageUrl to the product image, instruction to 'golden hour studio lighting', mode to 'high_control'. The node polls for completion (default 30 retries, 3s wait) and returns the new image binary and response data.