Get myPlex queue to cover more sources

Hi all,



myPlex ist on eof the best things, which came up here, since I saw this feature within boxee.

Both, boxee and myPlex, currently do not support the german sites http://ardmediathek.de and http://www.zdf.de/ZDFmediathek/hauptnavigation/startseite?flash=off (no critism). Both are media archives of the german tv stations.



I’m familiar with the plex plugins to add this content as a channel so I thought I can contribute this knowhow to enable myPlex to identify videos within this websites.



Do you know how to make this possible?



so long

Barclay

The code snippets necessary for myPlex to support each unique domain are called URL Services. They are collected in the Services.bundle which can be found at https://github.com/plexinc-plugins/Services.bundle. There are lots of examples in there. There is also documentation available at http://dev.plexapp.com/docs/channels/services/index.html.

Happy coding :slight_smile:

to summarize for my understanding:



is this bundle used by myPlex (on the plexapp.com servers) and by the plex releases?

If I forc and contribute to this repository, how can I tests this code?

Does it make sense, to change the channel plugins (like https://github.com/plexinc-plugins/ZDFMediathek.bundle) , which relies on this url services, instead of parsing the html code on their own?




You're right, there is a copy of the Services.bundle on the myPlex servers which handles calls from the "Plex It" bookmarklet, and there is also a local copy in the plugins folder of your PMS install. That one is for plugins using the 2.1 version of the plugin framework. You can certainly upgrade your channels to v2.1 so that they use the MediaObjectsforURL() function from the associated URL Service. The plugin should not rely on the MetadataObjectForURL() function from the URL Service. You'll need to maintain the code in the plugin to gather metadata for the videos. The reason being, that calling the URL Service to gather metadata for all the videos in a list would be very resource intensive and require a lot of http calls whereas, normally, a plugin will gather metadata for all the videos in a list from a single page (or just a few pages) which allows much quicker loading and fewer resource demands/http calls.

You can test your code by hitting the PMS in a browser or with curl to check that you get proper XML returned:

http://localhost:32400/system/services/url/lookup?url=<test url goes here>




I've also written a simple plugin to test URL Services. I just hard code my test url in the __init__.py file, and it allows me to test that the videos actually play. Feel free to give it a try. You can download it [here.](http://bit.ly/sG5jF1)

Mike

sorry to come up with much more questions, but there are still some open issues for me:



There exists a Plex Plugin for the german TV station ZDF. This plugin was developed by two, now inactive, community members and was contributed first in the forum by canbuffi (see http://forums.plexapp.com/index.php/topic/14208-release-zdf-mediathek-plugin-v01-alpha/page__p__84765#entry84765) and lateron by mplex (see http://wiki.plexapp.com/index.php/ZDFmediathek). Now I changed this plugin and moved it to github (https://github.com/barclay-reg/plex-plugin-zdfmediathek).



Now I have seen, that also on github the code was added to the plexinc-plugins account by sullman (https://github.com/plexinc-plugins/ZDFMediathek.bundle). This code seems to be the version from the plex wiki (initial added by mplex).



Now the questions:



Should I fork the plugin from the plexinc-plugins github (https://github.com/plexinc-plugins/ZDFMediathek.bundle) to contribute my changed on this plugin?

Will the plugin then be available in the app-store automaticly?

If I fork the Services.bundle, I need to wait until the next plex release, to release my plugins, which rely on this changes, correct?



Thanks again for your advice

Barclay




Yes, the best thing to do is to fork the existing plugin on github. Add your changes to that version, even if it means replacing most of the code. When it's ready to go, issue a pull request on github. That will notify the Plex guys that your updates are ready. They will pull in the code and review it before pushing it to the store for automatic updates. Since your version of the plugin relies on the services.bundle, you'll have to issue a pull request for that (if you haven't already done so). The local services.bundle is also updated regularly through the store. The version of the services which supports myPlex is hosted on separate servers and is updated less frequently but, that shouldn't affect the functionality of your plugin.

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.