POST method.
Our API expects HTTP Status code 200 for all requests successful or not. All other HTTP status codes are treated as unsuccessful.
Request Header
| Key | Value | Description |
|---|---|---|
X-Request-Signature | Hash string | Signature string issued by our API. |
Accept | application/json | Accept: application/json |
Content-Type | application/json | Content-Type: application/json |
Verifying Callback Request Signature
TheX-Request-Signature header is used to ensure the authenticity and integrity of the API request. It contains a Base64-encoded HMAC-SHA512 hash, which the operator must generate using the request body and their secret API token (API_TOKEN).
- Extract all keys and values from the request body
- The request body must be a flat JSON object (no nested objects).
- Example request body
- Sort the keys alphabetically
- Sorted keys:
["amount", "currency", "playerId", "timestamp"]
- Sorted keys:
- Get the corresponding values in sorted key order
- Values:
["1500", "USD", "user123", "1713792000"]
- Values:
- Join the values with a comma (
"1500,USD,user123,1713792000") - Generate base64 encoded HMAC-SHA512 hash of the string using
API_TOKENas the key - Compare the hash string you generated with the value provided in the
X-Request-Signatureheader. If they do not match, it indicates that the request may have been altered or tampered with by a malicious actor.
