Dedicated to the Hydrogen framework, headless commerce, and building custom storefronts using the Storefront API.
Hi,
when I change the url from the shoify backend I can choose the possibility to create an URL Redirect from the old link to new one..
But, since I want to do the same thing via API, when I change the "handle" field it creates a new Url but old one became a "not found page"... there is a way to set this "create URL REDIRECT" via API?
Thnak you very much
While it's not part of the product update mutation, you can create a URL redirect via a separate mutation using UrlRedirect. Here is some documentation about the mutation: https://shopify.dev/api/admin-graphql/2021-10/objects/urlredirect#fields
Hope this helps!
To learn more visit the Shopify Help Center or the Community Blog.