getmcp
AGENTS.md13 starsChanged 8 months agoMITView on GitHub
For the complete specification (schemas, transformation rules, config formats, research appendix), see SPECIFICATION.md. getmcp is a universal installer and configuration tool for MCP (Model Context Protocol) servers across all AI applications. Every AI app (Claude Desktop, VS Code, Cursor, Goose, Windsurf, Zed, etc.) uses a different config format for MCP servers — different root keys, field names, file formats, and conventions. getmcp solves this by defining a single canonical format (aligned with the official MCP registry schema), then using generators…
We split this AGENTS.md into the rules it gives an agent
12 rules. About 1 is common, 1 is distinctive, and 10 are very specific to this project.
≈1
Common · estimate
Many files like this have a rule of this kind.
≈1
Distinctive · estimate
This author's own choices. Worth a look.
10
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Very specific: line 57
Add the new app ID to the AppId enum in packages/core/src/schemas.ts
- Very specific: line 58
Create packages/generators/src/<app-name>.ts extending BaseGenerator
- Very specific: line 62
Add stdio + remote tests in packages/generators/tests/generators.test.ts
- Very specific: line 63
Add detection paths in packages/cli/src/detect.ts if the app has a known config file location
- Very specific: line 64
Update packages/web/src/components/ConfigViewer.tsx to include the new app tab
- Very specific: line 77
Add command aliases in packages/cli/src/utils.ts (COMMAND_ALIASES map) if the command should have shorthand names
- Very specific: line 79
Add tests in packages/cli/tests/
- Distinctive: line 83
After every code implementation (new feature, new command, new file, bug fix, refactor, etc.), review the following documentation files and …
- Very specific: line 99
Run all tests: npx vitest (from repo root)
- Very specific: line 100
Run per-package: npx vitest packages/core, npx vitest packages/generators, etc.
- Very specific: line 114
NEVER: add NODE_AUTH_TOKEN or NPM_TOKEN environment variables to the publish workflow
- Common: line 115
NEVER: create or store npm access tokens in repository secrets for publishing
≈ “Common” is an estimate: at least 1 in 5 of the 36,368 AGENTS.md 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
agent.md — getmcp Codebase Guide
For the complete specification (schemas, transformation rules, config formats, research appendix), see
SPECIFICATION.md.
Project Summary
getmcp is a universal installer and configuration tool for MCP (Model Context Protocol) servers across all AI applications. Every AI app (Claude Desktop, VS Code, Cursor, Goose, Windsurf, Zed, etc.) uses a different config format for MCP servers — different root keys, field names, file formats, and conventions. getmcp solves this by defining a single canonical format (aligned with the official MCP registry schema), then using generators to transform it into each app's native format. A registry of popular servers, a CLI for automated installation, and a web directory complete the toolchain.
Architecture Overview
This is a TypeScript monorepo (npm workspaces, ESM-only, Node >= 22.17) with 5 packages:
@getmcp/cli -----> @getmcp/generators -----> @getmcp/core
\----> @getmcp/registry -----> @getmcp/core
@getmcp/web -----> @getmcp/core + @getmcp/generators + @getmcp/registry| Package | npm Name | Purpose |
packages/core | @getmcp/core | Zod schemas, TypeScript types, utility functions (type guards, transport inference) |
packages/generators | @getmcp/generators | 19 config generators (one per AI app), each transforms canonical format to app-native format |
packages/registry | @getmcp/registry | Catalog of MCP server definitions with search/filter API |
packages/cli | @getmcp/cli | CLI tool: add, remove, list, find, check, update, doctor, import, sync, registry commands with app auto-detection, config merging, multi-registry support, and installation tracking via getmcp-lock.json |
packages/web | @getmcp/web | Next.js (App Router) web directory for browsing servers and generating config snippets, with Vercel Analytics and Speed Insights |
Tech stack: TypeScript 5.7+, Zod 4.0+, Vitest 3.0+, Next.js 15.3+ (web), Tailwind CSS 4.0+ (web), @clack/prompts (CLI). Linting/Formatting: oxlint + oxfmt, enforced via lefthook pre-commit hook.
See
.agents/docs/SPECIFICATION.mdSection 3 for the full architecture breakdown.
Key Concepts
- Canonical Format: Single format aligned with the official MCP registry schema (root key
mcpServers). Stdio:command,args,env,cwd,timeout,description. Remote:url,transport,headers,timeout,description. Transport auto-inferred from URL. - Generators: Extend
BaseGenerator(packages/generators/src/base.ts), implementgenerate()to transform canonical → app-native format. Each implementsdetectInstalled()for platform-specific app detection. - Registry:
Map<string, InternalRegistryEntry>keyed by official reverse-DNS name (e.g.io.github.github/github-mcp-server), with search and filtering functions.getServer()is ID-only; usegetServerBySlug()for slug lookups (web URLs). - CLI: Auto-detects installed apps, prompts for env vars, generates app-specific configs, and merges into existing files (never overwrites). Tracks installations in
getmcp-lock.json. - Design Principles: (1) Never overwrite (2) Canonical format as single source of truth (3) Auto-detect apps (4) Platform-aware path resolution (5) Schema-validated via Zod
See file-map.md for the complete file-by-file reference.
Common Tasks
MCP server registry
Server data is synced from the official MCP registry via packages/registry/scripts/sync.ts. To add a new server, submit it to the official registry — getmcp syncs automatically via the daily GitHub Actions workflow.
Adding a new generator (supporting a new AI app)
- Add the new app ID to the
AppIdenum inpackages/core/src/schemas.ts - Create
packages/generators/src/<app-name>.tsextendingBaseGenerator - Implement
generate()with the app's field mappings; overrideserialize()if non-JSON - Set the
appproperty withAppMetadata(id, name, configFileName, configPaths per platform, docsUrl) - Register the generator in
packages/generators/src/index.ts - Add stdio + remote tests in
packages/generators/tests/generators.test.ts - Add detection paths in
packages/cli/src/detect.tsif the app has a known config file location - Update
packages/web/src/components/ConfigViewer.tsxto include the new app tab
Modifying an existing generator's transformation rules
- Locate the generator file:
packages/generators/src/<app-name>.ts - Review its
generate()method to understand current field mappings - Make changes and run
npx vitest packages/generatorsto validate - Cross-reference with
.agents/docs/SPECIFICATION.mdSection 5 and Section 10 for the app's official format
Adding a CLI command
- Create
packages/cli/src/commands/<command>.ts - Wire it into
packages/cli/src/bin.tsargument dispatch using dynamicimport() - Add command aliases in
packages/cli/src/utils.ts(COMMAND_ALIASESmap) if the command should have shorthand names - Handle prompt cancellation using the
exitIfCancelled()helper frompackages/cli/src/utils.ts - Add tests in
packages/cli/tests/
Post-Implementation Documentation Check
After every code implementation (new feature, new command, new file, bug fix, refactor, etc.), review the following documentation files and update any that are affected:
| File | What to check |
CLAUDE.md | File map matches actual source files; test counts are accurate; common tasks sections reflect current workflow |
.agents/docs/SPECIFICATION.md | Schemas, command docs, transformation rules, test counts, and monorepo tree match the implementation. Do not add future plans here — all roadmap items belong in ROADMAP.md only |
.agents/docs/ROADMAP.md | Newly implemented items are marked [x] with a note about the implementing file. This is the single source of truth for all planned/future work |
packages/cli/README.md | New commands, flags, supported apps, and API exports are documented |
This is not optional — documentation drift causes confusion and wastes time. Treat it as part of completing the implementation.
Testing
- 720 tests across 30 test files
- Run all tests:
npx vitest(from repo root) - Run per-package:
npx vitest packages/core,npx vitest packages/generators, etc. - Test locations:
packages/core/tests/— schema validation (including RegistrySource, RegistryCredential, RegistryAuthMethod), type guards, transport inference, ProjectManifestpackages/generators/tests/— all 19 generators (stdio + remote + multi-server + serialization + detectInstalled)packages/registry/tests/— entry validation, lookup, search, categories, content integrity, fetch-metricspackages/cli/tests/— app-selection, bin flags, config-file I/O, credentials, detect, errors, format, lock file, preferences, registry-cache, registry-config, utilspackages/cli/tests/commands/— add, check, doctor, find, import, list, registry, remove, sync, update command tests
Publishing
Auto-release via conventional commits (.github/workflows/publish.yml). Uses OIDC trusted publishing — no tokens.
- NEVER add
NODE_AUTH_TOKENorNPM_TOKENenvironment variables to the publish workflow - NEVER create or store npm access tokens in repository secrets for publishing
See publishing.md for trigger paths, workflow steps, OIDC rules, and edge cases.
Commit Convention
Follows Conventional Commits v1.0.0. Scopes: core, generators, registry, cli, web. Breaking changes use ! or BREAKING CHANGE: footer.
See commit-convention.md for full types table and examples.
Installed Skills
Skills are installed under .agents/skills/. See the skill files for triggers and descriptions.
References
SPECIFICATION.md— Complete project specification: schemas, transformation rules per app, registry format, CLI behavior, research appendixROADMAP.md— Planned improvements and open tasksdesign-system.md— Web package design system: colors, fonts, typography, components, layout patterns, and OG image specscompetence.md— Competence analysiscss-scroll-spy.md— CSS scroll spy pattern: inline<style>technique required by Turbopack constraintfile-map.md— Complete file-by-file reference for all 5 packagespublishing.md— Auto-release workflow, OIDC trusted publishing, trigger paths, edge casescommit-convention.md— Conventional Commits types, scopes, and examplesexternal-apis.md— External API endpoints, data fetched, error handling, and official docs links- Repository:
https://github.com/RodrigoTomeES/getmcp
Where files are headingNew AGENTS.md files have more rules about keeping secrets out of the code, and fewer about code style.
Of the AGENTS.md files we read, the 28,693 first seen in the last six months, against the older ones: the kind of rule that gained most share, and the kind that lost most. About files like this in general, not this one, and an estimate, since a kind is a pattern in the words.
In this repository25 other files it gives its agents.
- .agents/skills/vercel-composition-patterns/AGENTS.mdAGENTS.md
- .agents/skills/vercel-react-best-practices/AGENTS.mdAGENTS.md
- .claude/skills/vercel-composition-patterns/AGENTS.mdAGENTS.md
- .claude/skills/vercel-react-best-practices/AGENTS.mdAGENTS.md
- llms.txtllms.txt
- accessibilitySkill
- agent-browserSkill
- best-practicesSkill
- core-web-vitalsSkill
- find-skillsSkill
- frontend-designSkill
- performanceSkill
- react-doctorSkill
- seoSkill
- tailwind-design-systemSkill
- vercel-composition-patternsSkill
- vercel-react-best-practicesSkill
- web-design-guidelinesSkill
- web-quality-auditSkill
- agent-browserSkill
- find-skillsSkill
- frontend-designSkill
- vercel-composition-patternsSkill
- vercel-react-best-practicesSkill
- web-design-guidelinesSkill
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
Reviews can't be read right now.
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.

