JKorf / Bybit.Net

A C# .netstandard client library for the Bybit REST and Websocket V5 API focusing on clear usage and models
https://jkorf.github.io/Bybit.Net/
92 stars 65 forks source link

Spot Api Klines Error 2 #45

Closed emin-karadag closed 1 year ago

emin-karadag commented 2 years ago

Hello, I'm running the GetKlinesAsync() method using the Bybit Spot API. However, as far as I can see, the 'CloseTime' field among the incoming data is always null. Thank you.

var klineResult = await client.SpotApi.ExchangeData.GetKlinesAsync("1SOLUSDT", Bybit.Net.Enums.KlineInterval.OneMonth, ct: stoppingToken);
if (klineResult.Success && klineResult.Data.Any())
{

}
kulikov-dev commented 2 years ago

@emin-karadag Looks like it's not a Bybit.net issue. Check this query from any REST checker and the close time will = 0. So, I bet it's a bybit issue, maybe because of this explanation from API docs ("If startTime and endTime are not specified, only the latest candles will be sent").

kulikov-dev commented 1 year ago

@JKorf I guess, it should be closed.