Feature request for sales channel changes in collections to trigger an update webhook.
Customers of our app rely on webhooks to keep product and collection data in sync with Shopify.
Given the following scenario:
- Store owner creates a collection with the “Online Store” sales channel disabled
- Adds products to the collection and saves
- At a later time, enables the “Online Store” sales channel to display it on the frontend
No webhook is fired when this occurs. In my opinion this should either be emitted by collections/update or collection_publications/update. Otherwise our application is under the impression that no publication has the collection enabled.
Hi @Patrick_S1
Would the collection_publications/update webhook work for this?
@Liam-Shopify This would be ideal, but from my testing and reading the Shopify docs, this won’t work in its current form. A third party app will not receive webhooks related to the “Online Store” sales channel publication.
If this can be added in it would be great though!
Have you tested subscribing to this webhook and seeing if publishing a collection to online store triggers the webhook?
Yes I have, and it does not. Disabling Online Store then saving the collection as well as enabling Online Store then saving the collection do not trigger any webhooks. Only after subsequent updates (like adding a product or changing collection description) do I get a collections/update webhook.
Thanks @Patrick_S1 - it does look like the collection_publications/update webhook only is triggered whenever a collection publication listing is updated, not if visibility for Online Store is changed.
It doesn’t seem that there is a dedicated webhook that fires only on “collection becomes visible in Online Store” - I’ll connect with the team that owns this area to see if this is on their roadmap to support and to register this as a feature request.
1 Like