← ClaudeAtlas

mcp-server-scaffoldlisted

Scaffold and smoke-test a minimal local stdio MCP server with one tool in TypeScript or Python. Use when the user asks to build an MCP server, expose a local tool to Claude Code or Cursor, configure mcp.json, add Model Context Protocol tooling, debug a stdio MCP server, or connect an agent to a local API.
qingsongcui/claude-code-skills · ★ 0 · AI & Automation · score 70
Install: claude install-skill qingsongcui/claude-code-skills
# MCP server scaffold Build the smallest server that a host can attach to: **one tool, stdio transport, one observed success, one observed failure**. Do not start with OAuth, HTTP/SSE, database state, or a marketplace listing. Use the current official build guide for SDK setup and API signatures: <https://modelcontextprotocol.io/docs/develop/build-server>. ## Select the language from the existing project | Existing project | Default | Do not assume | |---|---|---| | Node/TypeScript project | TypeScript | Node version or package manager — inspect its manifest | | Python project | Python | SDK version — inspect `pyproject.toml`/requirements | | Empty directory | Ask before generating | The user’s runtime, deployment, and packaging needs | Do not mix both SDKs into a single “starter.” One language, one executable entry point, one tool. ## Server contract 1. Give the server a stable name and version. 2. Register one tool with a narrow input schema. 3. Return a structured, user-readable error for invalid input; do not expose a stack trace as tool output. 4. Connect over stdio. 5. Send all diagnostics to **stderr**. Stdout is the JSON-RPC transport and any log line corrupts it. The stdout rule is from the official MCP build guide: <https://modelcontextprotocol.io/docs/develop/build-server>. ## Minimal project shape TypeScript: ```text mcp-hello/ ├── package.json ├── tsconfig.json └── src/index.ts ``` Python: ```text mcp-hello/ ├── pyproject.toml └── src/mcp_hello/serve