Kucoin / kucoin-api-docs

KuCoin API Docs
Other
273 stars 147 forks source link

429 req in klines call #366

Open cuxito opened 2 years ago

cuxito commented 2 years ago

Hello,

I have the problem that I want to get 8 klines initially and then the last 2 candles every 30 mins but every so often I get a 429 error sometimes on the first call, other times when a time passes. I need to know why this happens

server_time = round(client.get_server_timestamp() / 1000) timerest= round(server_time - 4h) klines = client.get_kline(symbol='BTC-USDT', kline_type='30min', startAt=timerest, endAt=server_time)

and every 30 mins server_time = round(client.get_server_timestamp() / 1000) timerest = server_time - (30 * 60 * 2) klines = client.get_kline(symbol='BTC-USDT', kline_type='30min', startAt=timerest, endAt=server_time)

progressivehed commented 2 years ago

Hello

Do you get 429 or 429000 error on REST Kline?

We have recently optimized Kline rate limit. However you can also use Kline on websocket. It will provide you more real data.

For more information please refere to main API TELEGRAM GROUP and state your issue there to get guide from Admins there.

Also you can refer to API Learning Center Channel