andreaswasita/copilot-agents-dojo/using-mcp
Claude Code and agent skill by andreaswasita/copilot-agents-dojo
- community
Checking that the SKILL.md file is still in the repository.
Wires MCP servers into a Copilot client and verifies them.
Install
npx vskill@latest install andreaswasita/copilot-agents-dojo/using-mcpSKILL.md
Using MCP Skill
Discovers, configures, and verifies Model Context Protocol servers from Copilot, Claude Code, Cursor, and other MCP-compliant clients. Treats mcp/registry.yaml as the source of truth and least-privilege scopes as non-negotiable. Does NOT itself author servers (see building-mcp-servers) or bypass the broker (see calling-mcp-tools-via-subprocess).
When to Use
- User mentions MCP, MCP server, "add a tool", "connect to <service>".
- Agent needs data from an external system (GitHub, Postgres, Azure, Graph, browser, FS).
- "Why can't Copilot see X?" — check the MCP wiring before anything else.
- Authoring or modifying
.vscode/mcp.json,.mcp.json,.cursor/mcp.json.
Prerequisites
- A Copilot client that supports MCP (Copilot CLI, VS Code agent mode, Claude Code, Cursor).
mcp/registry.yamlaccessible in the dojo (this skill is parasitic on the registry).npx/nodeavailable for stdio servers, or hosted endpoint for Streamable HTTP.- Auth context already set up (
az login,gh auth, OAuth flow, etc.) — never paste raw secrets into configs. - The
view,edit, andpowershellCopilot tools.
How to Run
Quick Reference
| Transport | When | Auth model | |
|---|---|---|---|
| stdio | Local dev, single user | Inherits CLI session env (az, gh) | |
| Streamable HTTP | Hosted, teams, sandboxed | OAuth 2.1 + PKCE | |
| SSE (legacy) | Only if server still requires it | Migrate to Streamable HTTP |
| Client | Config file | |
|---|---|---|
| VS Code / GHCP agent mode | .vscode/mcp.json (workspace) or user-level via MCP: Open User Configuration | |
| Copilot CLI | ~/.copilot/mcp.json or per-project .copilot/mcp.json | |
| Claude Code | .mcp.json (repo) or ~/.claude.json (user) | |
| Cursor | .cursor/mcp.json or ~/.cursor/mcp.json |
| Scope rule | Concrete | |
|---|---|---|
| GitHub MCP | Fine-grained PAT, read-only where possible, scoped to specific repos | |
| Filesystem MCP | Explicit allow-list of dirs — never / or ~ | |
| Postgres / MSSQL MCP | Read-only role for assistant work | |
| Azure MCP | Inherit az login identity, no SP secrets in config |
Procedure
Step 1: Registry First
Use view on mcp/registry.yaml. If the server is listed, use its sanctioned config. If it is not listed, hand off to building-mcp-servers first and add a registry entry before consuming it.
Step 2: Pick Transport
Use the transport table above. Default to stdio for dev; Streamable HTTP for anything shared.
Step 3: Configure
Use edit to add the snippet to the client's config file. Reference env vars (${env:VAR}) — never inline secrets. Pin server version (@x.y.z) for reproducibility.
Step 4: Scope Down
Apply the scope table. Default to read-only unless the workflow demonstrably requires writes. Document the scope in the registry entry, not just the config.
Step 5: Verify
Run via the powershell tool:
Then ask the agent to perform a tiny task that exercises one tool. Failure modes to check:
- Trailing commas in JSON.
- Wrong
type(stdiovshttp). - Server printed to stdout before the JSON-RPC handshake (kills framing).
- Missing env var the server silently needs.
Step 6: Fallback When the Broker Misbehaves
If tools/call hangs or "tools_changed" loops, do not reconfigure — bypass. Switch to calling-mcp-tools-via-subprocess.
Pitfalls
- DO NOT paste an MCP URL into chat instead of a config file.
- DO NOT use a
repo-scope classic GitHub token. Fine-grained, scoped. - DO NOT allow-list
/or~for the filesystem MCP server. - DO NOT hard-code tokens into committed configs. Use
${env:VAR}. - DO NOT add a server without verifying the agent can actually invoke it.
- DO NOT re-implement GitHub / Postgres / FS access as a custom skill when an MCP server already exists.
Verification
- [ ] Server entry exists in
mcp/registry.yaml(with scopes documented). - [ ] Config file uses the snippet from
mcp/configs/verbatim (except env / scopes). - [ ] Server pinned to a specific version (no floating
latest). - [ ] Client shows the server as connected / green.
- [ ] One representative tool call executed end-to-end via the agent.
- [ ] No secrets in committed files (
grepfor token patterns).
Security
- Security scanPassed, 100 of 100Pattern checks on the skill's files.
- Model reviewNot runA model review is scheduled for the next rescan.
Quality evaluation
- Task evaluationNot runNo evaluation yet. Run one in Skill Studio.
Source
- SKILL.md in the repositoryCheckingoptional-skills/using-mcp/SKILL.md
Popularity
- Repository stars
- 48
- Repository forks
- 15
- 7-day trend score
- 19
Stars and forks are for the whole GitHub repository, not this skill alone. Not refreshed yet.
Works with
Any agent vskill installs to: 56 targets in all. These 39 have a page on this site.
- Claude Code
- Cursor
- GitHub Copilot
- Windsurf
- Codex
- Gemini CLI
- Cline
- Amp
- Roo Code
- Goose
- Continue
- Kilo Code
- Junie
- Trae
- OpenHands
- Qwen Code
- AI Agent
- Tabnine Chat
- Sourcegraph Cody
- Amazon Q
- Firebase Genkit
- Sweep
- Devin
- Phind
- Mentat
- Claude Desktop
- Aider
- GPT Pilot
- Plandex
- bolt.new
- v0
- Replit Agent
- Anse
- TypingMind
- BetterChatGPT
- LibreChat
- Warp AI
- Pieces
- Fig AI
Embed badge
[](https://verified-skill.com/skills/andreaswasita/copilot-agents-dojo/using-mcp)