Fluent Commerce Logo
Docs

SendEventOnVerifyingParcelsComplete

Rule

Changed on:

7 Aug 2025

Overview

This rule triggers an event when items are packed into parcels without rejection.
Plugin NameOrder Reference Module
Namespace[[account.id]].order
The Order Reference Module is the foundation for order-related implementations. It provides reference workflows for click & collect, home delivery and mixed baskets and those needed to build your own. Extensible by design, use this Module as a base to build a solution to your customers' needs.

UI Description

Send event {eventName} if parcels complete the fulfilment.

Accepts

  • Fulfilment

Actions

  • This Rule conditionally produces a `SendEventAction`

Rule parameters

NameTypeDescription
eventNameStringName of the event to send if the check passes.

Event attributes

ParameterDescriptionData TypeRequired?
packedItemsThe list of packed and rejected fulfilment itemsObjectRequired

Exceptions

This rule may result in following exception:
  • throw `IllegalArgumentException` if incoming event has no `packedItems` attribute

Configuration example

1{
2  "name": "[[account.id]].order.SendEventOnVerifyingParcelsComplete",
3  "props": {
4       "eventName": "CreateParcels"
5  }
6}

Detailed Technical Description

This rule produces a `SendEventAction` if items are not empty in the `packedItems.articles` attribute, and the `packedItems.rejections` attribute is empty.

1{"packedItems": {
2      "articles": [
3        {
4          "barcode": "4567",
5          "height": "30",
6          "length": "30",
7          "maxWeight": "9.9",
8          "minWeight": "5",
9          "packaging_name": "Medium",
10          "weight": "8",
11          "width": "30",
12          "items": [
13            {
14              "fulfilmentItemId": "140",
15              "quantity": 2
16            },
17            {
18              "fulfilmentItemId": "139",
19              "quantity": 1
20            }
21          ]
22        }
23      ],
24      "rejections": [
25        {
26          "fulfilmentItemId": "139",
27          "rejectedQty": 2,
28          "rejectReason": {
29            "label": "fc.sf.rejectionReason.damagedItem",
30            "value": "damagedItem"
31          }
32        }
33      ]
34    }
35}
Workflow Builder (Modeller) Screenshot
No alt provided

Version History

2024-10-08

v1.0.0

Initial release