Mgo

xyz.chain-ops由 chain-ops.xyz 發布官方發布者v2.2.0更新於 Oct 24, 2026

Compare live gas across up to 9 EVM chains and get the cheapest one. x402 pay-per-call on Base.

已驗證Streamable HTTP可網頁執行雲端與基礎設施金融

概覽

AI 產生的概覽

遠端 MCP 伺服器,比較最多 9 條 EVM 鏈的即時 Gas 價格,並在交易前推薦最便宜的鏈。

可以做什麼
  • 取得 4 條主要 EVM 鏈的免費即時 Gas 價格,有速率限制。
  • 在 4 條鏈之間給出最便宜鏈的建議與節省百分比。
  • 比較 9 條網路(含 BNB、Polygon、Avalanche、zkSync 與 Hyperliquid),供跨鏈路由決策使用。
  • 付費方案回傳解碼後的 x402 付款要求,由 x402 用戶端在 Base 上以 USDC 結算。
適用情境
適合交易代理、DeFi 機器人,或在跨鏈、部署合約、送出交易前需要挑選鏈並降低 Gas 成本的助理。免費示範方案足以查詢原始價格;付費方案提供建議與更廣的鏈涵蓋範圍。
執行需求
遠端 Streamable HTTP 端點,無需安裝。免費示範工具不需任何設定。付費工具需要支援 x402 的用戶端,能以有餘額的錢包在 Base(eip155:8453)簽署 EIP-3009 USDC 授權,通常需在用戶端環境設定 EVM 私鑰。需要能連線該 API 及其上游 RPC 與價格來源。
安裝前請注意
付費工具每次呼叫花費 0.001 或 0.002 USDC 並在鏈上結算,助理可能動用真實資金;用戶端需持有私鑰以簽署付款。上游資料來源無法使用時不會結算付款。示範方案限制為每小時 10 次、每天 100 次。Gas 與價格資料來自第三方 RPC 與價格來源。

安裝

在 SourceWeft 中

  1. 開啟 儀表板中的 Mgo,將其新增到工作區。
  2. 為需要使用其工具的對話啟用該服務。

Web executable,透過 Streamable HTTP。 遠端服務在工作區中設定後即可從網頁執行環境執行。

交給代理程式安裝

把這段提示詞貼上到 Claude Code、Codex、Cursor 等代理程式,或 SourceWeft 對話中。代理程式會讀取該伺服器的安裝指南,先向你展示發布者、端點和登入方式,經你同意後再把它新增到你的客戶端。金鑰不會寫進任何命令。

閱讀 https://sourceweft.com/mcp/xyz.chain-ops%2Fmgo/install.md,並按其中說明把這個 MCP 伺服器接入我的客戶端。修改任何設定之前,先告訴我它的發布者、端點和登入方式,等我確認。不要把 API 金鑰寫進命令或我會提交的檔案;問我金鑰應從哪裡取得。

檢視代理程式所依據的安裝指南

其他 MCP 客戶端

把它新增到你客戶端的 mcpServers 設定中。

{
  "mcpServers": {
    "mgo": {
      "type": "http",
      "url": "https://api.mgo.chain-ops.xyz/mcp"
    }
  }
}

README

MGO — Multi-chain Gas Optimizer

An x402-native API that compares real-time gas prices across up to 9 EVM chains and recommends the cheapest one. Built for trading agents, DeFi bots, and any AI agent that needs to optimize transaction costs.

Quick Start

bash
# 1. Install dependenciesnpm install
# 2. Set environment variablescp .env.example .env# Set WALLET_ADDRESS (USDC receiving wallet on Base) and CDP_API_KEY_ID/SECRET (facilitator auth)
# 3. Run locally (same entry point as production)npm start
# 4. Test# Open in browser: http://localhost:3000/gas/demo

Tiers

FeatureDemo (Free)Basic ($0.001)Premium ($0.002)
Chains449
Gas pricesYesYesYes
Cheapest chain recommendationNoYesYes
Savings % calculationNoYesYes
Cost savings estimateNoYesYes
BNB, Polygon, Avalanche, zkSync, HyperliquidNoNoYes
Rate limit10/hr, 100/dayUnlimitedUnlimited

Endpoints

EndpointPaymentDescription
GET /gas/demoFreeRaw gas prices only (10/hr rate limit)
GET /gas/basic$0.001 USDC (x402)4-chain comparison + recommendation + savings
GET /gas/premium$0.002 USDC (x402)9-chain full comparison
GET /pricesFreeNative token USD prices (ETH, BNB, POL, AVAX, HYPE), 60s cache
POST /mcpFree / x402MCP Streamable HTTP endpoint (tools: get_gas_demo, get_cheapest_chain, get_gas_basic, get_gas_premium)
GET /openapi.jsonFreeOpenAPI 3.1 spec
GET /llms.txt, /skill.mdFreeAI agent discovery files
GET /.well-known/x402, /.well-known/x402.json, /.well-known/mcp.json, /.well-known/agent-card.jsonFreeDiscovery metadata
GET /healthFreeServer health check

Payment Flow (x402 v2)

  1. GET /gas/basic or /gas/premium → 402 with requirements in the PAYMENT-REQUIRED header (base64 JSON). A v1-shaped copy is also in the body for legacy clients.
  2. Client signs an EIP-3009 USDC authorization on Base (eip155:8453)
  3. Resend with PAYMENT-SIGNATURE header → facilitator (Coinbase CDP) verifies → data response with PAYMENT-RESPONSE receipt → USDC settled on-chain

If the upstream RPC / price feed is unavailable the API answers 503 and no payment is settled.

javascript
// Client example (@x402/fetch, x402 v2)const { wrapFetchWithPayment } = require("@x402/fetch");const { x402Client } = require("@x402/core/client");const { ExactEvmScheme } = require("@x402/evm/exact/client");const { privateKeyToAccount } = require("viem/accounts");
const client = new x402Client().register("eip155:*", new ExactEvmScheme(privateKeyToAccount(process.env.EVM_PRIVATE_KEY)));const paidFetch = wrapFetchWithPayment(fetch, client);const res = await paidFetch("https://api.mgo.chain-ops.xyz/gas/basic");

MCP (Claude / Cursor / any MCP client)

Remote Streamable HTTP server, no install:

json
{  "mcpServers": {    "mgo-gas": { "url": "https://api.mgo.chain-ops.xyz/mcp" }  }}

Also published as npm package chain-ops-mgo and in the official MCP Registry (xyz.chain-ops/mgo). Paid tools return the decoded x402 payment requirements; pay with an x402 client against the resource URL.

Operations

  • Access log + /stats (Upstash Redis, key via STATS_KEY; send it as x-stats-key header)
  • Demo rate limit and the CoinGecko price cache are shared through the same Redis
  • Secrets never live in this repo: see .env.example

Deploy to Vercel

bash
npm i -g vercelvercel --prod

Platform Registration

  1. BlockRun — Register MCP server URL
  2. Dexter — One-line facilitator config
  3. x402.org — Automatic llms.txt crawling

來源:README.md,提交 f0543bd

工具

4

get_gas_demo

Get free real-time gas prices for 4 major EVM chains (Ethereum, Base, Arbitrum, Optimism). Rate limited 10/hr.

無需輸入參數。

get_cheapest_chain

Get a direct recommendation for the cheapest EVM chain right now with savings %. Free, rate limited.

無需輸入參數。

get_gas_basic

Find the cheapest EVM chain before sending a transaction. Compares live gas across Ethereum, Base, Arbitrum & Optimism and returns the cheapest chain with savings % (e.g. 'Use Base — saves 99.8% vs Ethereum'). Use before bridging, deploying a contract, or any tx where you can choose the chain. $0.001 USDC via x402 on Base, no API key.

無需輸入參數。

get_gas_premium

Find the cheapest EVM chain across 9 networks before transacting. Covers Ethereum, Base, Arbitrum, Optimism, BNB, Polygon, Avalanche, zkSync & Hyperliquid; returns the cheapest chain with savings % for cross-chain routing decisions. Use when you need the widest chain coverage to route a tx to the lowest-fee network. $0.002 USDC via x402 on Base, no API key.

無需輸入參數。

版本歷史

1
  1. v2.2.0最新Sep 16, 2026

評分

已滿足適用檢查項的 100%

該評分衡量此收錄條目的完整程度,依據註冊中心條目、端點與公開來源計算得出。它不是對伺服器本身的評價,也不表示伺服器安全或目前可用:可連通性是帶日期的檢查結果,評分也不包含安裝量或使用者評價。

  • 近 30 天內可連通必需25 分
  • 已宣告認證方式必需10 分
  • 已列出工具必需15 分
  • 描述必需15 分
  • 圖示10 分
  • 文件15 分
  • 授權條款10 分