On this page
Why this happens
Segment query syntax changed in API 2026-10. Apps that store query strings or generate segment functions may continue sending the old syntax even if the Shopify admin segment builder has changed.
How to fix it
- Read existing segments and preserve their IDs, names, and query strings before making changes.
- Find function expressions ending in = true or = false and translate them to MATCHES or NOT MATCHES.
- Move parameter comparisons inside the function, preserving operators and intended audience criteria.
- Replace deprecated named relative dates such as 90_days_ago with the supported relative offset syntax, such as -90d.
- Update one segment at a time; read back its saved query and compare membership against known customer fixtures.
Production example
Old: products_purchased(quantity: 5) = true. New: products_purchased MATCHES (quantity = 5). Old: shopify_email.opened() = true. New: shopify_email.opened MATCHES (). These are segment function examples, not replacements for every ordinary equality condition.
How to test this
- Export the original query text and record the expected business rule.
- Translate a positive and a negative function condition.
- Validate both expressions against API 2026-10, checking GraphQL and mutation errors.
- Compare known customer membership and counts, including date boundaries.
- Verify scheduled integrations use the revised expression before activating campaigns or discounts.

