API docs / Image models

codeformer API

Robust face restoration algorithm for old photos / AI-generated faces

Model id
sczhou/codeformer
Provider
sczhou
Output
Image
Price
From 3 credits per run, the same as on voor.ai. Options such as length or resolution can change it.

Request

POST https://voor.ai/v1/generations with "model": "sczhou/codeformer". Poll GET /v1/tasks/{id} or receive the signed webhook. See the overview for keys, idempotency, webhooks and errors.

curl https://voor.ai/v1/generations \
  -H "Authorization: Bearer $VOOR_API_KEY" \
  -H "Content-Type: application/json" \
  -H "Idempotency-Key: $(uuidgen)" \
  -d '{
  "model": "sczhou/codeformer",
  "input": {
    "reference_images": [
      "https://example.com/input.png"
    ]
  },
  "callback_url": "https://example.com/webhooks/voor"
}'

# Then poll the task (or wait for the webhook):
curl https://voor.ai/v1/tasks/TASK_ID \
  -H "Authorization: Bearer $VOOR_API_KEY"

Input parameters

NameTypeDetails
reference_imagesrequiredarray of URLs

Input image

Up to 1 files · Accepts image/*

upscale_factornumber

The final upsampling scale of the image

Default: 2

background_enhanceboolean

Enhance background image with Real-ESRGAN

Default: true

codeformer_fidelitynumber

Balance the quality (lower number) and fidelity (higher number).

Default: 0.5

Min 0 · Max 1

face_upsampleboolean

Upsample restored faces for high-resolution AI-created images

Default: true