Claude Code
Native transport, connects straight to /mcp.
eswat2-mcp
One FastAPI app, two transports, five layers — from client transport down to the source-of-truth content it serves.
config.yaml — server identity
eswat2:// schemeNative transport, connects straight to /mcp.
Via mcp-remote proxy, forwarding to /mcp.
Plain requests against the REST routes below.
./start.sh runs the app in the background; override with MCP_PORT.
api/index.py imports app from src/server.py. Live at eswat2-mcp.vercel.app.
Same FastAPI instance either way — deployment only changes the entrypoint, not the app.
REST API
Discovery
Namespaces & content
Search & graph
Pages & ops
FastMCP — mounted at /mcp
Resources
Tools
Static mounts
/gallery → assets/gallery /fontsAuto docs
/docs /openapi.json FastAPI defaults, generated from the routes aboveNamespaces & entries
all_namespaces()has_namespace()list_slugs()get_entry() / load_content()Tags
list_tags()entries_by_tag()URI & stats
parse_uri()kb_stats()total_entry_count()Loads compiled kbs/*.json into memory at import time. Namespace-aware URI parsing (namespace://slug) backs both the REST and MCP layers above.
Source of truth — modules/
Compiled — kbs/
Build is an offline step (task build → scripts/build_all.py, which runs build_kb.py + build_thumbs.py) — not a live request-time dependency.