Installing and Configuring the XMLTV Grabber

The purpose of this guide is to give direction on how to setup and configure the XMLTV Project Grabber to use XMLTVListings.com guide data for the EPG. This guide already assumes that you have knowledge of Windows Command Line Interface (CLI).

This guide is offered “as is”. Any issues or problems with using the guide, or with Windows Operating System are not covered in this guide. As such, no warranty, or support is offered to you regarding your system. Use at own risk.


Testing Parameters and Versions

  1. Tests completed using Windows 10 Pro 20H2 64bit.
  2. XMLTV version is 1.0.0-win32.
  3. All information regarding the Grabber is obtained from here: http://wiki.xmltv.org/index.php/HowtoUseGrabbers

Gathering Information

  1. Log into your XMLTVListings.com account
  2. Note your API Key located at the top left under the "Account Summary". You will need the API Key later when you configure the grabber.
  3. Create a Lineup. When finished note the Lineup ID. This will be a 4 digit number.

Installing XMLTV Package

  1. You will need to install XMLTV on your system. Download the zip file from here: https://sourceforge.net/projects/xmltv/files/xmltv/1.0.0/
  2. Unzip the download to your computer. For example: C:\XMLTV
  3. Open the Command Line Interface for Windows and navigate to where you extracted the XMLTV files. For example, your command would be: C:\XMLTV\xmltv.exe
  4. This will take some time to start on the first run. You will then see this output listings all the grabbers installed on your system:
    XMLTVlistings.com Grabbers List
  5. Configure the tv_grab_na_tvmedia Grabber using the following command:

    1. xmltv.exe tv_grab_na_tvmedia --configure
    2. Enter your API key which is found on your account dashboard page.
    3. Choose one or your lineups. You can add or modify lineups from your account page
    4. This will create a new folder called .xmltv in the same folder as where you ran the xmltv.exe from. Here is where your configuration is saved (your API key and the lineup ID that you are downloading.

    Download Data using the Grabber

    1. Type the following commands:
      1. Xmltv.exe tv_grab_na_tvmedia --days 7 --output guide.xml
        • --days xx is how many days you want to download. Max is 14. Please note: only download the max days that you would use. The more days you download, the longer the time to download the data file.
        • --output guide.xml is the name of the file that is stored locally on your system. This file, using the above command, will store in the same folder as where you ran the command from.
    2. You can now open the guide.xml file using a text editor (like Notepad) and see the guide information.

    Automate the Daily Download

    1. You will want to automate this command so that the grabber downloads the data on a daily basis. Create a file called xmltv_download.bat (name it what you like) and save it to the C:\XMLTV directory with the following contents:
      echo off
      rem Download XMLTV data from XMLTVListings.com using Grabber
      C:\XMLTV\Xmltv.exe tv_grab_na_tvmedia --days 7 --output guide.xml

    2. Please note: the location of the command is dependent on where you run xmltv.exe from.
    3. Create a Scheduled Task using Windows Task Scheduler for the xmltv_downoad.bat file. One download per day is sufficient to get 7 days of data, everyday.
      1. The scope of this article does not include how to create the scheduled task. If you are not familiar with how this works, simply search the internet for guides on how to do this.