Difference between revisions of "MythVideo Grabber Script Format"

From MythTV Official Wiki
Jump to: navigation, search
(Created page with 'MythVideo grabber scripts are small executable perl, python, or binary applications which query online sources of metadata and return it in a format parseable by MythVideo. This…')
 
(The Search Command)
Line 6: Line 6:
  
 
Command Format:  '''INETREF:TITLE'''
 
Command Format:  '''INETREF:TITLE'''
 +
 
Command Example:  ./tmdb.pl -M "Harry"
 
Command Example:  ./tmdb.pl -M "Harry"
  
Line 11: Line 12:
  
 
Response Format:  '''INETREF:TITLE'''
 
Response Format:  '''INETREF:TITLE'''
 +
 
Response Example:
 
Response Example:
  

Revision as of 16:54, 28 October 2009

MythVideo grabber scripts are small executable perl, python, or binary applications which query online sources of metadata and return it in a format parseable by MythVideo. This page documents the current format required of the grabber scripts to function.

The Search Command

All scripts must provide a search command, which takes a title as an argument and return a list of possible results. The results must be one per line, in the format:

Command Format: INETREF:TITLE

Command Example: ./tmdb.pl -M "Harry"

Inetref is a number like an IMDB, TMDB, or TVDB number. It is a unique serial ID that identifies that film to the data source's API.

Response Format: INETREF:TITLE

Response Example:

0241527:Harry Potter And The Philosopher's Stone (2001)
0304141:Harry Potter And The Prisoner Of Azkaban (2004)
0373889:Harry Potter and the Order of the Phoenix (2007)
0295297:Harry Potter And The Chamber Of Secrets (2002)
0330373:Harry Potter And The Goblet Of Fire (2005)
0216800:Harry, un ami qui vous veut du bien (2000)
0329028:Dumb and Dumberer: When Harry Met Lloyd  (2003)
0118954:Deconstructing Harry (1997)
0066999:Dirty Harry  (1971)
0098645:Who's Harry Crumb? (1989)
0098635:When Harry Met Sally... (1989)
0093148:Harry and the Hendersons (1987)
1201607:Harry Potter and the Deathly Hallows: Part II (2011)
0926084:Harry Potter and the Deathly Hallows: Part I (2010)
0417741:Harry Potter and the Half-Blood Prince (2009)
0048750:The Trouble with Harry (1955)

The Data Command

Each grabber must also provide a data command. The data returned includes items such as title, subtitle, year of release, and other textual metadata. Grabbers written for MythTV .23 or greater should also return image results for coverart, fanart, banners, and screenshots (where available). This command varies slightly depending on whether the script is for TV or Film material.

For film material, the data command would look like:

Command Format: SCRIPTNAME -ARGS INETREF Command Example: ./tmdb.pl -D 0241527

For Television Material, the season and episode values are added as arguments:

Command Format: SCRIPTNAME -ARGS INETREF SEASONNUM EPISODENUM Command Example: ./ttvdb.py -D 73739 5 1