MCP Integration

A guide for connecting a Claude Code plugin to outside services and APIs through the Model Context Protocol, a standard way to provide tools to an AI coding assistant.

In plain words
What is it for?
Use it to add databases, APIs or file systems to a plugin, configure MCP servers in .mcp.json or plugin.json, and set up OAuth or other authentication.
Why use it?
It explains how to make external capabilities available inside a plugin and how to configure servers and authentication.

Skill for Claude CodeCodex

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add skills/tlipoca9/devgen/mcp-integration
Any agent
npx skills add tlipoca9/devgen --skill mcp-integration
Clone the repo
git clone --depth 1 https://github.com/tlipoca9/devgen

Made for: Claude Code, Codex.

Per session 97 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 3,032 The whole file, excluding the scripts and references it only reads on demand.
Security scan B 1 finding. Scan, not verified.
Origin 100% copy Near-identical to another mod in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.00097 $0.03032
Opus 5 $0.00048 $0.01516
Sonnet 5 $0.00019 $0.00606
Haiku 4.5 $0.00010 $0.00303

Measured 2d ago against content hash 1cbfb6b1cf98, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade B, and why

MCP Integration scanned grade B with 1 finding against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 2d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Unrestricted tool accessmediumExcessive agency

A wildcard tool grant or "run any command" leaves no least-privilege boundary at all.

- ❌ Pre-allow all tools with wildcards
Origin

This is a copy

100% identical to MCP Integration — 0 lines differ, which has more behind it and is treated as the original. This page carries a canonical link to it rather than competing with it.

.codebuddy/skills/mcp-integration/SKILL.md · 555 lines

How it starts

The opening of the file, as written. The whole thing — 555 lines — stays where its author put it; the contents beside it link to each section on GitHub.

MCP Integration for Claude Code Plugins

Overview

Model Context Protocol (MCP) enables Claude Code plugins to integrate with external services and APIs by providing structured tool access. Use MCP integration to expose external service capabilities as tools within Claude Code.

Key capabilities:

  • Connect to external services (databases, APIs, file systems)
  • Provide 10+ related tools from a single service
  • Handle OAuth and complex authentication flows
  • Bundle MCP servers with plugins for automatic setup

MCP Server Configuration Methods

Plugins can bundle MCP servers in two ways:

Method 1: Dedicated .mcp.json (Recommended)

Create .mcp.json at plugin root:

{
  "database-tools": {
    "command": "${CLAUDE_PLUGIN_ROOT}/servers/db-server",
    "args": ["--config", "${CLAUDE_PLUGIN_ROOT}/config.json"],
    "env": {
      "DB_URL": "${DB_URL}"
    }
  }
}

Benefits:

  • Clear separation of concerns
  • Easier to maintain
  • Better for multiple servers

Method 2: Inline in plugin.json

Add mcpServers field to plugin.json:

{
  "name": "my-plugin",
  "version": "1.0.0",
  "mcpServers": {
    "plugin-api": {
      "command": "${CLAUDE_PLUGIN_ROOT}/servers/api-server",
      "args": ["--port", "8080"]
    }
  }
}

Benefits:

  • Single configuration file
  • Good for simple single-server plugins

MCP Server Types

stdio (Local Process)

Execute local MCP servers as child processes. Best for local tools and custom servers.

Configuration:

{
  "filesystem": {
    "command": "npx",
    "args": ["-y", "@modelcontextprotocol/server-filesystem", "/allowed/path"],
    "env": {
      "LOG_LEVEL": "debug"
    }
  }
}

Use cases:

  • File system access
  • Local database connections
  • Custom MCP servers
  • NPM-packaged MCP servers

Process management:

  • Claude Code spawns and manages the process
  • Communicates via stdin/stdout
  • Terminates when Claude Code exits

SSE (Server-Sent Events)

Connect to hosted MCP servers with OAuth support. Best for cloud services.

Read the full file on GitHub · 555 lines

Files

What ships with it

6 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 2d ago First seen · 555 lines · 97 tokens per session scan B 1cbfb6b1cf98

Subscribe to this mod's changes

MCP Integration is a skill published in the GitHub repository tlipoca9/devgen (5 stars, last pushed 4mo ago), licensed MIT. It adds 97 tokens to every session and 3,032 once invoked, about $0.0005 per session on Opus 5. A static security scan graded it B with 1 finding (unrestricted tool access). It is 100% identical to MCP Integration, differing in 0 lines, and is treated as a copy.

Related

Other skills, from other repositories

datamodel-code-generator

Use this skill when the user wants Python data models, Pydantic models, dataclasses, TypedDicts, msgspec structs, or type-safe Python classes generated from OpenAPI, AsyncAPI, JSON Schema, GraphQL, JSON/YAML/CSV sample data, MCP tool schemas, Protocol Buffers, XML Schema, Apache Avro, or existing Python model objects.…

koxudaxi/datamodel-code-generator · 147 tokens

preserved_skill

previous skill.

koxudaxi/datamodel-code-generator · 0 tokens

fin-brief-generator

根据用户输入或已有研究输出(文献综述/想法报告/新颖性报告),自动生成或更新FINBRIEF.md,减少用户填写负担。.

csmar432/finai-research · 42 tokens

add-localization

Add or update a language translation in the privacy policy generator. Trigger when user says: "add {language} translation", "add locale", "translate to {language}", "add localization for {language}", or when a user wants to contribute a new language.

nisrulz/app-privacy-policy-generator · 56 tokens

add-thirdparty-service

Add a new third-party service to the privacy policy generator. Trigger when user says: "add {name} service", "add third party service", "add 3rd party service", "add new service entry", or when a user wants to contribute a new service to the app.

nisrulz/app-privacy-policy-generator · 63 tokens

autumn-framework-2x

Autumn 2.0.0 line ONLY: JDK 8, Spring Boot 2.7.18, MyBatis-Plus 2.x, javax. namespace. Use on autumn master (artifact 2.0.0) or business apps pinned to that stack. NOT for Autumn 3.0.0 / JDK 17+ / Spring Boot 3.5 / Jakarta — use autumn-framework-3x on the 3.0.0 branch when available. Enforces docs/AISTANDARDS.md +…

henryxm/autumn · 724 tokens