I want to programmatically update the meta tags for all my products. But it’s been a pain to figure out how to do it using the new GraphQL API.
I often get wrong answers from the assistant in Shopify.dev. Is there a better way to get solutions?
Topic summary
A developer is struggling to programmatically update product meta tags using Shopify’s new GraphQL API, finding the dev assistant unhelpful.
Suggested approach:
- Review the GraphQL API documentation for Product fields directly
- Create a simple custom Shopify app (single file) to experiment with different GraphQL queries
- Test queries iteratively until achieving the desired results
Resource mentioned:
ShopifyDevs YouTube channel offers a starter series on GraphQL that may help with learning the API structure.
The issue remains unresolved, with the conversation offering guidance on self-directed learning rather than a direct solution.
Well keep in mind the dev assistant will work based on whatever prompt you give it but it’s not perfect.
It might be a good idea to take a step back and review the GraphQL API docs for Product and see what kind of fields you need.
If I were you I’d spin up a simple custom Shopify App (literally one file in your language of choice) and play around with different GraphQL queries until you get the exact data you need.
Shopify has a pretty starter series on GraphQL on the ShopifyDevs YouTube channel.