Loyalty Webhook

Subscribe to loyalty updated webhook through Datanuum support to get notified on every updates to the loyalty points or expiry of the customer.

 

A simple Http POST method can accept the webhooks and the information provided in the JSON can be used for saving into ERP Database or POS to display it for the counter operator to check and help the customers to redeem points

EXAMPLE REQUEST:

POST http://erp.company.com/datanuum/webhook


Payload:
{
  "origin": {
    "trigger": "LOYALTY_POINT_UPDATED",
    "source": "Loyalty Core",
    "country": {
      "iso": "AE"
    }
  },
  "customer": {
    "phone": "971505093262",
    "accountId": "CU1662313",
    "first": "Customer",
    "gender": "F",
    "city": "DUBAI",
    "country": "AE",
    "language": "EN",
    "accountType": "CUSTOMER",
    "businessFields": {
      "wouldYouLikeToReceiveInformationFromPanE": "1",
      "customerType": "B2C",
      "preferredLanguage": "English"
    }
  },
  "entity": {
    "loyaltyTier": {
      "name": "SILVER",
      "logo": "https://ub3-static.s3.amazonaws.com/journey/1467/silver-2134749556.png",
      "tierOrder": 1,
      "pointsAttain": 0,
      "pointsAttainDays": 365,
      "pointsRetain": 0,
      "pointsRetainDays": 365,
      "pointsExpiryDays": 365,
      "benefits": "Silver Benefits text"
    },
    "nextTier": {
      "id": 178,
      "name": "GOLD",
      "logo": "https://ub3-static.s3.amazonaws.com/journey/1467/gold-71249659870.png",
      "tierOrder": 2,
      "pointsAttain": 15000,
      "pointsAttainDays": 365,
      "pointsRetain": 5000,
      "pointsRetainDays": 365,
      "pointsExpiryDays": 365,
      "benefits": "Gold Benefits text"
    },
    "tierExpiry": "2024-06-23 00:00:00 UTC",
    "tierRetainExpiry": "2024-06-23 00:00:00 UTC",
    "wallets": [
      {
        "countryIso": "AE",
        "currency": "AED",
        "point": 4187,
        "value": 20.94,
        "pointSetting": {
          "id": 347,
          "countryIso": "AE",
          "currency": "AED",
          "pointValue": 0.005,
          "created": "2021-12-17 09:31:40 UTC",
          "createdBy": 2332,
          "modified": "2023-04-11 10:35:02 UTC",
          "modifiedBy": 2299
        }
      }
    ],
    "pointExpiry": "2024-06-23 00:00:00 UTC",
    "tierBalance": 187,
    "pendingTierBalance": 0,
    "toNextTier": 14813,
    "redeemable": [
      {
        "countryIso": "AE",
        "currency": "AED",
        "point": 4187,
        "value": 20.94
      }
    ],
    "membershipDate": "2023-06-24 00:00:00 UTC",
    "cumulativeCredit": 4187,
    "pendingCredit": 0,
    "calculateByPending": false,
    "membershipId": "68268500"
  },
  "generic": false
}

Expected Response: HttpStatus.200