---
title: "Upscale Image"
method: POST
path: "/media/upscale"
tags: ["media"]
---

# Upscale Image

`POST /media/upscale`

## Request

- Base URL: `https://api.moda.app/v1`
- URL: `https://api.moda.app/v1/media/upscale`
- Auth: HTTP bearer

Deterministic super-resolution, 2x or 4x (metered provider call).

An image with real transparency is routed to the alpha-preserving engine,
which renders 4x only: `scale=2` on such an image is rejected with 422 and
a message naming both ways forward. Everything else accepts either factor.

Transparency is detected by reading the image, and that read has a size
ceiling: above ~24 megapixels the alpha channel is left unread and the
image takes the ordinary route, which flattens it. Both factors stay
available there. Flatten such a source yourself if its transparency
matters.

## Headers

- `Moda-Version` '2026-04-12' | '2026-05-01'

## Request body

- UpscaleImageRequest
  - `image` string, required: file_ id or http(s) URL.
  - `scale` integer: 2 or 4.
  - `idempotency_key` string, nullable: A retried call with the same key replays the stored response (replayed:true) instead of paying for a second provider render.

## Response `200`

Successful Response

- object

## Other responses

- `401`: Authentication required.
- `402`: Insufficient credits for a metered operation.
- `403`: Permission denied for this scope.
- `404`: Resource not found.
- `409`: Conflict (idempotency / resource state).
- `422`: Request validation failed.
- `429`: Rate limit exceeded.
- `500`: Internal error.

## Changes

- **2026-11-03** `9ac6a3abc0f8`: 1 info
  - endpoint added

[Operation history](https://skmtc.dev/moda/apis/moda-public-api/changes/media/upscale/post.md)

---

[API](https://skmtc.dev/moda/apis/moda-public-api.md) - [All operations](https://skmtc.dev/moda/apis/moda-public-api/llms.txt) - [OpenAPI document](https://skmtc.dev/moda/apis/moda-public-api/revisions/9ac6a3abc0f8?raw)
