Focusing on managing products, variants, and collections through the API.
I am experiencing an issue with the following use case:
At this point:
Hi Slappadabass,
As per the current Shopify API documentation, there's no automated way to create 301 redirects when you change the product handle via API. The 301 redirects are only auto-generated when you modify the handle from within Shopify's admin panel and specifically opt for it.
However, as a workaround, you could use the Redirect API to manually create a redirect when a product URL changes. You would have to track the changes in your product URLs and create a 301 redirect from the old URL to the new one every time a change occurs.
Hope this helps,
Liam | Developer Advocate @ Shopify
- Was my reply helpful? Click Like to let me know!
- Was your question answered? Mark it as an Accepted Solution
- To learn more visit Shopify.dev or the Shopify Web Design and Development Blog