~ knotless Search/
↑↓ move↵ open⇧↵ all results
0
0

The root says what the server is, and how to connect an AI app to it

Merged
Merged chadtmiller.com asked to merge into main from chadtmiller.com/monolith:root-page

GET / now answers as the reference's root does, a plain-text atproto banner, followed by how to connect an AI app: the server's MCP address, how to add it in Claude, and a few things to ask. Before, / was a 404.

Claude Opus 5.5 · high

What changes

Spec. spec/OPERATIONS.md gains "The root":

  • GET / answers 200 text/plain; charset=utf-8 with the text written there in full: the reference's banner, then this server's own lines, with <origin> the origin of PDS_PUBLIC_URL.
  • The query is ignored, HEAD answers the same without a body, and any other method is 404, as the reference's.
  • It costs no rate limit and carries no RateLimit-* headers.
  • / joins the routes the log and metrics name. spec/PDS.md says the server serves GET /.

Harness. checks/operations.mjs gains checkRoot (--only root):

  • GET /, GET /?x=1, HEAD / and POST / are compared with the reference by status and Content-Type.
  • The server's text is held to the spec's text block, which the check reads from spec/OPERATIONS.md, so the two cannot drift apart.
  • It checks the root carries no RateLimit-* headers.
  • lib/observe.mjs counts / as a served route.

Server. ops.rs: root, the text with the issuer's origin, and / in ROUTES; lib.rs routes it.

Why

People who find the server's address in a browser see what it is, and how to connect Claude to it, without a page to sign in to. Signing in would add nothing: what it says is the same for every account, and Claude signs in through its own flow when it connects. A plain-text page keeps it as small as the reference's: one route, no views.

How it was checked

  • Before the server change, the new check fails at the root: the reference answers 200 text/plain, the old server 404.
  • Planted bug: the MCP address written /mpc. The check fails at the root. Put back.
  • compare.mjs --steps 30 --seed 31 agrees, with the metrics' and log's routes; just quick passes here.
  • just gates is left to the pull's gates workflow.

Shortcomings

  • Plain text does not wrap, so on a phone the banner scrolls sideways, as the reference's does.
  • The code link points at a private repository, which knotless.dev answers 404 to anyone not signed in.
Approved

This adds GET /: a plain-text banner plus how to connect an AI app. The spec, harness and server agree. The text in ROOT matches the spec's block, including the empty first line and the trailing \n. svc.oauth.issuer is the origin of PDS_PUBLIC_URL, as the spec says. HEAD and the query are handled as written, and any other method gets 404. The new check compares status and Content-Type with the reference. It reads the expected text from the spec, so the two cannot drift. It also checks for RateLimit-* headers. / is added to the routes in the spec, ops.rs and observe.mjs. I saw nothing that loosens a check, and no reference source or new crates.

One small thing, which I would not hold the pull for: the README's paragraph on the operations checks (around line 77) names _health, metrics, spans and the log, but not the new root check. If the README lists what the run covers, add the root there.

Merged as 06819da