StockShortage event data
The stock shortage model is an object with following fields. CAS sends it whenever it finds insufficient stock while reserving stock for a customs shipment or processing a movement order. For a positive adjustment (ADJP), each line is an item for which no stock record was found.
| Property | Cardinality | Type | Description |
|---|---|---|---|
| id | 1x | string | A unique key that identifies the event |
| tenantId | 1x | string | Tenant ID of the tenant for which this event applies |
| plantId | 1x | string | Technical ID of the plant of the customs shipment's storage location. Empty for a movement order, or when that plant cannot be determined, so a subscription filtered on a plant does not receive those events |
| eventTime | 1x | timestamp | The exact time in UTC that the event occurred in CAS |
| eventType | 1x | string | Type of the event. StockShortage for this event |
| eventSubType | 1x | string | Subtype of the event: CustomsShipment or MovementOrder. See Notification events |
| data.externalReference | 1x | string | The external reference of the customs shipment or of the movement order |
| data.documentReference | 1x | string | The document reference of the movement order. Null for a customs shipment |
| data.movementOrderType | 1x | string | The movement order type, e.g. ADJN, DCSV, TRFR or ADJP. Null for a customs shipment |
| data.severity | 1x | string | Info: stock shortages are allowed, and the available quantities were reserved or handled. Warning: stock shortages are not allowed, and nothing was reserved or handled |
| data.isExciseRelated | 1x | boolean | True when any item in shortage is on the excise list |
| data.lines | 1..n | [object] | One line per item in shortage |
| data.lines[].itemReference | 1x | string | The external reference of the item |
| data.lines[].serialBatchReference | 1x | string | The serial batch reference |
| data.lines[].storageLocationReference | 1x | string | The reference of the storage location of the item. Empty when the item's lines on one movement order are in several storage locations |
| data.lines[].sequenceNumber | 1x | int | The sequence number of the declaration item. Null for a movement order |
| data.lines[].requestedQuantity | 1x | decimal | The quantity requested |
| data.lines[].availableQuantity | 1x | decimal | The quantity in stock. This is the quantity reserved, unless the severity is Warning |
| data.lines[].missingQuantity | 1x | decimal | The requested quantity minus the available quantity |
| data.lines[].unitOfMeasure | 1x | string | The unit of measure of the quantities |
Example
{
"id": "434513a3-0305-4639-baf6-c85235b965b3",
"tenantId": "yourTenantId",
"plantId": "technicalPlantId",
"eventTime": "2026-11-03T18:41:00.9584103Z",
"eventType": "StockShortage",
"eventSubType": "CustomsShipment",
"data": {
"externalReference": "yourExternalReference",
"documentReference": null,
"movementOrderType": null,
"severity": "Info",
"isExciseRelated": false,
"lines": [
{
"itemReference": "ITEM_01",
"serialBatchReference": "BATCH_01",
"storageLocationReference": "SL_01",
"sequenceNumber": 1,
"requestedQuantity": 10,
"availableQuantity": 6,
"missingQuantity": 4,
"unitOfMeasure": "KGM"
}
]
}
}