$0.04
per request
Image → 1–6 images
up to 10 MB, 16 MP
POST /v1/images/variateImage
endpoint
Try it
Get an API token on your profile page (it needs a positive API units balance) and set it once per terminal session:Response
datahas one entry per image (n). Download each image from itsurl.- The
modeldecides whether the output is raster or vector. A vector model returns SVG files. - Image URLs are temporary: files are kept for about 24 hours, so download them. See Limits and sizes.
creditsis the number of API units charged for the request.- Pass
"response_format": "b64_json"to get the image bytes inline, or"multipart"for the lowest latency. See Image inputs and results.
Parameters
The input image must be PNG, JPG, WEBP, or SVG, under 10 MB, up to 16 MP, with sides between 256 and 4096 px. See Input images.
Examples
Upload a local file
Upload a local file
Several wide variations
Several wide variations
Set
size to another aspect ratio and n to get a few variations in one request. The response has one data entry per image.Reproducible variations as PNG
Reproducible variations as PNG
Pass
random_seed to make a request reproducible. image_format returns PNG instead of WebP.Related
Image to image
Change an image with a prompt and a strength value.
Pricing
Prices of every model and tool.