I’m pulling my hair out over a simple thing like canceling orders.
Could someone please explain to me what’s the best way to cancel an order?
I have read the documentation, but it doesn’t help me to answer these questions.
How to detect if the opposing order has been filled? (cancel stop order if take profit filled, or vice versa)
Should I detect via websocket or REST?
A small code example would be awesome