Prepare Package Command
Actors
Akinon Order Management System (OMS)
Domain Objects
Packaging Order
OMS Command (Packaging Order Command)
Process
The OMS application copies orders from the Akinon Omnitron Application to itself to prepare delivery/distribution plans, generate packaging orders and transfer them to operation points.
The products in the order are distributed to the Packaging Orders by running the rules in the distribution scenarios designated by the brand.
Packaging Orders are transferred to the Akinon Instore App or the brand’s integrated software. (via Packaging Orders Webhooks)
Packaging orders assigned to the Store/Warehouse commence in the Waiting status.
The PREPARE_PACKAGE_COMMAND command is executed to prepare the products in the package. If there are missing products or replaceable products in the package, this command should be executed.
This command does three things at the same time:
If there are missing/defective products in the package, it marks these products as out-of-stock. The DETECTED_OUT_OF_STOCK_ITEM command must be added for this operation.
If there are replaceable products in the package, it replaces a product with an alternative product. The REPLACE_PRODUCT command must be added for this operation.
For the remaining products in the package, it updates the barcode information. The PKG_STATE_TRANSITION command must be added for this operation.
When this command is executed, the status of the packaging order is updated to Preparing.
If the command is executed successfully, the API returns the package ID, package number, stock location ID and remaining package items.
Command Parameters and Prerequisites
For each packaging order;
package
integer
The ID of the package
Mandatory
transition
integer
The ID of the command
Optional (if Slug is given)
slug
slug
Unique slug of the command
Optional (if Transition ID is given)
select_items_by_omnitron_id
boolean
Select items by Omnitron ID
Mandatory (It can be send as false)
replacement_products
list
List of replaceable products
Optional
create_manual_oos_package
boolean
Create manual OOS package
Mandatory (It can be send as false)
oos_package_items
list
ID's of the missing/defective package items
Optional
barcodes
list
Barcode values of the package items
Optional
denial_reason
integer
Denial reason ID
Optional
unit_weights
list
Unit Weight values of the package items
Optional
This command can only be executed for packages that are in the following states:
Waiting (enum_value: 100)
POST
Prepare Package
POST
Prepare PackagePath: https://{customer_api_url}/api/v1/oms/packages/{package_id}/command/
Request Body
{
"transition": 71,
"input_parameters": {
"select_items_by_omnitron_id": true,
"replacement_products": [
{
"package_item": 282687,
"new_product_sku": "10034"
}
],
"create_manual_oos_package": true,
"oos_package_items": [
282688
],
"barcodes": [
{
"order_item": 2047,
"barcode": "123"
},
{
"order_item": 2046,
"barcode": "123"
},
{
"order_item": 2045,
"barcode": "123"
}
]
}
}
Successful Response
Status Code: 200 OK
After the successful execution of the command, the API returns following responses :
{
"id": 123,
"number": "1234567891234567P3",
"stock_location": 2,
"packageitem_set": ["..."]
}
Last updated
Was this helpful?