Server Now Playing API

Anyone know if it’s possible to get now playing information from the clients off the server, like Tautulli does for Plex? Would like to get something setup to monitor this on my homepage install.

1 Like

Have you looked at this?

Otherwise, you could approach it yourself. For instance, if you go to the path http://[SERVER_NAME]:[SERVER_PORT]/dvr, you can get whatever the current activity is, including what is playing on clients.

However, this isn't full-proof as some things like Stream Files play directly from the clients and don't even hit the server, so you wouldn't capture that. And Stream Links don't play through either, so you wouldn't capture those. For stuff like this, you'd need to get info from the clients directly to know what they are up to. This isn't trivial, but in Media Tools Manager for Channels (a Streaming Library Manager extension), the base code exists that you could re-appropriate for these purposes:

So short answer is "Yes", medium answer is "but not without a lot of custom programming."

Thanks for your reply - I will take a look at ChannelWatch.

I did just find the http://[SERVER_NAME]:[SERVER_PORT]/dvr but couldn't work out a clean way of extracting the contents because the 'key' seems to be variable. But it's exactly what I'm after, just wanted to take the "Watching XXX on Living Room TV" etc.

Would you have any idea how to do that?

If you understand Python and JSON, you can follow back from def get_channels_dvr_activity() here:

https://github.com/babsonnexus/stream-link-manager-for-channels/blob/main/slm.py#L12318

1 Like

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.