Skip to main content
The catalog’s data models belong to Medusa’s Product module, version 2.22. Mercur adds no columns to them. It adds relations through module links, listed under each model. Every model also has created_at, updated_at, and deleted_at timestamps that Medusa manages.

Product

The shared master product. Table product, id prefix prod. Native relations:
  • variants: ProductVariant[], deleted with the product
  • options: ProductOption[] through the ProductProductOption pivot
  • images: ProductImage[], deleted with the product
  • categories: ProductCategory[] through product_category_product
  • collection: ProductCollection, nullable
  • type: ProductType, nullable
  • tags: ProductTag[] through product_tags
Mercur relations:
  • sellers: Seller[], the store allowlist in product_seller
  • product_attribute_values: attribute values attached to the product
  • scoped_attributes: product-scoped attributes, read-only
  • changes: ProductChange[], the audit and edit history, read-only
  • reviews: Review[]

ProductVariant

One purchasable configuration of a product. Table product_variant, id prefix variant. Relations: product (nullable), options (ProductOptionValue[] through product_variant_option), and images (ProductImage[]). Mercur links offers to variants through offer.variant_id. Each store’s price and stock live on the offer, not here.

ProductOption

An axis that variants vary on. Table product_option, id prefix opt. Relations: products and values (ProductOptionValue[]). A variant-axis attribute mirrors one option through product_attribute.product_option_id.

ProductOptionValue

One value of an option. Table product_option_value, id prefix optval. Relations: option (nullable), variants, and product_options.

ProductImage

A product image. Table image, id prefix img. Relations: product and variants.

ProductCategory

A node in the category tree. Table product_category, id prefix pcat. Relations: parent_category (nullable), category_children (deleted with the parent), and products. Mercur adds sellers, media_images, and the product attribute link.

ProductCollection

A flat group of products. Table product_collection, id prefix pcol. Relations: products. Mercur adds media_images.

ProductTag

A free-form label. Table product_tag, id prefix ptag. Relations: products.

ProductType

A single classification per product. Table product_type, id prefix ptyp. Relations: products.