Skip to main content
Back to skills
development
Claude

MCP Builder

Build MCP (Model Context Protocol) servers that let LLMs interact with external services.

Build custom MCP servers that connect your AI assistant to external APIs and services. The skill covers design, implementation, and testing.

mcpserversapiintegration
Share:
Version 2.0.0Updated Jan 25, 2026

Capabilities

FastMCP for Python development
TypeScript SDK support
Tool schema design patterns
Error handling best practices
Testing and validation

Use cases

Connecting to databases
API integrations
Custom tool development
Automation workflows
External service access

Try it

Example prompts to use with this skill

Prompt

Build an MCP server that connects to a weather API

Output
I'll create a FastMCP server for weather data:
from fastmcp import FastMCP
import httpx

mcp = FastMCP('weather-server')

@mcp.tool()
async def get_weather(city: str) -> dict:
    """Get current weather for a city."""
    async with httpx.AsyncClient() as client:
        response = await client.get(
            f'https://api.weather.com/v1/current',
            params={'city': city}
        )
        return response.json()

if __name__ == '__main__':
    mcp.run()
The tool lets Claude fetch real-time weather data.
Prompt

How do I handle errors in MCP tools?

Output
Use structured error handling with descriptive messages:
from fastmcp import FastMCP
from fastmcp.exceptions import ToolError

mcp = FastMCP('my-server')

@mcp.tool()
async def fetch_data(id: str) -> dict:
    if not id:
        raise ToolError('ID is required')
    
    try:
        result = await database.get(id)
        if not result:
            raise ToolError(f'No data found for ID: {id}')
        return result
    except ConnectionError:
        raise ToolError('Database connection failed')
ToolError messages appear to the user, so make them helpful and actionable.

Add to your AI assistant

Choose your AI assistant and run the command in your terminal

Claudecurl -fsSL https://raw.githubusercontent.com/n3wth/newth-skills/main/skills/mcp-builder.md -o ~/.claude/skills/mcp-builder.mdCopy

Discussions

Sign in with GitHub to join the discussion.

Loading...