INTERACT FORUM
Windows => Plug-in Development => Topic started by: mpg732 on February 18, 2023, 09:49:58 am
-
I have been playing around with creating controls for MC in Demopad. I have the following command http://localhost:52199/MCWS/v1/Playback/Playlist?Zone=-1. That works and all, but was wondering how and or if it can be done, I would like to limit how much info is returned, IE only Title, artist, duration and son ID#, so is that possible? I also have a playlist of over 800 songs, that is a lot of returned data to sort through and parse. I also was wondering if you can get the returned info in the shuffled state that the playlist is currently playing in? I was also wondering if you can get a limited number of songs, such as give me the first 1 to 50 songs, then next being 51 to 100, and so on?
Thanks
Mike
PS, I have searched the internet for answers but was not able to find answers...
-
see the doc at http://localhost:52199/MCWS/v1/doc
you'll see there is a parameter
Fields: The fields to include in an MPL (use empty to include all fields) (set to Calculated to include calculated fields). (default: )
I don't believe there is any pagination built in
-
I started there, I guess I don't understand how to do this, that's why I am asking for help. Can you please give an example command?
Thanks
Mike
-
So kinda got it working with the following line,
http://localhost:52199/MCWS/v1/Playback/Playlist?Fields=Key,Name,Artist,Duration?Zone=-1
Can not get Duration to show up in the returned data
-
Try: http://localhost:52199/MCWS/v1/Playback/Playlist?Fields=Key,Name,Artist,Duration&Zone=-1
-
Thanks got that part figured out,
http://localhost:52199/MCWS/v1/Playback/Playlist?Action=JSON&ActiveFileOnly=1&Fields=Key,Name,Artist
is it possible to split up how much I que, like 1 to 50 then 51 to 100, so on and so on
-
Maybe if you explain your end goal you’ll get some other responses
-
This Centro stuff looks pretty cool.
Thanks for mentioning it!
-
is it possible to split up how much I que, like 1 to 50 then 51 to 100, so on and so on
no
-
Thanks got that part figured out,
http://localhost:52199/MCWS/v1/Playback/Playlist?Action=JSON&ActiveFileOnly=1&Fields=Key,Name,Artist
is it possible to split up how much I que, like 1 to 50 then 51 to 100, so on and so on
There's no built in pagination. You *can* sort of work around this by 'getting' all relevant items, storing that list, and splitting it yourself. You can send multiple requests to JRiver that append items to the end of the queue. What are you trying to achieve exactly with the pagination?
800 items isn't ridiculous to parse and sort from a computational perspective.
-
Thanks all, I have a few different ways of going about it, just seeing all my options before I dive into what I am trying to accomplish.