Advanced

Conditions

Reusable logic blocks for automation, visibility, and filters.

Intro

A Condition is a saved piece of logic — “shipping method contains Express”, “tag equals VIP”, “SKU starts with FR-” — that other features reuse. Write it once, reference it everywhere.

Purpose

  • Keep rules consistent: one definition of “VIP order” across the store
  • Make Automation Rules and Visibility easier to read and maintain

Create a condition

  1. Open Advanced → Conditions and click New Condition.
  2. Add rows: Entity, Field, Operator, Value, and — between rows — Combine with (And / Or). Set Product item matching (Across items or Single item) when the condition has several product-item rows.
  3. Give it a Title by meaning — “VIP order”, not “tag=vip v2” — and a Group.
  4. Reference it from Automation Rules, Visibility, Store Filters, Shipment Filters, or a Document.
  5. Test it in the Automation Rules Tester with a known order that should match — and one that should not.

Entities

EntityDescribesNote
OrderThe order: totals (incl. tax), label, payment / fulfillment status, channel, source, tags, custom attributes, delivery date (also by metafield key)
Product itemOne line item: name, SKU, barcode, type, vendor, tags, collections, price, quantity, properties, fulfillment location, Location available quantity (stock on hand at that location — see below), metafields, and its checkout classification — Shipping Group (checkout), Checkout rate code / name, Checkout rate strategy (sum_prices own box · append_free rides free in another group's box · highest_wins one price for the box), Checkout rate shared with typeThe only entity that can select lines — used by split actions and by document row filters. Checkout fields need the order's checkout summary from Shipping Rates; pair Checkout rate shared with type with a Type row on the same item
Any item in shipment / No item in shipmentShipment-wide gates: "at least one line where …" / "no line where …". Rows placed next to each other form one check that a single item must satisfy; a row of another entity in between starts a new, independent check — so "has livestock" above and "has a plain supply" below are two questions no single item has to answerDecide whether the condition matches; never pick lines. Item match mode: Match any item / Match all items
ShipmentStatus, Tags, Printed document, Printed document count, Printed document outdated by item changesShipment stage only — never matches in store filters (no shipment exists at import). Previews don't count as prints; a document is outdated when its last print is older than the last line-item change (added / cancelled / quantity / split / merge — not address or method edits). See Documents → Print tracking
Customer, Shipping address, Shipping item, Discount itemThe matching order record

Operators

Equals · Not Equals · Greater Than · Greater Than or Equal · Less Than · Less Than or Equal · Contains · Does Not Contain · Starts With · Does Not Start With · Ends With · Is Empty · Is Not Empty.

  • Text comparisons are case-sensitive; numeric operators only make sense on price, quantity, totals and Location available quantity.
  • Not Equals and Does Not Contain are true when the value is missing (an item without a type "does not contain Livestock").
  • Is Empty on a list field (tags, printed documents) means "none at all".
  • And / Or are evaluated strictly left to right — there is no precedence; order the rows accordingly.
  • Metafield values are written key:value or namespace.key:value (only the first colon splits key from value); product and variant metafields are read.

Location available quantity

Product item → Location available quantity is the inventory available count of the line's variant at the fulfillment location Shopify assigned to that line — the same number the shipment detail page shows under the SKU (Location: Warehouse · 12 available). It is read from the synced inventory levels; when no per-location level exists it falls back to the variant's overall available stock. The value is a plain number and is compared numerically:

RuleUse it for
Location available quantity Less Than 1Oversold or last units sold — tag the shipment Backorder and hold it
Location available quantity Less Than or Equal 5Low stock at that location — tag Reorder
Location available quantity Is EmptyNo inventory data known (variant not synced or inventory not tracked)

Notes: the count is a snapshot at the moment the rule runs (on import the order's own units have normally already been deducted, so < 1 means the location is out of stock after this order). With split fulfillment (several locations on one line) the row is true when any of them satisfies it. It only exists on imported orders and shipments — checkout carts in Shipping Rates carry no inventory data, so the row never matches there. Pair it with a Type or Tags row on the same item to scope it to the products you care about.

Groups

Every condition belongs to a group — the same groups as Automation Rules; anything saved without one goes to the Default group, and a condition created inline from a rule joins that rule's group. Filter the list by group, click a group badge to show only that group, and use Manage groups to rename, re-default or delete groups (members move to the default group). One group name has a built-in meaning:

  • Printing — when this group contains at least one active condition, the print preview's Filter rows by condition dropdown and the document editor's Default condition list only its conditions. Keep your print-only conditions (Fish products, Supplies, Frozen lines) here. See Documents → Filter rows by condition.

Where conditions are used

FeatureBehaviour
Automation RulesCondition matches → actions run (tag, split, append)
Store Filters · Shipment filtersSkip importing an order / building a shipment
VisibilityWho sees which shipments
DocumentsProduct item rules hide non-matching rows; other rules leave out whole shipments. Saved as a document's Default condition or picked per print
Delivery Calendar rules, Collective partnersEnable / disable calendars, share orders

Editing a shared condition changes every feature that references it; the editor shows This condition is shared — changes here affect: …. A condition that is still in use cannot be deleted (still used by N rule(s) or filter(s)) — repoint or delete those first; a bulk delete skips such conditions and says so.

The list

Search, filter by All statuses / Active / Inactive and by group. Each row shows the title, a Per item badge for single-item matching, the group, and the first clauses under Matches. Managers get an inline Active switch and can select rows to Activate, Deactivate or Delete in bulk. An inactive condition is ignored in production but can be dry-run with Include inactive rules in the Tester.