Loading Line Sheet Data¶
In VibeIQ, "line sheet data" refers to Item, ProjectItem, and AssortmentItem data.
Item
: Item data is global and exists outside the context of a Project.- Items can also be part of a Family, as indicated by a single Family Item. Families can have Options, which are variations of the Family Item. In other terms, you could think of this as Product (Family) vs Colorway (Option).
ProjectItem
: ProjectItem data is specific to an Item as it exists in a Project.- This is typically considered as seasonal data and can change season over season.
- If an Item is carried over into a following season, the data from the prior season, as represented by ProjectItem, will not necessarily be the same.
AssortmentItem
: AssortmentItem data is specific to an Item as it exists within an Assortment and a Project.- An item can exist within many different Assortments in a single Project.
- Organizing your regions into many assortments is an example of this.
Despite this hierarchical structure: Item (Global) > ProjectItem (Seasonal) > AssortmentItem (Grouping/Regional), the load file for this structure remains tabular-CSV. This is possible because a single property key should not be shared across more than one of these three entities. An important note, the loader is only able to load data for one project at a time when it comes to ProjectItems and AssortmentItems.
Loading Items¶
Required Properties¶
In your load file, you must provide the following properties for each row. These may be the CSV column headers or usage of federatedMappings
or conditionalColumns
in the loader configuration to match these keys.
Loading an Item Option for a Family:¶
itemFamilyFederatedId
: The federatedId of the Item Option's Family Item.name
: The name of the Item Option's Family Item.itemOptionFederatedId
The federatedId of the Item Option.optionName
: The name of the Item Option itself.
Upon load, the loader will search for an Item Option by itemOptionFederatedId
. If one does not exist, a new Item will be created and assigned to the Item Family that has federatedId
of itemFamilyFederatedId
. If that Item Family does not exist, it will be created as well.
name
and optionName
will be updated on the Family and Option Items, respectively, if they already exist. Therefore, it's critical that name
and optionName
remain consistent across subsequent loads of the same Items.
loadType:
- ITEM
federatedMappings:
itemFamilyFederatedId: 'style'
itemOptionFederatedId: 'colorName'
name: 'styleName'
optionName: colorName
conditionalColumns:
- default: item:product:apparel
toProperty: typePath
- default: color
toProperty: optionGroup
{
"loadType": ["ITEM"],
"federatedMappings": {
"itemFamilyFederatedId": "style",
"itemOptionFederatedId": "colorName",
"name": "styleName",
"optionName": "colorName"
},
"conditionalColumns": [
{
"default": "item:product:apparel",
"toProperty": "typePath"
},
{
"default": "color",
"toProperty": "optionGroup"
}
]
}
Loading Only an Item Family¶
itemFamilyFederatedId
: The federatedId of the Item Option's Family Item.name
: The name of the Item Option's Family Item.
Upon load, the loader will search for an Item Family by itemFamilyFederatedId
. If one does not exist, a new Item will be created.
name
will be updated on the Family Item if it already exists. Therefore, it's critical that name
remains consistent across subsequent loads of the same Items.
loadType:
- ITEM
federatedMappings:
itemFamilyFederatedId: 'style'
name: 'styleName'
conditionalColumns:
- default: item:product:apparel
toProperty: typePath
- default: color
toProperty: optionGroup
{
"loadType": ["ITEM"],
"federatedMappings": {
"itemFamilyFederatedId": "style",
"name": "styleName",
},
"conditionalColumns": [
{
"default": "item:product:apparel",
"toProperty": "typePath"
},
{
"default": "color",
"toProperty": "optionGroup"
}
]
}
Loading ProjectItems:¶
Required Properties¶
Because ProjectItems require an Item, names and federatedId
s are already required. We also need a way of knowing what project to use. We can do this with either:
- Assortment Parameters if loading into an Assortment. See the AssortmentItem section for more information.
- If only loading items into a Project and not also loading them into an Assortment,
workspaceIdentifier
specifies the ID of the project to load into.
Example loading just into a Project, without an Assortment load: workspaceIdentifier
:
loadType:
- ITEM
- PROJECT_ITEM
federatedMappings:
itemFamilyFederatedId: 'STYLE_NUMBER'
name: 'STYLE_NAME'
itemOptionFederatedId: 'MATERIAL_OPTION_NUMBER'
itemOption: 'MATERIAL_OPTION_NAME'
workspaceIdentifier: 'fall:2022'
{
"loadType": ["ITEM", "PROJECT_ITEM"],
"federatedMappings": {
"itemFamilyFederatedId": "STYLE_NUMBER",
"name": "STYLE_NAME",
"itemOptionFederatedId": "MATERIAL_OPTION_NUMBER",
"itemOption": "MATERIAL_OPTION_NAME"
},
"workspaceIdentifier": "fall:2022"
}
Loading AssortmentItems¶
Required Properties¶
Loading AssortmentItems means taking a list of Items and inserting them into an Assortment. An Item's existence in an Assortment is specified by the AssortmentItem entity. There are two types of AssortmentItem loads:
Full Assortment Load (default)¶
When performing a full load, the entire state of the Assortment's Items will match the load file. This means that any Items not in the load file will be removed from the Assortment. Using the parameters below, you may use the Assortment's ID or Identifier to dictate the Assortment to load into.
assortmentId
: The ID of the Assortment to load into.assortmentIdentifier
: The identifier of the Assortment to load into. This is an internal property and is not the Assortment Name.assortmentSplit
: An object allowing you to conditionally split the Items in the load file across multiple assortments.fieldToSplitOn
: The column name in the load file to use for splitting.values
: An array of objects specifying the value to split on and the Assortment to load into.value
: The value in thefieldToSplitOn
column to split on. Example"mens"
.assortmentId
: The ID of the Assortment to load any rows withvalue
matching in columnfieldToSplitOn
.assortmentIdentifier
: The identifier of the Assortment to load any rows withvalue
matching in columnfieldToSplitOn
.- This may be combined with
assortmentId
only within theassortmentSplit
object.
- This may be combined with
Example with assortmentId
:¶
loadType:
- ITEM
- ASSORTMENT
- PROJECT_ITEM
federatedMappings:
itemFamilyFederatedId: 'style'
itemOptionFederatedId: 'colorName'
name: 'styleName'
optionName: colorName
conditionalColumns:
- default: item:product:apparel
toProperty: typePath
- default: color
toProperty: optionGroup
assortmentId: "assortmentId1"
# assortmentIdentifier: "assortmentIdentifier2" # this may be used interchangeably with assortmentId
{
"loadType": [
"ITEM",
"ASSORTMENT",
"PROJECT_ITEM"
],
"federatedMappings": {
"itemFamilyFederatedId": "style",
"itemOptionFederatedId": "colorName",
"name": "styleName",
"optionName": "colorName"
},
"conditionalColumns": [
{
"default": "item:product:apparel",
"toProperty": "typePath"
},
{
"default": "color",
"toProperty": "optionGroup"
}
],
"assortmentId": "assortmentId1"
// "assortmentIdentifier": "assortmentIdentifier2" // this may be used interchangeably with assortmentId
}
Example with assortmentSplit
:¶
loadType:
- ITEM
- ASSORTMENT
- PROJECT_ITEM
federatedMappings:
itemFamilyFederatedId: 'style'
itemOptionFederatedId: 'colorName'
name: 'styleName'
optionName: colorName
conditionalColumns:
- default: item:product:apparel
toProperty: typePath
- default: color
toProperty: optionGroup
assortmentSplit:
fieldToSplitOn: wearer
values:
- value: mens
assortmentId: "assortmentId1"
- value: womens
assortmentIdentifier: "assortmentIdentifier2"
{
"loadType": [
"ITEM",
"ASSORTMENT",
"PROJECT_ITEM"
],
"federatedMappings": {
"itemFamilyFederatedId": "style",
"itemOptionFederatedId": "colorName",
"name": "styleName",
"optionName": "colorName"
},
"conditionalColumns": [
{
"default": "item:product:apparel",
"toProperty": "typePath"
},
{
"default": "color",
"toProperty": "optionGroup"
}
],
"assortmentSplit": {
"fieldToSplitOn": "wearer",
"values": [
{
"value": "mens",
"assortmentId": "assortmentId1"
},
{
"value": "womens",
"assortmentIdentifier": "assortmentIdentifier2"
}
]
}
}
Partial Assortment Load¶
To add Items to an Assortment without removing existing Items that do not exist in the load file, you may do so with a few properties
within assortmentSplit
. With them, you can either add or remove items from an Assortment without requiring the entire
Assortment's state on-hand while doing the load.
assortmentSplit
partialAssortmentUpdate?
: An optional boolean property indicating whether you want to perform a partial update on the Assortment instead of a full update.- Set this to
true
if you want to append the items in the load file to the assortment(s). - Set this to
false
or omit it if you want to perform a full update on the Assortment.
- Set this to
addField?
: An optional string property where if a value exists in the column of this name, the row will be added to the Assortment. Expected values in the CSV aretrue
,false
, or empty''
.dropField?
: An optional string property where if a value exists in the column of this name, the row will be dropped from the Assortment. Expected values in the CSV aretrue
,false
, or empty''
.fieldToSplitOn
: The column name in the load file to use for splitting.values
: An array of objects specifying the value to split on and the Assortment to load into.value
: The value in thefieldToSplitOn
column to split on. Example"mens"
.assortmentId
: The ID of the Assortment to load any rows withvalue
matching in columnfieldToSplitOn
.assortmentIdentifier
: The identifier of the Assortment to load any rows withvalue
matching in columnfieldToSplitOn
.- This may be combined with
assortmentId
only within theassortmentSplit
object.
- This may be combined with
Example with partialAssortmentUpdate
:¶
loadType:
- ITEM
- PROJECT_ITEM
- ASSORTMENT
assortmentSplit:
partialAssortmentUpdate: true
addField: addItem
dropField: dropItem
fieldToSplitOn: season
values:
- value: "spring"
assortmentId: "someAssortmentId"
{
"loadType": [
"ITEM",
"PROJECT_ITEM",
"ASSORTMENT"
],
"assortmentSplit": {
"partialAssortmentUpdate": true,
"addField": "addItem",
"dropField": "dropItem",
"fieldToSplitOn": "season",
"values": [
{
"value": "spring",
"assortmentId": "someAssortmentId"
}
]
}
}