Adapt Message Content Based on Coupon Availability

Prev Next

Goal

Adapt the displayed content within a message based on whether coupons are still available in a selected coupon list.


Background Information

In Mapp Engage, you can dynamically adapt message content depending on the availability of coupons. This ensures that recipients see the right content even if a coupon list runs out of codes during sendout. The logic is implemented using InsertIf expressions that control which content block is shown in the final message.


Prerequisites

  • A coupon list must exist with the Display Alternative Text setting activated (see Create a New Coupon List).

  • Basic understanding of personalization syntax (InsertIf expressions).


Procedure

  1. In the Main Navigation, go to Audience > Segmentation > Personalization.

  2. Click Create to open the Personalization Builder.

  3. In the Personalization Builder, create a personalization for when coupons are available:

    <%InsertIf expression="${(ecx:isEmptyCouponList(coupon['MyCouponList']) == 'false')}"%>
    • Replace MyCouponList with the name of your coupon list.

    • This expression displays the corresponding content when coupons are available.

  4. Create a personalization for when no coupons are available:

    <%InsertIf expression="${(ecx:isEmptyCouponList(coupon['MyCouponList']) == 'true')}"%>
    • This expression displays different content when the coupon list is empty.

  5. (Optional) Refine the personalization with additional conditions.

    Example: Show alternative content if no coupons are available or if the customer has not yet completed a purchase:

    <%InsertIf expression="${(ecx:isEmptyCouponList(coupon['MyCouponList']) == 'true') or (user.CustomAttribute['Customer'] == 'true')}"%>
  6. Save the personalization.

  7. Insert the personalization into the message content where you want the dynamic blocks to appear (see Insert a Personalization).


Additional Information

Looking for a structured learning path?

Learn step by step in our Academy Course: Mapp Engage - Personalization Rules.

  • Actual coupons are not inserted during test or preview messages. If no preview text is defined, the system automatically generates placeholder text based on the coupon list name (e.g., birthdaycoupons_previewCoupon).

  • For general information about managing coupon lists, see Manage Coupon List.