How to know if bracket order StopLoss or Target is hit through the Orders status API ?

tahseen
So I see that using orders, I can retrieve information related to trades. So I can get to know if Bracket Order has got initiated, which means my position of BUY or SELL is set with SL and TP

But how do I programmatically know if the Bracket Order SL or TP is hit and it is completely closed ?
  • tahseen
    Am using pair concept. A bracket order would have to COMPLETE status to finish completely if am correct. First COMPLETE is of entry execution and second COMPLETE is for SL or TP hit
  • sujith
    Hi,
    You can use postbacks to get notified for every order updates.
  • tahseen
    You didn't understand my question. Whether Orders API or Postback, the data is same. My question is how to know from that data that an open executed bracket order has hit its SL or TP ? Which I am guessing is when there are two COMPLETE status, it means one bracket order executed and then TP or SL hit
  • sujith
    Are you looking for an event when second leg order is placed or second leg order is executed?
  • tahseen
    See I know bracket order executed. But I don't know if that Bracket Order's Target or SL is hit or not. At the moment I am managing using pair approach because am using only Bracket order, so I know if I get 2 status in an instrument as COMPLETE, it means first one was when Bracket Order executed and the second one means TP or SL is hit

    But any simpler approach if you have, you can let me know
Sign In or Register to comment.