-
Notifications
You must be signed in to change notification settings - Fork 5
Description
Description
When a new delivery report arrives from Azure Communication Services or Link Mobility, the Notifications API retrieves the identifier of the order associated with the corresponding Email or SMS notification. It then checks the status of all related Email and SMS notifications.
If all Email and SMS notifications appear to have reached a final state, the API updates the corresponding order’s status to a final state (e.g., Completed).
However, the current logic can stop triggering this cycle on certain non-final statuses:
- SMS notifications with status
Accepted - Email notifications with status
Succeeded
These states should not trigger the order completion cycle, as they do not represent a true delivery completion or failure.
Additionally, the logic that evaluates whether an order can be marked as completed currently executes within the delivery report handling flow. This coupling makes the delivery report processing unnecessarily heavy and could be improved by moving the completion check into a background service.
Proposed Solution
- Adjust completion logic
- Refactor processing flow if needed.
Acceptance Criteria
- Non-final statuses
SucceededandAccepteddoes not trigger the order completion cycle. - Delivery report processing runs independently from order completion evaluation (if needed).
Metadata
Metadata
Assignees
Labels
Type
Projects
Status