Product Update Webhook: find collection updated in Product

New Member
2 0 0

Hi,

I'm facing some issues in the Product Update webhook. Whenever I'm updating name/description and other fields in the product, I'm getting a webhook response with updated field but on updating the collection of that product, there's no way I can find out if the Product's collection is updated or not. At every Product update webhook, I'd to hit two different API ("admin/api/2020-10/custom_collections.json?product_id=632910392" and "/admin/api/2020-10/smart_collections.json?product_id=632910392") for finding Custom and Smart collection associated with the Product.

Is there any way to optimize this flow because, with above mentioned flow, I'd to hit two Shopify API at every Product Update webhook call.

Please help me out here.

0 Likes
Shopify Staff
Shopify Staff
31 3 4

Hello, if you'd like to receive updates on product collections, you can subscribe to the collections/update webhook

0 Likes