How would I know whether my previous trade was an oco order or a normal order?

I am using python binance and my program wants to check that from all the previous orders which orders were oco. Is there any function available in binance to check this?

Hi. If you are subscribing the user data stream, you can check on the attribute ā€˜gā€™ of executionReport. If it is an OCO order, it should have its OrderListId, which is different from -1.

1 Like