Get Quote
Retrieve a real-time conversion quote between USDT and Bitcoin.
This endpoint allows you to preview the expected rate, amount received, and validity period for a USDT ↔ BTC trade. Quotes can be used to show customers live pricing or to execute a trade with a locked rate.
Endpoint
Purpose
Use this endpoint to:
Display current pricing before executing a trade
Lock a quote for execution via the /trades/execute endpoint
Evaluate exact cost or return amount for conversions
Fetch trade metadata (fees, expiry, reference) before committing
Query Parameters
Parameter | Type | Required | Description |
---|---|---|---|
from | string | Yes | Asset to convert from. One of: usdt or bitcoin |
to | string | Yes | Asset to convert to. One of: usdt or bitcoin |
amount | integer | Yes | Amount to convert, in satoshis for BTC or cents for USDT. Example: 100000 = 100,000 sats or 1,000 cents |
Example Request
Successful Response (200 OK)
Command Line
Response Fields
Field | Type | Description |
---|---|---|
quoteId | string | Unique ID for this quote. Use it when executing the trade. |
from | string | Asset being traded from (usdt or bitcoin) |
to | string | Asset being acquired |
inputAmount | integer | Amount being converted (in cents or sats) |
outputAmount | integer | Amount that will be received |
rate | integer | Price rate in output/input terms (e.g., sats per cent) |
fee | integer | Fee applied to this trade |
expiresAt | string | ISO timestamp when this quote expires |
Notes
Quotes are valid for a short time (usually 30 seconds)
Use the quoteId
in /trades/execute
to ensure price locking
Without quoteId
, the trade executes at current market rate
Fees depend on your integration tier (default is 0)
Errors
Code | Message | Fix |
---|---|---|
400 | "Invalid asset pair" | Only use usdt ↔ bitcoin |
400 | "Missing or invalid amount" | Must be a valid positive integer |
403 | "Insufficient balance" | Ensure sufficient balance (future feature) |
500 | "Quote service unavailable" | Retry or contact support |