Skip to content

Upscale Exact

Request

Description

The Upscale Exact Route enlarges an image to upscale_factor times its size on each side, anywhere from 1x to 4x, decimals included, with Bria's FIBO 2 upscaler.

Instead of stretching pixels, a FIBO 2 model trained for upscaling redraws the image at the new size, rebuilding edges, textures and fine detail. The result is then matched back to the source's colors and cleaned of grain, so it stays faithful to the original. See What's new: Bria Upscale Exact for examples.

Asynchronous

This endpoint is asynchronous only. It returns 202 Accepted with a status_url right away; get the result from the status endpoint or a webhook. When the job is done, result holds image_url and the seed it used. A small image takes about 10 seconds, and a 16 MP image about a minute.

Size Limits

  • Each side of the input must be at least 256 px, and the input at most 16,777,216 px in total (16.8 MP, such as 4096 x 4096).
  • The result, upscale_factor times each side, can be at most 70,000,000 px.

A request outside these limits returns 400 Resolution not supported, with the limit in details, before any processing starts.

Transparency

With preserve_alpha (the default), the input's alpha channel comes back resized to the result, as a PNG. A JPEG has no transparency, so output_type: jpeg leaves it out.

Content Moderation

This endpoint includes granular content moderation controls to ensure safe usage across all stages of processing:

  • Input Image Moderation – Scans the uploaded image and stops processing if inappropriate or restricted content is detected.
  • Output Image Moderation – Evaluates the generated image and blocks the response if it violates safety guidelines.

Constraints

The Bria API supports JPEG, PNG and WEBP files in RGB, RGBA, or CMYK color modes. When the file is of a different type or color mode, the status code 415 will be returned.

Security
api_token
Bodyapplication/jsonrequired
imagestringrequired

The source image to be handled by the API. Supported input types:

  • Base64-encoded string
  • URL pointing to an image file that is publicly accessible and available at the time of processing.

Accepted formats: JPEG, JPG, PNG, WEBP. Each side must be at least 256 px, and the image at most 16,777,216 px in total.

upscale_factornumber, (float), [ 1 .. 4 ]

How many times larger each side gets, as a float from 1 to 4, such as 2.5. 2 doubles the width and height. The result can be at most 70,000,000 px.

Default:2
preserve_alphaboolean

Controls whether the alpha channel values from the input image are retained in the output, if the input includes an alpha channel.

  • When true: The output image maintains the original transparency of fully and partially transparent pixels, resized to the result.
  • When false: The output image is fully opaque.
  • Has no effect if the input image does not include an alpha channel, or with output_type: jpeg.
Default:true
output_typestring

The result's format. A JPEG is several times smaller than the PNG but has no transparency.

Default:"png"
Enum:"png""jpeg"
seedinteger, [ 1 .. 4294967295 ]

Seeds the upscale. When omitted, a random seed is used; the result returns the seed it used.

webhook_urlstring, (uri)

Optional URL for receiving the result via webhook when the async job completes. See webhooks.

visual_input_content_moderationboolean

When enabled, applies content moderation to input visual.

Expected behavior:

  • Processing stops if the image fails moderation.
  • Returns a 422 error with details about which parameter failed.
Default:false
visual_output_content_moderationboolean

When enabled, applies content moderation to result visual.

Expected behavior:

  • If the modified image fails moderation, returns a 422 error.
Default:false
POST
/upscale/exact
from bria_client import BriaSyncClient

client = BriaSyncClient()  # reads BRIA_API_TOKEN

job = client.submit(
    endpoint="image/upscale/exact",
    payload={
        "image": "https://labs-assets.bria.ai/sandbox-example-inputs/enhance_image_example.jpg",
        "upscale_factor": 2.5,
    },
)
result = client.poll(job, interval=3, timeout=600)
print(result.result.image_url)

Responses

Accepted (Asynchronous). You can track the progress and retrieve the final result using the status endpoint. For more details, refer to the status endpoint section.

Bodyapplication/json
request_idstringrequired
status_urlstringrequired
Response
{ "request_id": "string", "status_url": "string" }