Token导航 LogoToken导航TokenDH.com
MCP Ison logo
运维云端未说明官方级别未说明来源级核验

MCP Ison

MCP Server

mcpison是一个透明的MCP传输层拦截代理,可将MCP Server返回的JSON数据实时转换为轻量级的ISON格式,降低大语言模型的Token消耗,无需修改原有MCP Server代码。

工具数

0

提示词数

0

GitHub Stars

3

资源数

0
JavaScript协议转换云端部署

安装说明

本站只整理中文说明和来源信息,不托管安装包,也不代用户安装。

作者 / 组织

123XiaoYi321

提供方

123XiaoYi321

最后核验

2026/5/17 20:20

快速接入

先看主来源和安装命令,再打开仓库或文档;下面只保留这个条目的关键接入事实。

详细介绍

mcpison - MCP to ISON Transport Proxy

](https://github.com/123XiaoYi321/mcp-ison) ](https://www.npmjs.com/package/mcpison)

⭐ If this tool saves you tokens, please !

English | 中文


English

mcpison is a transparent MCP (Model Context Protocol) transport interceptor. It converts JSON responses from MCP Servers into the lightweight ISON format in real-time, reducing LLM token consumption without modifying the original MCP Server code.

Installation

npm install -g mcpison

Usage 1: Web Management UI

A visual interface for managing proxy configurations. Start it with:

mcpison-ui
# Open http://localhost:4000

Use a custom port:

mcpison-ui --port 8080

Paste your existing mcpServers JSON block into the Batch Import tab. It will:

  • Detect each server's transport type (HTTP/SSE or stdio)
  • Register remote HTTP endpoints as local proxy routes
  • Wrap local stdio commands with mcpison
  • Output the complete updated configuration

Individual tabs for adding HTTP/SSE or stdio servers manually are also available.


Usage 2: Remote HTTP/SSE API Proxy *(Added in v1.1.0)*

For remote MCP Servers that expose a URL, mcpison acts as a local reverse proxy.

Option A: Proxy a Single Endpoint

mcpison --proxy-url https://mcp.api-inference.modelscope.net/123456/mcp --port 3000

Update your MCP client config:

"mcpServers": {
  "my-remote-server": {
    "type": "sse",
    "url": "http://localhost:3000/sse"
  }
}

Option B: Proxy Multiple Endpoints on One Port *(Added in v1.1.x)*

Create a mcp-routes.json file:

{
  "/modelscope": "https://mcp.api-inference.modelscope.net/123456/mcp",
  "/weather": "https://weather-mcp.example.com/api"
}

Start with the config:

mcpison --config mcp-routes.json --port 3000
"mcpServers": {
  "my-modelscope": { "type": "sse", "url": "http://localhost:3000/modelscope/sse" },
  "my-weather":    { "type": "sse", "url": "http://localhost:3000/weather/sse" }
}

Usage 3: Local stdio Proxy

For MCP Servers running locally via stdio, prepend mcpison to your command in the MCP client configuration:

"mcpServers": {
  "my-local-server": {
    "command": "mcpison",
    "args": ["python", "/path/to/sql-server.py"]
  }
}
Add --debug as the first item in args to log byte savings: "args": ["--debug", "python", "/path/to/sql-server.py"]

Regardless of which mode you use, all client traffic flows through mcpison. It compresses JSON in memory and returns ISON transparently, without modifying the original server code.


中文

mcpison 是一个透明的 MCP (Model Context Protocol) 传输层拦截代理。它可以将 MCP Server 返回的 JSON 数据实时转换为轻量级的 ISON 格式,降低大语言模型的 Token 消耗,无需修改任何原本的 MCP Server 代码。

安装

npm install -g mcpison

用法 1:Web 管理界面

提供可视化界面管理代理配置。启动方式:

mcpison-ui
# 然后打开 http://localhost:4000

自定义端口:

mcpison-ui --port 8080

批量导入 标签页中粘贴你的 mcpServers JSON,系统会自动:

  • 识别每个服务器的通信类型(HTTP/SSE 或 stdio)
  • 将远程 HTTP 节点注册为本地代理路由
  • 为本地 stdio 节点添加 mcpison 包装
  • 输出可直接使用的完整新配置

界面上也提供 HTTP/SSE 和 stdio 的独立手动添加面板。


用法 2:远程 HTTP/SSE API 代理 *(V1.1.0 新增)*

对于只提供 URL 的远程 MCP Server,mcpison 可以作为本地反向代理。

方式 A:单独代理一个节点

mcpison --proxy-url https://mcp.api-inference.modelscope.net/123456/mcp --port 3000
"mcpServers": {
  "my-remote-server": {
    "type": "sse",
    "url": "http://localhost:3000/sse"
  }
}

方式 B:单端口代理多个节点 *(V1.1.x 新增)*

创建 mcp-routes.json

{
  "/modelscope": "https://mcp.api-inference.modelscope.net/123456/mcp",
  "/weather": "https://weather-mcp.example.com/api"
}
mcpison --config mcp-routes.json --port 3000
"mcpServers": {
  "my-modelscope": { "type": "sse", "url": "http://localhost:3000/modelscope/sse" },
  "my-weather":    { "type": "sse", "url": "http://localhost:3000/weather/sse" }
}

用法 3:本地命令行工具 (stdio)

对于运行在本地、使用 stdio 通信的 MCP Server,在配置文件中把 mcpison 前置到命令前:

"mcpServers": {
  "my-local-server": {
    "command": "mcpison",
    "args": ["python", "/path/to/sql-server.py"]
  }
}
args 首位加上 --debug 可在调试日志中查看节省的字节数。

不论是哪种方式,客户端所有流量都通过 mcpison 转发;它在内存中将 JSON 转换为 ISON 后返回给客户端,原 Server 代码无需任何改动。

目录标签

目录标签

JavaScript协议转换云端部署数据传输优化本地部署MCP代理JSON压缩轻量级格式

接入字段

传输方式(transport,传输协议)

未说明

鉴权方式(authType,认证方式)

token

工具数量(toolCount,工具数)

0

资源数量(resourceCount,资源数)

0

提示词数量(promptCount,提示词数)

0

权限和风险

未说明token部署方式未说明

接入前请确认传输方式、认证方式和部署位置,并根据实际工具能力限制访问范围。

安装前确认

不要直接授予不必要的文件、网络或账号权限;先核对安装命令和配置内容。

仍需确认:installCommand

来源信息

继续浏览同类 MCP