/** * Swap Builder — Builds the unshield+approve+swap multicall * * Produces 3 calls for the ERC-7579 batch execute: * Call 1: Railgun.transact(proof, ...) → unshield tokens to smart wallet * Call 2: ERC20.approve(allowanceTarget, netAmount) * Call 3: Router.swap(calldata from quote) * * The unshield amount equals the desired amount (0% fee on b402 fork). * The approve and swap amounts use the net amount. */ import type { Call } from '../wallet/batch-calldata'; import type { SwapQuote } from '../types'; export interface PrivateSwapCallsParams { /** Pre-built unshield calldata (from ZK proof pipeline) */ unshieldCalldata: string; /** Railgun relay contract address */ railgunRelay: string; /** Token being sold (for approve call) */ tokenIn: string; /** Amount the wallet receives after unshield (no fee on b402 fork) */ netAmountAfterFee: bigint; /** Swap quote from 0x or Aerodrome */ swapQuote: SwapQuote; } /** * Build the 3-call array for a private swap. * * @returns Array of 3 calls: [unshield, approve, swap] */ export declare function buildPrivateSwapCalls(params: PrivateSwapCallsParams): Call[];