Conditions
Control when a discount fires and which lines or options it matches
Conditions decide when a discount fires. They form a boolean tree attached to Branch nodes, and the same builder powers per-line and per-option matching targets.
Three Condition Shapes
| Shape | Purpose |
|---|---|
| Leaf | A single predicate, for example "subtotal is 100 or more" |
| Logical | Combines several children with AND, OR, or NOT |
| Array | Iterates a collection and combines the per-element results |
Array conditions power line-level and delivery-option-level filtering. They loop over each cart line or each delivery option and evaluate an inner condition per element.
A tree using all three shapes
This example reads: "cart is 100 or more, AND (customer is logged in OR shipping to Germany), AND at least one line is from vendor Acme".
Logical Operators
| Operator | Meaning |
|---|---|
| AND | All children must be true |
| OR | At least one child must be true |
| NOT | Negates a single child |
Trees can nest to any depth, so you can express combinations like "A AND (B OR NOT C)".
Comparison Operators
Fourteen operators are available for leaf predicates.
| Operator | Applies to |
|---|---|
| Equals | All types |
| Not equals | All types |
| Greater than | Numbers |
| Greater than or equal | Numbers |
| Less than | Numbers |
| Less than or equal | Numbers |
| In list | All types (value is a list) |
| Not in list | All types (value is a list) |
| Contains | Text |
| Does not contain | Text |
| Starts with | Text |
| Ends with | Text |
| Is null | All types (no value needed) |
| Is not null | All types (no value needed) |
Fields You Can Test
Every leaf predicate targets one of the following fields read from the cart at checkout.
| Field | Type |
|---|---|
| Cart subtotal amount | Number (money) |
| Cart total amount | Number (money) |
Any field that expects a Shopify id (product, variant, collection, customer, company) is filled with a resource picker that searches Shopify, so you never type raw ids.
Not Yet Available
The following fields are not exposed as condition sources at launch: custom metafields on product, customer, or cart; customer tags; order-history counters such as number of orders and amount spent; B2B company and company location; delivery estimated dates; cart tax and duty amounts; and weight. See How It Works for the roadmap.