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
Expand Image (Outpainting)
AI-generatedSummary
Expands the provided image to the specified aspect ratio via outpainting, polls the generation status, and returns the resulting image as binary data.
Inputs
- imageUrl (required) — The URL of the image. Alternatively, you can pass a base64 encoded string.
- aspect_ratio — Target aspect ratio for outpainting (e.g. 16:9, 1:1, 4:3)
- maxRetries — Maximum number of times to poll the status URL
- waitTime — Time to wait between polling attempts in milliseconds
Output shape
Returns an object with json containing the full API response data and binary containing the downloaded image as image/png. If the operation does not complete within maxRetries, an error is thrown.
For non-structured_instruction operations (including expand_image), the binary data key 'data' holds the image; the json key holds the final response.