Shipment and Order Notifications Special Logic

Overview


This guide explains how shipment and order notifications are triggered, including timing rules, restrictions, and special handling scenarios.


Shipment notifications


1. Multiple checkpoint processing


A. Latest checkpoint priority


When a shipment receives multiple checkpoint updates at the same time, the system processes them using a latest checkpoint priority rule.


  • Only the most recent checkpoint event is considered.
  • Notifications are triggered based on that latest checkpoint.
  • Earlier checkpoints in the same batch are ignored for notifications.


Example:


If a shipment receives the following updates simultaneously:


  • Out for delivery is at 10:00 AM.
  • Delivered is at 10:05 AM.
  • Only the Delivered notification will be sent.


Checkpoint time window restrictions


A. Shipment status update: 7-Day time window rule


Shipment notifications are only triggered if the checkpoint event occurs within a 7-day window relative to the notification trigger time.


  • If the events are older than 7 days, no notification will be triggered.
  • if the events are within 7 days, notification will be triggered.


B. Split order summary: 24-hour rule


For split shipments (multiple shipments under one order):


  • Notifications are triggered only if the checkpoint event occurred within 24 hours.
  • Older events are ignored for notifications.


Purpose:


  • This rule prevents outdated shipment updates from triggering unnecessary notifications.
  • It ensures that customers receive only recent and relevant updates.


C. Historical delivered shipments


Shipments that are already marked as Delivered before being imported into the system behave differently.


  • No notifications will be triggered for historical delivered shipments.


Reason:


  • These shipments are treated as historical data.
  • This avoids sending misleading or redundant notifications to customers.


Return to sender limitatioms


A. Customer notifications (Restricted)


When a shipment enters a return_to_sender flow, customer notifications are limited. Only the following statuses will trigger notifications:


  • exception:returning_to_sender
  • exception:returned_to_sender


All other return-related statuses will NOT trigger customer notifications.


B. Internal notifications (No restrictions)


Internal stakeholders (e.g., operations, support teams) are not affected by these restrictions:


  • All shipment status updates will continue to trigger internal notifications.
  • This rule ensures full operational visibility for all the internal stakeholders managing the business communication.


Order notifications


Order-related notifications are triggered by a 72-hour time window:


  • The notifications are only triggered if the relevant event occurs within 72 hours.
  • The events occurred outside this window will not trigger any notifications.


Supported order events


Order Event

Timestamp Field Used

Order Placed

placed_at

Order Unfulfilled

placed_at

Order Partially Fulfilled

metric.created_at (latest fulfillment)

Order Fulfilled

metric.created_at (latest fulfillment)

Order Canceled

order.metric.canceled_at

Updated on: 16/04/2026