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.


GET{{HOST}}/balance

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

GET
{{HOST}}/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

POST
{{HOST}}/balance
{
    "responseCode": 200,
    "responseMessage": "success",
    "responseData": {
        "active": 1000000,
        "pending": 10000,
        "total": 1010000
    }
}

Was this page helpful?