m

mcp-okx

@aahl/mcp-okx
Hosted
0 Stars 14 次浏览 aahl 更新于 2026-08-23

MCP Server for okx.com

MCP 服务配置

复制以下 JSON 到 OPClaw 或其他 MCP 客户端的配置文件中即可使用

{
  "mcpServers": {
    "ghcr.io/aahl/mcp-okx": {
      "args": [
        "run",
        "-i",
        "--rm",
        "ghcr.io/aahl/mcp-okx:latest"
      ],
      "command": "docker"
    },
    "mcp-okx": {
      "args": [
        "mcp-okx@0.1.0"
      ],
      "command": "uvx"
    }
  }
}

可用工具 (5 个)

该服务在 MCP 协议中暴露的工具,AI 可按需调用

tavily_search 14 个参数 需填 1 项

Search the web for current information on any topic. Use for news, facts, or data beyond your knowledge cutoff. Returns snippets and source URLs.

必填参数:query

tavily_extract 6 个参数 需填 1 项

Extract content from URLs. Returns raw page content in markdown or text format.

必填参数:urls

tavily_crawl 11 个参数 需填 1 项

Crawl a website starting from a URL. Extracts content from pages with configurable depth and breadth.

必填参数:url

tavily_map 8 个参数 需填 1 项

Map a website's structure. Returns a list of URLs found starting from the base URL.

必填参数:url

tavily_research 2 个参数 需填 1 项

Perform comprehensive research on a given topic or question. Use this tool when you need to gather information from multiple sources to answer a question or complete a task. Returns a detailed response based on the research findings.

必填参数:input

服务介绍

🆗 OKX MCP Server

<!- - mcp-name: io.github.aahl/mcp-okx - ->

# 📲 Install

# # Method 1: uvx

{
  "mcpServers": {
    "mcp-okx": {
      "command": "uvx",
      "args": ["mcp-okx"],
      "env": {
        "OKX_API_KEY": "your-okx-api-key",
        "OKX_API_SECRET": "api-secret-key",
        "OKX_PASSPHRASE": "api-passphrase",
        "OKX_TRADE_FLAG": "1", #  0: Production trading, 1: Demo trading
        "OKX_BASE_URL": "https://www.okx.com", #  Optional
        "MCP_AUTH_TOKEN": "your-custom-token"  #  Default same as OKX_API_KEY
      }
    }
  }
}

# # Method 2: Docker

mkdir /opt/mcp-okx
cd /opt/mcp-okx
wget https://raw.githubusercontent.com/aahl/mcp-okx/refs/heads/main/docker-compose.yml
docker-compose up -d
{
  "mcpServers": {
    "mcp-okx": {
      "url": "http://0.0.0.0:8811/mcp", #  Streamable HTTP
      "headers": {
        "Authorization": "Bearer your-okx-api-key-or-custom-token"
      }
    }
  }
}

# # ⚙️ Environment variables

  • OKX_API_KEY: API key of your OKX account. Please refer to my api page regarding API Key creation.
  • OKX_API_SECRET: API secret key of your OKX account.
  • OKX_PASSPHRASE: API passphrase of your OKX account.
  • OKX_TRADE_FLAG: 0: Production trading, 1: Demo trading
  • OKX_BASE_URL: Base URL of OKX. Default: https://www.okx.com
  • MCP_AUTH_TOKEN: Custom token for authentication. Default same as OKX_API_KEY

# 🛠️ Available Tools

  • account_config - Get account configuration
  • account_balance - Get account balance
  • account_positions - Get account positions
  • account_position_risk - Get account position risk
  • place_order - Place a new order
  • cancel_order - Cancel an incomplete order
  • get_trade_order - Get order details
  • get_order_list - Get incomplete order list
  • get_orders_history - Get Order History
  • close_positions - Liquidate all positions
  • market_tickers - Get cryptocurrency rankings

相关 MCP 服务