MCP Leash — Development skill for Claude Code
Find the dangerous tools in your MCP servers and lock them down in Claude Code — one command.
How to install MCP Leash
This entry records only its repository, not the path inside it, so there is no
exact command to give. Open codersanjay3/mcp-leash and copy the folder into
~/.claude/skills/, or the file into ~/.claude/agents/.
What MCP Leash does
Find the dangerous tools in your MCP servers and lock them down in Claude Code — one command.
Alternatives in Development
- MCP Builder — Guide for creating high-quality MCP servers to integrate external APIs and services 94.1k ★
- MCP Python SDK — Python SDK for building MCP servers 22.3k ★
- Claude Code Everything You Need To Know — Ultimate all-in-one guide to mastering Claude Code 1.3k ★
README
mcp-leash
Find the dangerous tools in your MCP servers and lock them down in Claude Code — one command.
npx mcp-leash

**[Try it in your browser →](https://codersanjay3.github.io/mcp-leash/)** Paste your MCP tool names and see what `lock` would deny or ask for. Nothing leaves your browser.
[](https://github.com/codersanjay3/mcp-leash/actions/workflows/ci.yml) [](https://www.npmjs.com/package/mcp-leash) [](LICENSE)
Why
- Every MCP server you add hands Claude a bag of tools, and some of them delete repos, run shell commands or send messages as you. Most people never read the tool list.
- Claude Code's permission rules can allow, ask or deny a tool, but writing
mcp__server__toolrules by hand for every server is tedious, so it doesn't happen. - Permission rules can't look at arguments (Claude Code ignores
mcp__rules with parentheses). mcp-leash adds a small hook that can, for example "ask before pushing tomain", and keeps an audit log of every MCP call.
Quickstart
npx mcp-leash scan # see every tool your MCP servers expose, ranked by risk
npx mcp-leash lock # deny the destructive ones, ask for the ones that change things
npx mcp-leash unlock # remove exactly what lock added
`lock` shows a diff, asks for confirmation, and backs up your settings file first. Restart Claude Code (or reload `/permissions`) afterwards.
Example output
This is real output from `mcp-leash scan --trust-project --project test/fixtures/project-basic` in this repo. `fake` is a tiny MCP server used by the tests; `broken` points at a script that doesn't exist, to show that one bad server doesn't stop the scan.
mcp-leash scan test/fixtures/project-basic
fake (project · stdio · node ../fake-server.mjs)
CRITICAL
Related Skills
Skill Scan Gate
CI gate for Claude Code skills and plugins: scans a skills or plugin repository for instruction-override text,
Cost Estimate
Per-session token-overhead estimator (BL-READINESS-001 sibling). Breaks down the fixed context cost a session
Bridle Public
Local tool that measures how your Claude Code harness (CLAUDE.md, skills, hooks, MCP servers, plugins) affects
Trustabl Cursor
Agent Reliability Analyzer MCP server for Cursor: find agent reliability issues in MCP servers
Context Budget
Analyze context window usage across agents, skills, MCP servers, and rules to find optimization opportunities.
Symbolhop
Go-to-definition and find-references for coding agents. An MCP server and CLI that answers from your language
Related Agents
Claude Code MCP Specialist
Expert MCP server configuration specialist for Claude Code. Use when you need to set up, configure, or find MC
MCP Finder
Searches online to find MCP servers. SPAWNED BY create-mcp skill after identifying user needs. Searches NPM, G
Analyse
Use for deep analysis tasks — break down problems, evaluate options, find root causes, surface insights from d