Get swap quote

Get swap quote on Curve

Ethereum
Ethereum
Base
Base

Reads onchain state

Ready to run on Base

Reads the amount a Curve pool would pay right now for swapping one coin to another. The pool's get_dy is called for the two coin indices and the input amount, returning the output in the output coin's units net of the pool's fee. Indices are resolved at runtime when the coins are coils, and the action requires they differ. Reach for it to compare venues before routing, to set a swap floor from a live quote with a slippage haircut, or to gate a trade behind a minimum rate with a predicate.

Plug lets you combine onchain actions like this one into a single transaction, without writing a smart contract. Use in App opens a new plug with this action already in it.

More plugs on Base

Provide liquidity on Base · 6 plugs

More on Curve · 11

On other protocols · 4