Interactive Brokers posted a recorded webinar at youtube on Dec 13 2016.
https://www.youtube.com/watch?v=hogXB07OJ_I
The topic is to use IBridgePy, a flexiable and easy-to-use python tool to trade at IB. You can easily get the positions in IBridgePy.