Skip to content

vault:mint

Mint an exact amount of ERC-4626 vault shares, approving the vault for the required assets (previewMint, which rounds up) automatically when needed. For ERC-7540 asynchronous vaults use vault:request-deposit instead.

⚗️ Experimental — available at next.evmcrispr.com.

Supports runtime fields inside smart blocks. Use explicit @helper! expressions or captured outputs; other fields are evaluated at build time.

vault:mint <shares> <of> <vault>
NameTypeEvaluationDescription
sharesnumberRuntime in smart blocksAmount of vault shares to mint, in base units (wei)
ofcommandBuild timeKeyword of
vaultaddressBuild timeERC-4626 vault address
NameTypeEvaluationDescription
--toaddressRuntime in smart blocksReceiver of the minted shares (defaults to the connected account)
--no-approveboolBuild timeSkip the automatic allowance check and approve action
# Mint exactly 100 sDAI shares, approving previewMint worth of WXDAI
vault:mint 100e18 of 0xaf204776c7245bF4147c2612BF6e5972Ee483701