Conversions
Buy or sell Bitcoin with USD on a funded, open payments-core account using POST /trade/order with provider: "BITGO".
Before trading, confirm fiat or asset availability via:
GET /account-fiat-total?accountId={accountId}GET /account-asset-total?accountId={accountId}
Place an Order
POST /trade/orderprovider: "BITGO"symbol: e.g."BTC-USD"side:"buy"or"sell"type:"limit"(requireslimitPriceUnitCount) or"market"quantityUnitCount: base quantity in sats (string bigint)limitPriceUnitCount: USD cents per whole BTC (string bigint), required for limit orders
Example that worked on DEV (buy 10,000 sats at $50,000/BTC):
{
"accountId": "<accountId>",
"symbol": "BTC-USD",
"side": "buy",
"type": "limit",
"provider": "BITGO",
"quantityUnitCount": "10000",
"limitPriceUnitCount": "5000000"
}
| Field | Unit | Example meaning |
|---|---|---|
quantityUnitCount | sats | "10000" = 0.0001 BTC |
limitPriceUnitCount | USD cents / BTC | "5000000" = $50,000.00 per BTC |
Minimum quantity enforced
Orders below the provider minimum size are rejected. If a small quantityUnitCount fails validation upstream, increase size (the DEV example above used "10000" sats) rather than retrying the same tiny notional.
Sync vs async placement
Omit async or set async: false to place the order and settle immediate fills inline in the response. async: true returns once the order is accepted and lets reconciliation sync fills later.
Track an Order
GET /trade/order/{id}: poll a single order by the id returned from createGET /trade/order: list orders (optional filters such asaccountId,symbol,status)
After fills, re-check account-fiat-total / account-asset-total to confirm balances moved.
Putting It Together
Next Steps
- Withdrawals: Send USD or crypto out
- Fees: How platform fees apply on payments-core accounts