Interface: ProductCategory
Represents a category for organizing products in the catalog.
The ProductCategory interface defines the structure and properties of a product category, which is used to group related products for easier discovery and navigation. Categories create a hierarchical organization system that helps users find products through browsing rather than direct search.
Categories play a crucial role in the shopping experience by providing intuitive navigation paths that match how customers naturally think about product types and relationships.
Properties
code?
optional
code:string
URL-friendly identifier for the category.
This code is used in URLs and as a machine-readable identifier for the category. It should be lowercase, contain no spaces, and use hyphens or underscores for word separation.
The code enables direct linking to category pages and is used in API calls that reference specific categories.
history?
optional
history:History
Revision history information for the category.
This property tracks changes made to the category over time, including when changes were made and by whom. This audit trail helps with troubleshooting and understanding category evolution.
History tracking is particularly important for categories that are frequently updated or managed by multiple administrators.
parentProductCategoryId
parentProductCategoryId:
string
ID of the parent category, if any.
This property establishes the hierarchical relationship between categories, identifying which category is the parent of this one. An empty or null value indicates this is a top-level (root) category.
Parent-child relationships create the category tree structure that enables drilldown navigation from general to specific product types.
productCategoryId
productCategoryId:
string
Unique identifier for this category.
This ID uniquely identifies this specific category within the system. It serves as the primary key for the category in databases and APIs.
This ID should be used for all operations that need to target this specific category, such as assigning products or updating settings.
productCategoryName
productCategoryName:
string
Display name of the category.
This is the human-readable name shown in the user interface for this category. It should be clear, concise, and accurately describe the types of products contained within the category.
The name is a key factor in users' ability to find and understand the category's purpose and contents.
products?
optional
products:string
[]
List of product IDs assigned to this category.
This property contains an array of IDs for all products that are assigned to this category. Products can belong to multiple categories, allowing them to be found through different navigation paths.
This association between products and categories powers category-based browsing and filtering in the product catalog.
status
status:
Status
Activation status of the category.
This property indicates whether the category is currently active (visible to users) or inactive (hidden from normal navigation). This allows categories to be temporarily removed without deleting them.
Only categories with ACTIVE status should normally be shown to end users, while INACTIVE categories might still be visible in administrative interfaces.