Overlay images
Try it interactively →POST /api/image-overlayOverlay one image on top of another at a chosen position. Supports alpha transparency, configurable blend mode and opacity.
Inputs
| Name | Type | Default | Description |
|---|---|---|---|
| image* | file | — | Background image bytes. |
| foreground* | file | — | Foreground image bytes. |
| gravity | enum (north | south | east | west | northeast | northwest | southeast | southwest | center) | "center" | Anchor for the foreground. |
| opacity | number (0…100) | 100 | Foreground opacity (percent). |
| scale | number (0…100) | 0 | Foreground scale relative to background's smaller side (0 = native). |
| offsetX | number (-8192…8192) | 0 | Horizontal offset in pixels. |
| offsetY | number (-8192…8192) | 0 | Vertical offset in pixels. |
| format | enum (png | jpeg | webp) | — | Output format. Defaults to the background's format. |
Response
Modes: binary, json. Cache: yes (24h TTL).