Order webhooks
Types of triggers
Webhooks can be triggered on the following events related to orders.
Order is picked
This webhook will fire when an order's status is changed to Picked or above (400 or above). There must be at least one picked item on the order as well.
Order status is changed
This webhook will fire when an order's status is changed. You can select the statuses you want the webhook to trigger for, e.g. if you want it be triggered whenever an order's status goes to Sent, or when it goes from Open to Released, and so on.
Order is created
This webhook will fire when an order is created.
Payload
Example
When the webhook is triggered, the following payload will be delivered to the webhook endpoint.
{
"webhookOrdersId": 0,
"webhookEventId": 0,
"system": "string",
"timestamp": "2023-01-01T12:00:00.0000000",
"orderId": 0,
"orderNumber": "string",
"goodsOwnerId": 0,
"path": "string",
"byUser": {
"userId": 0
},
"byComputer": {
"computerId": 0,
"computerName": "string"
},
"orderStatus": {
"number": 0
},
"currentShipmentId": null,
"webhookTemplate": "string",
"goodsOwnerName": "string",
"goodsOwnerClasses": [
{
"id": 0,
"code": "string",
"name": "string"
},
{
"id": 0,
"code": "string",
"name": "string"
}
],
"tracking": [
{
"trackingUrl": "string",
"waybill": "string",
"isReturn": false
},
{
"trackingUrl": "string",
"waybill": "string",
"isReturn": false
}
],
"parcels": [
{
"id": 0,
"parcelNumber": "string",
"isReturnParcel": false,
"tracking": {
"trackingUrl": "string"
}
},
{
"id": 0,
"parcelNumber": "string",
"isReturnParcel": false,
"tracking": {
"trackingUrl": "string"
}
}
]
}
Specification
WebhookOrderPayload |
webhookOrdersId | int | Internal ID for the webhook. |
webhookEventId | int | Internal ID for this particular event. |
system | string | The name of the Ongoing WMS instance where the event happened. |
timestamp | string | When the event happened. |
orderId | int | Order ID. |
orderNumber | string | Order number. |
goodsOwnerId | int | The Ongoing WMS system id for the goods owner. |
path | string | REST API path to the resource. |
byUser | ByUserInfo | An element of type ByUserInfo. |
byComputer | ByComputerInfo | An element of type ByComputerInfo. |
orderStatus | OrderStatus | An element of type OrderStatus. |
currentShipmentId | int (nullable) | If the order has been placed on a shipment, this contains the shipment ID. |
webhookTemplate | string | The name of the webhook type. |
goodsOwnerName | string | |
goodsOwnerClasses | GoodsOwnerClass[] | A list of GoodsOwnerClass. |
tracking | OrderTracking[] | A list of OrderTracking. |
parcels | Parcel[] | A list of Parcel. |
ByUserInfo |
userId | int | Ongoing WMS user ID of the user who performed the action. |
ByComputerInfo |
computerId | int | Ongoing WMS workstation ID of the workstation which the user was logged in to. |
computerName | string | Ongoing WMS workstation name of the workstation which the user was logged in to. |
OrderStatus |
number | int | Order status ID. |
GoodsOwnerClass |
id | int | |
code | string | |
name | string | |
OrderTracking |
trackingUrl | string | |
waybill | string | |
isReturn | boolean | |
Parcel |
id | int | |
parcelNumber | string | |
isReturnParcel | boolean | |
tracking | ParcelTracking | An element of type ParcelTracking. |
ParcelTracking |
trackingUrl | string | |