Quote a buy
arcnow_quote_buyQuote what a token buy would return right now, with fee breakdown, average fill price, and minimum-out at chosen slippage. Use it before any purchase to see the real cost instead of the spot price.
Instructions
What a given amount of the token's quote would buy right now, wherever the token trades: tokens out, every fee and who receives it — on a curve the flat 1% split four ways between creator, platform, referrer and protocol — the average price the order would fill at, and the minimum-out floor at several slippage tolerances.
Costs nothing and signs nothing. Use it before every buy, and use it INSTEAD of a spot price whenever someone asks what an amount would get them — an order moves the price across its own size, so the spot price is only ever its first infinitesimal slice.
ON A BONDING CURVE: if the buy would fill the curve, this says so, reports the refund, and explains the gas-limit trap that decides whether the token's market is created in that same transaction or never. Read that part before quoting a graduating buy to anyone.
IN A UNISWAP V4 POOL (the token graduated and migrated): the quote says it is a pool quote, priced by simulating the real swap through arcnow.io's router. It shows the two charges apart — arcnow.io's fee hook's 0.80% and the pool's own 0.20% LP fee, 1.00% in all, both read off the pool — the average fill price against the pool's spot price, and the price impact. referrer does not exist on a pool swap and is refused.
A token that graduated but never migrated trades nowhere; this says so and names arcnow_migrate. A quote is a snapshot of one block. Anyone else's trade changes it.
THE AMOUNT IS IN THE TOKEN'S QUOTE: native USDC, or the ERC-20 (such as EURC) it was launched in — arcnow_token names it. Every figure in the answer is labelled with that quote's symbol. An ERC-20 quote is pulled with an exact approval, which the answer says.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| address | Yes | The curve address, or the token address. Either works. | |
| quoteIn | Yes | How much of the token's quote to spend, in whole units as a person writes it — "25", "1.5" — in the quote the token is priced in: native USDC (18 decimals) or an ERC-20 such as EURC (6). It is read exactly in that quote's decimals; more decimal places than the quote has is refused, never rounded. A string, because a JSON number cannot hold 18 decimals. | |
| referrer | No | CURVE ONLY: the address credited with the referral share of the fee. With no referrer that share goes to the platform instead. Refused for a token in its pool, whose swap has no referrer. (There is no developer share and no developer argument: the fee has four parties — creator, platform, referrer, protocol.) |