OHCLV (Candles)
Last updated
Last updated
GET
https://api.swivel.exchange/v4/samples?underlying=x&maturity=y&protocol=p&start=z&end=e&interval=f&type=g
This endpoint allows you to request OHLCV points for the given period. Returns OHLCV points with each containing its OHLCV data at the given timestamp.
Name | Type | Description |
---|---|---|
interval*
string
The time between datapoints in minutes dividable by 5. E.g. 5, 15, 30, 60, ...
maturity*
string
The maturity of market in unix seconds.
underlying*
string
The underlying token contract being transacted. E.g. USDC, DAI, etc.,
start*
number
Start of of the period in seconds
end*
number
End of the period in seconds
type*
string
Sampling type e.g. OHLCV
protocol*
integer
A pointer that refers to a given yield bearing market like Lido or Compound.
The protocol enum values:
enum Protocols {
Erc4626 = 0,
Compound = 1,
Rari = 2,
Yearn = 3,
Aave = 4,
Euler = 5,
Lido = 6
}