I am in the process of building a music jukebox front end using the http/xml plex server interface. I was wondering if there is anyway to have PMS randomly select a song to play out of all of the songs in its database. Ideally it would be nice to put a genre filter on this selection. For example pick a random country song.
I might also be able to accomplish this if I could somehow get direct access to the PMS database.
I am in the process of building a music jukebox front end using the http/xml plex server interface. I was wondering if there is anyway to have PMS randomly select a song to play out of all of the songs in its database. Ideally it would be nice to put a genre filter on this selection. For example pick a random country song.
I might also be able to accomplish this if I could somehow get direct access to the PMS database.
Thanks for the quick reply. I guess the clients that support this, must be accessing the DB directly.
Do you know the type of database being used and how I might gain direct access to it? Anything information about the schema definition would also be useful.
Thanks for the quick reply. I guess the clients that support this, must be accessing the DB directly.
Do you know the type of database being used and how I might gain direct access to it? Anything information about the schema definition would also be useful.
Thanks again, Bill
NO.
You should not go down that path.
They have interface to Plex Media Server. Requests and Responses - Maybe you could find out more through the Channel Development forum. There is actually a whole group of forums for Developers here
Edit 1: Sorry - you are already there
Edit 2: Really you ought to see what interfaces and documentation is provided for channel developers rather than take my answers
I am already using the request/response interface to do most of what I need, search for artist, play songs, etc. However, the documentation I have been able to find on this interface is somewhat limited. The best that I have been able to find so far is at this link Plex Media API - Google Drive. However, performing a random song selection is something that requires access to the complete list of songs. I don't want to have to copy all of the songs in the media server to some local source in order to do a random selection. That would sort of defeat the purpose.
Based on what I have been able to find so far on this API, I can't even search for a song. I can only search for artists. That functionality may exist, but I have yet to find how to do it.
Maybe I misunderstood what a channel is. It thought is more of a source of external media.
I am already using the request/response interface to do most of what I need, search for artist, play songs, etc. However, the documentation I have been able to find on this interface is somewhat limited. The best that I have been able to find so far is at this link Plex Media API - Google Drive. However, performing a random song selection is something that requires access to the complete list of songs. I don't want to have to copy all of the songs in the media server to some local source in order to do a random selection. That would sort of defeat the purpose.
Based on what I have been able to find so far on this API, I can't even search for a song. I can only search for artists. That functionality may exist, but I have yet to find how to do it.
Maybe I misunderstood what a channel is. It thought is more of a source of external media.
Thanks, Bill
I use the By Artist selection on Roku Plex (actually I use RARflixTest and not the official Plex for Roku) and add on the shuffle option which I think is working. The code is all on Github I think so you should be able to see how it is done
For picking up all music tracks or all photos - it needs to be a Plex Media Server feature because I do not believe there is such a request type at the moment and it has been asked for in the wish lists in the PlexPASS forum for voting. But any selections that return high number of objects the clients at the moment crash. I have been testing with filters for requests on photos and can manage without breaking the client for returns of 6000, 7000. On some might even get up to 12000.
My interest in all this is as the end user - because I want to be able to view 50,000+ photos and listen to 10,000+ tracks of music in loop randomly with ability to pause and continue. But that is not possible for such volumes because i think the clients just run out of memory - may be the issue is only for photos.
Why can it not be broken down into blocks of say 1000 at a time - adding another Transport layer. I have not looked into the protocol and interface but it seems very crude. The power is at the server end so probably the randomisation ought to be at the server end - any done at the client end is just tactical - how could client cope with randomising the whole database items - too much to handle.
I totally agree that the selection of a random song ought to be part of the server. It just doesn't make sense to have to move all information to the client in order to do a random selection.
I upgraded to the latest version of PMS yesterday and it appears that some additional searching capabilities have been added to the API. You can now search by Artists, Albums or Tracks using the following queries: