docs: document schema URL convention for MDX links#3641
Conversation
Adds docs/contributing/schema-links.md explaining that Markdown hyperlinks to AdCP JSON schemas must use absolute https://adcontextprotocol.org/schemas/v3/... URLs — bare paths fail the Mintlify link checker. Covers the released-vs-unreleased decision rule, the $schema-vs-hyperlink distinction, and the two CI validators. https://claude.ai/code/session_01MzMHhmkVpMuiLTnCVLpJWx
|
Pushing back on this PR — the convention it documents is wrong for the most common case.
Concretely: PR #3576 adds Documenting "use prod URLs" trains contributors into a habit that breaks exactly when they need links most. The right fix is environment-aware resolution, not a doc patch:
Three programmatic options, in increasing order of invasiveness:
Proposing:
cc @bokelley |
Closes #3634
Contributors writing MDX docs naturally reach for bare
/schemas/enums/foo.jsonpaths when linking to a JSON schema — it's how schemas are referenced everywhere else in the repo ($ref, changeset text, commit messages). But the Mintlify broken-links checker rejects bare paths: they're not Mintlify pages, they're external artifacts. The correct convention (use absolutehttps://adcontextprotocol.org/schemas/v3/...URLs) existed only in.agents/playbook.md, invisible to contributors.This PR adds the convention to contributor-facing docs in three places:
docs/contributing/schema-links.md(new) — full guidance page following the existingx-entity-annotation.md/testable-snippets.mdpattern. Covers released vs. unreleased schemas, the$schema-vs-hyperlink distinction, and both CI validators (mintlify broken-links+check-schema-links.yml).CONTRIBUTING.md— one-line pointer under "Schema conventions" linking to the new page.docs/building/schemas-and-sdks.mdx—<Note>cross-link at the Schema Versioning section, where contributors reading about schema URLs are most likely to need this guidance.Non-breaking justification: adds new docs/content only; no schema, protocol, or API surface changed; existing consumers unaffected.
Pre-PR review:
3.0.0-rc.3version ref →3.0.1; released schema used as "unreleased" example → replaced withcore/account-authorization.json); 1 nit (CONTRIBUTING.md link pattern) fixed; changeset verifiedSession: https://claude.ai/code/session_01MzMHhmkVpMuiLTnCVLpJWx
Generated by Claude Code