INTERACT FORUM
Windows => JRiver Media Center 33 for Windows => Topic started by: Richard Martin on October 18, 2024, 04:14:38 pm
-
I wonder if I am missing something.
I have read https://wiki.jriver.com/index.php/Web_Service_Interface
I have looked at http://[library server address]/MCWS/v1/doc and http://[library server address]/MCWS/v1/WSDL both list the available functions and doc has examples of the responses, but I can't see anything specifying the arguments to pass when calling the functions.
Is there any documentation that I am missing or some other way of finding out how to understand how to call the functions?
-
Hover over the "click here" in Play > Playback and view the link shown in your browsers tooltip. Most of the calls have parameters, but some of the click here examples don't show them.
-
The arguments are on the documentation page, it's the "parameters" under each API name.
http://localhost:52199/MCWS/v1/Files/Current?action=JSON&Formatted=1
"Action" and "Formatted" are parameters, as described in the documentation page for /Files/Current.
-
Hover over the "click here" in Play > Playback and view the link shown in your browsers tooltip. Most of the calls have parameters, but some of the click here examples don't show them.
When I hover over Click here I see a tool tip that says "Click here" and when I click I see response examples
-
The arguments are on the documentation page, it's the "parameters" under each API name.
http://localhost:52199/MCWS/v1/Files/Current?action=JSON&Formatted=1
"Action" and "Formatted" are parameters, as described in the documentation page for /Files/Current.
I don't know why I didn't see that...it was right in front of me!
Thank you
[Edit]
The first one I was trying to use, Authenticate, doesn't list any parameters. Presumably it's username and password, or user and pwd or some combination. I could be here awhile trying them.
-
It is Basic HTTP authentication.
These might help.
https://en.wikipedia.org/wiki/Basic_access_authentication
https://yabb.jriver.com/interact/index.php?topic=111986.0
https://yabb.jriver.com/interact/index.php?topic=122106.0
Authenticate will give you a 401 reply (Authorization Required). Pull the "www-authenticate" header and retrieve the Basic Realm. Then make an HTTP call passing the proper Authorization header from Realm, Username and Password (how you do this depends on the HTTP library you're using). Correct authorization will provide you with a Token and a ReadOnly value in the returned XML. If you're going to write, and do anything more than basic, you'll want MCWS to be configured with authentication, and you'll expect the server to not indicate it is in ReadOnly mode.
-
When I hover over Click here I see a tool tip that says "Click here" and when I click I see response examples
-
It is Basic HTTP authentication.
These might help.
https://en.wikipedia.org/wiki/Basic_access_authentication
https://yabb.jriver.com/interact/index.php?topic=111986.0
https://yabb.jriver.com/interact/index.php?topic=122106.0
Authenticate will give you a 401 reply (Authorization Required). Pull the "www-authenticate" header and retrieve the Basic Realm. Then make an HTTP call passing the proper Authorization header from Realm, Username and Password (how you do this depends on the HTTP library you're using). Correct authorization will provide you with a Token and a ReadOnly value in the returned XML. If you're going to write, and do anything more than basic, you'll want MCWS to be configured with authentication, and you'll expect the server to not indicate it is in ReadOnly mode.
Thank you, that should help
-
Thank you, got it now