Repository navigation
Description
Migrated from jimhoyd-com/urlcode-docs#18, which is being closed along with that repository. Re-validated against this repository's current main before filing — the original is partly valid, partly already fixed, and it surfaces one live defect here that nobody has caught.
What holds up
The capability claim is correct and I re-verified it in schemas/urlcode.schema.json at current main:
$defs.route.properties.auth— "Short form for a route protected by the declared auth extension.trueor an object expands topolicies.extensions.authwith the same keys minusrequired;required: falseemits no policy. Refused without anextensions.authdeclaration or alongsidepolicies.extensions.auth."$defs.routeAuth.properties— exactlyrequired,role,permission,verified,freshWithinSeconds,onDeny, withadditionalProperties: false.$defs.route.properties.cache— "Short form forpolicies.cache… Refused alongsidepolicies.cache; use one form."
So role is singular, the key set is closed, and a reader guessing roles gets a validation failure. That part of the original is exactly right.
What no longer applies
The original was filed as "a gap on the public site specifically — the documentation home that AGENTS.md says readers are sent to." That premise is gone: urlcode-docs is being retired and docs/ here is the documentation home. It is also largely fixed here already:
docs/POLICIES.md:44-56introduces both short forms by name, explains thecacheexpansion and its refusal condition, and shows a runnable example.docs/EXTENSIONS.md:44showsauth: {role: member}withauth: truein a trailing comment;:56-57lists the accepted keys includingfreshWithinSecondsandonDeny.docs/AI-AUTHORING.md:124-129gives the short form and then states outright that "there is noroles".docs/YAML-REFERENCE.md:259-272generates the full field table for bothroutes.*.authandroutes.*.cachestraight from the schema.scripts/check-guidance-claims.ts— the gate the original said the site lacked — exists here and runs innpm run check.
So the "not documented" framing does not survive the move. Closing it unexamined would have been wrong too, because of the next part.
The live defect it surfaces
docs/NEXT-STEPS.md:500 still says:
Fixes: protecting a route today is
policies: { extensions: { auth: {} } }, which is the mechanism, not the intent. The form an agent should write isauth: { required: true, roles: [admin] }.
roles is not a key. routeAuth sets additionalProperties: false, so that YAML is rejected by the validator — and the sentence presents it in the present tense as the form to write. This is precisely the defect the original reported against docs/PROJECT-DIRECTION.md and that #160 fixed; this instance was missed. docs/SPIKE-CORE-LAYERING.md:229 echoes it as "auth: { required: true, roles: [...] } direction".
There is a mitigating nuance worth stating rather than hiding: NEXT-STEPS.md is a plan document written before the feature shipped, and the surrounding "Work:" bullet is describing proposed work. But the feature shipped with role singular, and line 500 reads as guidance, not as a dated proposal. It needs the shape corrected or the section marked delivered-with-a-different-shape — the same treatment this repository already gives stale spike claims.
Why the gate did not catch it
scripts/check-guidance-claims.ts scans a fixed list of 7 agent-facing files:
starters/default/AGENTS.md
skills/urlcode/SKILL.md
.claude/skills/urlcode-{authoring,operations}/SKILL.md
packaging/claude-plugin/skills/urlcode-{authoring,operations}/SKILL.md
docs/AI-AUTHORING.md
docs/NEXT-STEPS.md, docs/PROJECT-DIRECTION.md, docs/EXTENSIONS.md and docs/POLICIES.md are not in it. Those are the pages a human reader is most likely to copy YAML from. The original's own diagnosis — a gap persists where no gate reaches — turns out to apply to this repository too, not only to the site.
Proposed work
- Fix
docs/NEXT-STEPS.md:500toauth: { required: true, role: admin }, or mark the section as delivered with the shipped shape. Same for the echo indocs/SPIKE-CORE-LAYERING.md:229. - Widen
check-guidance-claims.ts'staught-fieldrule beyond the 7 agent-facing files to any Markdown containing a fencedyamlblock, so a schema-invalid example in reader-facing prose fails the build. That is the durable fix; item 1 alone leaves the next instance to chance. - Optional: state the two
authrefusal conditions indocs/POLICIES.mdprose. It currently spells out the refusal forcachebut only implies it forauth("when the project declares an auth extension").
Not established
I did not check whether widening the checker to all fenced yaml blocks produces false positives on intentionally-invalid examples (docs that show a rejected form on purpose). That should be measured before item 2 is implemented, not assumed.
Activity
Carry trust-by-default into the CLI, the recipes and the checker (#170)
jimhoyd commentedon Sep 20, 2026
Revalidated during the bca8ac7 codebase audit (macOS, Node 26.8.2). The original NEXT-STEPS example is now archived, but the broader executable-documentation gap remains in live guides:
docs/yaml/policies.md:18:page: {source: pages/index.html}must usefile. The complete fenced project fails at/routes/~1/page (required).docs/policies/compression.md:35:secret: api-keyfails the binding-name pattern; use an admitted identifier such asapi_key. The complete fenced project fails at/routes/~1api~1report/secrets/KEY/secret (pattern).docs/AI-AUTHORING.md:249:webhooks/stripelacks its leading slash; schema-only validation accepts the object but route compilation rejects the path. The same section still lists removedlinkas a native handler (line 236).Scanned 64 YAML fences in tracked non-archive/non-spike Markdown; identified 49 route/project-shaped candidates. After adding only omitted
version: "1"or the documented routes wrapper, schema validation found the two broken complete examples above plus the deliberately partial profile illustration in docs/POLICIES.md:169 (excluded from defects). This is not an execution check of all prose fragments.npm run checkstill passes. Add classified snippet fixtures (complete, fragment, intentionally invalid) and semantic route validation, not just field-name regexes. Keeping this evidence on #168 rather than filing a duplicate coverage issue.Catch schema-invalid YAML examples in all documentation prose
Close the actionable parts of the open issues (#195)
jimhoyd commentedon Sep 20, 2026
All three proposed items are now on
mainvia #195.Already fixed before this work.
docs/NEXT-STEPS.mdhas since been archived todocs/archive/2026-09-19/NEXT-STEPS.mdand carries an explicit correction notingroleis singular and that the pluralrolesthis plan proposed is rejected by the validator. Thedocs/SPIKE-CORE-LAYERING.md:229echo is gone.Done, and the false-positive question this issue raised was measured rather than assumed.
scripts/check-guidance-claims.tsgains a fourth rule,closed-object-keys, over every authored Markdown file. Measurement:The 14 are all name collisions across nesting depths —
page: {from: query, name: page}is a function argument namedpage, not thepagehandler, andauth: {signedIn: true}is an extension's own policy underpolicies.extensions, not the closedrouteAuth. So the suspicion recorded under "Not established" was correct: a naive widening does produce false positives on intentionally-different shapes. Requiring at least one declared key beside the undeclared one identifies the mapping as the closed shape, drops all 14, and still catches this issue's defect, whererequiredsits besideroles.Two defects surfaced while implementing. The script's header had always documented that a marker on its own line exempts the following paragraph, but the code only matched within a paragraph — and the new rule needs it, since a fenced block cannot hold an HTML comment without the comment becoming part of the example. And a plain recursive walk descended into
.claude/worktrees, where each entry is a full second copy of the repository.Done.
docs/POLICIES.mdnow states all threeauthshort-form refusal conditions, verified againstsrc/config.ts:165-168: noextensions.authdeclared,policies.extensions.authalso set, orpolicies.extensions: false.Closing.
Reconcile readiness register, roadmap and open decisions with current…
Reconcile readiness register, roadmap and open decisions with current…