Orders

Orders are a group of items that are picked or put into the storage system. When creating and updating orders, the changes need to be verified and updated asynchronously by PowerPick.

Attributes

  • id string LIMIT: 50

    Unique identifier for the object.

  • countEmptyLocations boolean

    For count orders only. Determines if locations with that material at a quantity of 0 should be included in the count.

    Default value: false

  • deadline dateTime

    Date by which the order must be completed.

  • directionType integer/string

    The type of order. Can use integer or string.

    Possible values:

    1 or "put"
    2 or "pick"
    3 or "return"
    4 or "transport"
    5 or "count"
    7 or "production"

    Default value: 2 (pick)

  • errorCode integer

  • errorDescription string

  • handlingUnit string

    DEPRECATED.

  • hasStock integer

    If there is enough stock to fulfill the order.

    Possible values:

    0 = False
    1 = True

  • Info1 string LIMIT: 80

    A generic field for custom use.

  • Info2 string LIMIT: 80

    A generic field for custom use.

  • Info3 string LIMIT: 80

    A generic field for custom use.

  • Info4 string LIMIT: 80

    A generic field for custom use.

  • Info5 string LIMIT: 80

    A generic field for custom use.

  • modifedAt datetime

    The date/time this order was last modified. This will either be the creation date if it is still queued, or the processed date.

  • name string LIMIT: 50

    Unique name for the order.

  • owner string LIMIT: 50

    Used in a transfer order. The owner will be replaced by the given recipient, which will be assigned as the new owner of the material during the put.

  • priority integer

    Order priority level.

    Possible values:

    1 = Low
    2 = Medium
    3 = High
    4 = Hot (if included)

    Default value: 2 (Medium)

  • recipient string LIMIT: 50

    Used in a transfer order. The recipient given will be assigned as the new owner of the material during the put.

  • status string

    Order status type.

    Possible values:

    "Untouched"
    "Ready for Allocation" (when reverted from "Is Allocated")
    "Is Allocated"
    "In Process" (order is imported but not fully picked/put)
    "Processed" (order is fulfilled)

    Default value: Untouched

  • type integer

    Order creation/origin type. Automatically determined.

    Possible values:

    0 = NotSet
    1 = External
    2 = ExtManaged
    3 = Internal
    4 = Manual
    5 = Auto

  • unit string LIMIT: 50

    Used with batches.

  • warehouseName string LIMIT: 50

    Name of the warehouse this order belongs to.

  • zones array

    Array of Zone names this order is a part of.

  • [dynamicField] string LIMIT: 1999

    Any of the dynamic order fields from PowerPick. Requires ItemPath's Custom Fields app.

Endpoints

List Orders

get /api/orders

Arguments

  • countEmptyLocations boolean

    For count orders only. Determines if locations with that material at a quantity of 0 should be included in the count.

  • deadline datetime

    Date by which the order must be completed. Like all date arguments, a [gt], [lt], [lte], for [gte] can be prefixed.

  • directionType integer/string

    Only return orders that have the given direction type. Can use integer or string.

    Possible values:

    1 or "put"
    2 or "pick"
    3 or "return"
    4 or "transport"
    5 or "count"
    7 or "production"

  • handlingUnit string

    DEPRECATED.

  • hasStock integer

    If there is enough stock to fulfill the order.

    Possible values:

    0 = False
    1 = True

  • Info1 string LIMIT: 80

    A generic field for custom use.

  • Info2 string LIMIT: 80

    A generic field for custom use.

  • Info3 string LIMIT: 80

    A generic field for custom use.

  • Info4 string LIMIT: 80

    A generic field for custom use.

  • Info5 string LIMIT: 80

    A generic field for custom use.

  • modifiedDate datetime

    Return orders modified on a certain date. Like all date arguments, a [gt], [lt], [lte], for [gte] can be prefixed.

  • name string LIMIT: 50

    Only return orders that have the given name.

  • type integer

    Order creation/origin type. Automatically determined.

    Possible values:

    0 = NotSet
    1 = External
    2 = ExtManaged
    3 = Internal
    4 = Manual
    5 = Auto

  • owner string LIMIT: 50

    Used in a transfer order. The owner will be replaced by the given recipient, which will be assigned as the new owner of the material during the put.

  • priority integer

    Only return orders that have the given priority.

  • recipient string LIMIT: 50

    Used in a transfer order. The recipient given will be assigned as the new owner of the material during the put.

  • status string

    Order status type.

    Possible values:

    "Untouched"
    "Ready for Allocation" (when reverted from "Is Allocated")
    "Is Allocated"
    "In Process" (order is imported but not fully picked/put)
    "Processed" (order is fulfilled)

  • unit string LIMIT: 50

    Used with batches.

  • [dynamicField]

    Any dynamic fields that have been set up can be used as a filter. Requires ItemPath's Custom Fields app.

  • limit integer

    A limit on the number of objects to be returned. Limit can range between 1 and 1000.

    Default value: 250

  • offset integer

    Will return items, but only those after the integer amount.

  • orderBy string, array

    Order the response by the selected field. Multiple values can be passed, separated by a comma.

  • countOnly boolean

    When "true", will only return a count of the amount of items in the query.

    Default value: false

Request with curl
curl "http://[Your IP] /api/orders" \ -X get \ -H "Content-Type: application/json" \ -H "Authorization: Bearer [Your JWT Access Token]"
Example Response
{
    "orders": [
        {
            "warehouseName": "Warehouse",
            "Info5": null,
            "id": "85A55CF6-BE05-48AF-B0D7-D71212C3ACCA",
            "order_lines": [
                {
                    "number": 1,
                    "serialNumber": "61",
                    "materialName": "S103",
                    "quantity": 1.0,
                    "quantityDeviated": 1.0,
                    "id": "11A3CA33-3A5C-47AC-8A99-C30B03255120",
                    "quantityConfirmed": 0.0,
                    "modifiedDate": "2021-11-15T15:49:20.353000",
                    "quantityRequested": 0.0,
                    "lot": null
                },
                {
                    "number": 2,
                    "serialNumber": "62",
                    "materialName": "S103",
                    "quantity": 1.0,
                    "quantityDeviated": 1.0,
                    "id": "B9125633-C57C-4BBF-A022-E163C9B817F7",
                    "quantityConfirmed": 0.0,
                    "modifiedDate": "2021-11-15T15:49:20.373000",
                    "quantityRequested": 0.0,
                    "lot": null
                },
                {
                    "number": 3,
                    "serialNumber": "63",
                    "materialName": "S103",
                    "quantity": 1.0,
                    "quantityDeviated": 1.0,
                    "id": "55A6E9BC-8AC5-40A5-9F9E-8C8AA7EFC735",
                    "quantityConfirmed": 0.0,
                    "modifiedDate": "2021-11-15T15:49:20.393000",
                    "quantityRequested": 0.0,
                    "lot": null
                },
                {
                    "number": 4,
                    "serialNumber": "64",
                    "materialName": "S103",
                    "quantity": 1.0,
                    "quantityDeviated": 1.0,
                    "id": "3A425AA6-5247-4E7C-A567-48E99FEC46C9",
                    "quantityConfirmed": 0.0,
                    "modifiedDate": "2021-11-15T15:49:20.417000",
                    "quantityRequested": 0.0,
                    "lot": null
                },
                {
                    "number": 5,
                    "serialNumber": "65",
                    "materialName": "S103",
                    "quantity": 1.0,
                    "quantityDeviated": 1.0,
                    "id": "4A0C741B-5E79-4713-BB4B-4F10E9C23B1C",
                    "quantityConfirmed": 0.0,
                    "modifiedDate": "2021-11-15T15:49:20.440000",
                    "quantityRequested": 0.0,
                    "lot": null
                }
            ],
            "modifiedDate": "2021-11-15T15:49:20.317000",
            "handlingUnit": null,
            "ORDERISSUETO": null,
            "Info3": null,
            "orderType": 1,
            "ORDERNOTE": null,
            "ORDERFACILITY": null,
            "status": "queued",
            "hasStock": 0,
            "directionType": 1,
            "Info1": null,
            "ORDERINFO6": null,
            "Info2": null,
            "unit": null,
            "priority": 2,
            "storageUnits": [
                {
                    "id": "CA1E5648-FA38-416F-9604-CF33A6763496",
                    "name": "VLM-01"
                }
            ],
            "incompleteAllocations": 0,
            "Info4": null,
            "name": "Test Put Order Safe 10",
            "deadline": null
        }
    ]
}

Create Order

post /api/orders

Create an order and get a response. An array of at least one Order Line is required. For fields on the Order Lines level, click here.

Body Parameters

  • name string LIMIT: 50
    REQUIRED

    The unique order name/number.

  • order_lines array
    REQUIRED

    Any amount of order lines related to this order (see Order Lines for more information on fields).

  • allocate boolean

    Whether this order should be allocated when imported.

    Default value: false

  • carriers array

    A list of carriers that this order can be picked or put from. Either an ID or name is required.

    Possible values:

    [{"id": "66AFE69B-695E-469F-9E73-C416A12B727E"}, {"name": "01"}]

  • countEmptyLocations boolean

    For count orders only. Determines if locations with that material at a quantity of 0 should be included in the count.

    Possible values:

    false

  • deadline dateTime

    Date by which the order must be completed.

  • directionType integer/string

    The type of order. Can use integer or string.

    Possible values:

    1 or "put"
    2 or "pick"
    3 or "return"
    4 or "transport"
    5 or "count"
    7 or "production"

    Default value: 2 (pick)

  • handlingUnit string

    DEPRECATED.

  • Info1 string LIMIT: 80

    A generic field for custom use.

  • Info2 string LIMIT: 80

    A generic field for custom use.

  • Info3 string LIMIT: 80

    A generic field for custom use.

  • Info4 string LIMIT: 80

    A generic field for custom use.

  • Info5 string LIMIT: 80

    A generic field for custom use.

  • locations array

    A list of locations that this order can be picked or put from. Either an ID or name is required.

    Possible values:

    [{"id": "8B3E44C1-EA03-4F2D-A514-EF5B7AE2BF89"}, {"name": "VLM 1/01/01"}]

  • owner string LIMIT: 50

    Used in a transfer order. The owner will be replaced by the given recipient, which will be assigned as the new owner of the material during the put.

  • priority integer

    Order priority level.

    Possible values:

    1 = Low
    2 = Medium
    3 = High
    4 = Hot (if included)

    Default value: 2 (Medium)

  • recipient string LIMIT: 50

    Used in a transfer order. The recipient given will be assigned as the new owner of the material during the put.

  • shelves array

    A list of shelves that this order can be picked or put from. Either an ID or name is required.

    Possible values:

    [{"id": "7142BF15-38BD-4971-BCB2-D890DDA9CC32"}, {"name": "01/01"}]

  • storageUnits array

    A list of storage units that this order can be picked or put from. Either an ID or name is required.

    Possible values:

    [{"id": "3276A9F6-7CE5-4924-A02B-FD8304D7C3A1"}, {"name": "VLM 1"}]

  • unit string LIMIT: 50

    Used with batches.

  • warehouseName string LIMIT: 50

    The name of the Warehouse this order will be associated with. If no warehouse name or id is given, it will use the warehouse associated with the current station.

  • warehouseId uuid

    The id of the Warehouse this order will be associated with. Cannot be used with warehouseName.

  • zones array

    A list of zones that this order can be picked or put from. Either an ID or name is required.

    Possible values:

    [{"id": "9B937196-FBDC-4462-9D15-E60A7EEB5FA7"}, {"name": "Zone 1"}]

  • [dynamicField] string LIMIT: 1999

    Any of the dynamic order fields from PowerPick. Requires ItemPath's Custom Fields app.

Request with curl
curl "http://[Your IP] /api/orders" \ -X post \ -H "Content-Type: application/json" \ -H "Authorization: Bearer [Your JWT Access Token]" \
-d '{
    "name": "Sample Put Order",
    "directionType": "Put",
    "allocate": true,
    "order_lines": [
        {
            "materialId": "8E7EC42A-F2B2-4B64-BF71-750F006DEF8D",
            "quantity": 1,
            "Info1": "TEST",
            "serialNumber": 8
        },
               {
            "materialId": "8E7EC42A-F2B2-4B64-BF71-750F006DEF8D",
            "quantity": 1,
            "Info1": "TEST",
            "serialNumber": 9
        },        {
            "materialId": "8E7EC42A-F2B2-4B64-BF71-750F006DEF8D",
            "quantity": 1,
            "Info1": "TEST",
            "serialNumber": 10
        },        {
            "materialId": "8E7EC42A-F2B2-4B64-BF71-750F006DEF8D",
            "quantity": 1,
            "Info1": "TEST",
            "serialNumber": 12
        }
    ]
}'
Example Response
{
    "order": {
        "warehouseName": "Warehouse",
        "Info5": null,
        "id": "C1B2FB93-40A9-4B17-998B-DEA51CCE5C38",
        "order_lines": [
            {
                "number": 1,
                "serialNumber": "8",
                "materialName": "S103",
                "quantity": 1.0,
                "quantityDeviated": 1.0,
                "id": "C528ABFC-A2E3-4C53-A487-04E66C5BB906",
                "quantityConfirmed": 0.0,
                "modifiedDate": "2021-11-15T20:06:51.363000",
                "quantityRequested": 0.0,
                "lot": null
            },
            {
                "number": 2,
                "serialNumber": "9",
                "materialName": "S103",
                "quantity": 1.0,
                "quantityDeviated": 1.0,
                "id": "7611E030-7B47-475C-AE09-4C4C5456BE57",
                "quantityConfirmed": 0.0,
                "modifiedDate": "2021-11-15T20:06:51.423000",
                "quantityRequested": 0.0,
                "lot": null
            },
            {
                "number": 3,
                "serialNumber": "10",
                "materialName": "S103",
                "quantity": 1.0,
                "quantityDeviated": 1.0,
                "id": "38DC788D-A46C-4163-B6DA-4D9F3B411B91",
                "quantityConfirmed": 0.0,
                "modifiedDate": "2021-11-15T20:06:51.510000",
                "quantityRequested": 0.0,
                "lot": null
            },
            {
                "number": 4,
                "serialNumber": "12",
                "materialName": "S103",
                "quantity": 1.0,
                "quantityDeviated": 1.0,
                "id": "238EEE37-9B6B-4204-97E8-F1635B4BD4D0",
                "quantityConfirmed": 0.0,
                "modifiedDate": "2021-11-15T20:06:51.577000",
                "quantityRequested": 0.0,
                "lot": null
            }
        ],
        "modifiedDate": "2021-11-15T20:06:51.363000",
        "handlingUnit": null,
        "ORDERISSUETO": null,
        "Info3": null,
        "orderType": 1,
        "ORDERNOTE": null,
        "ORDERFACILITY": null,
        "status": "queued",
        "hasStock": 1,
        "directionType": 1,
        "Info1": null,
        "ORDERINFO6": null,
        "Info2": null,
        "unit": null,
        "priority": 2,
        "storageUnits": [
            {
                "id": "CA1E5648-FA38-416F-9604-CF33A6763496",
                "name": "VLM-01"
            }
        ],
        "incompleteAllocations": 0,
        "Info4": null,
        "name": "Sample Put Order",
        "deadline": null
    }
}

Show Order

get /api/orders/[id]

Get a specific order from the PPG database and return a JSON response. The order will be pulled either from the MasterOrder table or the HistoryMasterOrder table, depending on whether it's been picked.

Request with curl
curl -L 
-X GET '[Your IP]/api/orders/C1B2FB93-40A9-4B17-998B-DEA51CCE5C38' 
-H 'Content-Type: application/json' 
-H 'Authorization: Bearer [Your JWT Access Token]'
Example Response
{
    "order": {
        "warehouseName": "Warehouse",
        "Info5": null,
        "id": "C1B2FB93-40A9-4B17-998B-DEA51CCE5C38",
        "order_lines": [
            {
                "number": 1,
                "serialNumber": "8",
                "materialName": "S103",
                "quantity": 1.0,
                "quantityDeviated": 1.0,
                "id": "C528ABFC-A2E3-4C53-A487-04E66C5BB906",
                "quantityConfirmed": 0.0,
                "modifiedDate": "2021-11-15T20:06:51.363000",
                "quantityRequested": 0.0,
                "lot": null
            },
            {
                "number": 2,
                "serialNumber": "9",
                "materialName": "S103",
                "quantity": 1.0,
                "quantityDeviated": 1.0,
                "id": "7611E030-7B47-475C-AE09-4C4C5456BE57",
                "quantityConfirmed": 0.0,
                "modifiedDate": "2021-11-15T20:06:51.423000",
                "quantityRequested": 0.0,
                "lot": null
            },
            {
                "number": 3,
                "serialNumber": "10",
                "materialName": "S103",
                "quantity": 1.0,
                "quantityDeviated": 1.0,
                "id": "38DC788D-A46C-4163-B6DA-4D9F3B411B91",
                "quantityConfirmed": 0.0,
                "modifiedDate": "2021-11-15T20:06:51.510000",
                "quantityRequested": 0.0,
                "lot": null
            },
            {
                "number": 4,
                "serialNumber": "12",
                "materialName": "S103",
                "quantity": 1.0,
                "quantityDeviated": 1.0,
                "id": "238EEE37-9B6B-4204-97E8-F1635B4BD4D0",
                "quantityConfirmed": 0.0,
                "modifiedDate": "2021-11-15T20:06:51.577000",
                "quantityRequested": 0.0,
                "lot": null
            }
        ],
        "modifiedDate": "2021-11-15T20:06:51.363000",
        "handlingUnit": "Box 1",
        "ORDERISSUETO": null,
        "Info3": null,
        "orderType": 1,
        "ORDERNOTE": null,
        "ORDERFACILITY": null,
        "status": "queued",
        "hasStock": 1,
        "directionType": 1,
        "Info1": null,
        "ORDERINFO6": null,
        "Info2": null,
        "unit": null,
        "priority": 2,
        "storageUnits": [],
        "incompleteAllocations": 0,
        "Info4": null,
        "name": "Sample Put Order",
        "deadline": null
    }
}

Update Order

put /orders/[id]

Update an order and get a response. Each key/value is optional. Only keys sent will be updated, but an object is required to be sent.

Arguments

  • allocate boolean

    If true or false, this will either allocate or deallocate the order.

  • deadline dateTime

    Date by which the order must be completed.

  • countEmptyLocations boolean

    For count orders only. Determines if locations with that material at a quantity of 0 should be included in the count. If changed from "true" to "false", order will need to be reallocated.

  • directionType integer/string

    The type of order. Can use integer or string.

    Possible values:

    1 or "put"
    2 or "pick"
    3 or "return"
    4 or "transport"
    5 or "count"
    7 or "production"

  • handlingUnit string

    DEPRECATED.

  • Info1 string LIMIT: 50

    A generic field for custom use.

  • Info2 string LIMIT: 50

    A generic field for custom use.

  • Info3 string LIMIT: 50

    A generic field for custom use.

  • Info4 string LIMIT: 50

    A generic field for custom use.

  • Info5 string LIMIT: 50

    A generic field for custom use.

  • name string LIMIT: 50

    This updates the unique order name.

  • owner string LIMIT: 50

    Used in a transfer order. The owner will be replaced by the given recipient, which will be assigned as the new owner of the material during the put.

  • priority integer

    Order priority level.

    Possible values:

    1 = Low
    2 = Medium
    3 = High
    4 = Hot (if included)

  • recipient string LIMIT: 50

    Used in a transfer order. The recipient given will be assigned as the new owner of the material during the put.

  • unti string LIMIT: 50

    Used with batches.

  • [dynamicField] string LIMIT: 1999

    Any of the dynamic order fields from PowerPick. Requires ItemPath's Custom Fields app.

Request with curl
curl "http://[Your IP] /orders/[id]" \ -X put \ -H "Content-Type: application/json" \ -H "Authorization: Bearer [Your JWT Access Token]"
-d '{"allocate": "false", "handlingUnit": "Box 1"}'
Example Response
{
    "order": {
        "warehouseName": "Warehouse",
        "Info5": null,
        "id": "C1B2FB93-40A9-4B17-998B-DEA51CCE5C38",
        "order_lines": [
            {
                "number": 1,
                "serialNumber": "8",
                "materialName": "S103",
                "quantity": 1.0,
                "quantityDeviated": 1.0,
                "id": "C528ABFC-A2E3-4C53-A487-04E66C5BB906",
                "quantityConfirmed": 0.0,
                "modifiedDate": "2021-11-15T20:06:51.363000",
                "quantityRequested": 0.0,
                "lot": null
            },
            {
                "number": 2,
                "serialNumber": "9",
                "materialName": "S103",
                "quantity": 1.0,
                "quantityDeviated": 1.0,
                "id": "7611E030-7B47-475C-AE09-4C4C5456BE57",
                "quantityConfirmed": 0.0,
                "modifiedDate": "2021-11-15T20:06:51.423000",
                "quantityRequested": 0.0,
                "lot": null
            },
            {
                "number": 3,
                "serialNumber": "10",
                "materialName": "S103",
                "quantity": 1.0,
                "quantityDeviated": 1.0,
                "id": "38DC788D-A46C-4163-B6DA-4D9F3B411B91",
                "quantityConfirmed": 0.0,
                "modifiedDate": "2021-11-15T20:06:51.510000",
                "quantityRequested": 0.0,
                "lot": null
            },
            {
                "number": 4,
                "serialNumber": "12",
                "materialName": "S103",
                "quantity": 1.0,
                "quantityDeviated": 1.0,
                "id": "238EEE37-9B6B-4204-97E8-F1635B4BD4D0",
                "quantityConfirmed": 0.0,
                "modifiedDate": "2021-11-15T20:06:51.577000",
                "quantityRequested": 0.0,
                "lot": null
            }
        ],
        "modifiedDate": "2021-11-15T20:06:51.363000",
        "handlingUnit": "Box 1",
        "ORDERISSUETO": null,
        "Info3": null,
        "orderType": 1,
        "ORDERNOTE": null,
        "ORDERFACILITY": null,
        "status": "queued",
        "hasStock": 1,
        "directionType": 1,
        "Info1": null,
        "ORDERINFO6": null,
        "Info2": null,
        "unit": null,
        "priority": 2,
        "storageUnits": [],
        "incompleteAllocations": 0,
        "Info4": null,
        "name": "Sample Put Order",
        "deadline": null
    }
}

Delete Order

delete /api/orders/[id]/delete

Delete a specific order from the PPG database and return a JSON response. This will also delete the order lines associated with the order.

Request with curl
curl -L 
-X DELETE '[Your IP]/api/orders/C1B2FB93-40A9-4B17-998B-DEA51CCE5C38/delete' 
-H 'Content-Type: application/json' 
-H 'Authorization: Bearer [Your JWT Access Token]'
Example Response
{"deleted": "true"}