collection Remove Products
Requires access scope. Also: The user must have a permission to remove products from a collection.
Removes multiple products from a collection in a single operation. This mutation can process large product sets (up to 250 products) and may take significant time to complete for collections with many products.
For example, when ending a seasonal promotion, merchants can remove all sale items from a "Summer Clearance" collection at once rather than editing each product individually.
Use to:
- Bulk-remove products from collections efficiently
- Clean up collection membership during catalog updates
- Implement automated collection management workflows
The operation processes asynchronously to avoid timeouts and performance issues, especially for large product sets.
Learn more about collection management.
Arguments
- •ID!required
The ID of the collection to remove products from. The ID must reference an existing manual collection.
- Anchor to productIdsproduct•[ID!]!
Ids required The IDs of products to remove from the collection. The mutation doesn't validate that the products belong to the collection or whether the products exist.
- •Job
The asynchronous job removing the products.
- Anchor to userErrorsuser•[User
Errors Error!]! non-null The list of errors that occurred from executing the mutation.