Metadata
Overview
This endpoint allows you to pass additional information related to game sessions or player activities, ensuring accurate tracking and reporting.
POST /open-api-games/v1/games-processor
MetaData request has its own data and api fields and this means that it can contain different types of data. But at this moment the only types are roundComplete which carries information about completed round and freespinEnd which carries information about played bonus.
Round Complete
For the bet games provider has to inform platform after end of a round.
Parameters
Request:
| Name | Type | Description |
|---|---|---|
api | string | Name of operation, “metaData” here |
data | object | |
data.gameSession | string | Game session id. |
data.currency | string | Balance currency. Passed by the link to open the game. See section “Managing Games and Connections”, field accounts[].gameEmbedUrl. |
data.gameId | string | [Optional field] Game id is required for the providers who are using specific session mode. (F.E. Lobby Games) |
data.api | string | Name of “metaData” operation. “roundComplete” in this case |
data.data.betId | string | Bet id (round) which was completed |
Response:
| Name | Type | Description |
|---|---|---|
api | string | Name of operation: “debit”, “credit”, “rollback” |
isSuccess | boolean | Is success? |
error | string | Empty string if isSuccess == true. |
errorMsg | string | Error code, see “Errors” table |
data | object | |
data.api | string | Name of “metaData” operation |
data.data | string | Internal ‘data’ field |
Errors:
| Name | Description |
|---|---|
| NO_ERRORS | No errors. Passed if isSuccess == true. |
| ALREADY_PROCESSED | The operation for this transaction has already been successfully processed. |
| SIGN_NOT_PROVIDED | Sign header was not passed. |
| INVALID_SIGN | Invalid signature. |
| UNKNOWN_CURRENCY | Unknown currency. |
| INSUFFICIENT_BALANCE | The player’s balance is not enough to carry out the operation. |
| INTERNAL_ERROR | Internal service error. The operation must be repeated. |
Example
Request:
curl --location --request POST 'https://apiEndpoint/open-api-games/v1/games-processor' \
--header 'Content-Type: application/json' \
--data '{
"api": "metaData",
"data": {
"gameSessionId": "16e2ea64-5725-40a4-99cc-c5c0deb8568d",
"currency": "RUB",
"api":"roundComplete",
"data":{
"betId":"4687286"
}
}'
Response:
{
"api": "metaData",
"isSuccess": true,
"error": "",
"errorMsg": "NO_ERRORS",
"data": {
"data": {},
"api": "roundComplete"
}
}
Free Spin End
Free spin end metadata is required to inform platform about end of free spins in bound of one bonus.
Parameters
Request:
| Name | Type | Description |
|---|---|---|
api | string | Name of operation, “metaData” here |
data | object | |
data.gameSession | string | Game session id. |
data.currency | string | Balance currency. Passed by the link to open the game. See section “Managing Games and Connections”, field accounts[].gameEmbedUrl. |
data.gameId | string | [Optional field] Game id is required for the providers who are using specific session mode. (F.E. Lobby Games) |
data.api | string | Name of “metaData” operation. “freespinEnd” in this case available |
data.data.bonusId | string | Bonus id which must be reported as played |
data.data.total | int | Total amount of win for reported bonusId |
Response:
| Name | Type | Description |
|---|---|---|
api | string | Name of operation: “debit”, “credit”, “rollback” |
isSuccess | boolean | Is success? |
error | string | Empty string if isSuccess == true. |
errorMsg | string | Error code, see “Errors” table |
data | object | |
data.api | string | Name of “metaData” operation |
data.data | string | Internal ‘data’ field |
Errors:
| Name | Description |
|---|---|
| NO_ERRORS | No errors. Passed if isSuccess == true. |
| ALREADY_PROCESSED | The operation for this transaction has already been successfully processed. |
| SIGN_NOT_PROVIDED | Sign header was not passed. |
| INVALID_SIGN | Invalid signature. |
| UNKNOWN_CURRENCY | Unknown currency. |
| INSUFFICIENT_BALANCE | The player’s balance is not enough to carry out the operation. |
| INTERNAL_ERROR | Internal service error. The operation must be repeated. |
Example
Request:
curl --location --request POST 'https://apiEndpoint/open-api-games/v1/games-processor' \
--header 'Content-Type: application/json' \
--data '{
"api": "metaData",
"data": {
"gameSessionId": "16e2ea64-5725-40a4-99cc-c5c0deb8568d",
"currency": "RUB",
"api":"freespinEnd",
"data":{
"bonusId":"1234",
"total" : 1000
}
}'
Response:
{
"api": "metaData",
"isSuccess": true,
"error": "",
"errorMsg": "NO_ERRORS",
"data": {
"data": {},
"api": "freespinEnd"
}
}