Skip to main content

Accept Fulfillment Order Discrepancy

POST 

/api/fulfillment-orders/:fulfillmentOrder/accept-discrepancy

Self-heal a shipping-provider ↔ fulfillment-order line discrepancy. Use this when the shipping provider marked the order shipped but one line's product cannot be fulfilled (no on-hand to deduct) — a permanent mismatch between what the provider shipped and what can actually leave the warehouse.

Accepting records a real shipment (with the provider's tracking) for the lines that DID ship and parks the discrepant line so it is never deducted from inventory. The provider's order record is left untouched (it stays the source of truth for what the provider believes shipped), and the open discrepancy alert is resolved.

Body:

  • acknowledged (required, must be true): explicit confirmation that the discrepant line will NOT be deducted from inventory. Any other value returns 422.

Side effects: records the SalesOrderFulfillment (+ tracking, inventory movements, COGS) for the fulfillable lines, marks the discrepant line out-of-sync (parked), stamps who/when accepted, advances the fulfillment order lifecycle, and resolves the discrepancy alert.

Returns the fulfillment order with discrepancy_accepted_at / discrepancy_accepted_by set. 422 if there is no shipped provider order, nothing discrepant to accept, or the shipment cannot be recorded.

Authentication: Requires Bearer token.

Request

Responses

OK

Response Headers
    Content-Type