How to Get YouTube Videos to Play in Serviio
YouTube videos are played by Serviio as RSS feeds, which are essenially playlists of YouTube videos.
The RSS feeds are created by the YouTube api in response to specific api requests in the form of:
http://gdata.youtube.com/feeds/api/... which are entered in the console under “Library/Online sources”.
YouTube also offers each video in multiple quality formats, so Serviio requires the addition'
of the YouTube.groovy to the Serviio plug-ins library to select the video best matching
the “Preferred online content quality:” set in the “Console/Online sources” tab.
Note there is a bug in the 6.1 groovy that causes medium quality videos to play as low quality.
The PTF is documented at http://forum.serviio.org/viewtopic.php?f=20&t=3276&start=110
To get a specific Youtube Video use:
where xxxxxxxxxxx is the 11 character video code that normally follows
when viewing Youtube videos on your PC.
Note that when YouTube requires the use of a player as in
is is likely that the returned youtube playlist will be empty
so the video cannot be played by Serviio.
To get a specific Youtube Playlist use:
where yyyyyyyyyyyyyyyy is the 16 character playlist code that normally follows
when playing or viewing YouTube playlists on your PC.
Note: The leading characters PL are removed.
To search for YouTube videos by name use:
where zzzzzzz is your search term, and multiple terms are joined by “+” as in:
To get the uploads, or favorite videos of any user(channel) use:
where uuuuuuuu is the YouTube username which is also the channel name.
To get YouTube Generated Standard Feeds use these examples:
There are 8 Standard Feeds that may be substituted in the above examples:
most_viewed, most_popular, most_recent, most_discussed,
most_responded, top_rated, top_favorites, recently_featured
You may also append one of the following Genres to focus the results:
Autos, Comedy, Education, Entertainment, Film, Games, Howto,
Music, News, Nonprofit, People, Animals, Tech, Sports, Travel
You may also limit the responses by geography by inserting one of
the following country codes after “standardfeeds” as in this example:
AU, BR, CA, CZ, FR, DE, GB, NL, HK, IN, IE, IL,
IT, JP, MX, NZ, PL, RU, KR, ES, SE, TW, US
To get YouTube Generated Trailer Feeds use these 2 special links are available:
How to Get Extended YouTube Output
By default, YouTube will limit its output to 50 videos for any request,
and Serviio will limit its display to the “Max. number of feed items to retrieve:”
that is set in the “console/Online sources” tab.
YouTube provides “&start-index=” and “&max-results=” modifiers
that allow any range of results to be returned from a request.
Assuming that the Serviio limit is 20 videos, but the first 80 results are needed,
then the following 4 YouTube queries would be required for this example search:
Additionally, when adding these to the Serviio Console, different “Display Names” must be entered
for each feed so they may be distinguished and displayed by Serviio as different feeds.