Cancel a whole platform: "custom" order, or individual quantities on
it, before it ships.
Cancellation has its own operation rather than being inferred from a
PUT. Dropping a line from a PUT body is not a cancellation and
never has been — it would destroy the line identity that returns and
claims are attached to, and it leaves the checks below nowhere to run.
Cancellations are final. There is no un-cancel.
Whole order or part of it
Omit lines to cancel the entire order. Supply lines to cancel
specific quantities — the order stays active while any live quantity
remains. cancelled_quantity is the cumulative total for a line,
not the increment for this request.
When a cancellation is refused
| Situation | Result |
|---|---|
| An open or approved claim exists on the order (or on a line you are cancelling) | 409 CLAIM_EXISTS |
| A line has an active return | 409 LINE_HAS_ACTIVE_RETURN |
| The order has already shipped | 409 ORDER_ALREADY_SHIPPED |
| We cannot reach the returns service to check | 503 RETURNS_CHECK_UNAVAILABLE — retry |
| The order is already cancelled | 200, nothing changes |
protection_cost_delta exceeds the fair share for the quantity cancelled | 422 PROTECTION_DELTA_DISPROPORTIONATE |
| The order has already been invoiced | Allowed — the credit lands on your next invoice |
A cancellation is refused rather than partially applied: if you get a
4xx or 5xx, nothing was changed.
Protection fees
protection_cost_delta is the reduction in the protection fee,
apportioned by you and sent as a negative number. The order's own
protection_cost never changes — reductions are recorded against
the cancellation. A later PUT must therefore still send the
original protection_cost; sending the reduced figure is rejected
with 409 PROTECTION_IMMUTABLE.
How large a reduction may be
A reduction must be proportional to the value you are cancelling:
max reduction = charged protection fee x (value cancelled / order value)
Both sides are cumulative — lines carries cumulative quantities, so
the ceiling is measured against everything reduced on the order so far,
not this request alone. A stated figure within max($0.10, 1%) of the
ceiling is accepted exactly as sent; beyond that the whole request is
rejected with 422 PROTECTION_DELTA_DISPROPORTIONATE and nothing is
cancelled — we never reduce by a different amount than you asked for.
The response carries max_allowed, so a rejected request can be
corrected and resent.
While any quantity remains live on the order the remaining fee cannot
fall below $1.95; only cancelling the whole order releases the fee
entirely.
Example. A $9.00 fee on an order of three equally-priced items.
Cancelling one item allows at most $3.00. A stated -9.00 is rejected;
-3.00 through -3.10 is accepted as sent.
Retries
An Idempotency-Key (UUID) header is required when you send lines,
and optional for a whole-order cancel.
Quantities are cumulative and two partial cancels on one order are
legitimately two events, so a retry without a key would be recorded as a
second cancellation and credited twice. Omitting it on a partial cancel
returns 422 IDEMPOTENCY_KEY_REQUIRED.
A whole-order cancel is safe without one — an order can only move to
cancelled once — but sending a key still gives you an exact replayed
response instead of a fresh evaluation.
| Time | Status | User Agent | |
|---|---|---|---|
Retrieving recent requests… | |||