npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

@aalis/plugin-mcp-client

v0.9.3

Published

MCP 客户端:连接外部 MCP server,把其 tools 注册进工具表

Readme

plugin-mcp-client

作为 MCP (Model Context Protocol) client 连接外部 MCP servers(通过 stdio),把它们暴露的 tools 包装注册到 Aalis 的 ToolService,让 Aalis agent 可以直接调用外部生态的工具。

接入要点

  • 每个 server 在 config 中独立一项(id / command / args / env
  • 工具名会加前缀 mcp_<server-id>_<tool-name> 避免与本地工具命名冲突
  • 每个 server 注册一个工具分组 mcp:<server-id>,可在 platform 配置中按需启用
  • ctx.onDispose 注册了 client 关闭回调,插件卸载时自动断开
  • 工具的 safety / authority 由 config 中按 server 配置,默认 safe—— 对接 filesystem / shell 等高危 server 时务必显式设为 dangerous

配置示例

plugins:
  "@aalis/plugin-mcp-client":
    servers:
      - id: github
        command: npx
        args: ["-y", "@modelcontextprotocol/server-github"]
        env:
          GITHUB_PERSONAL_ACCESS_TOKEN: "ghp_xxx"
        enabled: true

      - id: fs
        command: npx
        args: ["-y", "@modelcontextprotocol/server-filesystem", "/path/to/allowed/dir"]
        safety: dangerous   # 文件系统访问视为高危
        authority: 3

依赖

  • @modelcontextprotocol/sdk ^1.0.4
  • inject.required: tools(api-tools / plugin-tools)

注意

  • MCP inputSchema 顶层非 type: 'object' 时会被包装为 { input: schema }
  • 工具名超过 64 字符(OpenAI 限制)会被截断
  • 非法字符(/ . 等)会被替换为下划线