How Trading Works

A high-level guide to how USDT ↔ Bitcoin conversions are priced, executed, and settled within Bitnob’s infrastructure.

What Bitnob Trading Does

Bitnob gives you programmatic access to convert stablecoins and Bitcoin using a simple, reliable API. Behind the scenes, it handles:

Price discovery using a routing engine

Quote generation with optional locking

Liquidity sourcing from multiple exchanges and OTC desks

Atomic execution with no partial fills or slippage drift

Wallet settlement with clear status and traceability

As a developer, you only need to make two calls: one to get a quote, one to execute a trade. Everything else — including pricing, routing, timing, confirmation, and settlement — is abstracted away.

The Trade Lifecycle

Trade Lifecycle

Execution Components

LayerWhat It Does
Quote EngineFetches pricing from internal liquidity pools or external sources
Routing LogicChooses best fill path based on asset, direction, and amount
Execution EngineBroadcasts and confirms the trade, ensuring it's atomic and final
Wallet SystemUpdates internal balances and credits the user’s destination wallet instantly

Trade Scenarios

ScenarioFlow
User wants to buy BTC with USDTQuote from USDT → BTC → Execute → BTC is credited to their wallet
User wants to sell BTC for USDTQuote from BTC → USDT → Execute → USDT is credited to their wallet
Platform wants to auto-convertSkip UI, use real-time quote + execute in backend
Merchant wants to lock priceFetch quote, hold for 30 seconds, show user fixed rate

Key Properties

Atomicity: Trades either succeed fully or not at all. You won’t see partial fills.

Quote Expiry: Quotes are typically valid for 30 seconds. If expired, you’ll receive a quote_expired error.

Real-Time Settlement: Once the trade is successful, the resulting asset is immediately available in the destination wallet.

No Slippage Guessing: Using quoteId ensures your user receives exactly the output amount shown.

Developer Responsibilities

Store and pass quoteId if you want locked pricing

Always provide a unique reference for traceability

Never rely solely on synchronous responses — use trade.completed webhook for final confirmation

Display rates and expirations clearly in your product interface if exposing trades to users

Did you find this page useful?