Skip to main content

productDeleteBulk

Remove several products from the catalogue in one request.

Each id is deleted exactly as productDelete would delete it — cross- and up-sell relationships are detached automatically, and every deleted product emits its own event — so this is a batch of single deletes, not a different kind of delete. Each therefore costs its own transaction; a very large batch is slow rather than refused.

An id that cannot be deleted does not fail the request. It lands in failedIds with an entry in failures saying why, and the rest of the batch is deleted regardless. Repeated ids are collapsed, so an id sent twice gets one verdict.

Read failures[].reason before offering a retry: only PRODUCT_DELETE_FAILED describes something a repeat could fix.

Possible errors:

  • INVALID_INPUT: The list of ids was empty.

AUTH: Role=[product.OWNER]

productDeleteBulk(
productIds: [Int!]!
): ProductBulkDeleteResponse!

Arguments

productDeleteBulk.productIds ● [Int!]! non-null scalar

Numeric identifiers of the products to delete. Recommended maximum: 100 per request — advisory, not enforced.

Type

ProductBulkDeleteResponse object