Update an order
Updates an order. Supports updating email, addresses, special instructions, and line items.
Required scope: write_orders (for API-key authentication).
Authorizations
Secret API key for admin access
JWT token for admin user authentication
Headers
Bearer token for admin authentication
Path Parameters
Order ID
Body
Identities the record has in external systems, keyed by system: the same { system: external_id } map the Admin API renders, so what you read can be sent straight back. Systems you do not name keep the reference they have. A list of { system, external_id } entries is accepted too.
"customer@example.com"
Null detaches the customer, leaving a guest order under its email.
AED, AFN, ALL, AMD, ANG, AOA, ARS, AUD, AWG, AZN, BAM, BBD, BDT, BGN, BHD, BIF, BMD, BND, BOB, BRL, BSD, BTN, BWP, BYN, BYR, BZD, CAD, CDF, CHF, CLF, CLP, CNY, COP, CRC, CUC, CUP, CVE, CZK, DJF, DKK, DOP, DZD, EEK, EGP, ERN, ETB, EUR, FJD, FKP, GBP, GEL, GHS, GIP, GMD, GNF, GTQ, GYD, HKD, HNL, HRK, HTG, HUF, IDR, ILS, INR, IQD, IRR, ISK, JMD, JOD, JPY, KES, KGS, KHR, KMF, KPW, KRW, KWD, KYD, KZT, LAK, LBP, LKR, LRD, LSL, LTL, LVL, LYD, MAD, MDL, MGA, MKD, MMK, MNT, MOP, MRO, MRU, MTL, MUR, MVR, MWK, MXN, MYR, MZN, NAD, NGN, NIO, NOK, NPR, NZD, OMR, PAB, PEN, PGK, PHP, PKR, PLN, PYG, QAR, RON, RSD, RUB, RWF, SAR, SBD, SCR, SDG, SEK, SGD, SHP, SKK, SLE, SLL, SOS, SRD, SSP, STD, STN, SVC, SYP, SZL, THB, TJS, TMM, TMT, TND, TOP, TRY, TTD, TWD, TZS, UAH, UGX, USD, UYI, UYU, UYW, UZS, VED, VEF, VES, VND, VUV, WST, XAF, XCD, XCG, XOF, XPF, YER, ZAR, ZMK, ZMW, ZWD, ZWG, ZWL, ZWN, ZWR "USD"
Defaults to the store primary channel when omitted.
aa, ab, ae, af, ak, am, an, ar, as, av, ay, az, ba, be, bg, bh, bi, bm, bn, bo, br, bs, ca, ce, ch, co, cr, cs, cu, cv, cy, da, de, de-AT, de-CH, dv, dz, ee, el, en, en-AU, en-CA, en-GB, en-IN, en-NZ, en-US, eo, es, es-419, es-CL, es-EC, es-MX, et, eu, fa, ff, fi, fj, fo, fr, fr-CA, fy, ga, gd, gl, gn, gu, gv, ha, he, hi, ho, hr, ht, hu, hy, hz, ia, id, ie, ig, ii, ik, io, is, it, iu, ja, jv, ka, kg, ki, kj, kk, kl, km, kn, ko, kr, ks, ku, kv, kw, ky, la, lb, lg, li, ln, lo, lt, lu, lv, mg, mh, mi, mk, ml, mn, mr, ms, mt, my, na, nb, nd, ne, ng, nl, nn, no, nr, nv, ny, oc, oj, om, or, os, pa, pi, pl, ps, pt, pt-BR, pt-PT, qu, rm, rn, ro, ru, rw, sa, sc, sd, se, sg, si, sk, sl, sl-SI, sm, sn, so, sq, sr, ss, st, su, sv, sw, ta, te, tg, th, ti, tk, tl, tn, to, tr, ts, tt, tw, ty, ug, uk, ur, uz, ve, vi, vo, wa, wo, xh, yi, yo, za, zh-CN, zh-HK, zh-TW, zu "en-US"
Public, customer-visible note.
Staff-only note. Rich text HTML; reads come back as this plus internal_note_html.
The buyer's own purchase-order reference. Searchable alongside the order number, and rendered on every order-facing document.
The signed_id of the buyer's purchase order, from files.upload() with visibility: 'private'. Null removes the document the order carries.
Stock location to prefer for fulfillment. Order Routing's built-in preferred-location rule ranks it first; routing falls back to the next rule when the location can't cover the cart.
Makes the order a company purchase, with that company's catalog prices and tax treatment. Null makes a draft a plain customer order again.
When true, copies the shipping address to the billing address.
Line items to upsert, keyed by variant. An entry sets that variant's quantity, creating the line item when the order has none; quantity: 0 removes it. Variants you do not send are left alone.
Response
order updated

