
Ncp
io.github.portel-dev由 GitHub 账号 portel-dev 发布v3.0.0更新于 Oct 24, 2026
1 MCP to rule them all. Orchestrate, discover, and run any tool instantly.
概览
网关型 MCP 服务器,让助手通过一个精简接口发现并调用多个其他 MCP 服务器的工具,支持代码模式与定时调度。
- 可以做什么
- 按意图搜索下游工具、技能与 Photon,并运行匹配到的工具
- 用 TypeScript 编写多步骤工作流,一次组合调用多个工具(代码模式)
- 按 cron 或自然语言时间定时运行任意工具,并查看执行历史
- 管理 MCP 服务器:添加、删除、列出、导入配置,以及按项目划分的配置
- 查看用量、节省的 token 与性能分析,并检查服务器健康状态
- 适用场景
- 适合助手已连接大量 MCP 服务器、工具列表变得臃肿混乱时,或需要对工具调用做周期性后台自动化时。它本身是枢纽而非新能力来源,因此只有在你已有或计划添加下游 MCP 服务器时才有意义。
- 运行要求
- 通过 npx 从 npm 包以 stdio 在本地运行;需要 Node.js 22 或更高版本(推荐 24)、npm/npx 和命令行环境。下游服务器需另行配置,远程服务器可能需要 bearer 令牌或 OAuth 凭据。可选环境变量 NCP_DEBUG、NCP_MODE 和 NO_COLOR 控制日志与运行模式。
安装
README
[npm version] [npm downloads] [GitHub release downloads] [Latest release] [License: Elastic-2.0] [MCP Compatible]
Your MCPs, supercharged. Discover tools, execute with code mode, run on schedule, find skills, and load Photons through common MCP clients. On-demand discovery keeps the initial tool surface focused.
Related Portel project: Photon turns TypeScript methods into reliable agent-facing capabilities: MCP tools, embedded app UIs, CLI commands, web routes, schedules, webhooks, retries, and Beam interfaces. NCP helps agents discover and operate tools; Photon helps developers build the tools and apps agents can trust.
💍 What is NCP?
Instead of your AI juggling 50+ tools scattered across different MCPs, NCP gives it a single, unified interface with code mode execution, scheduling, skills discovery, and custom Photons.
Most hosts see NCP's small gateway surface (find, run, and, when enabled, code). Hosts that support MCP Apps can also receive selected app callback tools so embedded interfaces keep working. NCP adds app tools selectively; it omits conflicting app groups rather than renaming callbacks that an app may call by name.
find- Search for any tool, skill, or Photon: "I need to read a file" → finds the right tool automaticallycode- Execute TypeScript directly:await github.create_issue({...})(code mode, enabled by default)run- Execute tools individually (when code mode is disabled)
Behind the scenes, NCP manages all 50+ tools + skills + Photons: routing requests, discovering the right capability, executing code, scheduling tasks, managing health, and caching responses.
The host determines which optional features it can use. NCP advertises MCP Apps, Skills, and Tasks capabilities, while clients that do not support an extension continue with the core tools and existing request flows.
Why this matters:
- Your AI stops analyzing "which tool do I use?" and starts doing actual work
- Code mode lets AI write multi-step TypeScript workflows combining tools, skills, and scheduling
- Skills provide domain expertise: canvas design, PDF manipulation, document generation, more
- Photons enable custom TypeScript MCPs without npm publishing
- On-demand discovery keeps the initial tool surface focused; actual context use depends on the host, enabled NCP tools, and connected servers
- Your AI becomes focused. Not desperate.
🚀 NEW: Project-level configuration - each project can define its own MCPs automatically
What's MCP? The Model Context Protocol by Anthropic lets AI assistants connect to external tools and data sources. Think of MCPs as "plugins" that give your AI superpowers like file access, web search, databases, and more.
📑 Quick Navigation
- The Problem - Why too many tools break your AI
- The Solution - How NCP transforms your experience
- Getting Started - Installation & quick start
- Try It Out - See the CLI in action
- Supercharged Features - How NCP empowers your MCPs
- Setup by Client - Claude Desktop, Cursor, VS Code, etc.
- Popular MCPs - Community favorites to add
- Advanced Features - Project config, scheduling, remote MCPs
- Troubleshooting - Common issues & solutions
- How It Works - Technical deep dive
- Contributing - Help us improve NCP
😤 The MCP Paradox: From Assistant to Desperate
You gave your AI assistant 50 tools to be more capable. Instead, you got desperation:
- Paralyzed by choice ("Should I use
read_fileorget_file_content?") - Exhausted before starting ("I've spent my context limit analyzing which tool to use")
- Costs explode (50+ tool schemas burn tokens before any real work happens)
- Asks instead of acts (used to be decisive, now constantly asks for clarification)
🧸 Why Too Many Tools Break the System
Think about it like this:
A child with one toy → Treasures it, masters it, creates endless games with it A child with 50 toys → Can't hold them all, gets overwhelmed, stops playing entirely
Your AI is that child. MCPs are the toys. More isn't always better.
The most creative people thrive with constraints, not infinite options. A poet given "write about anything" faces writer's block. Given "write a haiku about rain"? Instant inspiration.
Your AI is the same. Give it one perfect tool → Instant action. Give it 50 tools → Cognitive overload. NCP provides just-in-time tool discovery so your AI gets exactly what it needs, when it needs it.
📊 The Before & After Reality
Before NCP: Desperate Assistant 😵💫
When your AI assistant manages 50 tools directly:
What happens:
- AI burns 50%+ of context just understanding what tools exist
- Spends 5-8 seconds analyzing which tool to use
- Often picks wrong tool due to schema confusion
- Hits context limits mid-conversation
After NCP: Executive Assistant ✨
With NCP as Chief of Staff:
NCP reduces the need to load every downstream tool schema into the host up front. The amount of context saved and any effect on response time vary with the host, server catalog, and enabled features.
📋 Prerequisites
- Node.js 22+ (Node.js 24 recommended; CI uses 24) (Download here)
- npm (included with Node.js) or npx for running packages
- Command line access (Terminal on Mac/Linux, Command Prompt/PowerShell on Windows)
🚀 Installation
Choose your MCP client for setup instructions:
Quick Start (npm)
For advanced users or MCP clients not listed above:
Step 1: Install NCP
Step 2: Import existing MCPs (optional)
Step 3: Configure your MCP client
Add to your client's MCP configuration:
✅ Done! Your AI can discover and run tools through NCP. Hosts with MCP Apps support may also receive selected app callback tools.
🧪 Test Drive: See the Difference Yourself
Want to experience what your AI experiences? NCP has a human-friendly CLI:
🔍 Smart Discovery
Notice: NCP understands intent, not just keywords. Just like your AI needs.
📋 Ecosystem Overview
⚡ Direct Testing
Why this matters: You can debug and test tools directly, just like your AI would use them.
✅ Verify Everything Works
✅ Success indicators:
- NCP shows version number
ncp listshows your imported MCPsncp findreturns relevant tools- Your AI client shows NCP's gateway tools; an Apps-capable host may also show selected app callback tools
💪 From Tools to Automation: The Real Power
You've seen find (discover tools) and code (execute TypeScript). Individually, they're useful. Together with scheduling, they become an automation powerhouse.
A Real Example: The MCP Conference Scraper
We wanted to stay on top of MCP-related conferences and workshops for an upcoming release. Instead of manually checking websites daily, we asked Claude:
"Set up a daily scraper that finds MCP conferences and saves them to a CSV file"
What Claude did:
-
Used
codeto write the automation: -
Used
scheduleto automate it:
How to set this up yourself:
First, install the web photon (provides search and read capabilities):
Then ask Claude to create the scraper - it will use the web photon automatically.
What happens now:
- Every morning at 9am, the scraper runs automatically
- Searches for new MCP events and adds them to the CSV
- If our laptop was closed at 9am, it catches up when we open it
- We wake up to fresh conference data - no manual work
The insight: find and code let AI write automation. schedule makes it run forever. That's the powerhouse.
💡 Why NCP Transforms Your AI Experience
🧠 From Desperation to Delegation
- Desperate Assistant: "I see 50 tools... which should I use... let me think..."
- Executive Assistant: "I need file access. Done." (NCP handles the details)
💰 Focused Tool Discovery
- NCP lets the host search a larger tool catalog on demand
- The context impact depends on your host and enabled tool surface
🎯 Eliminates Choice Paralysis
- Desperate: AI freezes, picks wrong tool, asks for clarification
- Executive: NCP's Chief of Staff finds the RIGHT tool instantly
🚀 Confident Action
- Before: 8-second delays, hesitation, "Which tool should I use?"
- After: Instant decisions, immediate execution, zero doubt
Bottom line: Your AI goes from desperate assistant to executive assistant.
⚡ Supercharged Features
Here's exactly how NCP empowers your MCPs:
The result: Your MCPs go from scattered tools to a unified, intelligent system that your AI can actually use effectively.
🛠️ For Power Users: Manual Setup
Prefer to build from scratch? Add MCPs manually:
💡 Pro tip: Browse Smithery.ai (2,200+ MCPs) or mcp.so to discover tools for your specific needs.
🎯 Popular MCPs That Work Great with NCP
🔥 Most Downloaded
🛠️ Development Essentials
🌐 Productivity & Integrations
🤖 Internal MCPs
NCP includes powerful internal MCPs that extend functionality beyond external tool orchestration:
Scheduler MCP - Automate Any Tool
Schedule any MCP tool to run automatically using cron or natural language schedules.
Features:
- ✅ Natural language schedules ("every day at 9am", "every monday")
- ✅ Standard cron expressions for advanced control
- ✅ Automatic validation before scheduling
- ✅ Execution history and monitoring
- ✅ Works even when NCP is not running (system cron integration)
MCP Management MCP - Install MCPs from AI
Install and configure MCPs dynamically through natural language.
Features:
- ✅ Search and discover MCPs from registries
- ✅ Install MCPs without manual configuration
- ✅ Update and remove MCPs programmatically
- ✅ AI can self-extend with new capabilities
Skills Management MCP - Extend Claude with Plugins
Manage Anthropic Agent Skills - modular extensions that add specialized knowledge and tools to Claude.
Features:
- ✅ Vector-powered semantic search for skills
- ✅ One-command install from official marketplace
- ✅ Progressive disclosure (metadata → full content → resources)
- ✅ Official Anthropic marketplace integration
- ✅ Custom marketplace support
- ✅ Auto-loading of installed skills
Analytics MCP - Visualize Usage & Performance
View usage statistics, token savings, and performance metrics directly in your chat.
Features:
- ✅ Usage trends and most used tools
- ✅ Token savings analysis (Code-Mode efficiency)
- ✅ Performance metrics (response times, error rates)
- ✅ ASCII-formatted charts for AI consumption
Configuration: Internal MCPs are disabled by default. Enable in your profile settings:
🔧 Advanced Features
Smart Health Monitoring
NCP automatically detects broken MCPs and routes around them:
🎯 Result: Your AI never gets stuck on broken tools.
Multi-Profile Organization
Organize MCPs by project or environment:
🚀 Project-Level Configuration
New: Configure MCPs per project with automatic detection - perfect for teams and Cloud IDEs:
How it works:
- 📁 Local
.ncpdirectory exists → Uses project configuration - 🏠 No local
.ncpdirectory → Falls back to global~/.ncp - 🎯 Zero profile management needed → Everything goes to default
all.json
Perfect for:
- 🤖 Claude Code projects (project-specific MCP tooling)
- 👥 Team consistency (ship
.ncpfolder with your repo) - 🔧 Project-specific tooling (each project defines its own MCPs)
- 📦 Environment isolation (no global MCP conflicts)
Remote MCP Transports and Hibernation Support
NCP supports both stdio (local) and HTTP/SSE (remote) MCP servers:
Stdio Transport (Traditional):
Streamable HTTP (Remote):
For a legacy HTTP/SSE endpoint, set "transport": "sse". If an older profile has a URL and no transport, NCP continues to use its legacy SSE behavior. New registry imports select Streamable HTTP by default. Protocol-version negotiation is separate from transport selection and does not discover another endpoint automatically.
OAuth 2.1 with PKCE (MCP 2025-03-26 spec):
OAuth 2.1 Features:
- ✅ PKCE (Proof Key for Code Exchange) - Required by OAuth 2.1 for security
- ✅ Dynamic Client Registration (RFC 7591) - Auto-registers if no clientId provided
- ✅ Token Storage & Auto-Refresh - Tokens saved to
~/.ncp/auth/and refreshed automatically - ✅ Browser Authorization Flow - Opens browser for user consent
- ✅ Headless Fallback - Manual code entry for servers/CI environments
- ✅ Protected Resource Discovery (RFC 9728) - Auto-discovers OAuth endpoints
First-time setup flow:
- NCP opens browser to authorization URL
- You grant permissions
- Browser redirects to local callback (
http://localhost:9876) - NCP exchanges code for access token (with PKCE)
- Token saved and refreshed automatically for future requests
🔋 Hibernation-Enabled Servers:
NCP automatically supports hibernation-enabled MCP servers (like Cloudflare Durable Objects or Metorial):
- Zero configuration needed - Hibernation works transparently
- Automatic wake-up - Server wakes on demand when NCP makes requests
- State preservation - Server state is maintained across hibernation cycles
- Cost savings - Only pay when MCPs are actively processing requests
How it works:
- Server hibernates when idle (consumes zero resources)
- NCP sends a request → Server wakes instantly
- Server processes request and responds
- Server returns to hibernation after idle timeout
Perfect for:
- 💰 Cost optimization - Only pay for active processing time
- 🌐 Cloud-hosted MCPs - Metorial, Cloudflare Workers, serverless platforms
- ♻️ Resource efficiency - No idle server costs
- 🚀 Scale to zero - Servers automatically sleep when not needed
Note: Hibernation is a server-side feature. NCP's remote MCP client works with both traditional and hibernation-enabled servers without special configuration.
Modern MCP extensions and result handling
NCP preserves downstream tool descriptors and native MCP results through discovery and run, including structured content, error state, metadata, and text, image, audio, resource, and resource-link blocks. If an integration previously parsed JSON text that encoded an array of result blocks, update it to consume the native MCP result fields.
When a host advertises MCP Apps support, NCP selectively exposes downstream app launch tools and app callbacks, and serves their ui:// resources. The host controls whether app-only callbacks are available to the model. Tool-name and UI-resource collisions cause the affected app groups to be omitted; their ordinary tools remain available through find and run.
The Skills extension exposes local and compatible remote skill manifests on demand, including SHA-256 digests for the manifest bytes. The Tasks extension gives compatible modern hosts durable handles for run and code, with tasks/get, tasks/update, and tasks/cancel. After a restart, unfinished work is reported as interrupted rather than replayed; cancellation is reported only when NCP can confirm the worker stopped. Hosts without Tasks support keep the existing synchronous or multi-round request flow.
Response caches are bounded, and private cached entries are partitioned by server configuration and credential identity. Server cache lifetimes and tool-list change notifications guide refreshes. For transport, SDK, registry, extension, and compatibility details, see the MCP compatibility notes.
Photon Runtime (CLI vs DXT)
The TypeScript Photon runtime is enabled by default, but the toggle lives in different places depending on how you run NCP:
- CLI / npm installs: Edit
~/.ncp/settings.json(or runncp config) and setenablePhotonRuntime: trueorfalse. You can also override ad‑hoc withNCP_ENABLE_PHOTON_RUNTIME=true ncp find "photon". - DXT / client bundles (Claude Desktop, Cursor, etc.): These builds ignore
~/.ncp/settings.json. Configure photons by setting the env var inside the client config:
If you disable the photon runtime, internal MCPs continue to work, but .photon.ts files are ignored until you re-enable the flag.
Import from Anywhere
🛟 Troubleshooting
Import Issues
AI Not Using Tools
- Check connection:
ncp list(should show your MCPs) - Test discovery:
ncp find "your query" - Validate config: Ensure your AI client points to
ncpcommand
Performance Issues
🌓 Why We Built This
Like Yin and Yang, everything relies on the balance of things.
Compute gives us precision and certainty. AI gives us creativity and probability.
We believe breakthrough products emerge when you combine these forces in the right ratio.
How NCP embodies this balance:
Neither pure AI (too unpredictable) nor pure compute (too rigid).
Your AI stays creative. NCP handles the precision.
📚 Deep Dive: How It Works
A reproducible gateway benchmark measures serialized payload sizes, local latency, workflow completion, and result fidelity. Run npm run benchmark:mcp; its byte-based token proxy is labeled separately from actual tokenizer measurements.
Want the technical details? Token analysis, architecture diagrams, and performance benchmarks:
Learn about:
- Vector similarity search algorithms
- N-to-1 orchestration architecture
- Real-world token usage comparisons
- Health monitoring and failover systems
🤝 Contributing
Help make NCP even better:
- 🐛 Bug reports: GitHub Issues
- 💡 Feature requests: GitHub Discussions
- 🔄 Pull requests: Contributing Guide
📄 License
Elastic License 2.0 - Full License
TLDR: Free for all use including commercial. Cannot be offered as a hosted service to third parties.
来源:README.md,提交 d8061b8
工具
0版本历史
2- v3.0.0最新Oct 19, 2026
- v1.5.3Sep 16, 2026
评分
已满足适用检查项的 40%
该评分衡量此收录条目的完整程度,依据注册中心条目、端点与公开来源计算得出。它不是对服务器本身的评价,也不表示服务器安全或当前可用:可连通性是带日期的检查结果,评分也不包含安装量或用户评价。
- 近 30 天内可连通25 分
请保持端点能够响应 MCP 握手;SourceWeft 每 30 天探测一次。
- 已声明认证方式10 分
请在注册中心条目中声明凭据请求头,或保持端点能够响应探测,以便判定其认证方式。
- 已列出工具15 分
请让服务器在无凭据时响应 tools/list,或发布可在沙箱中无凭据启动的软件包。
- 描述必需15 分
- 图标10 分
- 文档15 分
- 许可证10 分
请在仓库或注册中心条目中声明许可证。