MCP Server Builder
anthropics/skills
Guides the design and implementation of Model Context Protocol servers in TypeScript or Python, from tool naming and error messages to evaluation.
Walks through building MCP servers in Python or TypeScript that expose tools, resources and prompts to Claude, with templates, registration and testing.
$ npx skills add shareAI-lab/learn-claude-code --skill mcp-builder -a claude-codeProject install by default; add -g for ~/.claude/skills/.
$ gh skill install shareAI-lab/learn-claude-code mcp-builder --agent claude-codeProject scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).
$ git clone --depth 1 https://github.com/shareAI-lab/learn-claude-code.git skills-src && mkdir -p .claude/skills && cp -r skills-src/skills/mcp-builder .claude/skills/mcp-builder && rm -rf skills-srcUse ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.
Claude Code skills documentation · loads skills from .claude/skills/
Install the "mcp-builder" agent skill from https://github.com/shareAI-lab/learn-claude-code/tree/main/skills/mcp-builder into .claude/skills/mcp-builder/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "mcp-builder", then confirm the skill loads.Claude Code copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$skill-installer install https://github.com/shareAI-lab/learn-claude-code/tree/main/skills/mcp-builderType this inside Codex. $skill-installer <name> installs a curated skill from openai/skills. The installer writes to $CODEX_HOME/skills (default ~/.codex/skills). Restart Codex if the skill does not show up.
$ npx skills add shareAI-lab/learn-claude-code --skill mcp-builder -a codexProject install goes to .agents/skills/; add -g for ~/.codex/skills/.
$ gh skill install shareAI-lab/learn-claude-code mcp-builder --agent codexProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/shareAI-lab/learn-claude-code.git skills-src && mkdir -p .agents/skills && cp -r skills-src/skills/mcp-builder .agents/skills/mcp-builder && rm -rf skills-srcUse ~/.agents/skills/ instead of .agents/skills for a personal install.
Codex skills documentation · loads skills from .agents/skills/
Install the "mcp-builder" agent skill from https://github.com/shareAI-lab/learn-claude-code/tree/main/skills/mcp-builder into .agents/skills/mcp-builder/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "mcp-builder", then confirm the skill loads.Codex copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ npx skills add shareAI-lab/learn-claude-code --skill mcp-builder -a cursorProject install goes to .agents/skills/; add -g for ~/.cursor/skills/.
$ gh skill install shareAI-lab/learn-claude-code mcp-builder --agent cursorProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/shareAI-lab/learn-claude-code.git skills-src && mkdir -p .cursor/skills && cp -r skills-src/skills/mcp-builder .cursor/skills/mcp-builder && rm -rf skills-srcUse ~/.cursor/skills/ instead of .cursor/skills for a personal install.
Cursor skills documentation · loads skills from .cursor/skills/, .agents/skills/, .claude/skills/, .codex/skills/
Install the "mcp-builder" agent skill from https://github.com/shareAI-lab/learn-claude-code/tree/main/skills/mcp-builder into .cursor/skills/mcp-builder/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "mcp-builder", then confirm the skill loads.Cursor copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ gemini skills install https://github.com/shareAI-lab/learn-claude-code.git --path skills/mcp-builder--scope user (default) or --scope workspace; --path is the subfolder of the repo that holds the skill; --consent skips the security confirmation prompt.
$ npx skills add shareAI-lab/learn-claude-code --skill mcp-builder -a gemini-cliProject install goes to .agents/skills/; add -g for ~/.gemini/skills/.
$ gh skill install shareAI-lab/learn-claude-code mcp-builder --agent gemini-cliProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/shareAI-lab/learn-claude-code.git skills-src && mkdir -p .gemini/skills && cp -r skills-src/skills/mcp-builder .gemini/skills/mcp-builder && rm -rf skills-srcUse ~/.gemini/skills/ instead of .gemini/skills for a personal install, then run /skills reload.
Gemini CLI skills documentation · loads skills from .gemini/skills/, .agents/skills/
Install the "mcp-builder" agent skill from https://github.com/shareAI-lab/learn-claude-code/tree/main/skills/mcp-builder into .gemini/skills/mcp-builder/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "mcp-builder", then confirm the skill loads.Gemini CLI copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ gh skill install shareAI-lab/learn-claude-code mcp-builderInstalls for Copilot at project scope by default; add --scope user for a personal install. Preview a skill first with gh skill preview. Needs GitHub CLI 2.90.0 or later (public preview).
$ npx skills add shareAI-lab/learn-claude-code --skill mcp-builder -a github-copilotProject install goes to .agents/skills/; add -g for ~/.copilot/skills/.
$ git clone --depth 1 https://github.com/shareAI-lab/learn-claude-code.git skills-src && mkdir -p .github/skills && cp -r skills-src/skills/mcp-builder .github/skills/mcp-builder && rm -rf skills-srcUse ~/.copilot/skills/ instead of .github/skills for a personal install. Commit .github/skills so cloud agent and code review can use it.
GitHub Copilot skills documentation · loads skills from .github/skills/, .claude/skills/, .agents/skills/
Install the "mcp-builder" agent skill from https://github.com/shareAI-lab/learn-claude-code/tree/main/skills/mcp-builder into .github/skills/mcp-builder/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "mcp-builder", then confirm the skill loads.GitHub Copilot copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ npx skills add shareAI-lab/learn-claude-code --skill mcp-builder -a opencodeOpenCode documents no install command of its own. Project install goes to .agents/skills/; add -g for ~/.config/opencode/skills/.
$ gh skill install shareAI-lab/learn-claude-code mcp-builder --agent opencodeProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/shareAI-lab/learn-claude-code.git skills-src && mkdir -p .opencode/skills && cp -r skills-src/skills/mcp-builder .opencode/skills/mcp-builder && rm -rf skills-srcUse ~/.config/opencode/skills/ instead of .opencode/skills for a personal install.
OpenCode skills documentation · loads skills from .opencode/skills/, .claude/skills/, .agents/skills/
Install the "mcp-builder" agent skill from https://github.com/shareAI-lab/learn-claude-code/tree/main/skills/mcp-builder into .opencode/skills/mcp-builder/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "mcp-builder", then confirm the skill loads.OpenCode copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
mcp-builderWalks through building MCP servers in Python or TypeScript that expose tools, resources and prompts to Claude, with templates, registration and testing.
MCP servers can expose three things: tools Claude can call like API endpoints, resources it can read like files or records, and prompt templates. A Python quick start covers project setup with a virtual environment, a basic server template and registering the server in Claude's mcp.json file, and a TypeScript path starts from npm init and the @modelcontextprotocol/sdk package with a template of its own.
Advanced patterns follow for wrapping an external API with httpx, reading from a sqlite3 database and serving read-only resources. Testing uses the MCP Inspector against the running server. Best practices are clear tool descriptions, validated and sanitized input, meaningful error messages, async I/O, authentication for sensitive operations and tools that are safe to retry.
5 steps, taken from the step headings in SKILL.md.
Read from SKILL.md and the folder at commit ce8f9f1. It shows what the files ask for, not the result of running them.
Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.
From allowed-tools in the SKILL.md frontmatter.
Shell commands in SKILL.md call:
python3npmpipnpxFrom the folder's file list and the shell code blocks in SKILL.md.
Hosts in commands or code, which the agent is likely to contact:
api.weatherapi.comFrom URLs in SKILL.md, links to its own repository left out.
Names no API keys, tokens, secrets or passwords.
From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.
MCP Server Builder loads about 1.2k tokens when it runs. Until then it costs about 47 tokens; SKILL.md has 147 words of instructions outside code blocks.
Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.
The automated check found no risky patterns in SKILL.md.
Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.
The full file from shareAI-lab/learn-claude-code at commit ce8f9f1, republished under its MIT licence (© shareAI-lab). 147 words, ~1,230 tokens.
.claude/skills/mcp-builder/SKILL.md (or your agent's skills folder).You now have expertise in building MCP (Model Context Protocol) servers. MCP enables Claude to interact with external services through a standardized protocol.
MCP servers expose:
# Create project
mkdir my-mcp-server && cd my-mcp-server
python3 -m venv venv && source venv/bin/activate
# Install MCP SDK
pip install mcp#!/usr/bin/env python3
"""my_server.py - A simple MCP server"""
from mcp.server import Server
from mcp.server.stdio import stdio_server
from mcp.types import Tool, TextContent
# Create server instance
server = Server("my-server")
# Define a tool
@server.tool()
async def hello(name: str) -> str:
"""Say hello to someone.
Args:
name: The name to greet
"""
return f"Hello, {name}!"
@server.tool()
async def add_numbers(a: int, b: int) -> str:
"""Add two numbers together.
Args:
a: First number
b: Second number
"""
return str(a + b)
# Run server
async def main():
async with stdio_server() as (read, write):
await server.run(read, write)
if __name__ == "__main__":
import asyncio
asyncio.run(main())Add to ~/.claude/mcp.json:
{
"mcpServers": {
"my-server": {
"command": "python3",
"args": ["/path/to/my_server.py"]
}
}
}mkdir my-mcp-server && cd my-mcp-server
npm init -y
npm install @modelcontextprotocol/sdk// src/index.ts
import { Server } from "@modelcontextprotocol/sdk/server/index.js";
import { StdioServerTransport } from "@modelcontextprotocol/sdk/server/stdio.js";
const server = new Server({
name: "my-server",
version: "1.0.0",
});
// Define tools
server.setRequestHandler("tools/list", async () => ({
tools: [
{
name: "hello",
description: "Say hello to someone",
inputSchema: {
type: "object",
properties: {
name: { type: "string", description: "Name to greet" },
},
required: ["name"],
},
},
],
}));
server.setRequestHandler("tools/call", async (request) => {
if (request.params.name === "hello") {
const name = request.params.arguments.name;
return { content: [{ type: "text", text: `Hello, ${name}!` }] };
}
throw new Error("Unknown tool");
});
// Start server
const transport = new StdioServerTransport();
server.connect(transport);import httpx
from mcp.server import Server
server = Server("weather-server")
@server.tool()
async def get_weather(city: str) -> str:
"""Get current weather for a city."""
async with httpx.AsyncClient() as client:
resp = await client.get(
f"https://api.weatherapi.com/v1/current.json",
params={"key": "YOUR_API_KEY", "q": city}
)
data = resp.json()
return f"{city}: {data['current']['temp_c']}C, {data['current']['condition']['text']}"import sqlite3
from mcp.server import Server
server = Server("db-server")
@server.tool()
async def query_db(sql: str) -> str:
"""Execute a read-only SQL query."""
if not sql.strip().upper().startswith("SELECT"):
return "Error: Only SELECT queries allowed"
conn = sqlite3.connect("data.db")
cursor = conn.execute(sql)
rows = cursor.fetchall()
conn.close()
return str(rows)@server.resource("config://settings")
async def get_settings() -> str:
"""Application settings."""
return open("settings.json").read()
@server.resource("file://{path}")
async def read_file(path: str) -> str:
"""Read a file from the workspace."""
return open(path).read()# Test with MCP Inspector
npx @anthropics/mcp-inspector python3 my_server.py
# Or send test messages directly
echo '{"jsonrpc":"2.0","id":1,"method":"tools/list"}' | python3 my_server.py© shareAI-lab, MIT. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file
Just SKILL.md in skills/mcp-builder of shareAI-lab/learn-claude-code.
Open the folder on GitHubat commit ce8f9f1
We found 6 copies of this SKILL.md (exact, near-identical or edited) in other folders, from 5 other GitHub owners. This page covers the copy in shareAI-lab/learn-claude-code, which our catalogue first saw on October 7, 2026.
MCP Server Builder next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.
| Skill | Stars | Used in | Tokens | Auto-check | Licence | Repo updated |
|---|---|---|---|---|---|---|
| MCP Server Builder this skillshareAI-lab/learn-claude-code | 78k | 5 repos | ~1.2k | Automated safety check: Pass | MIT | |
| MCP Server Builderanthropics/skills | 180k | 63 repos | ~2.3k | Automated safety check: Pass | Apache-2.0 | |
| Zizkadb ReleaseZIZKA-AI-SL/ZizkaDB | 125 | — | ~399 | Automated safety check: Pass | Custom licence | |
| Nevermined PaymentsLeoYeAI/openclaw-master-skills | 2.2k | — | ~4.5k | Automated safety check: Notes | MIT | |
| LexGuard MCP Developer GuideSeoNaRu/lexguard-mcp | 131 | — | ~1.1k | Automated safety check: Pass | Custom licence | |
| Context7 MCP Skillholon-run/uxc | 116 | — | ~564 | Automated safety check: Pass | MIT |
anthropics/skills
Guides the design and implementation of Model Context Protocol servers in TypeScript or Python, from tool naming and error messages to evaluation.
ZIZKA-AI-SL/ZizkaDB
Bumps versions, runs pre-push verification, and publishes ZizkaDB SDK and MCP packages.
LeoYeAI/openclaw-master-skills
Integrates Nevermined payment infrastructure into AI agents, MCP servers, Google A2A agents, and REST APIs.
SeoNaRu/lexguard-mcp
Developer guide for the LexGuard Korean law MCP server: layer rules, adding tools and repositories, JSON-RPC responses, law API handling, answer rules and tests.
holon-run/uxc
Query up-to-date library documentation and code examples using Context7 MCP.
shareAI-lab/Kode-CLI
Guide to designing and building MCP servers: tool, resource and prompt design for agent usability, with TypeScript or Python implementation workflows.
shareAI-lab/learn-claude-code
Design and build AI agents for any domain. An agent skill from shareAI-lab/learn-claude-code.
shareAI-lab/learn-claude-code
Reviews code against a five-part checklist covering security, correctness, performance, maintainability and testing, and reports findings in a fixed format.
shareAI-lab/learn-claude-code
Gives the agent command-line and Python recipes for reading, creating, merging and splitting PDF files, plus tips for large and scanned documents.
Categories
Walks through building MCP servers in Python or TypeScript that expose tools, resources and prompts to Claude, with templates, registration and testing. MCP servers can expose three things: tools Claude can call like API endpoints, resources it can read like files or records, and prompt templates.json file, and a TypeScript path starts from npm init and the @modelcontextprotocol/sdk package with a template of its own.
MCP Server Builder fits situations like: creating an MCP server that wraps an external service; adding custom tools to Claude through MCP; exposing database content to an agent as read-only resources; testing an MCP server with the Inspector.
Run `npx skills add shareAI-lab/learn-claude-code --skill mcp-builder -a claude-code`. Or copy the skill folder (skills/mcp-builder in shareAI-lab/learn-claude-code) into .claude/skills/mcp-builder in your project. Claude Code loads it when a task matches its description.
Run `npx skills add shareAI-lab/learn-claude-code --skill mcp-builder -a codex`. Or copy the skill folder (skills/mcp-builder in shareAI-lab/learn-claude-code) into .agents/skills/mcp-builder in your project. Codex loads it when a task matches its description.
Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add shareAI-lab/learn-claude-code --skill mcp-builder -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/mcp-builder, .gemini/skills/mcp-builder, .github/skills/mcp-builder and .opencode/skills/mcp-builder in your project.
Going by SKILL.md and its folder, MCP Server Builder needs the command-line tools its instructions call (python3, npm, pip and npx). Our summary lists: Python 3 or Node.js with npm, depending on the server language.
SKILL.md names 1 domain. In commands or code: api.weatherapi.com; the agent is likely to contact it when it follows the instructions. This is read from the text; nothing was executed.
Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. Review the folder before installing.
MCP Server Builder is published under the MIT licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.
About 1.2k tokens (SKILL.md is roughly 4.9k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full.
Skills that share tags, products or a category with MCP Server Builder: MCP Server Builder (anthropics/skills, 180k stars), Zizkadb Release (ZIZKA-AI-SL/ZizkaDB, 125 stars), Nevermined Payments (LeoYeAI/openclaw-master-skills, 2.2k stars) and LexGuard MCP Developer Guide (SeoNaRu/lexguard-mcp, 131 stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.
shareAI-lab (a GitHub organization) maintains it in shareAI-lab/learn-claude-code, which has 78,211 GitHub stars. The repository holds 4 skills in this directory. The repository was last updated on September 28, 2026.
Source: shareAI-lab/learn-claude-code on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.