Technical Documents

Common workflows, events, and functions in Solidity that developers can use to design and curate vaults.

Launch Vault

This contract is an ERC4626-compatible vault that allows users to deposit an underlying asset and receive proportional shares which are ERC20 tokens. The vault also keeps track of balances and total supply over time, supports delayed withdrawals, and provides mechanisms to rescue shares from blocklisted accounts.

Main Features

  • ERC20 Compliance with Enhanced Controls

  • Standard ERC20 functionality (transfer, transferFrom, balanceOf, etc.).

  • Additional checks for pause and blocklisted addresses.

ERC4626 Vault Functions

  • Implements standard ERC4626 methods: deposit, mint, redeem, and withdraw.

  • Enables predictable and standardized vault interactions.

Deposit and Mint

  • Users can deposit assets to receive shares (deposit) or mint a specified number of shares by depositing the required amount (mint).

  • Supports deposit limits and ensures proper share-to-asset conversion with rounding.

Withdrawal and Redemption

  • Withdrawals and redemptions are scheduled for future periods to allow for controlled asset disbursement.

  • Includes claiming functionality to finalize withdrawals after the period ends.

Rescue Mechanisms

  • Allows administrators with RESCUER_ROLE to recover shares or pending withdrawals from blocklisted addresses.

  • Prevents blocklisted accounts from executing any vault operations.

Period-Based Logic

  • The vault operates in configurable periods, allowing withdrawals to be processed at the end of a period.

  • Periods can be configured to control duration, start times, and transitions.

Last updated