Get transaction details
This API will provide a detailed status for a given transaction-id. The response contains user-entered transactions detail’s status; the status of the payment amount transaction, as well as the fee-amount transaction; and the ledger details of the transaction.
/GetTransactionDetails
import requests
url = “https://stageapi.cfsemoney.com/v1/GetTransactionDetails?userTransactionId=xxxxxxxxxx-0f97f4f8fe25”
payload={}
headers = {
‘x-api-key’: ‘YOUR-API-KEY‘,
‘Authorization’: ‘Bearer <<bearer-token>>‘,
‘Content-Type’: ‘application/json’
}
response = requests.request(“GET”, url, headers=headers, data=payload)
print(response.text)
curl –location –request GET ‘https://stageapi.cfsemoney.com/v1/GetTransactionRejectReason?transactionId=xxxxxxxxxxxxxxxxxxx” \
–header ‘x-api-key: <<YOUR-API-KEY>>‘ \
–header ‘Authorization: Bearer <<bearer-token>>‘,
{
“statusCode”: 200,
“body”: “{\”data\”: {\”userTransactionSummary\”: [{\”transaction_id\”: \”6a5ca644-3364-4b1c-b90c-73cf9bc2e065\”, \”amount\”: 8.0, \”payment_method\”: \”SWIFT\”, \”to_account_holder_name\”: \”VOICETEC SYS LIMITED\”,
\”to_account_no\”: null, \”to_sort_code\”: null, \”payment_reference\”: \”IT Internal test 3\”, \”notes\”: null,
\”transaction_state\”: \”processing\”, \”transaction_status\”: \”processing\”, \”transaction_journey\”: \”@@-2023-10-03 11:17:59.639047-Initiate@@-2023-10-03 11:18:03.06299-ready@@-2023-10-03 11:18:03.072103-processing\”,
\”provider_name\”: \”ClearBank (CB)\”}], \”paymentAndFeeTransactionDetails\”: [{\”e2e_txn_id\”: \”375744a3-3d1d-4949-b013-753f3368fcb\”, \”transaction_id\”: \”6a5ca644-3364-4b1c-b90c-73cf9bc2e065\”, \”payment_reference\”: \”IT Internal test 3\”,
\”notes\”: null, \”e2e_transaction_state\”: \”waiting for response\”, \”e2e_transaction_status\”: \”processing\”}],
\”ledgerDetails\”: []}, \”message\”: \”transaction details fetched successfully.\”, \”status\”: true}”
}
{
“statusCode”: 400,
“body”: “{\”message\”: \”xxx”}”
}