Skip to content

URD: Product

ModuleCORE-05Versionv0.4
StatusBuiltDate2026-05-29

1. Purpose

Define the user-facing requirements for product catalogue management: how owners create and maintain products, the variants they actually sell, the prices (fares) those variants carry, the categories that organize them, and the identifiers used to look them up. The catalogue is the foundation every selling channel reads from.

2. Scope

IncludedExcluded
Product create / update / status managementBill of Materials & recipes → Inventory
Categories (with add-on flag)Stock levels per location → Inventory
Variants and aggregate variant operationsOrder processing & checkout → Orders
Fares and fare sets (pricing input)Promotion discount calculation (In-progress)
Multi-scheme identifiers (SYSTEM, SLUG, SKU, BARCODE, QRCODE)Unit-conversion engine (Planned)
Sale-channel availabilityCSV / bulk import (Planned)
Variant types & units of measureTechnical API specifications → developer docs
Role-based data filtering

Conceptual definitions only — concrete schema and behavior live in commerce domain model and pricing fares.

3. Definitions

TermDefinition
ProductA base item in a merchant's catalogue.
VariantA sellable unit of a product (e.g. a size or flavour). What is actually sold and priced.
Variant typeClassification driving stocking & bundling: STORABLE, CONSUMABLE, SERVICE, KIT, COMBO, MANUFACTURED.
Fare setThe pricing container linked 1-to-1 to a variant.
FareA price entry inside a fare set; can be a base price, an override, or a quantity/time/channel tier.
CategoryA product grouping within a merchant; can be flagged add-on.
IdentifierA scheme-based code (SYSTEM, SLUG, SKU, BARCODE, QRCODE) used for lookup.
BundleA combo, add-on, or frequently-bought-together relationship between variants.
Sale-channel productA mapping controlling which products appear in which channels.

4. Conceptual Model

Conceptual only — full schema lives in the commerce domain model and pricing fares.

5. Functional Requirements

One table per functional area. <AREA> codes match the test-case IDs. Priority = MoSCoW (Must / Should / Could / Won't).

5.1 Product (PRD)

IDPRequirementStatus
URD-PRD-001MOwner can create a product within a merchantBuilt
URD-PRD-002MEach product gets a system-generated identifier and slugBuilt
URD-PRD-003MProduct name & description support multiple languagesBuilt
URD-PRD-004MA default variant is created with each new productBuilt
URD-PRD-005MOwner can update product informationBuilt
URD-PRD-006MOwner can deactivate / reactivate / archive a productBuilt
URD-PRD-007MProduct slug is unique within the same merchantBuilt
URD-PRD-008MUser can find a product by ID or slugBuilt
URD-PRD-009MUser can view a product list (role-filtered)Built
URD-PRD-013SOwner can attach images / media to productsBuilt
URD-PRD-014SOwner can assign products to specific sale channelsBuilt
URD-PRD-015SArchived products are read-only (terminal status)Built
URD-PRD-016SProducts support a parent-child hierarchyBuilt
URD-PRD-017SUser can search products by name (partial, i18n-aware)Built
URD-PRD-018SUser can filter the product list by categoryBuilt
URD-PRD-019COwner can import a catalogue from CSV / spreadsheetPlanned

5.2 Category (CAT)

IDPRequirementStatus
URD-CAT-001MOwner can create categories within a merchantBuilt
URD-CAT-002MCategory name supports multiple languagesBuilt
URD-CAT-003MOwner can update and delete categoriesBuilt
URD-CAT-004SA category can be flagged as add-onBuilt

5.3 Variant (VAR)

IDPRequirementStatus
URD-VAR-001MEvery product has at least one variant; status can changeBuilt
URD-VAR-002MOwner can create additional variantsBuilt
URD-VAR-003MAggregate create: variant + info + fare set + fares + identifiers in one atomic stepBuilt
URD-VAR-004MAggregate update: update a variant with all related data atomicallyBuilt
URD-VAR-005MEach variant has a system-generated identifierBuilt
URD-VAR-006MVariant type (STORABLE / CONSUMABLE / SERVICE / KIT / COMBO / MANUFACTURED) is selectableBuilt
URD-VAR-007SVariant can have an effective date rangeBuilt
URD-VAR-008SOwner can assign SKU / BARCODE / QRCODE identifiersBuilt
URD-VAR-009SVariant stores base / purchase / sale units of measureBuilt
URD-VAR-010SBundles relate variants as combo / add-on / frequently-bought-togetherBuilt
URD-VAR-011CA variant's resolved price can be read via a dedicated endpointPlanned
URD-VAR-012CUnit conversions between purchase and sale unitsPlanned

5.4 Fare / Pricing (FAR)

IDPRequirementStatus
URD-FAR-001MEvery variant has exactly one fare setBuilt
URD-FAR-002MEvery fare set contains at least one (default) fareBuilt
URD-FAR-003MFare amount must be zero or positiveBuilt
URD-FAR-004MAt sale time the system resolves the applicable fare: override → discount → defaultBuilt
URD-FAR-005SFares can have effective date rangesBuilt
URD-FAR-006SFares can have min / max quantity windowsBuilt
URD-FAR-007SFares support parent-child groups with context rules (channel, time, quantity)Built

The current fare model uses OVERRIDE and DISCOUNT group types (an earlier draft labelled these SALE/OVERRIDE). See pricing fares.

5.5 Identifiers (PID)

IDPRequirementStatus
URD-PID-001MEach identifier is unique per scheme within a merchantBuilt
URD-PID-002MA product / variant can hold multiple identifiers across schemesBuilt
URD-PID-003MSYSTEM and SLUG identifiers are auto-generated on creationBuilt
URD-PID-004SOwner can assign SKU, BARCODE, QRCODE identifiersBuilt

5.6 Promotions (CMP)

IDPRequirementStatus
URD-CMP-001SOwner can create and manage promotion campaigns (with date range, usage limit)In-progress
URD-CMP-002SPromotions are scoped to a merchantIn-progress
URD-CMP-003CPromotion discounts are applied automatically at pricing timePlanned

Promotion CRUD is functional; the discount calculation engine is disabled, so discounts are not yet applied automatically. See pricing promotions.

5.7 Access (ACC)

IDPRequirementStatus
URD-ACC-001MAll product operations are filtered by the requesting user's roleBuilt
URD-ACC-002MOwner sees only products under own merchantsBuilt
URD-ACC-003MEmployee sees only products in assigned merchantsBuilt
URD-ACC-004MAdmin / Super Admin bypass role filteringBuilt

6. Acceptance Criteria

AC-PRD-01: Product creation
GivenWhenThen
Owner with an active merchantCreates a product with name + categoryProduct created with generated identifiers; default variant created; product linked to merchant
Slug would collideSystem ensures a unique slug within the merchant
AC-VAR-01: Aggregate variant
GivenWhenThen
An existing productOwner creates a variant with info, fares, and identifiers in one stepVariant + info + fare set + fares + identifiers created atomically
Any sub-step failsEntire operation rolls back; nothing is persisted
AC-FAR-01: Fare resolution
GivenWhenThen
A variant with multiple active faresAdded to cartOverride group wins; otherwise lowest qualifying discount; otherwise the default fare; date & quantity windows filter candidates first
No qualifying fareThe default (base) fare is used
AC-ACC-01: Role-based access
GivenWhenThen
Owner with merchants X, YViews productsOnly products under X and Y are returned
Employee assigned to XViews productsOnly products under X are returned
AdminViews productsAll products returned; filtering bypassed

7. Constraints & Non-Goals

Constraints

IDConstraint
C-01A product belongs to exactly one merchant
C-02Product slug is unique within the same merchant
C-03Every product has at least one variant
C-04Every variant has exactly one fare set with at least one fare
C-05Aggregate create / update operations are all-or-nothing
C-06All records use soft-delete; nothing is physically removed
C-07Role-based filtering applies to every list and count operation

Non-Goals

  • Bill of Materials / recipe management (→ Inventory)
  • CSV / Excel bulk import
  • Unit-conversion engine
  • Promotion discount calculation (CRUD only today)

8. Version History

DateAuthorDescriptionVer
2026-02-26P. Do — Product OwnerInitial user stories & requirementsv0.1
2026-04-16P. Do — Product OwnerExpanded variant & fare requirementsv0.3
2026-05-29Docs migrationRestructured to module-docs convention; status-honest Built/In-progress/Planned per dev docs; promotions split from inventory (moved to Inventory module)v0.4

Proprietary and Confidential. Unauthorized copying, distribution, or use of this software is strictly prohibited.