directa-mcp · 127.0.0.1:10002
Model Context Protocol server
Your portfolio, balance, orders, candles and ticks — handed to an AI client that runs on your machine, next to the terminal that already holds them.
The extension downloads as a file. Open Claude Desktop, go to Settings › Extensions and drop it in — double-clicking works only where the installer registered the file type.
Needs Darwin running and logged in, with API access on under
Sviluppatori › Dev kit, plus uv.
Candles and ticks need Directa's real-time data entitlement.
Install
Every client is asking for the same thing: how to start the server. The snippets below carry the current release, so there is no tag to look up.
…
…
…
| Client | Where the JSON goes |
|---|---|
| Claude Desktop | %APPDATA%\Claude\claude_desktop_config.json · ~/Library/Application Support/Claude/ |
| Cursor | ~/.cursor/mcp.json, or .cursor/mcp.json for one project |
| Windsurf | ~/.codeium/windsurf/mcp_config.json |
| Gemini CLI | ~/.gemini/settings.json |
| VS Code | .vscode/mcp.json — under servers, with "type": "stdio" |
Darwin's sockets are local, so a client that only accepts remote HTTP servers cannot reach them — ChatGPT on web and desktop included. Codex CLI is the way in there.
Surface
Each one ships the protocol's annotations, so your client can group them by permission and ask before the ones that matter — rather than treating a balance check and a market order as the same kind of thing.
Twelve tools that ask Darwin questions and change nothing.
get_portfolio_overviewPositions with derived prices and value, totals, and a reconciliation check against Darwin's own figuresget_positions get_positionOpen positions, as Darwin reports themget_account_balance get_availabilityLiquidity, open P&L, equity, buying power with and without marginget_ordersThe day's orders with decoded state; the live ones on their owncheck_connection get_darwin_statusWhether Darwin is up, and whether the datafeed is on. Needs no loginget_daily_candles get_intraday_candles get_candle_data_range get_tick_dataOHLC candles at any period, and tick-by-tick tradesSix tools that reach the market, your money, or your desktop.
preview_limit_orderWhat an order would cost — commission, amount, instrument — while placing nothingplace_limit_orderA real buy or sell limit, submitted and confirmed in one connectionmodify_order cancel_orderReprice or revoke a working ordercancel_all_ordersRevoke every order on one symbol. The symbol filter is verifiedstart_darwinLaunches dGO so you can log in. The OTP stays yoursOrders stay inert until you switch them on. With DIRECTA_ENABLE_ORDERS off, the four order tools send nothing at all to Darwin and say so.
There is no simulated mode, and that is the protocol's doing: the dAPI has no command that accepts an order without sending it to market, and Directa offers no test account. So the switch is a safety catch rather than a mode — it lives in the server's configuration, where the model cannot reach it. With it on, orders are real, with real money.
Read the wire carefully
Both are handled in the client, and both are why a naive reading of these lines gets the numbers wrong by an order of magnitude.
STOCK;M.100001;10:00:00;20000;0;0;95.0;200
Twenty thousand of nominal at 95.00% of it. The position is worth €19,000 — not €1,900,000. Quantity times price is wrong by 100×.
INFOACCOUNT;10:00:00;A0000;1500.0;1180;95667.0;98347.0;PROD
That field is the portfolio's carrying cost, reconciled to the cent — not a gain. The open P&L is the one before it. Reading them the way they are named overstates the profit by nearly an order of magnitude.