Skip to main content
prepareDepositTxData builds calldata for vault deposits. Use it when the user has already granted allowance to the Boring Vault contract (or when a permit flow will supply approval).

Helper Signature

  • Returns { abi, address, functionName: 'deposit', args, chainId }.
  • args[0] is the recipient, args[1] is the deposit amount in base units.
  • Throws APIError if the vault, token, or chain is unsupported.

React with Privy

React with wagmi

React with viem

If the allowance is insufficient, switch to the Approve & Deposit flow. For permit-enabled tokens, jump to Deposit with Permit.***