In this article, you'll learn more about Conditions and how to use them in a rule. This will make more sense if you've already read Building a Rule.
Conditions are the events that have to happen or the requirements that have to be met before Effects are triggered.
Every rule requires valid Conditions and Effects. Talon.One's Rule Engine validates the Conditions you define, and if all are validated to TRUE, only then is an Effect triggered.
Choose between +Add Condition or Always Trigger Effects. If you choose Always Trigger Effects, the effects you set will trigger for every customer order.
You can add multiple conditions in a rule to set up more personalized, granular promotions.
For example, you can create a rule with the following conditions:
You can also use a Cart Item Filter in your condition. This is just one example of a Condition, there are many possibilities that can be achieved based on the data you send Talon.One.
When you click +Add Conditions a drop down will appear with a list possibilities. You can have several Conditions in a rule and choose whether "all" or "at least one" Condition must be true. Below you will find a list of these options and their definitions.
Coupon code is valid / Referral code is valid
Select this option if coupons or referral codes are required for your campaign. This condition is true if a customer enters a valid code from this campaign. This option is only visible when they have been activated while creating a campaign, or selected later in Settings
Coupon codes can be created on the Coupons page or with the API. Learn how to add Coupons for a campaign here. Unlike Coupons, Referral Codes are created with the API, read our developer documentation for creating Referral Codes and learn more about Referral Campaigns here.
Validate an attribute value
Select this option to build expressions using attributes. Click the field and the available attributes will open in the palette. Search the list for available attributes and select your required data points such as Events, Sessions, Profiles Attributes, etc.
Some examples of conditions you can create include:
- Session total is greater than 99$
- Current time is between Monday and Friday
- Destination is equal to Berlin
- Email contains .edu
- Coupon create date is before the current time (or a specific date)
You can use built-in attributes or use any custom attributes that you have integrated to build conditions.
For the "Validate an attribute value" condition we offer different logic operators depending on the type of attribute you select. Some attributes only need true or false answers (yes or no), others are number values and need more possibilities to create specific conditions
For the attribute "Current time" for example you can choose between unique operators:
- is after
- is before
- is between
- is not between
- is day of week
The standard operators for number values include:
- is equal to
- is not equal to
- is less/greater than
- is less/greater than or equal to
- is one of
- is not one of
- does not contain
So, you can choose "is one of" or "is not one of" and select (or type in) multiple inputs:
Check for custom attributes
Use this option to check if a current user or session has a value for the attribute. For example, if you want to check if a customer has an active subscription you can use the attribute "Subscription Active" then select "exists" or "does not exist".
Check for events
Use this option to create a condition triggered by system events like "Customer Account Registration" or "Customer Session Creation/Update/Close".
Coupon code is valid (without redemption)
Use this if you want to validate a coupon but NOT redeem it. This won't generate accept or reject coupon effects and can be used as a way of checking if a customer's coupon is valid.
Group multiple conditions
Add several Conditions in this group that will validate to "True" when at least one of these conditions matches. For example, a group of Conditions could include three different shipping cities.
Using the data you send Talon.One, you can create Custom Attributes and use them in your conditions. You can also use Cart Filters for building Conditions.
There are many possibilities for creating Conditions, so be sure to get in touch if you have questions about creating more customized rules and Campaigns.
Next, you will want to read: