ACSD-65195: GraphQL createCompany mutation returns an error for a country without a required region
The ACSD-65195 patch fixes the issue where the GraphQL createCompany mutation throws an error for countries that don’t require a region. This patch is available when the Quality Patches Tool (QPT) 1.1.63 is installed. The patch ID is ACSD-65195. Please note that this issue is scheduled to be fixed in Adobe Commerce 2.4.9.
Affected products and versions
The patch is created for Adobe Commerce version:
- Adobe Commerce (all deployment methods) 2.4.7-p3
Compatible with Adobe Commerce versions:
- Adobe Commerce (all deployment methods) 2.4.4 - 2.4.6-p9, 2.4.7 - 2.4.7-p4
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
The GraphQL createCompany mutation returns an error when a region is specified for a country that doesn’t require one.
Steps to reproduce:
- Enable B2B Companies.
- Send the
createCompanyGraphQL mutation with a specified region field for a country that doesn’t require one. For example: country_id: AE and region: Dubai. - Check the GraphQL response.
Expected results:
The company should be created successfully without returning an error when a region is specified for a country that does not require one.
Actual results:
The company is not created, and the following error is returned:Error: Invalid value of "Dubai" provided for the region field.
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.