1. Contract Interactions

How to stake?

To stake, it is required to deposit any multiple of 32 ETH to the Staking Contract. The deposited ETH will be used by the Staking Contract to fund available validation keys registered by the Operator(s). There is 2 ways to do this:

  1. Transfer the multiple of 32 ETH to the Staking Contract address

  2. Call the deposit() function of the Staking Contract

Both will fund the validators by depositing them on the official Staking Contract and will set the owner of the validator in the Contract to the wallet which signed the deposit or transfer transaction.

Due to gas cost limitation, it is not recommended to deposit more than 40 validators (ie more than 1280 ETH) at once.

How to claim rewards?

A validator(s) owner can claim the accrued EL and CL (Post-Shanghai) rewards on the Staking contract for its validator(s). When withdrawing available rewards, the commission dispatch is performed to the different partners defined in the contract (globalFee and operatorFee).

  1. withdrawCLFee(bytes _publicKey) performs commission dispatching on the available CL Recipient balance of the validator (accrued through EL fees earn when a block is proposed with or without MEV) and sends the rest to the validator owner. Pre-Shanghai this function reverts.

  2. withdrawELFee(bytes _publicKey) performs commission dispatching on the available EL Recipient balance of the validator (accrued through EL fees earn when a block is proposed with or without MEV) and sends the rest to the validator owner.

  3. withdraw() performs both of the above (reverts pre-Shanghai)

These 3 functions can be called by SYS_ADMIN or the validator owner, the net available rewards will always go to the registered validator owner.

[Optional] How to change owner of a validator?

This feature is disabled by default and must be enabled by SYS_ADMIN using setWithdrawerCustomizationEnabled(true)

The owner of a validator can transfer its ownership to an other address if this feature is enabled by SYS_ADMIN. This can be done by calling the following function from the validator owner wallet:

  • setWithdrawer(validatorPubkey, newOwner)

After this call, newOwner will be the recipient of redeemed net rewards of the validator validatorPubkey and the only wallet able to trigger the exit of the validator.

Last updated