Project
Our API project is designed to serve as an integrated platform for grouping merchant businesses within our application. By centralizing various merchant operations, this robust API allows for streamlined management, enhanced data analytics, and optimized user experience, all while simplifying administrative tasks for the merchants. The objective is to create a cohesive ecosystem that benefits both the merchants and end-users.
This API is exclusively accessible to a select group of merchants for enhanced security and customization. If you're interested in accessing this feature to streamline your business operations within our application, please contact our support team for eligibility and activation.
Check Balance
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.
# Signature 98Pays Check Balance For PHP Code
$xSignature = hash_hmac('sha512', $ClientKey, $ClientToken)
Allows Merchants to check the project's balance from the 98Pays API
Check Balance
<?php
$curl = curl_init();
curl_setopt_array($curl, array(
CURLOPT_URL => '{{HOST}}/balance',
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 Balance
{
"responseCode": 200,
"responseMessage": "success",
"responseData": {
"active": 1000000,
"pending": 10000,
"total": 1010000
}
}
List Active Projects
Returns all active projects owned by the merchant associated with the authenticated project. This endpoint is used to map projectId and projectName between systems.
Authenticate this endpoint with X-Client-Key, X-Client-Token, and X-Signature as described in the Authentication section. For this GET request, generate the signature from the project key only.
- Name
projectId- Type
- integer
- Description
Unique project identifier used by reconciliation report filters.
- Name
projectName- Type
- string
- Description
Project name registered in 98Pays.
- Name
status- Type
- string
- Description
Project status. Only projects with the ACTIVE status are returned.
List Active Projects
curl --request GET '{{HOST}}/v1/projects' \
--header 'X-Client-Key: <PROJECT_KEY>' \
--header 'X-Client-Token: <PROJECT_TOKEN>' \
--header 'X-Signature: <HMAC_SHA512_SIGNATURE>'
Response
{
"code": "OK",
"message": "Project list retrieved successfully.",
"data": [
{
"projectId": 13,
"projectName": "QA Testing Project 1",
"status": "ACTIVE"
},
{
"projectId": 14,
"projectName": "Production Project Utama",
"status": "ACTIVE"
}
]
}
