REST API · Webhooks · MCP

Image APIfor upscaling and editing

Every tool on the website over HTTPS: upscale, remove background, white background with shadow, remove objects and AI expand. Start free with a sandbox key, then buy a credit pack or use the Business plan.

  • 100 free sandbox jobs a month
  • Failed jobs refunded automatically
  • Signed webhooks
  • Idempotent retries

OpenAPI spec: /api/v1/openapi.json

# 1. Create a job
curl https://imageupscale.app/api/v1/jobs \
  -H "Authorization: Bearer $IMAGEUPSCALE_KEY" \
  -F file=@./photo.jpg -F scale=4

# 2. Poll until "status" is "succeeded", then download output.url
curl https://imageupscale.app/api/v1/jobs/$JOB_ID \
  -H "Authorization: Bearer $IMAGEUPSCALE_KEY"

Upscale

tool=upscale

1 credit per 2 MP at 2x/4x

Remove background

tool=removebg

1 credit

Old photo repair

tool=restore

4 credits per 4 output MP

Text & screenshots

tool=text

2 credits

Remove objects

tool=erase

20 credits

AI expand

tool=expand

20 credits

Pay as you go

Pricing

Credits from a pack never expire and also work on the website. Buying any pack unlocks live keys. A 4x upscale of an image up to 2 MP or a background removal is 1 credit; remove objects and AI expand are 20.

Sandbox

Free

iu_test_ key · any account

  • 100 jobs a month
  • No credits used
  • Watermarked results
Create key

1,000 credits

$19

$19.00 per 1,000 credits

  • Never expire
  • Unlocks live keys
  • Work on the website too

10,000 credits

$149

$14.90 per 1,000 credits

  • Never expire
  • Unlocks live keys
  • Work on the website too
Best value

50,000 credits

$590

$11.80 per 1,000 credits

  • Never expire
  • Unlocks live keys
  • Work on the website too

Business plan · $24.99/month · includes the API with 5,000 credits a month

Compare plans

Step 1

Get a key

Go to Account → API & webhooks and create a key. It's shown once; store it as a secret. Send it in the Authorization header:

HTTP header
Authorization: Bearer iu_live_…
Free

Sandbox keys (iu_test_…) are free on any account: 100 jobs a month, no credits used, and results carry a watermark. Use them to build and test your integration.

Playground

Try it

Paste a sandbox key, pick an image and send a real request. You'll see each response as the job runs.

POST/api/v1/jobs

The key stays in this tab and is only sent to our API.

Response
// Response appears here

Step 2

Create a job

Send the image as a multipart file, or JSON with an image_url. Add an Idempotency-Key header so network retries never charge twice, and a webhook_url if you don't want to poll.

POST/api/v1/jobs
curl https://imageupscale.app/api/v1/jobs \
  -H "Authorization: Bearer $IMAGEUPSCALE_KEY" \
  -H "Idempotency-Key: order-1234-photo-1" \
  -F file=@./photo.jpg -F scale=4 -F model=photo

Step 3

Get the result

Poll every 2–5 seconds until status is succeeded or failed, or use a webhook. output.url is a signed link valid for up to an hour; fetch the job again for a new one. Results are deleted after 30 days on paid plans (24 hours otherwise).

GET/api/v1/jobs/:id
queuedprocessingsucceededorfailed
{
  "id": "Vb3k…",
  "object": "job",
  "status": "succeeded",
  "scale": 4,
  "model": "photo",
  "output": {
    "url": "https://…",
    "width": 4000,
    "height": 3000,
    "bytes": 8123456,
    "expires_at": "…"
  },
  "credits_cost": 1,
  "refunded": false,
  "error": null
}

Reference

Options

Send these as form fields or JSON keys on create.

Upscaling

scale

2 · 4 · 8 · 16

2x/4x cost 1 credit per started 2 input MP, 8x 2 per 2 MP, 16x (two 4x passes) 8 per input MP. Required unless target is set.

model

photo · anime

Which upscaling model to use.

face_enhance

boolean

Adds 1 credit per started input MP.

denoise

off · low · medium · high

Cleans noise and JPEG blocks before upscaling.

unblur

boolean

Removes motion or focus blur before upscaling (input up to 4 MP, adds ceil(input MP × 5) credits).

Target size

target

pixels · print · preset · edge · enhance

pixels (width/height), print (print + dpi), preset, edge or enhance (same size as the input: AI clean-up without enlarging).

preset

amazon · shopify · etsy · ebay · instagram_square · instagram_portrait · youtube_thumbnail · desktop_4k

With target=preset.

edge

1080 · 2048 · 3840 · 7680

Pixels on the long side, with target=edge.

Enhancements

auto_color

boolean

Fixes dull, dark or washed-out colour and light. Free.

sharpen

off · low · medium · high

Free.

strength

0–100

Default 100. Lower values blend the AI result with a plain resize for a more natural look. Free.

lighting

boolean

Lifts shadows and midtones. Free.

Tools

tool

upscale · restore · text · creative

upscale (default), restore (old photo repair, 4 credits per started 4 output MP; colorize: true adds 1 per started 2 input MP), text (text & screenshots, 2 credits) or creative (AI adds new detail; creativity 1–10, 8 credits per output MP, min 8, output up to 16 MP). Tools run at scale 2 or 4.

tool

removebg · erase · expand

Edit tools keep the input size and take no scale: removebg (cut-out only, 1 credit; with background, shadow: none, soft, contact or float, and square: true for a centred square canvas), erase (20 credits; mask file or mask_url) and expand (20 credits; aspect: 1:1, 4:5, 3:4, 2:3, 9:16, 16:9, 3:2, 4:3).

Background

background

keep · transparent · white · color · blur

transparent (cut-out, PNG/WebP), white (cut-out on white, for marketplaces), color with bg_color (e.g. #f5f5f5) or blur (portrait-style blurred background). Any of these adds 1 credit.

Output & input

output_format

auto · png · jpg · webp

File format of the result.

metadata

keep · strip

keep copies camera EXIF (never GPS).

input

JPG · PNG · WebP · AVIF · HEIC · TIFF · BMP · GIF

GIF uses the first frame. Up to 50 MB / 10,000 px; output up to 512 MP.

Events

Webhooks

We POST { event, created_at, data: Job } with X-ImageUpscale-Signature: t=…,v1=…. Verify it with your webhook secret (Account page).

Non-2xx responses are retried 3 times

  1. #1after 1 minute
  2. #210 minutes
  3. #31 hour
import crypto from "node:crypto";

function verify(rawBody, header, secret) {
  const { t, v1 } = Object.fromEntries(header.split(",").map((kv) => kv.split("=")));
  if (Math.abs(Date.now() / 1000 - Number(t)) > 300) return false;
  const mac = crypto.createHmac("sha256", secret).update(`${t}.${rawBody}`).digest("hex");
  return crypto.timingSafeEqual(Buffer.from(mac), Buffer.from(v1));
}

Reliability

Limits & errors

10/s

requests per key

20

jobs in progress per key

50 MB

max input · 10,000 px

512 MP

max output

Over the limit you get 429 with Retry-After. Send an Idempotency-Key on create so network retries never charge twice. Errors look like this:

{"error":{"code":"quota_paid","message":"Not enough credits."}}
HTTPcode
400bad_requestMissing or invalid parameters.
400unsupported_formatThe file isn't a supported image.
400too_large_pixelsInput is over 10,000 px.
401unauthorizedMissing or invalid API key.
402quota_paidNot enough credits.
403forbiddenLive keys need a Business plan or an API pack.
413too_large_bytesInput file is over 50 MB.
413output_too_largeOutput exceeds your megapixel limit.
422target_unreachableTarget size can't be reached with the scales available.
422nsfwBlocked by content policy.
429sandbox_limitSandbox key used its 100 jobs this month.
429rate_limitedOver the request rate. Wait for Retry-After.

Start building for free

A sandbox key gives you 100 watermarked jobs a month. Switch to a live key when you're ready; failed jobs are refunded automatically.