Create Purchase Order
POST /purchase_orders
π Paid plan only
Creates a purchase order. The PO number is auto-generated if omitted.
Parameters
Section titled β Parameters βHeader Parameters
Section titled βHeader Parameters βE.g. 123
Example
123Request Body
Section titled βRequest Body βobject
object
Supplier ID. Required; must belong to the company.
Warehouse ID stock is delivered to. Required; must belong to the company.
Lifecycle state: draft -> active -> completed.
PO number. Auto-generated if blank.
Must be unique per company.
Expected delivery date (must fall between 2010-01-01 and 2035-01-01).
Default GBP. Cannot be changed once the PO is active.
Auto-calculated from expected_date if omitted.
Emails the supplier report on save when the PO is active.
Format for the supplier report. Default pdf.
Line items.
object
Existing line item ID (update requests only).
Must exist in the company and not be deleted. Required for create requests.
Must be greater than 0. Required for create requests.
Unit cost. Must be greater than 0. Required for create requests.
Required for create requests.
Updates the supplier product variant reference.
Updates the supplier product variant title.
Update requests only β increments the received count for the line item. Cannot be negative.
Example
{ "purchase_order": { "supplier_id": 1748, "destination_warehouse_id": 1784, "expected_date": "2026-02-01T00:00:00Z", "currency_code": "GBP", "note": "Restock order", "shipping_and_handling": 12.5, "purchase_order_product_variants_attributes": [ { "product_variant_id": 1226617, "quantity": 10, "cost": 9.99, "tax_rate": 0.2 } ] }}Responses
Section titled β Responses βCreated. Returns the new purchase order (same shape as the list items).
object
object
Example
{ "id": 492, "number": "PO-0000002", "state": "draft", "supplier_id": 1748, "destination_warehouse_id": 1784, "line_items": []}Validation failed (missing supplier/warehouse, invalid line item cost/quantity/tax_rate, duplicate reference_number, or IDs not found in the company). Returns an array of error messages.