Skip to content

Conversation

@iewilliam
Copy link
Contributor

This PR includes 2 sets of changes needed for storing customers' loyalty data in AEP:

  • Adding more fields to the pre-existing profile loyalty field group
  • Adding a new Experience Event loyalty transaction field group
    The data will typically come from the customer's Loyalty Management System, 3rd party or otherwise.

Profile Loyalty Field Group Changes

We are adding the following fields:

  • Fields for tracking the end user's points in a more comprehensive manner (expiredPoints, lifetimePoints, etc.)
  • lifetimePurchases: Some Loyalty Management Systems track the end user's lifetime purchases since they typically have visibility to the end user's purchases
  • tierExpiryDate: Loyalty programs with tier levels usually give the user a certain grace period before they are downgraded even if they no longer fulfill the tier's requirements (for example not enough points after spending it)
  • cardsDetails: Some loyalty programs are tied to specific cards instead of to the end user's loyalty program id

Experience Event Loyalty Field Group

This field group is for tracking loyalty transactions, which are usually tied to an end user's commercial transaction. Loyalty transactions are typically dependent on the commercial transaction's details, so Loyalty Management Systems conversely receive them from the customer and use them as input when resolving the loyalty program's business logic.

For example, the end user is trying to use a 10% off coupon while buying a $500 power tool. The Loyalty management system will need both the coupon code and the shopping cart to figure out:

  • Is the coupon code valid
  • Does it have any exclusions or limits
  • Calculate the final discount (is it simply $50 or is it only $40 due to some limits)
  • Calculate any points gained from the transaction (+450 points to the user's loyalty id)
    This field group would therefore be typically used together with a commercial transaction tracking field group, for example the Commerce Details field group, to capture the full transaction details.

Fields

  • discounts: Lists any loyalty discounts that are applied to this transaction, along with their cause (coupon, pointsRedemption, referralRedemption etc) and the promotionId of that cause
  • couponRedemption: Lists details about coupons that were redeemed in this transaction, if any
  • pointsRedemption: Lists details about points that were spent in this transaction, if any
  • pointsGained: Lists points that were gained as a result of this transaction
  • referralRedemption: Lists details about referrals that were redeemed in this transaction, if any

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant