Skip to main content

rollbackProductImport

Requires permission products:import:rollback.

Reference-guarded rollback of a COMPLETED import — unreferenced variants it created are deleted, referenced or stocked ones deactivated; updates are not reverted (notRevertedCount).

Errors: a failed call returns a GraphQL errors entry, not a field on the result, and data may be null or partial. Read the entry's extensions.code and message; every shape and code is in the Error reference.

Example:

mutation RollbackProductImport($importId: String!) {
rollbackProductImport(importId: $importId) {
deactivatedVariants
deletedProducts
deletedVariants
notRevertedCount
}
}

Variables:

{
"importId": "string"
}

Response:

{
"data": {
"rollbackProductImport": {
"deactivatedVariants": 0,
"deletedProducts": 0,
"deletedVariants": 0,
"notRevertedCount": 0
}
}
}
rollbackProductImport(
importId: String!
): ProductImportRollbackResult!

Arguments​

rollbackProductImport.importId ● String! non-null scalar​

The ID of the import.

Type​

ProductImportRollbackResult object​

What a rollback of an import undid.