A webhook is an HTTP(S) endpoint set up on a server to listen for requests sent by the CRM. Webhooks can be configured as actions in campaigns, triggering an external process for each player participating in a campaign.
Webhooks can be used for various purposes, such as:
- Granting bonuses to specific participants
- Allocating free spins to campaign participants
- Connecting to a third-party communication channel
Depending on campaign settings, a webhook may be executed multiple times for the same player and campaign.
Webhook Listener Requirements
Method
- Webhook listeners can be set up to receive requests via GET, POST, PUT or DELETE.
Request Format
- Default requests are sent in JSON format.
Example JSON Request
{
"JobID": "c57dc868-f3b8-4587-a288-758da6ee1ae0",
"ExternalCustomerID": [
"1908193917031211117"
],
"Campaign": "Campaign retargeting: - Lottery - high rollers wagered on a future draw"
}
Response Handling
- A valid response should return HTTP Status 200 (OK).
- If any other status code is received, the CRM will attempt up to five retries within approximately an hour.
Webhook Parameters
Parameter | Type | Description |
---|---|---|
JobID | string |
Unique identifier for the request (GUID or incremented number). |
ExternalCustomerID | string[] |
List of customer IDs (up to 10,000 per request). |
Campaign | string |
Name of the campaign that triggered the webhook. |
Configuring a Webhook
A webhook configuration requires a single HTTP endpoint. Once created, navigate to: Channels → Webhooks → Add the webhook.
Configuration Tips:
- Custom Parameters – Pass parameters via query strings or enable Advanced Settings.
- Single Logic per Webhook – Maintain one logic element per webhook for clarity.
- Use HTTPS – Always configure webhooks with secure HTTPS endpoints.
- Authorisation Headers – If required, enable Advanced Settings.
- Whitelisting IPs – Contact
product@aretonet.com
for an updated list of CRM request IPs.
Webhook Use Cases
Webhooks function as flexible API integrations for CRM campaigns. When triggered, a webhook executes like an SMS or email, but instead calls an API with campaign and player data.
- Grant free spins automatically upon campaign execution.
- Award bonuses or free bets to engaged players.
- Send notifications to VIP or customer support teams.
- Integrate with third-party communication channels
Advanced Webhooks
Enabling Advanced Settings
Advanced Settings allow for more complex webhook integrations, often eliminating the need for middleware.
Advanced Configuration Options:
- Define HTTP method (e.g.,
POST
,PUT
) - Customise request format (JSON, XML, or other formats)
- Add authorisation headers
- Modify Content-Type
- Include additional variable parameters
Advanced Webhook Rules:
✔ If no custom parameters are defined, the default JSON request is used.
✔ If a POST request requires URL parameters, these can be included in the webhook URL.
✔ If custom parameters are defined, the default JSON request is ignored.
✔ To modify the Content-Type, add a Content-Type
header.
✔ A maximum of 10 headers can be added.
Webhook Variables
The following variables can be used in webhook requests.
Standard Variables
Variable | Type | Description |
---|---|---|
{#EMAIL} |
string |
Player's email address |
{#MOBILE} |
string |
Player's mobile number |
{#CAMPAIGN} |
string |
Name of the campaign triggering the webhook |
{#UID} |
string |
Unique job identifier |
{#TestMode} |
string |
"true" if CRM is in sandbox mode |
{#PLAYERID} |
string |
Unique player identifier from registration |
Custom Fields
Variable | Type | Description |
---|---|---|
{#CustomString1} - {#CustomString4} |
string |
Custom string fields |
{#CustomInt1} - {#CustomInt4} |
integer |
Custom integer fields |
Player Profile Variables
Variable | Type | Description |
---|---|---|
{#COUNTRY} |
string |
2-letter country code |
{#BIRTHDAY_DAY} |
integer |
Player's birth day |
{#BIRTHDAY_MONTH} |
integer |
Player's birth month |
{#BIRTHDAY_YEAR} |
integer |
Player's birth year |
{#ZIPCODE} |
string |
Player's ZIP code |
{#CITY} |
string |
Player's city |
{#ACC_CURRENCY} |
string |
Player's account currency |
{#BALANCE} |
string |
Player's account balance |
{#LANGUAGE} |
string |
Player's 2-letter language code |
Custom Attributes
Custom attributes created in the CRM either during the integration or by meanas of a Data Operation block in a Journey, will be automatically added to the bottom of the dropdown list in the Variables section of the webhook UI.
By following these guidelines, users can effectively configure webhooks to automate CRM processes, integrate third-party services, and enhance customer engagement.