5. Minting osETH
Overview
Checking Minting Limits
const staker = new EthereumStaker({ network: 'hoodi' })
await staker.init()
const { maxMint } = await staker.getMaxMintForVault({
delegatorAddress: userAddress,
validatorAddress
})
console.log(maxMint) // '1' - 1 ETH
if (maxMint < amountToMint) {
// The user is trying to mint more than they can
throw new Error('Minting amount exceeds the limit')
}Calculating Health Factor for Minting
Executing the Minting Transaction
Next Steps
Last updated
Was this helpful?