Variation feed allows you to automate the process of creating, editing, and removing variations. It is done by choosing a template, and connect it to a CSV or XML file with the variations metadata (images, titles, etc.). Whenever the file changes - the variations will change as well.
Step 1: Design Your Template
- Create a template of the variations.
- Turn into a variable every part of the template that you want to be populated by the variation feed. For example, if you want the image to be different for every variation, and the image URL is in the variation feed - the image src should be a variable.
Step 2: Prepare the File
The file can be a CSV or an XML file, that you can either upload to Dynamic Yield or host on your server.
- Every row is a variation.
- Columns are the variables. For example, if you have 3 variables for the title, image URL and link - file must include at least 3 columns - for each one of the variables.
- File must have at least one column that will have a unique value. It can be an additional column (that is not used in any variable). This column will be used for the variation name.
- Avoid using spaces or special characters in the title. If there are special characters in the table, save the file in UTF8 format.
- Values must include less than 1,000 characters.
|Title||Image URL||Target URL|
|New summer collection||acme.com/img/summer.png||acme.com/summer|
|Complete the look||acme.com/img/complete.png||acme.com/collection|
Step 3: Create a Variation Feed
- Go to Assets › Data Feeds.
- Click Add New and select Variation Feed.
- Name the feed.
- In the Feed Source, you can do one of the following:
- Upload the file: After you will connect variations to the variation feed, they will update every time you replace the file.
- Paste the URL that hosts the file: Whenever the file changes - the variations will change.
- Under the Advanced Settings:
- If the feed source is a URL on your servers, choose the sync rate.
- Use a Parser Function to adapt and manipulate the feed source, to create a simple, flat table that will be the variation feed.
- Click Preview.
- Choose a column with a unique value in the "Unique Key" settings.
- Choose a column that will be served as the variation name in the "Variation Name Key". The variation name will later appear in the reports, so make sure it is descriptive to the variation content.
- Click Save and Activate.
Tip: You can use the same feed for multiple experiences or campaigns, and add a column that will later be used as a filter, and set a different filter per experience. For example, if you have promotions for mobile users and promotions for desktop users, you can have them in the same feed. Add a column "Device", and a value of "Mobile" or "Desktop". When you'll create an experience that is targeted to mobile users, you will be able to filter rows that include "Mobile" value in the "Device" column. The same goes for an experience that is targeted at desktop users.
Step 4: Create Your Campaign
- Create a campaign that will contain the experience with your variations.
- When you create a new experience, under the Variation wizard step, click the "Syncing it with a Data Feed" button:
- Select the template you created in Step 1.
- In the template, select the variation feed you created in Step 3.
- In the template, map the feed columns to the template variables. When you map, you will immediately see in the preview how the variation will look like if will be based on the first row of the feed.
- Choose which variations to create.
- Decide how many (1-50) and which variation to create.
- You can also filter rows by a value in the feed.
- Click Sync Variations. The variations are added to an experience in the campaign.
- Click Save Experience and Save and Publish.
- You can always click the "Sync Settings" to change the template, the variation feed, the mapping, or the filter.
That's it! Your experience is synced with the variation feed:
- When rows are added - new variations will be created.
- When rows are removed - variations will be deleted.
- When values change in the variation feed - variation will change as well.
The variations will not sync if:
- A new version of the feed source is empty (relevant if the feed is hosted on your server)
- There are no rows in the feed that matches the filters