Pick Pack

This is the documentation for version v1 of the API. Last update on Jul 1, 2021.

Base URL
https://api.emporix.io/pick-pack

Assignees

The caller must have the `pickpack

The caller must have the pickpack.pickpack_manage scope assigned.

Add assignee to specific order.

Please note, that if the order has packingStatus set to CANCELLED, it is not possible to modify assignee for this particular order.

Headers
  • authorization Required / string

    Bearer token

Path parameters
  • tenant Required / string

    The tenant that the caller is acting upon.

    Please note that this value is always lowercase.

  • orderId Required / string

    site code for tenant

Query parameters
  • siteCode Required / string

    site code for tenant

Responses
  • 200

    The request has succeeded.

  • 404 object

    Not found

    • status Required / integer

      original HTTP error code, should be consistent with the response HTTP code

      Minimum value is 100, maximum value is 599.

    • type Required / string

      classification of the error type, lower case with underscore eg validation_failure

    • message string

      Order not exist

    • moreInfo string(uri)

      link to documentation to investigate further and finding support

    • details array[object]

      list of problems causing this error

      • field string

        a bean notation expression specifying the element in request data causing the error, eg product.variants[3].name, this can be empty if violation was not field specific

      • type Required / string

        classification of the error detail type, lower case with underscore eg missing_value, this value must be always interpreted in context of the general error type.

      • message string

        The order must exist to be assigned to it

      • moreInfo string(uri)

        link to documentation to investigate further and finding support for error detail

  • 409 object

    Conflict

    • status Required / integer

      original HTTP error code, should be consistent with the response HTTP code

      Minimum value is 100, maximum value is 599.

    • type Required / string

      classification of the error type, lower case with underscore eg validation_failure

    • message string

      Only one packer can be assigned to an order

    • moreInfo string(uri)

      link to documentation to investigate further and finding support

    • details array[object]

      list of problems causing this error

      • field string

        a bean notation expression specifying the element in request data causing the error, eg product.variants[3].name, this can be empty if violation was not field specific

      • type Required / string

        classification of the error detail type, lower case with underscore eg missing_value, this value must be always interpreted in context of the general error type.

      • message string

        Only one packer can be assigned to an order

      • moreInfo string(uri)

        link to documentation to investigate further and finding support for error detail

POST /{tenant}/orders/{orderId}/assignees
$ curl \
 -X POST https://api.emporix.io/pick-pack/{tenant}/orders/{orderId}/assignees?siteCode=string \
 -H "Content-Type: application/json" \
 -H "authorization: string" \
 -d '{"id":"2","firstName":"a","lastName":"b","siteCode":"main"}'
Request payload example
# Headers
authorization: string
Response example (200)
{
  "message": "Successfully added assignee",
  "code": 200
}
Response example (404)
{
  "status": 404,
  "message": "Order with id: <id> and siteCode: <siteCode> not found!",
  "type": "validation_violation",
  "details": [
    {
      "field": "tenant",
      "message": "size must be between 3 and 16",
      "type": "invalid_header"
    }
  ]
}
Response example (409)
{
  "status": 409,
  "message": "Order with id: <id> and siteCode: <siteCode> has already assignee or order not found!",
  "type": "validation_violation",
  "details": [
    {
      "field": "tenant",
      "message": "size must be between 3 and 16",
      "type": "invalid_header"
    }
  ]
}

Events

The caller must have the `pickpack

The caller must have the pickpack.pickpack_view scope assigned.

Get events by timestamp

Headers
  • authorization Required / string

    Bearer token

Path parameters
  • tenant Required / string

    The tenant that the caller is acting upon.

    Please note that this value is always lowercase.

Query parameters
  • timestamp string

    Date after which we want to filter the events.

  • pageNumber integer

    Number of the page.

  • pageSize integer

    Size of the page.

Responses
  • 200

    The request has succeeded.

  • 400

    Cannot parse queryParam timestamp to Date.

GET /{tenant}/events
$ curl \
 -X GET https://api.emporix.io/pick-pack/{tenant}/events \
 -H "authorization: string"
Response example (200)
[
  {
    "eventId": "eventid156",
    "productId": "5c334cb0a9812100098ffb6c",
    "orderCycle": "test-cycle",
    "orderNumber": "B7013638",
    "timestamp": "2020-09-14T13:35:18.333+00:00",
    "packedAmount": 2,
    "user": "C1414948570",
    "site": "main",
    "bookProduct": true
  },
  {
    "eventId": "eventid157",
    "productId": "5c334cb0a9812100098ffb6c",
    "orderCycle": "test-cycle",
    "orderNumber": "B7013638",
    "timestamp": "2020-09-14T13:35:18.333+00:00",
    "packedAmount": -2,
    "user": 1234,
    "site": "main"
  },
  {
    "eventId": "eventid158",
    "productId": "5c334cb0a9812100098ffb6c",
    "orderCycle": "test-cycle",
    "orderNumber": "B7013638",
    "timestamp": "2020-09-14T13:35:18.333+00:00",
    "packedAmount": 1000,
    "user": 1234,
    "site": "main",
    "bookProduct": false
  },
  {
    "eventId": "eventid159",
    "productId": "5c334cb0a9812100098ffb6c",
    "orderCycle": "test-cycle",
    "orderNumber": "B7013638",
    "timestamp": "2020-09-14T13:35:18.333+00:00",
    "packedAmount": -500,
    "user": 1234,
    "site": "main"
  },
  {
    "eventId": "eventid160",
    "productId": "5c334cb0a9812100098ffb6c",
    "orderCycle": "test-cycle",
    "orderNumber": "B7013638",
    "timestamp": "2020-09-14T13:35:18.333+00:00",
    "packedAmount": 3000,
    "user": 1234,
    "site": "main"
  },
  {
    "eventId": "eventid161",
    "productId": "5c334cb0a9812100098ffb6c",
    "orderCycle": "test-cycle",
    "orderNumber": "B7013638",
    "timestamp": "2020-09-14T13:35:18.333+00:00",
    "packedAmount": -10000,
    "user": 1234,
    "site": "main"
  },
  {
    "eventId": "eventid162",
    "productId": "5c334cb0a9812100098ffb6c",
    "orderCycle": "test-cycle",
    "orderNumber": "B7013638",
    "timestamp": "2020-09-14T13:35:18.333+00:00",
    "pickedAmount": 1000,
    "user": 1234,
    "site": "main"
  },
  {
    "eventId": "eventid163",
    "productId": "5c334cb0a9812100098ffb6c",
    "orderCycle": "test-cycle",
    "orderNumber": "B7013638",
    "timestamp": "2020-09-14T13:35:18.333+00:00",
    "pickedAmount": -500,
    "user": 1234,
    "site": "main"
  },
  {
    "eventId": "eventid164",
    "productId": "5c334cb0a9812100098ffb6c",
    "orderCycle": "test-cycle",
    "orderNumber": "B7013638",
    "timestamp": "2020-09-14T13:35:18.333+00:00",
    "pickedAmount": -600,
    "user": 1234,
    "site": "main"
  },
  {
    "eventId": "eventid169",
    "productId": "4",
    "orderCycle": "test-cycle",
    "orderNumber": "3",
    "timestamp": "2020-09-14T13:35:18.333+00:00",
    "pickedAmount": -600,
    "user": 1234,
    "site": "main"
  }
]
Response example (400)
{
  "message": "Cannot parse String: 2020-09-14T13:00:00.0+0200 to Date, correct format is: yyyy-MM-dd'T'HH:mm:ssZ",
  "code": 400
}

The caller must have the `pickpack

The caller must have the pickpack.pickpack_manage scope assigned.

Creates packing event.

Please note, that if the order has packingStatus set to CANCELLED, it is not possible to create any new packing events for this particular order.

Headers
  • authorization Required / string

    Bearer token

  • saas-token Required / string

    Token provided by emporix system. Used to identify logged in users. This token has an expiery date and is signed with a passphrse.

Path parameters
  • tenant Required / string

    The tenant that the caller is acting upon.

    Please note that this value is always lowercase.

Body
  • eventId string
  • orderCycle string
  • pickedAmount number
  • packedAmount number
  • canceledAmount number
  • supplierId string
  • unit string
  • timestamp string
  • siteCode string
  • bookProduct boolean
Responses
  • 200

    The event has been created.

  • 409

    The event with given eventId already exists.

  • 400
    • User with userId is not assigned to the order with orderId!.
    • Order with orderId has invalid status to be packed!.
POST /{tenant}/events
$ curl \
 -X POST https://api.emporix.io/pick-pack/{tenant}/events \
 -H "Content-Type: application/json" \
 -H "authorization: string" \
 -H "saas-token: string" \
 -d '{"eventId":"eventid132,","orderNumber":"B7013638,","productId":"5c334cb0a9812100098ffb6c,","orderCycle":"abc,","pickedAmount":6,"packedAmount":6,"canceledAmount":6,"supplierId":"supplier1,","unit":"H87,","timestamp":"2020-09-14T13:35:18.333Z,","siteCode":8000,"bookProduct":true}'
Request payload example
# Headers
authorization: string
saas-token: string

# Payload
{
  "eventId": "eventid132,",
  "orderNumber": "B7013638,",
  "productId": "5c334cb0a9812100098ffb6c,",
  "orderCycle": "abc,",
  "pickedAmount": 6,
  "packedAmount": 6,
  "canceledAmount": 6,
  "supplierId": "supplier1,",
  "unit": "H87,",
  "timestamp": "2020-09-14T13:35:18.333Z,",
  "siteCode": 8000,
  "bookProduct": true
}
Response example (409)
{
  "message": "Event with id: [ eventid132 ] is already created",
  "code": 409
}
Response example (400)
[
  {
    "message": "User with userId: [ userId ] is not assigned to order with orderId: [ orderId ] or given order not exist",
    "code": 400
  },
  {
    "message": "Order with id: [ orderId ] has invalid status to be packed",
    "code": 400
  }
]

Finish

The caller must have the `pickpack

The caller must have the pickpack.pickpack_manage scope assigned.
This endpoint finishes the provided order by recalculationg the current state, changing the order status to 'packed', deleting all assignees and sending the order confirmation email

Headers
  • authorization Required / string

    Bearer token

  • saas-token Required / string

    Token provided by emporix system. Used to identify logged in users. This token has an expiery date and is signed with a passphrse.

Path parameters
  • tenant Required / string

    The tenant that the caller is acting upon.

    Please note that this value is always lowercase.

  • orderId Required / string
Responses
  • 200

    Status has been successfully changed to 'packed'

  • 400

    This status will be returned in case a business exception occurs

  • 500

    This status will be returned in case a technical exception occurs

POST /{tenant}/orders/{orderId}/finish
$ curl \
 -X POST https://api.emporix.io/pick-pack/{tenant}/orders/{orderId}/finish \
 -H "authorization: string" \
 -H "saas-token: string"
Response example (200)
{
  "message": "Status has been successfully changed to 'packed'",
  "code": 200
}
Response example (400)
{
  "message": "User with userId: C1414948570 is not assigned to order with orderId: 3443 or given order not exist",
  "code": 400
}
Response example (500)
{
  "message": "Something went wrong or service is currently unavailable. Please contact with support.",
  "code": 500
}

Jobs

The caller must have the `pickpack

The caller must have the pickpack.pickpack_manage scope assigned.

Triggers orders recalculation for given order list

Headers
  • authorization Required / string

    Bearer token

Path parameters
  • tenant Required / string

    The tenant that the caller is acting upon.

    Please note that this value is always lowercase.

Body
  • jobType string
  • orderIds array[string]
Responses
  • 200

    New order recalculation job has been created.

  • 409

    The event with given jobId already exists.

  • 400

    Bad request. Wrong order request body!

POST /{tenant}/jobs/recalculations
$ curl \
 -X POST https://api.emporix.io/pick-pack/{tenant}/jobs/recalculations \
 -H "Content-Type: application/json" \
 -H "authorization: string" \
 -d '{"jobType":"MANUAL","orderIds":["03DV9N3R","5XS34VOB","JGPZWWLA","JGPZWWLA","09FFWHA2","1B70WHY7"]}'
Request payload example
# Headers
authorization: string

# Payload
{
  "jobType": "MANUAL",
  "orderIds": [
    "03DV9N3R",
    "5XS34VOB",
    "JGPZWWLA",
    "JGPZWWLA",
    "09FFWHA2",
    "1B70WHY7"
  ]
}
Response example (200)
{
  "jobId": "6040e0d8623b310af7bc84ec"
}
Response example (409)
{
  "message": "Processing for given order are still in progress for tenant {tenant} and orderIds: {orderId}",
  "code": 409
}
Response example (400)
{
  "message": "Cannot create job for tenant: %s, because orderIds is a empty set!",
  "code": 400
}

Ordercycles

The caller must have the `pickpack

The caller must have the pickpack.pickpack_view scope assigned.

Get OrderCycles of orders from now

Headers
  • authorization Required / string

    Bearer token

Path parameters
  • tenant Required / string

    The tenant that the caller is acting upon.

    Please note that this value is always lowercase.

Query parameters
  • siteCode Required / string

    site code for the tenant

Responses
  • 200

    The request has succeeded.

GET /{tenant}/orderCycles
$ curl \
 -X GET https://api.emporix.io/pick-pack/{tenant}/orderCycles?siteCode=string \
 -H "authorization: string"
Response example (200)
[
  "2020-11-13",
  "2020-11-14",
  "2020-11-15"
]

Orders

The caller must have the `pickpack

The caller must have the pickpack.pickpack_view scope assigned.

Get packlist by deliveryDate.

Please note, that if the order has packingStatus set to CANCELLED, it will not be returned.

Headers
  • authorization Required / string

    Bearer token

Path parameters
  • tenant Required / string

    The tenant that the caller is acting upon.

    Please note that this value is always lowercase.

Query parameters
  • siteCode Required / string

    site code for the tenant

  • deliveryDate Required / string

    Date after which we want to filter the orders.

Responses
  • 200

    The request has succeeded.

GET /{tenant}/orders
$ curl \
 -X GET https://api.emporix.io/pick-pack/{tenant}/orders?siteCode=string&deliveryDate=string \
 -H "authorization: string"
Response example (200)
[
  {
    "orderId": "01LIWJ40",
    "customerName": "John Smith",
    "packingStatus": "initial",
    "productsTotal": 3000,
    "productsPacked": 654,
    "assignees": [
      {
        "firstName": "a",
        "lastName": "b",
        "id": "2"
      }
    ],
    "packagingProducts": [
      {
        "imageUrl": "https://res.cloudinary.com/saas-ag/image/upload/v1546865144/saastest2/products/7ba519d5-458e-47b0-9622-01a34012de6d.jpg",
        "productName": "Verpackungs Box",
        "entryId": "packaging-1",
        "packedCount": 0
      },
      {
        "productName": "Kühlbox",
        "entryId": "packaging-2",
        "packedCount": 0
      }
    ]
  },
  {
    "orderId": "1SWES7IS",
    "customerName": "John Smith",
    "packingStatus": "initial",
    "productsTotal": 3000,
    "productsPacked": 2266,
    "packagingProducts": [
      {
        "imageUrl": "https://res.cloudinary.com/saas-ag/image/upload/v1546865144/saastest2/products/7ba519d5-458e-47b0-9622-01a34012de6d.jpg",
        "productName": "Verpackungs Box",
        "entryId": "packaging-1",
        "packedCount": 0
      },
      {
        "productName": "Kühlbox",
        "entryId": "packaging-2",
        "packedCount": 0
      }
    ]
  },
  {
    "orderId": "0OIANX16",
    "customerName": "John Smith",
    "packingStatus": "initial",
    "productsTotal": 3000,
    "productsPacked": 1519,
    "packagingProducts": [
      {
        "imageUrl": "https://res.cloudinary.com/saas-ag/image/upload/v1546865144/saastest2/products/7ba519d5-458e-47b0-9622-01a34012de6d.jpg",
        "productName": "Verpackungs Box",
        "entryId": "packaging-1",
        "packedCount": 0
      },
      {
        "productName": "Kühlbox",
        "entryId": "packaging-2",
        "packedCount": 0
      }
    ]
  }
]

Packaging

The caller must have the `pickpack

The caller must have the pickpack.pickpack_manage scope assigned.

Update packaging products in order

Headers
  • authorization Required / string

    Bearer token

  • saas-token Required / string

    Token provided by emporix system. Used to identify logged in users. This token has an expiery date and is signed with a passphrse.

Path parameters
  • tenant Required / string

    The tenant that the caller is acting upon.

    Please note that this value is always lowercase.

  • orderId Required / string

    Number of the packed order

Body
  • productId string
  • packedCount integer
Responses
  • 200

    The request has succeeded.

  • 400 object

    Not found

    • status Required / integer

      original HTTP error code, should be consistent with the response HTTP code

      Minimum value is 100, maximum value is 599.

    • type Required / string

      classification of the error type, lower case with underscore eg validation_failure

    • message string

      User is not assgined or order not exist

    • moreInfo string(uri)

      link to documentation to investigate further and finding support

    • details array[object]

      list of problems causing this error

      • field string

        a bean notation expression specifying the element in request data causing the error, eg product.variants[3].name, this can be empty if violation was not field specific

      • type Required / string

        classification of the error detail type, lower case with underscore eg missing_value, this value must be always interpreted in context of the general error type.

      • message string

        The order must exist to be assigned to it

      • moreInfo string(uri)

        link to documentation to investigate further and finding support for error detail

PUT /{tenant}/orders/{orderId}/packaging
$ curl \
 -X PUT https://api.emporix.io/pick-pack/{tenant}/orders/{orderId}/packaging \
 -H "Content-Type: application/json" \
 -H "authorization: string" \
 -H "saas-token: string" \
 -d '[{"entryId":"packaging-1","packedCount":3}]'
Request payload example
# Headers
authorization: string
saas-token: string

# Payload
[
  {
    "entryId": "packaging-1",
    "packedCount": 3
  }
]
Response example (200)
{
  "message": "Successfully update packing products for order with orderId: {orderId} and tenant: {tenant}",
  "code": 200
}
Response example (400)
{
  "status": 400,
  "message": "User with userId: {userId} is not assigned to order with orderId: {orderId} or given order not exist",
  "type": "validation_violation",
  "details": [
    {
      "field": "tenant",
      "message": "size must be between 1 and 16",
      "type": "invalid_header"
    }
  ]
}

Root

The caller must have the `pickpack

The caller must have the pickpack.pickpack_view scope assigned.

Get order by Id

Headers
  • authorization Required / string

    Bearer token

Path parameters
  • tenant Required / string

    The tenant that the caller is acting upon.

    Please note that this value is always lowercase.

  • orderId Required / string

    Order id.

Responses
  • 200

    The request has succeeded.

  • 404 object

    Not found

    • status Required / integer

      original HTTP error code, should be consistent with the response HTTP code

      Minimum value is 100, maximum value is 599.

    • type Required / string

      classification of the error type, lower case with underscore eg validation_failure

    • message string

      Order not exist

    • moreInfo string(uri)

      link to documentation to investigate further and finding support

    • details array[object]

      list of problems causing this error

      • field string

        a bean notation expression specifying the element in request data causing the error, eg product.variants[3].name, this can be empty if violation was not field specific

      • type Required / string

        classification of the error detail type, lower case with underscore eg missing_value, this value must be always interpreted in context of the general error type.

      • message string

        Order with orderId: {orderId} not found.

      • moreInfo string(uri)

        link to documentation to investigate further and finding support for error detail

GET /{tenant}/orders/{orderId}
$ curl \
 -X GET https://api.emporix.io/pick-pack/{tenant}/orders/{orderId} \
 -H "authorization: string"
Response example (200)
{
  "id": "04OBTM5N",
  "orderDetails": {
    "orderTotal": 41.12,
    "valueOfGoods": 34.34,
    "deposit": 2.88,
    "coupons": 0,
    "currency": "USD"
  },
  "entries": [
    {
      "productId": "5c2e8c19a46b0e0008491ac0",
      "productName": "Schönbuch Braumanufaktur Amber Ale Six Pack",
      "price": 5.99,
      "imageUrl": "https://res.cloudinary.com/saas-ag/image/upload/v1546554396/saasdev2/products/0adb900a-b5c5-4bf9-974d-27a5844e4f21.jpg",
      "unitPricingMeasure": {
        "unitCode": "MLT",
        "value": "1980"
      },
      "packedCount": 1,
      "canceledCount": 0
    },
    {
      "productId": "5c2e8427a46b0e000849199c",
      "productName": "Schönbuch Braumanufaktur Doppelbock Six Pack",
      "price": 6.49,
      "imageUrl": "https://res.cloudinary.com/saas-ag/image/upload/v1546552364/saasdev2/products/417af5ac-a53c-4e36-9694-e4419f700bdd.jpg",
      "unitPricingMeasure": {
        "unitCode": "MLT",
        "value": "1980"
      },
      "packedCount": 1,
      "canceledCount": 0
    },
    {
      "productId": "5c2e835aa46b0e000849197c",
      "productName": "Schönbuch Braumanufaktur Horst Hell Six Pack",
      "price": 5.29,
      "imageUrl": "https://res.cloudinary.com/saas-ag/image/upload/v1546552158/saasdev2/products/01aa95b1-4feb-4a60-9870-499203913a62.jpg",
      "unitPricingMeasure": {
        "unitCode": "MLT",
        "value": "1980"
      },
      "packedCount": 1,
      "canceledCount": 0
    },
    {
      "productId": "5c2e8422a46b0e000849199b",
      "productName": "Schönbuch Braumanufaktur Pils Six Pack",
      "price": 5.29,
      "imageUrl": "https://res.cloudinary.com/saas-ag/image/upload/v1546552357/saasdev2/products/269d54a8-8e6b-43a9-80a7-5d6ea992bb2b.jpg",
      "unitPricingMeasure": {
        "unitCode": "MLT",
        "value": "1980"
      },
      "packedCount": 1,
      "canceledCount": 0
    },
    {
      "productId": "5c2e8544a46b0e00084919c0",
      "productName": "Schönbuch Braumanufaktur Unfiltered Beer Six Pack",
      "price": 5.29,
      "imageUrl": "https://res.cloudinary.com/saas-ag/image/upload/v1546552648/saasdev2/products/55d752e5-80b9-437a-a1fd-591788664479.jpg",
      "unitPricingMeasure": {
        "unitCode": "MLT",
        "value": "1980"
      },
      "packedCount": 1,
      "canceledCount": 0
    },
    {
      "productId": "5c2e86b0a46b0e00084919f0",
      "productName": "Schönbuch Pale Ale Six Pack",
      "price": 5.99,
      "imageUrl": "https://res.cloudinary.com/saas-ag/image/upload/v1546553012/saasdev2/products/ef5a0c0a-5ef5-4b93-bffa-6404ce1a919d.jpg",
      "unitPricingMeasure": {
        "unitCode": "MLT",
        "value": "1980"
      },
      "packedCount": 1,
      "canceledCount": 0
    }
  ],
  "packagingProducts": [
    {
      "imageUrl": "https://res.cloudinary.com/saas-ag/image/upload/v1546865144/saastest2/products/7ba519d5-458e-47b0-9622-01a34012de6d.jpg",
      "productName": "Verpackungs Box",
      "entryId": "packaging-1",
      "packedCount": 0
    },
    {
      "productName": "Kühlbox",
      "entryId": "packaging-2",
      "packedCount": 0
    }
  ],
  "customer": {
    "id": "C5618042673",
    "title": "MRS",
    "customerName": "Eni Kercs",
    "email": "e.kercsula@emporix.com",
    "phoneNumber": "123456789"
  },
  "delivery": {
    "deliveryTime": {
      "deliveryDate": "2019-05-16",
      "deliveryTimeFrom": "12:00:00",
      "deliveryTimeTo": "23:00:00"
    },
    "deliveryAddress": {
      "title": "MRS",
      "contactName": "Eni Kercs",
      "companyName": null,
      "street": "5th Avenue",
      "streetNumber": "13",
      "streetAppendix": null,
      "zip": "11211",
      "city": "NYC Williamsburg",
      "country": "United States"
    },
    "deliveryCost": {
      "amount": 3.9,
      "currency": "USD"
    },
    "deliveryOption": {
      "packaging": "Paper",
      "replacement": true,
      "pickup": false
    }
  },
  "payment": {
    "invoiceNumber": "GCI191232",
    "invoiceAddress": {
      "title": "MRS",
      "contactName": "Eni Kercs",
      "companyName": null,
      "street": "5th Avenue",
      "streetNumber": "13",
      "streetAppendix": null,
      "zip": "11211",
      "city": "NYC Williamsburg",
      "country": "United States"
    },
    "methods": [
      {
        "method": "paymentByDebit"
      }
    ]
  },
  "statusChanges": [
    {
      "status": "initial",
      "dateChange": "2020-09-07T07:02:57.334312",
      "assignee": {
        "firstName": "Ruben",
        "lastName": "McKenzie"
      }
    }
  ]
}
Response example (404)
{
  "status": 404,
  "message": "Order with orderId: {orderId} not found.",
  "type": "validation_violation",
  "details": [
    {
      "field": "tenant",
      "message": "size must be between 3 and 16",
      "type": "invalid_header"
    }
  ]
}

The caller must have the `pickpack

The caller must have the pickpack.pickpack_manage scope assigned.

Change pick-pack order status.

Please note, that if the order has packingStatus set to CANCELLED, it is not possible to do any further operations on this particular order.

Headers
  • authorization Required / string

    Bearer token

  • saas-token Required / string

    Token provided by emporix system. Used to identify logged in users. This token has an expiery date and is signed with a passphrse.

Path parameters
  • tenant Required / string

    The tenant that the caller is acting upon.

    Please note that this value is always lowercase.

  • orderId Required / string
Body
  • packingStatus string

    Values are INITIAL, IN_PROGRESS, PRE_PACKED, PACKED, and CANCELLED.

Responses
  • 200

    The request has succeeded.

  • 400

    This status will be returned in case a business exception occurs

  • 500

    This status will be returned in case a technical exception occurs

PATCH /{tenant}/orders/{orderId}
$ curl \
 -X PATCH https://api.emporix.io/pick-pack/{tenant}/orders/{orderId} \
 -H "Content-Type: application/json" \
 -H "authorization: string" \
 -H "saas-token: string" \
 -d '{"packingStatus":"IN_PROGRESS"}'
Request payload example
# Headers
authorization: string
saas-token: string

# Payload
{
  "packingStatus": "IN_PROGRESS"
}
Response example (200)
{
  "message": "Status has been successfully changed",
  "code": 200
}
Response example (400)
{
  "message": "User with userId: C1414948570 is not assigned to order with orderId: 3443 or given order not exist",
  "code": 400
}
Response example (500)
{
  "message": "Something went wrong or service is currently unavailable. Please contact with support.",
  "code": 500
}

The caller must have the `pickpack

The caller must have the pickpack.pickpack_manage scope assigned.

Delete assignee from specific order.

Path parameters
  • tenant Required / string

    Stands for the "project" that requests this resource. Must match the "project" that is associated with the access token in the Authorization header.

  • orderId Required / string

    Number of the packed order

  • assigneeId Required / string

    assignee which will be removed from order

Responses
  • 204

    The request has succeeded.

DELETE /{tenant}/orders/{orderId}/assignees/{assigneeId}
$ curl \
 -X DELETE https://api.emporix.io/pick-pack/{tenant}/orders/{orderId}/assignees/{assigneeId}
Response example (204)
NO_CONTENT

The caller must have the `pickpack

The caller must have the pickpack.pickpack_view scope assigned.

Get jobs by jobId

Headers
  • authorization Required / string

    Bearer token

Path parameters
  • tenant Required / string

    The tenant that the caller is acting upon.

    Please note that this value is always lowercase.

  • jobId Required / string

    jobId of requested order recalculation job

Responses
  • 200

    The request has succeeded.

  • 404

    Job with jobId not found!

GET /{tenant}/jobs/recalculations/{jobId}
$ curl \
 -X GET https://api.emporix.io/pick-pack/{tenant}/jobs/recalculations/{jobId} \
 -H "authorization: string"
Response example (200)
{
  "_id": {
    "$oid": "604733b4623b310af7bc8518"
  },
  "jobStatus": "DONE",
  "orders": [
    {
      "orderId": "RG679IXM",
      "orderStatus": "SUCCESS",
      "message": "Successfully processed Order: RG679IXM"
    }
  ],
  "startedAt": {
    "$date": "2021-03-04T13:45:00.883Z"
  },
  "finishedAt": {
    "$date": "2021-03-04T13:46:01.075Z"
  }
}
Response example (404)
{
  "message": "Job with jobId {jobId} for tenant {tenant} not found",
  "code": 404
}