Download at:
http://code.google.com/p/yars-jrmc-remote-server-plugin/downloads/listThis is an alpha version, so please only use if you are, well, geeky. I would love any feedback y'all have.
After installing, restart Media Center and then you can use a browser to access the sample web server interface at
http://localhost:18887The goal of this plugin is to provide a remote http server interface to all Media Center functionality exposed via J River's automation interface and return the results in JSON form. Currently supported functions include: library browsing, adding/playing view items/files, zone selection, play/pause, track navigation, track info, track rating. More will come as I find time.
The server takes in a variety of commands and returns JSON output. This then provides a building block for other apps/AJAX web apps to access MC functionality. I am using it for a MC/Squeezebox integration project, but I am trying to make it generic enough for other applications.
Also included with the plugin is an sample web app usage, showcasing the currently supported commands. This is accessible at
http://localhost:18887 (for now the port is hardcoded, but will be configurable in an upcoming release). You can see all the json commands that are occurring by looking at the YARS Plugin item in Media Center under "Services & Plugins". View this output as a guide for how to call to the json interface until real documentation exists.
The html source for the page can be found at <plugin-install-dir>/static/index.html. This file can be modified on the fly if you feel like it, though only the file index.html can be used for now.
The sample uses the prototype js library to call Ajax commands to the server and present the JSON results in HTML form.
Though my primary goal is a complete JSON server, I plan to support the static web server functionality more completely so that UI/Web savvy folks could drop in static web server content to give a richer web UI.
I'll put the source up in a few days after I clean up a few things like picking an open source license to use. If folks are interested in contributing to the code, let me know, and we'll try to figure out a model for shared development.
Thanks to PaulSinnema & Mr ChriZ for your valuable posts regarding Plugin development.
Tom