Agent skill · software engineering · aiskillstore

mcp-patterns

Model Context Protocol (MCP) server patterns for building integrations with Claude Code. Triggers on: mcp server, model context protocol, tool handler, mcp resource, mcp tool.

Why this skill is useful

Provides specific patterns and code examples for building MCP servers that integrate with Claude Code, which the AI may not generate reliably on its own.

What it needs

Requires node, python installed locally. About 2k tokens when loaded. Last updated 2026-08-07. 405 stars on the source repository.

What this skill does

MCP Patterns Model Context Protocol (MCP) server patterns for building integrations with Claude Code. Basic MCP Server (Python) Project Layout Claude Desktop Configuration Basic Configuration With uv (Recommended) Quick Reference Pattern Use Case Reference --------- ---------- ----------- Tool validation Input sanitization with Pydantic ./references/tool-patterns.md Error handling Graceful failure responses ./references/tool-patterns.md Multiple tools CRUD-style tool registration ./references/tool-patterns.md Static resources Config/settings exposure ./references/resource-patterns.md Dynamic resources Database-backed resources ./references/resource-patterns.md Environment auth API key from env vars ./references/auth-patterns.md OAuth tokens Token refresh with TTL ./references/auth-patterns.md SQLite cache Persistent state storage ./references/state-patterns.md In-memory cache TTL-based caching ./references/state-patterns.md Manual testing Quick validation script ./references/testing-patterns.md pytest async Unit tests for tools ./references/testing-patterns.md Common Issues Issue Solution ------- ---------- Server not starting Check command path, ensure dependencies installed Tool not appearing Verify listtools() returns valid schema Auth failures Check env vars are set in config, not shell Timeout errors Add timeout to httpx calls, use async properly JSON parse errors Ensure calltool returns proper content structure Official Documentation https://modelcontextprotocol.io - MCP specification https://modelcontextprotocol.io/docs/concepts/tools - Tools reference https://modelcontextprotocol.io/docs/concepts/resources - Resources reference https://github.com/modelcontextprotocol/python-sdk - Python SDK https://github.com/modelcontextprotocol/servers - Official MCP servers Additional Resources For detailed patterns, load: ./references/tool-patterns.md - Validation, error handling, multi-tool registration ./references/resource-patterns.md - Static and dynamic resource exp …

How to use it

Reference it in AdaL, Claude Code, Cursor or any coding agent — nothing to install:

@skills aiskillstore/mcp-patterns

View the source on GitHub

Browse the @skills marketplace