Staking
RewardRouter contract also exposes functions for staking and unstaking LLP.
In order to stake your LLP
Call RewardRouter.stakeLlp function with:
llpAmount: amount of LLP you want to stake
The amount of LLP you want to stake is transferred from msg.sender to the RewardTracker contract, and equivalent fLLP tokens are minted for msg.sender.
In order to unstake LLP
Call RewardRouter.unstakeLlp function with:
amount: amount of LLP you want to unstake
In this transaction, the amount of fLLP specified is burned, and the LLP is returned back to msg.sender.
In the same step, the incentives collected for users against the staked LLP are also disbursed to msg.sender.
However, the user can also claim his or her reward without unstaking LLP by calling:
RewardTracker.claim functions with:
_receiver: address where the user wants to claim the rewards.
After you call the RewardTracker.claim function, whatever amount of claimable tokens a user has is transferred from the RewardTracker contract to _receiver’s address.
Note: Rewards against the staked LLP are disbursed weekly, which means that claimable rewards for every user are updated weekly.
Last updated