Free Rounds by bet
Request Example
POST /serviceApi.php HTTP/1.1
Content-Type: application/json
- Single id
- Multiple ids
https://stg.otkgaming.com/serviceApi.php
{
"action" : "freeRounds",
"platform" : 8,
"partnerId" : 1,
"time" : "24-03-2021 11:03:04",
"data": {
"playerId": "24429392",
"externalReferenceId": "41d5-ae4a-48a83e6321a0",
"freeRoundValidity": "13-04-2021 11:04:04",
"numberOfFreeRounds": 40,
"amount": 0.1,
"currency":"EUR",
"gameIds": ["2"]
},
"hash" : "36435dd6e55d8926e2b97c4ae7450bee"
}
https://stg.otkgaming.com/serviceApi.php
Both endpoints now support multiple player entries.
- Fields
playerIdsandexternalReferenceIdscan now be sent as arrays. - Each value must be unique and have a maximum combined length of 20,000 characters.
{
"action" : "freeRounds",
"platform" : 8,
"partnerId" : 1,
"time" : "24-03-2021 11:03:04",
"data": {
"playerIds" :[28201644,456789],
"externalReferenceIds":["asd1","asdf2"],
"freeRoundValidity": "13-04-2021 11:04:04",
"numberOfFreeRounds": 40,
"amount": 0.1,
"currency":"EUR",
"gameIds": ["2"]
},
"hash" : "36435dd6e55d8926e2b97c4ae7450bee"
}
| Property Name | Descriptio | Type | Notes |
|---|---|---|---|
| action | request type | string | |
| platform | platform identifier | integer | unique per platform |
| partnerId | identifier of partner on the platform | integer | |
| time | request time | string | dd-mm-yyyy hh:mm:ss |
| data[playerId] | unique player identifier | string(100) | unique per platform |
| data[externalReferenceId] | unique free round reference identifier | string(100) | unique per platform |
| data[freeRoundValidity] | free round expire date | string | dd-mm-yyyy hh:mm:ss |
| data[numberOfFreeRounds] | number of free rounds | integer | |
| data[currency] | currency of bet amount | string(3) | currency of bet amount for all free rounds |
| data[amount] | the bet amount in the provided currency | number | the amount that is taken from game list response bets list |
| data[gameIds] | list of game identifiers | list of games, must be length of 1 game | only first launched game gets free rounds |
| hash | calculated sha256 string (privateKey provided game provider’s side) | string | hash string is calculated based on privateKey, time, and "data" in JSON string. Example $hash = hash("sha256", "privateKey15-02-2023 15:31:31json_encode(data) |
Response Example
- Success
- Rejected
https://stg.otkgaming.com
{
"code" : 0,
"message" : "ok",
"data" : {
"referenceId": "41d5-ae4a-48a83e6321a0"
}
}
https://stg.otkgaming.com
{
"code" : 8,
"message" : "hash not valid",
"data" : null
}
{
"code" : 9,
"message" : "platform not valid (partnerid or platform values are wrong",
"data" : null
}