Using IB Gateway, instead of TWS to communicate with IB
After you become familiar with the bot, you will notice that the TWS graphic interface is pretty useless when trading and it has the very annoying daily
autologoff feature.
Since G-Bot is designed to stay always on 24/7, it may be convenient using the IB gateway instead
of TWS,
which does not have the annoying autologoff feature.
Using the Gateway is just
the same thing as using the TWS. The difference is that it does not have the
interface to manage orders.
When you install the TWS, also the IB Gateway gets installed. You can find it in
the program menu along with the TWS:

When you login the Gateway, make sure to choose API (and not FIX).
Just note that the port it uses by default is 4001, so you need to specify that port in G-Bot (you can just click on the small "gateway" icon, under the pert number to get the default).
The Gateway has API settings, just like the TWS, that you need to set up correctly (just the same as we did for TWS):

The Gateway does not have a way to show account information (we have
requested this feature several times).
However, you can display the data received through the latest folio update
events through G-Bot (use context, "$" icon).