关于 MCP Client:
@pinax/mcp 是桥接客户端,可将 Claude Desktop 等支持 stdio 的 MCP 客户端连接到远程 MCP 服务。它通过配置的远程端点和访问令牌转发对 Pinax Token API 数据的访问。
主要功能
- 01桥接 stdio 客户端与远程 MCP
- 02可配置远程 URL
- 03JWT 访问令牌认证
- 04详细日志选项
适用场景
- 01将 Claude Desktop 连接到 Pinax 服务
- 02将 MCP 客户端路由至远程服务
- 03通过环境变量提供凭据
MCP 相关
该客户端通过 HTTP 将支持 stdio 的 MCP 客户端桥接到远程 MCP 服务。文档中的 https://mcp.pinax.network 端点提供 Pinax Token API 数据。
配置
本地服务的配置在各客户端中通用,复制后粘贴到客户端的 MCP 配置文件即可。
工具
还没有获取到工具列表
本地服务需要在你的电脑上运行后才能读取工具,维护者暂未提供工具列表。
详细介绍
MCP 客户端:@pinax/mcp
用于连接 https://app.pinax.network 上兼容 MCP 服务的 MCP 客户端。
用法
Usage: @pinax/mcp [options]
A bridge client for connecting Claude Desktop and other MCP-compatible clients to remote MCP servers.
Options:
-V, --version output the version number
--remote-url <string> Remote MCP server URL (env: REMOTE_URL)
--access-token <string> JWT Access Token (env: ACCESS_TOKEN)
-v, --verbose <boolean> Enable verbose logging (choices: "true", "false", default: false, env: VERBOSE)
-h, --help display help for command
文档:https://app.pinax.network/docs/guides/mcp
端点
此 MCP 允许大模型访问 Pinax Token API 提供的数据。
- MCP 服务(Streamable HTTP)请使用
https://mcp.pinax.network
身份验证
- 在 https://app.pinax.network 登录
- 前往 密钥
- 复制项目密钥并生成 JWT 访问令牌
配置
环境变量(.env)
ACCESS_TOKEN=<your-jwt-token-from-app.pinax.network>
REMOTE_URL=https://mcp.pinax.network
Claude Desktop 配置
将以下内容添加到 Claude Desktop 配置文件:
位置:
- macOS:
~/Library/Application Support/Claude/claude_desktop_config.json - Windows:
%APPDATA%/Claude/claude_desktop_config.json - Linux:
~/.config/Claude/claude_desktop_config.json
配置:
{
"mcpServers": {
"pinax": {
"command": "npx",
"args": [
"@pinax/mcp",
"--remote-url",
"https://mcp.pinax.network",
"--access-token",
"YOUR_ACCESS_TOKEN_HERE"
]
}
}
}
或者使用环境变量:
{
"mcpServers": {
"pinax": {
"command": "npx",
"args": ["@pinax/mcp"],
"env": {
"REMOTE_URL": "https://mcp.pinax.network",
"ACCESS_TOKEN": "YOUR_ACCESS_TOKEN_HERE"
}
}
}
}
在 Bun 中使用(开发)
{
"mcpServers": {
"pinax": {
"command": "/path/to/bun",
"args": [
"run",
"/path/to/pinax-mcp/index.ts",
"--remote-url",
"http://localhost:8080/mcp",
"--access-token",
"YOUR_ACCESS_TOKEN_HERE",
"-v",
"true"
]
}
}
}
支持的客户端
此桥接程序适用于任何支持 stdio 传输的 MCP 客户端:
- Claude Desktop
- Cline
- Cursor
- 任何其他兼容 MCP 的应用程序
故障排除
启用详细日志记录
在命令中添加 -v true,或在环境中设置 VERBOSE=true:
npx @pinax/mcp --remote-url https://example.com/mcp --access-token YOUR_TOKEN -v true
常见问题
连接超时:
- 确认
ACCESS_TOKEN有效 - 检查
REMOTE_URL是否正确且可访问
身份验证失败:
- 在 https://app.pinax.network/keys 生成新的访问令牌
- 确保令牌尚未过期
服务断开连接:
- 查看 Claude Desktop 日志以获取详细错误信息
- 确认网络连接正常,可以访问远程服务
开发
安装依赖
bun install
本地运行
bun run index.ts --remote-url http://localhost:8080/mcp --access-token YOUR_TOKEN -v true
构建
bun build ./index.ts --outdir ./dist --target=node
架构
┌─────────────────┐ ┌──────────────┐ ┌─────────────────┐
│ Claude Desktop │◄──stdio─►│ MCP Bridge │◄──HTTP──►│ Remote MCP │
│ (or other │ │ Client │ │ Server │
│ MCP client) │ └──────────────┘ └─────────────────┘
└─────────────────┘
许可证
评论
支持 Markdown
一个开放协议,规定了 AI 应用如何以统一方式连接外部工具与数据源。客户端负责与模型对话,MCP 服务负责提供工具、资源和提示模板,两者通过标准消息通信,同一个服务可以被不同客户端复用。