A RESTful data service for Interactive Brokers that automatically opens and closes positions given only a symbol and a time to exit the position. This makes it suitable for automatic algorithmic trading. The service automatically determines the number of units (shares) to buy (sell) based on a specified percentage of the portfolio to be allocated to a position.