Deribit¶
Fetch market and static data from Deribit API.
You can import the module via
quantflow.data.deribit.Deribit
dataclass
¶
Bases: AioHttpClient
Deribit API client
Example¶
get_book_summary_by_instrument
async
¶
Get the book summary for a given instrument.
| PARAMETER | DESCRIPTION |
|---|---|
instrument_name
|
Instrument name
TYPE:
|
Source code in quantflow/data/deribit.py
get_book_summary_by_currency
async
¶
Get the book summary for a given currency.
For linear futures/options, the currency parameter should be set to "usdc"
and the base parameter should be set to the underlying
currency (e.g. "btc" or "eth").
| PARAMETER | DESCRIPTION |
|---|---|
currency
|
Currency
TYPE:
|
kind
|
Optional instrument kind
TYPE:
|
base
|
Optional base currency for linear futures/options
TYPE:
|
Source code in quantflow/data/deribit.py
get_instruments
async
¶
Get the list of instruments for a given currency.
| PARAMETER | DESCRIPTION |
|---|---|
currency
|
Currency
TYPE:
|
kind
|
Optional instrument kind
TYPE:
|
expired
|
Include expired instruments
TYPE:
|
base
|
Optional base currency for linear futures/options
TYPE:
|
Source code in quantflow/data/deribit.py
get_volatility
async
¶
Provides information about historical volatility for given cryptocurrency
| PARAMETER | DESCRIPTION |
|---|---|
currency
|
Currency
TYPE:
|
Source code in quantflow/data/deribit.py
volatility_surface_loader
async
¶
volatility_surface_loader(currency, *, inverse=True, exclude_open_interest=None, exclude_volume=None, use_perp=False)
Create a VolSurfaceLoader for a given crypto-currency
| PARAMETER | DESCRIPTION |
|---|---|
currency
|
Currency
TYPE:
|
inverse
|
Whether to use inverse or linear options. Inverse options are priced in the base currency, while linear options are priced in USD.
TYPE:
|
exclude_open_interest
|
Exclude options with open interest below this threshold
TYPE:
|
exclude_volume
|
Exclude options with volume below this threshold
TYPE:
|
use_perp
|
Whether to use perpetual as futures proxies
TYPE:
|
Source code in quantflow/data/deribit.py
124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 | |
get_path
async
¶
to_result
async
¶
| PARAMETER | DESCRIPTION |
|---|---|
response
|
HTTP response object
TYPE:
|
Source code in quantflow/data/deribit.py
to_df
async
¶
| PARAMETER | DESCRIPTION |
|---|---|
response
|
HTTP response object
TYPE:
|