Skip to main content

productImportPreview

Requires permission products:import:preview.

The aggregated preview diff for the human approval gate.

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:

query ProductImportPreview($importId: String!) {
productImportPreview(importId: $importId) {
status
autoAppliedRules
createCount
errorRows
importId
mode
currencySummary {
currency
isBase
rowCount
}
}
}

Variables:

{
"importId": "string"
}

Response:

{
"data": {
"productImportPreview": {
"status": "COMMITTING",
"autoAppliedRules": [
"string"
],
"createCount": 0,
"errorRows": 0,
"importId": "string",
"mode": "CREATE_ONLY",
"currencySummary": [
{
"currency": "string",
"isBase": true,
"rowCount": 0
}
]
}
}
}
productImportPreview(
importId: String!
): ProductImportPreview!

Arguments​

productImportPreview.importId ● String! non-null scalar​

The ID of the import.

Type​

ProductImportPreview object​

A dry run of a product import: counts, samples, and the decisions made for the operator.