Developers

Reading is free and needs no sign-in: the same library the website shows, ranked the same way (names, search terms, typos and plain-language needs). An optional, anonymous agent credential raises the rate limit (https://generativeicons.com/auth.md). Generating a new icon acts for a person and needs their LottieFiles account: an app connects it once (see Generate from your app).

MCP servers#

Server URL Tools
Icons https://generativeicons.com/mcp search_icons, get_icon, list_categories, read_guide
Guides https://generativeicons.com/mcp/docs search_guides, read_guide

Both use Streamable HTTP (MCP 2025-06-18; 2025-03-26 and 2024-11-05 also answer) and expose the guides as resources. Server cards: https://generativeicons.com/.well-known/mcp/server-card.json and https://generativeicons.com/mcp/docs/server-card. In Claude Code:

Terminal
claude mcp add --transport http generative-icons https://generativeicons.com/mcp

A2A agent#

https://generativeicons.com/a2a answers A2A messages (JSON-RPC; A2A 1.0 SendMessage, and 0.3 message/send) at once, with a Markdown part and a JSON data part. Agent card: https://generativeicons.com/.well-known/agent-card.json. Its skills:

Skill Send Reply
find-icons What an icon should mean, e.g. "upload failed" The best matches with their pages and files
icon-details An icon id, e.g. "trash", or a data part {"id": "trash"} Files, sha256, install commands and code
search-guides A question, e.g. "How do I change an icon's color in React?" The guide sections that answer it

A data part {"skill": "...", "query": "...", "category": "...", "limit": 10} picks the skill explicitly. There are no tasks and no streaming.

REST API#

Base URL https://generativeicons.com/api/v1, described at https://generativeicons.com/openapi.json (OpenAPI 3.1).

Request Answer
GET /api/v1/icons?q=<meaning>&category=&limit= The best matches for what an icon should mean
GET /api/v1/icons?limit=&offset= Every icon, a page at a time
GET /api/v1/icons/<id> One icon: description, states, styles, motions, file URL and sha256, install commands, and code for JavaScript, React, iOS and Android
GET /api/v1/categories The categories with their icon counts
GET /api/v1/search?q= Semantic similarity alone (the website fuses it with word matching)
GET /api/v1/bundle.lottie?icons=bell,check&color=&darkColor=&lightColor=&theme=&style=&weight=&motion= Up to 100 icons in one dotLottie file, with the look written in: each icon is an animation named by its id. /api/v1/bundle/<name>.lottie names the file. It sends CORS headers, so other tools can open it by URL
Terminal
curl 'https://generativeicons.com/api/v1/icons?q=upload+failed&limit=3'

Icon files are at https://generativeicons.com/assets/.lottie, the full catalog at https://generativeicons.com/catalog.json, and every guide as Markdown at https://generativeicons.com/docs/.md.

Generate from your app#

When the library has no icon that fits, the website draws a new one in a few minutes, in the same drawing and motion style. Apps and plugins, such as a LottieFiles Creator plugin, can do the same for a person who connects their LottieFiles account. Each generation counts toward that person's daily limit, and the icon is published as a public community icon: unreviewed, MIT licensed.

1. Connect the person's account#

The app shows a code and opens a page. The person signs in with LottieFiles there, checks the code and allows the app. This is the device authorization flow (RFC 8628), with JSON bodies.

Step Request Answer
Start POST /api/v1/connect with {"client": "Your app's name"} device_code (secret), user_code (like BCDF-GHJK), verification_uri_complete, expires_in (600) and interval (5)
Allow Open verification_uri_complete in the person's browser and show user_code The person signs in if needed, checks the code and clicks Allow
Collect POST /api/v1/connect/token with {"device_code": "..."}, every interval seconds Once allowed: {"access_token": "gic_...", "token_type": "Bearer", "expires_in": 2592000, "account": {"id": "..."}}

Until then the token request answers 400 with authorization_pending (keep polling), slow_down (wait 5 seconds longer), access_denied (the person declined), expired_token (the code is older than ten minutes: start again) or invalid_grant (unknown, or already collected). Also poll as soon as your app is visible again: browsers slow timers in background tabs, and the person allows the app in another tab.

The token lasts 30 days. Keep it like a password and send it as Authorization: Bearer. POST /api/v1/connect/revoke with it disconnects the app (always 204). Signing out of the website disconnects every app of the account.

2. Generate#

Request Answer
GET /api/v1/me signedIn, account.id, quota (used, limit, resetsAt) and activeJob. signedIn: false means the token no longer works: connect again
POST /api/v1/generate with {"prompt": "a paper lantern lighting up"} 202 with job, or 200 with reused: an earlier community icon for the same request (send "force": true to generate anyway)
GET /api/v1/jobs/<id> job: status (queued, running, then built, existing, refused or failed), step (brief, drawing, checking, building, reviewing, publishing), preview (the latest build) and, once built, icon with its .lottie URL
GET /api/v1/me/jobs?cursor= The account's generations, newest first

A generation takes about 1 to 7 minutes: poll its job every few seconds until status is no longer queued or running. Every job ends: one that stops reporting reads as failed with error.code STALLED 20 minutes after it started, so the loop below always stops, and a finished job never changes. One runs at a time per account, shared with the website, so a second answers 409 BUSY with the running job's id in job. 401 SIGN_IN_REQUIRED means connect again; 429 QUOTA means the day's generations are used up (quota.resetsAt says when more come).

JavaScript
const BASE = 'https://generativeicons.com';
const call = (path, body, token) => fetch(BASE + path, {
  method: body ? 'POST' : 'GET',
  headers: { 'content-type': 'application/json', ...(token && { authorization: 'Bearer ' + token }) },
  body: body && JSON.stringify(body),
}).then(response => response.json());
const wait = seconds => new Promise(resolve => setTimeout(resolve, seconds * 1000));

// 1. Connect: show the code, open the page, collect the token.
const start = await call('/api/v1/connect', { client: 'My plugin' });
showCode(start.user_code);
openInBrowser(start.verification_uri_complete);
let token, interval = start.interval;
while (!token) {
  await wait(interval);
  const answer = await call('/api/v1/connect/token', { device_code: start.device_code });
  if (answer.access_token) token = answer.access_token;
  else if (answer.error.code === 'slow_down') interval += 5;
  else if (answer.error.code !== 'authorization_pending') throw new Error(answer.error.message);
}

// 2. Generate, then follow the job.
let { job, reused } = await call('/api/v1/generate', { prompt: 'a paper lantern lighting up' }, token);
while (job && ['queued', 'running'].includes(job.status)) {
  await wait(3);
  ({ job } = await call('/api/v1/jobs/' + job.id, null, token));
}
const icon = reused ?? job.icon; // icon.lottie is the dotLottie file's URL

Errors#

Every error is JSON: {"error": {"code": "...", "message": "..."}}.

Status Code When
400 invalid_parameter A parameter is missing or unknown
404 not_found No such icon, endpoint or file
400 authorization_pending, slow_down, access_denied, expired_token, invalid_grant Connecting an app: see Generate from your app
401 invalid_token A token of this site's that expired or was altered (no token is fine)
401 SIGN_IN_REQUIRED Generating without a session or a working app token: connect again
409 BUSY A generation of the account is still running; the body's job is its id
429 QUOTA The account's generations for the day are used up
405 method_not_allowed A method the endpoint doesn't take (reading is GET; generating and connecting are POST)
429 rate_limited Past the limit; wait the seconds in Retry-After
503 unavailable The library or semantic search could not be read; retry

Limits#

Each client (IP address) may make 120 requests a minute across the API, both MCP servers and the A2A agent. An agent that registers (anonymous, no sign-in: https://generativeicons.com/auth.md) and sends its access token gets its own 600 a minute. Every response carries RateLimit-Policy; past the limit the answer is 429 with Retry-After.

Generating has its own limits: each LottieFiles account may generate 10 icons a day, one at a time, and make 6 generate requests a minute. Starting a connection is limited to 10 a minute per IP address.

Versions and deprecation#

  • Paths carry the major version: /api/v1/. Additions (new endpoints, fields or parameters) never break v1.
  • A breaking change ships as a new version beside the old one. The old version keeps working for at least six months; its responses carry a Deprecation header (RFC 9745), a Sunset header with the removal date (RFC 8594), and a Link to the successor (rel="successor-version") and to this page (rel="deprecation").
  • The unversioned /api/ paths answer like v1 but are deprecated since 6 October 2026 and will be removed on 6 April 2027. Use /api/v1/.
  • MCP tools change the same way: new tools and optional arguments are additions; a breaking change gets a new tool name, and the old one keeps working for six months.

In the browser#

The home page registers search_icons, open_icon, set_icon_appearance and get_icon_code as WebMCP tools (document.modelContext), and the search box is a declarative tool form; icon pages register the same tools but open_icon.

Discovery#

https://generativeicons.com/llms.txt · https://generativeicons.com/index.md · https://generativeicons.com/.well-known/ard.json · https://generativeicons.com/.well-known/api-catalog · https://generativeicons.com/.well-known/agent-card.json · https://generativeicons.com/.well-known/agent-skills/index.json · https://generativeicons.com/.well-known/oauth-protected-resource · https://generativeicons.com/auth.md · https://generativeicons.com/sitemap.xml

Contact#

Questions and problems: support@lottiefiles.com or https://help.lottiefiles.com/kb-tickets/new.