diff --git a/sites/mytelly.co.uk/mytelly.co.uk.config.js b/sites/mytelly.co.uk/mytelly.co.uk.config.js index 6ebe128a..dbfd58e1 100644 --- a/sites/mytelly.co.uk/mytelly.co.uk.config.js +++ b/sites/mytelly.co.uk/mytelly.co.uk.config.js @@ -18,6 +18,12 @@ const tz = 'Europe/London' module.exports = { site: 'mytelly.co.uk', days: 2, + request: { + headers: { + 'User-Agent': + 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/132.0.0.0 Safari/537.36 OPR/117.0.0.0' + } + }, url({ date, channel }) { return `https://www.mytelly.co.uk/tv-guide/listings/channel/${ channel.site_id @@ -36,7 +42,7 @@ module.exports = { const td = $(el).find('td:eq(1)') const title = td.find('h5 a') if (detailedGuide) { - queues.push(title.attr('href')) + queues.push({ url: title.attr('href'), params: module.exports.request }) } else { const subtitle = td.find('h6') const time = $(el).find('td:eq(0)') @@ -115,7 +121,7 @@ module.exports = { }, async channels() { const channels = {} - const queues = [{ t: 'p', method: 'post', url: 'https://www.mytelly.co.uk/getform' }] + const queues = [{ t: 'p', url: 'https://www.mytelly.co.uk/getform', params: this.request }] await doFetch(queues, (queue, res) => { // process form -> provider if (queue.t === 'p') { @@ -127,9 +133,8 @@ module.exports = { const provider = opt.attr('value') queues.push({ t: 'r', - method: 'post', url: 'https://www.mytelly.co.uk/getregions', - params: { provider } + params: { ...this.request, provider } }) }) } @@ -150,7 +155,7 @@ module.exports = { t: 's', method: 'post', url: 'https://www.mytelly.co.uk/tv-guide/schedule', - params + params: { ...this.request, data: params } }) } } diff --git a/sites/mytelly.co.uk/readme.md b/sites/mytelly.co.uk/readme.md index dd1380ea..64027758 100644 --- a/sites/mytelly.co.uk/readme.md +++ b/sites/mytelly.co.uk/readme.md @@ -1,6 +1,6 @@ # mytelly.co.uk -https://www.mytelly.co.uk/tv-guide/listings/tv-tonight.html +https://www.mytelly.co.uk/tv-guide/ ### Download the guide