Stockeo Help
Ask or search…
K

Image URL settings

XML

You may encounter an XML structure where links to images are stored in separate Image nodes.
Screenshot
XML snippet
Images stored in separate Image nodes annotated
Images stored in separate Image nodes
<Product>
<Items>
<ProductItem>
<ItemCode>A012345</ItemCode>
<ItemImage1>http://warehouse.com/images/A012345.jpg</ItemImage1>
<ItemImage2>http://warehouse.com/images/A012345_1.jpg</ItemImage2>
</ProductItem>
</Items>
</Product>
For the notation above, use the following settings in the Image URL fields:
Screenshot
Copy from here
Stockeo settings for Image URL fields when images are stored in separate ItemImage nodes annotated
Stockeo settings for Image URL fields when images are stored in separate ItemImage nodes
Image URL: Items/ProductItem/ItemImage1
Image URL: Items/ProductItem/ItemImage2
It may also happen that the URLs are nested as children of the Image node.
Screenshot
XML snippet
Images stored in the child nodes of ItemImages node annotated
Images stored in the child nodes of ItemImages node
<Product>
<Items>
<ProductItem>
<ItemCode>A012345</ItemCode>
<ItemImages xmlns:d5p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays">
<d5p1:string>http://warehouse.com/images/A012345.jpg</d5p1:string>
<d5p1:string>http://warehouse.com/images/A012345_1.jpg</d5p1:string>
</ItemImages>
</ProductItem>
</Items>
</Product>
Use the following settings to access them:
Screenshot
Copy from here
Stockeo settings for Image URL fields when images are stored in in the child nodes of ItemImage node annotated
Stockeo settings for Image URL fields when images are stored in in the child nodes of ItemImage node
Image URL: Items/ProductItem/ItemImages/*[1]
Image URL: Items/ProductItem/ItemImages/*[2]
Another case is when the URLs are nested as the same named children of the Image node.
Screenshot
XML snippet
URLs are nested as the same named children of the Image node annotated
URLs nested as the same named children of the Image node
<Product>
<Items>
<ProductItem>
<ItemCode>A012345</ItemCode>
<ItemImages>
<ItemImage>http://warehouse.com/images/A012345.jpg</ItemImage>
<ItemImage>http://warehouse.com/images/A012345_1.jpg</ItemImage>
</ItemImages>
</ProductItem>
</Items>
</Product>
Get accees to them with these settings:
Screenshot
Copy from here
Stockeo settings when URLs are nested as the same named children of the Image node annotated
Stockeo settings when URLs are nested as the same named children of the Image node
Image URL: Items/ProductItem/ItemImages/ItemImage[1]
Image URL: Items/ProductItem/ItemImages/ItemImage[2]

JSON

In the JSON file images may be stored as an array of objects that consist of e.g. image id and image URL.
Screenshot
JSON snippet
Image URLs are stored as a property of the object in the product_images array annotated
Image URLs are stored as a property of the object in the product_images array
{
"data": [
{
"product_code": "A012345",
"product_name": "Sitting Jazz Band Strings",
"product_images": [
{
"id": 5856,
"image": "https://warehouse.com/images/A012345.jpeg"
},
{
"id": 5857,
"image": "https://warehouse.com/images/A012345_1.jpeg"
}
]
}
]
}
In this case use the following settings:
Screenshot
Copy from here
Stockeo settings when Image URLs are stored as a property of the object in the product_images array annotated
Stockeo settings when Image URLs are stored as a property of the object in the product_images array
Image URL: product_images[0].image
Image URL: product_images[1].image
Image URL: product_images[2].image
Please note that the indexing of array elements in JSON starts at 0.
You can add fields up to the highest expected number of images. This will not cause an error, even if there is no link to the image on the given index.