Hi, I would like to know if the reason/note is included in the inventory webhook, if not how do you suggest I can link the webhook notification to inventory changes?
Also, I’m having issues with the response of this query:
{
inventory_changes(sku: "A079SUBABT1101") {
data(sort: "+created_at", last: 10) {
edges {
node {
user_id
previous_on_hand
change_in_on_hand
location_id
reason
created_at
cycle_counted
}
}
}
}
}
for some reason, the last 3 results are old values from last year and shouldn’t be in the results:
thanks
Hey @apopelka,
Thanks for reaching out!
The Inventory Update Webhook does not have a field for reason or note, and at the moment, there is no way to link the notification to inventory changes. I will share your feedback with the team about adding a reason field to the webhook body.
Could you share the request id for that query, please?
Please let me know if you have any questions or concerns.
Best,
RayanP
Hi @sh-agent, thanks for the quick reply, here’s the request id: 650c517d40ace1abcb2d46e9
.
Also, I’d like to confirm if the inventory
value on the webhook references the available
inventory.
Thanks!
1 Like
Hey @apopelka,
Thanks for hanging in there while I looked into this issue.
I believe if you sort using the first filter it will return the expected results here.
{
inventory_changes(sku: "A079SUBABT1101") {
data(sort: "-created_at", first: 10) {
edges {
node {
user_id
previous_on_hand
change_in_on_hand
location_id
reason
created_at
cycle_counted
}
}
}
}
}
We will continue investigating the issue with the last filter.
Regarding the inventory value on the Inventory Update Webhook, it actually does not reference the available value.
I believe Inventory = on-hand + sell ahead - allocated - reserve.
Please let me know if you have any questions or concerns.
Best,
1 Like