Simple UX
Simple usage covers the three roles most users will take. Each is one Router call after the one-time setup; none requires ongoing management.
Swapper
Swap one asset for another, either direction of intent:
router.swapExactIn(poolId, tokenIn, tokenOut, inIdx, outIdx, amountIn, minAmountOut, you, deadline);
router.swapExactOut(poolId, tokenIn, tokenOut, inIdx, outIdx, amountOut, maxAmountIn, you, deadline);One pool per asset set — no fee tiers to choose from. Quotes come from the Lens
(previewSwapIn / previewSwapOut); the total cost (slippage + one low fixed fee) is visible
before you sign.
Liquidity provider
Deposit assets, receive fungible pool shares, done:
router.addLiquidity(poolId, tokens, maxAmounts, minLpShares, you, deadline);The position is always in range (the liquidity follows the price), and fees are added directly
to the pool — your shares simply appreciate. No repositioning, no harvesting. On star pools you
can enter with a single asset (zapIn) instead of a basket.
Asset supplier
Lend an asset to a pool's lending market and earn the borrowers' interest:
router.supply(poolId, assetIdx, amount, you, deadline);
router.withdraw(poolId, assetIdx, amount, you, you, deadline); // or withdrawMaxRates adjust automatically to utilization (adaptive-curve IRM). Markets are isolated: your supply is exposed only to the pool/market you chose — never to the rest of the protocol.