Skip to main content

ib_async.flexreport

Generated from the installed ib_async 2.1.0 package. Signatures and defaults are version-specific.

Access to account statement webservice.

Operational guides

Public constants

NameValue
FLEXREPORT_URL'https://ndcdyn.interactivebrokers.com/AccountManagement/FlexWebService/SendRequest?'

FlexError

FlexError(...)

Completeness: advanced-low-level · Canonical ID: ib_async.flexreport.FlexError

Advanced or protocol-level surface classified separately from application utilities.

Sources and provenance

Common base class for all non-exit exceptions.

FlexReport

FlexReport(token=None, queryId=None, path=None)

Completeness: advanced-low-level · Canonical ID: ib_async.flexreport.FlexReport

Advanced or protocol-level surface classified separately from application utilities.

Sources and provenance

To obtain a token:

  • Login to web portal
  • Go to Settings
  • Click on "Configure Flex Web Service"
  • Generate token

df

df(self, topic: str, parseNumbers=True)

Completeness: advanced-low-level · Canonical ID: ib_async.flexreport.FlexReport.df

Advanced or protocol-level surface classified separately from application utilities.

Sources and provenance

Same as extract but return the result as a pandas DataFrame.

download

download(self, token, queryId)

Completeness: advanced-low-level · Canonical ID: ib_async.flexreport.FlexReport.download

Advanced or protocol-level surface classified separately from application utilities.

Sources and provenance

Download report for the given token and queryId.

extract

extract(self, topic: str, parseNumbers=True) -> list

Completeness: advanced-low-level · Canonical ID: ib_async.flexreport.FlexReport.extract

Advanced or protocol-level surface classified separately from application utilities.

Sources and provenance

Extract items of given topic and return as list of objects.

The topic is a string like TradeConfirm, ChangeInDividendAccrual, Order, etc.

get_url

get_url(self)

Completeness: advanced-low-level · Canonical ID: ib_async.flexreport.FlexReport.get_url

Advanced or protocol-level surface classified separately from application utilities.

Sources and provenance

Generate flexreport URL.

load

load(self, path)

Completeness: advanced-low-level · Canonical ID: ib_async.flexreport.FlexReport.load

Advanced or protocol-level surface classified separately from application utilities.

Sources and provenance

Load report from XML file.

save

save(self, path)

Completeness: advanced-low-level · Canonical ID: ib_async.flexreport.FlexReport.save

Advanced or protocol-level surface classified separately from application utilities.

Sources and provenance

Save report to XML file.

topics

topics(self)

Completeness: advanced-low-level · Canonical ID: ib_async.flexreport.FlexReport.topics

Advanced or protocol-level surface classified separately from application utilities.

Sources and provenance

Get the set of topics that can be extracted from this report.