Get the FREE Ultimate OpenClaw Setup Guide →

qmt

基于 QMT 平台股票行情的 MCP 服务器,用于提供股票市场数据下载和查询的功能。

Installation
Run this command in your terminal to add the MCP server to Claude Code.
Run in terminal:
Command
claude mcp add --transport stdio jm12138-qmt-mcp-server qmt_mcp_server_stdio

How to use

The QMT MCP Server exposes programmatic access to stock market data derived from the QMT platform. It supports downloading historical stock data, querying instrument details, and retrieving market data for multiple tickers. Core tools exposed by the server include get_current_time_tool (to fetch the current time), get_instrument_detail_tool (to obtain detailed information about a specific stock), download_history_data_tool (to download historical data for a single ticker), download_history_data2_tool (to download historical data for multiple tickers in one go), and get_market_data_ex_tool (to fetch market data for multiple instruments). You can run the server in stdio mode for local use or in SSE mode for deployment, and connect via your client of choice using the provided JSON configurations for popular editors and tools.

How to install

Prerequisites:

  • Python 3.8+ and pip
  • Windows environment (as noted in the README)
  • Network access to install packages from PyPI

Installation steps:

  1. Install the MCP server package from GitHub: pip install git+https://github.com/jm12138/qmt-mcp-server

  2. Verify Python environment is set up and the package is available: python -m pip show qmt-mcp-server

  3. Run the MCP server in stdio mode for local usage (example): qmt_mcp_server_stdio

  4. Alternatively, run the server in SSE mode for deployment: qmt_mcp_server_sse --host 0.0.0.0 --port 8000

  5. Connect a client using the appropriate mcp_config format (see the documentation in the README for client integrations).

Additional notes

Tips and notes:

  • The README indicates Windows is the currently supported client environment; ensure your client environment matches.
  • The provided tools are designed to work with A-share tickers (e.g., 600941.SH, 601857.SH, 600028.SH, 600938.SH). Use get_instrument_detail_tool to fetch instrument metadata before pulling historical data.
  • When downloading historical data, be mindful of trading holidays and data availability for the chosen date range.
  • If deploying SSE mode, make sure the host and port are accessible to your clients (consider configuring firewalls and TLS if needed).
  • Use get_market_data_ex_tool to retrieve aggregated market metrics for multiple instruments to compare performance quickly.
  • If you plan to automate queries, consider batching calls with download_history_data2_tool to optimize network usage.

Related MCP Servers

Sponsor this space

Reach thousands of developers