Documentation · Section 6 of 6
Broker Connections
Interactive Brokers through the Desktop App and TWS, Trading 212 over its API, the IBKR permissions checklist, manual orders, the Activity log, commissions and credential security.
Read the guide: From trading idea to testable rules: strategy specs and honest backtesting
Broker Connections
Link your broker accounts to dotQuant.
- Interactive Brokers (IBKR) — full support via the dotQuant Desktop App: orders, live positions, and your own market-data entitlement on the chart.
- Trading 212 (T212) — full cloud-to-cloud support via your T212 API key: Invest and Stocks ISA accounts, fractional quantities, order status and fill polling with full economics (fill price, commission).
The portfolio lane executes on both: T212 directly, IBKR through the Desktop App — an IBKR portfolio's reviews and orders wait honestly while the desktop is offline, and IBKR's per-order commissions suit larger contribution slices than T212's commission-free model.
Each connection card shows its configuration state and live connectivity status. Credentials are write-only: once saved they are never returned to the browser — the settings form always shows empty credential fields by design. Archive a connection at any time from its card.
One connection at a time: every operation — an order, a cash read, a portfolio plan — names exactly one connection, and only that connection may serve it. A live account is never silently answered by a paper sibling, or the other way round.
Interactive Brokers (IBKR)
Hybrid local/cloud integration via the dotQuant Desktop App.
Your IBKR credentials and API sessions never leave your local environment — the cloud side only ever sees order instructions and their results. The same bridge relays your entitlement's live market data to your chart (see Broker Live Bars and IBKR Market Data Subscriptions, which lists the subscription each region needs).
IBKR Trading Permissions & API Access
The one-time checklist that lets orders actually execute.
1. TWS API access — TWS/Gateway: Global Configuration → API → Settings: enable ActiveX and Socket Clients, and make sure Read-Only API is unticked. Read-only lets dotQuant see data but blocks every order.
2. Client Portal Read-Only Access — Client Portal → Settings → Account Settings: if Read-Only Access is enabled for your user, no API order can be placed at all (TWS error 460, no trading permissions). Disable it — this is the most common blocker and the least visible one.
3. Trading Permissions — Client Portal → Settings → Trading Permissions: your account needs permission for the country/product you are trading (e.g. Stocks — Europe for a Xetra order). Missing permission also reports as error 460/201. Approval for a new permission can take a day.
After any change, restart TWS or Gateway — permissions and entitlements only take effect in a fresh session.
How a blocked order presents: in TWS it sits parked with a Transmit button (quantity 0/N); on dotQuant the marker shows Rejected with your broker's own reason and the matching fix. A rejected order is kept in your history — the reason is why.
Also worth knowing:
- The account allocation is pinned to the connection you placed the order on — with several IBKR accounts in one TWS, the order goes to the account you named in dotQuant, never a default.
- Market data subscriptions are a separate concern from trading permissions — see IBKR Market Data Subscriptions under Market Data & Charts.
- Paper accounts need TWS logged into the paper user (port 7497 by default); the desktop app connects to both live and paper TWS side by side.
Trading From the Chart
Manual orders on your connected broker.
- Orders are passed through untouched: dotQuant never retries, amends, or auto-cancels an order on your behalf.
- Submission, acceptance, rejection, and fills stream back to the UI in real time.
- Your positions and account remain fully visible and manageable in TWS — dotQuant is a client of your broker, never a custodian.
For agents: the
place-manual-order workflow covers the same path — sanity-check with get-broker-cash / get-broker-position, send submit-order (high-impact — confirm with the user), then follow the verdict on list-orders.Sell by the Close
Out of a buy before the session ends, without watching it.
- The sale is an order of its own: it shows in Activity next to the buy, and in History as Sold by the close with what your broker made of it.
- If your broker refuses the sale (for IBKR: the Desktop App was not running), the position stays open overnight. History shows it as Order failed with the broker's reason, you are emailed, and dotQuant tries again in the next session's last minutes while the shares are still held — or sell them yourself.
- A buy still unfilled at the close has nothing to sell; whatever part fills later is sold at the end of the session it fills in.
- Markets that never close (crypto, FX) have no close to sell by.
For agents:
submit-order with CloseBySessionEnd: true (buys only); the sale appears on list-orders with closesOrderId and closeReason, and on list-history as kind position-closed.Activity: Your Order History
Every order the platform sent on your behalf, with its origin.
- Filter chips split the list by origin: Portfolios, Strategies, Manual — each order carries the portfolio or strategy that produced it.
- Fills show quantity and price (plus commission where the broker reports it); rejections stay in the history with the broker's verbatim reason — a rejected order is a fact, not a failure to hide.
- Each symbol's feed view also carries a Transactions panel with your order history for just that instrument.
For agents: the
list-orders query returns the same records, filterable by origin kind and reference.Broker Commissions & Small Orders
What a fill costs, why tiny orders feel it most, and where dotQuant shows it.
Fixed pricing (the default on many accounts) charges a percentage of trade value with a minimum per order — for example, European equities at ~0.05% with a €3.00 minimum (Xetra and other German venues). US stocks have their own fixed schedule (typically USD 0.005/share, USD 1.00 minimum).
Tiered pricing charges lower IBKR commissions (e.g. ~€1.25 minimum on Xetra) plus the exchange, clearing and regulatory fees passed through at cost. For most small orders it works out cheaper; for larger sizes compare both against IBKR's published schedules.
Small orders feel this the most. A €3.00 minimum on a €40 trade is 7.5% of the position — the price has to move that much before the trade breaks even. If you test with single shares, expect the minimum to dominate; switching the account to Tiered pricing (IBKR Client Portal → account settings → fee plan) usually softens it.
Where you see it in dotQuant: when your broker reports the commission with a fill, it appears on the order's chart marker, together with the realized P/L on closing trades — or, while the live broker price is streaming, the current P/L of the position the fill opened.
Fee figures above are IBKR's and were correct in mid-2026 — their published commission schedules are the authority.
Encryption and Security
Zero-knowledge approach to your API credentials.
Write-only credentials: once saved, keys and secrets are never returned to the browser or displayed in clear text. To update credentials, enter new values and save — existing credentials remain active until replaced.