Skip to navigation

Images

Filters and overlays applied to any public image URL.
View as Markdown

Image endpoints take a public image URL and a transform, queue the work, and hand back a jobId. They do not return an image directly — collect the result with the jobs endpoints.

Filters

GET /v1/image/filter/{type}?image={url}

Thirteen filters:

pixelartasciiascii-colorify
blurgrayscaleinvert
sepiathresholdposterize
edgeglitchvignette
halftone
const job = await aegis.image.filter('ascii', {
image: 'https://example.com/cat.png',
})
const { result } = await aegis.jobs.wait(job.jobId, { timeout: 60 })

Overlays

GET /v1/image/overlay/{type}?image={url}

Four overlays: gay, communism, drip, wanted.

const job = await aegis.image.overlay('wanted', {
image: 'https://example.com/cat.png',
})

The response

Both endpoints answer immediately with the queued job:

{
"success": true,
"data": {
"jobId": "3f8a1c8e-5b7d-2049-af31-c6e8d5b90742",
"status": "pending",
"type": "ascii",
"image": "https://example.com/cat.png"
},
"requestId": "0f8fad5b-d9cb-469f-a165-70867728950e"
}

status will be pending or processing — the work has not finished yet.

Using the result

result on the finished job holds the URL of the transformed image. The job record expires after 24 hours, so copy the URL when you collect it.

const { status, result } = await aegis.jobs.wait(job.jobId, { timeout: 60 })
if (status === 'completed') console.log(result)

result is typed loosely in the spec because its shape is decided by the render worker, not the API. Read it defensively rather than assuming a field is there.

Cost

Images are in the canvas rate class — one of the more expensive buckets, at 10 per minute on the free plan. See rate limits.