VimenDocs
Guides

One-click mint & redeem (Zap)

Mint or exit a whole basket from ETH or USDG in a single transaction.

The zap collapses "buy N constituents, approve N times, mint" into one transaction, paid in ETH or USDG. Under the hood it's the VimenZap router: stateless, admin-less, and atomic. If any leg can't fill, everything reverts and you keep your money.

Paying with ETH

Everyone on the chain holds ETH (it's the gas token), so it's the zero-setup path:

  • No approval, no signature: native ETH travels as the transaction's value. One payable zapMint, done.
  • Your ETH is swapped immediately into the exact constituent amounts inside the same transaction; the basket is minted and any unspent ETH is refunded automatically.
  • Pricing is honest by construction: the impact gate converts each constituent's Chainlink fair value through the ETH/USD feed and blocks the ETH path if that feed is stale (the app will suggest USDG or in-kind instead).
  • Fun fact: constituents whose pools are ETH-quoted get cheaper to reach with ETH than with USDG, because those routes drop a hop.

Paying with USDG

Enable USDG (first time only)

Approve USDG once to the canonical Permit2 contract (0x000000000022D473030F116dDEE9F6B43aC78BA3). This is the only ERC-20 approval you'll ever make for zapping; the router itself is never granted an allowance.

Quote

Enter a basket amount (or USDG amount). The app calls the router's quoteZapMint, which runs the real swaps in simulation and reverts with the exact numbers, so the quoted cost equals execution cost in the same block, not an estimate with slippage guesswork. (ETH quotes work the same way.)

Sign and mint

You sign a Permit2 message (token = USDG, amount = your max spend, spender = router) and send one transaction. The router pulls only the actual cost, buys the exact constituent amounts with exact-output swaps (zero dust), mints the basket, and sends it to you. Any surplus stays yours.

Zap-redeeming

The mirror image: one transaction burns your basket tokens, sells every constituent, and pays you USDG or native ETH (the Receive toggle on the redeem tab), protected by a minOut floor set from the quote. The once-ever setup is an ERC-20 approval of the basket token to the immutable router. (In-kind redemption remains available always; the zap is a convenience on top, never a replacement.)

The 5% impact gate

Before offering a zap, the app scores each swap leg against the constituent's oracle price (converted through ETH/USD when you pay with ETH). If any leg's execution premium exceeds 5%, the zap disables itself and tells you why: thin pools disable the zap loudly instead of overcharging quietly. When that happens you can:

  • mint in-kind instead (unaffected by pools), or
  • wait: pools deepen over time, and the gate re-enables automatically.

Some basket legs are thin at launch (MSFT, AMZN, PLTR, MU); the gate is what makes offering them honest. Legs filled through Rialto are USDG-only; when a basket needs a Rialto leg, the app offers the USDG path for it.

Fees and costs of a zap

CostAmount
Protocol mint fee0.30% (in basket tokens, as with any mint)
Swap feesPer-pool Uniswap v4 / Rialto fees, included in the quote
Redeem feeNone: protocol redeem is free; zap-redeem pays only swap fees
Router feeNone: the router is a free, stateless utility

On this page