TickersImp..::..GetHistoricalTicksAsync Method
Get historical values of price, volume_24h, market_cap for a given cryptocurrency.
Namespace:
CoinpaprikaApi.ImpAssembly: CoinpaprikaApi (in CoinpaprikaApi.dll)
Syntax
public Task<IEnumerable<TickItem>> GetHistoricalTicksAsync( string coin_id, DateTimeOffset start, Nullable<DateTimeOffset> end, uint limit, bool quote_btc, TickerInterval interval )
Public Function GetHistoricalTicksAsync ( _ coin_id As String, _ start As DateTimeOffset, _ end As Nullable(Of DateTimeOffset), _ limit As UInteger, _ quote_btc As Boolean, _ interval As TickerInterval _ ) As Task(Of IEnumerable(Of TickItem))
Parameters
- coin_id
- Type: String
The coin identifier (ex: btc-bitcoin).
- start
- Type: DateTimeOffset
The start start point for historical data.
- end
- Type: Nullable<(Of <(<'DateTimeOffset>)>)>
The end point for for historical data.
- limit
- Type: UInt32
The limit of result rows (max 5000). Default: 1000
- quote_btc
- Type: Boolean
Set to true to use BTC as quote currency, else quote is USD.
- interval
- Type: CoinpaprikaApi.Types..::..TickerInterval
The bucket interval.
Return Value
A Task<IEnumerable<TickItem>> representing the asynchronous operation.Exceptions
Exception | Condition |
---|---|
ArgumentNullException | coin_id - Invalid value, coin_id must be a valid coin identified (ex: btc-bitcoin) |
ArgumentOutOfRangeException | end - Invalid value, end must be a valid date after start. |