x402-mcp
@speccy/x402-mcp
Speccy の有料 x402 エンドポイントをラップする MCP サーバーです。MCP 互換の AI エージェントに、予測市場データとサンドボックス化された Python 実行環境という 2 つの強力なツールを提供します。サーバーはあなたの代わりに、呼び出しごとに Base 上の USDC で支払います。
エージェント側に x402 の知識は不要です。エージェント側のウォレット設定も不要です。サーバーをインストールしてエージェントに接続するだけです。完了です。
ツール
ツール | 説明 | 1回あたりのコスト |
| Polymarket の主要な予測市場(出来高・流動性・startDate の並び替え) | $0.01 USDC |
| 隔離された Docker サンドボックスで Python 3.12 コードを実行します(ネットワークなし、読み取り専用 FS、30 秒タイムアウト、64KB 出力) | $0.02 USDC |
Related MCP server: Polymarket MCP Server
インストール
npm install -g @speccy/x402-mcp設定
オペレーターウォレットのキーを設定します(呼び出しごとに x402 を支払うウォレット):
export SPECCY_MCP_WALLET_KEY="0x..." # operator wallet private keyオプションの上書き:
SPECCY_MCP_API_BASE(デフォルト:https://api.speccy.cloud)— Polymarket エンドポイントSPECCY_MCP_EXEC_BASE(デフォルト:https://exec.speccy.cloud)— サンドボックス実行エンドポイント
MCP 互換エージェントへの接続
Claude Desktop(claude_desktop_config.json):
{
"mcpServers": {
"speccy-x402": {
"command": "speccy-x402-mcp",
"env": { "SPECCY_MCP_WALLET_KEY": "0x..." }
}
}
}任意の MCP クライアント(stdio):
SPECCY_MCP_WALLET_KEY=0x... speccy-x402-mcpアーキテクチャ
[Agent] → MCP tool call (stdio) → [this server] → x402 paid fetch → [Speccy endpoint on VPS]
→ [CDP facilitator] → on-chain USDC transferサーバーは 1 つのオペレーターウォレットを保持します。各呼び出しで、そのウォレットから x402 の支払いが実行されます。決済アラートは、Notifier bot を介してオペレーターの Telegram に送信されます(HTTP エンドポイントと同じバックエンドを使用)。
注記
ウォレットキーがオペレーターのマシンから外部に出ることはありません(設定ファイルではなく環境変数として保持)。
Base メインネット(
eip155:8453)で USDC と、マージン用の少量の ETH をウォレットに入金してください(ETH は、ウォレットが x402 以外の転送を行う場合にのみ使用されます)。現在は Base メインネットのみで決済されます。テストネット / 他のチェーンを使用するには、
X402_NETWORK環境変数と対応するファシリテーターが必要です。各呼び出しは独立しておりステートレスです。セッションもサーバー上の状態もありません。
ソース / 課題
ソース: github.com/speccy-ai/x402-mcp(プレースホルダー)
課題 / 機能リクエスト: リポジトリで issue を開くか、Telegram で @SpeccyNotifierbot にメッセージを送ってください。
ライセンス
MIT — Philip (Esla) 作、Speccy 向け
Available Tools
2 toolsexec_pythonA
Run Python code in an isolated Docker sandbox. Costs $0.02 USDC per execution. No network, read-only filesystem, 30s timeout, 64KB output cap.
Inputs: code (required).
get_prediction_marketsB
Get top Polymarket prediction markets. Costs $0.01 USDC per call (x402 settled in background).
Inputs: sort, limit.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
TDQS
Scored across 2 tools
The two tools are completely distinct in purpose: one fetches Polymarket prediction markets, the other executes Python code. There is no realistic risk of an agent confusing them.
Both tool names follow the same lowercase snake_case verb_noun pattern: get_prediction_markets and exec_python. The naming is predictable and consistent.
Two tools is on the thin side, and the tools are unrelated, making the server feel like a loose collection rather than a focused toolkit. The count is not unreasonable for a paid utility server, but it is borderline.
The tools have no shared domain and each is a single isolated operation. get_prediction_markets only returns top markets with no drill-down or follow-up actions, and exec_python is a one-off sandbox execution primitive. The broader x402 workflow is unclear, leaving significant gaps.
Maintenance
Related MCP Connectors
Market data and web intelligence for AI agents, paid per call in USDC on Base via x402.
Market and on-chain crypto data for AI agents. Pay per call in USDC on Base (x402).
17 pay-per-call web, finance, legal and onchain tools for AI agents. USDC on Base via x402/MPP.
Pay-per-call crypto market intelligence for AI agents. USDC on Base via x402.
Related MCP Servers
- AlicenseAqualityCmaintenanceEnables AI agents to discover and analyze prediction markets, execute trades, and manage positions on Polymarket via the Model Context Protocol.786 npm22MIT
- AlicenseNot gradedqualityDmaintenanceEnables AI agents to query Polymarket data such as top wallets, live trades, market details, and smart money flows using natural language through MCP tools.MIT
- AlicenseNot gradedqualityBmaintenanceEnables AI agents to access crypto prices, DeFi yields, Polymarket data, Base chain info, and security scans with pay-per-call via USDC on Base mainnet.MIT
- AlicenseNot gradedqualityDmaintenanceEnables AI agents to autonomously trade, analyze, and manage positions on Polymarket prediction markets with 45 tools, real-time WebSocket monitoring, and enterprise-grade safety features.MIT