ThrillPots Events
ThrillPots publishes a number of events which your integration service can subscribe to. There are a number of reasons you may want to consume these events, for example:
- Synthesizing related Kafka/RabbitMQ events
- Storing the events for BI / Analysis purposes
The following events are currently published by ThrillPots Gateway:
JackpotUpdateEvent
- contains the latest jackpot values for the specified Jackpot Instance- Reference
{
"event_type": "JackpotUpdateEvent",
"event_id": "d6f05820-1da2-4152-bcba-6c0186f6cd77"
"data": {
"id": "jackpot instance ID",
"status": String,
"currency": String,
"allowed_brands": [String],
"allowed_sources": [String],
"pots": [
{
"id": String,
"is_progressive": Boolean,
"current_value": Number
}
],
"last_updated": Number
}
}
JackpotWinEvent
- contains the details of a jackpot win- Reference
{
"event_type": "JackpotWinEvent",
"event_id": "3fe809f4-c94f-4950-9b86-5f2d0b8f604f"
"data": {
"brand_id": String,
"player_id": String,
"source_id": String | null,
"instance_id": String,
"jackpot_name": String,
"timestamp": Number,
"win_pot_it": String,
"win_amount": Number,
"currency_multipliers": {
"brand_id": String,
"base_currency": String,
"multipliers": {
"EUR": Number,
"GBP": Number,
"ZAR": Number,
...
"NZD": Number,
"SEK": Number
}
}
"games_in_jackpot": [String],
"seed": Number,
"win_withheld": Boolean,
"seed_deficit": Number,
"community_winners": null | [{
"player_id": String,
"brand_id": String,
"currency": String,
"win_amount": Number
}]
}
}
RaffleWinEvent
- contains the details of a Raffle Win- Reference
{
"brand_id": String,
"instance_id": String,
"jackpot_name": String,
"jackpot_currency": String,
"currency_multipliers": {
"brand_id": String,
"base_currency": String,
"multipliers": {
"EUR": Number,
"GBP": Number,
"ZAR": Number,
...
"NZD": Number,
"SEK": Number
}
}
"timestamp": Number,
"winners": [
{
"player_id": String,
"brand_id": String,
"currency": String,
"win_amount": Number
}
],
"win_withheld": bool
}
OptInEvent
- contains the details of a player opt-in or opt-out into a Jackpot Instance Reference
{
"event_type": "OptInEvent",
"event_id": "27045bf8-78d2-4f99-97f1-e7d2e3aa434d"
"data": {
"instance_id": String,
"player_id": String,
"ext_player_id": String,
"player_brand_id": String,
"preferred_contribution_value": [Number],
"contribution_count": Integer,
"contribution_value": Number,
"opted_in": Boolean,
"last_updated": Integer
}
}
CommunityPayoutErrorEvent
- sent in case of an error that is encountered when processing community payouts Reference
{
"event_type": "CommunityPayoutErrorEvent",
"event_id": "c034a751-cf91-4722-bc89-a2f8af472805"
"data": {
"instance_id": String,
"gameround_id": String,
"tx_credit_id": String,
"failed_payouts": [
{
"player_id": String,
"brand_id": String,
"currency": String,
"win_amount": Number
}
]
}
}
RafflePayoutErrorEvent
- sent in case of an error that is encountered when processing raffle payouts Reference
{
"event_type": "RafflePayoutErrorEvent",
"event_id": "e981296b-199f-4454-b4ec-b3f36910c2cc"
"data": {
"instance_id": String,
"failed_payouts": [
{
"player_id": String,
"brand_id": String,
"currency": String,
"win_amount": Number
}
]
}
}
The ThrillPots events are published via the WebSocket endpoint /events
.
Authenticating the Websocket connection to receive events
Once you have established a WebSocket connection from your event processor service to ThrillPots Gateway, you will need to send an Authenticate
message which contains your Thrill-ID JWT token to authenticate your service to receive events.
{
"action": {
"Authenticate": {
"auth_token": "{{thrill-id-jwt}}"
}
}
}
If the authentication fails, the connection will be closed. Once you have authenticated, you should start receiving the events from the ThrillPots service.