This notice is intended for members who are a SuiteCommerce or SuiteCommerce Advanced customer who uses the Item Search API. To improve the user experience and SEO for items that are unavailable (such as those that are out of stock or hidden), some changes to the Item Search API are being made.
While these changes will improve your site’s user experience and SEO, they may also affect its function if you have customizations that call this API.
What is Changing
In some situations, the Item Search API returns HTTP 200 OK status codes that are better suited to 404 Page Not Found status codes. This could create inconsistencies in shopper expectations and web crawler behavior, such as search engines incorrectly tagging an item as available when it is not, and developers having to create workarounds in their customizations.
Starting on May 30, 2022, the HTTP status codes will change from 200 OK to 404 Not Found for items that are unavailable due to one or both of the following configurations:
- Item is made unavailable for display in the web store by clearing the Display in Web Site box on the item record.
- Item is made unavailable for display in the web store by setting the Out of Stock Behavior option to Remove item when out-of-stock.
Your web store may be affected if you have customizations that call the Item Search API to retrieve items by the Item ID or the Item URL input parameters.
Recommended Actions
What should I do if I do NOT have any customizations in my site that call the Item Search API by Item ID or URL?
You do not need to do anything. The change will be a general improvement to your web store’s user experience and SEO.
What should I do if I DO have customizations in my site that call the Item Search API by Item ID or URL?
You or your developers will need to test your customizations in different scenarios to ensure that they continue to function normally when the above configurations are being used.
For example, you may have customizations that assume the Item Search API will always return a 200 OK status code and have not implemented handlers for cases where a 404 Not Found status code is returned. Customizations that do not properly handle these cases may malfunction, potentially causing problems to not only the customization but normal shopping functions.
What will happen when a single request for multiple Item IDs is sent and some items are available, and others are unavailable?
A 404 Not Found status code is only returned if all the items are unavailable. If at least one of the items is available, a 200 OK status code is returned. You or your developers will need to test your customizations in different scenarios to ensure that they continue to function normally.
NetSuite’s Customer Support is available to answer questions, and our Advanced Customer Support (ACS) and Professional Services (PS) teams can provide technical expertise if required.