How to configure Interactive Brokers automatic import

From this page you can find the guide how to create a Flex Query ID and Token to enable automatic transaction import from Interactive Brokers.

Click “Log in” and then click “Portal Login”

From the menu choose: Reporting -> Flex Queries

Click on the “+” icon, to start configuring the report

  1. From the “Sections” list, click on the “Cash Transactions”.
    1. Choose all options, except Summary
    2. Click “Select All” to select all fields
    3. Click “Save”

  1. From the “Sections” list, click on the “Trades”.
    1. Choose only “Execution”
    2. Click “Select All” to select all fields
    3. Click “Save”

  1. Choose format “XML”
  2. Choose period “Last 30 Calendar Days”
  3. Set Date Format: yyyy-MM-dd
  4. Set Time Format: HH:mm:ss
  5. Set Date/Time Separator: ; (semi-colon)
  6. Set all other options: “No”
  7. Click “Save”

From the report list, click on the name of the created report and there you can see field Query ID. Copy the number to Portfellow.

From the “Flex Queries page” click on the cog icon next to the “Flex Web Service Configuration”.

On the new window tick the “Flex Web Services Status” checkbox, choose 1 Year and leave the IP address field empty and click Generate New Token and click “Save” if needed.


If the Activation Period is too short, you can click on the “Generate New Token” field and choose 1 year expiry time. You need to click this button also to generate a new token, when previous one expires in about 1 year.

Copy “Current Token” field to Portfellow. 

Copy “Current Token” field to Portfellow.