> ## Documentation Index
> Fetch the complete documentation index at: https://docs.itoflow.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# Analyze your Interactive Brokers portfolio

> Connect Interactive Brokers' MCP server to Itoflow, then ask Itoflow for risk, factor and concentration analysis of your real positions.

Interactive Brokers (IBKR) runs an official MCP server that lets an AI assistant read your account. Connect it to Itoflow, and Itoflow can pull your positions and analyze them with its factor risk model.

**What you'll get:** a dashboard in Itoflow Chat with your exposures by holding, sector, country and currency, factor exposures, the biggest contributors to risk, and anything that breaks the limits you set.

```mermaid theme={null}
flowchart LR
  IBKR[IBKR account] -->|MCP, read access| Chat[Itoflow Chat]
  Chat --> Engine[Factor risk model]
  Engine --> Dashboard[Risk dashboard]
```

## Before you start

* An Itoflow account with MCP connections enabled. Check under **Integrations → MCP servers** (in the sidebar, or under **More** on mobile) in the [app](https://app.itoflow.ai/integrations#connections).
* An Interactive Brokers account. IBKR doesn't offer its AI integration in India or Japan.

## Quick start

> [tab] Ask your AI assistant
>
> With [Itoflow connected to Codex or Claude](https://docs.itoflow.ai/mcp/install.md), paste this into your assistant:
>
> ```text theme={null}
> Use Itoflow for this. First check my Itoflow MCP server connections. If
> Interactive Brokers isn't connected, add https://api.ibkr.com/v1/api/mcp-public
> as a connection named "Interactive Brokers", connect it, and give me the sign-in
> link; wait until I confirm I've signed in and the connection is ready. Then
> start an Itoflow research turn that uses that connection to read my positions
> and cash, shows my long, short, gross and net exposure and my weights by
> holding, sector, country and currency, estimates my factor exposures and
> portfolio volatility with Itoflow's factor risk model, lists the five biggest
> contributors to risk, and flags any position above 10% of net asset value,
> long or short. Wait for it to finish and summarize the result with the date of
> the positions used.
> ```
>
> > [card] [Open in Claude](https://claude.ai/new?q=Use%20the%20Itoflow%20plugin%20\(https%3A%2F%2Fgithub.com%2Fitoflow%2Fskills\)%20for%20this.%20If%20it%20isn't%20installed%20yet%2C%20first%20tell%20me%20how%20to%20install%20it%20and%20sign%20in%20to%20Itoflow%2C%20and%20wait%20until%20I%20confirm.%20Then%3A%0A%0AUse%20Itoflow%20for%20this.%20First%20check%20my%20Itoflow%20MCP%20server%20connections.%20If%20Interactive%20Brokers%20isn't%20connected%2C%20add%20https%3A%2F%2Fapi.ibkr.com%2Fv1%2Fapi%2Fmcp-public%20as%20a%20connection%20named%20%22Interactive%20Brokers%22%2C%20connect%20it%2C%20and%20give%20me%20the%20sign-in%20link%3B%20wait%20until%20I%20confirm%20I've%20signed%20in%20and%20the%20connection%20is%20ready.%20Then%20start%20an%20Itoflow%20research%20turn%20that%20uses%20that%20connection%20to%20read%20my%20positions%20and%20cash%2C%20shows%20my%20long%2C%20short%2C%20gross%20and%20net%20exposure%20and%20my%20weights%20by%20holding%2C%20sector%2C%20country%20and%20currency%2C%20estimates%20my%20factor%20exposures%20and%20portfolio%20volatility%20with%20Itoflow's%20factor%20risk%20model%2C%20lists%20the%20five%20biggest%20contributors%20to%20risk%2C%20and%20flags%20any%20position%20above%2010%25%20of%20net%20asset%20value%2C%20long%20or%20short.%20Wait%20for%20it%20to%20finish%20and%20summarize%20the%20result%20with%20the%20date%20of%20the%20positions%20used.)
> >
> > Start this in Claude with the Itoflow plugin.
>
> > [card] [Open in ChatGPT](https://chatgpt.com/?q=Use%20the%20Itoflow%20plugin%20\(https%3A%2F%2Fgithub.com%2Fitoflow%2Fskills\)%20for%20this.%20If%20it%20isn't%20installed%20yet%2C%20first%20tell%20me%20how%20to%20install%20it%20and%20sign%20in%20to%20Itoflow%2C%20and%20wait%20until%20I%20confirm.%20Then%3A%0A%0AUse%20Itoflow%20for%20this.%20First%20check%20my%20Itoflow%20MCP%20server%20connections.%20If%20Interactive%20Brokers%20isn't%20connected%2C%20add%20https%3A%2F%2Fapi.ibkr.com%2Fv1%2Fapi%2Fmcp-public%20as%20a%20connection%20named%20%22Interactive%20Brokers%22%2C%20connect%20it%2C%20and%20give%20me%20the%20sign-in%20link%3B%20wait%20until%20I%20confirm%20I've%20signed%20in%20and%20the%20connection%20is%20ready.%20Then%20start%20an%20Itoflow%20research%20turn%20that%20uses%20that%20connection%20to%20read%20my%20positions%20and%20cash%2C%20shows%20my%20long%2C%20short%2C%20gross%20and%20net%20exposure%20and%20my%20weights%20by%20holding%2C%20sector%2C%20country%20and%20currency%2C%20estimates%20my%20factor%20exposures%20and%20portfolio%20volatility%20with%20Itoflow's%20factor%20risk%20model%2C%20lists%20the%20five%20biggest%20contributors%20to%20risk%2C%20and%20flags%20any%20position%20above%2010%25%20of%20net%20asset%20value%2C%20long%20or%20short.%20Wait%20for%20it%20to%20finish%20and%20summarize%20the%20result%20with%20the%20date%20of%20the%20positions%20used.)
> >
> > Start this in ChatGPT with the Itoflow plugin.
>
> Using another client? Copy the prompt with the button on the code block.

> [tab] In the Itoflow app
>
> 1. Open [MCP servers](https://app.itoflow.ai/integrations#connections) and select **Add MCP server**.
> 2. Enter `https://api.ibkr.com/v1/api/mcp-public`, select **Add server**, then select **Connect** on the new row.
> 3. Sign in to Interactive Brokers when asked and approve access. Itoflow never sees your IBKR password. When the connection shows **Ready**, its tools are available in all your chats.
> 4. Open [Chat](https://app.itoflow.ai/chat) and ask for a risk analysis of your Interactive Brokers positions: long, short, gross and net exposure, weights by holding, sector, country and currency, factor exposures, the biggest contributors to risk, and any position above 10% of net asset value, long or short.

## Check it worked

The dashboard should list the same positions you see in IBKR, with the date Itoflow read them. It also states its method and any data it couldn't get.

If Itoflow says it can't read your positions or find the IBKR tools, open [MCP servers](https://app.itoflow.ai/integrations#connections). IBKR sign-ins expire; when the connection shows **Sign-in expired**, select **Reconnect**, sign in to Interactive Brokers again, then ask again.

## Ideas for follow-up questions

Ask these in the same conversation with your assistant, or in Chat.

* "Which of my holdings move most with interest rates, and how big is that exposure?"
* "How would my portfolio have done in the 2022 sell-off, based on today's weights?"
* "Show my currency exposure and the effect of a 10% fall in the US dollar."
* "Which positions add the most risk for the return they've delivered?"

## Limits

* The connection works in Chat research turns, whether you start them in the app or from your assistant. Scheduled monitors and strategies can't use it.
* Itoflow reads your positions when you ask. They don't sync to Itoflow by themselves.
* Itoflow doesn't place orders at Interactive Brokers. IBKR's server can draft trade instructions, but they never become orders until you review and submit them in an IBKR platform.
* Analysis isn't investment advice. Check the figures before you act on them.

## Next steps

* [Connect GitHub and MCP servers](https://docs.itoflow.ai/features/integrations.md): manage the connection, and what to do if it fails.
* [Chat](https://docs.itoflow.ai/features/chat.md): how research turns, files and models work.
* [Interactive Brokers: AI integrations](https://www.interactivebrokers.com/en/trading/ai-integrations.php): IBKR's own guide to its MCP server.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.