Playing a Playlist
#1
Is there a way to use JSON to play an existing playlist (smart or m3u)? It looks like Playlist.GetPlaylists only returns a playlist of items currently playing and not all playlists on the system.  I found a thread from 2013 that confirms this behavior, but there was also a discussion of changing it and somehow 2013 is almost ten years ago.

Anyway, if the above doesn't work, is there aanother way to accomplish this? All I am trying to do is play an existing playlist, but before I spend hours trying to see if I can do it with Player.Open (I am very new to JSON so it takes me forever...) and sending it the file location of a playlist on the server, it would be great if anyone could confirm if that might work.

Thanks.
Reply
#2
What about: 

https://kodi.wiki/view/JSON-RPC_API/v12#Player.Open

Doesn't this work for you?
Reply
#3
I cannot test this currently, but the command should look like this:

{ "jsonrpc":"2.0", "method":"Player.Open", "params":{ "item":{"directory":"special://musicplaylists//myPlaylistFileName" } }, "id":1 }
Reply
#4
From my testing your suggestion is correct but,

it seems special:// does not work and you have to specify the actual underlying pathname

if you have an m3u playlist you have to say it is a file

if you have a xsp smart playlist you have to say it is a directory

I have been trying to work out how to open a smart playlist in partymode which the api documentation says  should work,

but I cannot understand how to do so, as my knowledge of json is well below what is needed to understand the api docs

if anyone can provide an example of the correct command I'd be very grateful
Reply



Logout Mark Read Team Forum Stats Members Help
Playing a Playlist0
This forum uses Lukasz Tkacz MyBB addons.