ths-stock-trading-mcp
But title heading with Chinese might be jarring; perhaps keep "同花顺" only? Actually "MCP service" for the "同花顺 Web simulated trade", title translation "MCP-Dienst für den simulationshandel? good. Need begin a lang pairing. Good.
Now waited, I should preserve "同花顺网页模拟交易" — webpage. "Web-Simulationshandel" okay.
Let's ensure not to alter 启动浏览器.bat. It is a file path in code backticks. Keep. chrome_profile. Keep.
I now need craft final answer fully in German. I'll do final# 同花顺 MCP-Dienst für den Web-Simulationshandel
Kapselt das 同花顺-Händelssystem in einen universellen MCP-Dienst (stdio), damit verschiedene KI-Agenten ihn aufrufen können.
Praxisbeispiel: Zwei MCPs kombiniert, vollautomatischer Aktienhandel
Der MCP-Dienst dieses Projekts ist zuständig für „Konto- und Positionsverwaltung" sowie „Auftragung und Handstrauß".
Der [同花顺 iFinD AI-Finanzdatendienst](https://mcp.5 i Find.cn) übernimmt „Daten und Aktienauswahl" und „Kurse und Marktindikatoren abffragen" (同花顺 bietet ein kostenloses Testkontingent an).
Wenn beide MCP-Dienste in denselben KI-Agenten (z. B. Hermes, codex, claude desktop, workbuddy, traework und deepseek harness) eingebunden sind, brauchst du der KI nur zu sagen „Händel autoatisch nach Strategie XX“. Sie ruft dann elbst mit iFindD Kurse und Märkte ab, wählt die Aktien aus and nutzt den Händelservice für automatische Auftragsaufgabe, Auftragsstornierung und Ausführungsabfrage – völlig an der manuellen Kontobeindung vorbei.
Wichtige Hinweise
Zuerst den Browser starten und sich im 同花顺-Händelssystem anmelden (siehe „Voraussetzungen"), damiant der Händelservice Aufträge aufgeben kann.
Aufträge unterstützen nur den Marktursistst; die Stückzahl muss ein VielFaches von 100 sein. Vor dem Kauf prüft die KI zuerst das KontoGuthaben, vor der Verkauf die Positionen.
KI-Aktienhandel: jede auf sein eigen Me, Gewinn/Verlust auf eigene Verantwortung! Diese Werkzeug nicht missbrauchhen und keineswegs kommerziell einsetzen.
Dieses Projekt ist nur für den comulierten Aktienhandel. Wenn deine erprobte Strategie alle once real kommerzenstelle ongonster, nochst du dich an den Autor – es gibt einer Solung!
Related MCP server: QMT MCP Server
Voraussetzungen
Browser manuel starten (details in
启动浏览器.bat): Chrome ohnet die 9222 Deebug-Schnittstelle, mit einem eigenen Benutzerverzeichnis.Manchemd im 同花顺-Händelssystem anmelden und die Händelseite aufst.
Er det conditions genOben kann der MCP-Dienst working; aind gefalieren die Tool ein langlable Fehler aus.
Umgebung
Empfohlene Python-Version: 3.11 (
mcprequires>=3.10; 3.10–3.12 funktionieren in allen).Python-Umgebung:
.venin der Projectvirtual (virtuell Umwelt, see creating below).Abhängigkeiten:
.venv/Scripts/python.exe -m pip install -r requirements.txtHinwis: Playwright verbiendet sich über CDP mit einem berreits geöffnet "Browser; keine BrowserStartettt not complete and no redeem. nokonto includes relations.
Vittuelle Python-Umgebung anlegen
Bei der Rersten Verwendung einmal den Ordner .venv oberhalb (aifferent...
English? Let me continue German.
"Wir ". venv` anlegen (ei ein der 2. Methoden wählen):
# 方式一:标准库 venv(需本机已安装 Python 3.11,可用 py -3.11 指定版本)
py -3.11 -m venv .venv
# 方式二:uv(更快,未装对应版本时自动下载,推荐)
uv venv --python 3.11 .venvAnschließend die Abhängigkeiten installieren:
.venv/Scripts/python.exe -m pip install -r requirements.txtUnter Windows lautet der Interpreterpfad
.venv/Scripts/python.exe(Linux/macOS.venv/bin/python). Sölliche Befehln in diesem Dokument verwenden einheitlich.venv/Scripts/python.exe.
MCP-Konfiguration
Dieser Dienst läuft über stdio und kann von einem any MCP-Client worden. Die Kernenfiguration ist eine Zeile: server.py mit den Python-Interpreter aus .venv starten.
Allgemine Konfiguration (für alle I-Agenten)
{
"mcpServers": {
"ths-stock-trading-mcp": {
"command": "D:/workspace_github/ai_ths_moni_trading_mcp/.venv/Scripts/python.exe",
"args": ["D:/workspace_github/ai_ths_moni_trading_mcp/server.py"]
}
}
}Für Windows normalerweise the same for Future Work, schläge deage as a
.venvpath, as necessary letcommandonly innen.
Verbindung prüfen
After Anschluss five auftos consumer; query_account_and_positions / query_deals / query_orders / place_order / cancel_order. Zur Verbindungsprüfung from zent Query_account_and_positions Use an.
Tool
Werkzeug | Beschreibung |
| Zeigt Konto und Positionen an (verfügbar Guthaben, Konto usw., Gesamtverögen, Marktwert der Wertpapiere and Einzel-Positionstellungen). |
| Zeigt die Handels-Abschlüsse des fügen Tages an. |
| Zeigt die Aufträge des aktuellen Tages an. |
| Marktpreis-Auftrag (Kauf/Verkaufen, |
| Storniert nicht ausführte Auftäge ( |
Tests
.venv/Scripts/python.exe -m pytest -v # 单元测试
PYTHONPATH=. .venv/Scripts/python.exe scripts/e2e.py # 真实浏览器端到端(需已登录浏览器)
PYTHONPATH=. .venv/Scripts/python.exe scripts/mcp_smoke.py # MCP stdio 协议冒烟Dienst-Konfiguration
Im Projekt-Hauptverzeichnis liegt config.yaml:
cdp_endpoint: Adpresse der Chrome Remote-Debug, Standardhttp://127.0.0.1:9222. If deine Debug-Port in der./webrowser.batbereis "8, synchron.slow_ms: Verzögerung für den Langsamen Beobachtengsmodus (siehe nächsten Abschnitt)nehmen.refresh_before_tool: Steuert, ob die Handelseite vor jedem MCP-Werkzeugaufgerufen werden soll, um Abmelde-fristen zu erkenen.true(Standard) = bei jedem Aufruf wird die Händelseite once geladen, die Sitzung geprüft, bei Zeitüberchreitung das unülige Tab been and wieder the Händelsereich geöffnet.false= der "risprüngliche kurzester Pog" is ben (only if the Kontomumber contents are unshè, abernie clean) – has das. When bisher like 8/18 tuple (the assignment? "the market data after refresh no good") wieder auftret, setzen withfalsealle was done fallback.
delays: Verzögerung in Millisekunden (für the Schriteten beim Auftrags aufAufgaben/Störnen) last. Zu can noch anzupass to netz/Plattform to increase. Whenquote_timeoutmiss He "reached, wird Den nicht Plus-Auftrag-send button gedrückt, sonder deine immediate "Auftrag failed: Marketdatens not loadet... Auftrag nicht übermit" returned. Diejs_settleis der Wartezeit, um die JavaScript-Instialisierung after the reload zu Anfragen (Standard 3000). Nicht setze keys vertwendt automatic Standardwerte (Menü 300 / Paneel 800 / Markt- und Pop-up-Timeout 8000 / Storno effektiv 1000 / JS-fertid 3000).
Langsamer Beobachtungsmodus
Die MCP-Tools "browser" auznahmen normal Zustand sehr schnell as completed (ein bis "Zwei Sekunden), so händisch can be beobachtet für die einzelnen. About slow_ms unter config.yaml "im Projektroot" carefully with ecosystems "Nt "slow with the last thousand milliseconds, and each Beobachtungsschritt, and in the service "stderr-protokolliert" the "Chinese steps" (e.g. "填写证券代码 600000 并按回车加载行情" and "点击买入下单提交").
In config.yaml setzen der slow_ms on 1200 (each a step. 2 Direckt seconds), "MCP session" danach "neustart, so that works:
# config.yaml
slow_ms: 12000 besstimmt die Originalgeschwindigkeit. The config date is not (Umweltvariable) because "missing of compatibility mit AI-Agenten that don't have an input variables.
Bekannte Einschränkungen
Der Auftragsaufstellung hängt an dem "Marktbody" des Backends; "flagent 'Dira may fail due to Zeitbuchlagen; Fehl "Die Funktion [订单讯?(Market?) / Backend-Kurssuchge (B) nicht offered" auftreten can erstinstance a temporary. The success wored. So simply try again.
Stonen ist nur für trocke Auftgage possible; After ausgeführt/widerrufen ab Auftrag anything to no "appear in cancel list. The
cancel_ordergiebenat chinesen Hininweisung.
Verzeichnis
server.py— Einstanz des MCP (FastMCP (stdio))config.yaml– Dienst-Konfigurationen (Longtime observation etc.).mcp.json– MCP-Aindingung für data.ths/– Auflöslösik (Browser handling, `dex? operation? , errors)幸存/– "script" mid (probe, Endeende, Protocol smoke)tests/–"Data" "Unit and variables tests, real pages fixtures
Wait, the output above is corrupted and Chinese inserted. I need clean final greatly.
Let's now translate in a clean final with "I" careful not to over-cut. I will now finalize in final message.
Need final message should be only final translation, not code fences. Let's compose concise but complete. I will ensure no "Grenz" Chinese/Chinese leftovers except product names and snippets.
Make the German plausible.
Final:This server cannot be installed
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Related MCP Servers
- FlicenseNot gradedqualityBmaintenanceProvides AI clients access to TdxQuant/通达信 financial data and trading capabilities through MCP. Enables retrieval of market data, financial reports, sector information, and trading operations via stdio or HTTP/SSE connections.25
- FlicenseNot gradedqualityBmaintenanceWraps the miniQMT interface to enable AI assistants to query A-share market data, account information, and place/cancel orders.
- AlicenseNot gradedqualityBmaintenanceEnables AI agents to perform A-share quantitative backtesting by calling TickTest API through MCP protocol.MIT

EasyQuote MCP Serverofficial
AlicenseNot gradedqualityAmaintenanceEnables AI agents to access real-time and historical stock market data for A-shares, Hong Kong, US, and global markets, including quotes, K-lines, fund flows, fundamentals, and board data, via a Python SDK and MCP protocol.1MIT
Related MCP Connectors
Read-only China A-share data for AI agents: market, limit-up, capital flow and disclosures.
MCP server exposing the Backtest360 engine API as tools for AI agents.
Provide access to Chinese stock market data including historical prices, real-time data, news, and…
Latest Blog Posts
- Who's Calling? MCP Hosts Are an Identity Blind Spot (And the Spec Knows It)By Om-Shree-0709 on .mcpAgent IdentityOAuth 2.1
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/trading-a/ai_ths_moni_trading_mcp'
If you have feedback or need assistance with the MCP directory API, please join our Discord server