Inventory Reference Module
Changed on:
11 Apr 2025
Publisher: | Fluent Commerce |
---|---|
Website: | Fluent Commerce |
Download reference module
Interface contracts
Dependencies
Version History
Key Changes
- The CreateBaseVirtualPosition, UpdateBaseVirtualPosition, CreateAggregateVirtualPosition, and UpdateAggregateVirtualPosition rules now apply control-specific logic only if the event includes a Control Group reference (event attribute). The Control Group reference is initially loaded from the Virtual Catalog (see LoadVirtualPositionAndVirtualCatalogueDetails).
`virtualCatalogueControlGroupRef`
- Before this enhancement, the rules would run control logic even when a Control Group reference was absent, which could cause errors during updates.
- Now, if a Control Group reference is not present in the event payload, the control logic is skipped, which matches the expected optional behavior.
- The rule descriptions have been updated to clearly show that is optional and to avoid confusion about required fields.
`virtualCatalogueControlGroupRef`
Key Changes:
- Rules and Utilities
- and
`ApplyThresholdControlsToInventoryPosition`
Rules have been enhanced to apply fallback logic that imitates the presence of an Active Bulk Threshold Control (applicable to all the Inventory and Virtual Catalogs) to ensure the correct management of Position Statuses when no Bulk Threshold Controls are configured. Previously, Inventory and Virtual Positions remained in the`ApplyThresholdControlsToVirtualPosition`
Status when no Active Bulk Threshold Control(s) was available for a corresponding Inventory or Virtual Catalog.`CREATED`
- New and
`UpsertInventoryQuantity`
Rules have been introduced to enable Inventory Quantity Type configuration for Inventory Quantity creation or update via the Batch.`LoadInventoryPositionData`
- Reference Workflows
- Reference Inventory Catalog Workflow has been improved to:
- Support loading Inventory Quantities of any Type via the Enhanced Inventory Batch.
- Ensure correct calculation when Inventory is loaded before the Product is created in Fluent
`onHand`
- Direct Inventory Updates have been deprecated.
- 📖 See the Inventory Catalog Workflow Template Version History section for details.
- Reference Inventory Catalog Workflow has been improved to:
Note:
- An upgrade to the Core Reference Module 2.0.0+ is mandatory for correct Reference Inventory Catalog Workflow functioning.
Key Changes:
- Rules and Utilities
- New Rules have been introduced to enable Cross-Retailer events sending for Master/Sub-Retailer(s) setup:
- and
`CreateAggregateVirtualPosition`
Rules have been optimized to load all the related Controls (by Product, its Categories, and list of Locations) at once for efficient Aggregate Virtual Position Available-to-Sell (ATS) calculations.`UpdateAggregateVirtualPosition`
- Attribute Utils have been updated to use a plain type instead of the
`string`
, ensuring that a Product attribute`enum`
is saved in the same way as it was sent via the`type`
event.`UPSERT_PRODUCT`
- and
`NotifyVirtualCatalogueOnNetworkMatch`
Rules have been extended with a pagination logic to ensure correct execution for the following scenarios:`ValidateProductCategoriesExist`
- A given Location belongs to more than 10 Networks, and the Virtual Catalog to be updated has a Network outside the first 10 Networks fetched.
- A given Product has more than 100 Categories assigned.
- Reference Workflows
- All the Workflows:
- Rules have been switched to the
`SendEventGQL`
(Core Reference Module).`SendEvent`
- “Deactivate” Rulesets have been removed:
`DeactivateProductCatalogue`
`DeactivateIC`
`DeactivateIP`
`DeactivateIQ`
`DeactivateVC`
- Inventory Catalog Workflow:
- Rules have been replaced with the new
`NotifyVirtualCatalogueOnNetworkMatch`
Rule for the`NotifyVirtualCataloguesByRefsOnNetworksMatch`
Ruleset.`NotifyVirtualCatalogues`
- Ruleset has been replaced with a generic
`CalculateOnHandForFulfilment`
one.`CalculateOnHand`
Ruleset has been removed.`UpdateOnHandForFulfilment`
- Rule has been removed from the
`UpdateInventoryQuantitiesStatus`
Ruleset.`BatchInventoryQuantityCreate`
- All the Workflows:
Key Changes:
- Inventory and Virtual Position Reference Statuses have been extended with and
`OUT_OF_STOCK`
Statuses.`AT_RISK`
- A New Reference Control Type has been introduced. It is driven by threshold-based logic and applicable to both Inventory and Virtual Positions, empowering Inventory stock Status management.
`BULK_THRESHOLD`
- Reference Inventory Workflows have been updated with New Rules: and
`ApplyThresholdControlsToInventoryPosition`
, utilized in the following Rulesets:`ApplyThresholdControlsToVirtualPosition`
- Inventory Catalog: ,
`UpdateOnHand`
,`ActivateInventoryPosition`
`UpdateOnHandForFulfilment`
- Virtual Catalogs:
- Base: ,
`CREATE`
`UpdateBaseVirtualPosition`
- Aggregate: ,
`CREATE`
`UpdateAggregateVirtualPosition`
- Base:
- Rulesets' Triggers and Status Properties have been updated to reflect the introduction of the new Statuses.
- Inventory Catalog:
Limitations:
- Control Group(s) assignment to Inventory and Virtual Catalogs and Bulk Threshold Controls configuration are mandatory for correct Workflows functioning.
UPDATED: Bulk Threshold Controls configuration is no longer mandatory (starting from the Inventory Module 2.2.0 version). - The argument in the
`retailerRefs`
,`productCatalogues`
,`inventoryCatalogues`
, and`virtualCatalogues`
GraphQL queries is not supported for the Inventory Reference Module Rule Plugin because of the utilized Apollo Client restrictions.`controlGroups`
Enhanced Rules: The following inventory rules have been updated to support flexible inventory catalog types and to remove the dependency on the default catalog type:
`SplitInventoryUpdates`
`InventoryChanged`
`LoadInventoryPosition`
`CheckIfInventoryPositionExists`
`DownToInventoryPositionIfExists`
`CheckInventoryQuantityExists`
`ForwardIfInventoryQuantityTypeExists`
`BatchInventoryPositionUpdate`
`UpdateInventoryQuantity`
`CreateBaseVirtualPosition`
`UpdateBaseVirtualPosition`
`LoadVirtualPositionAndVirtualCatalogueDetails`
`NotifyVirtualCatalogueOnNetworkMatch`
Key Changes:
- Inventory position types now inherit from the inventory catalog type, enabling workflows and plugins to function across different catalog types without rule modifications.
- The subtype in the inventory catalog workflow must be correctly set to leverage this flexibility, ensuring rules are no longer limited to the default catalog type.
- Rule updates have removed the hard-coded inventory catalog type (DEFAULT), increasing the usability of these rules with non-default catalogs.
- A new field, , has been introduced for the
`inventoryQuantity`
event. This field aggregates all attributes under "attributes" from inventory batches and related rulesets like`InventoryChanged`
. Specific keys like "condition," "expectedOn," and "storageAreaRef" will be updated at the inventory quantity level, while other attributes will be available in workflows for further actions.`INVENTORY_UPDATE`
- Rule Enhancement: Updated the rule to limit retrieval to the
`LoadInventoryPosition`
inventory quantity type.`LAST_ON_HAND`
- This change reduces unnecessary data fetching, focusing only on relevant inventory quantities.
- Improved Performance:
- By narrowing the data retrieval scope, the module processes inventory data more efficiently.
- No Workflow Changes:
- The update involves only a change to the inventory rule, with no impact on existing workflows or operations from the 1.3.0 version
Module release including:
- Reference Module Structure Improvements:
- The Module File and Folder Organization has been updated
- The Naming and Versioning have been improved
- The Core Module dependency has been established, utilizing its Reference Rules
- The Workflows Ruleset Key Fields have been arranged
- The Workflows Placeholder and Default Value Formats have been modified
- Reference Workflows Enhancements and Fixes:
- Inventory Catalog Workflow has been extended, ensuring proper Inventory Updates with:
- Additional attributes for the Rule:
`LoadInventoryPosition`
- inventoryQuantityExists
- inventoryQuantityTypes
- New Ruleset
`CheckInventoryQuantityExists`
- New Rules:
- Additional attributes for the
- Product Catalog Workflow has been fixed:
- Status Trigger has been removed from the
`ACTIVE`
Ruleset`ActivateProduct`
- Inventory Catalog Workflow has been extended, ensuring proper Inventory Updates with:
Minor Module release with the following fixes:
- rule has been updated to
`SplitUpdatesAndDownToInventoryPosition`
to correctly send the following events to the right entity level`SplitInventoryUpdates`
- rule will correctly work with more than 10 delta updates
`SplitDeltasAndDownToInventoryPosition`
- New rule & reference workflow were introduced to handle an edge case where a Virtual Position won't be created when creating a new Inventory Position
`CreateBaseVirtualPositionIfNotPresent`
Module release including reference implementations of Inventory Delta updates and direct Last on Hand Inventory Updates.
v1.1.0
Module release with reference implementation of Product Catalog domain.
v1.0.0
Initial Inventory Reference Module release.
Overview
The Inventory Reference Module is the foundation for inventory related implementations. It provides reference Workflows for inventory ingestion and processing. Extensible by design, use this Module as a base to build a solution to the needs of your customers.
The Inventory Module includes the following areas:
- Product Catalog workflow
- Inventory Catalog workflow
- Control Group workflows
- Virtual Catalog workflows
Detailed Technical Description
The artifacts below make up the Inventory Module.
Workflows:
Name | Primary Entity | Description |
Product Catalog |
| This workflow is used to implement the Product Catalog entity features within the Inventory Module |
| This workflow is used to implement the Inventory Catalog entity features within the Inventory Module | |
| This workflow is used to implement the Virtual Catalog entity features within the Inventory Module | |
Control Group |
| This workflow is used to implement the Control Group entity features within the Inventory Module |
Rules
Name | Description |
Apply Threshold Controls to an Inventory Position and determine its Status. | |
Apply Threshold Controls to a Virtual Position and determine its Status. | |
Calculates the onHand value of an inventory position using inventory quantities filtered by statuses and types followed by sending an event | |
Change the state of the current entity | |
Creates an aggregate virtual position and sends an event | |
Creates a base virtual position and sends an event | |
Checks if a base virtual position exists and creates the position if it doesn't already exist | |
Creates a category | |
Creates an Inventory Quantity(ies) for the specified Inventory Position | |
Creates an Inventory Position | |
Creates an Inventory Quantity for a Fulfillment | |
Creates an Inventory Quantity | |
Creates a Standard Product | |
Creates a Variant Product | |
Sends an event to the Category entity | |
Send an event to the Inventory Position entity | |
Checks if an Inventory Position exists and if so sends an event | |
Sends an event to the Product entity | |
Checks if a Virtual Position exists and if so sends an event | |
Send an event | |
Checks if a Category exists and if so sends an event | |
Checks if a Category exists and if not sends an event | |
Sends an event if an attribute equals a given value | |
Checks if an Inventory Position exists and if not sends an event | |
Checks an Inventory Position status and sends an event on match | |
Checks if an Inventory Quantity of the specified type exists and if so sends an event | |
Checks if an Inventory Quantity of the specified type exists and if not sends an event | |
Checks a Location status and sends an event on match | |
Sends an event if the onHand value has changed | |
Checks a Product status and sends an event on match | |
Checks if a Standard Product exists and if so sends an event | |
Checks if a Standard Product exists and if not sends an event | |
Checks if a Variant Product exists and if so sends an event | |
Checks if a Variant Product exists and if not sends an event | |
Checks if a Virtual Position exists and if not sends an event | |
Load the given Inventory Position and its Inventory Quantity (of the
| |
Load the given Inventory Position data and send an event This Rule is a simplified version of the | |
Loads the status of the related Product and Location for an Inventory Position and send an event | |
Loads the virtual position details and then sends an event | |
Send an event to an Inventory Catalog on Product update | |
Send an event (or multiple events) to Virtual Catalog(s) if its Network(s) finds a match with a given Inventory Position Location Network(s). | |
Send an event (or multiple events) to the Virtual Catalog(s) specified by its Reference(s) if its Network(s) finds a match with a given Inventory Position Location Network(s). | |
Send an event (or multiple events) to Virtual Catalog(s) specified by its Type(s) if its Network(s) finds a match with a given Inventory Position Location Network(s). | |
Send events to all Inventory Positions related to the given Location | |
Send events to all Inventory Positions related to the given Product | |
Send events to all Virtual Positions when a control is updated | |
Set a Base Virtual Position value to 0 | |
Send an event | |
Send events to create fulfilment related Inventory Quantities | |
Send an event to all Inventory Quantities related to an Inventory Position | |
Notifies the inventory positions of the incoming deltas with an event | |
Update an Aggregate Virtual Position | |
Update a Base Virtual Position | |
Update related Categories for a Standard Product | |
Update related Categories for a Variant Product | |
Update a Category | |
Update the value of a Control | |
Bulk update Inventory Quantities related to an Inventory Position | |
Update an Inventory Quantity | |
Update an Inventory Positions onHand | |
Update a Standard Product | |
Update a Variant Product | |
Create or Update an Inventory Quantity | |
Validate whether the given categories exist | |
Validate if the given category exists | |
Validate if the given product exists | |
Validate if the categories in the product payload exist | |
Validate if a standard product has valid information | |
Validate if a variant product has valid information |
Features

Capability type: | Module |
---|