01
The short version
Simple by default.
All routes use GET, return JSON, and work from any origin. Start with one quote, then add filters only when your interface needs them.
START HERE
GET /api/quote
{
"quote": "Almost anyone can be an author...",
"author": "A. A. Milne",
"index": 1
}
02
Core resources
Quote endpoints.
Use the quote routes for random discovery, stable indexes, or deterministic author-based experiences.
GET/api/quoteRECOMMENDED
Return one quote. Add a query parameter to request a specific record, author, or deterministic result.
indexnumberOne-based quote index.
author_idstringFilter by stable author ID.
searchstringSearch quote and author text.
seednumberRepeat the same random result.
EXAMPLE/api/quote?search=courage&seed=0
GET/api/quotes
Return a paginated collection of quotes for archive views and data tools.
EXAMPLE/api/quotes?limit=20&offset=0
GET/api/random
Return a fresh random quote without needing to know the archive size.
EXAMPLE/api/random
03
People in the archive
Author endpoints.
Author records provide names, bios, quote counts, and stable IDs for browseable directory experiences.
GET/api/authors
List authors with sorting and pagination.
EXAMPLE/api/authors?sort=quotes&limit=20
GET/api/author/:id
Fetch one author record and its quote count.
EXAMPLE/api/author/A00001
04
Discovery tools
Search the archive.
Build lightweight search, filters, and archive summaries with these read-only routes.
GET/api/search
Search quotes and authors with a single query.
EXAMPLE/api/search?q=hope&limit=10
GET/api/stats
Return archive totals and summary counts.
EXAMPLE/api/stats
GET/api/themes
List available SVG card themes.
EXAMPLE/api/themes
05
Visual output
SVG quote cards.
Generate a shareable SVG from any quote. Cards scale cleanly in READMEs, profiles, websites, and bots.
GET/api/cardSVG
Generate a card by quote index, with optional theme and border controls.
indexnumberQuote index to render.
themestringdark, light, midnight, nord, or mono.
border_radiusnumberRounded corners from 0 to 40.
border_widthnumberStroke width from 0 to 5.
EXAMPLE/api/card?index=1&theme=midnight
06
Health and metadata
Small useful routes.
HEALTH/api/healthSimple service status response.
LETTERS/api/lettersAuthor directory letter index.
THEMES/api/themesAvailable card theme names.
ROOT/apiMachine-readable API index.