curl --request POST \
--url https://api.orbita.melonn.com/supplier-orders/{internal_order_number}/finalize \
--header 'Content-Type: application/json' \
--header 'x-api-key: <api-key>' \
--data '
{
"comments": "Supplier confirmed the missing units will not be shipped"
}
'Finalize supplier order
Finalizes one of your supplier orders that was unpacked with differences, accepting the
quantities received as final. The order moves to state 5 (Finalized) and a
SUPPLIER_ORDER/CLOSED webhook is emitted.
Use it when an order is in state 7 (Unpacked with differences) and you do not expect
any more inventory for it. If more inventory arrives for an order in state 7, the order
goes back to unpacking instead. Orders that stay in state 7 without activity are
eventually finalized automatically by Melonn.
Preconditions
- The order must be in state
7(Unpacked with differences). - Every shipment registered for the order must have been received.
- Every package of the order must have been processed (unpacked).
| Code | Name | Closed |
|---|---|---|
| 1 | Created | No |
| 2 | Confirmed | No |
| 3 | Canceled | Yes |
| 4 | Reception in process | No |
| 5 | Finalized | Yes |
| 6 | Unpacking in progress | No |
| 7 | Unpacked with differences | No |
Request body
The body is optional. You can send comments; when it is a non-empty string it is saved
as the order’s comments (replacing the previous value) and in the order history.
If you send the Content-Type: application/json header, send a JSON body such as {}:
an empty body with that header returns 400.
curl --request POST \
--url https://api.orbita.melonn.com/supplier-orders/{internal_order_number}/finalize \
--header 'Content-Type: application/json' \
--header 'x-api-key: <api-key>' \
--data '
{
"comments": "Supplier confirmed the missing units will not be shipped"
}
'Authorizations
Path Parameters
Internal order number of the order to finalize (e.g. I00012345).
Body
Optional comment. When not empty, it replaces the order's comments and is saved in the order history.
Response
Order finalized. No body.