Selling Plan Group
Requires access scope.
A selling method that defines how products can be sold through purchase options like subscriptions, pre-orders, or try-before-you-buy. Groups one or more objects that share the same selling method and options.
The group provides buyer-facing labels and merchant-facing descriptions for the selling method. Associates Product and objects with selling plan groups to offer them through these purchase options.
Selling plan groups and their associated records are automatically deleted 48 hours after a merchant uninstalls the App that created them. Back up these records if you need to restore them later.
Anchor to FieldsFields
- Anchor to appIdapp•String
Id The ID for app, exposed in Liquid and product JSON.
- Anchor to appliesToProductapplies•Boolean!
To Product non-null Whether the given product is directly associated to the selling plan group.
- Anchor to productIdproduct•ID!
Id required The ID of the product.
Arguments
- Anchor to appliesToProductVariantapplies•Boolean!
To Product Variant non-null Whether the given product variant is directly associated to the selling plan group.
- Anchor to productVariantIdproduct•ID!
Variant Id required The ID of the product.
Arguments
- Anchor to appliesToProductVariantsapplies•Boolean!
To Product Variants non-null Whether any of the product variants of the given product are associated to the selling plan group.
- Anchor to productIdproduct•ID!
Id required The ID of the product.
Arguments
- Anchor to createdAtcreated•Date
At Time! non-null The date and time when the selling plan group was created.
- Anchor to descriptiondescription•String
The merchant-facing description of the selling plan group.
- •ID!non-null
A globally-unique ID.
- Anchor to merchantCodemerchant•String!
Code non-null The merchant-facing label of the selling plan group.
- Anchor to namename•String!non-null
The buyer-facing label of the selling plan group.
- Anchor to optionsoptions•[String!]!non-null
The values of all options available on the selling plan group. Selling plans are grouped together in Liquid when they're created by the same app, and have the same
andvalues.- Anchor to positionposition•Int
The relative position of the selling plan group for display.
- Anchor to productsproducts•Product
Connection! non-null Products associated to the selling plan group.
- Anchor to firstfirst•Int
The first
nelements from the paginated list.- Anchor to afterafter•String
The elements that come after the specified cursor.
- Anchor to lastlast•Int
The last
nelements from the paginated list.- Anchor to beforebefore•String
The elements that come before the specified cursor.
- Anchor to reversereverse•BooleanDefault:false
Reverse the order of the underlying list.
Arguments
- Anchor to productsCountproducts•Count
Count A count of products associated to the selling plan group.
- Anchor to productVariantsproduct•Product
Variants Variant Connection! non-null Product variants associated to the selling plan group.
- Anchor to productIdproduct•ID
Id Filters the product variants by a product ID.
- Anchor to firstfirst•Int
The first
nelements from the paginated list.- Anchor to afterafter•String
The elements that come after the specified cursor.
- Anchor to lastlast•Int
The last
nelements from the paginated list.- Anchor to beforebefore•String
The elements that come before the specified cursor.
- Anchor to reversereverse•BooleanDefault:false
Reverse the order of the underlying list.
Arguments
- Anchor to productVariantsCountproduct•Count
Variants Count A count of product variants associated to the selling plan group.
- Anchor to productIdproduct•ID
Id The ID of the product to scope the count to.
Arguments
- Anchor to sellingPlansselling•Selling
Plans Plan Connection! non-null Selling plans associated to the selling plan group.
- Anchor to firstfirst•Int
The first
nelements from the paginated list.- Anchor to afterafter•String
The elements that come after the specified cursor.
- Anchor to lastlast•Int
The last
nelements from the paginated list.- Anchor to beforebefore•String
The elements that come before the specified cursor.
- Anchor to reversereverse•BooleanDefault:false
Reverse the order of the underlying list.
Arguments
- Anchor to summarysummary•String
A summary of the policies associated to the selling plan group.
- Anchor to translationstranslations•[Translation!]!non-null
The published translations associated with the resource.
- Anchor to localelocale•String!required
Filters translations locale.
- Anchor to marketIdmarket•ID
Id Filters translations by market ID. Use this argument to retrieve content specific to a market.
Arguments
Anchor to QueriesQueries
- •query
Returns a
resource by ID.- •ID!required
The ID of the
to return.
Arguments
- •ID!
- •query
Retrieves a paginated list of
objects that belong to the app making the API call. Selling plan groups are selling methods like subscriptions, preorders, or other purchase options that merchants offer to customers.Each group has one or more
objects that define specific billing and delivery schedules, pricing adjustments, and policies. Use thequeryargument to search by name or filter results by other criteria.Learn more about building selling plans.
- Anchor to firstfirst•Int
The first
nelements from the paginated list.- Anchor to afterafter•String
The elements that come after the specified cursor.
- Anchor to lastlast•Int
The last
nelements from the paginated list.- Anchor to beforebefore•String
The elements that come before the specified cursor.
- Anchor to reversereverse•BooleanDefault:false
Reverse the order of the underlying list.
- Anchor to sortKeysort•Selling
Key Plan Group Sort Keys Default:ID Sort the underlying list using a key. If your query is slow or returns an error, then try specifying a sort key that matches the field used in the search.
- Anchor to queryquery•String
A filter made up of terms, connectives, modifiers, and comparators. You can apply one or more filters to a query. Learn more about Shopify API search syntax.
- Anchor to default•string
Filter by a case-insensitive search of multiple fields in a document.
query=Bob Normanquery=title:green hoodie- Anchor to app_id•id
CURRENTDefaultALL* (numeric app ID)- Anchor to category•string
A comma-separated list of categories.
SUBSCRIPTIONPRE_ORDERTRY_BEFORE_YOU_BUYOTHER- Anchor to created_at•time
- Anchor to delivery_frequency•string
- Anchor to name•string
- Anchor to percentage_off•float
Example:
Valid values:
Valid values:
Arguments
Anchor to MutationsMutations
- •mutation
Adds multiple products to a selling plan group.
- •ID!required
The ID of the selling plan group.
- Anchor to productIdsproduct•[ID!]!
Ids required The IDs of the products to add.
Arguments
- •ID!
- •mutation
Adds multiple product variants to a selling plan group.
- •ID!required
The ID of the selling plan group.
- Anchor to productVariantIdsproduct•[ID!]!
Variant Ids required The IDs of the product variants to add.
Arguments
- •ID!
- •mutation
Creates a selling plan group that defines how products can be sold and purchased. A selling plan group represents a selling method such as "Subscribe and save", "Pre-order", or "Try before you buy" and contains one or more selling plans with specific billing, delivery, and pricing policies.
Use the
resourcesargument to associate products or product variants with the group during creation. You can also add products later usingor.Learn more about building selling plan groups or explore examples of creating TBYB and other selling plan groups.
- Anchor to inputinput•Selling
Plan Group Input! required The properties of the new Selling Plan Group.
- Anchor to resourcesresources•Selling
Plan Group Resource Input The resources this Selling Plan Group should be applied to.
Arguments
- •mutation
Update a Selling Plan Group.
- •ID!required
The Selling Plan Group to update.
- Anchor to inputinput•Selling
Plan Group Input! required The properties of the Selling Plan Group to update.
Arguments
- •ID!