Delete inventory
Remove an inventory record for a product.
Mutation
mutation DeleteInventory($id: Int!) {
inventoryDelete(id: $id) {
messages
}
}
Variables
{
"id": 98422
}
Response
{
"data": {
"inventoryDelete": {
"messages": []
}
}
}
How it works
Pass the inventory record id (not the product ID) to delete a specific stock entry. An empty messages array indicates success. Deleting an inventory record does not affect other inventory records for the same product in different warehouses.
See also
- Create inventory — add a stock record
- Fetch product stock across warehouses — query inventory from the storefront