Creates a delivery.
Creates a delivery in a draft state. Also creates an aggregated delivery related to the same purchase order if it doesn't exist yet. A delivery can only be created for a purchase order in the
ORDERED state, or in the
DELIVERED state if it is still accepting deliveries.
intake_reason field takes a number code with the following meanings:
|4||Quality issue (returned)|
|5||Wrongly delivered (returned)|
|6||Wrongly delivered (accepted)|
|7||Wrongly ordered (returned)|
|8||Wrongly ordered (accepted)|
|9||Delivered too much (returned)|
|10||Delivered too much (accepted)|
|11||Late delivery (returned)|
|12||Late delivery (accepted)|
|13||Pricing issue (returned)|
|14||Pricing issue (accepted)|