ImageSuite API

REST API documentation

Call any of ImageSuite's AI image processing endpoints from your own apps. One Pro subscription ($9/mo) includes both web access and API access.

Authentication

Get your API key from the dashboard. Pass it as a Bearer token in every request:

Authorization: Bearer imgsk_xxxxxxxxxxxxxxxxxxxxx

Keys start with imgsk_ followed by 32 random characters.

Quick start

A complete example — generate an image from a prompt:

curl -X POST https://imagesuite.io/api/ai/generate \
  -H "Authorization: Bearer YOUR_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "prompt": "minimalist mountain landscape at sunset",
    "aspectRatio": "16:9",
    "numOutputs": 1
  }'

Endpoints

POST/api/upscale

AI upscale via Real-ESRGAN. Accepts 2×, 4×, or 8× scale.

Request body
{
  "imageDataUrl": "data:image/png;base64,...",
  "scale": 4,
  "faceEnhance": false
}
Response (200)
{ "url": "https://replicate.delivery/.../output.png" }
POST/api/background-removal

Remove background using BiRefNet. Returns transparent PNG.

Request body
{ "imageDataUrl": "data:image/png;base64,..." }
Response (200)
{ "url": "https://replicate.delivery/.../output.png" }
POST/api/ai/generate

Generate images from a text prompt using FLUX Schnell.

Request body
{
  "prompt": "a cat astronaut floating in space",
  "aspectRatio": "1:1",
  "numOutputs": 2,
  "outputFormat": "webp"
}
Response (200)
{ "urls": [
  "https://replicate.delivery/.../1.webp",
  "https://replicate.delivery/.../2.webp"
] }
POST/api/ai/restore

Restore old/blurry photos with face detail recovery (GFPGAN).

Request body
{
  "imageDataUrl": "data:image/png;base64,...",
  "scale": 2
}
Response (200)
{ "url": "https://replicate.delivery/.../restored.png" }
POST/api/ai/cartoonify

Turn a photo into 8 styles (3D, anime, pixel art, clay, etc.).

Request body
{
  "imageDataUrl": "data:image/png;base64,...",
  "style": "3D",
  "prompt": "a smiling person"
}
Response (200)
{ "url": "https://replicate.delivery/.../cartoon.png" }
POST/api/ai/inpaint

Remove objects via mask. White pixels in the mask = remove.

Request body
{
  "imageDataUrl": "data:image/png;base64,...",
  "maskDataUrl":  "data:image/png;base64,..."
}
Response (200)
{ "url": "https://replicate.delivery/.../inpainted.png" }
POST/api/ai/replace-background

Replace the background with an AI-generated scene from a prompt.

Request body
{
  "imageDataUrl": "data:image/png;base64,...",
  "prompt": "a beach at sunset, golden hour"
}
Response (200)
{ "url": "https://replicate.delivery/.../new-bg.webp" }

Errors & rate limits

  • 401 — missing or invalid API key
  • 402 — Pro subscription required (or expired)
  • 400 — invalid input (missing prompt, malformed data URL, etc.)
  • 500/502 — upstream model error
  • 503 — service temporarily unconfigured

No published rate limits today, but please be reasonable. Heavy abuse may result in key revocation.

Get an API key

Pro subscribers get unlimited web access and an API key for the same $9/mo. No separate developer plan to worry about.