- Input token: does the vault take its own deposit token directly, or will the API swap another token in for you? This is the direct vs swap distinction.
- Settlement: does the deposit complete in one transaction, or does it queue and require a follow-up claim? This is the instant vs async distinction.
Direct vs swap
Direct and swap are the two values of themode field on a deposit request.
| Mode | What it does | Available when |
|---|---|---|
direct | The user deposits the vault’s native token directly. | meta.directInteractionEnabled is true |
swap | The user supplies a different input token and the API routes it through a DEX before depositing. | meta.routedSwapEnabled is true |
true on the same opportunity, in which case you choose the mode. Both can describe the same vault from opposite ends:
| Scenario | meta.directInteractionEnabled | meta.routedSwapEnabled |
|---|---|---|
| Direct deposit only | true | false |
| Swap deposit only | false | true |
| Both modes available | true | true |
slippageBps, the maximum acceptable slippage in basis points. The exact request shape for both modes, including how slippageBps defaults and bounds, is on Deposit.
Instant vs async
Most vaults settle a deposit in a single transaction. Some, including Mellow and Lagoon, queue the deposit and require a second step once the vault processes it.| Settlement | What happens | What you do next |
|---|---|---|
| Instant | The deposit transaction completes the position in one shot. | Nothing. The position is live. |
| Async | The deposit enters a pending state in the vault. | Wait for the vault to process it, then claim to finalize (or cancel to abort). |
meta.asyncDepositisfalse: the deposit completes in a single transaction.meta.asyncDepositistrue: the deposit needs a separate claim step after the vault processes the request.meta.asyncWithdrawsignals the same for withdrawals.
Putting it together
The two axes combine freely. An opportunity can be direct + instant, swap + instant, direct + async, or swap + async. Resolve both before generating the deposit:Read the input flags
Check
meta.directInteractionEnabled and meta.routedSwapEnabled to decide whether you can deposit the user’s token directly or need swap mode.Build the deposit accordingly
Set
mode, and if async, plan for the claim step. See Deposit and Async Deposits.
