Skip to content

Fetch a font file

GET
/f/{file}
curl --request GET \
--url https://api.pixonaut.app/f/example

Operation ID: fonts.files.get

A font family’s file by its content hash: a TTF for a renderer, a WOFF2 for a browser. Any cache may keep it for good, since the bytes at a hash never change. A TTF asked for with text is cut down to the glyphs those characters reach, every layout feature kept, so a renderer draws text made only of them as the whole face draws it; a text of more than 1000 distinct characters is served the whole face.

file
required
string
text
string

The font file

string
X-Request-Id
required
string

Every response names the request it answers in X-Request-Id: the id the request was sent with in that header, when it is well formed, else one the API gave it. Quote it when reporting a refusal or a failure: the API’s log lines for that request carry it.

Not modified: the If-None-Match etag still holds

X-Request-Id
required
string

Every response names the request it answers in X-Request-Id: the id the request was sent with in that header, when it is well formed, else one the API gave it. Quote it when reporting a refusal or a failure: the API’s log lines for that request carry it.

No font file by that name: <sha256>.ttf or <sha256>.woff2 naming a hash the catalog has made (plain text)

X-Request-Id
required
string

Every response names the request it answers in X-Request-Id: the id the request was sent with in that header, when it is well formed, else one the API gave it. Quote it when reporting a refusal or a failure: the API’s log lines for that request carry it.

Refused: rate_limited

Media typeapplication/json
object
error
required
string

Examples

Examplerate_limited

rate_limited

{
"error": "rate_limited"
}
X-Request-Id
required
string

Every response names the request it answers in X-Request-Id: the id the request was sent with in that header, when it is well formed, else one the API gave it. Quote it when reporting a refusal or a failure: the API’s log lines for that request carry it.

The request failed unexpectedly.

Media typetext/plain
string
Allowed value: Internal Server Error
X-Request-Id
required
string

Every response names the request it answers in X-Request-Id: the id the request was sent with in that header, when it is well formed, else one the API gave it. Quote it when reporting a refusal or a failure: the API’s log lines for that request carry it.

Questions? Write to [email protected].

Status · Terms of service · Privacy policy · Subprocessors