Skip to main content

Record Outsourced Receipt

POST 

/api/manufacturing/manufacturing-orders/:manufacturingOrder/outsourced-receipt

Record receipt of finished goods from a contractor for an outsourced MO. Runs the production-costing flow: consumes the reserved components from FIFO, produces the output inventory, and costs it as materials + the PO's service fee. The MO must be Started (in_progress / partially_completed).

Required scope: manufacturing:write

Grant this scope to your token under Settings → Developer → Personal Access Tokens.

A service_fee_amount override updates the cost FinancialLine on the backing PO before costing, so it flows into cost_breakdown.service_fee.

Fields:

  • receipt_date (required, date)
  • service_fee_amount (optional, numeric ≥ 0) — overrides the PO service-fee financial line
  • lines (required, min 1):
    • mo_output_line_id (NULLABLE integer) — the MO output line this received quantity produces; defaults to the primary output
    • purchase_order_line_id (NULLABLE integer) — not used for finished-goods mapping; reserved for PO-linked receipts
    • received_quantity (required, numeric ≥ 0)
    • batch_number (optional, ≤ 128 chars) — auto-generated if blank
    • expiry_date (optional, date)
  • component_variance (optional): mo_component_line_id + actually_consumed_at_contractor — overrides per-component consumption

Service fee: with a per-unit rate configured, the fee is computed automatically at each receipt - omit service_fee_amount. Sending service_fee_amount on a receipt overrides the purchase order's total fee explicitly and switches the order to flat-fee mode - later receipts keep that total instead of re-truing from a rate.

Inter-stage freight: freight_amount (with optional freight_supplier_id and freight_reference) records the middle-mile shipping bill for goods arriving at this stage. It is added as a cost line on the backing purchase order and capitalizes into the received goods' landed cost rather than being expensed.

Component lot selection: when a component is lot-tracked, component_variance[].lot_allocation names the exact FIFO layers the contractor drew from, in the quantities they used (quantities are in the product's stock unit of measure). Omit it and the layers are chosen automatically in FIFO/FEFO order — which stays the default, since a contractor cannot always report the lot. Supplying it is what preserves an accurate genealogy record when they can.

Request

Responses

Successful response