Skip to content

Product Attribute Conditions

Product Attribute conditions let you build rules based on the specific properties of products in the cart — their SKU, vendor, type, metafields, price, and more.

Combining conditions — Not every condition can be combined with every other in a single rule. Payflow filters the picker automatically. See Condition Sets for details.

Condition key: variantSku

Checks whether any line item in the cart has a variant SKU that matches your value.

Operators: Is one of, Is not any of, Text contains, Text does not contain, Is empty, Is not empty

Use cases:

  • Restrict COD for products with “HEAVY-” prefix in SKU
  • Show a special shipping option for items with a specific SKU pattern
  • Hide a payment method for clearance items (identified by SKU)

Condition key: productVendor

Checks whether any product in the cart is from a specific vendor/brand.

Operators: Is one of, Is not any of, Text contains, Text does not contain, Is empty, Is not empty

Use cases:

  • Apply different shipping rules for products from a specific supplier
  • Restrict payment methods for a specific brand in your multi-vendor store

Condition key: productType

Checks the Shopify product type field on any product in the cart (set in the product editor under “Organization”).

Operators: Is one of, Is not any of

Use cases:

  • Hide COD for “Digital” product types
  • Restrict shipping options for “Furniture” products
  • Apply different rules for “Apparel” vs “Electronics”

Condition key: isGiftCard

Returns true if any item in the cart is a Shopify gift card.

Operators: Is true, Is false

Use cases:

  • Restrict payment methods when a gift card product is in the cart
  • Hide COD for orders containing gift cards (since they require a different fulfillment flow)

Condition key: requiresShipping

Returns true if all items in the cart require physical shipping (i.e. no digital/download-only items).

Operators: Is true, Is false

Use cases:

  • Show local delivery options only when physical items are in the cart
  • Hide shipping methods entirely for fully digital orders

Condition key: lineItemPrice

Checks the unit price of any line item in the cart.

Operators: At least (≥), At most (≤), Is (==), Is not (!=)

Use cases:

  • Hide COD for carts containing items over a certain price
  • Show a special payment method for high-ticket items

Condition key: lineItemCompareAtPrice

Checks the compare-at (original / “was”) price of any line item. Returns empty if no compare-at price is set.

Operators: At least (≥), At most (≤), Is (==), Is not (!=), Is empty, Is not empty

Use cases:

  • Apply different rules for sale items (where compare-at price is set)
  • Hide a payment method when any cart item is discounted

Condition key: cartAttribute

Checks the value of a Shopify cart attribute by key. Cart attributes are custom key-value pairs set programmatically by your storefront (via Liquid or the Cart API).

Operators: Is one of, Is not any of, Text contains, Text does not contain, Is empty, Is not empty

Use cases:

  • Apply rules based on a custom B2B flag set by your storefront
  • Trigger logic based on an upsell app that sets a cart attribute
  • Check for a referral code or promo attribute

Condition key: productMetafield

Checks the value of a metafield on any product in the cart. You specify the metafield namespace and key.

Operators: Is one of, Is not any of, Text contains, Text does not contain, Is empty, Is not empty

Use cases:

  • Restrict payment methods based on a custom “requires_age_verification” metafield
  • Apply different shipping rules based on a “hazardous_material” product metafield
  • Check a supplier-set “min_order_value” metafield

Condition key: variantMetafield

Checks the value of a metafield on any variant in the cart. You specify the metafield namespace and key.

Operators: Is one of, Is not any of, Text contains, Text does not contain, Is empty, Is not empty

Use cases:

  • Apply rules based on variant-level custom data
  • Check for a “shipping_class” metafield on variants for custom rate logic

Condition key: lineItemProperty

Checks the value of a custom line item property on any cart line. Line item properties are key-value pairs attached to individual items in the cart (often set by product forms, subscription apps, or custom storefront logic).

Operators: Is one of, Is not any of, Text contains, Text does not contain, Is empty, Is not empty

Use cases:

  • Apply rules based on a custom property set by a subscription app (e.g. _subscription_type)
  • Restrict payment methods when a line item carries a specific custom value
  • Check for personalisation data (e.g. an engraving or gift message property)