Skip to main content
Version: Lastest

Security

1. How to generate signature for API Buy card code

Example of parameters passed to the API

{
"partnerRefId": "AB123",
"productCode": "AC100",
"quantity": 10,
"signature": "b10294bae53e89919b3efd62a763bf3..."
}

The order of parameters to create the signature will be sorted alphabetically.
The parameters are included into signature: partnerRefId + productCode + quantity
The string generated with the above parameters will be:

"partnerRefId=AB123&productCode=AC100&quantity=10"

signature = HMAC_SHA256("partnerRefId=AB123&productCode=AC100&quantity=10", YOUR_SECRET_KEY)