Update draft order
/ admin/ v1/ stores/ {store_id}/ draft-orders/ {draft_id}- orders:write
Replace the draft. A draft already sent keeps its link, which shows the new quote. Send If-Match.
Path parameters
store_idstringrequiredThe store's ID, like
store_01k8qs5s…. Apps get it with the install, in the OAuth redirect and the token response.draft_idstringrequiredThe draft order's ID, like
draft_01k8qs5s….
Headers
If-Matchstring · or nullETag from the last read, e.g. "v3"
shop-api-versionYYYY-MMThe version to answer in. Without it, your app’s pinned version, else the newest.
Body
customer_idstring · or nullAn existing customer; their email, phone and language fill in what is left blank.
emailstring · or nullphonestring · or nulllocalestring · or nullThe customer's language for the invoice, e.g.
ar.linesarray of objectsshipping_addressobject · or nullAn address for a checkout. Named apart from customers' saved addresses in the API documents.
billing_addressobject · or nullAn address for a checkout. Named apart from customers' saved addresses in the API documents.
shippingobject | object · or nullHow the order is delivered.
Returns
200 Saved, priced.
Errors
- 403
forbiddenMissing permission. - 404
not_foundNo such draft. - 409Already an order (
draft_completed) or being paid (payment_in_progress). - 412
precondition_failedChanged since read. - 422
validation_failedValidation failed.