io.github.adacapo21/openmm-mcp

平台与服务

by qbt-labs

AI-native crypto trading MCP server — market data, orders, grid strategies & DeFi

什么是 io.github.adacapo21/openmm-mcp

AI-native crypto trading MCP server — market data, orders, grid strategies & DeFi

README

@qbtlabs/openmm-mcp

smithery badge npm version npm downloads License: MIT Ask DeepWiki

📚 Documentation · 🤖 AI Skills Portal · 🔌 API Reference

MCP server for OpenMM — exposes market data, account, trading, and strategy tools to AI agents via any MCP client.

<a href="https://glama.ai/mcp/servers/QBT-Labs/openmm-mcp"> <img width="380" height="200" src="https://glama.ai/mcp/servers/QBT-Labs/openmm-mcp/badge" alt="openmm-mcp MCP server" /> </a>

Two Ways to Use

OptionBest ForAPI KeysPayments
Local (npm)Full control, your own keysEncrypted vaultFree
Hosted (mcp.openmm.io)No setup, pay-per-useNot needed for public datax402 USDC

Local Setup

Prerequisites: Node.js 20 or later.

1. Install and configure

bash
npm install -g @qbtlabs/openmm-mcp
openmm-mcp --setup

The setup wizard writes the correct MCP config for your client (Claude Desktop, Claude Code, Cursor, Windsurf). No credentials are stored in config files — only the socket path.

2. Initialize encrypted vault

bash
openmm-init

This creates an encrypted vault at ~/.openmm/vault.enc containing your wallet key and exchange API credentials. You'll set a password, generate (or import) a wallet, and optionally add exchange keys.

3. Start the server

bash
openmm serve

Type your vault password once. The unified socket starts at /tmp/openmm.sock — all MCP clients connect here. No credentials exist in any config file.

Manual configuration

If you prefer to edit config files directly instead of using --setup:

ClientConfig file
Claude Desktop~/Library/Application Support/Claude/claude_desktop_config.json
Claude Code~/.claude.json
Cursor.cursor/mcp.json
Windsurf~/.codeium/windsurf/mcp_config.json
json
{
  "mcpServers": {
    "openmm": {
      "command": "node",
      "args": ["/path/to/openmm-mcp/dist/index.js"],
      "env": {
        "MCP_TRANSPORT": "stdio",
        "OPENMM_SOCKET": "/tmp/openmm.sock",
        "PAYMENT_SERVER": "https://mcp.openmm.io",
        "X402_TESTNET": "true"
      }
    }
  }
}

Replace /path/to/openmm-mcp with the actual install path. For Claude Desktop, use the full path to node (e.g. from which node) to avoid nvm/PATH issues.

Tip: Run openmm-mcp --setup instead — it writes the correct absolute paths automatically.

No API keys. No private keys. No passwords. Just the socket path.

Without vault (quick start)

You can skip the vault and pass API keys directly in the env block:

json
{
  "mcpServers": {
    "openmm": {
      "command": "npx",
      "args": ["@qbtlabs/openmm-mcp"],
      "env": {
        "MEXC_API_KEY": "your_key",
        "MEXC_SECRET": "your_secret"
      }
    }
  }
}

The vault strengthens every scenario — nothing sensitive exists in any config file, process environment, or client memory.

Client compatibility

ClientWithout vaultWith vault
Claude DesktopAPI keys in envOnly OPENMM_SOCKET
Claude CodeAPI keys in envOnly OPENMM_SOCKET
CursorAPI keys in envOnly OPENMM_SOCKET
WindsurfAPI keys in envOnly OPENMM_SOCKET

All clients connect to the same running openmm serve — one vault, one socket, any client.


Hosted Server with x402 Payments

Connect to mcp.openmm.io — no local installation needed for public data. Pay per tool call with USDC on Base.

How it works

code
AI Agent (Claude / Cursor / Windsurf)
│  MCP stdio — no keys in config
▼
MCP Client Process
(reads OPENMM_SOCKET — credentials never here)
│  Unix socket /tmp/openmm.sock (mode 0600)
▼
openmm serve — unified vault process
┌──────────────────────────────────┐
│  ~/.openmm/vault.enc             │
│  AES-256-GCM + PBKDF2           │  ← wallet key + exchange keys, one vault
│            │                     │
│  Policy Engine                   │  ← maxPerTx, maxPerDay, allowedChains
│  (checked before key is touched) │
│            │                     │
│  signAndWipe()                   │  ← key used inline, wiped from memory
└──────────────────────────────────┘
│  EIP-3009 signature only
▼
mcp.openmm.io → x402 verification → Base L2 settlement

Security properties

PropertyHow
Keys encrypted at restAES-256-GCM + PBKDF2 in ~/.openmm/vault.enc
Keys never in client memoryMCP process only holds socket path
Keys never in config filesNo API keys, no private keys anywhere in config
Process isolationSigning happens in openmm serve, not in the AI agent process
Policy enforcementSpending limits checked before private key is accessed
Memory safetysignAndWipe() — key used once, goes out of scope immediately

Payment flow

  1. Agent calls a tool
  2. Server returns 402 Payment Required with price
  3. openmm serve signs EIP-3009 authorization (gasless — no ETH needed)
  4. Server submits payment on-chain and returns data

Tool Pricing

CategoryToolsPrice (USDC)
Freelist_exchanges$0.00
Readget_ticker, get_orderbook, get_trades, get_ohlcv, get_balance, list_orders, get_cardano_price, discover_pools, get_strategy_status$0.001
Writecreate_order, cancel_order, cancel_all_orders, start_grid_strategy, stop_strategy$0.01

Available Tools (15)

ToolDescriptionParameters
Market Data
list_exchangesList supported exchanges
get_tickerReal-time price, bid/ask, spread, volumeexchange, symbol
get_orderbookOrder book depth (bids/asks)exchange, symbol, limit?
get_tradesRecent trades with buy/sell summaryexchange, symbol, limit?
get_ohlcvOHLCV candlestick dataexchange, symbol, timeframe?, limit?
Account
get_balanceAccount balances (all or filtered)exchange, asset?
list_ordersOpen orders (all or by symbol)exchange, symbol?
Trading
create_orderPlace limit or market orderexchange, symbol, type, side, amount, price?
cancel_orderCancel order by IDexchange, symbol, orderId
cancel_all_ordersCancel all orders for a pairexchange, symbol
Cardano DEX
get_cardano_priceAggregated token price from DEXessymbol
discover_poolsDiscover liquidity poolssymbol, minLiquidity?
Strategy
start_grid_strategyStart grid tradingexchange, symbol, lowerPrice, upperPrice, gridLevels?, totalAmount
stop_strategyStop a running strategystrategyId, cancelOrders?
get_strategy_statusGet strategy statusstrategyId

CLI Reference

Setup & Server

CommandDescription
openmm-initCreate vault, generate/import wallet, add exchanges
openmm-init --import <key>Create vault with an existing private key
openmm serveUnlock vault, start unified socket
openmm-statusShow vault, socket, wallet, and exchange status (no password)

Exchange Credentials

CommandDescription
openmm-exchange listList configured exchanges
openmm-exchange add <id>Add exchange credentials
openmm-exchange remove <id>Remove exchange credentials

Supported exchanges: mexc, gateio, bitget, kraken, binance, coinbase, okx

Wallet

CommandDescription
openmm-wallet infoShow wallet address and chain
openmm-wallet setSet wallet credentials
openmm-wallet exportDisplay private key (requires confirmation)

Spending Policy

CommandDescription
openmm-policy showShow current policy
openmm-policy set max-per-tx <amount>Max USDC per transaction
openmm-policy set max-per-day <amount>Max USDC per day
openmm-policy set allowed-chains <chains>Comma-separated chain IDs
openmm-policy resetClear all policy limits

Advanced

CommandDescription
openmm-vault infoShow vault metadata
openmm-vault change-passwordChange vault password
openmm-vault exportExport all credentials (dangerous)
openmm-vault destroyDelete the vault

Example Usage

Check BTC price:

code
"Get me the BTC/USDT ticker on MEXC"

Place an order:

code
"Buy 0.1 ETH at $2400 on Kraken"

Start grid strategy:

code
"Start a grid strategy on MEXC for INDY/USDT between $0.10 and $0.15 with 10 levels and $500 total"

Check Cardano token:

code
"What's the current price of SNEK on Cardano DEXes?"

Security

  • Vault: AES-256-GCM encrypted at ~/.openmm/vault.enc
  • Password: Interactive terminal only — never in any config file, env var, or CLI flag
  • Socket: /tmp/openmm.sock mode 0600 — the socket is the authentication boundary
  • Policy: Spending limits enforced at the socket before the private key is touched
  • Isolation: Private key never enters any MCP client process memory — signing happens in the openmm serve process via IPC

Development

bash
git clone https://github.com/QBT-Labs/openMM-mcp-agent.git
cd openMM-mcp-agent
npm install
npm run typecheck
npm run lint
npm test
npm run build

Resources

License

MIT

Hosted deployment

A hosted deployment is available on Fronteir AI.

常见问题

io.github.adacapo21/openmm-mcp 是什么?

AI-native crypto trading MCP server — market data, orders, grid strategies & DeFi

相关 Skills

MCP构建

by anthropics

Universal
热门

聚焦高质量 MCP Server 开发,覆盖协议研究、工具设计、错误处理与传输选型,适合用 FastMCP 或 MCP SDK 对接外部 API、封装服务能力。

想让 LLM 稳定调用外部 API,就用 MCP构建:从 Python 到 Node 都有成熟指引,帮你更快做出高质量 MCP 服务器。

平台与服务
未扫描114.1k

Slack动图

by anthropics

Universal
热门

面向Slack的动图制作Skill,内置emoji/消息GIF的尺寸、帧率和色彩约束、校验与优化流程,适合把创意或上传图片快速做成可直接发送的Slack动画。

帮你快速做出适配 Slack 的动图,内置约束规则和校验工具,少踩上传与播放坑,做表情包和演示都更省心。

平台与服务
未扫描114.1k

MCP服务构建器

by alirezarezvani

Universal
热门

从 OpenAPI 一键生成 Python/TypeScript MCP server 脚手架,并校验 tool schema、命名规范与版本兼容性,适合把现有 REST API 快速发布成可生产演进的 MCP 服务。

帮你快速搭建 MCP 服务与后端 API,脚手架完善、扩展顺手,尤其适合想高效验证服务能力的开发者。

平台与服务
未扫描10.2k

相关 MCP Server

Slack 消息

编辑精选

by Anthropic

热门

Slack 是让 AI 助手直接读写你的 Slack 频道和消息的 MCP 服务器。

这个服务器解决了团队协作中需要 AI 实时获取 Slack 信息的痛点,特别适合开发团队让 Claude 帮忙汇总频道讨论或发送通知。不过,它目前只是参考实现,文档有限,不建议在生产环境直接使用——更适合开发者学习 MCP 如何集成第三方服务。

平台与服务
83.4k

by netdata

热门

io.github.netdata/mcp-server 是让 AI 助手实时监控服务器指标和日志的 MCP 服务器。

这个工具解决了运维人员需要手动检查系统状态的痛点,最适合 DevOps 团队让 Claude 自动分析性能数据。不过,它依赖 NetData 的现有部署,如果你没用过这个监控平台,得先花时间配置。

平台与服务
78.4k

by d4vinci

热门

Scrapling MCP Server 是专为现代网页设计的智能爬虫工具,支持绕过 Cloudflare 等反爬机制。

这个工具解决了爬取动态网页和反爬网站时的头疼问题,特别适合需要批量采集电商价格或新闻数据的开发者。不过,它依赖外部浏览器引擎,资源消耗较大,不适合轻量级任务。

平台与服务
35.4k

评论