Discussing APIs and development related to customers, discounts, and order management.
Hi All,
Is it possible to determine which market created an order via the APIs? I have a plus merchant who wants to do specific things with an order for the different markets. Currently I do not see any field that relates to which specific market the order was placed, only the presentment currency gives any hint but its not enough to determine which specific market the order "belongs" to.
Its obvious this data is maintained somewhere otherwise you wouldnt be able to see the sales statistics for the markets. I just don't see its availability in the APIs but maybe I missed it.
Anybody know where I might find this information for a specific order?
Cheers,
Gary
Solved! Go to the solution
This is an accepted solution.
Shipping (or billing, in case there's no shipping needed) country determines the market.
Since a country can belong to only one market, you could look it up that way.
This is an accepted solution.
Shipping (or billing, in case there's no shipping needed) country determines the market.
Since a country can belong to only one market, you could look it up that way.
Hi Evaldas,
Hey thanks for the tip, I guess I was kinda hoping for an easier method but ce la vie 🙂
I'll have to use the graphql query to get the markets and check which are active (since there is no query param to reduce the result to only active markets) and check on the fly, decompose the results to something for faster lookup and cache it for a while.
Thanks again for the info!
Cheers,
Gary
Hello,
Let's say we use "Billing address" then that wouldn't in this scenario: I could be viewing a Japanese Market based product where my billing address is UK and I want it shipped to a friend there in Japan. In this case, the billing and the Market do not match.
I think having an order attributed to the Market (similar to how Products are tied to a Market) helps with the data integrity on top of Gary's response with it needing to be unnecessary complex to get that data by the region.