API Reference
Wallets
Finalize Crypto Swap [POST]

Finalize Crypto Swap

https://sandboxapi.bitnob.co/api/v1/wallets/finalize-crypto-swap (opens in a new tab)

Finalize a cryptocurrency swap using a quote ID obtained from the initialize-crypto-swap endpoint.


Body Parameters

ParameterTypeRequiredDescription
quoteIdstringQuote ID from initialize-crypto-swap

Request

Wallets/Finalize Crypto Swap [POST]
curl --request POST \
   --url https://sandboxapi.bitnob.co/api/v1/wallets/finalize-crypto-swap \
   --header 'Authorization: Bearer API-KEY' \
   --header 'accept: application/json' \
   --header 'content-type: application/json' \
   --data '
{
"quoteId": "66aa68ebe3876fbfc1084313"
}
'

Responses

🟢 200 - Result example
{
"status": true,
"message": "purchase initiated",
"data": {
  "id": "62ac5a85-7178-4d60-a643-49bfe44a57cc",
  "fees": 0,
  "type": "debit",
  "status": "success",
  "action": "SELL_USD_FOR_TRX",
  "amount": 39.99,
  "walletId": "57d44ef1-fcc5-471c-b758-778ca5359112",
  "createdAt": "2024-07-31T16:54:16.205Z",
  "updatedAt": "2024-07-31T16:54:16.205Z",
  "reference": "9e785f71628e",
  "centFees": 3999,
  "centAmount": 3999,
  "description": "SELL USD FOR TRX",
  "balanceAfter": 496001,
  "balanceBefore": 500000
}
}
Last updated on