Lean.Brokerages.InteractiveBrokers
Lean.Brokerages.InteractiveBrokers copied to clipboard
Rate limit does not match IB API rate limits?
Hello, it says here that rate limit is 50 messages/3 seconds: https://github.com/QuantConnect/Lean.Brokerages.InteractiveBrokers/blob/65cd739f89ec1fb56803d4b08e7d5b84aa6491b4/QuantConnect.InteractiveBrokersBrokerage/InteractiveBrokersBrokerage.cs#L158
however, in IB API documentation it says that the limit is 50 messages/1 second:
Aside from the TWS API's inherent limitation of 50 messages per second implying a maximum of 50 orders per second being sent to the TWS, there are no further API-only limitations. Interactive Brokers however requires its users to monitor their Order Efficiency Ratio (OER) as detailed in the Considerations for Optimizing Order Efficiency IBKB article.
https://interactivebrokers.github.io/tws-api/order_limitations.html
Is it the same rate limit? If so, can we change this limit here, in order to allow more orders sent quicker?
Hey @yul! Sorry for the delay, we adjusted the rate limit because we were seeing issues, take a look at https://github.com/QuantConnect/Lean.Brokerages.InteractiveBrokers/pull/29 . There might be room to reduce it but it's risky to undo the change, would require extensive testing many subscriptions/history/orders requests