Skip to main content
Behind the two API calls sits a routing engine: price discovery across centralized exchanges and OTC desks, quote generation with optional locking, atomic execution, and instant wallet settlement. You never touch order books, slippage management, or venue routing; you quote, execute, and confirm.

Prices come from routing, not a feed

The price on a quote reflects live pricing across venues, routing optimized for reliability and capital efficiency, and any margin configuration on your tier. Treat the quote as the truth for pricing: never reconstruct or cache a rate beyond its expires_at. For an indicative rate with no execution promise, read List all prices instead.

Market rate or locked quote

Lock the quote whenever a user sees a rate before confirming, and whenever you promise a fixed price. An NGN order without a quote_id needs a reference and fills at the market rate. Quotes expire fast: about 10 seconds in production, and in sandbox 30 seconds for NGN pairs and about 5 minutes for crypto pairs, so drive a visible countdown from expires_at and disable the confirm action when it passes.

What atomic execution buys you

An order fills completely or fails cleanly; there is no partial state. If the quote expired, the balance is short, or execution errors, no funds move and you get a clean error. Consequently:
  • Never debit a user before trade.completed arrives.
  • A failed trade needs no cleanup, only a fresh quote.
  • On NGN pairs, retrying with the same reference is safe: it returns the original order. On crypto pairs it can trade twice, so look the order up first. See Execute a trade.

Amounts and rates

Requests take quantity in major units of the base currency: "0.0001" BTC, "10" USDT, "5000" for ₦5,000. The quoted price is per unit of base currency in the quote currency, and the exchange block on every quote spells out exactly what you send and receive, so display from it rather than computing your own conversion.

Common questions

Markets move. A quote that stayed valid would let callers exploit price changes at Bitnob’s expense, so each one carries a short expires_at. Executing after expiry fails cleanly with 422 and code PRECONDITION_FAILED; fetch a fresh quote. For display-only pricing with no expiry, use List all prices.
The spread is the difference between the rate a user gets and the market rate, and it is how trading platforms earn. You can pass Bitnob’s rate through untouched or apply your own markup on top before showing it; the quote’s rate is the executable floor.
From centralized exchanges, OTC desks, and internal routing. You do not manage any of it; the quote you receive is trusted and executable, and your system receives the promised output or nothing.
Yes, quotes are free and don’t commit you to anything. But for browsing and pricing calculators, use indicative rates instead: List all prices for crypto pairs and Get exchange rate for NGN pairs. Create a quote only when the user is ready to confirm. NGN quotes are checked against your balance and back a single order.
Quote validation, balance check, execution, credit to the destination balance, then the trade.completed event. Any failure along the way moves no funds.
Unique reference per trade, no execution of expired quotes, webhook-driven state rather than trusting the synchronous response, and reconciliation of trades against balances. See Handle trading failures.

A complete sell flow

A user holds 100,000 sats and wants stablecoins:
  1. Create a quote for the BTC → USDT pair.
  2. Show “You’ll receive $45.12” with a countdown from expires_at.
  3. On confirmation, submit the order with the quote id, price, and your reference.
  4. On trade.completed, credit your ledger and show success.
  5. Optionally continue into a payout to a bank or mobile money account.