http.cat
CLAUDE.md3.7k starsChanged 18 days agoMITView on GitHub
The website at https://http.cat: a static Next.js site with a cat image for each HTTP status code. There's no server-side code: the "API" (e.g. /404 returning the 404 cat image) is implemented in the Nginx config. New features and behavior changes start as a spec in specs/. Read specs/README.md for the process before working on one. - Don't implement a feature or behavior change until its spec has Status: approved. If there's no spec yet, write a draft and ask…
We split this CLAUDE.md into the rules it gives an agent
2 rules. About 0 are common, 0 are distinctive, and 2 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈0
Distinctive · estimate
This author's own choices. Worth a look.
2
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Very specific: line 12
Don't implement a feature or behavior change until its spec has Status: approved.
- Very specific: line 60
Follow the README: add the image to both public/images/ and public/images-original/, add the status to lib/statuses.js, and add …
≈ “Common” is an estimate: at least 1 in 5 of the 25,680 CLAUDE.md files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
http.cat
The website at https://http.cat: a static Next.js site with a cat image for each
HTTP status code. There's no server-side code: the "API" (e.g. /404 returning
the 404 cat image) is implemented in the Nginx config.
Spec-driven development
New features and behavior changes start as a spec in specs/. Read
specs/README.md for the process before working on one.
- Don't implement a feature or behavior change until its spec has
Status: approved. If there's no spec yet, write a draft and ask for review. - Behavior is "done" when the spec's acceptance checks pass. Update the spec in the same change if the implementation had to deviate from it.
specs/0000-baseline/spec.mddescribes the URLs the site serves today and the invariants they rely on. Any change that alters those tables must update them.- Small changes (new cat images, typos, translations, dependency bumps) and infrastructure or tooling changes that don't change what a URL returns (e.g. Nginx syntax updates, scripts) don't need a spec.
Commands
npm run dev: local dev servernpm run build: static export toout/(runsscripts/post-build.jsafter)npm test: content and build output checks (runnpm run buildfirst)npm run lint: ESLintnpm run nginx:up/nginx:down: serveout/through the production Nginx config in Docker (scripts/local-nginx.sh). Usessudo dockerwhen the socket isn't writable, so it needs the user to run it (! npm run nginx:up).npm run test:smoke: checks the spec URL tables against the container, or against production withSMOKE_URL=https://http.cat(GET requests only)
How it fits together
lib/statuses.js: the list of statuses shown on the site. It's CommonJS so the Node scripts inscripts/can reuse it.content/<code>.mdandcontent/ca/<code>.md: status descriptions (English and Catalan), rendered bylib/status-info.ts.locales/{en,ca}/common.json: UI strings. Both files must have the same keys.public/images/(served) andpublic/images-original/(originals): one<code>.jpgper status.0.jpgis a hidden easter egg not instatuses.js.app/: pages.app/ca/mirrors the English pages for Catalan.app/[file]/route.tsgenerates the JSON API (out/<code>.json).deploy/nginx/http.cat.conf: production Nginx config, the source of truth. Itstry_filesorder is load-bearing (see the comments in the file and issue #267). It isn't deployed automatically: changes have to be copied to the server by the maintainer.integrations/: snippets for using HTTP Cats in other tools (not deployed).
Deploying
npm run deploy (scripts/deploy.sh) rsyncs out/ to the server and purges
the Cloudflare cache. Without a purge, Cloudflare keeps serving old responses,
including old redirects and 404s. Never run a deploy or purge without the
maintainer asking for it.
Adding a status
Follow the README: add the image to both public/images/ and
public/images-original/, add the status to lib/statuses.js, and add
content/<code>.md plus a Catalan translation in content/ca/<code>.md.
npm test checks that all of these exist.
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

