api - Shopify Webhooks: Is there a way to determine whether or not an order came from Shopify POS?
I'm receiving a Webhook for every order that has been maid, but I do not know if it came from POS or from the website.
Answer
Solution:
You can inspect the order, and there is indeed a property known as the source of the order. That will tell you where the order originated from. Some Apps generate orders so their source will be a number. POS is pos. You should have no trouble figuring out the source from the attribute in the order.
In GraphQL parlance, you look for the app { name } and for example you'd see something "Draft Order" or "POS". In RestAPI is it probably still just source or source_name.
Source
Didn't find the answer?
Our community is visited by hundreds of Shopify development professionals every day. Ask your question and get a quick answer for free.
Similar questions
Find the answer in similar questions on our website.
Write quick answer
Do you know the answer to this question? Write a quick response to it. With your help, we will make our community stronger.