mcp-tool-generator
Skill0 starsChanged 8 months agoMITView on GitHub
Generate a TypeScript MCP server with frontend tools for each discovered application feature. Uses @modelcontextprotocol/ext-apps for tool registration and @mcp-ui/server for UI content. Reads feature maps from feature-mapper and optionally code maps from code-correlator. Use when asked to: generate MCP tools, create frontend MCP, build MCP server, create tools for this app, generate mcp-ui tools, build tool server.
1 other project uses a version of this.
Adopted by
Most recently taken up by
- patonkikh/APEStheir own version, first seen Jul 3, 2026
Other versions1 project uses a version of this.
Word for word · 0
None found.
Edited · 0
None found.
Wrote their own version · 1
- patonkikh/APES★ 3same name
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
In this repository3 other files it gives its agents.
- app-explorerSkill
- code-correlatorSkill
- feature-mapperSkill
The file
We split this skill into the rules it gives an agent
12 rules. About 0 are common, 5 are distinctive, and 7 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈5
Distinctive · estimate
This author's own choices. Worth a look.
7
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Very specific: line 24
If no feature map is found, stop and instruct the user to run feature-mapper first.
- Very specific: line 25
If available, load code map JSON from .claude/artifacts/code-map-*/.
- Distinctive: line 26
If code map is missing, continue without code references.
- Very specific: line 57
Follow patterns in references/server-scaffold.md.
- Very specific: line 62
Use registerAppTool() and registerAppResource() for each feature UI.
- Very specific: line 63
Use createUIResource() with only:
- Very specific: line 69
Run tsc --noEmit against generated output.
- Distinctive: line 70
Ensure imports resolve and generated types are valid.
- Distinctive: line 74
Write generated server into:
- Distinctive: line 90
Use for form confirmations, action status, compact tables, and small result panes.
- Distinctive: line 93
Use for dashboards, full-page workflows, and complex interactive views.
- Very specific: line 98
When feature handlers need browser interaction (form fill, click, navigation), generate compatibility-safe Chrome MCP calls.
≈ “Common” is an estimate: at least 1 in 5 of the 350,495 skill 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
MCP Tool Generator
Overview
This skill generates a complete TypeScript MCP server from feature documentation created by feature-mapper. It uses @modelcontextprotocol/ext-apps for tool and resource registration and @mcp-ui/server for UI content generation. The output contains one tool per discovered feature, with content limited to rawHtml and externalUrl.
Prerequisites
- Feature map exists at
.claude/artifacts/feature-map-*/(required). - Code map exists at
.claude/artifacts/code-map-*/(optional enrichment). - Node.js + TypeScript environment is available for generated server validation.
- Pipeline
1 -> 2 -> 4is supported (you can skipcode-correlator).
Generation Workflow
Step 1: Read Input
- Load feature map JSON from
.claude/artifacts/feature-map-*/. - If no feature map is found, stop and instruct the user to run
feature-mapperfirst. - If available, load code map JSON from
.claude/artifacts/code-map-*/. - If code map is missing, continue without code references.
Step 2: Categorize Features
- Group features by behavior type:
- form submission
- navigation
- data display
- action trigger
Step 3: Determine Content Types
- Apply mapping rules from
references/input-format.md:dashboard/reporting->externalUrlform/crud/settings->rawHtmlnavigation/search->externalUrl- other ->
externalUrl(safe default)
Step 4: Generate Tool Definitions
- For each feature, generate:
- tool name from
feature.id - tool description from feature name + description
inputSchemafromfeature.actions- handler definition with selected content type
- tool name from
- Enforce a hard cap of 50 tools per generated server.
Step 5: Generate Server Scaffold
- Copy scaffold files from
assets/mcp-server-template/. - Inject generated registrations into
src/index.ts. - Follow patterns in
references/server-scaffold.md.
Step 6: Generate Tool Handlers
- Generate one handler per tool using
references/tool-templates.md. - Use
registerAppTool()andregisterAppResource()for each feature UI. - Use
createUIResource()with only:rawHtmlexternalUrl
Step 7: Validate
- Run
tsc --noEmitagainst generated output. - Ensure imports resolve and generated types are valid.
Step 8: Save Output
- Write generated server into:
.claude/artifacts/mcp-server-{timestamp}/
API Overview
McpServerfrom@modelcontextprotocol/sdk: base MCP server instance.registerAppTool()from@modelcontextprotocol/ext-apps: registers tool definitions with app-aware metadata.registerAppResource()from@modelcontextprotocol/ext-apps: registers UI resources for host retrieval.createUIResource()from@mcp-ui/server: constructs UI resources from allowed content types.
For full signatures and examples, read references/mcp-ui-api.md.
Content Types
rawHtml- Inline HTML rendered in chat.
- Use for form confirmations, action status, compact tables, and small result panes.
externalUrl- iframe-based URL rendering.
- Use for dashboards, full-page workflows, and complex interactive views.
remoteDomis not used by this skill.
Chrome MCP Integration
When feature handlers need browser interaction (form fill, click, navigation), generate compatibility-safe Chrome MCP calls. Do not hardcode tool prefixes. Use references/chrome-mcp-compat.md for runtime mapping across available Chrome MCP variants.
Output
Generated MCP server output is written to .claude/artifacts/mcp-server-{timestamp}/.
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.

