My app implements a custom fulfillment service (fetch_stock endpoint).
When a shop changes their inventory in my app, I want that change to be reflected immediately in their Shopify Admin > Products.
Currently, it can take up to an hour for Shopify to call the fetch_stock endpoint.
Similarly, I'd like the shop to be able to use the shopify admin to change inventory, and have that change be pushed back to fulfillment service. I'm not sure if listening on the inventory_levels.update webhook will work here, since my app is managing the inventory?
@scottydont Since my app is managing the inventory through the fetch_stock endpoint, it doesn't seem right to modify the inventory directly through the API?
Additionally, I'm having issues because shop's can edit their inventory directly in the Admin > Products, even though the product inventory_service is set to my app. I can listen to inventory_levels/update webhook and update the inventory accordingly, but that webhook also fires when an order is created, so I have no way to differentiate whether the inventory was updated through the admin (meaning I need to update it on my end too) or through an order (I take no action).
Is there another way to do this? Ideally, there would be a `source` attribute or similar, the value being "admin", or "order", in the inventory_levels/update webhook payload.
|2 hours ago|