openpencil/packages/mcp/AGENTS.md
Danila Poyarkov b0231927c5
docs: route contributors through per-domain guides and ship npm license text (#785)
Root AGENTS.md becomes a map plus cross-cutting rules; folder rules live in one AGENTS.md per package and top-level folder, checked by check:docs. CONTRIBUTING.md owns process; README and the docs page link to it. Release preparation copies the root LICENSE into every published package, Core, CLI, and MCP gain READMEs, and the release workflow test packs its fixture in-process instead of through npm.
2026-09-29 01:02:06 +04:00

1,002 B

MCP server

stdio and Hono HTTP MCP server that reuses Core tools (packages/core/AGENTS.md, Tools).

  • MCP-only filesystem and server tools live in packages/mcp/src/tool/registration.ts; listener and session lifecycle under packages/mcp/src/server/, stdio under packages/mcp/src/stdio/, transport discovery under packages/mcp/src/transport/.
  • Registration uses Standard Schema with Valibot JSON Schema conversion from the Core tool input contract; per-tool exposure comes from isToolExposed().
  • File access must resolve symlinks inside the effective MCP root. CLI defaults are the current directory on macOS and Linux and the home directory on Windows.
  • Keep browser lifecycle out of this package and out of Core.
  • Transport tests live under tests/engine/mcp/{server,stdio,transport} with shared fixtures under tests/helpers/mcp; isolate tests from user runtime discovery. Playwright starts the development MCP companion through the Vite automation plugin; see tests/AGENTS.md.