A community-driven registry for Claude, Cursor, Windsurf, Cline & more. Not affiliated with Anthropic.
Are you the author? Sign in to claim
MCP server bridge for RTK (Rust Token Killer) — token-optimized CLI output for Claude Desktop, Cursor, Windsurf, and all
MCP server bridge for RTK (Rust Token Killer) — token-optimized CLI output for any MCP-compatible client.
rtk-mcp exposes a single MCP tool (run_command) that routes shell commands through RTK for 60-90% token reduction before the output reaches your LLM's context window.
MCP Client (Claude Desktop, Cursor, Windsurf, ...)
→ rtk-mcp (this server)
→ rtk git status ← filtered output (78% fewer tokens)
→ returns to LLM
Without RTK installed, commands execute normally (no filtering, no token savings).
RTK already saves tokens for Claude Code and Gemini CLI via hooks. But hooks are client-specific — each new AI tool needs its own integration.
MCP is a universal protocol. One server, every client:
| Client | MCP Support |
|---|---|
| Claude Desktop | Yes |
| Cursor | Yes |
| Windsurf | Yes |
| Cline (VS Code) | Yes |
| Continue | Yes |
| Zed | Yes |
| VS Code (native) | Yes |
| GitHub Copilot | Yes |
Measured over 25 days of daily usage with RTK:
| Filter | Token reduction |
|---|---|
cargo test | 97.8% |
env | 99.3% |
cargo clippy | 92.5% |
find | 79.2% |
ls | 67-78% |
grep | 64.4% |
Total: 5.3M tokens saved across 4,876 commands.
Install RTK first:
cargo install --git https://github.com/rtk-ai/rtk
# Verify
rtk --version # Should show "rtk X.Y.Z"
rtk gain # Should work (not "command not found")
git clone https://github.com/ousamabenyounes/rtk-mcp.git
cd rtk-mcp
cargo build --release
The binary is at target/release/rtk-mcp.
Add to ~/Library/Application Support/Claude/claude_desktop_config.json (macOS) or %APPDATA%\Claude\claude_desktop_config.json (Windows):
{
"mcpServers": {
"rtk": {
"command": "/path/to/rtk-mcp"
}
}
}
Add to .cursor/mcp.json in your project:
{
"mcpServers": {
"rtk": {
"command": "/path/to/rtk-mcp"
}
}
}
Add to your MCP settings (check each client's documentation for the exact config file path):
{
"mcpServers": {
"rtk": {
"command": "/path/to/rtk-mcp"
}
}
}
Once configured, the run_command tool is available in your AI assistant. It accepts:
| Parameter | Type | Required | Description |
|---|---|---|---|
command | string | Yes | The command to execute (e.g. git status, cargo test) |
cwd | string | No | Working directory (defaults to server cwd) |
Example tool calls from the LLM:
{"name": "run_command", "arguments": {"command": "git log --oneline -5", "cwd": "/my/project"}}
{"name": "run_command", "arguments": {"command": "cargo test"}}
{"name": "run_command", "arguments": {"command": "ls -la src/"}}
Only allowlisted commands are accepted. Dangerous commands like bash, sh, rm, sudo are blocked:
Allowed: git, cargo, npm, npx, pnpm, pytest, ruff, mypy, pip, uv, go, golangci-lint, docker, grep, find, ls, cat, head, tail, wc, env, echo, pwd, gh, curl, wget, node, tsc, next, prettier, eslint, biome, playwright, prisma, vitest, dotnet, psql, make, tree
Blocked: Everything else (bash, sh, rm, sudo, chmod, python, etc.)
shlex for proper quoted argument handling (no split_whitespace injection)Command::new() directly, never spawns a shellisError: true in MCP response┌──────────────┐ stdio (JSON-RPC) ┌──────────────┐
│ MCP Client │ ◄──────────────────────► │ rtk-mcp │
│ (Cursor, │ │ │
│ Claude │ │ 1. Parse │
│ Desktop) │ │ 2. Validate │
│ │ │ 3. Execute │
└──────────────┘ └──────┬───────┘
│
┌──────▼───────┐
│ rtk │
│ (filtering) │
│ │
│ git status │
│ → 78% less │
│ tokens │
└──────────────┘
tools/call request with a command stringrtk-mcp validates the command against the allowlistshlex (handles quotes correctly)rtk <command> for filtered output# Run tests
cargo test
# Build
cargo build --release
# Test MCP protocol manually
echo '{"jsonrpc":"2.0","id":1,"method":"initialize","params":{"protocolVersion":"2024-11-05","capabilities":{},"clientInfo":{"name":"test","version":"0.1"}}}' | ./target/release/rtk-mcp
MIT
1000+ skills curated from Anthropic, Vercel, Stripe, and other engineering teams
A Claude Code skill by Hao (駱君昊) that learns your Facebook voice and auto-posts to FB / IG / Threads / X with a 14-day c
Claude Code skill for YouTube creators — channel audits, video SEO, retention scripts, thumbnails, content strategy, Sho
Design enforcement with memory — keeps your UI consistent across a project