INTERACT FORUM

More => Old Versions => JRiver Media Center 19 for Windows => Topic started by: miketl on February 23, 2014, 07:43:23 pm

Title: Command line to retrieve status
Post by: miketl on February 23, 2014, 07:43:23 pm
Hello,

Is it possible to issue a command line to get the current status of JRiver (i.e, Playing/Paused etc.)

Thanks
Title: Re: Command line to retrieve status
Post by: MrC on February 23, 2014, 08:02:24 pm
Here's one way:

$ wget --quiet -O - --user xxx --password yyy "http://localhost:52199/MCWS/v1/Playback/Info?Zone=-1"  | grep '"Status"'
<Item Name="Status">Playing</Item>

$ mc19.exe /Pause

$ wget --quiet -O - --user cappella --password gomerpyle "http://localhost:52199/MCWS/v1/Playback/Info?Zone=-1"  | grep '"Status"'
<Item Name="Status">Paused</Item>

There is also the ability to use the mc19.exe launcher with an MCWS command, but I don't get any output when I try:

$ mc19.exe "/MCWS/v1/Playback/Info?Zone=-1"

Command line reference:

    http://wiki.jriver.com/index.php/The_Command_Line (http://wiki.jriver.com/index.php/The_Command_Line)
Title: Re: Command line to retrieve status
Post by: miketl on February 23, 2014, 08:13:11 pm
Thank you for your help.

But in order to issue the commands that you listed do I need to set JRiver as a Media Network Server? Because it is only used on one computer, so it is just used for playback of local files.
Title: Re: Command line to retrieve status
Post by: MrC on February 23, 2014, 08:21:26 pm
For the command line usage, no, it does not need to be enabled.  But I got no results.

For status via http, yes, it has to be enabled.  It is very light weight, so I wouldn't worry about it.
Title: Re: Command line to retrieve status
Post by: DoubtingThomas on February 23, 2014, 09:15:58 pm
I use the MCWS calls too using wget... (or use curl).

It works great.  Some scripting knowledge is required.  I run them using unix korn shell scripts from Windows using cygwin.