How to react to collection updates?

Highlighted
Shopify Expert
4179 29 401

Sales Channel turned out to be a useless exercise due to the ad-hoc nature of the rules and how they are interpreted. Fine.

 

Moving back to a Standard App, when a product gets added or removed from a collection via to "Smart" or "auto" coding, that does not trigger a collections/update webhook. So how do we know when that happens? In a Sales Channel we had specific webhooks that triggered with a "Hey, someone just added some crap to your collection", but we don't get that.

So what do people do? What's that secret sauce? If collections/update webhook is not gonna trigger, what else works?

 

 

Custom Shopify Apps built just for you! hunkybill@gmail.com http://www.resistorsoftware.com
0 Likes
Highlighted
Shopify Staff
Shopify Staff
7 3 1

Hello @HunkyBill,

I just checked with the team: for smart or auto coding, collection memberships do not trigger a collections/update webhook as if a user manually updated them. The two recommended approaches are:

  1. Periodically polling the collection if there’s only one you’re interested in
  2. Subscribing to products/update and collections/update to maintain product-collection memberships based on the collection’s rules and product’s properties

Hopefully this helps!

1 Like
Highlighted
Shopify Expert
4179 29 401

Hi,

That is exactly what I am doing, but I am not liking that pattern at all. I understand that the difficulty lies in the concept of the products being added/removed based on the rules, and that that means an update on the collection is tough to signal. Tough but not impossible.

It would be nice if Shopify could borrow the concepts used in Sales Channel to provide the same level of info to non-Sales Channel Apps. I see no reason why that could not be done, but of course, you will beg to differ

Anyway, thanks for the closure on this issue. Better (much better) than crickets chirping on the issue.

 

 

Custom Shopify Apps built just for you! hunkybill@gmail.com http://www.resistorsoftware.com
0 Likes