ACP2E-5242: GraphQL uses the store ID as the website ID during add-to-cart requests
The ACP2E-5242 patch fixes the issue where checking product availability while adding items to the cart displays an error indicating that the website cannot be found. This patch is available when the Quality Patches Tool (QPT) 1.1.84 is installed. The patch ID is ACP2E-5242. Please note that this issue is scheduled to be fixed in Adobe Commerce 2.4.10.
Affected products and versions
The patch is created for Adobe Commerce version:
- Adobe Commerce (all deployment methods) 2.4.9
Compatible with Adobe Commerce versions:
- Adobe Commerce (all deployment methods) 2.4.9
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
Checking product availability while adding items to the cart displays an error indicating that the website cannot be found.
Steps to reproduce:
- Log in to the Admin panel.
- Go to Admin > Stores > Settings > All Stores, click Create Store View.
- Create a second store view named “store_2”, for example.
- Create an empty guest cart with a GraphQL request using the “Store: store2” HTTP header.
- Record the returned cart ID.
- Add a simple product to the cart with a GraphQL request using the “Store: store2” HTTP header, the product SKU, and the cart ID.
Expected results:
The product is successfully added to the cart via the GraphQL request.
Actual results:
The GraphQL request fails and writes the message “The website with id … that was requested wasn’t found. Verify the website and try again.” to var/log/exception.log.
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