Imported from previous forum
I moved to a new broker. They are slow in responding, which is why I'm turning to this online forum.
I'm doing triangular arbitrage. Say there is an opportunity EUR/USD (buy) > EUR/TRY (sell) > USD/TRY (buy). I'm going to list currency and symbol tags below for each of the three orders.
Order 1: 55=EUR/USD 15=EUR
Order 2: 55=EUR/TRY 15=EUR
Order 3: 55=USD/TRY 15=USD
My problem is that all three trades are treated individually. So at the end of the whole process, I have three different positions opened instead of one. Is there a way I can make the currency that is the result of the prior trade be used in the current trade.
So for Order 2, use the EUR I got from Order 1 to acquire TRY and for Order 3 use the TRY to acquire USD?
I should note I have tried Netting in ExecInst and ClOrdLinkID. None of these worked.
Try using NewOrderList with a user-defined ContingencyType(1385) to link the 3 orders together. By convention it would then be a chain of FX orders where two consecutive orders in the list need to have one currency in common to be used in the way you describe above and contingent upon the previous order in the list actually having traded in the amount desired.