Interactive Brokers Reporting Integration Tool GuideCopy Location
Copy Location
This guide provides information for Interactive Brokers clients requesting a reporting data feed from the IBKR generic reporting interface for purposes of integrating that data with third-party software. We provide, on request, reporting data for the following, each in a separate file:
- P&L
- Position
- Security
- Account
- Activity
- Cash Report
- NAV
Reporting Integration ProcessCopy Location
Copy Location
Integrating your IB reporting data with third-party software includes the following steps:
- Request a reporting data feed from Interactive Brokers by sending an email to reportingintegration@interactivebrokers.com.
- Interactive Brokers prepares the requested files.
- The data files are transmitted to the customer via FTP. See Transmitting Files for detailed instructions.
- You integrate the reporting data files with third-party software.
Reporting File TypesCopy Location
Copy Location
You can choose to receive any of the following types of reporting files.
Start of day (SOD) reporting file types:
- Account – Contains general account information, including Account ID, Title, etc.
- Activity – Contains all trade activity, transfers, dividends, etc. as of the report date.
- Cash Report – Contains cash balances in total, and for the securities and futures segments of your account.
- NAV Report – Contains the Net Asset Value (NAV) of all positions by asset class (stock, securities options, warrants and bonds), cash and accruals.
- P&L – Contains mark-to-mark and short-term (ST) and long-term (LT) realized and unrealized profit and loss information for your account.
- Positions – Contains positions (including cash and accrual balances) as of the report date.
- Securities – Contains detailed security information for all assets traded or held.
End of day (EOD) reporting file types:
- Trade Confirms – Contains trade activity.
See File Layouts for detailed descriptions of the contents of each type of file.
Requesting a Reporting Data FeedCopy Location
Copy Location
When you request a reporting data feed from Interactive Brokers, your email must contain the following information:
- Include the text “I would like to integrate my Interactive Brokers reporting data with _______.” Fill in the blank with the name of the software vendor.
- The software vendor’s contact information.
- Your Interactive Brokers Account ID.
If you are a Master Account User (for example, a Financial Advisor), include the Account IDs of all of the client and/or sub accounts for which you would like reporting data. - The Reporting File Types you are requesting.
- Delivery information: Tell us how you want the files delivered. IB can host the files on our FTP/sFTP site, can upload them to your FTP/sFTP site, or can make them available for download. Include your PGP Public Key for file encryption. See Transmitting Files for detailed instructions.
- Selected options. See Configuring Reporting Data Files for detailed instructions.
Note that the date of the reporting data is always the last business day. Typically there is no data available for New Year’s Day.
File Naming ConventionCopy Location
Copy Location
By default, all reporting data files are text files (*.txt). You can use a different file name extension (for example, *.csv) as long as you include it with your configuration options. Regardless of the type of reporting file you choose to receive, the file name follows this convention:
<AccountID>_<FileType>_<AsOfDate:yyyyMMdd>.txt
where:
- <AccountID> is your Interactive Brokers Account ID. This can be replaced by a Third-Party Account Reference, if provided. See Configuring Reporting Data Files for more information on including a Third-Party Account Reference.
- <FileType> is the type of reporting file: Account, Activity, Positions, or Securities.
- <AsOfDate:yyyyMMdd> is the “as of” reporting date, in the format yyyymmdd. This is always the last business day.
ExamplesCopy Location
Copy Location
U000000_Activity_20100317.txt
This example uses an IB Account ID (U000000), Activity as the file type, and a reporting date of March 17, 2010 (20100317).
XYZCorp_Bookkeeping_20100317.txt
This example uses a Third Party Account Reference (“XYZCorp”) instead of your IB Account ID, a custom value of “Bookkeeping” for the file type (instead of Activity), and a reporting date of March 17, 2010 (20100317)
Configuring Reporting Data FilesCopy Location
Copy Location
When you request IB reporting data, you can configure the features listed below. You must include your configuration options in your request email so that we can create the files correctly.
- File Type: You can choose one or more of these file types: Account, Activity, Cash Report, NAV, P&L, Positions, Securities, and Trade Confirms.
If you choose the Activity file, you can also include summarized trade data. You can summarize trade data by symbol – for each symbol, there will be one record for buys and one record for sells, if applicable. For advisors and brokers, client fees are also summarized at the account level. - If you choose the Positions file, you can choose additional levels of detail called Tax Lots and/or Open Dividend Accruals.
- Preferred Version – This is the version of the report fields. The default is 1.0. As we update our report fields, the Version will also be updated (for example, 1.0 will be updated to 1.1).
- Field Delimiter – Specify pipe or comma. If a data field contains a delimiter character, the data will be wrapped in double quotes. This option is required.
- Date Format – Indicates how dates will appear in the report data. The default date format is yyyymmdd but you can specify whatever date format you prefer. For example, you could request that the date format be mmddyyyy.
- Number Format – Indicates how numbers will appear in the report data. The default number format is ###0.#########.
- Third Party Account Reference – If you provide this information, it will be used in the file names and header records instead of your IB Account ID. This option is not required.
- Include Header/Trailer Records – Specify whether or not you want header and trailer records included in the report data. If you want header and trailer records, they will be included in ALL reporting file types.
- Include Column Header – Specify whether or not you want column headers included in the report data files.
- Use PGP Encryption for FTP/sFTP- Required for the reporting data files. You must provide IBKR with your Public Key and files will be encrypted using the key.
- File name extension – Specify the file name extension of your data files. For example, *.csv. The default value is *.txt.
You do not have to request all of the above configuration options. The default value will be used for any configuration option you do not request.
Use line feed (LF) as the end-of-line character.
Transmitting FilesCopy Location
Copy Location
Report data files can be delivered via FTP or sFTP (or Web Service is alternatively available), options outlined below:
- IBKR hosted Plain FTP (port 21 with PGP encryption)
- IB will provide host, username, password.
- You will provide IB with a PGP public key.
- IB hosted sFTP (port 22 with PGP encryption)- uses key-based authentication
- IB will provide host, username, and directory
- You will provide IB with RSA key for key-based authentication and IP address(es) you will be connecting from.
- Third-party hosted Plain FTP (port 21 with PGP encryption)
- You will provide host, username, password, directory.
- You will provide IB with PGP public key.
- Third-Party hosted sFTP (with PGP encryption). You will provide IBKR with-
- Host, username, directory, port.
- IB will provide RSA key (for key-based authentication) and IP address to white-list.
- Web Service
- We will provide additional details via email.
Tell us in your request email to reportingintegration@interactivebrokers.com your delivery preference and we will assist with setting up the configuration.
If you request delivery of report data files as downloadable files, the files will be available from the Activity Downloads page, which you access from the Third-Party Reports menu in Client Portal.
File LayoutsCopy Location
Copy Location
This chapter describes the layout of each reporting file. The following topics are included:
Start of day (SOD):
- Account File Layout
- Activity File Layout
- Cash Report File Layout
- NAV File Layout
- P&L File Layout
- Positions File Layout
- Security File Layout
End of day (EOD):
The Version column in the file layout tables indicates the version number when a field first appeared.
See Sample Files in the next chapter for samples of reporting files.
Account File LayoutCopy Location
Copy Location
Some items in the Account file layout are identified as configurable. For more information about configuring these items, see Configuring Reporting Data Files.
Header Record
Column | Type | Version | Comments |
---|---|---|---|
Record ID | Alphanumeric | 1.0 | H |
Acct Ref | Alphanumeric | 1.0 | The IB account number (configurable) |
File Type | Alphanumeric | 1.0 | Account (configurable) |
Run Date | Alphanumeric | 1.0 | CCYYMMDD System Date (date format configurable) |
Run Time | Alphanumeric | 1.0 | HH:MM:DD in 24 hour format System Clock Time |
As of Date | Alphanumeric | 1.0 | CCYYMMDD Data On Record As-Of Date (date format configurable) |
Version | Numeric | 1.0 | Version of the file layout used. |
Account Record
Column | Type | Version | Comments |
---|---|---|---|
Type | Alphanumeric | 1.0 | D |
AccountID | Alphanumeric | 1.0 | Account number |
AccountTitle | Alphanumeric | 1.0 | Full account title |
Street | Alphanumeric | 1.0 | Street address |
Street2 | Alphanumeric | 1.0 | Additional street address |
City | Alphanumeric | 1.0 | City |
State | Alphanumeric | 1.0 | State |
Zip | Alphanumeric | 1.0 | Postal code |
Country | Alphanumeric | 1.0 | Country |
AccountType | Alphanumeric | 1.0 | Values will be one of: – Individual (Single) – Institution Master – Institution Client – Advisor Master – Advisor Master Consolidated – Advisor Client – Broker Master – Broker Master Consolidated – Broker Client – Fund Advisor (also known as Fund Investment Manager) |
CustomerType | Alphanumeric | 1.0 | Values will be one of: – Individual – Joint – Trust – IRA – Corporate – Partnership – Limited Liability Corporation – Unincorporated Business – IRA Traditional Rollover – IRA Traditional New – IRA Traditional Inherited – IRA Roth New – IRA Roth Inherited – IRA SEP New – IRA SEP Inherited |
BaseCurrency | Alphanumeric | 1.0 | Base Currency of the account |
MasterAccountID | Alphanumeric | 1.6 | |
Van | Alphanumeric | 1.6 | Virtual Account Number |
Capabilities | Alphanumeric | 1.7 | Account Capabilities: Cash, Margin, Portfolio Margin |
TradingPermissions | Alphanumeric | 1.7 | Asset class Note: Excluded from versions 1.98 and above. |
Alias | Alphanumeric | 1.8 | Account alias |
PrimaryEmail | Alphanumeric | 1.9 | Email address |
DateOpened | Alphanumeric | 1.92 | Date account was opened (date format configurable) |
DateClosed | Alphanumeric | 1.92 | Date account was closed (date format configurable) |
DateFunded | Alphanumeric | 1.98 | Date account was funded (date format configurable) |
IBExecution | Alphanumeric | 1.97 | |
IBPrime | Alphanumeric | 1.97 | |
AccountRepresentative | Alphanumeric | 1.98 | Account Representative |
DefaultTaxBasisElection | Alphanumeric | 1.992 | DefaultTaxBasisElection Values are: – FI (First In, First Out) – LIFO (Last In, First Out) – ML – Maximize Losses – HC – Highest Cost tax lot-matching method – MLG – Maximize Long-Term gain tax lot-matching method – MLL – Maximize Long-Term loss tax lot-matching method – MSG – Maximize Short-Term gain tax lot-matching method – MSL – Maximize Short-Term loss tax lot-matching method – SL – Specific Lot tax lot-matching method |
IBKREntity | Alphanumeric | 1.992 |
Trailer Record
Column | Type | Version | Comments |
---|---|---|---|
Record ID | Alphanumeric | 1.0 | T |
Record Count | Numeric | 1.0 | Including header and trailer |
Activity File LayoutCopy Location
Copy Location
Some items in the Activity file layout are identified as configurable. For more information about configuring these items, see Configuring Reporting Data Files.
Header Record
Column | Type | Version | Comments |
---|---|---|---|
Record ID | Alphanumeric | 1.0 | H |
Acct Ref | Alphanumeric | 1.0 | The IB account number (configurable) |
File Type | Alphanumeric | 1.0 | Activities (configurable) |
Run Date | Alphanumeric | 1.0 | CCYYMMDD System Date (date format configurable) |
Run Time | Alphanumeric | 1.0 | HH:MM:DD in 24 hour format System Clock Time |
As of Date | Alphanumeric | 1.0 | CCYYMMDD Data On Record As-Of Date (date format configurable) |
Version | Numeric | 1.0 | Version of the file layout used. |
Activity Record
Column | Type | Version | Comments |
---|---|---|---|
Type | Alphanumeric | 1.0 | D |
AccountID | Alphanumeric | 1.0 | Account number |
ConID | Numeric | 1.0 | Internal unique identifier for all asset types. Full asset information can be found in the Security File Layout. Empty for Asset Type CASH. |
SecurityID | Alphanumeric | 1.0 | ISIN for US and nonUS securities |
Symbol | Alphanumeric | 1.0 | Empty for Asset Type CASH |
BBTicker | Alphanumeric | 1.91 | Bloomberg ticker |
BBGlobalID | Alphanumeric | 1.94 | Bloomberg Global ID. Note: Limited to 1.94-1.993 |
FIGI | Alphanumeric | 1.994 | Bloomberg Global ID. Note: Limited to 1.994 and greater |
SecurityDescription | Alphanumeric | 1.9 | Description of the security |
AssetType | Alphanumeric | 1.0 | For more information, see Asset Types. |
Currency | Alphanumeric | 1.0 | Currency of the asset |
BaseCurrency | Alphanumeric | 1.0 | Base currency of the account |
TradeDate | Alphanumeric | 1.0 | CCYYMMDD (date format configurable) Note: Clearing trade date (per local exchange) in versions 1.993 and greater |
TradeTime | Alphanumeric | 1.9 | Time of the trade, in HH:mm:ss format Note: Limited to version 1.9-1.992 |
DateTime | Alphanumeric | 1.993 | The Execution Date and Time (CCYYMMDD HH:mm:ss) |
SettleDate | Alphanumeric | 1.0 | CCYYMMDD (date format configurable) |
OrderTime | Alphanumeric | 1.99 | CCYYMMDD HH:mm:ss (date format configurable) |
TransactionType | Alphanumeric | 1.0 | For more information, see Transaction Type. |
ImpactsCash | Alphanumeric | 1.994 | Values will be Y or N |
Quantity | Numeric | 1.0 | Note the following regarding sign: If buy 100 = 100 If sell 100 = -100 If cancel buy = 100 If cancel sell = -100 |
UnitPrice | Numeric | 1.0 | |
GrossAmount | Numeric | 1.0 | Quantity * Price (V1.1 or earlier) -Quantity * Price (V1.2 or later) Note that this is a general formula and does not consider multipliers or notional price (futures), bond pricing (/100), etc. |
SECFee | Numeric | 1.0 | |
Commission | Numeric | 1.0 | Negative amount indicates commission charged. Positive amount indicates commission rebate. For Forex trades, the commission is reported in base currency. |
Tax | Numeric | 1.0 | |
Net | Numeric | 1.0 | Total cash received or delivered. Not included on Forex trades. For Futures and CFDs, this is the transaction MTM. |
NetInBase | Numeric | 1.0 | Total cash received or delivered. For Futures and CFDs, this is the transaction MTM. |
RealizedPL | Numeric | 1.994 | Realized profit or loss in local currency |
RealizedPLInBase | Numeric | 1.994 | Realized profit or loss in base currency |
TradeID | Alphanumeric | 1.0 | Trade ID, unless cancel or correction, then it is the original Trade ID |
TaxBasisElection | Alphanumeric | 1.0 | For trades, represents the tax basis election. Values are: – FI (First In, First Out) – LIFO (Last In, First Out) – ML – Maximize Losses – HC – Highest Cost tax lot-matching method – MLG – Maximize Long-Term gain tax lot-matching method – MLL – Maximize Long-Term loss tax lot-matching method – MSG – Maximize Short-Term gain tax lot-matching method – MSL – Maximize Short-Term loss tax lot-matching method – SL – Specific Lot tax lot-matching method |
Description | Alphanumeric | 1.0 | Activity description |
FXRatetoBase | Numeric | 1.1 | Conversion rate from asset currency to base currency. |
ContraPartyName | Alphanumeric | 1.2 | For DVP records that represent the contra broker. |
ClrFirmID | Alphanumeric | 1.3 | For DVP records, the contra broker’s ID. |
Exchange | Alphanumeric | 1.5 | Included for trades. |
MasterAccountID | Alphanumeric | 1.6 | The Account ID of the master account. |
Van | Alphanumeric | 1.6 | Virtual Account Number |
AwayBrokerCommission | Numeric | 1.93 | The away broker’s commission charge. |
OrderID | Alphanumeric | 1.93 | The IB Order ID. |
ClientReference | Alphanumeric | 1.95 | Client note entered by cashiering. |
TransactionID | 1.96 | The IB TransactionID. | |
ExcecutionID | Alphanumeric | 1.99 | The IB ExecutionID. |
CostBasis | Alphanumeric | 1.99 | The basis of an opening trade is the inverse of proceeds plus commission and tax amount. For closing trades, the basis is the basis of the opening trade. |
Flag | Alphanumeric | 1.99 | For more information, see Flag Codes |
ActionID | Alphanumeric | 1.992 | The IB ActionID |
LevelofDetail | Alphanumeric | 1.992 | Executions, Symbol Summary, Orders |
OrderType | Alphanumeric | 1.994 | |
OrderReference | Alphanumeric | 1.994 | |
BrokerageOrderID | Alphanumeric | 1.994 |
Trailer Record
Column | Type | Version | Comments |
---|---|---|---|
Record ID | Alphanumeric | 1.0 | T |
Record Count | Numeric | 1.0 | Including header and trailer |
Cash Report File LayoutCopy Location
Copy Location
This optional file type contains cash balances in total, and for the securities and futures segments of your account. This information is similar to what is displayed in the Cash Report section of activity statements.
Header Record
Column | Type | Version | Comments |
---|---|---|---|
Record ID | Alphanumeric | 1.0 | H |
Acct Ref | Alphanumeric | 1.0 | The IB account number (configurable) |
File Type | Alphanumeric | 1.0 | Account (configurable) |
Run Date | Alphanumeric | 1.0 | CCYYMMDD System Date (date format configurable) |
Run Time | Alphanumeric | 1.0 | HH:MM:DD in 24 hour format System Clock Time |
As of Date | Alphanumeric | 1.0 | CCYYMMDD Data On Record As-Of Date (date format configurable) |
Version | Numeric | 1.0 | Version of the file layout used. |
Cash Report Record
Column | Type | Version | Comments |
---|---|---|---|
Type | Alphanumeric | 1.0 | D |
AccountID | Alphanumeric | 1.0 | Account number |
ReportDate | 1.96 | CCYYMMDD (date format configurable) | |
Currency | Alphanumeric | 1.0 | Currency |
BaseSummary | Alphanumeric | 1.0 | Is this your base currency (Y or N) |
Change in Insured Bank Deposit | Numeric | 1.0 | Changes in amount swept in Insured Bank Deposit Program by currency. |
Label | Alphanumeric | 1.0 | Description of the item. This matches the line labels in an activity statement. |
Total | Numeric | 1.0 | Total cash balance of your account. |
Securities | Numeric | 1.0 | Cash balance in the Securities segment of your account. |
Futures | Numeric | 1.0 | Cash balance in the Futures (Commodities) section of your account. |
IBUKL | Numeric | 1.0 | Cash balance in your IB-UKL account. |
PAXOS | Numeric | 1.991 | Cash balance in your account held at Paxos. |
Trailer Record
Column | Type | Version | Comments |
---|---|---|---|
Record ID | Alphanumeric | 1.0 | T |
Record Count | Numeric | 1.0 | Including header and trailer |
Position File LayoutCopy Location
Copy Location
Some items in the Positions file layout are identified as configurable. For more information about configuring these items, see Configuring Reporting Data Files.
Header Record
Column | Type | Version | Comments |
---|---|---|---|
Record ID | Alphanumeric | 1.0 | H |
Acct Ref | Alphanumeric | 1.0 | The IB account number (configurable) |
File Type | Alphanumeric | 1.0 | Positions (configurable) |
Run Date | Alphanumeric | 1.0 | CCYYMMDD System Date (date format configurable) |
Run Time | Alphanumeric | 1.0 | HH:MM:DD in 24 hour format System Clock Time |
As of Date | Alphanumeric | 1.0 | CCYYMMDD Data On Record As-Of Date (date format configurable) |
Version | Numeric | 1.0 | Version of the file layout used. |
Position Record
Column | Type | Version | Comments |
---|---|---|---|
Type | Alphanumeric | 1.0 | D for position summary, or L for tax lot O for Open Dividend Accruals |
AccountID | Alphanumeric | 1.0 | Account number |
ConID | Numeric | 1.0 | Internal unique identifier for all asset types. Full asset information can be found in the Security File Layout. Empty for Asset Type CASH, INTACC and DIVACC. |
SecurityID | Alphanumeric | 1.0 | ISIN for US and nonUS securities |
Symbol | Alphanumeric | 1.0 | Empty for Asset Type CASH, INTACC and DIVACC |
BBTicker | Alphanumeric | 1.91 | Bloomberg ticker |
BBGlobalID | Alphanumeric | 1.94 | Bloomberg Global ID Note: Limited to 1.94-1.993 |
FIGI | Alphanumeric | 1.994 | Bloomberg Global ID Note: Limited to 1.994 and greater |
SecurityDescription | Alphanumeric | 1.9 | Description of the security |
AssetType | Alphanumeric | 1.0 | For more information, see Asset Types. |
Currency | Alphanumeric | 1.0 | Currency of the asset |
BaseCurrency | Alphanumeric | 1.0 | Base currency of the account |
Quantity | Numeric | 1.0 | Note the following regarding sign: If Long 100=100 If Short 100=-100 |
QuantityInBase | Numeric | 1.0 | Applies only for Asset Type CASH As of Trade Date. Positive quantity indicates long; negative quantity indicates short. |
CostPrice | Numeric | 1.0 | Average cost price in currency of the asset |
CostBasis | Numeric | 1.0 | Cost basis in the currency of the asset |
CostBasisInBase | Numeric | 1.0 | Cost basis in the base currency of the account |
MarketPrice | Numeric | 1.0 | Current market price in the currency of the asset |
MarketValue | Numeric | 1.0 | Current market value in the currency of the asset |
MarketValueInBase | Numeric | 1.0 | Current market value in the base currency of the account |
UnrealizedPL | Numeric | 1.994 | Unrealized profit or loss in local currency |
UnrealizedPLinBase | Numeric | 1.994 | Unrealized profit or loss in base currency |
OpenDateTime | Alphanumeric | 1.0 | For tax lot rows, the open date and time. Only applies to tax lot rows. |
FxRateToBase | Numeric | 1.1 | Conversion rate from asset currency to base currency. |
ReportDate | Alphanumeric | 1.4 | CCYYMMDD Data On Record As-Of Date (date format configurable) |
SettledQuantity | Numeric | 1.5 | Populated for cash records only. |
SettledQuantityInBase | Numeric | 1.5 | Populated for cash records only. |
MasterAccountID | Alphanumeric | 1.6 | Account ID of the master account. |
Van | Alphanumeric | 1.6 | Virtual Account Number |
AccruedInt | Numeric | 1.93 | The amount of interest accrued on bonds. Populated for the BOND asset category where available. |
OriginatingOrderID | Numeric | 1.94 | Order ID of the originating order |
Multiplier | Numeric | 1.96 | Multiplier of position |
ActionID | Alphanumeric | 1.994 |
Trailer Record
Column | Type | Version | Comments |
---|---|---|---|
Record ID | Alphanumeric | 1.0 | T |
Record Count | Numeric | 1.0 | Including header and trailer |
P&L File LayoutCopy Location
Copy Location
This optional file includes mark-to-mark and short-term (ST) and long-term (LT) realized and unrealized profit and loss information for your account.
Header Record
Column | Type | Version | Comments |
---|---|---|---|
Record ID | Alphanumeric | 1.0 | H |
Acct Ref | Alphanumeric | 1.0 | The IB account number (configurable) |
File Type | Alphanumeric | 1.0 | PL |
Run Date | Alphanumeric | 1.0 | CCYYMMDD System Date (date format configurable) |
Run Time | Alphanumeric | 1.0 | HH:MM:DD in 24 hour format System Clock Time |
As of Date | Alphanumeric | 1.0 | CCYYMMDD Data On Record As-Of Date (date format configurable) |
Version | Numeric | 1.0 | Version of the file layout used. |
PL Record
Column | Type | Version | Comments |
---|---|---|---|
AccountID | Alphanumeric | 1.0 | Account number |
InternalAssetID | Numeric | 1.0 | Internal unique ID for the asset type. |
SecurityID | Alphanumeric | 1.0 | ISIN for US and nonUS securities |
Symbol | Alphanumeric | 1.0 | Empty for asset type CASH |
BBTicker | Alphanumeric | 1.91 | Bloomberg ticker |
BBGlobalID | Alphanumeric | 1.94 | Bloomberg Global ID Note: Limited to 1.94-1.993 |
FIGI | Alphanumeric | 1.994 | Bloomberg Global ID Note: Limited to 1.994 and greater |
SecurityDescription | Alphanumeric | 1.0 | Security name |
AssetType | Alphanumeric | 1.0 | For more information, see Asset Types. |
Currency | Alphanumeric | 1.0 | Currency of the asset |
ReportDate | Alphanumeric | 1.0 | CCYYMMDD (date format configurable) |
PositionMTM | Numeric | 1.0 | Position mark-to-market profit or loss in local currency |
PositionMTMInBase | Numeric | 1.0 | Position mark-to-market profit or loss in base currency |
TransactionMTM | Numeric | 1.0 | Transaction mark-to-market profit or loss in local currency |
TransactionMTMInBase | Numeric | 1.0 | Transaction mark-to-market profit or loss in base currency |
RealizedST | Numeric | 1.0 | Realized short-term profit or loss in local currency |
RealizedSTInBase | Numeric | 1.0 | Realized short-term profit or loss in base currency |
RealizedLT | Numeric | 1.0 | Realized long-term profit or loss in local currency |
RealizedLTInBase | Numeric | 1.0 | Realized long-term profit or loss in base currency |
UnrealizedST | Numeric | 1.0 | Unrealized short-term profit or loss in local currency |
UnrealizedSTInBase | Numeric | 1.0 | Unrealized short-term profit or loss in base currency |
UnrealizedLT | Numeric | 1.0 | Unrealized long-term profit or loss in local currency |
UnrealizedLTInBase | Numeric | 1.0 | Unrealized long-term profit or loss in base currency |
FXRatetoBase | Numeric | 1.992 | Conversion rate from asset currency to base currency. |
Trailer Record
Column | Type | Version | Comments |
---|---|---|---|
Record ID | Alphanumeric | 1.0 | T |
Record Count | Numeric | 1.0 | Including header and trailer |
Security File LayoutCopy Location
Copy Location
Some items in the Security file layout are identified as configurable. For more information about configuring these items, see Configuring Reporting Data Files.
Header Record
Column | Type | Version | Comments |
---|---|---|---|
Record ID | Alphanumeric | 1.0 | H |
Acct Ref | Alphanumeric | 1.0 | The IB account number (configurable) |
File Type | Alphanumeric | 1.0 | Securities (configurable) |
Run Date | Alphanumeric | 1.0 | CCYYMMDD System Date (date format configurable) |
Run Time | Alphanumeric | 1.0 | HH:MM:DD in 24 hour format System Clock Time |
As of Date | Alphanumeric | 1.0 | CCYYMMDD Data On Record As-Of Date (date format configurable) |
Version | Numeric | 1.0 | Version of the file layout used. |
Security Record
Column | Type | Version | Comments |
---|---|---|---|
Type | Alphanumeric | 1.0 | D |
ConID | Numeric | 1.0 | Internal unique identifier for all asset types. |
AssetType | Alphanumeric | 1.0 | For more information, see Asset Types. |
SecurityID | Alphanumeric | 1.0 | ISIN for US and nonUS securities |
Symbol | Alphanumeric | 1.0 | Empty for Asset Type CASH |
CUSIP | Alphanumeric | 1.99 | |
BBTicker | Alphanumeric | 1.91 | Bloomberg ticker |
BBTickerAndExchangeCode | Alphanumeric | 1.91 | Bloomberg ticker + exchange code |
BBGlobalID | Alphanumeric | 1.94 | Bloomberg Global ID. Note: Limited to 1.94-1.993 |
FIGI | Alphanumeric | 1.994 | Bloomberg Global ID Note: Limited to 1.994 and greater |
Description | Alphanumeric | 1.0 | Security Name |
UnderlyingSymbol | Alphanumeric | 1.0 | For derivatives |
UnderlyingCategory | Alphanumeric | 1.97 | For derivatives |
UnderlyingSecurityID | Alphanumeric | 1.97 | For derivatives |
UnderlyingPrimaryExchange | Alphanumeric | 1.97 | For derivatives |
UnderlyingConID | Alphanumeric | 1.98 | For derivatives |
Multiplier | Numeric | 1.0 | |
ExpirationDate | Alphanumeric | 1.0 | CCYYMMDD Option or Future expiration date (date format configurable) |
OptionType | Alphanumeric | 1.0 | P for Put, C for Call |
OptionStrike | Numeric | 1.0 | Strike price |
MaturityDate | Alphanumeric | 1.0 | Bond maturity date |
IssueDate | Alphanumeric | 1.0 | Note issue date |
PrimaryExchange | Alphanumeric | 1.96 | The exchange the security is listed on (stocks only). |
Currency | Alphanumeric | 1.96 | Currency of the asset |
SubCategory | Alphanumeric | 1.97 | Available for stocks |
Issuer | Alphanumeric | 1.98 | Security issuer |
Delivery Month | Alphanumeric | 1.99 | |
PrincipalAdjustFactor | Alphanumeric | 1.992 | IB calculated principal adjustment for bonds |
Trailer Record
Column | Type | Version | Comments |
---|---|---|---|
Record ID | Alphanumeric | 1.0 | T |
Record Count | Numeric | 1.0 | Including header and trailer |
Trade Confirms File LayoutCopy Location
Copy Location
Some items in the Activity file layout are identified as configurable. For more information about configuring these items, see Configuring Reporting Data Files.
Header Record
Column | Type | Version | Comments |
---|---|---|---|
Record ID | Alphanumeric | 1.0 | H |
Acct Ref | Alphanumeric | 1.0 | The IB account number (configurable) |
Trade Confirms | Alphanumeric | 1.0 | Activities (configurable) |
Run Date | Alphanumeric | 1.0 | CCYYMMDD System Date (date format configurable) |
Run Time | Alphanumeric | 1.0 | HH:MM:DD in 24 hour format System Clock Time |
As of Date | Alphanumeric | 1.0 | CCYYMMDD Data On Record As-Of Date (date format configurable) |
Version | Numeric | 1.0 | Version of the file layout used. |
Activity Record
Column | Type | Version | Comments |
---|---|---|---|
Type | Alphanumeric | 2.0 | D |
AccountID | Alphanumeric | 2.0 | Account number |
ConID | Numeric | 2.0 | Internal unique identifier for all asset types. Full asset information can be found in the SOD Security File Layout. Empty for Asset Type CASH. |
SecurityID | Alphanumeric | 2.0 | ISIN for US and nonUS securities |
CUSIP | Alphanumeric | 2.0 | |
Symbol | Alphanumeric | 2.0 | Empty for Asset Type CASH. |
BBTicker | Alphanumeric | 2.0 | Bloomberg ticker |
FIGI | Alphanumeric | 2.0 | Bloomberg Global ID |
SecurityDescription | Alphanumeric | 2.0 | Security Name |
AssetType | Alphanumeric | 2.0 | For more information, see Asset Types. |
Currency | Alphanumeric | 2.0 | Currency of the asset |
BaseCurrency | Alphanumeric | 2.0 | Base currency of the account |
Multiplier | Alphanumeric | 2.0 | |
Strike | Numeric | 2.0 | Strike price |
Expiration | Alphanumeric | 2.0 | CCYYMMDD Option or Future expiration date (date format configurable) |
PutCall | Alphanumeric | 2.0 | P for Put, C for Call |
TradeDate | Alphanumeric | 2.0 | CCYYMMDD (date format configurable) |
TradeTime | Alphanumeric | 2.0 | Time of the trade, in HH:mm:ss format |
SettleDate | Alphanumeric | 2.0 | CCYYMMDD (date format configurable) |
TransactionType | Alphanumeric | 2.0 | For more information, see Transaction Type. |
Quantity | Numeric | 2.0 | Note the following regarding sign: If buy 100 = 100 If sell 100 = -100 If cancel buy = 100 If cancel sell = -100 |
UnitPrice | Numeric | 2.0 | |
GrossAmount | Numeric | 2.0 | Quantity *Price* Multiplier |
Commission | Numeric | 2.0 | Negative amount indicates commission charged. Positive amount indicates commission rebate. For Forex trades, the commission is reported in base currency. |
BrokerExecutionCommission | Numeric | 2.0 | The total amount of IB execution charge applied to the trade. |
BrokerClearingCommission | Numeric | 2.0 | The total amount of IB clearing charge applied to the trade. |
ThirdPartyExecutionCommission | Numeric | 2.0 | The total amount of third party execution charges applied to the trade. |
ThirdPartyClearingCommission | Numeric | 2.0 | The total amount of third party clearing charges applied to the trade. |
ThirdPartyRegulatoryCommission | Numeric | 2.0 | The total amount of third party regulatory charges applied to the trade. |
OtherCommission | Numeric | 2.0 | The total amount of other charges applied to the trade. |
CommissionCurrency | 2.0 | The currency denomination of the commission. | |
Tax | Numeric | 2.0 | |
Exchange | Alphanumeric | 2.0 | Exchange trade was executed |
TradeID | Alphanumeric | 2.0 | Trade ID, unless cancel or correction, then it is the original Trade ID |
OrderID | Alphanumeric | 2.0 | The IB Order ID. |
Description | Alphanumeric | 2.0 | Activity description |
ClrFirmID | Alphanumeric | 2.0 | For DVP records, the contra broker’s ID. |
ContraPartyName | Alphanumeric | 2.0 | For DVP records that represent the contra broker. |
BrokerAccount | Alphanumeric | 2.0 | For DVP records that represent the contra broker account. |
Direction | Alphanumeric | 2.0 | For DVP records |
TransferredCommission | Alphanumeric | 2.0 | For DVP records |
TransferredSECFees | Alphanumeric | 2.0 | For DVP records |
MasterAccountID | Alphanumeric | 2.0 | The Account ID of the master account. |
Van | Alphanumeric | 2.0 | Virtual Account Number |
ExecutionID | Alphanumeric | 1.992 | IB ExecutionID |
NetCash | Alphanumeric | 1.992 | Total Cash received or delivered |
Trailer Record
Column | Type | Version | Comments |
---|---|---|---|
Record ID | Alphanumeric | 1.0 | T |
Record Count | Numeric | 1.0 | Including header and trailer |
Asset TypesCopy Location
Copy Location
The following table lists all of the asset types referenced in the Activity, Positions, and Securities file layouts.
Code | Version | Description |
---|---|---|
BILL | 1.0 | Treasury Bills |
BOND | 1.0 | Bonds (includes corporate and municipal) |
CASH | 1.0 | Forex |
CFD | 1.0 | Contracts for Differences |
CMDTY | 1.0 | Gold or silver (Metals) |
CRYPTO | 1.0 | Cryptocurrency |
DIVACC | 1.1 | Dividend Accrual Balance |
FOP | 1.0 | Future Options |
FSFOP | 1.0 | Options on Futures (Futures Style) |
FSOPT | 1.0 | Options (Futures Style) |
FUND | 1.0 | Mutual Funds |
FUT | 1.0 | Futures |
FXCFD | 1.0 | Contract for Difference on forex |
FXFWD | 1.0 | FX Forwards |
IBGNOTE | 1.0 | IB Notes |
INTACC | 1.1 | Interest Accrual Balance |
IOPT | 1.0 | Structured Products |
OPT | 1.0 | Equity and Index Options |
STK | 1.0 | Stocks (includes ADR, ETF) |
WAR | 1.0 | Warrants |
Activity CodesCopy Location
Copy Location
Transaction Type: The following table lists all of the transaction type codes referenced in the Activity file layouts.
Code | Version | Description |
---|---|---|
ADJ | 1.0 | Adjustments, including: – Client Fees – Commission Adjustments – Option Cash Settlements – Position MTM (Futures, CFDs) – Price Adjustments (Futures, CFDs) |
ASSIGN | 1.0 | Assignment |
BUY | 1.0 | Buy |
CA | 1.0 | Cancel |
CFD | 1.0 | CFD Interest and Fees |
CINT | 1.0 | Credit Interest on cash balances |
CO | 1.0 | Correct |
CORP | 1.0 | Corporate Actions including splits, mergers, acquisitions, etc. Summary of the corporate action will be included in the Description field |
COVER | 1.0 | Cover Short |
DCARD | 1.0 | Debit/Prepaid Card Activity |
DEL | 1.0 | Transfer of Securities (outgoing) |
DEP | 1.0 | Deposit of Funds (including cash transferred in) |
DEPH | 1.0 | Deposits on Hold |
DINT | 1.0 | Debit Interest on cash balances and hard to borrow fees |
DIV | 1.0 | Dividends |
DIVACC | 1.1 | Dividend Accrual Activity |
DIVR | 1.0 | Dividend Reinvestment |
DVPCA | 1.2 | Cancelled DVP |
DVPIN | 1.2 | Incoming DVP |
DVPOUT | 1.2 | Outgoing DVP |
EXE | 1.0 | Exercise |
EXP | 1.0 | Expire |
FRTAX | 1.0 | Foreign Tax Withholding |
GEA | 1.0 | Expiration or Assignment resulting from offsetting positions |
INSDEP | 1.97 | Insured Bank Deposit Interest |
INSDEPACC | 1.97 | Insured Bank Deposit Interest Accrual |
INSDEPXFR | 1.97 | Insured Deposit Transfer |
INTACC | 1.1 | Interest Accrual Activity |
INTP | 1.0 | Investment Interest Paid (from Bonds, Notes) |
INTR | 1.0 | Investment Interest Received (from Bonds, Notes) |
MFEE | 1.0 | Management Fee |
OFEE | 1.0 | Other Fees including market data, order cancellations, etc. |
PIL | 1.0 | Payment in Lieu of Dividends |
REC | 1.0 | Receipt of Securities (incoming) |
SCOM | 1.0 | Settled Commission |
SELL | 1.0 | Sell |
SHORT | 1.0 | Sell Short |
STAX | 1.0 | Sales Tax (Canada PST/GST/HST) |
TTAX | 1.0 | Transaction tax records that are reported separately from trades (i.e., daily trading charges). |
WITH | 1.0 | Withdrawal of Funds (including cash transferred out) |
Flag CodesCopy Location
Copy Location
Flag related to Corporate Action transaction type (CORP) and Unbooked Trades referenced in the Activity file layouts.
Flag Codes | Description |
---|---|
OR | Asset Purchase |
BC | Bond Conversion |
BM | Bond Maturity |
CD | Cash Dividend |
HD | Choice Dividend Delivery |
HI | Choice Dividend Issue |
CC | Contact Consolidation |
CA | Contract Soulte (a type of cash settlement) |
CO | Contract Spin Off |
CS | Contract Split |
CI | Convertible Issue |
CP | Coupon Payment |
DW | Delist Worthless |
DI | Dividend Rights Issue |
ED | Expire Dividend Right |
FA | Fee Allocation |
FS | Forward Split |
GV | Generic Voluntary |
IC | Issue Change |
FI | Issue Forward Split |
TC | Merger |
PC | Partial Call Issue |
RS | Reverse Split |
PI | Share Purchase Issue |
SO | Spin Off |
SD | Stock Dividend |
RI | Subscribable Rights Issue |
SR | Subscribe Rights |
TM | Tbill Maturity |
TI | Tender Issue |
UB | Unbooked Trades |
UE | Unknown Event |
TO | Voluntary Conversion |
CurrencyCopy Location
Copy Location
Available currencies that can populate in data files:
Currency Field | Description |
---|---|
AUD | Australian Dollar |
GBP | British Pound |
CAD | Canadian Dollar |
CNH | Chinese Offshore Yuan |
CZK | Czech Koruna |
DKK | Danish Krone |
EUR | Euro |
HKD | Hong Kong Dollar |
HUF | Hungarian Forint |
ISL | Israeli Shekel |
JPY | Japanese Yen |
KRW | Korean Won |
MYR | Malaysian Ringgit |
MXN | Mexican Peso |
NZD | New Zealand Dollar |
NOK | Norwegian Kroe |
PLN | Polish Zloty |
SAR | Saudi Riyal |
SGD | Singapore Dollar |
ZAR | South African Rand |
SEK | Swedish Krone |
CHF | Swiss Franc |
TRY | Turkish Lira |
AED | United Arab Emirates Dirham |
USD | United States Dollar |
Sample FilesCopy Location
Copy Location
Please reach out to reportingintegration@interactivebrokers.com to request the latest sample files.