Version 0.8.8
This commit is contained in:
1 parent
2ec9223af2
commit
5c996bba0a
4 files changed
+19
-6
No files matched your search
@@ -565,13 +565,15 @@ class Movistar(object):
|
||||
|
||||
def get_channels(self):
|
||||
demarcation = self.account['demarcation']
|
||||
profile = self.account['platform']
|
||||
cache_filename = 'channels_{}.json'.format(self.quality)
|
||||
content = self.cache.load(cache_filename)
|
||||
if content:
|
||||
data = json.loads(content)
|
||||
else:
|
||||
url = self.endpoints['canales'].format(deviceType='webplayer', profile=self.account['platform'], mdrm='true', demarcation=demarcation)
|
||||
url = self.endpoints['canales'].format(deviceType='webplayer', profile=profile, mdrm='true', demarcation=demarcation)
|
||||
if self.quality == 'UHD': url += '&filterQuality=UHD'
|
||||
#LOG(url)
|
||||
data = self.net.load_data(url)
|
||||
if not 'error' in data:
|
||||
self.cache.save_file(cache_filename, json.dumps(data, ensure_ascii=False))
|
||||
@@ -681,6 +683,14 @@ class Movistar(object):
|
||||
url += '&_='+ str(int(time.time()*1000))
|
||||
return url
|
||||
|
||||
def get_viewings_url(self):
|
||||
url = self.endpoints['ultimasreproducciones'].format(
|
||||
deviceType=self.dplayer, DIGITALPLUSUSERIDC=self.account['encoded_user'], PROFILE=self.account['platform'],
|
||||
ACCOUNTNUMBER=self.account['id'], idsOnly='false', start=1, end=30, mdrm='true', demarcation=self.account['demarcation'])
|
||||
url += '&filter=AD-SINX'
|
||||
url += '&_='+ str(int(time.time()*1000))
|
||||
return url
|
||||
|
||||
def get_search_url(self, search_term):
|
||||
url = self.endpoints['buscar_best'].format(
|
||||
ACCOUNTNUMBER=self.account['id'],
|
||||
|
||||
Reference in new issue
Block a user