Active curve
The app obtainsquoteSell(tokensIn). The contract computes gross curve output, deducts the 1% trading fee, and returns net native USDC to the seller.
If the curve allowance is insufficient, the app simulates and submits an exact token approval, waits for its successful receipt, then re-reads allowance. It rechecks balance, wallet, network, deadline, and current context before simulating and requesting the separate sell transaction.
Graduated market
The input token is approved to the verified SwapRouter. QuoterV2 estimates 6-decimal canonical ERC-20 USDC output, andexactInputSingle enforces the reviewed minimum output and deadline. The component re-reads a confirmed allowance before sending the dependent swap.
