Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

support paratition account #470

Open
noamagiv opened this issue Jul 24, 2024 · 1 comment
Open

support paratition account #470

noamagiv opened this issue Jul 24, 2024 · 1 comment
Assignees

Comments

@noamagiv
Copy link
Contributor

noamagiv commented Jul 24, 2024

I have multiple Interactive Brokers (IB) accounts connected to one, making it possible to view all account orders from a single account. Let's consider my main account as A and the sub-accounts as B and C.

Up until today, I only worked with Trading Gateway (TG) directly with Account C, and everything worked as expected. Today, I connected Account B and triggered it with the same Toml configuration, with the only change being the account number.

When TG started on Account B, it immediately canceled all open orders for Account C. I assume this happened because TG retrieved open orders without considering the specific account.

I can try to fix it, please assign it to me if you want .

@brndnmtthws
Copy link
Owner

Hmm, I'm not sure if the API has a decent way to support this, but it makes sense. IBKR's API is just trash, but there aren't any better options, sadly. There is an orderRef field, but the documentation doesn't provide enough detail on how to use it: https://interactivebrokers.github.io/tws-api/classIBApi_1_1Order.html#a9aa003d6c9f80b79d822a426e0fd5f5b

In any case, feel free to take a stab at this :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants