This commit is contained in:
VineFeeder
2026-06-29 13:08:31 +01:00
parent 0ff725a0e9
commit 548bc7f547
4 changed files with 11 additions and 9 deletions
+2
View File
@@ -9,6 +9,8 @@ TwinVine combines two Python packages:
TwinVine helps you find, select, and download media. Use the graphical front end when you want search and selection assistance, and use the command-line downloader for exact URLs. TwinVine helps you find, select, and download media. Use the graphical front end when you want search and selection assistance, and use the command-line downloader for exact URLs.
Envied is forked from unshackle github.com/unshackle-dl/unshackle and I thank the developers for thier effort.
## Key workflows ## Key workflows
- Use `envied` when you already have an exact program URL. - Use `envied` when you already have an exact program URL.
@@ -73,6 +73,7 @@ class ITV(Service):
self.cdm = ctx.obj.cdm self.cdm = ctx.obj.cdm
self.drm_system = "playready" if is_playready_cdm(self.cdm) else "widevine" self.drm_system = "playready" if is_playready_cdm(self.cdm) else "widevine"
if self.cdm != None:
self.security_level = f"SL{self.cdm.security_level}" if self.drm_system == "playready" else f"L{self.cdm.security_level}" self.security_level = f"SL{self.cdm.security_level}" if self.drm_system == "playready" else f"L{self.cdm.security_level}"
self.session.headers.update(self.config["headers"]) self.session.headers.update(self.config["headers"])
@@ -43,7 +43,7 @@ class TPTV(Service):
Service code for TPTVencore streaming service (https://www.TPTVencore.co.uk/). Service code for TPTVencore streaming service (https://www.TPTVencore.co.uk/).
\b \b
version 1.0.6 version 1.1.0
Date: June 2026 Date: June 2026
Author: A_n_g_e_l_a Author: A_n_g_e_l_a
Authorization: email/password for service in envied.yaml Authorization: email/password for service in envied.yaml
@@ -119,7 +119,7 @@ class TPTV(Service):
'User-Agent': 'Mozilla/5.0 (X11; Linux x86_64; rv:135.0) Gecko/20100101 Firefox/151.0', 'User-Agent': 'Mozilla/5.0 (X11; Linux x86_64; rv:135.0) Gecko/20100101 Firefox/151.0',
'Accept': '*/*', 'Accept': '*/*',
'Accept-Language': 'en-GB,en;q=0.5', 'Accept-Language': 'en-GB,en;q=0.5',
'api-key': 'zq5pyPd0RTbNg3Fyj52PrkKL9c2Af38HHh4itgZTKDaCzjAyhd', 'api-key': self.config['session']['api-key'],
'Content-Type': 'application/json', 'Content-Type': 'application/json',
'Origin': 'https://tptvencore.co.uk', 'Origin': 'https://tptvencore.co.uk',
'DNT': '1', 'DNT': '1',
@@ -201,7 +201,7 @@ class TPTV(Service):
"Accept": "*/*", "Accept": "*/*",
"Accept-Language": "en-GB,en;q=0.5", "Accept-Language": "en-GB,en;q=0.5",
"Referer": "https://tptvencore.co.uk/", "Referer": "https://tptvencore.co.uk/",
"tenant": "encore", #"tenant": "encore",
"Origin": "https://tptvencore.co.uk", "Origin": "https://tptvencore.co.uk",
"DNT": "1", "DNT": "1",
"Connection": "keep-alive", "Connection": "keep-alive",
@@ -36,7 +36,6 @@ class TptvLoader(BaseLoader):
'Accept-Language': 'en-GB,en;q=0.5', 'Accept-Language': 'en-GB,en;q=0.5',
'api-key': 'zq5pyPd0RTbNg3Fyj52PrkKL9c2Af38HHh4itgZTKDaCzjAyhd', 'api-key': 'zq5pyPd0RTbNg3Fyj52PrkKL9c2Af38HHh4itgZTKDaCzjAyhd',
'Referer': 'https://tptvencore.co.uk/', 'Referer': 'https://tptvencore.co.uk/',
'tenant': 'encore',
'Content-Type': 'application/json', 'Content-Type': 'application/json',
'Origin': 'https://tptvencore.co.uk', 'Origin': 'https://tptvencore.co.uk',
'DNT': '1', 'DNT': '1',
@@ -47,14 +46,14 @@ class TptvLoader(BaseLoader):
'Priority': 'u=0', 'Priority': 'u=0',
} }
super().__init__(headers) super().__init__(headers)
payload = {}
r = self.client.get("https://tptvencore.co.uk/", headers=headers) r = self.client.get("https://tptvencore.co.uk/", headers=headers)
if r.status_code != 200: if r.status_code != 200:
raise ConnectionError raise ConnectionError
else: else:
#headers = r.headers # belt and braces; not strictly needed
#self.client.headers.update({'headers': headers.get('headers')}) headers = r.headers
pass self.client.headers.update({'headers': headers.get('set-cookie')})
def receive( def receive(