MCP (Model Context Protocol) server builder — guides creation of high-quality MCP servers in Python (FastMCP) or TypeScript (MCP SDK). Use when building inte...
Version: 1.1.0 | Author: Shadows Company | License: MIT
Requires at least one of: python/python3/uv (for Python MCP servers) or node (for TypeScript MCP servers). The skill auto-detects the user's preferred stack based on available binaries.
fastmcp package (pip install fastmcp). Optional: httpx for HTTP clients, pytest for testing.@modelcontextprotocol/sdk and zod packages (npm install). Optional: tsx for development.uv run for faster setup.Additional tooling (pip, npm) is used only for dependency installation when explicitly requested by the user.
| Factor | Python (FastMCP) | TypeScript (MCP SDK) |
|---|---|---|
| Speed to build | Faster (less boilerplate) | More setup |
| Type safety | Runtime checks | Compile-time checks |
| Ecosystem | Data/ML/scripting | Web/Node ecosystem |
| Hosting | uvx, pip | npx, npm |
Default: Python with FastMCP unless the user needs TypeScript.
from fastmcp import FastMCP
mcp = FastMCP("my-service", description="What this server does")
@mcp.tool()
async def my_tool(param: str) -> str:
"""Description of what this tool does.
Args:
param: Description of the parameter
"""
# Implementation here
return f"Result for {param}"
@mcp.resource("resource://{name}")
async def get_resource(name: str) -> str:
"""Fetch a named resource."""
return f"Content of {name}"
my-mcp-server/
__init__.py
server.py # FastMCP instance + tools
config.py # Environment variables, constants
requirements.txt # fastmcp, httpx, etc.
README.md # Usage instructions
# Development
fastmcp dev server.py
# Install in Claude/OpenClaw
fastmcp install server.py --name "My Service"
# Or configure manually in settings
import { McpServer } from "@modelcontextprotocol/sdk/server/mcp.js";
import { StdioServerTransport } from "@modelcontextprotocol/sdk/server/stdio.js";
import { z } from "zod";
const server = new McpServer({
name: "my-service",
version: "1.0.0",
});
server.tool(
"my-tool",
"Description of what this tool does",
{ param: z.string().describe("Description of param") },
async ({ param }) => ({
content: [{ type: "text", text: `Result for ${param}` }],
})
);
const transport = new StdioServerTransport();
await server.connect(transport);
my-mcp-server/
src/
index.ts # McpServer instance + tools
config.ts # Environment variables
package.json # @modelcontextprotocol/sdk, zod
tsconfig.json
README.md
get_user, create_issue, not do_thingos.environ or process.envasync/await for all I/O operations# Python testing with FastMCP
import pytest
from fastmcp import Client
@pytest.fixture
def client():
return Client(mcp)
@pytest.mark.asyncio
async def test_my_tool(client):
result = await client.call_tool("my_tool", {"param": "test"})
assert "Result" in result.text
For OpenClaw/Claude Desktop:
{
"mcpServers": {
"my-service": {
"command": "python",
"args": ["-m", "my_mcp_server.server"],
"env": {
"API_KEY": "from-env-or-secrets"
}
}
}
}
This skill generates new source code files (scaffolding MCP servers). It does NOT execute the generated code during scaffolding.
pip install fastmcp, npm install @modelcontextprotocol/sdk — these install packages from public registries. Review package names before running.Published by Shadows Company — "We work in the shadows to serve the Light."
ZIP package — ready to use