Osmosis MCP服务器

提供基于Osmosis的Model Context Protocol服务器实现,使MCP客户端能够与指定的Osmosis账户交互。

  • by jonator
  • TypeScript
  • 本地部署
  • 7 星标
  • 更新于
在 GitHub 查看 jonator/osmosis-agent-toolkit

使用说明

渗透模型上下文协议

提供渗透实现 模型上下文协议 服务器提供了一个帐户助记符。 这使MCP客户端能够与给定的Osmosis帐户进行交互。

设置

要使用npx运行Osmosis MCP服务器,请使用以下命令:

npx -y @osmosis-agent-toolkit/mcp --mnemonic='$MNEMONIC'
# Start with OSMOSIS_MNEMONIC environment variable
npx -y @osmosis-agent-toolkit/mcp

使用Claude桌面或光标

将以下内容添加到您的 claude_desktop_config.json 或 .cursor/mcp.json。参见 这里 了解更多详情。

{
    "mcpServers": {
        "Osmosis": {
            "command": "npx",
            "args": [
                "-y",
                "@osmosis-agent-toolkit/mcp"
            ],
            "env": {
                "OSMOSIS_MNEMONIC": "<your mnemonic here>"
            }
        }
    }
}

调试服务器

要调试服务器,可以使用 MCP检查员.

首先构建服务器

bun run build

在终端中运行以下命令:

# Start MCP Inspector and server
npx @modelcontextprotocol/inspector bun dist/index.js --mnemonic='$MNEMONIC'
# Start MCP Inspector and server with OSMOSIS_MNEMONIC environment variable
npx @modelcontextprotocol/inspector bun dist/index.js

说明

  1. 替换 MNEMONIC 使用您实际的渗透记忆法。或设置 OSMOSIS_MNEMONIC 环境变量。
  2. 运行命令以启动MCP检查器。
  3. 在浏览器中打开MCP检查器UI,然后单击连接以启动MCP服务器。
  4. 您可以看到您选择的工具列表,并单独测试每个工具。