Overview
Interactive Brokers (IBKR) is a global broker covering stocks, options, and futures across every major exchange. Mykola supports IBKR via both Auto Sync (the recommended path — credentials saved once, fills pulled on a schedule) and File Upload (CSV export from IBKR's Flex Web Service).
Supported markets
Stocks · Options · Futures
How to import
Auto Sync (recommended)
IBKR's Flex Web Service mints a long-lived token paired with a saved Flex Query ID. Mykola uses that token to pull a fresh activity statement on every sync tick.
One-time setup in IBKR:
- Sign in to Client Portal at https://www.interactivebrokers.com/.
- Go to Performance & Reports → Flex Queries (or Reports → Flex Queries in the older portal).
- Click Create under Activity Flex Query. Give it a name like Mykola Trades.
- Add the Trades and Cash Transactions sections.
- In Trades, include columns:
DateTime,Symbol,AssetClass,BuySell,Quantity,TradePrice,IBCommission,Multiplier,Conid. - In Cash Transactions, include
Date,Amount,Type.
- In Trades, include columns:
- Set Period to Last 365 calendar days (or longer) and Format to CSV.
- Save the query and note its Query ID (a numeric string).
- Go to Settings → Account Settings → Flex Web Service and enable it. IBKR will show your Token (a long hex string). Copy it.
In Mykola:
- Open Accounts → Add a broker account.
- Pick Interactive Brokers, name the account, paste the Flex Query ID and the Flex Token.
- Hit Add account. The next scheduler tick pulls your fills; the account page shows the last sync time.
File Upload
If you'd rather not store a token, you can do the same Flex query manually and upload the resulting CSV:
- From the Flex Queries page, click Run on the query.
- Download the CSV.
- In Mykola: Accounts → your Manual account → Import CSV, pick the Interactive Brokers preset, upload the file.
Troubleshooting
- "Could not authenticate with Flex" — Flex tokens expire if not used for a long stretch. Re-generate one from Settings → Flex Web Service and update the account.
- Missing options multiplier — make sure the Multiplier column is included in your Flex query's Trades section. Without it, options notional/ROI math is wrong by 100×.
- Account just created and no trades yet — IBKR's Flex Web Service requires the account to be at least 24 hours old before queries return data.