Checkout (public)
Compare payment costs
Prices the invoice in up to five coins without creating deposit addresses. The checkout uses it to rank the coins a connected wallet holds, and, without refund_address, to check a chosen coin before the customer gives an address. Each entry has either the amount to send or the reason the coin cannot be used; a refused route also carries minimum_usd when NEAR Intents names a minimum. When NEAR Intents does not answer, or this server's 1Click request budget is taken by payments, an entry comes back with ok: false, temporary: true and "The payment network did not answer. Try again." When the business has private payments on and they cannot be quoted, the whole request fails with a quote_unavailable error, because no coin can be used.
Rate limits: 10 per minute per invoice, and 25 coins per minute per IP address and 100 coins per minute per network (each request counts the number of different coins it compares).
id*stringInvoice id, starting with inv_.
application/json- body
origin_assets*array<>1 <= items <= 5refund_address?stringThe payer's address on each coin's chain. Leave it out to check whether the coins can pay and what they cost before the payer gives an address.
1 <= length <= 200One estimate per distinct coin.
application/json- response
object*stringdata*array<|>curl -X POST 'https://example.com/api/v1/invoices/string/estimate' \ -H 'Content-Type: application/json' \ -d '{ "origin_assets": [ "string" ]}'{ "object": "list", "data": [ { "asset_id": "string", "ok": true, "amount_in": "string", "amount_in_base": "string", "amount_in_usd": "string" } ]}