Skip to main content
Prepares transaction data for a deposit using an EIP-2612 permit signature. This enables single-transaction deposits without a separate approval step.
For most use cases, use the unified deposit workflow which handles authorization automatically.

Import

Usage

Parameters

Return Type

The return structure is nested: ABI and args live under .data, not at the top level. When using writeContract, pass txData.data.abi, txData.data.functionName, and txData.data.args. When using sendTransaction, encode via encodeFunctionData({ abi: txData.data.abi, functionName: txData.data.functionName, args: txData.data.args }).

Examples

Permit Support

Not all tokens support EIP-2612 permits. Use prepareDepositAuthorization() to check:
Smart contract wallets (like Privy Smart Wallets or Safe) cannot sign permits. Use the approval flow with transaction batching instead.

Error Handling