SwinIR
SwinIR is an image restoration and super-resolution model based on Swin Transformer blocks, producing high-quality upscales with strong texture recovery and low artifact levels across common restoration settings.

API Reference
INTEGRATE
Complete technical specification for integration
RequestResponse
Examples4
CODE
Ready-to-use code snippets for common workflows
upscale
Vintage Sextant Auction Catalog Master$0.0019~7s
import { createClient } from '@runware/sdk'
const client = await createClient({ apiKey: process.env.RUNWARE_API_KEY })
await client.connect()
const [result] = await client.run({
model: 'runware:503@1',
upscaleFactor: 4,
inputs: {
image: 'https://assets.runware.ai/assets/inputs/9bd6fb5c-f794-4403-aaa9-df26464cb816.jpg'
}
})import asyncio
import os
from runware import Runware
async def main():
async with Runware(api_key=os.environ["RUNWARE_API_KEY"]) as client:
results = await client.run({
"model": "runware:503@1",
"upscaleFactor": 4,
"inputs": {
"image": "https://assets.runware.ai/assets/inputs/9bd6fb5c-f794-4403-aaa9-df26464cb816.jpg"
}
})
asyncio.run(main())curl https://api.runware.ai/v1 \
-H "Authorization: Bearer $RUNWARE_API_KEY" \
-H "Content-Type: application/json" \
-d '[
{
"taskType": "upscale",
"taskUUID": "e4517d73-25ea-4473-b97f-f69eae118a28",
"model": "runware:503@1",
"upscaleFactor": 4,
"inputs": {
"image": "https://assets.runware.ai/assets/inputs/9bd6fb5c-f794-4403-aaa9-df26464cb816.jpg"
}
}
]'runware run runware:503@1 \
upscaleFactor=4 \
inputs.image=https://assets.runware.ai/assets/inputs/9bd6fb5c-f794-4403-aaa9-df26464cb816.jpg{
"taskType": "upscale",
"taskUUID": "e4517d73-25ea-4473-b97f-f69eae118a28",
"model": "runware:503@1",
"upscaleFactor": 4,
"inputs": {
"image": "https://assets.runware.ai/assets/inputs/9bd6fb5c-f794-4403-aaa9-df26464cb816.jpg"
}
}Response
{
"taskType": "imageUpscale",
"taskUUID": "e4517d73-25ea-4473-b97f-f69eae118a28",
"imageUUID": "13bee6cc-974d-48ba-89e0-78283e5dca13",
"imageURL": "https://im.runware.ai/image/os/a10dlim3/ws/4/ii/13bee6cc-974d-48ba-89e0-78283e5dca13.jpg",
"cost": 0.0019,
"inputImageUUID": "9efae5a0-5610-4163-be55-84ef9c921905"
}upscale
Arctic Greenhouse Blue-Hour Enlargement$0.0032~11s
import { createClient } from '@runware/sdk'
const client = await createClient({ apiKey: process.env.RUNWARE_API_KEY })
await client.connect()
const [result] = await client.run({
model: 'runware:503@1',
upscaleFactor: 4,
inputs: {
image: 'https://assets.runware.ai/assets/inputs/0b2f0308-ab02-493e-8af8-a89c461c8643.jpg'
}
})import asyncio
import os
from runware import Runware
async def main():
async with Runware(api_key=os.environ["RUNWARE_API_KEY"]) as client:
results = await client.run({
"model": "runware:503@1",
"upscaleFactor": 4,
"inputs": {
"image": "https://assets.runware.ai/assets/inputs/0b2f0308-ab02-493e-8af8-a89c461c8643.jpg"
}
})
asyncio.run(main())curl https://api.runware.ai/v1 \
-H "Authorization: Bearer $RUNWARE_API_KEY" \
-H "Content-Type: application/json" \
-d '[
{
"taskType": "upscale",
"taskUUID": "b405138b-71ff-472f-b8bc-b18a70ef089d",
"model": "runware:503@1",
"upscaleFactor": 4,
"inputs": {
"image": "https://assets.runware.ai/assets/inputs/0b2f0308-ab02-493e-8af8-a89c461c8643.jpg"
}
}
]'runware run runware:503@1 \
upscaleFactor=4 \
inputs.image=https://assets.runware.ai/assets/inputs/0b2f0308-ab02-493e-8af8-a89c461c8643.jpg{
"taskType": "upscale",
"taskUUID": "b405138b-71ff-472f-b8bc-b18a70ef089d",
"model": "runware:503@1",
"upscaleFactor": 4,
"inputs": {
"image": "https://assets.runware.ai/assets/inputs/0b2f0308-ab02-493e-8af8-a89c461c8643.jpg"
}
}Response
{
"taskType": "imageUpscale",
"taskUUID": "b405138b-71ff-472f-b8bc-b18a70ef089d",
"imageUUID": "51c554a6-e824-4f95-a200-579508a56271",
"imageURL": "https://im.runware.ai/image/os/a04d20/ws/4/ii/51c554a6-e824-4f95-a200-579508a56271.jpg",
"cost": 0.0032,
"inputImageUUID": "33cc1435-de35-4ddb-b1bc-2fd28ee5ec72"
}upscale
Japanese Firecoat Conservation Master$0.007~17s
import { createClient } from '@runware/sdk'
const client = await createClient({ apiKey: process.env.RUNWARE_API_KEY })
await client.connect()
const [result] = await client.run({
model: 'runware:503@1',
upscaleFactor: 4,
inputs: {
image: 'https://assets.runware.ai/assets/inputs/2f90022f-c6e7-46da-a2da-79f2cff562bb.jpg'
}
})import asyncio
import os
from runware import Runware
async def main():
async with Runware(api_key=os.environ["RUNWARE_API_KEY"]) as client:
results = await client.run({
"model": "runware:503@1",
"upscaleFactor": 4,
"inputs": {
"image": "https://assets.runware.ai/assets/inputs/2f90022f-c6e7-46da-a2da-79f2cff562bb.jpg"
}
})
asyncio.run(main())curl https://api.runware.ai/v1 \
-H "Authorization: Bearer $RUNWARE_API_KEY" \
-H "Content-Type: application/json" \
-d '[
{
"taskType": "upscale",
"taskUUID": "2eba213a-8bba-443e-9367-320df28bd847",
"model": "runware:503@1",
"upscaleFactor": 4,
"inputs": {
"image": "https://assets.runware.ai/assets/inputs/2f90022f-c6e7-46da-a2da-79f2cff562bb.jpg"
}
}
]'runware run runware:503@1 \
upscaleFactor=4 \
inputs.image=https://assets.runware.ai/assets/inputs/2f90022f-c6e7-46da-a2da-79f2cff562bb.jpg{
"taskType": "upscale",
"taskUUID": "2eba213a-8bba-443e-9367-320df28bd847",
"model": "runware:503@1",
"upscaleFactor": 4,
"inputs": {
"image": "https://assets.runware.ai/assets/inputs/2f90022f-c6e7-46da-a2da-79f2cff562bb.jpg"
}
}Response
{
"taskType": "imageUpscale",
"taskUUID": "2eba213a-8bba-443e-9367-320df28bd847",
"imageUUID": "2fcbc251-dcaf-40e1-94cc-df2ab4133a57",
"imageURL": "https://im.runware.ai/image/os/a09dlim3/ws/4/ii/2fcbc251-dcaf-40e1-94cc-df2ab4133a57.jpg",
"cost": 0.007,
"inputImageUUID": "7f5acb57-873f-40b1-a72c-22d9c784b613"
}upscale
Cyanotype Fossil Exhibition Portrait$0.0038~10s
import { createClient } from '@runware/sdk'
const client = await createClient({ apiKey: process.env.RUNWARE_API_KEY })
await client.connect()
const [result] = await client.run({
model: 'runware:503@1',
upscaleFactor: 4,
inputs: {
image: 'https://assets.runware.ai/assets/inputs/62bf2181-a2ab-4329-97fc-ad2682cb8513.jpg'
}
})import asyncio
import os
from runware import Runware
async def main():
async with Runware(api_key=os.environ["RUNWARE_API_KEY"]) as client:
results = await client.run({
"model": "runware:503@1",
"upscaleFactor": 4,
"inputs": {
"image": "https://assets.runware.ai/assets/inputs/62bf2181-a2ab-4329-97fc-ad2682cb8513.jpg"
}
})
asyncio.run(main())curl https://api.runware.ai/v1 \
-H "Authorization: Bearer $RUNWARE_API_KEY" \
-H "Content-Type: application/json" \
-d '[
{
"taskType": "upscale",
"taskUUID": "de9d1022-d12a-4026-bbac-5ac93d4325eb",
"model": "runware:503@1",
"upscaleFactor": 4,
"inputs": {
"image": "https://assets.runware.ai/assets/inputs/62bf2181-a2ab-4329-97fc-ad2682cb8513.jpg"
}
}
]'runware run runware:503@1 \
upscaleFactor=4 \
inputs.image=https://assets.runware.ai/assets/inputs/62bf2181-a2ab-4329-97fc-ad2682cb8513.jpg{
"taskType": "upscale",
"taskUUID": "de9d1022-d12a-4026-bbac-5ac93d4325eb",
"model": "runware:503@1",
"upscaleFactor": 4,
"inputs": {
"image": "https://assets.runware.ai/assets/inputs/62bf2181-a2ab-4329-97fc-ad2682cb8513.jpg"
}
}Response
{
"taskType": "imageUpscale",
"taskUUID": "de9d1022-d12a-4026-bbac-5ac93d4325eb",
"imageUUID": "6e6e9536-1b3e-44df-a39b-812869f74a9d",
"imageURL": "https://im.runware.ai/image/os/a10dlim3/ws/4/ii/6e6e9536-1b3e-44df-a39b-812869f74a9d.jpg",
"cost": 0.0038,
"inputImageUUID": "c839abf2-4d7c-4413-b82b-e9dc1acd04e1"
}