Skip to main content
POST
Get a quote

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Body

application/json

Body of POST /v2/quote.

fromAmount
integer<int64>
required

Amount the taker would send, in the input asset's smallest units — for an RGB asset, its contract's.

Required range: x >= 0
pairId
string
required

Pair key, e.g. "BTC/BTC".

swapType
string
required

Which swap family — "submarine" / "reverse" / "chain". Pair ids are scoped per kind: BTC/BTC exists in both Submarine and Reverse as separate cards.

Example:

"submarine"

Response

Priced quote + pair-hash rate lock.

POST /v2/quote response.

fees
object
required

Fee breakdown for this quote, in the output asset's units.

fromAmount
integer<int64>
required

Amount the taker would send, smallest unit of the input asset. An RGB asset counts its contract's precision here and in every amount below.

Required range: x >= 0
grossOutput
integer<int64>
required

Gross output before fees: toAmount + fees.total.

Required range: x >= 0
hash
string
required

Pair-config hash — the pairHash the taker passes back on create to rate-lock.

pairId
string
required

Pair key, e.g. "BTC/BTC".

rate
number<double>
required
toAmount
integer<int64>
required

Amount the taker would receive after fees & spread; the same number a create for fromAmount pays out.

Required range: x >= 0
validUntil
integer<int64>
required

Unix-seconds timestamp past which the quote is stale.