Transactions
Effortlessly Track and Verify Transactions with our API. Simplify the process of checking transaction details with our comprehensive API solution. Easily retrieve and verify transaction information, including payment status, amounts, and timestamps.
The system retains transaction records for the last seven days only. For access to records older than this period, please contact your system administrator.
All Transactions
This is especially true when there's no message body to include. Hashing only the Project Key ensures a level of authentication between the client and the server.
- Name
page- Type
- mandatory
- Description
Default: 1
- Name
status- Type
- mandatory
- Description
'pending', 'success' .Default: 'success'
- Name
date- Type
- mandatory
- Description
Default: today with format Y-m-d
- Name
type- Type
- mandatory
- Description
'cashIn'/'receive', 'cashOut'/'send'
You need to authenticate your Headers request to access any endpoint in the 98Pays API, to see the authentication documentation please read the Authentication section.
Request And Response All Transactions
# Signature 98Pays All Transactions For PHP Code
$xSignature = hash_hmac('sha512', $ClientKey, $ClientToken)
All Transactions
<?php
$curl = curl_init();
curl_setopt_array($curl, array(
CURLOPT_URL => '{{HOST}}/transactions?page=1&status=success&date=2025-02-29&type=cashIn',
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => '',
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 0,
CURLOPT_FOLLOWLOCATION => true,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => 'GET',
CURLOPT_HTTPHEADER => array(
'X-Client-Key: ',
'X-Client-Token: ',
'X-Signature: '
),
));
$response = curl_exec($curl);
curl_close($curl);
echo $response;
Response All Transactions
{
"responseCode": 200,
"responseMessage": "success",
"responseData": [
{
"id": "repellendus",
"merchantRef": "nisi",
"status": "pending",
"feePayer": "merchant",
"amount": 5930000,
"fee": 3942077,
"totalAmount": 5930000,
"expiredDate": "2023-10-09T23:59:59+07:00",
"paidDate": null,
"settleDate": "2023-10-09T13:38:37+07:00",
"additionalInfo": {
"callback": null
},
"disbursement": {
"bankCode": null,
"recipientAccount": "5443020792443311",
"recipientName": "Mr. Deangelo Robel IV"
}
},
{
"id": "dolorum",
"merchantRef": "et",
"status": "pending",
"feePayer": "customer",
"amount": 7420000,
"fee": 4783777,
"totalAmount": 12203777,
"expiredDate": "2023-10-09T23:59:59+07:00",
"paidDate": null,
"settleDate": "2023-10-09T13:38:37+07:00",
"additionalInfo": {
"callback": null
},
"disbursement": {
"bankCode": null,
"recipientAccount": "4716296795643486",
"recipientName": "Darrick Rath V"
}
}
],
"responseExtra": {
"currentPage": 1,
"totalPages": 1,
"totalRecords": 2
}
}
Check Single Transaction
This is especially true when there's no message body to include. Hashing only the Project Key ensures a level of authentication between the client and the server.
- Name
resendCallback- Type
- opsional
- Description
true/false, Determine we need to resend you the callback
- Name
id- Type
- mandatory
- Description
Transaction ID or Merchant Ref
You need to authenticate your Headers request to access any endpoint in the 98Pays API, to see the authentication documentation please read the Authentication section.
Request And Response Check Single Transaction
# Signature 98Pays Check Balance For PHP Code
$xSignature = hash_hmac('sha512', $ClientKey, $ClientToken)
Request Check Single Transaction
<?php
$curl = curl_init();
curl_setopt_array($curl, array(
CURLOPT_URL => '{{HOST}}/check/55612dbap-fb6a-4c4b-bc99-0928ca398a9d?resendCallback=true',
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => '',
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 0,
CURLOPT_FOLLOWLOCATION => true,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => 'GET',
CURLOPT_HTTPHEADER => array(
'X-Client-Key: ',
'X-Client-Token: ',
'X-Signature: '
),
));
$response = curl_exec($curl);
curl_close($curl);
echo $response;
Response Check Single Transaction
{
"responseCode": 200,
"responseMessage": "success",
"responseData": {
"id": "55612dbap-fb6a-4c4b-bc99-0928ca398a9d",
"merchantRef": "REF12",
"status": "pending",
"feePayer": "customer",
"amount": 10000,
"fee": 3000,
"totalAmount": 13000,
"expiredDate": "2023-07-13T11:51:41+07:00",
"additionalInfo": {
"callback": "http://your-site-callback.com/notify"
},
"virtualAccount": {
"bankCode": "014",
"vaNumber": "666555440021",
"viewName": "Merchant Name"
}
}
}
