Cannot specify location when creating order using Shopify Rest API

Shopify Partner
10 0 0

We have 3 locations set in admin settings. And we want to use a location (not the default location) for some orders.

I have tried setting the order location_id field or the line_item origin_location field (tried also both together), but none is working.

There's no error but the created order always sets to the default location.

Reply 1 (1)

Shopify Staff (Retired)
193 36 54

Hey @wylanosorio ,


This would be expected - initial inventory debiting is actioned based on shop inventory priority configuration, and can then be re-attributed with a followup fulfillment call.


Alternatively, you can include a fulfillment array directly in the order payload and cite a location id from which to debit the inventory, but it's worth noting that this will cause the order to immediately transition to "fulfilled" upon creation.



To learn more visit the Shopify Help Center or the Community Blog.