πŸ“ŠOracles

Echelon’s loan origination and liquidation services rely on price feeds from external data sources, also called Oracles. To ensure proper liquidations and avoid any bad debt, Echelon relies on three major oracle sources:

  1. Custom

Echelon primarily uses Pyth oracle price feeds. For assets not supported by Pyth, the protocol uses Switchboard oracles to gather price data. In the event that these providers go down, Echelon will switch to a temporary fallback by performing a cron job that fetches prices from DEXs and CEXs to maintain system integrity. One can view the oracle providers for each market in the prices tab.

Custom Oracles for LSTs:

Echelon allows for looping of LSTs (Liquid Staking Tokens), enabling a higher LTV (Loan-to-value) of 90% in eMode. To minimize risks, the price of LSTs is uniquely calculated through a combination of Pyth, TWAP oracles, and on-chain staking rewards calculation. For instance, the price of sthAPT for liquidation is calculated as follows:

sthAPT = APT price [From Pyth] * thAPT/APT [TWAP oracle from Thalaswap] * sthAPT / thAPT [From Thala staking rate calculation]

  • The APT price comes from one of the safest and most advanced oracles, Pyth.

  • The thAPT/APT Pool (depest liquidity on Aptos).

  • sthAPT is calculated as thAPT + staking rewards (on-chain calculations).

The TWAP (Time-weighted average prices) oracle from Thalaswap further smooths the price over a time interval, reducing the risk of sudden depegs (i.e., high price deviations over a very short interval). Overall, this can significantly reduce the risks of liquidation from LST depegs, while also mitigating any risks of protocol bad debt.

Last updated