Reward Configuration - Create
This API allows merchants to create a new reward configuration used for assigning free bets to specific games under defined constraints.
POST /api/v1/integration/reward-configurations/create
Request
| Parameter Name | Data Type | Description | Required/Optional |
|---|---|---|---|
| name | String | Reward configuration name | Required |
| status | String | Reward configuration status [ACTIVE, INACTIVE] | Required |
| rewardType | String | Type of reward [FREE_BET] | Required |
| numberOfFreeBets | Integer | Number of free bets | Required |
| startDate | Instant | Start date in epoch milliseconds | Required |
| endDate | Instant | End date in epoch milliseconds | Required |
| duration | Integer | Duration of reward in minutes | Required |
| merchantId | UUID | Merchant ID | Required |
| timestamp | Long | Timestamp in epoch milliseconds | Required |
| hash | String | Hash signature for request verification. The hash is an HMAC SHA256 checksum of the concatenated parameter values (merchantId and timestamp). These values are encoded in UTF-8 and passed to the calculateHmacSha256 method along with the secret key. This hash must match the one generated by the merchant using the same logic and the shared secret key provided by HPGames. HMAC SHA256 Code Snippet | Required |
| games[].gameId | Integer | ID of the game eligible for the reward | Required |
| games[].betConstraints | Object | Bet constraints per currency | Required |
| games[].betConstraints.CURRENCY.betAmount | Decimal | Bet amount in CURRENCY | Required |
| games[].betConstraints.CURRENCY.maxWinPerBet | Decimal | Maximum win amount per bet in CURRENCY | Required |
Request example:
{
"name": "Reward",
"status": "ACTIVE",
"rewardType": "FREE_BET",
"numberOfFreeBets": 2,
"startDate": 1754495931035,
"endDate": 1754495931035,
"duration": 10,
"merchantId": "1387a6cc-3651-4473-ae52-e415caea3395",
"timestamp": 1754495931035,
"hash": "e93556d37a8c4eab7bda2d411322cdc4f0dc444c9101d9453a6635dfd8c73f7d",
"games": [
{
"gameId": 1,
"betConstraints": {
"EUR": {
"betAmount": 10,
"maxWinPerBet": 1000
}
}
}
]
}
Response
| Parameter Name | Data Type | Description | Required/Optional |
|---|---|---|---|
| id | UUID | Generated reward configuration ID | Required |
| name | String | Reward configuration name | Required |
| status | String | Reward configuration status [ACTIVE, INACTIVE] | Required |
| rewardType | String | Type of reward [FREE_BET] | Required |
| numberOfFreeBets | Integer | Number of free bets | Required |
| startDate | Instant | Start date in epoch milliseconds | Required |
| endDate | Instant | End date in epoch milliseconds | Required |
| duration | Integer | Duration in minutes | Required |
| merchantId | UUID | Merchant ID | Required |
| games | Array | List of game reward configurations | Required |
| games[].id | UUID | Generated internal ID for the game reward configuration | Required |
| games[].gameId | Integer | Game ID associated with the reward | Required |
| games[].betConstraints | Object | Constraints per currency | Required |
| games[].betConstraints.CURRENCY.betAmount | Decimal | Bet amount in CURRENCY | Required |
| games[].betConstraints.CURRENCY.maxWinPerBet | Decimal | Maximum win per bet in CURRENCY | Required |
Response example:
{
"id": "7a899322-c001-4187-8a8b-26d51d0e08fd",
"name": "Name",
"status": "ACTIVE",
"rewardType": "FREE_BET",
"numberOfFreeBets": 2,
"startDate": 1754495931035,
"endDate": 1754495931035,
"duration": 10,
"merchantId": "1387a6cc-3651-4473-ae52-e415caea3395",
"games": [
{
"id": "f72cb8ef-10e6-4903-8735-369f6544a0a2",
"gameId": 1,
"betConstraints": {
"EUR": {
"betAmount": 10,
"maxWinPerBet": 1000
}
}
}
]
}