Get Order status
There are two ways to get this done.
- Listening for payment webhooks: We covered how to create a webhook listener here in the getting setup guide - if you haven't done this already, go back to this step to get ready to receive webhooks.
- Calling get order-details API (API link):
You can retrieve directly the latest status by specifying the order ID as a path parameter.
curl --location 'https://sandbox-api.transfi.com/v3/orders/OR-2512221500071811800' \ --header 'mid: SAH1N3_NA_NA' \ --header 'Authorization: Basic =='{ "status": "success", "data": { "id": "OR-2509301236402255398", "status": "initiated", "type": "buy", "purposeCode": "personal", "source": { "currency": "USD", "amount": "10", "paymentType": "bank_transfer" }, "destination": { "currency": "USDTPOLYGON", "amount": "9", "walletAddress": "0xDEADBSFDG876DG76889DAAADFGASDF0ABCDEF" }, "userId": "UX-250910053447199", "senderName": { "firstName": "sumanth", "lastName": "d" }, "mid": "ABCDEF_NA_NA", "fees": { "networkFee": 0.81, "processingFee": 0.1, "fixedFee": { "totalFixedFees": 0, "totalFixedTfFees": 0, "totalFixedCxFees": 0, "fixedFeesCurrency": "USD", "fixedFeeDetails": { "baseFeeFixedRate": 0, "tfFeeFixedRate": 0, "cxFeeFixedRate": 0, "currency": "" } } } } }
Updated 5 days ago