This sub-class exposes all the necessary functions required for user to interact with the Fees and MEV Pool of the LSD network. The sub-class exposes all the necessary functions from the StakingFundsVault smart contract. For a user to interact with this sub-class, it is necessary to initialize the Wizard SDK with signer
instance and feesAndMevPoolAddress
.
Fetches the total number of LP tokens issued by the pool.
await wizard.feesAndMevPool.totalShares();
Returns the count of LP tokens in wei in Big Numbers.
Updates the accrued ETH per LP token.
await wizard.feesAndMevPool.updateAccumulatedETHPerLP();
Allows the user to deposit ETH for multiple BLS public keys in a batch. The minimum deposit limit is 0.001 and the maximum is 4 ETH per validator.
blsPublicKeys
: List of BLS public keys to deposit ETH for
amounts
: List of number of ETH to be deposited for corresponding BLS public keys
ethValue
: Amount of ETH attached with the transaction
await wizard.feesAndMevPool.batchDepositETHForStaking(blsPublicKeys, amounts, ethValue);
Allows the user to deposit ETH for a BLS public key and get LP tokens in return.
blsPublicKey
: BLS public key to deposit ETH for
amount
: Amount of ETH to be deposited
ethValue
: Amount of ETH attached with the transaction
await wizard.feesAndMevPool.depositETHForStaking(blsPublicKey, amount, ethValue);
Number of ETH deposited in Big Numbers.
Allows users to burn their LP tokens in batches. A user can provide BLS public key associated with the LP tokens to burn the tokens.
blsPublicKeys
: List of BLS public keys to burn the associated LP tokens for
amounts
: List of number of LP tokens to be burnt
await wizard.feesAndMevPool.burnLPTokensForETHByBLS(blsPublicKeys, amounts);
Allows users to burn a batch of LP tokens to get ETH that has not been staked in return.
lpTokens
: List of address of LP tokens to be burnt
amounts
: List of number of LP tokens to be burnt
await wizard.feesAndMevPool.burnLPTokensForETH(lpTokens, amounts);
Allows users to burn an LP token associated with an unstaked BLS public key to get back ETH.
lpToken
: Address of the LP token to be burnt
amount
: Amount of LP tokens to be burnt
await wizard.feesAndMevPool.burnLPTokenForETH(lpToken, amount);
Allows users to claim ETH from the syndicate contract if the respective BLS public keys have their tokens minted.
recipient
: Ethereum execution layer address that receives the ETH
blsPublicKeys
: List of BLS public keys to claim rewards for
await wizard.feesAndMevPool.claimRewards(recipient, blsPublicKeys);
Preview total ETH accumulated by a staking funds LP token holder associated with many KNOTs that have minted derivatives.
userAddress
: Ethereum execution layer address of the LP token holder
blsPublicKeys
: List of BLS public keys associated with the LP tokens held by the user
await wizard.feesAndMevPool.batchPreviewAccumulatedETHByBLSKeys(userAddress, blsPublicKeys);
Total accumulated ETH in Big Numbers.
Preview total ETH accumulated by a user for multiple LP tokens.
userAddress
: Ethereum execution layer address of the LP token holder
lpTokens
: List of address of LP tokens that the user holds
await wizard.feesAndMevPool.batchPreviewAccumulatedETH(userAddress, lpTokens);
Total ETH accumulated by the user in Big NUmbers.
Preview ETH accumulated by the user for a single LP token.
userAddress
: Ethereum execution layer address of the LP token holder
lpTokens
: Address of the LP token that the user holds
await wizard.feesAndMevPool.previewAccumulatedETH(userAddress, lpToken);
Total ETH accumulated by the user for the LP token.
Claim ETH to the Fees and MEV Pool, from the syndicate, that was accrued by a list of actively staked validators.
blsPublicKeys
: List of BLS public keys to claim ETH for
await wizard.feesAndMevPool.claimFundsFromSyndicateForDistribution(blsPublicKeys);