Type | Description |
---|---|
Products | Designed for storing product data, including structures like variants and prices. |
Content | Used for storing all other types of data. |
key
- a unique identifier for the recordactive
- a boolean field to enable or disable a recordoptions
- a field to store a list of options that define the variantprice
- a field to store the price of the variantOption
composite type, that field will always be an array field. We’re using that structure to create dynamic filters for all options, if you choose this field in a listing.
Connect a data feed
Merge
tab to see the fields that you can map.
You are presented with two columns - Storage Fields and Map To Value.
Storage mapping in Data Sync > Merge
Types of value mappings - composed, mapped, static
vendor.name
and productName
fields to fill the storage field label
- like “Apple - iPhone 13”.
1. Change the mapping mode to `composed`
2. Add the `concat` function
concat
operation (you can also search for it)3. Add the fields to concatenate
4. Save the configuration
5. Test the configuration
6. Test with custom data or a real record
if
function to conditionally set a value for the availability to ‘In Stock’ or ‘Low Stock’ depending on whether the stock is above or below 10.
1. Change the mapping mode to `composed` and add the `if` function
composed
and add the if
function.2. Add the condition
if
function takes three arguments:composed
and add the greaterthan
function.3. Configure the arguments
greaterthan
function takes two argumentsvalue
- the value used as a reference - in our case the stockcompare
- the value to compare to - in our case 10value
argument to mapped
and the compare
argument to static
.The screenshot also shows the return values then
and else
set to In Stock
and Low Stock
respectively.4. Test the configuration
stock
field.description
- the description of the image (e.g. “iPhone Pro front view”)type
- the type of the image (e.g. “image/jpeg”)url
- the url of the image (e.g. “https://cdn.example-store.com/images/[image-id]/gallery.jpg”)1. Analyse the output structure
MediaFile
with the following fields:description
- the description of the image (e.g. “iPhone Pro front view”)type
- the type of the image (e.g. “image/jpeg”)url
- the url of the image (e.g. https://cdn.example-store.com/images/[image-id]/gallery.jpg
)2. Add the reference array
images
array from the feed record payload.images
and add the field to the schema manually.3. Map the remaining fields
$item
variable.$parent
accessor.
For example if each image would have a list of versions (e.g. for different sizes), you could access the description of the parent record with $parent.description
.4. Test the configuration
alt
and type
fields are directly mapped using the $item
accessor.
The url
field is composed using the concat
function, building a string like this (pseudo code):5. Test the configuration
images
into a new array of MediaFile
objects.