
Capital.com MCP Server
io.github.SimonTarara62由 GitHub 帳號 SimonTarara62 發布v0.3.4更新於 Oct 27, 2026
Unofficial community MCP for the Capital.com Open API. Guarded two-phase trades; demo-first.
發布方自己的服務:capital.new mandate draft tools
概覽
非官方的本機 MCP 伺服器,連接 Capital.com 交易 API,讓助理取得行情、管理自選清單並執行具防護的兩階段交易。
- 可以做什麼
- 檢視工作階段與帳戶狀態、列出與切換帳戶、讀取偏好與活動及交易紀錄、為模擬帳戶加值
- 搜尋市場、讀取市場詳情與快照、瀏覽導覽節點、取得歷史 K 線及客戶多空部位
- 列出持倉與掛單,預覽持倉或掛單,再經確認後執行、修改、平倉或取消
- 建立、讀取、修改與刪除自選清單及其中的市場
- 啟用後透過 WebSocket 推送即時價格、K 線、價格警示與投資組合損益
- 提供行情掃描、交易提案、持倉檢視與即時監控等引導式提示,以及唯讀的 search 與 fetch 轉接器
- 適用情境
- 適合讓助理研究 Capital.com 的交易商品、檢視持倉與掛單,或在明確防護下準備並執行交易,建議先在模擬帳戶試用。不適合需要官方廠商支援整合的情境。
- 執行需求
- 以 Python 套件形式在本機執行(uvx 或 pipx,stdio,也可用 HTTP 遠端架設)。需要 Capital.com 的 API key、API 密碼與帳戶識別碼,可直接提供、透過 .env 檔案路徑提供,或以指令方式讀取密鑰。交易需開啟 CAP_ALLOW_TRADING 並設定 EPIC 允許清單;串流資料需開啟 CAP_WS_ENABLED。需能連線至 Capital.com API。
安裝
在 SourceWeft 中
- 開啟 儀表板中的 Capital.com MCP Server,將其新增到工作區。
- 為需要使用其工具的對話啟用該服務。
Desktop only,透過 STDIO。 STDIO 服務會啟動本機處理程序,因此需要 SourceWeft 桌面主機。
其他 MCP 客戶端
參照 儲存庫 中的啟動說明。
README
Capital.com MCP Server
Self-hosted Model Context Protocol (MCP) server for the Capital.com Open
API, written in Python on FastMCP. It
exposes 42 safe, guarded trading and market-data tools — two-phase
execution, allowlists, demo-first — to any MCP client, over stdio or HTTP. Built
on the tested capitalcom-cli
broker engine (SDK).
Works with Claude Desktop · Claude Code · Cursor · VS Code (Copilot) · Windsurf · ChatGPT — any MCP client.
[PyPI version] [Python versions] [CI] [License: Apache-2.0] [MCP Registry] [Glama quality score] [PyPI downloads]
⚠️ Unofficial & educational. Not affiliated with Capital.com. Trading is risky and this is not financial advice. Trading is disabled by default; all trades are two-phase (preview → confirm → execute) with allowlists and size/rate limits. Start on a demo account. Apache-2.0 licensed.
Install
No clone required — uvx runs it in an isolated, throwaway environment and
always fetches the latest tested release:
Or install a persistent command with pipx:
Pinning for production / real-money use
uvx capitalcom-mcp always runs the latest published release. That is fine
for trying it out, but for production or real-money use, pin the exact
version so an unexpected update can't change tool behavior under you:
The CLI form is uvx capitalcom-mcp==0.3.4 run …. Pin to a version you have
reviewed, and bump deliberately after reading the CHANGELOG.
1. Add your credentials (once)
Get an API key in the Capital.com app: Settings → API integrations (make a
demo key first). Then run the wizard — it writes a 0600 file and prints
the exact client snippet:
This writes ~/.config/capital-mcp/.env. Verify any time (no secrets printed):
Inspect the full effective configuration (redacted, offline) or confirm your credentials actually authenticate:
Prefer a secret manager? Set CAP_API_KEY_CMD / CAP_IDENTIFIER_CMD /
CAP_API_PASSWORD_CMD to a command that prints the secret (e.g.
op read op://vault/..., pass ...). The secret is fetched at launch and never
written to disk or to your client config.
2. Add the server to your client
Every client uses the same command/args/env shape. Pasting
"CAP_ENV_FILE": "<path from init>" keeps secrets out of the client file; or
put CAP_API_KEY/CAP_IDENTIFIER/CAP_API_PASSWORD directly in env.
Claude Desktop
~/Library/Application Support/Claude/claude_desktop_config.json (macOS) /
%APPDATA%\Claude\claude_desktop_config.json (Windows):
Claude Code
Cursor
~/.cursor/mcp.json (global) or .cursor/mcp.json (project):
VS Code (Copilot)
.vscode/mcp.json — note the root key is servers and type: "stdio":
Windsurf
~/.codeium/windsurf/mcp_config.json:
ChatGPT
ChatGPT requires a remote server (stdio is not supported) — see
Remote / VPS hosting. Once your server is reachable over
HTTPS, enable Developer Mode (Settings → Connectors → Advanced) and add the
server URL ending in /mcp. ChatGPT Deep Research connectors call two
read-only tools, search and fetch, which this server implements; full custom
tools require Developer Mode.
Remote / VPS hosting
Run with streamable-HTTP instead of stdio:
Or via env (handy in systemd): CAP_MCP_TRANSPORT=http, CAP_MCP_HOST,
CAP_MCP_PORT. Put it behind a TLS-terminating reverse proxy for any public use.
What's inside — tools, resources & prompts
This server exposes 42 tools, 4 resources, and 7 guided prompts. All
tool names are prefixed cap_ except the two ChatGPT Deep Research adapters
(search, fetch). Mutating tools require confirm=true; trades are two-phase.
The full surface is a stable contract — see API stability.
Session & account
Market data
Trading (read → preview → execute → manage)
Watchlists
Streaming (WebSocket; requires CAP_WS_ENABLED=true)
ChatGPT Deep Research adapters
Resources
Guided prompts
Prompts are reusable workflows your client can launch by name. They emit step-by-step guidance that orchestrates the tools above — they never trade on their own.
Safety model
- Trading off unless
CAP_ALLOW_TRADING=trueand the EPIC is inCAP_ALLOWED_EPICS(orALL). - Two-phase execution;
confirm=truerequired for mutations. - Size, open-position, and daily-order caps;
CAP_DRY_RUN=trueblocks all executions. ATIMEOUTconfirmation is ambiguous — reconcile, don't blindly retry.
Development
End-to-end tests drive every tool through the MCP against the demo API
(read, watchlists, account switch, preview/execute/amend/close/cancel, streaming).
They place real demo orders and clean up after themselves, so use a demo .env
with trading + streaming enabled:
Contributing
Contributions are welcome — this is a community project. Start with CONTRIBUTING.md, browse good first issues, and see the roadmap for where it's heading. The architecture and a worked "add a tool" example are in docs/extending.md.
License
來源:README.md,提交 d16c071
工具
0版本歷史
1- v0.3.4最新Sep 16, 2026
評分
已滿足適用檢查項的 50%
該評分衡量此收錄條目的完整程度,依據註冊中心條目、端點與公開來源計算得出。它不是對伺服器本身的評價,也不表示伺服器安全或目前可用:可連通性是帶日期的檢查結果,評分也不包含安裝量或使用者評價。
- 近 30 天內可連通25 分
請保持端點能夠回應 MCP 握手;SourceWeft 每 30 天探測一次。
- 已宣告認證方式10 分
請在註冊中心條目中宣告憑證請求標頭,或保持端點能夠回應探測,以便判定其認證方式。
- 已列出工具15 分
請讓伺服器在無憑證時回應 tools/list,或發布可在沙箱中無憑證啟動的軟體包。
- 描述必需15 分
- 圖示10 分
- 文件15 分
- 授權條款10 分
其他 Capital 整合
capital.new mandate draft tools
new.capital官方發布者
讓助理建立並驗證 Capital Authority Mandate 草案檔案(重算 SHA-256 摘要),而鑄造仍由人工儀式完成。
CRE Capital: capital stack calculator
capital.cre官方發布者
遠端商用不動產資本結構計算器,讓助理試算優先順位貸款、夾層、特別股與普通股各層,並得出成本、覆蓋率與 IRR。

Amanah Capital Private Markets
由 GitHub 帳號 10parkdrive 發布
遠端 MCP 端點,將助理連接到 Amanah Capital 私募市場,提供 27 個供配置方研究與盡職調查使用的工具。

Cestrian Capital Research
由 GitHub 帳號 Cestrian-HQ 發布
讀取 Cestrian Capital Research 附日期的美股與 ETF 評等、研究筆記、每日市場評論及評等異動。
Issuerwire — capital markets news for AI agents
由 GitHub 帳號 allooloo 發布
一個遠端 MCP 伺服器,為助理提供已上市發行人的簽章資本市場新聞資料列,包括申報、公告與第三方報導。