24/7 Support: 800.608.6482

Get Started

Reference Guide

Marketing

Feeds

1. Types of Feeds

2. To Create a Template Based Feed

3. To Download Your Template Feed

4. Ways to Run a Feed

Feeds were added in Miva Merchant release 9.0006.

In Miva Merchant, a feed is similar to an export. With a feed you can collect certain kinds of data from your store and make that data available in some way. You can:

  • Write the feed data to a file on your store server. See Enable File Creation
  • Email the data. See Enable Email Creation
  • Associate the feed with a URI (URL). When a person, or more likely a program of some kind, browses to the URI, the feed data is automatically generated. See:
    • Associating a Feed with a URI
    • To Associate a Feed with a URI - Method 1

Types of Feeds

As of 09/30/16, there are two types of feeds:

  • Template Based Feeds contain product, category, or customer information. See: To Create a Template Based Feed
  • XML Sitemap Feeds (also known as a "Standard Sitemap Protocol Feed") create special files that help search engines index your store pages. See: Sitemaps and Sitemap Feeds

To Create a Template Based Feed

  1. Go to Menu> Marketing > Feeds tab.
  2. In the Feeds tab, click Add Feed Add.
  3. Fill out the fields in the Add Feed dialog box. When you are done, click Add.
  4. Code: The code uniquely identifies the feed in your store database
    Name: The Name is used for display purposes in the admin interface.
    Feed Module: Select Template Based Feed
    Enable URI Access If you check this box, you'll be able to generate the feed data by web browsing to a URI. See:
    • Associating a Feed with a URI
    • To Associate a Feed with a URI - Method 1. See: To Associate a Feed with a URI - Method 1.
    URI Access Key Check this box if you want to password protect the URI. See: To Associate a Feed with a URI - Method 1.
    Enable File Creation Check this box if you want the feed data to be written to a file on your store server.
    File Location: This field is only used if you check the Enable File Creation checkbox.
    • Data (Private): The feed data will be written to a file in your MivaData folder. By default, this folder is at: /private/mivadata

      This folder is not accessible from the web. You can download this file to your local machine by using FTP. We recommend you use this folder for feeds that contain customer data.

    • Script (Public): The feed will be written to a file in the web server root folder (hotdogs by default). This folder is accessible from the web
    File Path:

    The File Path field lets you:

    • Set the name of the file that will contain the feed data. The File Path must begin with a forward slash "/".
    • Write the file to a subdirectory on your server. The subdirectory is relative to either the mivadata folder or the hotdogs folder. You must create this subdirectory before you can write files to it.

    Example 1:

    • Set the File Location field to Data.
    • Set the File Path field to: /myfeed.csv
    • Your file will be written to: private/mivadata/myfeed.csv

    Example 2:

    • Set the File Location field to Data.
    • Set the File Path field to: /feeds/myfeed.csv
    • Your file will be written to: private/mivadata/feeds/myfeed.csv

    Example 3:

    • Set the File Location field to Script.
    • Set the File Path field to: /myfeed.csv
    • Your file will be written to: hotdogs/myfeed.csv

      Since this is in a public accessible web directory, you could view this file by browsing to: https://www.domain.com/myfeed.csv

    Enable Email Creation Check this box if you want to email the feed data.

    Email From:

    Email Reply To:

    Email To:

    Email CC: Email BCC:

    Email Subject:

    Email Type:

    Send Base64 Encoded:
    The fields in bold are required.
    Template:

    Choose the type of data to include in the feed. When you create a template feed, you select the type of data to include with the Template field: None, Product, Category, or Customer.

    If you want to change the type of data in the feed, you have to Customize the feed and use the Mode field.

  5. Customize the feed (optional).

    When you create a template feed a special Page is created that lets you control the content of the feed. The page has the same name as your feed. For example, if you named your feed "Store Products", you will see a page called "Store Products". There are two ways to edit this page:

  6. Method 1:

    Go to Menu> User Interface > Pages tab > edit the page that has the same name as your feed

    User Interface

    Method 2:

    In the Marketing > Feeds tab, edit the feed that you just created. In the Edit Feed dialog box, click Edit Template.

    Edit Feed: Store Products

    4.1. When you are editing the page associated with your feed, scroll down to the Template Based Feed section. Make your changes to the page and click Update.

    Edit Page: Store Products

Mode: Use the Mode field to change the type of data that is included in the feed. For example, when you created the feed, you might have selected Product data. You can use the Mode field to change the feed to use Category data.
Load:
  • All: Include all products in the feed.
  • Active: Include all products marked as Active
  • Available: Include products that are not part of Availability Groups.
  • In Category: Include all products in a specific category. You can enter multiple categories in this field, separated by commas.
  • In Price Group: Include all products in a specific Price Group. You can enter multiple price groups in this field, separated by commas.
  • In Availability Group: Include all products in one or more Availability Groups. You can enter multiple availability groups in this field, separated by commas.
  • Not In Category: Include all products that are not in this category. You can enter multiple categories in this field, separated by commas.
  • Not In Price Group: Include all products not in this price group. You can enter multiple price groups in this field, separated by commas.
  • Not In Availability Group: Include all products not in this availability group. You can enter multiple availability groups in this field, separated by commas.
Encoding:

By default the feed data is formatted as a CSV.

If you set this field to CSV, the feed will be processed as a CSV file, which includes using a delimiter between fields and some string quoting.

If you set this field to None, the feed won't have the formatting of a CSV file, but you can still select a field delimiter from the Delimiter field (below).

Delimiter: Select the field delimiter for the feed data.
Predict Product Discounts: If you check this box, your price group discounts will be applied to products in the feed. If you don't check this box, products in the feed will have their non-discounted prices.
Load Variants: This field only affects products that have master products and Variants.
  • If this box is unchecked, master products are included in the feed and variants are not.
  • If this box is unchecked, variant products are included in the feed and the master products are not.

Product Fields:

Custom Fields:

Select the Product and Custom fields that you want to include in the feed.

To Download Your Template Feed

  1. Go to Menu> Marketing > Feeds tab.
  2. Edit a template feed and make sure you checked the Enable File Creation checkbox. Close the Edit Feed dialog box.
  3. In the Feeds tab, select the feed and click Process Now.
  4. Click Download File

Download

Ways to Run a Feed

To Run a Feed Manually

  1. Go to Menu> Marketing > Feeds tab.
  2. Select a feed and click Process Now.

To Run a Feed From a Scheduled Task

See:

  • Standard Scheduled Tasks: Run a Feed
  • To Create a New Scheduled Task

Associating a Feed with a URI

You can create a feed that is run when someone goes to a specific URI. You would probably only create this type of feed if you wanted to transfer the information from the feed to some external program.

For example:

  1. Create a feed.
  2. Associate the feed with a URI: http://www.miva_sample_store.com/my_feed
  3. When someone visits that URI, Miva Merchant runs the feed and dumps the feed information into the browser page.

URI Feed

The "someone" visiting the URI is usually a script or program. You might have accounting software that needs to get updated information about new products in your Miva Merchant store. You would create the URI feed in the admin interface, and then write a program that would periodically go to the URI, generate the feed data and download that data to some location on your network where your accounting software could get it. The cool thing about the "URI feed" is that it lets you place feed generation under the control of an external application. Your external program can get the latest feed data from your Miva store whenever it wants.

To Associate a Feed with a URI - Method 1
  1. Create a feed. Note that you can only associate a Template Feed with a URI. You cannot associate an XML Sitemap feed (Standard Sitemap Protocol feed) with a URI.

    1.1. In the Add Feed dialog box, make sure that you check the Enable URI Access checkbox. You may also want to password protect the URI with the URI Access Key field.

  2. Add Feed

  3. Go to Menu> Marketing > Feeds tab.
  4. Select a template feed and click URIs.
  5. Marketing Feeds

  6. In the Feed URIs dialog box, click Add URI Add.

    4.1. It doesn't really matter what you select in the Type column. In our example, we'll select "Normal".

    4.2. In the URI column, enter a URI, starting with a forward slash. There are some limits on the characters you can enter in this field, for example, the URI can't contain spaces. Other than that, the URI can be almost anything you want.

    4.3. Click Save URI Save . You can create multiple URIs for the same feed if you want.

    4.4. Click Close.

  7. To generate a URI feed, you (or more likely a program) would navigate to the URI:
    • Our sample domain is: http://www.miva_sample_store.com
    • Our sample feed is: /my_feed
    • Our sample URI Access Key is: test

    If you used a URI Access Key, you could generate this feed by browsing to: http://www.miva_sample_store.com/my_feed?Feed_AccessKey=test

    If you didn't use a URI Access Key, you would browse to: http://www.miva_sample_store.com/my_feed

Looking for Developer Docs?

We have a whole section for that, including: Developer Training Series, Template Language docs, Module Development tutorials and much, much more.

Head to the Developer Section

Miva believes that all online businesses should have access to a scalable ecommerce platform that can meet their unique business requirements. Miva offers PCI compliant ecommerce, hosting, and custom website design and development solutions. Miva customers have processed over $100 billion in online sales since 1997.

Copyright © 2016 Miva, Inc - All Rights Reserved   Privacy Policy | Store Policy

Links
Contact Us
Receive Tips & Updates

Copyright © 2016 Miva, Inc - All Rights Reserved

Back To The Top