Topics covering webhook creation & management, event handling, Pub/Sub, and Eventbridge, in Shopify apps.
Hey
I tried to find the reason why some clients' collections are not synced in our application. And after some research, I figured out that if you use a bulk operation on the products page (bulk 'Add collection' in my case, see the screenshot for reference), it fires the products_update webhook (without any reference to the collections in the payload) instead of collections_update. So we have to make an extra API call to get the collects object to get a list of collections on every product!
The second problem is that if many products have been selected this way, you will get a lot of webhooks - one for each product.For example, if you add 15 products to a collection, you will get 15 products_update webhooks instead of one collections_update.
It makes no sense 😞 And makes us to do extra API calls (just to reminder that Shopify has a limit for 2 calls per second)
Hi Maria!
Thanks for flagging this with us. I've been in touch with the product team responsible for this area and this is a known issue and the team is actively working on addressing this. Will update here once it's resolved.
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