Add Plex XML shortcuts to libraries, users, and sync headers
This commit is contained in:
@@ -277,6 +277,8 @@ class WebInterface(object):
|
||||
def return_plex_xml_url(self, endpoint='', plextv=False, **kwargs):
|
||||
kwargs['X-Plex-Token'] = plexpy.CONFIG.PMS_TOKEN
|
||||
base_url = 'https://plex.tv' if plextv else plexpy.CONFIG.PMS_URL
|
||||
if '{machine_id}' in endpoint:
|
||||
endpoint = endpoint.format(machine_id=plexpy.CONFIG.PMS_IDENTIFIER)
|
||||
return base_url + endpoint + '?' + urllib.urlencode(kwargs)
|
||||
|
||||
@cherrypy.expose
|
||||
|
Reference in New Issue
Block a user