Indirect Liquidity Providing on QuickSwap
Liquidity staking is a technique used to incentivize liquidity providing to one or more AMM’s trading pairs. Liquidity providers can stake their LP tokens on specific staking pools in order to receive an additional reward over the fees that they accrue from the AMM. A good percentage of the liquidity provided to AMMs today is incentivized through staking.
Impermax is a lending protocol that allows the use of LP tokens as collateral. The main limitation with Impermax was that in some cases users were forced to choose between either staking an LP token or using it on Impermax as collateral, and they couldn’t choose to do both at the same time. However this is not an issue anymore. Impermax now supports staked LP tokens and allows users to earn both the trading fees and the staking rewards while using it as collateral and leveraging it.
Liquidity Staking is Seamless to the User
For Impermax’s users nothing has changed in the user interface and no extra steps are required. By depositing an LP token on Impermax in a pair in which staking is supported, the LP token will be automatically staked. When withdrawing the LP token it will be automatically unstaked and the process will remain the same. As staking rewards are accrued, they will be automatically reinvested (used to buy more LP tokens), so liquidity providers on Impermax won’t have to worry about claiming the staking reward, they will just see their LP tokens balance going up! This applies to all new deposits and all currently deposited tokens. When leveraging an LP token the staking reward will also be multiplied.
Staking rewards reinvesting is enabled through a bounty program. Users will be able to call the reinvest function for reinvesting the staking reward of a certain pair and in exchange for that they can keep a percentage of the reward for themselves (the bounty).
Implications
This new functionality will make Impermax much more versatile and useful and will open the door to a great number of use cases.
For example Impermax is currently launching on many different networks and AMMs. QuickSwap will be supported on June 17th, and it will be followed by SushiSwap, PancakeSwap and others. These Automated Market Makers are giving staking rewards in their native token to strategic pairs and because of this liquidity providers can usually enjoy much higher ROI on these protocols when compared to Uniswap V2. Impermax will now enable liquidity providers to take full advantage of the situation and will allow them to leverage their LP tokens in order to multiply the reward.
Another use case is supporting the liquidity mining programs of some specific trading pairs. Several projects are using liquidity staking in order to attract liquidity to their trading pair and are offering very high APYs to liquidity providers. These projects will now be able to add their pair on Impermax with staking enabled. Impermax’s users will be able to take advantage of the very high APYs and in exchange more liquidity will be added to the trading pair with optimal capital efficiency.
Technical Implementation: Staked LP Tokens
Liquidity staking is implemented on Impermax without making any major changes to the core smart contracts implementation. Impermax’s core contracts have already proven to be working without any bugs or security issues for almost 4 months, and they have been stress tested through some exceptional events like the May 19th crypto crash. Any changes to the core smart contracts at this point would be unnecessary and potentially harmful to the protocol security.
In order to enable staking on Impermax without changing the core smart contracts we introduced the concept of Staked LP Tokens: an ERC20 contract that wraps an LP token and stakes it. All implementation smart contracts can be found in the Github repository. All smart contracts have been audited by CyberUnit.tech.
A user can deposit his LP tokens in the StakedLPToken contract in order to obtain a StakedLPToken ERC20. By doing so his LP tokens will be staked by the contract. StakedLPToken has a reinvest() function which anyone can call. This function redeems the pending staking reward for all the users who have deposited their LP tokens, and use it to obtain more LP tokens and increase the balance in LP tokens of the StakedLPToken contracts. In this way the number of LP tokens owned by anyone who owns the StakedLPToken will increase every time that the reinvest() function is called. In exchange the caller will be rewarded with a reinvest bounty which is a percentage of the total reward.
Normally, on Impermax a new pair can be created through the address of an LP token (the UniswapV2Pair contract). However, the StakedLPToken contract has an interface that mirrors the one of the wrapped LP token, and this allows it to create a new pair on Impermax for a StakedLPToken. Practically speaking, by doing this we enable the use of StakedLPToken on Impermax as collateral. This enables liquidity staking on Impermax while leaving the staking logic outside of the core contracts.
Liquidity Staking on QuickSwap
On June 17th Impermax will launch on Polygon’s QuickSwap. This will be the first form of liquidity staking available on Impermax. QuickSwap has created several staking pools which give the QUICK token as reward in order to incentivize the usage of their protocol.
If you want to learn more about Impermax or to ask any question about liquidity staking you can join the Impermax Telegram group.
__________________________________________________________________________________
We're developing a DeFi ecosystem that will enable investors to leverage their LP Token.
Comments