Migrate to customer segments
Partners who have apps that use customer saved searches can update their apps to use customer segments.
On April 4th, 2022, we introduced the Segmentation API, which you can use to filter out specific customers for marketing, analytics, and reporting purposes. If your app uses customer saved searches, then you need to migrate your app to support customer segments.
The Segmentation API deprecates customer saved searches and elements from the Discounts API. These changes affect all merchants because all shops have built-in, default saved searches.
Affected APIsAnchor link to section titled "Affected APIs"
Your app is affected by the deprecation of saved searches if it uses the GraphQL elements, REST API elements, and data tables listed on this page.
GraphQL Admin API saved searches, price rules, and discountsAnchor link to section titled "GraphQL Admin API saved searches, price rules, and discounts"
This section describes deprecated GraphQL API elements and their replacements, changes to existing GraphQL API elements, and recommended mutations for creating and modifying discount codes.
Deprecated GraphQL API elementsAnchor link to section titled "Deprecated GraphQL API elements"
This section describes replacements for deprecated GraphQL API elements.
Deprecated TypesAnchor link to section titled "Deprecated Types"
The following types were removed from the GraphQL Admin API:
Use the following elements instead:
Deprecated FieldsAnchor link to section titled "Deprecated Fields"
The following fields were removed from the GraphQL Admin API:
savedSearchesfield from the
savedSearchesIdsfield from the
Use the following fields instead:
segmentsfield from the
segmentIdsfield from the
Recommended mutations for creating and modifying discount codesAnchor link to section titled "Recommended mutations for creating and modifying discount codes"
You can use the Discounts API to create and update discount codes for all customers or for specific customers. You can specify which customers can use which discount codes by using the Segmentation API to filter out customers based on specific attributes.
The following mutations enable you to create or modify discount codes:
REST Admin API saved searches and price rulesAnchor link to section titled "REST Admin API saved searches and price rules"
customer_segment_prerequisite_ids from the
PriceRule resource instead.
The following table lists the resources that are affected by the REST Admin API saved searches deprecation: