feat(docs): MCP tools reference + interactive hub + overview diagram#40
Merged
Conversation
|
✅ CI - Verify PASSED Commit:
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
Interactive reference for the six frozen
memory__*MCP tools at/docs/mcp-tools, matching the look and interaction of the API reference shipped in #39 on/docs/rest-api.Each tool is a collapsible row: verb badge + mono
memory__<name>+ one-line summary + aLive · frozenchip. Expanded it shows the description, an Arguments table (name / type / required-default / description), a pretty-printed + syntax-highlighted Example input and Result (via the sharedjson-highlighttokenizer), and a one-line Behavior note where relevant.Contracts transcribed from
.mcpc.jsonAll input schemas, defaults, and constraints are transcribed verbatim from the CI-frozen snapshot at
agentage/web/packages/memory-mcp/.mcpc.json(the 6 tools:memory__search/read/list/write/edit/delete) - no fields invented. Result shapes follow each tool'soutputSchema. Collapsed-row summaries and the "Try it" prompts reuse the facts inlib/mcp-docs.ts(MCP_TOOLS,EXAMPLE_PROMPTS, endpoint/auth constants).Verb -> badge color:
search/read/list-> green (read),write-> amber,edit-> purple,delete-> red - reusing the same semantic tokens as the endpoint method badges.No copy-paste
Rather than duplicate the ~150-line accordion, this adds a sibling
toolsDocBlock and aToolListcomponent that reuses the existing subcomponents:SectionLabel(now exported fromendpoint-list.tsx), the sharedJsonBlock, and the chip/chevron/badge patterns. Only a 4-column arg table (the extra required-default column) is tool-specific. The/docs/rest-apipage and its data are untouched.Files
docs/types.ts-ToolArg/ToolContract/ToolGroup+{ type: 'tools' }DocBlocklib/mcp-tool-contracts.ts- the 6 contracts (new data module)components/docs/tool-list.tsx- the accordion (new)components/docs/endpoint-list.tsx- exportSectionLabel(1 line)docs/components/doc-article.tsx- wire thetoolsblockdocs/content/mcp-tools.ts- the page (new)docs/registry.ts+docs/nav.ts- register page; flip the "MCP tools" nav stub to real (CLI left as stub)Verify
npm run verifygreen (type-check + lint + format + test + build; 9 tests pass)next start:/docs/mcp-tools-> 200 with all 6 tool names,aria-expandedcount = 6, highlight spans present, 6Live · frozenchips;/docs/rest-api-> 200 unchanged.Note
The REST draft contract on
/docs/rest-apidocuments searchscoreas0-1relevance, while the MCPmemory__searchcontract (.mcpc.json) definesscoreas an integer match count. Different surfaces, expected - flagging for awareness, not changed here.MERGE ONLY AFTER review. This repo auto-deploys dev + prod on any push to master.