New event formats
Sterling Intelligent Promising introduces a new event format for inventory service. Going forward, any new events are delivered in the new format.
Change events
| Event ID in Inventory Visibility | Event code in payload |
|---|---|
|
|
| supplyChange.v2 | supplyChange.v2 |
| productAvailability.v2 | productAvailability.v2 |
| availableSupplyChange.v2 | availableSupplyChange.v2 |
| dgAvailabilityChange.v2 | dgAvailabilityChange.v2 |
| Demand.Change | demandChange |
Snapshot events
| Event ID in Inventory Visibility | Event code in payload |
|---|---|
| productAvailabilitySnapshot.v2 | productAvailabilitySnapshot.v2 |
| dgAvailabilitySnapshot.v2 | dgAvailabilitySnapshot.v2 |
| demandSnapshot | demandSnapshot |
| supplySnapshot | supplySnapshot |
Supply.Change- When the supply changes for an item, the
Supply.Changeevent is triggered. The code for this event issupplyChange.The following sample JSON is an example of a publishedSupply.Changeevent.
The{ "eventbatch":[ { "channel":"Order Management", "identifiers":[], "events":[ { "code": "supplyChange", "timestamp": "2020-01-18T06:00:00.021Z", "attributes": [ { "name":"tenantId", "type":"String", "value":"tenant1" }, { "name":"productID", "type":"String", "value":"SKU1024" }, { "name":"unitOfMeasure", "type":"String", "value":"EACH" }, { "name":"productClass", "type":"String", "value":"NEW" }, { "name":"shipNode", "type":"String", "value":"Matrix-Store-001" }, { "name":"shipByDate", "type":"dateTime", "value":"2500-01-01T00:00:00.000Z" }, { "name":"lineReference", "type":"String", "value":"" }, { "name":"reference", "type":"String", "value":"" }, { "name":"referenceType", "type":"String", "value":"" }, { "name":"segment", "type":"String", "value":"" }, { "name":"segmentType", "type":"String", "value":"" }, { "name":"quantity", "type":"Number", "value":"1.0" }, { "name":"changedQuantity", "type":"Number", "value":"1.0" }, { "name":"type", "type":"String", "value":"ONHAND_BACKROOM_01" }, { "name":"baseType", "type":"String", "value":"ONHAND" }, { "name":"tagNumber", "type":"String", "value":"|||" }, { "name":"updatedTs", "type":"dateTime", "value":"IGNORE_VALUE" }, { "name":"eta", "type":"dateTime", "value":"1900-01-01T00:00:00.000Z" }, { "name":"adjustmentReason", "type":"String", "value":"ADJUSTMENT"}, ] }, { "code":"supplyChange", "timestamp":"2020-01-03T15:48:02Z", "attributes":[ { "name":"tenantId", "value":"tenant1", "type":"String"}, { "name":"productID", "value":"SKU1024", "type":"String"}, { "name":"unitOfMeasure", "value":"EACH", "type":"String"}, { "name":"productClass", "value":"NEW", "type":"String"}, { "name":"lineReference", "value":" ", "type":"String"}, { "name":"shipNode", "value":"Matrix-Store-002", "type":"String"}, { "name":"shipByDate", "value":"2500-01-01T00:00:00Z", "type":"dateTime"}, { "name":"reference", "value":" ", "type":"String"}, { "name":"referenceType", "value":" ", "type":"String"}, { "name":"quantity", "value":"200.0", "type":"Number"}, { "name":"segment", "value":" ", "type":"String"}, { "name":"segmentType", "value":" ", "type":"String"}, { "name":"type", "type":"String", "value":"ONHAND_BACKROOM_01" }, { "name":"baseType", "type":"String", "value":"ONHAND" }, { "name":"tagNumber", "type":"String", "value":"|||" }, { "name":"updatedTs", "value":"2020-01-03T15:47:48Z", "type":"dateTime"}, { "name":"eta", "value":"1900-01-01T00:00:00Z", "type":"dateTime"}, { "name":"adjustmentReason", "type":"String", "value":"ADJUSTMENT"}, ]} ] }] }updatedTsfield indicates the time when the database was updated for this supply. If no database record is present, then it is null during theforcePublish. By default when a supply sync is performed, the supply change event is published only for those records that must be upserted as part of the supply sync. However, whenforcePublishis passed as true in a supply sync, an event is published for every supply record that is part of supply sync. This, in turn, publishes node and network availability change events as well, regardless of change in availability due to incoming supply record. If a supply record is not present in the system and is ignored as part of the sync process, thenupdatedTsis null for this record's event.Note: This parameter is applicable inproductAvailability.v2,availableSupplyChange.v2,dgAvailabilityChange.v2.
supplyChange.v2- When the supply changes for an item, the
supplyChange.v2event is triggered. The code for this event issupplyChange.v2.The following sample JSON is an example of a publishedsupplyChange.v2event.
The{ "type": "supplyChange.v2", "datacontenttype": "application/json", "id": "2a8d36a3-485b-3fc0-bd15-d530625a6ec5", "specversion": "1.0", "time": "2023-08-30T10:20:31.102Z", "data": { "tenantId": "tenant1", "itemId": "SKU1024", "unitOfMeasure": "EACH", "productClass": "NEW", "shipNode": "Matrix-Store-001" "shipByDate": "2500-01-01T00:00:00.000Z", "lineReference":null, "reference":null, "referenceType":null, "segment": null, "segmentType": null, "quantity": 1, "changedQuantity": 1, "customAttributes" : [ { "double" : 10.1, "key" : "futureQuantity" }, { "key" : "adjustmentReasonText", "string" : "returnDamaged" }, { "date" : "2023-01-01T00:00:00.000Z", "key" : "manufacturingDate" }], "type": "ONHAND_BACKROOM_01", "baseType": "ONHAND", "tagNumber": "|||", "updatedTs": "2023-08-30T10:20:31.102Z", "eta": "1900-01-01T00:00:00.000Z", "adjustmentReason": "ADJUSTMENT", } }updatedTsfield indicates the time when the database was updated for this supply. If no database record is present, then it is null during theforcePublish. By default when a supply sync is performed, the supply change event is published only for those records that must be upserted as part of the supply sync. However, whenforcePublishis passed as true in a supply sync, an event is published for every supply record that is part of supply sync. This, in turn, publishes node and network availability change events as well, regardless of change in availability due to incoming supply record. If a supply record is not present in the system and is ignored as part of the sync process, thenupdatedTsis null for this record's event.
productAvailability.v2- Node availability in
productAvailability.v2events is published per item-node basis whenever there is a change in available quantity. The change may be triggered in case of updates in supply, demand, safety stock, fulfillment option, and capacity levels.The following sample JSON is an example of a published event for SHP and PICK delivery method.- SHP delivery method
{ "type": "productAvailability.v2", "datacontenttype": "application/json", "id": "2a8d36a3-485b-3fc0-bd15-d530625a6ec5", "specversion": "1.0", "time": "2021-03-10T00:00:00.288Z", "data": { "itemAttributes" : { "color": ["red", "black"], "material": ["cotton"], "size": ["L", "M"] }, "computeTs": "2021-03-10T00:00:00.097Z", "tenantId": "tenant1", "productId": "SHIRT", "productClass": "CLASS_1", "deliveryMethod": "SHP", "segment": null, "segmentType": null, "shipNode": "store-BostonMA", "unitOfMeasure": "EACH", "currentAvailability": { "demandQuantity": 0, "supplyQuantity": 5, "toTs": "2021-04-01T00:00:00.000Z", "availableQuantity": 35, "consumedSafetyQuantity": 0, "fulfillmentAllowed": true, "reservedQuantity": 0, "shortageQuantity": 0, "thresholdLevel": 0, "demandShortage": 0, "reservationShortage":0, "safetyShortage":0, "segmentedQuantity": 5.0, "unsegmentedQuantity": 25.0, "consumptionDemandQuantity" : 0.0, "consumptionReservedQuantity" : 0.0 "unplanned": { "availableQuantity": 5.0, "demandQuantity": 3.0, "reserveQuantity": 2.0 } }, "futureAvailability": [ { "demandQuantity": 0, "supplyQuantity": 5, "fromTs": "2021-04-01T00:00:00.000Z", "toTs": "2500-01-01T00:00:00.000Z", "availableQuantity": 45, "consumedSafetyQuantity": 0, "fulfillmentAllowed": true, "reservedQuantity": 0, "shortageQuantity": 0, "demandShortage": 0, "reservationShortage":0, "safetyShortage":0, "segmentedQuantity": 5.0, "unsegmentedQuantity": 35.0, "consumptionDemandQuantity" : 0.0, "consumptionReservedQuantity" : 0.0, "unplanned": { "availableQuantity": 5.0, "demandQuantity": 3.0, "reserveQuantity": 2.0 } } ] } } - PICK delivery method
{ "type": "productAvailability.v2", "datacontenttype": "application/json", "id": "2a8d36a3-485b-3fc0-bd15-d530625a6ed6", "specversion": "1.0", "time": "2021-03-10T00:00:00.288Z", "data": { "itemAttributes" : { "color": ["red", "black"], "material": ["cotton"], "size": ["L", "M"] }, "computeTs": "2021-03-10T00:00:00.097Z", "tenantId": "tenant1", "productId": "SHIRT", "productClass": "CLASS_1", "deliveryMethod": "PICK", "segment": null, "segmentType": null, "shipNode": "store-BostonMA", "unitOfMeasure": "EACH", "currentAvailability": { "demandQuantity": 0, "supplyQuantity": 5, "toTs": "2021-04-01T00:00:00.000Z", "availableQuantity": 35, "consumedSafetyQuantity": 0, "fulfillmentAllowed": true, "reservedQuantity": 0, "shortageQuantity": 0, "thresholdLevel": 0, "demandShortage": 0, "reservationShortage":0, "safetyShortage":0, "segmentedQuantity": 5.0, "unsegmentedQuantity": 25.0, "consumptionDemandQuantity" : 0.0, "consumptionReservedQuantity" : 0.0, "unplanned": { "availableQuantity": 5.0, "demandQuantity": 3.0, "reserveQuantity": 2.0 } }, "futureAvailability": [ { "demandQuantity": 0, "supplyQuantity": 5, "fromTs": "2021-04-01T00:00:00.000Z", "toTs": "2500-01-01T00:00:00.000Z", "availableQuantity": 45, "consumedSafetyQuantity": 0, "fulfillmentAllowed": true, "reservedQuantity": 0, "shortageQuantity": 0, "demandShortage": 0, "reservationShortage":0, "safetyShortage":0, "segmentedQuantity": 5.0, "unsegmentedQuantity": 35.0, "consumptionDemandQuantity" : 0.0, "consumptionReservedQuantity" : 0.0, "unplanned": { "availableQuantity": 5.0, "demandQuantity": 3.0, "reserveQuantity": 2.0 } } ] } }
Note:- The
shortageQuantityis the shortage generated in the system because of excess demand, excess reservation, and excess safety stock. - The
consumedSafetyQuantityis the safety quantity that got adjusted with the availability in hand. - The
fulfillmentAllowedfield mentions whether fulfillment is allowed or not. demandShortagegives the excess demand quantity that could not get adjusted with supply.reservationShortagegives the value of any excess in reservation.safetyShortagegives the safety stock quantity that could not get adjusted with available supplies andshortageQuantity=demandShortage+reservationShortage+safetyShortage.SegmentedQuantityis the availability coming from segmented inventory. It is calculated only when segment consumes unsegmented inventory and is 0.0 if event shows unsegmented availability.UnsegmentedQuantityis the availability coming from unsegmented inventory. It is calculated only when segment consumes unsegmented inventory.- When the event is published for unsegmented availability, consider the following parameters for calculation:
consumptionDemandQuantityis the additional segmented demand quantity allocated to unsegmented availability. This is calculated only when consumption is enabled and event is raised for unsegmented inventory.consumptionReservedQuantityis the additional segmented reservation quantity placed with unsegmented availability. This is calculated only when consumption is enabled and event is raised for unsegmented inventory.
- The unplanned quantities in
currentAvailabilityindicate overselling of existing stock, while those infutureAvailabilityimply that supplier backfilling is required.
- SHP delivery method
- availableSupplyChange.v2
- The
availableSupplyChange.v2event provides the availability picture based on supply dates when there are changes happen in supply, demand, reservation, or safety stock. The code for this event isavailableSupplyChange.v2. The trigger point of theavailableSupplyChange.v2event is same as that ofproductavailability.v2.For more information, see Node available supplies.
The following sample JSON is an example of a published event for SHP and PICK delivery method.- SHP delivery method
{ "specversion": "1.0", "type": "availableSupplyChange.v2", "id": "515aa404-4411-38d8-9855-b6ab093a451e", "time": "2023-12-05T23:35:56.616Z", "datacontenttype": "application/json", "data":{ "tenantId":"us-b5d0aae5", "productId":"SHIRT", "segment":null, "segmentType":null, "unitOfMeasure":"EACH", "productClass":"NEW", "deliveryMethod":"SHP", "shipNode": "store-BostonMA", "computeTs": "2023-12-05T23:35:56.584Z", "thresholdLevel": "0", "availableSupplies":[{ "availableQuantity" : 8.0, "consumedSafetyQuantity" : 0.0, "demandQuantity" : 4.0, "fromTs" : "2023-12-01T00:00:00.000Z", "fulfillmentAllowed" : true, "reservedQuantity" : 0.0, "shortageQuantity" : 0.0, "supplyQuantity" : 12.0, "toTs" : "2023-12-30T00:00:01.000Z", "demandShortage": 0, "reservationShortage":0, "safetyShortage":0 }, { "availableQuantity" : 15.0, "consumedSafetyQuantity" : 0.0, "demandQuantity" : 0.0, "fromTs" : "2023-12-10T00:00:00.000Z", "fulfillmentAllowed" : true, "reservedQuantity" : 0.0, "shortageQuantity" : 0.0, "supplyQuantity" : 10.0, "toTs" : "2024-01-10T00:00:01.000Z", "demandShortage": 0, "reservationShortage":0, "safetyShortage":0, }], "unsegmentedAvailableSupplies":[{ "availableQuantity" : 90.0, "consumedSafetyQuantity" : 0.0, "demandQuantity" : 0.0, "fromTs" : "1900-01-01T00:00:00.000Z", "fulfillmentAllowed" : true, "reservedQuantity" : 0.0, "shortageQuantity" : 0.0, "supplyQuantity" : 90.0, "toTs" : "2500-01-01T00:00:00.000Z", "demandShortage": 0, "reservationShortage":0, "safetyShortage":0, "consumptionDemandQuantity" : 0.0, "consumptionReservedQuantity" : 0.0 }], "itemAttributes" : { "color": ["red", "black"], "material": ["cotton"], "size": ["L", "M"] } } } - PICK delivery method
{ "specversion": "1.0", "type": "availableSupplyChange.v2", "id": "515aa404-4411-38d8-9855-b6ab093a462f", "time": "2023-12-05T23:35:56.616Z", "datacontenttype": "application/json", "data":{ "tenantId":"us-b5d0aae5", "productId":"SHIRT", "segment":null, "segmentType":null, "unitOfMeasure":"EACH", "productClass":"NEW", "deliveryMethod":"PICK", "shipNode": "store-BostonMA", "computeTs": "2023-12-05T23:35:56.584Z", "thresholdLevel": "0", "availableSupplies":[{ "availableQuantity" : 13.0, "consumedSafetyQuantity" : 0.0, "demandQuantity" : 4.0, "fromTs" : "2023-12-01T00:00:00.000Z", "fulfillmentAllowed" : true, "reservedQuantity" : 0.0, "shortageQuantity" : 0.0, "supplyQuantity" : 12.0, "toTs" : "2023-12-30T00:00:01.000Z", "demandShortage": 0, "reservationShortage":0, "safetyShortage":0, }, { "availableQuantity" : 10.0, "consumedSafetyQuantity" : 0.0, "demandQuantity" : 0.0, "fromTs" : "2023-12-10T00:00:00.000Z", "fulfillmentAllowed" : true, "reservedQuantity" : 0.0, "shortageQuantity" : 0.0, "supplyQuantity" : 10.0, "toTs" : "2024-01-10T00:00:01.000Z", "demandShortage": 0, "reservationShortage":0, "safetyShortage":0 }], "unsegmentedAvailableSupplies":[{ "availableQuantity" : 90.0, "consumedSafetyQuantity" : 0.0, "demandQuantity" : 0.0, "fromTs" : "1900-01-01T00:00:00.000Z", "fulfillmentAllowed" : true, "reservedQuantity" : 0.0, "shortageQuantity" : 0.0, "supplyQuantity" : 90.0, "toTs" : "2500-01-01T00:00:00.000Z", "demandShortage": 0, "reservationShortage":0, "safetyShortage":0, "consumptionDemandQuantity" : 0.0, "consumptionReservedQuantity" : 0.0 }], "itemAttributes" : { "color": ["red", "black"], "material": ["cotton"], "size": ["L", "M"] } } }
Note: For more information, see definitions forshortageQuantity,consumedSafetyQuantity, andfulfillmentAllowed. - SHP delivery method
- dgAvailabilityChange.v2
dgAvailabilityChange.v2events represent the overall network availability for a distribution group. A new event is published whenever one or more contained nodes experience a change in availability quantity or timestamp. These changes can be triggered by updates in supply, demand, safety stock, fulfillment options, or capacity levels.The following sample JSON is an example of a published event for SHP and PICK delivery method.- SHP delivery method
{ "type": "dgAvailabilityChange.v2", "datacontenttype": "application/json", "id": "304746ba-4d53-3514-94d9-9353b8b14152", "specversion": "1.0", "time": "2021-03-10T00:00:00.283Z", "data": { "itemAttributes" : { "color": ["red", "black"], "material": ["cotton"], "size": ["L", "M"] }, "computeTs": "2021-03-10T00:00:00.119Z", "tenantId": "tenant1", "productId": "SHIRT", "productClass": "CLASS_1", "deliveryMethod": "SHP", "segment" : "Platinum", "segmentType" : "B2B Accounts", "distributionGroupId": "WEB", "unitOfMeasure": "EACH", "currentAvailability": { "toTs": "2021-04-01T00:00:00.000Z", "availableQuantity": 35, "consumedSafetyQuantity": 0, "fulfillmentAllowed": true, "reservedQuantity": 0, "shortageQuantity": 0, "thresholdLevel": 0, "demandShortage": 0, "reservationShortage": 0, "safetyShortage":0, "segmentedQuantity": 20.0, "unsegmentedQuantity": 10.0, "consumptionDemandQuantity" : 0.0, "consumptionReservedQuantity" : 0.0, "unplanned": { "availableQuantity": 5.0, "demandQuantity": 3.0, "reserveQuantity": 2.0 } }, "futureAvailability": [ { "fromTs": "2021-04-01T00:00:00.000Z", "toTs": "2500-01-01T00:00:00.000Z", "availableQuantity": 45, "consumedSafetyQuantity": 0, "fulfillmentAllowed": true, "reservedQuantity": 0, "shortageQuantity": 0, "demandShortage": 0, "reservationShortage":0, "safetyShortage":0, "segmentedQuantity": 5.0, "unsegmentedQuantity": 35.0, "consumptionDemandQuantity" : 0.0, "consumptionReservedQuantity" : 0.0 "unplanned": { "availableQuantity": 5.0, "demandQuantity": 3.0, "reserveQuantity": 2.0 } } ] } } - PICK delivery method
{ "type": "dgAvailabilityChange.v2", "datacontenttype": "application/json", "id": "515aa404-4411-38d8-9855-b6ab093a46df", "specversion": "1.0", "time": "2021-03-10T00:00:00.283Z", "data": { "itemAttributes" : { "color": ["red", "black"], "material": ["cotton"], "size": ["L", "M"] }, "computeTs": "2021-03-10T00:00:00.119Z", "tenantId": "tenant1", "productId": "SHIRT", "productClass": "CLASS_1", "deliveryMethod": "PICK", "segment": null, "segmentType": null, "distributionGroupId": "WEB", "unitOfMeasure": "EACH", "currentAvailability": { "toTs": "2021-04-01T00:00:00.000Z", "availableQuantity": 35, "consumedSafetyQuantity": 0, "fulfillmentAllowed": true, "reservedQuantity": 0, "shortageQuantity": 0, "thresholdLevel": 0, "demandShortage": 0, "reservationShortage":0, "safetyShortage":0, "segmentedQuantity": 5.0, "unsegmentedQuantity": 25.0, "consumptionDemandQuantity" : 0.0, "consumptionReservedQuantity" : 0.0, "unplanned": { "availableQuantity": 5.0, "demandQuantity": 3.0, "reserveQuantity": 2.0 } }, "futureAvailability": [ { "fromTs": "2021-04-01T00:00:00.000Z", "toTs": "2500-01-01T00:00:00.000Z", "availableQuantity": 45, "consumedSafetyQuantity": 0, "fulfillmentAllowed": true, "reservedQuantity": 0, "shortageQuantity": 0, "demandShortage": 0, "reservationShortage":0, "safetyShortage":0, "segmentedQuantity": 20.0, "unsegmentedQuantity": 20.0, "consumptionDemandQuantity" : 0.0, "consumptionReservedQuantity" : 0.0 "unplanned": { "availableQuantity": 5.0, "demandQuantity": 3.0, "reserveQuantity": 2.0 } } ] } }
Note: TheshortageQuantityattribute represents the aggregation of node-level shortage quantities across all nodes of the distribution group. For more information, see definitions forshortageQuantity,consumedSafetyQuantity, andfulfillmentAllowed.- SHP delivery method
- Demand.Change
- The inventory service allows you to publish the demand change data to
an external system for analytics. Such data enables the supply chain (SC) manager to be alerted when
there is a sudden flux of inventory demand. For example, if there is a sudden hand sanitizer demand
spike, the SC manager can quickly alter the fulfillment strategy to mitigate contractual damage to
some of the high valued buyers.
The following sample payload is an example of a published event. The Inventory Visibility event ID is
Demand.Changeand event code in payload isdemandChange.{ "specversion" : "1.0", "datacontenttype" : "application/json", "type": "demandChange", "id": "<UUID>", "time": "<time ISO-8601 format>", "data": { "itemId": "SHIRT", "unitOfMeasure": "EACH", "productClass": "CLASS_1", "tagNumber": "A|02", "shipNode": "store-BostonMA", "baseType": "OPEN_ORDER", "type": "CUSTOM_OPEN_ORDER", "segment": "Web", "segmentType": "Channel", "shipDate": "2020-05-29T13:00:00.000Z", "cancelDate": "2020-06-28T13:00:00.000Z", "minShipByDate": "2022-01-22T05:00:00.000Z", "quantity": 3.0, "changedQuantity": 2.0, "updatedTs": "2020-05-28T06:00:00.000Z", "adjustmentReason" : "PROCESS" } }Note: TheupdatedTsfield indicates the time when the database was updated for this demand.
- productAvailabilitySnapshot.v2
- Use the
productAvailabilitySnapshot.v2event to send a snapshot (on demand) of availability for a specific node, all nodes, or nodes that belong to a distribution group.
The following sample JSON is an example of a published event for SHP and PICK delivery method.- SHP delivery method
{ "type": "productAvailabilitySnapshot.v2", "datacontenttype": "application/json", "id": "2a8d36a3-485b-3fc0-bd15-d530625a6ec5", "specversion": "1.0", "time": "2021-03-10T00:00:00.288Z", "data": { "computeTs": "2021-03-10T00:00:00.097Z", "tenantId": "tenant1", "snapshotId": "productAvailabilitySnapshot-test", "productId": "SHIRT", "productClass": "CLASS_1", "deliveryMethod": "SHP", "segment": null, "segmentType": null, "shipNode": "store-BostonMA", "unitOfMeasure": "EACH", "currentAvailability": { "demandQuantity": 0, "supplyQuantity": 30, "toTs": "2021-04-01T00:00:00.000Z", "availableQuantity": 35, "consumedSafetyQuantity": 0, "fulfillmentAllowed": true, "reservedQuantity": 0, "shortageQuantity": 0, "thresholdLevel": 0, "demandShortage": 0, "reservationShortage":0, "safetyShortage":0, "segmentedQuantity": 20.0, "unsegmentedQuantity": 10.0, "consumptionDemandQuantity" : 0.0, "consumptionReservedQuantity" : 0.0, "unplanned": { "availableQuantity": 5.0, "demandQuantity": 3.0, "reserveQuantity": 2.0 } }, "futureAvailability": [ { "demandQuantity": 0, "supplyQuantity": 45, "fromTs": "2021-04-01T00:00:00.000Z", "toTs": "2500-01-01T00:00:00.000Z", "availableQuantity": 40, "consumedSafetyQuantity": 0, "fulfillmentAllowed": true, "reservedQuantity": 0, "shortageQuantity": 0, "demandShortage": 0, "reservationShortage":0, "safetyShortage":0, "segmentedQuantity": 20.0, "unsegmentedQuantity": 20.0, "consumptionDemandQuantity" : 0.0, "consumptionReservedQuantity" : 0.0 "unplanned": { "availableQuantity": 5.0, "demandQuantity": 3.0, "reserveQuantity": 2.0 } } ] } } - PICK delivery method
{ "type": "productAvailabilitySnapshot.v2", "datacontenttype": "application/json", "id": "2a8d36a3-485b-3fc0-be26-d530625a6ec5", "specversion": "1.0", "time": "2021-03-10T00:00:00.288Z", "data": { "computeTs": "2021-03-10T00:00:00.097Z", "tenantId": "tenant1", "snapshotId": "productAvailabilitySnapshot-test", "productId": "SHIRT", "productClass": "CLASS_1", "deliveryMethod": "PICK", "segment": null, "segmentType": null, "shipNode": "store-BostonMA", "unitOfMeasure": "EACH", "currentAvailability": { "demandQuantity": 0, "supplyQuantity": 30, "toTs": "2021-04-01T00:00:00.000Z", "availableQuantity": 30, "consumedSafetyQuantity": 0, "fulfillmentAllowed": true, "reservedQuantity": 0, "shortageQuantity": 0, "thresholdLevel": 0, "demandShortage": 0, "reservationShortage":0, "safetyShortage":0, "segmentedQuantity": 20.0, "unsegmentedQuantity": 10.0, "consumptionDemandQuantity" : 0.0, "consumptionReservedQuantity" : 0.0 }, "futureAvailability": [ { "demandQuantity": 0, "supplyQuantity": 40, "fromTs": "2021-04-01T00:00:00.000Z", "toTs": "2500-01-01T00:00:00.000Z", "availableQuantity": 40, "consumedSafetyQuantity": 0, "fulfillmentAllowed": true, "reservedQuantity": 0, "shortageQuantity": 0, "demandShortage": 0, "reservationShortage":0, "safetyShortage":0, "segmentedQuantity": 20.0, "unsegmentedQuantity": 20.0, "consumptionDemandQuantity" : 0.0, "consumptionReservedQuantity" : 0.0 "unplanned": { "availableQuantity": 5.0, "demandQuantity": 3.0, "reserveQuantity": 2.0 } } ] } }
You can manually trigger the snapshot for a specific node by calling the publish_all API. The productAvailabilitySnapshot.v2 publish_all API returns a job URL along with the{ "type": "productAvailabilitySnapshot.v2", "datacontenttype": "application/json", "id": "2a8d36a3-485b-3fc0-be26-d530625a6ec5", "specversion": "1.0", "time": "2021-03-10T00:00:00.288Z", "data": { "tenantId": "tenant1", "snapshotId": "productAvailabilitySnapshot-test", } }jobId. It also publishes a dummy event when the process is complete, which has the same format as the normal message, but it omits all attributes other thantenantIdandsnapshotId. ThesnapshotIdis a UUID to recognize the event. The URL forproductAvailabilitySnapshot.v2is:https://api.watsoncommerce.ibm.com/<tenantId>/v2/configuration/events/productAvailabilitySnapshot.v2/publish_allNote:- For more information, see definitions for
shortageQuantity,consumedSafetyQuantity, andfulfillmentAllowed. - When the event is published for unsegmented availability, consider the following parameters for calculation:
consumptionDemandQuantityconsumptionReservedQuantity
- SHP delivery method
- dgAvailabilitySnapshot.v2
- Use the
dgAvailabilitySnapshot.v2event to send a snapshot (on demand) of availability to a distribution group.
The following sample JSON is an example of a published event for SHP and PICK delivery method.- SHP delivery method
{ "type": "dgAvailabilitySnapshot.v2", "datacontenttype": "application/json", "id": "240fe0ec-e24a-31c2-93a0-74cb8160aa98", "specversion": "1.0", "time": "2021-07-17T00:00:00.503Z", "data": { "computeTs": "2021-07-17T00:00:00.174Z", "tenantId": "tenant1", "productClass": "NEW", "productId": "book", "snapshotId": "dgAvailabilitySnapshot-test", "unitOfMeasure": "EACH", "deliveryMethod": "SHP", "segment": null, "segmentType": null,"distributionGroup": "Stores", "distributionGroupId": "Stores", "currentAvailability": { "availableQuantity": 5, "consumedSafetyQuantity": 0, "fulfillmentAllowed": true, "reservedQuantity": 0, "shortageQuantity": 0, "thresholdLevel": 3, "toTs": "2021-07-20T00:00:00.000Z", "demandShortage": 0, "reservationShortage":0, "safetyShortage":0, "segmentedQuantity": 0.0, "unsegmentedQuantity": 0.0, "consumptionDemandQuantity" : 0.0, "consumptionReservedQuantity" : 0.0, "unplanned": { "availableQuantity": 5.0, "demandQuantity": 3.0, "reserveQuantity": 2.0 } }, "futureAvailability": [ { "availableQuantity": 15, "consumedSafetyQuantity": 0, "fromTs": "2021-07-20T00:00:00.000Z", "fulfillmentAllowed": true, "reservedQuantity": 0, "shortageQuantity": 0, "toTs": "2021-08-16T00:00:01.000Z", "demandShortage": 0, "reservationShortage":0, "safetyShortage":0, "segmentedQuantity": 5.0, "unsegmentedQuantity": 5.0, "consumptionDemandQuantity" : 0.0, "consumptionReservedQuantity" : 0.0 "unplanned": { "availableQuantity": 5.0, "demandQuantity": 3.0, "reserveQuantity": 2.0 } } ] } }
- PICK delivery method
{ "type": "dgAvailabilitySnapshot.v2", "datacontenttype": "application/json", "id": "240fe0ec-e24a-31c2-93a0-74cb8160bb00", "specversion": "1.0", "time": "2021-07-17T00:00:00.503Z", "data": { "computeTs": "2021-07-17T00:00:00.174Z", "tenantId": "tenant1", "productClass": "NEW", "productId": "book", "snapshotId": "dgAvailabilitySnapshot-test", "unitOfMeasure": "EACH", "deliveryMethod": "PICK", "segment": null, "segmentType": null,"distributionGroup": "Stores", "distributionGroupId": "Stores", "currentAvailability": { "availableQuantity": 5, "consumedSafetyQuantity": 0, "fulfillmentAllowed": true, "reservedQuantity": 0, "shortageQuantity": 0, "thresholdLevel": 3, "toTs": "2021-07-20T00:00:00.000Z", "demandShortage": 0, "reservationShortage":0, "safetyShortage":0, "segmentedQuantity": 0.0, "unsegmentedQuantity": 0.0, "consumptionDemandQuantity" : 0.0, "consumptionReservedQuantity" : 0.0, "unplanned": { "availableQuantity": 5.0, "demandQuantity": 3.0, "reserveQuantity": 2.0 } }, "futureAvailability": [ { "availableQuantity": 15, "consumedSafetyQuantity": 0, "fromTs": "2021-07-20T00:00:00.000Z", "fulfillmentAllowed": true, "reservedQuantity": 0, "shortageQuantity": 0, "toTs": "2021-08-16T00:00:01.000Z", "demandShortage": 0, "reservationShortage":0, "safetyShortage":0, "segmentedQuantity": 5.0, "unsegmentedQuantity": 5.0, "consumptionDemandQuantity" : 0.0, "consumptionReservedQuantity" : 0.0 "unplanned": { "availableQuantity": 5.0, "demandQuantity": 3.0, "reserveQuantity": 2.0 } } ] } }
Note:For more information, see definitions for- The
shortageQuantityattribute represents the aggregation of node-level shortage quantities across all nodes of the distribution group. - The
distributionGroupattribute is deprecated and will be removed in a subsequent release of the product. Instead, use thedistributionGroupIdattribute.
shortageQuantity,consumedSafetyQuantity, andfulfillmentAllowed.
The following EOF sample is an example of a published event:
You can manually trigger the snapshot for a specific distribution group by calling the{ "type": "dgAvailabilitySnapshot.v2", "datacontenttype": "application/json", "id": "2a8d36a3-485b-3fc0-bd15-d530625a6ec5", "specversion": "1.0", "time": "2021-03-10T00:00:00.288Z", "data": { "tenantId": "tenant1", "snapshotId": "dgAvailabilitySnapshot-test" } }publish_allAPI. ThedgAvailabilitySnapshot.v2 publish_allAPI returns a job URL along with thejobId. It also publishes a dummy event when the process is complete, which has the same format as the normal message, but it omits all attributes other thantenantIdandsnapshotId. You can generate a snapshot for a specific distribution group or all of them. The URL fordgAvailabilitySnapshot.v2is:https://api.watsoncommerce.ibm.com/<tenantId>v2/configuration/events/dgAvailabilitySnapshot.v2/publish_all - SHP delivery method
- demandSnapshot
-
As a System Integrator in Inventory Visibility, you publish a snapshot of the demand system for analysis. As a Fulfillment Manager, you use this information to report on the demand system and troubleshoot any issues found in advance of the next financial cycle. For example, as a result of a product promotion that you ran, there is an ongoing spike in demand for the product at a specific node. As a result to meet this increased demand, you must increase the supply available at the location to avoid any customers missing the product. With complete visibility of the demand system, you continue to meet your customer demand.
The following sample JSON is an example of a published event. The event code is
demandSnapshot.{ "type": "demandSnapshot", "datacontenttype": "application/json", "id": "a1ae3dcd-8fd6-4f76-b7ed-7916c739ac5a", "specversion": "1.0", "time": "2023-11-28T00:00:00.000Z", "data": { "fetchTs": "2023-11-28T00:00:00.000Z", "tenantId": "tenant1", "snapshotId": "demandSnapshot-test", "productId": "SKU1024", "unitOfMeasure": "EACH", "productClass": "NEW", "type": "OPEN_ORDER", "shipNode": "Matrix-Store-001", "tagNumber": null, "segment": "ONLINE", "segmentType": "Channel", "shipDate": "2023-12-05T00:00:00Z", "cancelDate": "2500-01-01T00:00:00Z", "referenceType": null, "reference": null, "minShipByDate": "2500-01-01T00:00:00Z", "quantity": 10 } }
supplySnapshot- As a Systems Integrator in Inventory Visibility, you publish a
snapshot of the supply system for analysis. As a Fulfillment Manager, you get an insight
into the supply system early on so any discrepancies found can be addressed in advance of the next
financial cycle. For example, you notice a spike in sales around a new product that you just started
to sell lately. To capture more sales, you decide to run a promotion around this product at a
certain node. With complete visibility of the supply system, you're aware already of the amount of
product that you must supply in advance of the promotion. This ensures that you meet your customer
demand successfully.
The following sample JSON is an example of a published event. The event code is
supplySnapshot.{ "type": "supplySnapshot", "datacontenttype": "application/json", "id": "4075a47d-9227-432e-ab3e-c369e8802aa0", "specversion": "1.0", "time": "2023-11-28T00:00:00.000Z", "data": { "fetchTs": "2023-11-28T00:00:00.000Z", "tenantId": "tenant1", "snapshotId": "supplySnapshot-test", "itemId": "SKU1024", "unitOfMeasure": "EACH", "productClass": "NEW", "type": "ONHAND", "shipNode": "Matrix-Store-001", "tagNumber": null, "segment": "ONLINE", "segmentType": "Channel", "eta": "1900-01-01T00:00:00Z", "shipByDate": "2500-01-01T00:00:00Z", "referenceType": null, "reference": null, "lineReference": null, "quantity": 100 } }