sendDeposit confirms the ERC-20 transfer and registers its custody-credit
lifecycle. It does not wait for the backend handover to finish. That split
matches the familiar sendTransaction → waitForTransactionReceipt model:
- Call
sendDepositto send, confirm, and register the deposit. - Read
result.registration.id. - Call
waitForDepositCreditwhen your UI needs to wait until the funds are credited on the Safe. - Optionally call
waitForDepositPositionwhen the UI should wait until rebalance into a position finishes (or is skipped).
amount is least units. Assets, chains, minimums, and strategies are on
Supported Assets. strategy applies on the first
deposit only.
Signature
Example
sendDeposit may already return credited. Passing that lifecycle ID to
waitForDepositCredit is safe; the helper returns immediately when credit is
complete.
Lifecycle states
Use
getDepositStatus for a one-off UI
refresh. Do not show a pending deposit as yield-bearing until it is credited
and balanceCredited is true.
Custom and sponsored wallets
For Privy, Biconomy, mobile, or other app-managed wallets, use the external deposit building blocks: prepare the first deposit, build and submit the transfer, confirm it, then register it withlogDeposit and await credit.
Compatibility
depositFunds remains available for existing
integrations. It is a convenience wrapper around sendDeposit plus a short
normal credit wait. New integrations should own the completion UX explicitly
with sendDeposit, waitForDepositCredit, and optionally waitForDepositPosition.