ACSD-61805: Fixes stock issue on storefront after backorder status update via REST API
- Topics:
- REST
- Catalog Management
- Inventory
CREATED FOR:
- Experienced
- Admin
- Developer
The ACSD-61805 patch fixes the issue where products remain out of stock on the storefront after updating the backorder status via REST API. This patch is available when the Quality Patches Tool (QPT) 1.1.56 is installed. The patch ID is ACSD-61805. Please note that the issue is scheduled to be fixed in Adobe Commerce 2.4.8.
Affected products and versions
The patch is created for Adobe Commerce version:
- Adobe Commerce (all deployment methods) 2.4.4
Compatible with Adobe Commerce versions:
- Adobe Commerce (all deployment methods) 2.4.4 - 2.4.7-p3
magento/quality-patches
package to the latest version and check the compatibility on the Quality Patches Tool: Search for patches page. Use the patch ID as a search keyword to locate the patch.Issue
Products remain out of stock on the storefront after updating the backorder status via REST API.
Steps to reproduce:
-
Install a clean instance with sample data.
-
Create a new inventory source.
-
Create a new inventory stock and assign the new source to it.
-
Assign the new source to product 24-MB01.
-
Set Source Item Status to
In Stock
for both product sources. -
Set the quantity (QTY) to 0 for both product quantities.
-
Save the product.
-
Fetch the admin token from this endpoint URL:
/rest/default/V1/integration/admin/token
{ "username":"admin", "password":"password" }
-
Update the product using the endpoint:
/rest/default/V1/products
{ "product":{ "sku": "24-MB01", "extension_attributes": { "stock_item": { "stock_id": "1", "is_in_stock": "0", "use_config_backorders": "false", "backorders": "0" } } } }
-
Run the cron jobs twice (once to create schedules and once to run the schedule):
bin/magento cron:run
-
Go to the frontend and check the product.
Expected results:
The product should be In Stock.
Actual results:
The product is Out of Stock.
Apply the patch
To apply individual patches, use the following links depending on your deployment method:
- Adobe Commerce or Magento Open Source on-premises: Quality Patches Tool > Usage in the Quality Patches Tool guide.
- Adobe Commerce on cloud infrastructure: Upgrades and Patches > Apply Patches in the Commerce on Cloud Infrastructure guide.
Related reading
To learn more about Quality Patches Tool, refer to:
- Quality Patches Tool: A self-service tool for quality patches in the Tools guide.