Product Set Operation
Requires access scope.
An entity that represents details of an asynchronous ProductSet mutation.
By querying this entity with the productOperation query using the ID that was returned when the product was created or updated, this can be used to check the status of an operation.
The status
field indicates whether the operation is ,
, or
.
The product
field provides the details of the created or updated product.
The field provides mutation errors that occurred during the operation.
Anchor to FieldsFields
- •ID!non-null
A globally-unique ID.
- Anchor to productproduct•Product
The product on which the operation is being performed.
- Anchor to statusstatus•Product
Operation Status! non-null The status of this operation.
- Anchor to userErrorsuser•[Product
Errors Set User Error!]! non-null Returns mutation errors occurred during background mutation processing.
Anchor to MutationsMutations
- •mutation
Performs multiple operations to create or update products in a single request.
Use the
mutation to sync information from an external data source into Shopify, manage large product catalogs, and perform batch updates. The mutation is helpful for bulk product management, including price adjustments, inventory updates, and product lifecycle management.
The behavior of
depends on the type of field it's modifying:
For list fields: Creates new entries, updates existing entries, and deletes existing entries that aren't included in the mutation's input. Common examples of list fields include
collections
,metafields
, andvariants
.For all other field types: Updates only the included fields. Any omitted fields will remain unchanged.
NoteBy default, stores have a limit of 100 product variants for each product. You can create a development store and enable the Extended Variants developer preview to create or update a maximum of 2,048 product variants in a single operation.
You can run
in one of the following modes:
- Synchronously: Returns the updated product in the response.
- Asynchronously: Returns a
object. Use the
query to check the status of the operation and retrieve details of the updated product and its product variants.
If you need to only manage product variants, then use one of the following mutations:
If you need to only manage product options, then use one of the following mutations:
Learn more about syncing product data from an external source.
- Anchor to identifieridentifier•Product
Set Identifiers Specifies the identifier that will be used to lookup the resource.
- Anchor to inputinput•Product
Set Input! required The properties of the newly created or updated product.
- Anchor to productPreferencesproduct•Product
Preferences Preferences Input The default preferences in the product create form.
- Anchor to synchronoussynchronous•BooleanDefault:true
Whether the mutation should be run synchronously or asynchronously.
If
true
, the mutation will return the updatedproduct
.If
false
, the mutation will return a.
Defaults to
true
.Setting
synchronous: false
may be desirable depending on the input complexity/size, and should be used if you are experiencing timeouts.Note: When run in the context of a bulk operation, the mutation will always run synchronously and this argument will be ignored.
Arguments
- Anchor to productproduct•Product
The product object.
- Anchor to productSetOperationproduct•Product
Set Operation Set Operation The product set operation, returned when run in asynchronous mode.
- Anchor to userErrorsuser•[Product
Errors Set User Error!]! non-null The list of errors that occurred from executing the mutation.
Fields