Skip to main content

Fulfillments

πŸ“„οΈVoid Shipment

Voids a shipment (SalesOrderFulfillment) — a SOFT, reversible cancel that does NOT hard-delete the record ('A1'). Voiding: reverses the shipment's inventory movements, reverts Fulfilled→Allocated allocations, restores the parent FulfillmentOrder budget and reopens the SAME FO to Open/Unsubmitted so it can be re-fulfilled, cancels the carrier order, and flips the SOF to status=canceled with voided_at/voided_by_user_id/void_reason set. The SOF + its lines are RETAINED for history; voided shipments are excluded from the active fulfillment tab (voided_at IS NULL filter).

πŸ“„οΈRepair Provider Fulfillment Orphan

Link an orphan shipping-provider order (link_state `orphan_linkable`, suggested_action `link`) to an existing FulfillmentOrder / SalesOrderFulfillment already on this sales order whose lines cover the same products (Phase 2). Only links to an FO/SOF that does NOT already have an active (non-cancelled) provider order β€” two active provider orders on one FO is invalid. An orphan whose only match is already taken is classified `orphan_duplicate` (use Import) instead of `orphan_linkable`, and a repair attempt against it is rejected with 422. Use the `provider`, `integration_instance_id`, and `external_order_id` from the orphan returned by GET provider-fulfillment-snapshots.

πŸ“„οΈImport Provider Fulfillment Orphan

Create the SKU fulfillment entities for an orphan shipping-provider order with no counterpart (link_state `orphan_importable`) (Phase 3). When the provider order is not yet shipped (suggested_action `import_fo`) a FulfillmentOrder is created; when it is already shipped (suggested_action `import_fo_and_sof`) a FulfillmentOrder plus a SalesOrderFulfillment ship event with tracking is created. Provider item SKUs are matched against the sales order's unfulfilled lines.