The stoploss protocol protects uniswap liquidity providers against impermanent losses.
๐ The stoploss protocol is a decentralized protocol against impermanent losses.
Is allows Liquidity Providers (LPs) to limit their impermanent losses on Automated Market Makers (AMMs, eg. Uniswap) in a safe, automated and non-custodial way.
Impermanent losses for LPs is recognized in the industry as the biggest problem of AMMs: "Impermanent loss is by far one of the biggest detriments to the success of DEXs like Uniswap." โ Lucas and Cooper
ยซ :Imp:ermanent losses has become a problem about equal to having an elephant in the living room. It's so big you just can't ignore it. ยป โ :smiling-imp: **
Most LPs supplying liquidity to AMMs such as Uniswap suffer from Impermanent losses. Stoploss allows LPs to limit those losses via a protocol that triggers automated liquidations based on users' maximum acceptable loss.
Example:
OR For the most bullish of us
Smart contracts:
Stoploss Factory => Create Stoploss pools + Stoploss Oracle
Each Stoploss pool is linked to uniswap router 02 and uniswap pair.
Each Stoploss pool use the stoploss Oracle to get price data (TWAP of Uniswap Pair).
Example: To protect against IL in the Uniswap ETH/DAI pair:
We create a Stoploss pool through the factory and an oracle
Users make stoploss order from this Stoploss pool. They can send directly LP Tokens, or they can send DAI that we convert for them into LP token, interacting with Uniswap Router Contract.
We have a subgraph that stores all Stoploss order created and all price oracle updates.
We deployed on kovan on top of live uniswap contracts. Everything works fine.
Data to create stoploss order: web3
Data to fetch stoploss orders states: the graph protocol
Side note: we simplified last minute the oracle to make better UX for the demo.