Covers all questions related to inventory management, order fulfillment, and shipping.
Hi - I'm using the inventorySetOnHandQuantities mutation and want to check a couple of things:
- If some of the InventorySetQuantityInput lines are valid and some aren't, will those which are valid still be processed?
- Any tips in handling the userErrors for those which aren't?
e.g. for the following return, does the number 1 under field refer to the 2nd item being invalid?
Many thanks for your help 👍
{ "data": { "inventorySetOnHandQuantities": { "userErrors": [ { "code": "INVALID_INVENTORY_ITEM", "field": [ "input", "setQuantities", "1", "inventoryItemId" ], "message": "The specified inventory item could not be found." } ], "inventoryAdjustmentGroup": null } }, "extensions": { "cost": { "requestedQueryCost": 11, "actualQueryCost": 10, "throttleStatus": { "maximumAvailable": 1000.0, "currentlyAvailable": 990, "restoreRate": 50.0 } } } }
Solved! Go to the solution
This is an accepted solution.
I'd have to see the data you submitted to be sure, but I think it means the position of the element in the json array, so yeah, in this case it is probably the second inventoryitemid that doesnt exist. But I guess you would be in the best position to test that out.
Cheers,
Gary
This is an accepted solution.
I'd have to see the data you submitted to be sure, but I think it means the position of the element in the json array, so yeah, in this case it is probably the second inventoryitemid that doesnt exist. But I guess you would be in the best position to test that out.
Cheers,
Gary
Cheers @garyrgilbert for your reply - appreciated 👍
I agree that is seem to be the case, and would like technical confirmation for this and whether the batch processing is partially processed or completely thrown out as the processing needed is quite different!
Hi Loxena,
That should be easy to verify, just check the inventory adjustment history on the variant prior to where the error happened.
Cheers,
Gary