Skip to content

Rendered sprite sheet image (WebP) — same parameters as the manifest

GET
/sprite/{providerKey}/{listKey}/sheet
curl --request GET \
--url 'https://gib.show/sprite/example/example/sheet?size=32&cols=25&limit=500&content=mixed&scale=1&gap=0&bg=ffffff&shape=circle&contrast=dark'
providerKey
required
string

Provider slug (e.g. pulsex, coingecko, trustwallet; user submissions are prefixed user-).

listKey
required
string

Provider’s list slug (e.g. extended).

size
integer
default: 32 >= 16 <= 128

Cell size in CSS pixels.

cols
integer
default: 25 >= 5 <= 50

Grid columns.

limit
integer
default: 500 >= 1 <= 2000

Maximum tokens. A request with a plate is cut to 500.

content
string
Allowed values: mixed

Content=mixed inlines vector images as data addresses instead of placing them on the grid.

chainId
string

Filter to one chain.

scale
integer
default: 1
Allowed values: 1 2

Sheet pixels per CSS pixel. 2 draws the sheet at twice the resolution for dense screens; positions and sizes stay in CSS pixels. Any value other than 2 means 1.

gap
integer
0 <= 32

Space between cells, in CSS pixels, so neighbouring logos do not touch and a scaled page cannot bleed one into another. Scaled with the sheet. Any value outside 0 to 32 answers 400.

bg
string
/^([0-9a-fA-F]{3}|[0-9a-fA-F]{6}|[0-9a-fA-F]{8})$/

Paint a plate of this colour behind the logo: 3, 6 or 8 hex digits without #, the last two of eight being alpha (for example ffffff, f80, 00000080). Any other value answers 400. A vector image stays a vector (image/svg+xml) unless as asks for pixels. With as=svg, a vector image that has no usable viewBox cannot take a plate as a vector, and the answer is 404 and not a png. A plate drawn to pixels is never wider than 2048 pixels: a larger logo is shrunk to fit. With contrast as well, bg is the plate colour and contrast decides whether the plate appears.

shape
string
default: circle
Allowed values: circle rounded square

The outline of the plate. Only used together with bg or contrast; on its own it is checked and then ignored. Any other value answers 400.

contrast
string
Allowed values: dark light

Say whether your page is dark or light. Gib looks at what share of the visible pixels of the logo have at least 3:1 contrast with that page, and adds a plate in the opposite tone (light on dark, dark on light) only when that share is under 25 percent, so a logo with some strong parts is left alone. Otherwise the image is served as if the parameter were absent. If the logo cannot be measured, the plain image is sent with cache-control: no-store. Any other value answers 400.

v
string
/^[0-9a-f]{14}$/

The layout version the manifest gave (its version field). Optional. When it no longer matches the current layout the answer is 409, so no client pairs one layout with another sheet.

WebP sheet with x-sprite-* metadata headers, including x-sprite-version. Kept a day when pinned by v, and five minutes otherwise.

Media type: image/webp
string format: binary

No raster tokens to render.

A gap, plate colour, shape or tone that is not valid.

Media type: application/json
object
error
string

Example generated

{
"error": "example"
}

Unknown provider or list.

Media type: application/json
object
error
string

Example generated

{
"error": "example"
}

The layout named by v is no longer current. Read the manifest again. The answer is never a redirect, which would pair one layout with another sheet.

Media type: application/json
object
error
string

Example generated

{
"error": "example"
}

This caller, or every caller together, has spent the sheet budget for the window. A sheet costs one unit per cell drawn (two for a plated cell), and the budget is spent only when a sheet is actually drawn. Retry-After says when it renews, in seconds, and the answer is never cached.

Media type: application/json
object
error
string

Example generated

{
"error": "example"
}
Retry-After
integer

Too many sheets are being drawn at once. Retry-After says how long to wait, in seconds, and the answer is never cached.

Media type: application/json
object
error
string

Example generated

{
"error": "example"
}
Retry-After
integer