Hi,
I’ve created a channel which allows users to play .m3u8 files.
I’d like to be able to monitor what is being played from the WebServer.
I’m using the following for when a menu is loaded
values = {'message': 'Loaded Menu {Menu name here}',
'username': get_username(),
'device': Request.Headers['X-Plex-Device-Name'],
'product': Request.Headers['X-Plex-Product']}
x = HTTP.Request('url to my web server', values, cacheTime=0)
I’m now trying to add the above couple of lines when a stream is ‘previewed’, played or stop. But i’m not sure were I would insert this?
I’ve tried inserting it into the following sections but this does not appear to be valid.
def GetMediaObject(url):
def CreateVideoClipObject(title, thumb, url, include_container=False, *args, **kwargs):
Just as a side note does anyone know how to get the client (plex client)'s IP Address?
Can anyone shed any more light on this?
Thanks.
Johnny