Record goods received with no order
hub_record_received_goodsStock that arrived with no purchase order behind it — the merchant bought it on the spot, or it was ordered outside the platform. Creates the order already fully received and ADDS THE QUANTITIES TO REAL STOCK at the outlet, in one step. Use this ONLY when no order exists. If the goods match an order that was sent, use receive_purchase_order instead — otherwise the same delivery is counted twice, once here and once when someone receives the real order. Check get_purchase_orders for an open order from this supplier before calling. The items must already be linked to the supplier (get_supplier_items) and stock-managed at the outlet. There is no undo: correcting a mistake means a stock adjustment afterwards.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| lines | Yes | What arrived | |
| notes | No | ||
| discount | No | Flat discount on the whole order, e.g. "25.00". Not with discountPercent | |
| dutyFees | No | Duty / customs charged on the order | |
| outletId | Yes | Outlet id from get_outlets — where the goods physically arrived | |
| customFees | No | Any other named charge on the order, e.g. "Handling" | |
| receivedAt | No | ISO date the goods arrived — defaults to now | |
| supplierId | Yes | Supplier id from get_suppliers | |
| invoiceDate | No | ISO date on the invoice | |
| shippingFee | No | Shipping charged on the order, e.g. "18.00" | |
| invoiceNumber | No | ||
| discountPercent | No | Discount as a percentage of the items subtotal | |
| updateSupplierCostVariantIds | No | Items whose unitCost should become the supplier’s stored cost from now on |