Our Partner & Developer boards on the community are moving to a brand new home: the .dev community forums! While you can still access past discussions here, for all your future app and storefront building questions, head over to the new forums.

Understing how product/create and inventory_items/create webhooks works

Solved

Understing how product/create and inventory_items/create webhooks works

AppDev1
Shopify Partner
3 0 1

Hi all,

I am working on an app that subscribes to all the product and inventory_items webhooks works. But i don't have good understanding of what webhooks are triggered in different use cases.

For example, I added a test product and product variant in my test store and published it. I was hoping it is going to send me "Product/create" webhook, but that never happened.

Sometimes, I have seen getting "inventory_items/create" when new product is added, sometimes I saw both of them getting triggered.

Is the a good documentation on this that I can read? I'd getting confusing to figure out these two topics.

 

Appreciate any help I can get on this.

Accepted Solution (1)

ShopifyDevSup
Shopify Staff
1453 239 534

This is an accepted solution.

Hey @AppDev1,


The Webhooks REST documentation was recently reorganized and updated with descriptions of each webhook event topic. Selecting a subscription topic will expand a basic description of what triggers the webhook, resource info, scopes as well as providing an example payload, though it may be important to note that some payloads may differ depending on other factors. 

When testing a few of the product and inventory topics each worked as described. For example when using either the admin and API to create a new product, the products/create webhook was triggered as expected, as was products/update when a variant was both added and removed. Info about product publication is generally found on the ProductListings object, a different than Products. Changes in publication on that object wouldn't be expected to trigger the product events like the create webhook.   

Testing different subscriptions and the events that trigger a webhook is always suggestion, but I hope this offers some clarity - Cheers!

Developer Support @ Shopify
- Was this reply helpful? Click Like to let us 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

View solution in original post

Replies 2 (2)

ShopifyDevSup
Shopify Staff
1453 239 534

This is an accepted solution.

Hey @AppDev1,


The Webhooks REST documentation was recently reorganized and updated with descriptions of each webhook event topic. Selecting a subscription topic will expand a basic description of what triggers the webhook, resource info, scopes as well as providing an example payload, though it may be important to note that some payloads may differ depending on other factors. 

When testing a few of the product and inventory topics each worked as described. For example when using either the admin and API to create a new product, the products/create webhook was triggered as expected, as was products/update when a variant was both added and removed. Info about product publication is generally found on the ProductListings object, a different than Products. Changes in publication on that object wouldn't be expected to trigger the product events like the create webhook.   

Testing different subscriptions and the events that trigger a webhook is always suggestion, but I hope this offers some clarity - Cheers!

Developer Support @ Shopify
- Was this reply helpful? Click Like to let us 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

AppDev1
Shopify Partner
3 0 1

Thanks for your comment @ShopifyDevSup . We have these webhhoks (product, order, fulfillment) integrated with our app for couple of years at this point, and it's been working pretty well.

 

I feel like there were some load issues around thanksgiving / Christmas time. We noticed these webhooks were delayed by ~12 hours. After new year, it's been near real time without any changes from our side.