Product data model
Proposal
After our initial data conversation with Algolia 02/06/23 we have come up with the following proposal.
- We would need one index per language, resulting in 9 indices in total.
- en
- en-US
- en-AU
- fr
- de
- es
- ko
- ja
- zh
- We would need to index products at variant level.
- Each product will have a base product attribute to group results using it
- Each product will have a variants attribute with all the styles available
- Each product will have a sizes attribute with all the sizes available
Data model
Each product will have the following attributes
- objectID: Variant product code. This will be unique
- baseSku: Base product code
- active: If the product is active or not. Non active products are considered to be in
Trading Preview - name: Product name
- marketingMessage: Product marketing message in the corresponding language
- productType: Product type. Example: raphacore, event, rccmembership
- category: Product default category
- collections: Name of the collections to which the product belongs. This will be an array
- gender: Product gender. Possible values are Womens, Mens, Unisex, Kids
- sleeveLength: Product sleeve length. Example: long-sleeve, short-sleeve
- legLength: Product leg length. Example: knee-length
- conditions: Conditions for which the product is recommended. Example: cold
- groupColour: Friendly colour name. Example: Blue
- colour: This will be
groupColour;swatchColour - image: First mannequin image of the product
- order: Product priority
- variants: Styles available for the base product. This will be an array of objects with the following format
- sku: Product code
- swatchColour: Hex colour
- url: Product url
- image: First mannequin image of the variant product
- order: Colour priority
- sizes: Sizes available for this variant product. This will be an array
- prices: Product price in all the currencies available in the index language. This will be an array of objects with the following format
- currency: Currency isocode
- group: Price group. Example: default, rccpricegroup
- value: Price value
- previousPrices: Original product price in all the currencies available in the index language. This will be an array of objects with the following format
- currency: Currency isocode
- group: Price group. Example: default, rccpricegroup
- value: Price value
- ratings: Average overall rating
- url: Product url
Example
{
"objectID": "WBL03LSBLK",
"baseSku": "WBL03LS",
"active": true,
"name": "Women's Merino Base Layer - Long Sleeve",
"productType": "raphacore",
"category": "Base Layers",
"collections": ["Classics"],
"gender": "Womens",
"sleeveLength": "long-sleeve",
"conditions": "cold",
"marketingMessage": "New Season",
"groupColour": "Black",
"colour": "Black;#000000",
"image": "https://media.rapha.cc/image/upload/archive/amplience-image/WBL03LS_BLK_Product_H1-18_01",
"order": 9170,
"variants": [
{
"sku": "WBL03LSBGR",
"swatchColour": "#12403C",
"url": "/shop/womens-merino-base-layer-long-sleevee/product/WBL03LSBGR",
"image": "https://media.rapha.cc/image/upload/archive/amplience-image/WBL03LS_BGR_Product_H220_01",
"order": 99
},
{
"sku": "WBL03LSBLK",
"swatchColour": "#000000",
"url": "/shop/womens-merino-base-layer-long-sleevee/product/WBL03LSBLK",
"image": "https://media.rapha.cc/image/upload/archive/amplience-image/WBL03LS_BLK_Product_H220_01",
"order": 80
},
{
"sku": "WBL03LSBUR",
"swatchColour": "#4e1f30",
"url": "/shop/womens-merino-base-layer-long-sleevee/product/WBL03LSBUR",
"image": "https://media.rapha.cc/image/upload/archive/amplience-image/WBL03LS_BUR_Product_H220_01",
"order": 50
},
{
"sku": "WBL03LSBWT",
"swatchColour": "#28282D",
"url": "/shop/womens-merino-base-layer-long-sleevee/product/WBL03LSBWT",
"image": "https://media.rapha.cc/image/upload/archive/amplience-image/WBL03LS_BWT_Product_H220_01",
"order": 20
},
{
"sku": "WBL03LSDRD",
"swatchColour": "#AD0020",
"url": "/shop/womens-merino-base-layer-long-sleevee/product/WBL03LSDRD",
"image": "https://media.rapha.cc/image/upload/archive/amplience-image/WBL03LS_DRD_Product_H220_01",
"order": 20
}
],
"sizes": ["Large", "Medium", "Small", "X-Large", "X-Small", "XX-Small"],
"prices": [
{
"currency": "GBP",
"group": "default",
"value": 85
},
{
"currency": "GBP",
"group": "rccpricegroup",
"value": 80
},
{
"currency": "EUR",
"group": "default",
"value": 95
}
],
"previousPrices": [
{
"currency": "GBP",
"group": "default",
"value": 95
},
{
"currency": "GBP",
"group": "default",
"value": 105
}
],
"ratings": 4.3,
"url": "/shop/womens-merino-base-layer-long-sleevee/product/WBL03LSBLKLRG"
}
Data configuration
| Property | Type | Searchable | Filterable | Display | Business Ranking |
|---|---|---|---|---|---|
| objectID | string | N | N | N | N |
| baseSku | string | N | N | N | N |
| active | boolean | N | Y | N | N |
| name | string | Y | N | Y | N |
| productType | string | N | N | N | N |
| category | string | Y | N | N | N |
| collections | array - string (name) | Y | Y | N | Y |
| gender | string | Y | Y | N | Y |
| sleeveLength | string | Y | Y | N | Y |
| legLength | string | Y | Y | N | Y |
| conditions | string | Y | Y | N | Y |
| marketingMessage | string | Y | N | Y | N |
| groupColour | string | Y | Y | N | Y |
| colour | string | N | N | N | N |
| image | string (url) | N | N | Y | N |
| order | number | N | N | N | Y |
| variants | array - Variant | N | N | Y | N |
| sizes | array - string | Y | N | N | N |
| prices | array - Price | N | Y | Y | N |
| previousPrices | array - Price | N | N | Y | N |
| ratings | string | N | Y | Y | Y |
| url | string | N | N | Y | N |