Bulk Reconcile Items
Beta/v1/catalog/items/actions/bulk-reconcileIdempotent with Idempotency-Key header. Learn more
Reconciles inventory for multiple items by SKU in one call, the bulk equivalent of counting stock and correcting the books.
reconcile_type controls whether each quantity is added to the item's current quantity (addition) or replaces it (force). The figure a force measures against is what is on hand net of demand nothing has covered, the same basis the single-item endpoint uses. Each quantity is converted from its row's unit into the item's base unit, and previous_quantity and new_quantity are reported in that base unit. A SKU listed twice applies each row in turn.
The response reports each row as reconciled, skipped (unknown SKU), or errored (unknown unit, or a unit outside the item's unit group), so a problem with one row does not fail the rest. Rows are written in batches of 50, each in its own transaction; a batch that cannot be written is rolled back whole and every row in it is reported in errors, while the batches before and after it still apply. Resubmit only the errored rows — in addition mode, resubmitting the whole request would apply the reconciled rows twice.
At most 1,000 rows per request, and a request body of at most 8 MB. Each correction is written to the item's inventory audit trail as a user correction, attributed to the caller.
dataarray of objectItems to reconcile, at most 1,000 rows per request. Split a larger count across requests.
skustringSKU of the item to reconcile.
Items whose SKU does not match an existing item are reported in the response's skipped_items rather than failing the request.
unitstringAbbreviation of the unit quantity is counted in (e.g. kg), matched without regard to case.
It must be the item's base unit or another unit in its category's unit group; the quantity is converted from it into the base unit before it is applied, so 2 dz against an item stocked in eaches reconciles 24. A row whose abbreviation matches no unit, or a unit outside the item's unit group, is reported in the response's errors and writes nothing.
quantitystring (decimal)Quantity to apply, interpreted according to the request's reconcile_type.
A decimal string rather than a number: a quantity that has been through a binary float is not the quantity you sent.
reconcile_typestringenumValues:additionforceHow each item's quantity is applied to its current quantity.
addition: adds the quantity to the item's current quantity.force: sets the item's current quantity to exactly the given quantity.
objectstringenumValues:bulk_reconcile_items_responseResource type identifier.
Items whose inventory was successfully reconciled.
objectstringenumValues:listResource type identifier.
page_infoobjectPagination metadata.
next_page_urlstringnullableRelative URL that fetches the next page of results.
previous_page_urlstringnullableRelative URL that fetches the previous page of results.
has_next_pagebooleanWhether more results exist after this page.
has_prev_pagebooleanWhether results exist before this page.
dataarray of reconciled_item_resultResources in this page.
objectstringenumValues:reconciled_item_resultResource type identifier.
itementitynullableThe item that was reconciled, named by id and SKU.
idstringUnique identifier for the entity.
objectstringenumValues:entityResource type identifier.
typestringenumValues:accountactorentityThe resource kind that this entity references, as an object-type value (e.g. user, account).
Unlike object — which is always entity — this names the underlying resource the id points to.
namestringnullableHuman-readable display name for the entity (e.g. a user's full name, a sales order number).
handlestringnullableSecondary human-readable identifier (e.g. email address, username, redacted API key value).
previous_quantitycomputed_quantitynullableQuantity before the reconciliation.
objectstringenumValues:computed_quantityResource type identifier.
valuestring (decimal)Raw decimal value, as a string to preserve precision.
This is the unformatted machine value; see display_value for the human-readable rendering.
display_valuestringFormatted value with unit abbreviation (e.g. "1,200 pr").
Unit of measure for this value.
Resolved in full rather than expandable: a computed quantity is not a stored row a caller could fetch on its own, so the unit it is counted in travels with it. Null only where the figure was derived without a unit record behind it.
idstringUnit ID.
objectstringenumValues:unitResource type identifier.
namestringDisplay name of the unit (e.g. "Gram", "Kilogram").
abbreviationstringShort abbreviation for the unit (e.g. "g", "kg").
typestringenumValues:currencyquantitytimeThe dimension this unit measures, such as mass, volume, or currency.
A unit can only be converted to another unit of the same dimension. The quantity dimension is for discrete countable items rather than a physical measure.
ratio_numeratorstring (decimal)Numerator of the ratio that converts a quantity in this unit into the dimension's base unit.
A quantity is converted with value × (ratio_numerator / ratio_denominator) + (offset_numerator / offset_denominator), so a kilogram in a gram-based dimension has a numerator of 1000 and a denominator of 1.
ratio_denominatorstring (decimal)Denominator of the ratio that converts a quantity in this unit into the dimension's base unit.
Cannot be zero.
offset_numeratorstring (decimal)Numerator of the conversion offset, applied after the ratio for scales that do not share a zero point, such as temperature.
Zero for units that convert by ratio alone.
offset_denominatorstring (decimal)Denominator of the conversion offset applied after the ratio.
Never zero; a unit with no offset carries a numerator of 0 over a denominator of 1.
is_base_unitbooleanWhether this is the base unit for its dimension.
Every other unit's conversion ratio is expressed relative to the base unit. Base units are platform-defined; units created through the API are never base units.
ownerownernullableOwner of this resource.
objectstringenumValues:ownerResource type identifier.
typestringenumValues:systemaccountWhere this resource came from.
system: a platform-provided default shared across all accounts; not editable.account: created and owned by a specific account; theaccountfield identifies which.
accountaccountnullableThe account that owns this resource.
Present only when type is account; system-owned resources have no owning account.
created_atstring (date-time)When this unit was created.
updated_atstring (date-time)When this unit was last updated.
new_quantitycomputed_quantitynullableQuantity after the reconciliation.
objectstringenumValues:computed_quantityResource type identifier.
valuestring (decimal)Raw decimal value, as a string to preserve precision.
This is the unformatted machine value; see display_value for the human-readable rendering.
display_valuestringFormatted value with unit abbreviation (e.g. "1,200 pr").
Unit of measure for this value.
Resolved in full rather than expandable: a computed quantity is not a stored row a caller could fetch on its own, so the unit it is counted in travels with it. Null only where the figure was derived without a unit record behind it.
idstringUnit ID.
objectstringenumValues:unitResource type identifier.
namestringDisplay name of the unit (e.g. "Gram", "Kilogram").
abbreviationstringShort abbreviation for the unit (e.g. "g", "kg").
typestringenumValues:currencyquantitytimeThe dimension this unit measures, such as mass, volume, or currency.
A unit can only be converted to another unit of the same dimension. The quantity dimension is for discrete countable items rather than a physical measure.
ratio_numeratorstring (decimal)Numerator of the ratio that converts a quantity in this unit into the dimension's base unit.
A quantity is converted with value × (ratio_numerator / ratio_denominator) + (offset_numerator / offset_denominator), so a kilogram in a gram-based dimension has a numerator of 1000 and a denominator of 1.
ratio_denominatorstring (decimal)Denominator of the ratio that converts a quantity in this unit into the dimension's base unit.
Cannot be zero.
offset_numeratorstring (decimal)Numerator of the conversion offset, applied after the ratio for scales that do not share a zero point, such as temperature.
Zero for units that convert by ratio alone.
offset_denominatorstring (decimal)Denominator of the conversion offset applied after the ratio.
Never zero; a unit with no offset carries a numerator of 0 over a denominator of 1.
is_base_unitbooleanWhether this is the base unit for its dimension.
Every other unit's conversion ratio is expressed relative to the base unit. Base units are platform-defined; units created through the API are never base units.
ownerownernullableOwner of this resource.
objectstringenumValues:ownerResource type identifier.
typestringenumValues:systemaccountWhere this resource came from.
system: a platform-provided default shared across all accounts; not editable.account: created and owned by a specific account; theaccountfield identifies which.
accountaccountnullableThe account that owns this resource.
Present only when type is account; system-owned resources have no owning account.
created_atstring (date-time)When this unit was created.
updated_atstring (date-time)When this unit was last updated.
Items that were skipped, e.g. because no item with the given SKU exists.
objectstringenumValues:listResource type identifier.
page_infoobjectPagination metadata.
next_page_urlstringnullableRelative URL that fetches the next page of results.
previous_page_urlstringnullableRelative URL that fetches the previous page of results.
has_next_pagebooleanWhether more results exist after this page.
has_prev_pagebooleanWhether results exist before this page.
dataarray of skipped_item_resultResources in this page.
objectstringenumValues:skipped_item_resultResource type identifier.
skustringItem SKU, as submitted.
reasonstringHuman-readable reason the item was skipped.
Items that failed to reconcile, e.g. because the given unit does not exist or the inventory write failed.
objectstringenumValues:listResource type identifier.
page_infoobjectPagination metadata.
next_page_urlstringnullableRelative URL that fetches the next page of results.
previous_page_urlstringnullableRelative URL that fetches the previous page of results.
has_next_pagebooleanWhether more results exist after this page.
has_prev_pagebooleanWhether results exist before this page.
dataarray of reconcile_error_resultResources in this page.
objectstringenumValues:reconcile_error_resultResource type identifier.
itementitynullableThe item the row named, named by id and SKU.
Always set: a row whose SKU matched no item is reported under skipped_items rather than here.
idstringUnique identifier for the entity.
objectstringenumValues:entityResource type identifier.
typestringenumValues:accountactorentityThe resource kind that this entity references, as an object-type value (e.g. user, account).
Unlike object — which is always entity — this names the underlying resource the id points to.
namestringnullableHuman-readable display name for the entity (e.g. a user's full name, a sales order number).
handlestringnullableSecondary human-readable identifier (e.g. email address, username, redacted API key value).
errorstringError message.
Responses
Successful response for Bulk Reconcile Items