Gate MCP

一個 Gate MCP(模型上下文協議)伺服器,能夠讓 AI Agent 與 Gate 加密貨幣交易所進行互動,以獲取即時市場數據。

Gate MCP

Gate MCP功能介紹

在2025年2月,Gate MCP將正式推出,為開發者提供基於中心化交易所的現貨和衍生品市場工具,提供真實且可靠的市場數據。

MCP 概述

由Anthropic制定的開源標準協議,將人工智慧與外部服務連接起來

MCP 核心概念

AI 可調用的函數,用於執行查詢、API 調用及其他操作

現貨市場資料

查詢現貨行情、訂單簿、交易和K線數據

合約市場資料

訪問合約、資金費率、溢價指數和清算歷史記錄

即時價格

獲取超過 1,700 個交易對的即時加密貨幣價格

技術分析

檢索多個時間範圍的 K 線/蠟燭圖數據

現貨市場工具

工具描述參數設定返回結果說明
list_currencies獲取所有支持的貨幣及其詳細資訊貨幣列表,包括名稱、精度、存款/提款狀態
get_currency獲取單一貨幣資訊
  • currency (string, required): Currency name, e.g., BTC, ETH
貨幣詳細資訊,包括精度、鏈資訊、存款/提現限制
list_currency_pairs獲取所有支持的交易對交易對列表、交易規則與精度
get_currency_pair獲取單一交易對的詳細資訊
  • currency_pair (string, required): Trading pair name, e.g., BTC_USDT
交易對詳細資訊,包括最小訂單量、價格精度
get_spot_tickers獲取現貨市場行情數據(價格、成交量、漲跌幅)
  • currency_pair (string, optional): Trading pair name. Returns all pairs if not specified
  • timezone (string, optional): Timezone for statistics, e.g., Asia/Shanghai
行情數據包括最新價格、24小時最高/最低、交易量、變化百分比
get_spot_order_book獲取交易對的訂單簿深度
  • currency_pair (string, required): Trading pair name
  • interval (string, optional): Price precision merge level, 0 for no merge
  • limit (number, optional): Number of levels to return, default 10, max 100
  • with_id (boolean, optional): Whether to return depth update ID
買入和賣出價格及數量的委託水準
get_spot_trades獲取近期交易記錄
  • currency_pair (string, required): Trading pair name
  • limit (number, optional): Number of records, default 100
  • last_id (string, optional): Pagination cursor
  • reverse (boolean, optional): Reverse order
  • from (number, optional): Start timestamp (seconds)
  • to (number, optional): End timestamp (seconds)
  • page (number, optional): Page number
交易記錄,包括價格、數量、時間戳記、方向
get_spot_candlesticks獲取 K 線/蠟燭圖數據
  • currency_pair (string, required): Trading pair name
  • interval (string, optional): K-line period: 1m, 5m, 15m, 30m, 1h, 4h, 8h, 1d, 7d, 30d
  • limit (number, optional): Number of data points (mutually exclusive with from/to)
  • from (number, optional): Start timestamp (seconds)
  • to (number, optional): End timestamp (seconds)
OHLCV 數據(開盤價、最高價、最低價、收盤價、成交量)

合約市場工具

工具描述參數設定返回結果說明
list_futures_contracts獲取所有永續合約
  • settle (string, optional): Settlement currency, usdt or btc
  • limit (number, optional): Maximum number to return
  • offset (number, optional): Offset for pagination
合約清單、規格及保證金要求
get_futures_contract獲取單一合約詳細資訊
  • contract (string, required): Contract identifier, e.g., BTC_USDT
  • settle (string, optional): Settlement currency, default usdt
合約細節,包括槓桿、維持保證金率
get_futures_tickers獲取合約市場行情數據
  • settle (string, optional): Settlement currency, default usdt
  • contract (string, optional): Contract identifier. Returns all if not specified
行情資料包括最新價格、標記價格和未平倉合約數量
get_futures_order_book獲取合約委託簿深度
  • contract (string, required): Contract identifier
  • settle (string, optional): Settlement currency, default usdt
  • interval (string, optional): Price precision merge level
  • limit (number, optional): Number of levels
  • with_id (boolean, optional): Whether to return depth update ID
買入和賣出價格及數量的委託水準
get_futures_trades獲取合約交易歷史記錄
  • contract (string, required): Contract identifier
  • settle (string, optional): Settlement currency, default usdt
  • limit (number, optional): Number of records
  • offset (number, optional): Offset for pagination
  • last_id (string, optional): Pagination cursor
  • from (number, optional): Start timestamp (seconds)
  • to (number, optional): End timestamp (seconds)
交易記錄,包括價格、數量、時間戳記
get_futures_candlesticks獲取合約K線數據
  • contract (string, required): Contract identifier
  • settle (string, optional): Settlement currency, default usdt
  • interval (string, optional): K-line period
  • limit (number, optional): Number of data points
  • from (number, optional): Start timestamp (seconds)
  • to (number, optional): End timestamp (seconds)
  • timezone (string, optional): Timezone: all, utc0, utc8
合約的OHLCV數據
get_futures_funding_rate獲取資金利率歷史記錄
  • contract (string, required): Contract identifier
  • settle (string, optional): Settlement currency, default usdt
  • limit (number, optional): Number of records
  • from (number, optional): Start timestamp
  • to (number, optional): End timestamp
資金利率歷史與時間戳記
get_futures_premium_index獲取高級指數 K 線圖
  • contract (string, required): Contract identifier
  • settle (string, optional): Settlement currency, default usdt
  • interval (string, optional): Data point interval
  • limit (number, optional): Number of data points
  • from (number, optional): Start timestamp (seconds)
  • to (number, optional): End timestamp (seconds)
高級指數K線數據
list_futures_liq_orders獲取清算訂單歷史記錄
  • settle (string, optional): Settlement currency, default usdt
  • contract (string, optional): Contract identifier. Returns all if not specified
  • limit (number, optional): Number of records
  • from (number, optional): Start timestamp
  • to (number, optional): End timestamp
清算訂單記錄

產品整合

MCP的使用主要分為兩個場景:Claude桌面版(桌面客戶端)和Claude AI(網絡平台)。

在Claude桌面版中使用

添加 Claude 連接器

claude.ai 的網頁版

前往設定 -> 連接器,然後直接添加官方的 Gate MCP 整合(添加步驟與上方截圖類似)。

應用範例

一旦啟用,您就可以使用自然語言與 Gate 市場數據進行互動:

檢查比特幣價格

目前 BTC/USDT 的最新價格是多少?

U
AI

目前BTC/USDT的價格為$83,742.9,24小時增幅為+1.17%。

獲取市場深度

查看 ETH/USDT 的訂單簿。

U
AI

[顯示前10名的買入和賣出價格及數量]

分析 K 線資料

獲取過去7天比特幣的每日K線數據。

U
AI

[返回K線數據並提供趨勢分析]

OpenAI 已將 MCP 支援整合到 ChatGPT 網頁介面中。

隱私與安全

  • 此服務僅查詢公開的市場資料
  • 不會收集任何個人資訊
  • 所有 API 呼叫均透過 HTTPS 加密傳輸
  • 欲了解更多詳情,請參閱 Gate 隱私政策

支持與反饋

常見問題解答

交易,隨時隨地
qrCode
掃碼下載 Gate App
社群列表
繁體中文
  • 简体中文
  • English
  • Tiếng Việt
  • 繁體中文
  • Español
  • Русский
  • Français (Afrique)
  • Português (Portugal)
  • Bahasa Indonesia
  • 日本語
  • بالعربية
  • Українська
  • Português (Brasil)