Get started
API Endpoint
https://payment.kingzplay.com/EnquiryBalance
Use this endpoint to retrieve the current available balance per currency for your merchant account.
To use this API, you need an API merchant keys. Please contact us at support@kingzplay.com to get your own API merchant keys.
Balance Enquiry
API Endpoint
https://payment.kingzplay.com/EnquiryBalance
Submit a POST request with a JSON body to fetch your balance.
# Here is a POST request example (with a real SHA-1 control you can reproduce)
{
"version": 3,
"merchant_account": "123456",
"control": "587da450a255c2cb472877df94cb48b1a6040dd1"
}
To submit balance enquiry request you need to make a POST API call to the following url :
https://payment.kingzplay.com/EnquiryBalance
QUERY PARAMETERS IN JSON BODY
| Field | Type | Description |
|---|---|---|
| merchant_account | String | Merchant account number assigned by KingzPlay, 12 bytes max. *[mandatory] |
| version | Numeric | API version for balance enquiry. Currently supports 3. *[mandatory] |
| control | String | Checksum generated via SHA-1 of the concatenated fields (see section “Create Balance Enquiry Control”). 40 bytes. *[mandatory] |
Response example (XML)
<?xml version="1.0" encoding="iso-8859-1"?>
<balance>
<merchant_account>123456</merchant_account>
<item>
<currency>PHP</currency>
<amount>587.00</amount>
</item>
</balance>
Notes:
- The response is returned in XML format.
- Each <item> node represents a currency and its corresponding balance amount.
- Amounts are represented in standard decimal string format per currency.
Create Balance Enquiry Control
NOTE: Never expose your partner_control provided by us to anyone. Doing so will compromise the security of future transactions.
For Balance Enquiry, the control is generated using a SHA-1 hash of the following fields concatenated in the exact order, then hex-encoded:
(merchant_account + version + partner_control)
Reproducible example:
merchant_account 123456
version 3
partner_control 11112222333344445555666677778888
The complete string becomes:
123456311112222333344445555666677778888
Hash the string using SHA-1 (hex lowercase). Resulting control is:
587da450a255c2cb472877df94cb48b1a6040dd1
Use this exact value in the sample request above to verify your implementation.