erdewit / ib_insync

Python sync/async framework for Interactive Brokers API
BSD 2-Clause "Simplified" License
2.75k stars 723 forks source link

Question: Weekly Log In/2 Factor Authentication? #703

Closed mr-september closed 4 months ago

mr-september commented 4 months ago

I see that many other users/developers have this unsolvable challenge that IBKR logs users out once every week, requiring a full log in with 2FA (on mobile phone). I couldn't find any mention of this in the readme nor documentation.

Has this project found a solution to that? Or is it also a shared limitation?

mattsta commented 4 months ago

I think there's 2.5 common solutions seem to be:

Depends on your needs overall. There's not a clean way to run a 100% unmanaged IBKR gateway system without disabling 2FA which opens up other problems. Or, you can attempt to use the UI restart password filling automation and just remember to be near your phone for remote authorization anytime it restarts (assuming it restarts on a proper schedule and not at random times during outages).

mr-september commented 4 months ago

Thanks. From some other sources on the internet there are 2 other workarounds, to various degrees of reliability and security:

  1. Ibeam github repository
  2. Adding a second user to your IBKR account with trading permissions to the linked account, which apparently does not need 2FA. Still need to deal with automated re-log-ins, but that's easier.

Still a bit of a toss-up between self-hosted servers and QC. Hope easier platforms/methods emerge in the future.

I'll close this thread since my questions are answered.