There a few posts somewhat related but I'll start a fresh topic because a lot of information seems very outdated.
Why is there no webhook for metafields?
We have noticed that if a product metafield is created/updated, the product webhook fires.
Same for order.
However, it is not the case for other types of entities such as customers, variants, collections, etc...
Is there a solution?
Hey @ClementBR ,
I like that you took the time to make a fresh post actually, I hope that anyone else looking for this finds it and shares their thoughts as well.
This has been a longstanding issue if I recall correctly, and one that we've spoken about before. I know I've logged this as an issue before and I'll find it again and make some more noise to try to get attention on it again. It's not an issue that I know of a solution to though and I would call this a bug.
Metafield webhooks technically exist, they're just resource-specific and require adding metafield_namespaces to the payload sent when setting up a new webhook subscription. I would imagine just having a general webhook create/update webhook topic would result in a ton of noise and webhook traffic, most of which the clients consuming the webhooks wouldn't find any value in - so I'm not sure creating a new topic would be the ideal solution here. I'd prefer we just fixed the bug and mde sure that the behaviour was consistent across every resource.
Yes it is indeed a long standing issue.
I do believe a separate topic for metafields would be ideal because as you said many apps won't care about metafields.
For the ones that do, it is is critical though.
As for metafield_namespaces, the problem is that we need to know when ANY metafield was changed.
Unless we could pass '*' as a namespace to indicate we want to listen to all namespaces?
Yes, it is indeed for reporting purposes.
We need reports to load reasonably fast and the only way to do that is to keep the metafields in sync locally.
Even with the graph bulk metafield loading capabilities, reports that aggregate a lot of data would still need to make many calls and it would cause reports to load very slowly, if at all.
Hey again Clement,
Fair enough - I just think that the vast majority of webhooks I've seen wouldn't be relevant to third-parties, but I can understand after filtering out the excess noise how this might be useful. I'd somewhat prefer to have the root issue of the update behaviour being inconsistent resolved first, but I'll file a request for a new webhook as well.
|54 seconds ago|