'Get latest order updates Binance

I'm trying to create a copy trader which will copy all trades from a main account to child account.

I checked Binance API docs but couldn't figure out much from it.

For example, I need to listen to all order updates such as executed, canceled, placed and so on - what would be the proper way to do that? If someone could give me an example I'd appreciate it.



Solution 1:[1]

Did you have a look at GET /api/v3/allOrders ?

https://binance-docs.github.io/apidocs/spot/en/#all-orders-user_data

It returns all open, cancelled and filled orders for a trading pair. If you use the library python-binance, you can easily call it with :

from binance.client import Client

client = Client(...) # your API keys

orders = client.get_all_orders(symbol='BNBETH')

print(orders)

But you need to provide a trading pair each time.

Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source
Solution 1 Art_Arnaud