A feed is a file that contains a list of products that you want to advertise through Merchant Center. When you add your products, you'll assign attributes to each one. Your product feeds will use these attributes to group your products together. Once you've created a feed, it can be used multiple times across as many Merchant Center features as you need.
For Devs: The product feed is created by placing the data in a certain way and then either deserializing into JSON/XML format or using the CSV format. The structure can be defined using the following code:
Products consist of: SKU, Name, Description, Categories, Variants and Attributes.
Use the SKU field to uniquely identify each product. This won't be shown to customers who view your products online. This shouldn't be confused with sizes/variants of each product i.e ItemNumber/EAN/GTIN.
Use the Name field to clearly identify the product.
Use the Description field to provide more details about the product. List product features, technical specifications and visual attributes in a textual manner.
Use the Categories field to include your own product categorisation system in your product data. There are no predefined categories, instead you may choose which values to include for the product.
Categories have a hierachical structure using the >
seperator e.g Home > Kitchen > Appliances > Cooker
.
Multiple categories are seperated on a specific list seperator, this is determined when you send the file.
Once the feed is processed the entire hierachical structure will be created from the category string e.g
Home
, Home > Kitchen
, Home > Kitchen > Appliances
.
Existing categories will be matched based on the name e.g root category Home
will be matched against Home > Bathroom > Sink
.
Examples of this field could be:
Shoes & Accessories > Men's Accessories > Gifts for Him
Shoes & Accessories > Men's Accessories > Cufflinks, Pins & Tie Clips
Menswear > Men's Shirts
Promotions > 20% off coats & shoes
Promotions
Use the Variants field to determine what exact item is in the Basket. This could be EAN or GTID. The stock count should also be passed in here to keep track of fragmented stock.
By using a combination of Key and Value, products can be grouped together so they can be interchanged with one another. For example, for clothing this could be size, but for Camera's it could be Model Colour.
Examples of this field for a suit jacket could be:
ItemNumber | Key | Value | Quantity |
---|---|---|---|
139467 | Suits | 40 (EU 50) | 12 |
139462 | Suits | 42 (EU 52) | 44 |
139470 | Suits | 44 (EU 54) | 56 |
Whereas for a phone where the difference in model a combination of colour and storage space:
ItemNumber | Key | Value | Quantity |
---|---|---|---|
Phone000001 | Colour / Size | RED 64GB | 33 |
Phone000002 | Colour / Size | YELLOW 64GB | 12 |
Phone000003 | Colour / Size | BLUE 128GB | 15 |
Use the Attributes field to include additional details related to the product. These are stored in Key Value Pair combinations and allow products to be grouped together in the backend.
Examples of this field could be:
Colour
/ Pink
Pattern
/ Plain
Country of Origin
/ UK
Once your feed is created, you'll add your product data by uploading a data feed to an online URL. Currently supported file formats are:
The file extension must be .csv. The first line of the file must be the header row with every subsequent line/row containing the details of the products.
Since Categories, Variants and Attributes are lists of self contained structured data these must be provided in a particular format with CsvListSeperator
and CsvPropertySeperator
characters.
List of category strings seperated with a CsvListSeperator
character.
In this case |
has been used.
"Clothing > Underwear & Socks > Socks|Eveningwear|Shoes & Accessories > Men's Accessories|Men's Gift > Under £35"
Since variants contain the properties: ItemNumber, Key, Value, Quantity
. The csv cell must be presented with a CsvPropertySeperator
character as well.
In this case ~
has been used.
"100001S~Socks~SMALL~32|100001M~Socks~MEDIUM~156|100001L~Socks~LARGE~29"
Attributes contain the properties: Key, Value
.
In this case ~
has been used.
"Material~Cotton|Pattern~Plain|Colour~Black|Country of Origin~UK|Gender~Men|Product Type~Socks|Fashion Category~Formalwear"
An example would look like this:
The file extension must be .json. This far easier to create since you can just structure your data into classes and deserialise using third party libaries directly.
See the section Code Structure above for class examples. You may find https://json2csharp.com and https://www.newtonsoft.com useful as well.
An example would look like this:
The file extension must be .xml. This far easier to create since you can just structure your data into classes and deserialise using third party libaries directly.
See the section Code Structure above for class examples. You may find the documentation on XmlSerializer useful as well.
An example would look like this:
Make the call to our API to schedule the product feed file to be ingested. We authenticate your API requests using your account's vendor API keys.
Depending on your account you could have multiple vendors (UK website, US website etc). Each Vendor will have their own ApplicationId
and ApiKey
. The API will return an invalid request error if you don’t include a key or if the key is incorrect.
You can use the Dashboard to create API keys.
POST api/Feed/UpdateProducts
https://adyen12-api.azurewebsites.net/api/Feed/UpdateProducts
Method to schedule product feed file to be ingested. File must contain products otherwise it will not be ingested.
Parameters:
ApplicationId
required
Obtained from the dashboard.
ApiKey
required
Obtained from the dashboard.
CsvFilePath
optional
Your uploaded CSV file path. This can be URL protected e.g "www.website.com/file.csv?secretkey=19d8da15-54fc-41c9-8867-50b7a229fd4a"
JsonFilePath
optional
Your uploaded JSON file path. This can be URL protected e.g "www.website.com/file.json?secretkey=19d8da15-54fc-41c9-8867-50b7a229fd4a"
XmlFilePath
optional
Your uploaded XML file path. This can be URL protected e.g "www.website.com/file.xml?secretkey=19d8da15-54fc-41c9-8867-50b7a229fd4a"
CsvListSeperator
required with CsvFilePath
Required when product feed is a CSV file. This is the list seperator character e.g "|"
CsvPropertySeperator
required with CsvFilePath
Required when product feed is a CSV file. This is the property seperator character e.g "~"
Request Examples:
{ "applicationId": "[YOUR_APPLICATION_ID]", "apiKey": "[YOUR_API_KEY]", "csvFilePath": "https://www.website.com/file.csv?secretkey=19d8da15-54fc-41c9-8867-50b7a229fd4a", "csvListSeperator": "|", "csvPropertySeperator": "~" }
{ "applicationId": "[YOUR_APPLICATION_ID]", "apiKey": "[YOUR_API_KEY]", "jsonFilePath": "https://www.website.com/file.json?secretkey=19d8da15-54fc-41c9-8867-50b7a229fd4a", }
Response Examples:
{ "Success": true, "ErrorMessage": null, "ProductFeedCount": { "Products": 1967, "Categories": 470, "Variants": 122, "Attributes": 563, "ProductVariants": 15729 } }
{ "Success": false, "ErrorMessage": "Missing File Path", "ProductFeedCount": null }
{ "Success": false, "ErrorMessage": "Missing CsvListSeperator and/or CsvPropertySeperator", "ProductFeedCount": null }
{ "Success": false, "ErrorMessage": "Missing ApplicationId and/or ApiKey", "ProductFeedCount": null }
{ "Success": false, "ErrorMessage": "Unauthorized Vendor: ApplicationId and/or ApiKey not valid", "ProductFeedCount": null }
POST api/Feed/UpdateProductStock
https://adyen12-api.azurewebsites.net/api/Feed/UpdateProductStock
The same method as UpdateProduct but will do a partial update of the stock quantity only. Much quicker to run. If the feed contains new products or variants, then these will be ignored and highlighted in the response.
Parameters:
See method UpdateProduct.
Request Examples:
See method UpdateProduct.
Response Examples:
{ "StockUpdate": { "ProductsUpdated": 1967, "VariantsUpdated": 15729, "ProductsNotFound": 16086, "VariantsNotFound": 0 }, "Success": true, "ErrorMessage": null }
POST api/Feed/DeleteProducts
https://adyen12-api.azurewebsites.net/api/Feed/DeleteProducts
Method to wipe all product data. This is called seperately to ensure invalid/empty product files do not wipe data accidentally.
Parameters:
ApplicationId
required
Obtained from the dashboard.
ApiKey
required
Obtained from the dashboard.
Request Examples:
{ "applicationId": "[YOUR_APPLICATION_ID]", "apiKey": "[YOUR_API_KEY]", }
Response Examples:
{ "Success": true, "ErrorMessage": null }
{ "Success": false, "ErrorMessage": "Unauthorized Vendor: ApplicationId and/or ApiKey not valid" }