Skip to main content

Backend integration

Bonus API introduction

note

Provider - side which provides games (Aviatrix).

Partner - side which integrates games.

Brand - partner's casino website where users play games and place bets.

This document describes the methods implemented by the provider. These methods are used to retrieve a list of bonus configurations, to manage bonuses and bonus assignments, to retrieve bonus assignment status per player.

good to know

API-generated bonuses follow the same rules as manual bonuses. Any bets made with these bonuses are deducted 100% from the overall turnover.

Bonus API methods

good to know

All POST requests contain the X-Auth-Signature HTTP header required to authenticate the host. This removes the need for IP whitelisting during the integration process. Otherwise, it deprives the provider of the ability to scale quickly (horizontally) without notifying the platform.

tip

Ask your integration manager for the base URL.

/CreateBonusConfig

Method is called to create new bonus configuration.

Attention

When creating a bonus configuration for multiple games in a single request, only games within the same category can be specified: crash games or slot games.

Game combination examples:

  • nft-aviatrix
  • second-chance
  • nft-aviatrix, second-chance
  • aviatrix-fruits

Example of the request

Attention

Request headers specified in example are required: Accept, Content-Type, X-Auth-Signature.

POST /bonus/v1/CreateBonusConfig HTTP/1.1
Content-Type: application/json
Accept: application/json
X-Auth-Signature: <signature>

{
"cid": "some-brand-id",
"config": {
"type": "free_bets",
"validFrom": "2020-12-03T12:15:30.000Z",
"validTo": "2020-12-03T12:15:30.000Z",
"gameSettings": [
{
"gameId": "some-game-id",
"minOddsWagering": 50.0,
"maxOddsWagering": 150.0
}
],
"isPlayable": false,
"wagering": {
"multiplier": 10,
"useBonusMoney": true
}
}
}
ParameterDescriptionTypeRequirementsExplanation
cidbrand identifierstringrequiredunique identifier
config.typebonus configuration typestringrequiredavailable values: free_bets
config.validFromthe begin of valid bonus configuration periodtimestamprequiredformat: yyyy-MM-dd’T’HH:mm:ss.SSSZ / RFC3339
config.validTothe end of valid bonus configuration periodtimestamprequiredformat: yyyy-MM-dd’T’HH:mm:ss.SSSZ / RFC3339
config.gameSettingslist of game specific settingsarrayrequiredsettings for a specific game type; at the same time, only games within the same category can be specified: crash games or slot games
gameIdgame identifierstringrequiredcurrent identifiers: nft-aviatrix, second-chance, aviatrix-fruits
minOddsWageringwagering minimum oddsdoubleoptionalodds in minor currency unit format (1.95 -> 195); valid range [0-10000]; not supported by aviatrix-fruits
maxOddsWageringwagering maximum oddsdoubleoptionalodds in minor currency unit format (1.95 -> 195); valid range [0-10000]; not supported by aviatrix-fruits
config.isPlayablepossibility to play with bonus balanceboolrequiredif true then it is possible to play with bonus balance
wagering.multiplierwagering multiplierintegerrequiredinteger multiplier for a wagering, for example 30
wagering.useBonusMoneydependency between bonus balance and wageringboolrequiredif true then playing with bonus balance will affect wagering

Example of the response from the server

HTTP/1.1 200 OK
{
"bonusConfigId": "6f41bd2a-4621-42e5-883c-647b8995684d",
"cid": "some-brand-id",
"config": {
"type": "free_bets",
"validFrom": "2020-12-03T12:15:30.000Z",
"validTo": "2020-12-03T12:15:30.000Z",
"gameSettings": [
{
"gameId": "some-game-id",
"minOddsWagering": 50.0,
"maxOddsWagering": 150.0
}
],
"isPlayable": false,
"wagering": {
"multiplier": 10,
"useBonusMoney": true
}
}
}
ParameterDescriptionTypeExplanation
bonusConfigIdbonus configuration identifierstringunique identifier, format: uuid
cidbrand identifierstringunique identifier
config.typebonus configuration typestringavailable values: free_bets
config.validFromthe begin of valid bonus configuration periodtimestampformat: yyyy-MM-dd’T’HH:mm:ss.SSSZ / RFC3339
config.validTothe end of valid bonus configuration periodtimestampformat: yyyy-MM-dd’T’HH:mm:ss.SSSZ / RFC3339
config.gameSettingslist of game specific settingsarraysettings for a specific game type; at the same time, only games within the same category can be specified: crash games or slot games
gameIdgame identifierstringcurrent identifiers: nft-aviatrix, second-chance, aviatrix-fruits
minOddsWageringwagering minimum oddsdoubleodds in minor currency unit format (1.95 -> 195); valid range [0-10000]; not supported by aviatrix-fruits
maxOddsWageringwagering maximum oddsdoubleodds in minor currency unit format (1.95 -> 195); valid range [0-10000]; not supported by aviatrix-fruits
config.isPlayablepossibility to play with bonus balanceboolif true then it is possible to play with bonus balance
wagering.multiplierwagering multiplierintegerinteger multiplier for a wagering, for example 30
wagering.useBonusMoneydependency between bonus balance and wageringboolif true then playing with bonus balance will affect wagering

/GetBonusConfigs

Method is called to retrieve list of existing bonus configurations for specified brand.

Example of the request

Attention

Request headers specified in example are required: Accept, Content-Type, X-Auth-Signature.

POST /bonus/v1/GetBonusConfigs HTTP/1.1
Content-Type: application/json
Accept: application/json
X-Auth-Signature: <signature>

{
"cid": "some-brand-id",
"showActiveOnly": false
}
ParameterDescriptionTypeRequirementsExplanation
cidbrand identifierstringrequiredunique identifier
showActiveOnlyfilter flagbooloptionalallows to display only active bonus configurations

Example of the response from the server

HTTP/1.1 200 OK
{
"values": [
{
"bonusConfigId": "6f41bd2a-4621-42e5-883c-647b8995684d",
"cid": "some-brand-id",
"config": {
"type": "free_bets",
"validFrom": "2020-12-03T12:15:30.000Z",
"validTo": "2020-12-03T12:15:30.000Z",
"gameSettings": [
{
"gameId": "some-game-id",
"minOddsWagering": 50.0,
"maxOddsWagering": 150.0
}
],
"isPlayable": false,
"wagering": {
"multiplier": 10,
"useBonusMoney": true
}
}
}
]
}
ParameterDescriptionTypeExplanation
valueslist of bonus configurationsarraycan present expired, active and inactive configurations
bonusConfigIdbonus configuration identifierstringunique identifier, format: uuid
cidbrand identifierstringunique identifier
config.typebonus configuration typestringavailable values: free_bets
config.validFromthe begin of valid bonus configuration periodtimestampformat: yyyy-MM-dd’T’HH:mm:ss.SSSZ / RFC3339
config.validTothe end of valid bonus configuration periodtimestampformat: yyyy-MM-dd’T’HH:mm:ss.SSSZ / RFC3339
config.gameSettingslist of game specific settingsarraysettings for a specific game type; at the same time, only games within the same category can be specified: crash games or slot games
gameIdgame identifierstringcurrent identifiers: nft-aviatrix, second-chance, aviatrix-fruits
minOddsWageringwagering minimum oddsdoubleodds in minor currency unit format (1.95 -> 195); valid range [0-10000]; not supported by aviatrix-fruits
maxOddsWageringwagering maximum oddsdoubleodds in minor currency unit format (1.95 -> 195); valid range [0-10000]; not supported by aviatrix-fruits
config.isPlayablepossibility to play with bonus balanceboolif true then it is possible to play with bonus balance
wagering.multiplierwagering multiplierintegerinteger multiplier for a wagering, for example 30
wagering.useBonusMoneydependency between bonus balance and wageringboolif true then playing with bonus balance will affect wagering

/CreateFreeBet

Method is called to create new bonus campaign within existing bonus configuration.

Example of the request

Attention

Request headers specified in example are required: Accept, Content-Type, X-Auth-Signature.

POST /bonus/v1/CreateFreeBet HTTP/1.1
Content-Type: application/json
Accept: application/json
X-Auth-Signature: <signature>

{
"cid": "some-brand-id",
"bonusConfigId": "6f41bd2a-4621-42e5-883c-647b8995684d",
"name": "Some Campaign Name",
"bonus": {
"betCount": 5,
"currencySettings": {
"EUR": {
"amount": 5,
"maxPromoWinAmount": 10000,
"maxBetWageringAmount": 200
},
"USD": {
"amount": 6,
"maxPromoWinAmount": 12000,
"maxBetWageringAmount": 400
}
},
"validTo": "2020-12-03T12:15:30.000Z"
}
}
ParameterDescriptionTypeRequirementsExplanation
cidbrand identifierstringrequiredunique identifier
bonusConfigIdbonus configuration identifierstringrequiredunique identifier, format: uuid
namebonus campaign namestringrequirednaming of a bonus campaign
bonus.betCountamount of bonus betsintegerrequiredbonus bets that will be granted to a player
bonus.currencySettingsmap of currency specific settingsmaprequiredbonus bet currency, format ISO-4217-3
amountamount of bonus betintegerrequiredformat minor currency unit, example: 1.95$ -> 195; can't be lesser than minimal and greater than maximal bet amount for specified brand
maxPromoWinAmountmaximum bonus win amountintegerrequiredformat minor currency unit, example: 1.95$ -> 195; can't be greater than maximal win amount for specified brand
maxBetWageringAmountmaximum amount for wageringintegeroptionalformat minor currency unit, example: 1.95$ -> 195
bonus.validToexpiration period of bonus campaigntimestamprequiredformat: yyyy-MM-dd’T’HH:mm:ss.SSSZ / RFC3339

Example of the response from the server

HTTP/1.1 200 OK
{
"bonusId": "00ed751a-a2ec-4077-beb0-db2cb795894e",
"cid": "some-brand-id",
"bonusConfigId": "6f41bd2a-4621-42e5-883c-647b8995684d",
"name": "Some Campaign Name",
"bonus": {
"betCount": 5,
"currencySettings": {
"EUR": {
"amount": 5,
"maxPromoWinAmount": 10000,
"maxBetWageringAmount": 200
},
"USD": {
"amount": 6,
"maxPromoWinAmount": 12000,
"maxBetWageringAmount": 400
}
},
"validTo": "2020-12-03T12:15:30.000Z"
}
}
ParameterDescriptionTypeExplanation
bonusIdbonus campaign identifierstringbonus campaign unique identifier, format: uuid
cidbrand identifierstringunique identifier
bonusConfigIdbonus configuration identifierstringunique identifier, format: uuid
namebonus campaign namestringnaming of a bonus campaign
bonus.betCountamount of bonus betsintegerbonus bets that will be granted to a player
bonus.currencySettingsmap of currency specific settingsmapbonus bet currency, format: ISO-4217-3
amountamount of bonus betintegerformat minor currency unit, example: 1.95$ -> 195; can't be lesser than minimal and greater than maximal bet amount for specified brand
maxPromoWinAmountmaximum bonus win amountintegerformat minor currency unit, example: 1.95$ -> 195; can't be greater than maximal win amount for specified brand
maxBetWageringAmountmaximum amount for wageringintegerformat minor currency unit, example: 1.95$ -> 195
bonus.validToexpiration period of bonus campaigntimestampformat: yyyy-MM-dd’T’HH:mm:ss.SSSZ / RFC3339

/DisableBonus

Method is called to disable existing bonus campaign.

Example of the request

Attention

Request headers specified in example are required: Accept, Content-Type, X-Auth-Signature.

POST /bonus/v1/DisableBonus HTTP/1.1
Content-Type: application/json
Accept: application/json
X-Auth-Signature: <signature>

{
"bonusId": "00ed751a-a2ec-4077-beb0-db2cb795894e",
"cid": "some-brand-id"
}
ParameterDescriptionTypeRequirementsExplanation
bonusIdbonus campaign identifierstringrequiredbonus campaign unique identifier, format: uuid
cidbrand identifierstringrequiredunique identifier

Example of the response from the server

HTTP/1.1 200 OK
{
"bonusId": "00ed751a-a2ec-4077-beb0-db2cb795894e"
}
ParameterDescriptionTypeExplanation
bonusIdbonus campaign identifierstringbonus campaign unique identifier, format: uuid

/AssignBonus

Method is called to assign a bonus to specified players.

Example of the request

Attention

Request headers specified in example are required: Accept, Content-Type, X-Auth-Signature.

POST /bonus/v1/AssignBonus HTTP/1.1
Content-Type: application/json
Accept: application/json
X-Auth-Signature: <signature>

{
"bonusId": "00ed751a-a2ec-4077-beb0-db2cb795894e",
"playerIds": ["player1", "player2", "player3"],
"cid": "some-brand-id"
}
ParameterDescriptionTypeRequirementsExplanation
bonusIdbonus campaign identifierstringrequiredbonus campaign unique identifier, format: uuid
playerIdslist of player identifiersarray of stringsrequiredplayers that will be granted with a bonus related to specified bonus campaign
cidbrand identifierstringrequiredunique identifier

Example of the response from the server

HTTP/1.1 200 OK
{
"bonusJobId": "71ac9c1b-faa7-4b77-ba49-beed09f3fb00",
"bonusId": "00ed751a-a2ec-4077-beb0-db2cb795894e",
"status": "pending",
"createdAt": "2020-12-03T12:15:30.000Z"
}
ParameterDescriptionTypeExplanation
bonusJobIdbonus job identifierstringunique identifier for a job that will assign/revoke bonus to/from players, format: uuid
bonusIdbonus campaign identifierstringbonus campaign unique identifier, format: uuid
statusbonus job statusstringpossible values: pending, completed, failed
createdAtstart of bonus job processtimestampformat: yyyy-MM-dd’T’HH:mm:ss.SSSZ / RFC3339

/GetAssignBonusStatus

Method is called to retrieve bonus assignment job status.

Example of the request

Attention

Request headers specified in example are required: Accept, Content-Type, X-Auth-Signature.

POST /bonus/v1/GetAssignBonusStatus HTTP/1.1
Content-Type: application/json
Accept: application/json
X-Auth-Signature: <signature>

{
"jobBonusAssignmentId": "99999",
"cid": "123"
}
ParameterDescriptionTypeRequirementsExplanation
jobBonusAssignmentIdbonus job identifierstringrequiredunique identifier for a job that will assign/revoke bonus to/from players, format: uuid
cidbrand identifierstringrequiredunique identifier

Example of the response from the server

HTTP/1.1 200 OK
{
"bonusJobId": "71ac9c1b-faa7-4b77-ba49-beed09f3fb00",
"bonusId": "00ed751a-a2ec-4077-beb0-db2cb795894e",
"status": "pending",
"createdAt": "2020-12-03T12:15:30.000Z"
}
ParameterDescriptionTypeExplanation
bonusJobIdbonus job identifierstringunique identifier for a job that will assign/revoke bonus to/from players, format: uuid
bonusIdbonus campaign identifierstringbonus campaign unique identifier, format: uuid
statusstate of bonus job processstringpossible values: pending, completed, failed
createdAtstart of bonus job processtimestampformat: yyyy-MM-dd’T’HH:mm:ss.SSSZ / RFC3339

/RevokeBonus

Method is called to revoke bonus assignment for specific players.

Example of the request

Attention

Request headers specified in example are required: Accept, Content-Type, X-Auth-Signature.

POST /bonus/v1/RevokeBonus HTTP/1.1
Content-Type: application/json
Accept: application/json
X-Auth-Signature: <signature>

{
"bonusId": "00ed751a-a2ec-4077-beb0-db2cb795894e",
"playerIds": ["player1", "player2", "player3"],
"cid": "some-brand-id"
}
ParameterDescriptionTypeRequirementsExplanation
bonusIdbonus campaign identifierstringrequiredbonus campaign unique identifier, format: uuid
playerIdslist of player identifiersarray of stringsrequiredplayers whose bonus we want to revoke
cidbrand identifierstringrequiredunique identifier

Example of the response from the server

HTTP/1.1 200 OK
{
"bonusJobId": "71ac9c1b-faa7-4b77-ba49-beed09f3fb00",
"bonusId": "00ed751a-a2ec-4077-beb0-db2cb795894e",
"status": "pending",
"createdAt": "2020-12-03T12:15:30.000Z"
}
ParameterDescriptionTypeExplanation
bonusJobIdbonus job identifierstringunique identifier for a job that will assign/revoke bonus to/from players, format: uuid
bonusIdbonus campaign identifierstringbonus campaign unique identifier, format: uuid
statusstate of bonus job processstringpossible values: pending, completed, failed
createdAtstart of bonus job processtimestampformat: yyyy-MM-dd’T’HH:mm:ss.SSSZ / RFC3339

/GetPlayerBonusAssignment

Method is called to retrieve bonus state and wagering progress for specific players.

Example of the request

Attention

Request headers specified in example are required: Accept, Content-Type, X-Auth-Signature.

POST /bonus/v1/GetPlayerBonusAssignment HTTP/1.1
Content-Type: application/json
Accept: application/json
X-Auth-Signature: <signature>

{
"bonusId": "00ed751a-a2ec-4077-beb0-db2cb795894e",
"playerIds": ["player1", "player2", "player3"],
"cid": "some-brand-id"
}
ParameterDescriptionTypeRequirementsExplanation
bonusIdbonus campaign identifierstringrequiredbonus campaign unique identifier, format: uuid
playerIdslist of player identifiersarray of stringsrequiredplayers whose bonus state we want to clarify
cidbrand identifierstringrequiredunique identifier

Example of the response from the server

HTTP/1.1 200 OK
{
"assignments": [
{
"playerBonusAssignmentId": "71ac9c1b-faa7-4b77-ba49-beed09f3fb00",
"playerId": "player1",
"createdAt": "2025-06-11T16:48:55Z",
"validTo": "2020-12-03T12:15:30.000Z",
"freeBet": {
"betCountPlaced": 5,
"betCountLimit": 10,
"status": "active"
}
}
]
}
ParameterDescriptionTypeExplanation
assignmentslist of player's bonus statesarraylist that shows current state of a bonus for players that were passed in request
playerBonusAssignmentIdbonus job identifierstringunique identifier for a player and bonus relation, format: uuid
playerIdplayer identifierstringplayer identifier in partner's system
createdAtwhen bonus was assigned to a playertimestampformat: yyyy-MM-dd’T’HH:mm:ss.SSSZ / RFC3339
validTobonus active periodtimestampformat: yyyy-MM-dd’T’HH:mm:ss.SSSZ / RFC3339
freeBet.betCountPlacedamount of played bonus betsintegeramount of bonus bets that player has made
freeBet.betCountLimitamount of granted bonus betsintegeramount of bonus bets granted to a player by bonus campaign
freeBet.statusbonus bet wagering statusstringpossible values: preassigned, pending, active, wagering, completed, expired, deassigned, unwagered, canceled

Bonus API error processing

In general case when error occurs then provider's server returns the response in format:

{
"code": 400,
"message": "error text"
}

Error response details

HTTP StatusMessage textRetryDescription
400Bad request: playerIds array exceeds 100 elementsNoThe playerIds array must contain no more than 100 elements.
400Bad request: betCount must be non-negativeNoThe betCount value cannot be negative.
400Bad request: bonus is disabledNoAttempt to assign disabled bonus.
400Missing required fieldNoOne or more required fields are missing.
400Invalid requestNoGeneral validation error. Please contact provider's support team.
404Bonus not foundNoThe specified bonusId does not exist.
404Job bonus assignment not foundNoThe referenced jobBonusAssignment was not found.
404Bonus config not foundNoThe provided bonusConfigId does not exist.
429Too many requestsYesThe client has sent too many requests in a given amount of time. Throttling in effect.
429Monthly quota reached: create free bet. Contact your integration manager.YesThe domain has reached its monthly quota for creating free bet bonus.
429Monthly quota reached: assign bonus. Contact your integration manager.YesThe domain has reached its monthly quota for bonus assignment.
500Internal server errorYesUnexpected server error. If it remains after few retry attempts, then please contact provider's support team.