Skill Development

build-mcp-server

A Claude Code skill that guides developers through designing an MCP server. It asks about the use case, recommends a deployment model, tool-design pattern and framework, then scaffolds the server or hands off to specialized skills.

  • 37.6k GitHub stars
build-mcp-server — illustration

What it is

build-mcp-server is the entry point for MCP server development in the mcp-server-dev plugin. It triggers when a user asks to "build an MCP server", "create an MCP", "wrap an API for Claude", "expose tools to Claude", "make an MCP app", or otherwise discusses building with the Model Context Protocol. Its core principle is "discovery, not code": picking the wrong server shape early causes painful rewrites later. Before giving guidance, it fetches https://claude.com/docs/llms-full.txt so its advice reflects Claude-specific auth types, review criteria and limits, which go beyond the generic MCP spec. The workflow runs in phases. Phase 1 asks five questions in a single batched message: what the server connects to, who will use it, how many distinct actions it exposes, whether a tool needs mid-call user input or rich display, and what auth the upstream service uses. Phase 2 recommends one deployment model. A remote streamable-HTTP server is the default recommendation. The alternatives are elicitation for simple structured input, an MCP app for interactive UI widgets, MCPB for bundled local servers, and local stdio (npx/uvx), which is only suggested for personal tools and prototypes. Phase 3 picks a tool-design pattern. Pattern A gives one tool per action for small surfaces (under about 15 operations). Pattern B uses search + execute for large APIs so the context window stays lean. A hybrid promotes the 3–5 most-used actions to dedicated tools. Phase 4 recommends a framework: either the official TypeScript SDK (@modelcontextprotocol/sdk) or FastMCP 3.x for Python. Phase 5 scaffolds inline for remote HTTP without UI or for local stdio prototypes. For MCP apps it hands off to the build-mcp-app skill, and for MCPB it hands off to build-mcpb, restating the design brief so the next skill doesn't re-ask. The skill also covers the other server primitives (Resources, Prompts, Elicitation, Sampling) and includes a quick-reference decision matrix. Phase 6 covers testing and publishing: adding the server as a custom connector in Claude, running the pre-submission checklist, submitting to the Anthropic Directory, and shipping a plugin that wraps the MCP with skills. Supporting reference files cover remote HTTP scaffolding, Cloudflare Workers deployment, tool design, auth (OAuth, CIMD, DCR), resources and prompts, elicitation, server capabilities, and version-sensitive claims.

Who it's for

  • Developers building an MCP server that works with Claude
  • Developers wrapping a cloud API (SaaS, REST, GraphQL) for Claude
  • Developers who need a local server that touches files, desktop apps or OS-level APIs
  • Developers planning to submit a connector to the Anthropic Directory

Requirements

Requirements

  • Access to https://claude.com/docs/llms-full.txt, which the skill fetches for Claude-specific context
  • A framework: the official TypeScript SDK (@modelcontextprotocol/sdk) or FastMCP 3.x (fastmcp on PyPI)
  • For MCP app widgets: @modelcontextprotocol/ext-apps (via the build-mcp-app skill)
  • For elicitation: host support (Claude Code ≥2.1.76), plus a capability check and a fallback
  • For OAuth 2.0 upstream services: a remote server with CIMD (preferred) or DCR support

هاد السكيل بيمشي معك خطوة بخطوة لتصمّم MCP server بيشتغل منيح مع Claude. بيسألك عن شو بدك تعمل، وبينصحك بطريقة النشر والفريموورك وتصميم الأدوات، وبعدين يا بيبني السيرفر يا بيسلّمك لسكيل متخصص.

Examples

Trigger phrase

Prompt
prompt
build an MCP server

Expected output: One of the user requests listed in the skill description that activates this skill.

Trigger phrase for wrapping an API

Prompt
prompt
wrap an API for Claude

Expected output: Another listed trigger. The skill then asks its discovery questions before recommending a deployment model.

Pattern A: one tool per action

Code
text
create_issue    — Create a new issue. Params: title, body, labels[]
update_issue    — Update an existing issue. Params: id, title?, body?, state?
search_issues   — Search issues by query string. Params: query, limit?
add_comment     — Add a comment to an issue. Params: issue_id, body

What it does: Example tool list for a small action surface (under about 15 operations), where each action gets a dedicated tool with a tight description and schema.

Pattern B: search + execute

Code
text
search_actions  — Given a natural-language intent, return matching actions
                  with their IDs, descriptions, and parameter schemas.
execute_action  — Run an action by ID with a params object.

What it does: Two-tool pattern for large APIs. The server holds the full catalog internally, which keeps Claude's context lean.