POST/api/packing/orders/{id}/confirm

Confirm the order — the gate [Packaging]

The end of the night for one order. It refuses while any line is still undecided — that is the whole point of the screen: an order reaching shipping with a line nobody looked at is the exact failure the paper process has today. A short line does NOT block it; short is a decision.

On success: stamps who packed it and when, records the box count, releases the lock, and advances packing → shipping (displayed as Ready to ship). Only an order currently being packed can be confirmed.

  • IdempotentThe SDK sends Idempotency-Key, so a retried request is only applied once.

1 parameter · 1 body field
idstringrequired
Order id.

The box count (PK-8) — it drives the labels.

boxCountintegerrequired
Required. Zero is allowed — some orders leave on an open rack with no box.

7 status codes
200The confirmed order.
idstringoptional
Order id.
orderNumberstringoptional
Human-facing, `ORD-YYMM-NNN`.
customerIdstringoptional
Customer id.
customerNamestringoptional
customerTypeSnapshotstringoptional
The customer's type AT ORDER TIME — it may change later, and the order keeps what it was sold under.
orderDatestringoptional
The day the order was taken.
requestedDeliveryDatestringoptional
The day it ships — what production and packing group by (D-14).
statusstringoptional
Allowed:draftconfirmedin_productionpackingshippingshippedclosed
sourcestringoptional
Allowed:phonewalk_inemail_importself_service
specialInstructionsstringoptional
Order-level note.
createdByIdstringoptional
createdByNamestringoptional
createdAtstringoptional
fromRecurringIdstringoptional
The standing order that generated this one (R6). Null for every hand-taken order. Note the `source` does NOT distinguish one: a generated order says `phone`, because the OrderSource enum was deliberately left untouched.
linesarray<object>optional
400Invalid input — the `error` string says what was wrong.
errorstringrequired
401Not authenticated. Sign in first (see the Auth tag).
errorstringrequired
403Authenticated, but not allowed — this endpoint requires a department membership or a role you do not have.
errorstringrequired
404Not found.
errorstringrequired
409Another packer has this order open.
errorstringrequired
500Unexpected server error.
errorstringrequired

Error handling

A 400 is returned: Invalid input — the error string says what was wrong. A 401 is returned: Not authenticated. Sign in first (see the Auth tag). A 403 is returned: Authenticated, but not allowed — this endpoint requires a department membership or a role you do not have. A 404 is returned: Not found. A 409 is returned: Another packer has this order open. A 500 is returned: Unexpected server error.