mcp-cli

MCP设计创作

提供方 yatainc

设计创作 stdio · 本地进程 OAuth 授权 社区 / 第三方 Cursor

mcpx is a lightweight CLI/JS runtime for the Model Context Protocol built with MoonBit, designed for small bundle size and low memory usage, enabling discovery and invocation of tools, skills, and resources from remote or local MCP servers.

一句话选型结论

按资料字段整理

mcp-cli 属于设计创作类 MCP 服务器,stdio · 本地进程,OAuth 授权,可直接接入 Cursor,没有现成安装命令,需按官方文档接入。接入前先确认权限范围;涉及写入、删除或付款的操作,建议先在测试环境验证。

分类设计创作 传输方式stdio · 本地进程 鉴权OAuth 授权 部署方式本地部署
GitHub 星标 0 仓库热度,无公开仓库时显示未标注
工具数 未标注 暴露给模型的工具数量
资源 / 提示词 0 / 0 资源与提示词模板数量
维护方 社区 / 第三方 核验等级 仅资料核对

工具与能力

设计创作
数量来自来源目录的标注,具体工具清单以官方文档为准
工具数量未标注暴露给模型可调用的工具个数
资源数量0可读取的资源条目
提示词数量0内置提示词模板数量

能力标签

Local Deployment Model Context Protocol CLI MoonBit lightweight runtime tool invocation OAuth authentication configuration management skill discovery resource reading

支持客户端

适用场景

Local DeploymentModel Context ProtocolCLI

安装与配置

stdio · 本地进程 OAuth 授权
客户端在本机拉起子进程,数据不出本机
  1. 1
    准备运行环境

    stdio 服务在本地起进程,需要先装好 Node.js 等运行时,再按安装命令拉取依赖。

  2. 2
    安装服务

    复制上面的安装命令执行;命令里带占位符的位置,换成自己的密钥或路径。

  3. 3
    写入客户端配置

    在客户端的 MCP 配置里填好启动命令和参数,保存后完全退出客户端再打开,让新配置生效。

  4. 4
    验证是否可用

    连接成功后随便调一个只读工具,确认能返回结果,再接入正式流程。

典型使用场景

3 类
按分类与标签整理的常见用法,具体以官方文档为准
出图与素材

生成配图、图标与素材。

设计稿处理

读取设计稿、批量改尺寸或导出。

内容生成

按主题生成文案与视觉草稿。

选择建议

选之前先看这几条
按条目字段给出的判断,不替你决定用不用

值得选的地方

  • 已适配 Cursor,换客户端不用重新研究配置。

先想清楚的地方

  • stdio 方式要求本地装好运行时(如 Node.js),换机器要重新装一遍。
  • 没有现成安装命令,需要按官方文档自己填启动命令和参数。
  • 使用前要准备好OAuth 授权对应的凭据,并按最小权限配置。
  • 资料没标注工具数量,实际能力要装好后确认。
  • 版本更新与行为细节以官方仓库为准。

更适合

  • 需要在设计创作场景里让模型直接调用外部能力的人。
  • 已经在用 Cursor 的用户,接入路径最短。
  • 想先快速试一下、能接受在本地或自有环境跑服务的人。

不太适合

  • 完全不想在本地装环境的人。
  • 不方便管理密钥或第三方授权的人。
  • 需要厂商级 SLA 和技术支持的生产环境。

同类对比

6 个同类
同分类里挑最接近的几条,字段以各自详情页为准
MCP 服务器工具数传输方式部署方式安装命令最后核验
mcp-cli当前 未标注 stdio · 本地进程 本地部署 无 2026-10-09
Cursor Talk To Figma MCP Da1c7911 40 未标注 未标注 无 2026-05-17
Blender MCP 17 stdio · 本地进程 本地部署 有 2026-05-18
Nova Canvas MCP Server 2 stdio · 本地进程 本地部署 有 2026-05-17
Figma Context MCP 3aaa8d28 未标注 未标注 支持远程部署 无 2026-05-17
kreuzberg 未标注 stdio · 本地进程 本地部署 有 2026-04-12

服务器档案

设计创作
字段来自项目仓库与公开索引,中文说明由本站标注
提供方yatainc上游标注的维护方 yatainc
分类设计创作本站按上游分类展示
连接方式stdio · 本地进程客户端在本机拉起子进程,数据不出本机
鉴权方式OAuth 授权远程服务建议用最小权限凭据
维护方社区 / 第三方核验等级 仅资料核对
包名 / 运行时未标注 · 未标注本地安装时用到的包标识与运行时
部署类型本地部署上游给出的部署形态
最近核验2026-10-09上游最后核验时间

详细介绍

14.8 KB
来自项目仓库与上游目录的原文,未做删改

mcpx

Lightweight CLI / JS Runtime for the Model Context Protocol built with MoonBit.
Designed for small bundle size and low memory usage, with short-lived, stateless-by-default MCP discovery and tool calls.

Installation```sh

curl -fsSL https://raw.githubusercontent.com/yatainc/mcpx/main/install.sh | sh


Run directly:```sh
nix run --accept-flake-config github:yatainc/mcpx -- --help

Usage```sh

mcpx
mcpx --help
mcpx --version
mcpx info
mcpx info <server|url> [tool]
mcpx search <pattern>
mcpx call <server|url> <tool> [arguments-json]
mcpx skills <server|url> [uri] [--verify] [--json]
mcpx resources <server|url> <uri> [--json]
mcpx auth <server> [--no-browser] [--json]
mcpx auth <server> --code <code> --state <state>
mcpx daemon
mcpx daemon <status|stop>


Direct remote MCP URL, no config:```sh
mcpx info https://mcp.example.com/mcp
mcpx call https://mcp.example.com/mcp search &#x27;{&quot;q&quot;:&quot;moonbit&quot;}&#x27;

Configured server:```sh
mcpx info github
mcpx search search
mcpx call github search '{"q":"moonbit"}'


CLI output is human-readable by default. MCP text-content results are printed
directly; non-text results are printed under `Result:`. `auth --no-browser --json`
remains JSON for copy/paste and automation handoff.

## Skills and Resources```sh
mcpx skills docs-server
mcpx skills docs-server custom://demo/SKILL.md --json
mcpx skills docs-server custom://demo/SKILL.md --verify --json
mcpx resources docs-server custom://demo
mcpx resources docs-server custom://demo/references/guide.md --json

skills lists all available pages, or gets one entry directly when given a URI.
A listing can be empty or partial; direct get does not require a preceding list.
Skill entries retain their frontmatter and manifest, including unknown fields.

resources reads ordinary resource contents, without requiring the Skills
extension. If the server declares directoryRead: true, it first tries a direct
child listing. Only an initial JSON-RPC -32602 selects content reading instead;
later-page failures, authentication errors and timeouts are errors. Directories
are nonrecursive. URIs and pagination cursors are sent unchanged.

Skills JSON uses {&quot;origin&quot;:...,&quot;result&quot;:...}; list results contain pages.
The origin is client-assigned: config:sha256: identifies the selected
config path and server name; url:sha256: identifies a direct URL. It is
never serverInfo.name and does not expose URL credentials. Entries and
pages preserve unknown fields. Human listings show origin, names and URIs; no
name is used as an identifier. Generic Resources JSON remains the parsed content
result or {&quot;pages&quot;:[...]} for directories. Text reads print text and binary
items remain JSON. Parsing uses standard MoonBit JSON numeric semantics.

These commands require MCP 2026-07-28 and use modern discovery even when stdio
protocol mode is omitted. Explicit stateful mode and keep-alive stdio targets
are rejected. Each native CLI command has one 30-second deadline across discovery,
pagination, verification and fallback. Retrieval limits are 128 MiB per decoded
HTTP body/stdio frame, 256 MiB cumulatively per CLI command, 1,000 pages and
100,000 items. Cursors remain opaque; a repeated continuation cursor is an error.
These are not total-wire/header or hard heap guarantees. HTTP framing and
compression are handled by the standard client. Responses are buffered within
these limits, not terminated early at the first final SSE event.

--verify requires a Skill URI. It gets and fixes one entry, checks its manifest
(512 resources and 16 MiB total declared file size inclusive), then reads only
root SKILL.md. Raw byte length, SHA-256, UTF-8 and the complete YAML frontmatter
are checked. YAML parsing uses an external parser; graph-to-JSON conversion
rejects cycles and limits depth to 128, visits to 1,000,000 and logical output to
96 MiB. These additional complexity policies are not a claim that every valid
16 MiB YAML document is accepted. Dynamic manifests cannot be verified.
Verification confirms consistency with the same server's unsigned entry, not
trust, authorship, user approval or activation. JSON verification output carries
origin, skillUri, verified, entry and the original resource result.

The library's Source::hold(uri) keeps an independent entry and a fixed RPC peer.
HeldSkill::read(uri) refuses unlisted files before I/O; it verifies supporting
bytes on demand without applying nested frontmatter. same_content compares
origin, Skill URI and the complete URI/digest set; failures never refresh the
entry silently. Native adapters provide http_mcp_skill_source and
StdioMcpClient::skill_source. A shared receive budget is for one finite operation,
not a reusable client's lifetime. Budget-bearing stdio connections require
explicit Stateless mode; legacy modes and fallback are rejected before spawn.
Custom transports own their I/O limits and serialization. The host must provide unique nonsecret origin labels, retain the
snapshot for its acting window, preserve origin in model context, and explicitly
handle approval/reapproval, cross-origin consent and execution permissions.
allowed-tools and other content never grant permissions here. A manifest's
hidden-file completeness remains a server assertion; unlisted reads are rejected.

There is no file saving, Skill cache, approval store, activation or execution of
Skill instructions. Ordinary resources is not a verified Skill-loading path.
Existing Tool cache, keep-alive and legacy transport paths remain separate.

Config

mcpx automatically reads configuration from two roots:

  • User: $XDG_CONFIG_HOME/mcpx when XDG_CONFIG_HOME is absolute, otherwise
    ~/.config/mcpx.
  • Project: the Git working-tree root containing the invoking directory.
    Linked worktrees and submodules use their own roots.

At each root, the first existing file wins, in this order:
mcp.jsonc, mcp.json, .mcp.jsonc, .mcp.json. Only one file per root is read.
JSONC comments and trailing commas are accepted for all four names. A selected
unreadable or invalid file is an error, not a reason to try another file.

Server maps are combined by name: project replaces the whole user definition.
Missing project fields do not inherit user auth, env or tool filters. Nested
configs do not shadow the Git-root config. Outside Git, or when Git is not
installed, only user config is used; other Git discovery failures are errors.
Direct URLs, help/version and daemon control do not load project config.

For example, an existing project .mcp.json can be used unchanged:```json
{
"mcpServers": {
"foldkit-devtools": {
"command": "node",
"args": ["./node_modules/@foldkit/devtools-mcp/dist/server.js"]
}
}
}


`transport` is inferred from `command` (stdio) or `url` (HTTP); exactly one is
required, and any explicit transport must agree. This is the shared
`mcpServers` subset, not a promise of every editor&#x27;s configuration dialect.
Project stdio servers default to the Git root as cwd; relative `cwd` values
resolve there after environment expansion. User entries use the invoking cwd.
Arguments are not rewritten. Executables use the effective caller/server `PATH`,
including when a daemon was started in another directory or shell.

Project config is automatic and can select executable commands and credentials;
use it only in projects you trust. There is no approval prompt or trust database.
`mcpx info` lists configured server names and descriptions without starting servers.

Add `&quot;$schema&quot;` for editor autocompletion and validation:```jsonc
{
  &quot;$schema&quot;: &quot;https://raw.githubusercontent.com/yatainc/mcpx/main/schema.json&quot;,
  &quot;mcpServers&quot;: {
    // Required: server name used by `mcpx info/call/search`.
    &quot;github&quot;: {
      // Optional: inferred as &quot;http&quot; from url.
      &quot;transport&quot;: &quot;http&quot;,
      // Required for http: MCP endpoint URL.
      &quot;url&quot;: &quot;https://mcp.github.com/mcp&quot;,

      // Optional: extra HTTP headers; ${VAR} is supported.
      &quot;headers&quot;: {
        &quot;Authorization&quot;: &quot;Bearer ${GITHUB_TOKEN}&quot;
      },

      // Optional: OAuth metadata used by `mcpx auth github`.
      &quot;auth&quot;: {
        &quot;type&quot;: &quot;oauth&quot;,
        &quot;clientId&quot;: &quot;${GITHUB_CLIENT_ID}&quot;,
        &quot;clientSecret&quot;: &quot;${GITHUB_CLIENT_SECRET}&quot;,
        &quot;metadataUrl&quot;: &quot;https://mcp.github.com/.well-known/oauth-authorization-server&quot;
      },

      // Optional: visible/callable tool allowlist. Glob only.
      &quot;allowedTools&quot;: [&quot;read_*&quot;, &quot;list_*&quot;, &quot;search_*&quot;],
      // Optional: denylist applied last; wins conflicts.
      &quot;disabledTools&quot;: [&quot;delete_*&quot;, &quot;write_*&quot;, &quot;create_*&quot;]
    },

    // Required: another server name.
    &quot;local&quot;: {
      // Optional: inferred as &quot;stdio&quot; from command.
      &quot;transport&quot;: &quot;stdio&quot;,
      // Required for stdio: executable.
      &quot;command&quot;: &quot;node&quot;,
      // Optional: executable arguments.
      &quot;args&quot;: [&quot;/path/to/server.js&quot;],

      // Optional connection handling. HTTP defaults to &quot;auto&quot;.
      // For stdio, omit this or use &quot;stateful&quot; for the current release.
      &quot;protocol&quot;: {
        &quot;mode&quot;: &quot;stateful&quot;
      },

      // Optional: process env; ${VAR} is supported.
      &quot;env&quot;: {
        &quot;API_TOKEN&quot;: &quot;${API_TOKEN}&quot;
      },
      // Optional: working directory.
      &quot;cwd&quot;: &quot;/path/to/project&quot;,

      // Optional: keep expensive stdio servers warm.
      &quot;lifecycle&quot;: {
        &quot;mode&quot;: &quot;keep-alive&quot;,
        &quot;idleTimeoutMs&quot;: 300000
      }
    }
  }
}

Credentials remain in the user credentials.json, but are scoped to the selected
config file and server name and are used only for the exact endpoint URL. Run
mcpx auth from the project whose server you intend to authenticate;
manual code completion must use the same source and endpoint. Name-only
credentials from earlier versions are not reused: authenticate again, and run
mcpx daemon stop to replace any old daemon after upgrading.

Keep-alive reuses only matching source and effective launch conditions, including
environment values and protocol mode. It does not guarantee application readiness
or retry failed tool calls; relay/server readiness remains the server's concern.

MCP protocol modes

protocol.mode controls the MCP connection lifecycle. Accepted values are auto,
stateful, and stateless; the resulting protocol version determines request
encoding.

HTTP defaults to auto: it tries MCP 2026-07-28 discovery and falls back to the
initialize lifecycle only for explicit legacy signals. stateful selects the
initialize lifecycle directly and retains a server-issued session ID. stateless
requires MCP 2026-07-28, never sends a session ID, and does not silently downgrade
to an initialize-era protocol.

For stdio Tool commands, omitted mode and explicit stateful preserve initialize-era behavior.
Explicit auto tries server/discover and falls back on JSON-RPC method-not-found;
stateless requires MCP 2026-07-28. This is independent of stdio
lifecycle.mode, which only controls process reuse.

Environment values

Only the user config directory's .env is read, using simple KEY=value lines;
there is no project .env discovery. Process environment wins over .env for
interpolation. Child processes inherit the invoking environment plus resolved
server env; the dotenv file is not exported wholesale.
Only ${VAR} interpolation is supported; fallback syntax such as
${VAR:-fallback} is intentionally rejected.

Interpolation applies to HTTP, OAuth static client fields, and stdio launch fields.

Search

mcpx search searches configured server names and descriptions.
No server connections are needed — it reads config only. Results show the
top 5 matches ranked by relevance (exact > prefix > contains).

Keep-alive daemon

Public daemon commands are intentionally limited:```sh
mcpx daemon status
mcpx daemon stop


Keep-alive stdio servers start the daemon automatically when needed. Changed
launch conditions select a different process; old entries retain their configured
idle lifetime. Run `mcpx daemon stop` to discard all retained processes.

## OAuth

OAuth is explicit: `info` and `call` never open a browser unexpectedly. When auth
is required, the CLI returns a hint such as `mcpx auth `.```sh
mcpx auth github
mcpx auth github --no-browser --json
mcpx auth github --code CODE --state STATE

--no-browser --json prints an authorization URL, callback URL, and state. Open
the URL manually, then complete with --code and --state.

Credentials are stored in ~/.config/mcpx/credentials.json. The PKCE verifier is
stored machine-managed and is not printed.

Development

Nix pins the development toolchain. Moon resolves library versions from
moon.mod; there is no duplicate Nix manifest or checked-in registry snapshot.
The first registry update/build requires network access to fetch missing dependencies.

nix build fetches dependencies through Moon in a separate fixed-output step,
then builds offline. When changing dependencies, update the single outputHash
in package.nix (set it to lib.fakeHash, build, and use the reported hash).
The Nix application package and binary cache remain available.sh nix develop moon update moon build --target native cli moon fmt moon check --target all --frozen --warn-list +73 --deny-warn bash scripts/update-api.sh moon test --target native --frozen --warn-list +73 --deny-warn --no-parallelize moon test --target js --frozen --warn-list +73 --deny-warn moon test --target wasm-gc --frozen --warn-list +73 --deny-warn bash scripts/e2e.sh bash scripts/benchmark.sh

Tools definitions, pagination, catalog validation, and refresh/retry decisions
live in portable core/tools. core/protocol owns common JSON-RPC and MCP
metadata; core/http owns HTTP negotiation and exchange. Native stdio owns its
connection, request IDs, locking, and operation timeout independently of HTTP.

The native cli/tools package executes resolved Tool commands and formats their
results. The CLI root resolves config, environment, and OAuth and routes commands;
it has a single execution path, not a separate JSON command-plan API.
Set MCPX_BIN=/path/to/mcpx when running scripts/e2e.sh to test an existing
artifact instead of rebuilding the checkout.

bash scripts/update-api.sh refreshes generated interfaces from fresh compiler
output: native where supported, then JS/Wasm. Unlike moon info --target, it also
updates platform-only packages whose canonical Wasm interface is unavailable.

The benchmark script includes moved Tools and SSE cases. CLI call benchmarks now
measure parsing only, since the unused command-plan renderer was removed; their
timings are not comparable to the previous parse-and-render workload.

Roadmap

  • [x] support MCP 2026-07-28 discovery, tools/list, and tools/call over HTTP
  • [x] add MCP 2026-07-28 stdio negotiation
  • [ ] publish the JS build as a library package
  • [ ] provide an npm package that downloads/installs the native CLI

Detail in: bit issue list

Prior Art

  • openclaw/mcporter
  • evantahler/mcpx
  • AIGC-Hackers/mcpx
  • philschmid/mcp-cli

License

MIT

常见问题

8 问
答案由本站依据条目字段整理,不引用上游原文
mcp-cli 怎么安装?

资料没有给出安装命令,请到官方仓库或文档按说明接入;这类条目多数是生态应用,或尚未发布可安装包。

mcp-cli 怎么在 Cursor 里配置?

它的传输方式是stdio · 本地进程,在客户端的 MCP 配置里填好启动命令和参数,保存后完全退出客户端再打开,配置才会生效。

mcp-cli 收费吗?

本站不代收费用,也没有标注具体价格。是否收费取决于服务本身和背后的接口额度,正式使用前按官方说明确认。

mcp-cli 需要 API Key 吗?

资料标注需要OAuth 授权认证,使用前准备好对应凭据,并按最小权限配置。

mcp-cli 支持哪些客户端?

资料标注支持 Cursor;其他客户端只要能配置 MCP Server,也能用同样的命令或地址接入。

mcp-cli 能提供哪些能力?

资料显示能力标签包括 Local Deployment、Model Context Protocol、CLI、MoonBit、lightweight runtime、tool invocation。具体工具清单以官方文档为准。

mcp-cli 需要什么运行环境?

属于本地进程,需要在本机装好运行环境。

mcp-cli 是本地还是远程?

它是本地进程(stdio),由客户端在本机拉起。传输方式为stdio · 本地进程。

热门专题

按标签挑服务器
全部专题 →

服务器信息以作者仓库与官方文档为准;分类、传输方式与鉴权方式的中文说明为中文整理,最近核验 2026-10-09。