pub struct Liquidation { /* private fields */ }Implementations§
Source§impl Liquidation
impl Liquidation
Sourcepub fn from_client(client: Client) -> Self
pub fn from_client(client: Client) -> Self
Wraps an already-built client (e.g. from ClientBuilder).
Sourcepub async fn get(
&self,
exchange: impl Into<String>,
symbol: impl Into<String>,
options: LiquidationOptions,
) -> Result<LiquidationResponse>
pub async fn get( &self, exchange: impl Into<String>, symbol: impl Into<String>, options: LiquidationOptions, ) -> Result<LiquidationResponse>
Fetch recent liquidation events for a futures symbol on a given exchange, newest first.
Sourcepub async fn feed(
&self,
options: LiquidationFeedOptions,
) -> Result<LiquidationFeedResponse>
pub async fn feed( &self, options: LiquidationFeedOptions, ) -> Result<LiquidationFeedResponse>
Fetch most recent liquidation events across all futures symbols, newest first. Use together with the /ws/v1/liquidation/feed firehose for a live feed view.
Sourcepub async fn heatmap(
&self,
options: LiquidationHeatmapOptions,
) -> Result<LiquidationHeatmapResponse>
pub async fn heatmap( &self, options: LiquidationHeatmapOptions, ) -> Result<LiquidationHeatmapResponse>
Aggregated long/short liquidation USD by (token, exchange) over a rolling window. Result is cached for ~10s. Sub-1h windows are not supported; use the WS feed for finer granularity.
Sourcepub async fn map(
&self,
options: LiquidationMapOptions,
) -> Result<LiquidationMapResponse>
pub async fn map( &self, options: LiquidationMapOptions, ) -> Result<LiquidationMapResponse>
Coinglass-style liquidation map for one perpetual pair. Returns a price-grid breakdown of where leveraged positions would be liquidated, split by leverage tier (10x / 25x / 50x / 100x) and side (long below current price, short above). Built from current OI + last-24h candle entries + a fixed leverage-cohort prior. Read the assumptions field in the response for the modelling disclaimer. Cached server-side (~5s) so back-to-back polls are cheap.
Sourcepub async fn stats(
&self,
options: LiquidationStatsOptions,
) -> Result<LiquidationStatsResponse>
pub async fn stats( &self, options: LiquidationStatsOptions, ) -> Result<LiquidationStatsResponse>
Aggregate liquidation stats (total, long/short split, count, venue count, biggest single event) over a 1h/4h/24h window. Backs the liquidation page KPI strip for windows the live feed buffer can’t cover.
Sourcepub async fn symbol_history(
&self,
symbol: impl Into<String>,
options: LiquidationSymbolHistoryOptions,
) -> Result<LiquidationSymbolHistoryResponse>
pub async fn symbol_history( &self, symbol: impl Into<String>, options: LiquidationSymbolHistoryOptions, ) -> Result<LiquidationSymbolHistoryResponse>
Bucketed long / short liquidation USD over time for a single (base, quote) pair, joined with the futures-candle close as a reference price line. Long/short USD comes from cex.liquidation (Side=‘sell’ = long position liquidated, ‘buy’ = short). Price comes from candle.futures_1m on the requested exchange — or Binance as the reference when none is specified. Cached ~30s server-side.
Trait Implementations§
Source§impl Clone for Liquidation
impl Clone for Liquidation
Source§fn clone(&self) -> Liquidation
fn clone(&self) -> Liquidation
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more