agentleFS
jamestorrevillasjamestorrevillas/dev-skills/.github/skills/mcp-builder/SKILL.md

mcp-builder

Skill4 starsChanged 9 months agoMITView on GitHub

Use this skill when building Model Context Protocol (MCP) servers, creating AI tool integrations, designing agent-accessible tools, or making external services accessible to AI agents. Trigger on keywords: MCP, Model Context Protocol, MCP server, AI tool, tool integration, agent tools, connect AI to, build MCP, FastMCP.

  • Reads credentials

187 other projects use a version of this.

Adopted by

Most recently taken up by

Used with

Projects with it also use chinese-code-review, chinese-commit-conventions and 10 more.

Other files people use alongside this one.

Files found in the same public projects as a version of this one, more often than they turn up anywhere else. Each project counts once, large collections count for less, and this file's own repository is left out.
  • Leodorareluctant259Skill

    chinese-code-review

    中文代码审查规范——在保持专业严谨的同时,用符合国内团队文化的方式给出有效反馈

    Also in 8 projects that use this

  • Leodorareluctant259Skill

    chinese-commit-conventions

    中文 Git 提交规范 — 适配国内团队的 commit message 规范和 changelog 自动化

    Also in 8 projects that use this

  • ComposioHQSkill

    codebase-migrate

    Run large codebase migrations and multi-file refactors. Uses the Composio CLI to coordinate issue tracking, batched PRs, and CI verification while the agent executes the transforms locally across hundreds of files.

    Also in 5 projects that use this

  • truongtv22Skill

    Problem-Solving Techniques

    Apply systematic problem-solving techniques for complexity spirals (simplification cascades), innovation blocks (collision-zone thinking), recurring patterns (meta-pattern recognition), assumption constraints (inversion exercise), scale uncertainty (scale game), and dispatch when stuck. Techniques derived from Microsoft Amplifier project patterns adapted for immediate application.

    Also in 6 projects that use this

  • mrgoonieSkill

    aesthetic

    Create aesthetically beautiful interfaces following proven design principles. Use when building UI/UX, analyzing designs from inspiration sites, generating design images with ai-multimodal, implementing visual hierarchy and color theory, adding micro-interactions, or creating design documentation. Includes workflows for capturing and analyzing inspiration screenshots with chrome-devtools and ai-multimodal, iterative design image generation until aesthetic standards are met, and comprehensive design system guidance covering BEAUTIFUL (aesthetic principles), RIGHT (functionality/accessibility), SATISFYING (micro-interactions), and PEAK (storytelling) stages. Integrates with chrome-devtools, ai-multimodal, media-processing, ui-styling, and web-frameworks skills.

    Also in 6 projects that use this

  • AnthropicSkill

    academy-guide

    Stop and check this skill before finishing any reply to a question about how to use Claude or a Claude product — it recommends matching courses, tutorials, and use cases from Claude Academy (academy.claude.com), Anthropic's learning hub. Trigger on: "how do I", "how can I", "getting started with", "what can Claude do", "teach me", "learn to use"; questions about artifacts, projects, skills, plugins, connectors, MCP; requests about rolling Claude out to a team, class, or organization; and any ask for training materials, onboarding content, or learning resources. Use it when the user is learning how to use a feature or product — not when they are mid-task and just want the task done. This skill composes with other skills: after consulting product documentation to answer how a Claude feature works, also check here for a matching course or tutorial — a docs-grounded answer and an Academy recommendation belong together. Only recommend on a strong match; never invent Academy content.

    Also in 11 projects that use this

  • +2 more from Leodorareluctant259

The file

We split this skill into the rules it gives an agent

1 rule. 0 are common, 1 is distinctive, and 0 are very specific to this project.

  • 0

    Common

    Most of the 172 edited versions we read keep these.

  • 1

    Distinctive

    This author's own choices. Worth a look.

  • 0

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    When to use MCP: When you want a tool to be reusable across multiple agents or platforms (Claude, Copilot, Cursor, etc.)

    line 12

“Common” is measured: kept by at least 6 in 10 of the 172 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

MCP Builder

What is MCP

Model Context Protocol is the open standard for connecting AI agents to external tools and data sources. Think of it as USB-C for AI — one standard connector to any tool.

When to use MCP: When you want a tool to be reusable across multiple agents or platforms (Claude, Copilot, Cursor, etc.)

When NOT to use MCP: For project-specific, one-off integrations where the overhead isn't worth it.


MCP Server Structure

my-mcp-server/
├── server.py (Python) or index.ts (TypeScript)
├── tools/
│   ├── tool_one.py
│   └── tool_two.py
├── resources/       # Optional: expose data sources
├── prompts/         # Optional: expose prompt templates
├── requirements.txt or package.json
└── README.md

Python (FastMCP) — Recommended

from fastmcp import FastMCP

mcp = FastMCP("my-server-name")

@mcp.tool()
def get_user(user_id: str) -> dict:
    """
    Retrieve a user by their ID.
    
    Args:
        user_id: The unique identifier of the user
    
    Returns:
        User object with id, name, email
    """
    # implementation
    return {"id": user_id, "name": "James", "email": "james@example.com"}

@mcp.tool()
def create_task(title: str, description: str, assignee: str = None) -> dict:
    """Create a new task in the project management system."""
    # implementation
    return {"id": "task_123", "title": title, "status": "created"}

if __name__ == "__main__":
    mcp.run()

TypeScript (MCP SDK)

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-server", version: "1.0.0" })

server.tool(
  "get_user",
  "Retrieve a user by their ID",
  { userId: z.string().describe("The user's unique ID") },
  async ({ userId }) => ({
    content: [{ type: "text", text: JSON.stringify({ id: userId, name: "James" }) }]
  })
)

const transport = new StdioServerTransport()
await server.connect(transport)

Tool Design Principles

Tool Definition Checklist

  • Name is descriptive and action-oriented (get_user, not user)
  • Description clearly states when to use this tool
  • Parameters have clear names and descriptions
  • Returns are documented
  • Error cases are handled and return meaningful messages
  • Side effects are documented (if tool writes/deletes data)

Tool Design Rules

  • One tool = one action — don't combine multiple operations
  • Idempotent where possible — safe to call multiple times
  • Validate inputs — don't trust that the AI passes valid data
  • Return structured data — JSON is better than plain text for programmatic use
  • Include context in errors — "User 'abc' not found" not just "Not found"

Resources (Exposing Data)

@mcp.resource("users://list")
def list_users() -> str:
    """Returns all users as a JSON string"""
    users = db.get_all_users()
    return json.dumps(users)

@mcp.resource("user://{user_id}")
def get_user_resource(user_id: str) -> str:
    """Returns a specific user's data"""
    user = db.get_user(user_id)
    return json.dumps(user)

Connecting to Claude Desktop

In claude_desktop_config.json:

{
  "mcpServers": {
    "my-server": {
      "command": "python",
      "args": ["/path/to/server.py"],
      "env": {
        "API_KEY": "your-key-here"
      }
    }
  }
}

Security Checklist

  • Never expose credentials in tool definitions
  • Validate and sanitize all inputs before using in DB queries or file operations
  • Rate limit expensive operations
  • Log all tool invocations for auditing
  • Implement timeouts for external calls
  • Don't give the tool more permissions than it needs

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.