sammchardy / python-binance

Binance Exchange API python implementation for automated trading
https://python-binance.readthedocs.io/en/latest/
MIT License
6k stars 2.2k forks source link

future_create_order() ------ how to run faster? #1018

Open bmw7 opened 3 years ago

bmw7 commented 3 years ago

In my test environment, I ran the following code :

order = client.futures_create_order(symbol='ETHUSDT',side='SELL',type='MARKET',quantity=20)

I found that the runtime was over 0.5 seconds! How to make the runtime faster? Preferably within a few milliseconds.

luk0y commented 3 years ago

Probably the issue is with the latency. BTW are you on telegram ?

bmw7 commented 3 years ago

Probably the issue is with the latency. BTW are you on telegram ?

In my server. I ping 'api.binance.com' , the response time is only 5ms.

luk0y commented 3 years ago

Ping cant be use used here. Ping: roundtrip of a tiny packet between your host and the CDN edge node that is closest to you; that packet never sees the Binance server.

I already made what you expecting and we can talk on telegram/discord if that’s okay.

bmw7 commented 3 years ago

Ping cant be use used here. Ping: roundtrip of a tiny packet between your host and the CDN edge node that is closest to you; that packet never sees the Binance server.

I already made what you expecting and we can talk on telegram/discord if that’s okay.

thanks! I am on telegram now. my telegram account is: uprisefuture