PUT /V1/products/:productSku/stockItems/:itemId
PUT /V1/products/:productSku/stockItems/:itemId is a Magento 2 REST endpoint in the CatalogInventory module. Requires an admin Bearer token with ACL Magento_Catalog::catalog_inventory.
Last verified: against Magento 2.4.9.
Returns
int
Service contract
Magento\CatalogInventory\Api\StockRegistryInterface::updateStockItemBySku
Authorization
Admin Bearer token with ACL:
- Magento_Catalog::catalog_inventory
Path parameters
Body parameters
Example request
Auto-generated from the service contract — paste-ready against your store's /rest/default base. Replace the host, store code, ACL token, and any required values before running.
Headers
Path
/V1/products/{productSku}/stockItems/:itemIdBody
{
"stockItem": {
"backorders": 0,
"enable_qty_increments": false,
"extension_attributes": {},
"is_decimal_divided": false,
"is_in_stock": {},
"is_qty_decimal": false,
"item_id": 0,
"low_stock_date": "",
"manage_stock": false,
"max_sale_qty": 0,
"min_qty": 0,
"min_sale_qty": 0,
"notify_stock_qty": 0,
"product_id": 0,
"qty": 0,
"qty_increments": {},
"show_default_notification_message": false,
"stock_id": 0,
"stock_status_changed_auto": 0,
"use_config_backorders": false,
"use_config_enable_qty_inc": false,
"use_config_manage_stock": false,
"use_config_max_sale_qty": false,
"use_config_min_qty": false,
"use_config_min_sale_qty": 0,
"use_config_notify_stock_qty": false,
"use_config_qty_increments": false
}
}Related in CatalogInventory
Other endpoints shipped by the same module.
/V1/stockItems/:productSku
CatalogInventory · Magento\CatalogInventory\Api\StockRegistryInterface::getStockItemBySku
/V1/stockItems/lowStock/
Retrieves a list of SKU's with low inventory qty
CatalogInventory · Magento\CatalogInventory\Api\StockRegistryInterface::getLowStockItems
/V1/stockStatuses/:productSku
CatalogInventory · Magento\CatalogInventory\Api\StockRegistryInterface::getStockStatusBySku
Every Magento dev tool, in one hosted workspace.
Free to sign up. Nothing to install. Drafts, audits, and projects saved across every tool.