Skip to main content
Skip table of contents

Skip Message

You may find yourself in a scenario where you want to skip/suppress a message for a person based on some logic in the content itself. This tag allows you to do so.

{% skip_message message:"<user defined message>" %}

All message skips caused by this liquid tag will be recorded as a Message Skipped event in the person’s journey with:

  • reason = custom_skip

  • reason_detail = <user defined message>

Code snippets that can be included on top or within the personalization logic of any message serve as a good example.

Applications

Skip if there is no data in the external feed:

{% if ext_feed == empty %} {% skip_message message:"No data in feed"}

Skip if a person received a message within the last 2 days:

{% assign today_date = 'now' | date: '%s' %}
{% assign pre_date = last_contacted | date: '%s' %}
{% assign diffSeconds = today_date | minus: pre_date %}
{% assign diffDays = diffSeconds | divided_by: 3600 | divided_by: 24 %}
{% if diffDays < 2 %}
{% skip_message message:"Last contacted within last 2 days" %}
{% endif%}

The constraint used in the campaign is on user properties, whereas the variable is sent in the event properties.

The Zeta Marketing Platform manages skips at a person level, not a contact level. For example, consider person John Doe who has an email address john@doe.com (contact 1) and mobile phone number 555-345-6789 (contact 2). When the ZMP skips sending a campaign message to John’s email, it will also automatically skip sending him an SMS message, even if the skip criteria weren’t explicitly met for contact 2.

JavaScript errors detected

Please note, these errors can depend on your browser setup.

If this problem persists, please contact our support.