pdrbrnd / whatsinthebox

7 days of the best movies in Portuguese TV
https://whatsinthebox.tv
GNU General Public License v3.0
26 stars 1 forks source link

TV Guides #17

Open ruifcardoso opened 2 months ago

ruifcardoso commented 2 months ago

Hello, MEO provides an open page where you can get the TV Guide:

https://www.meo.pt/tv/canais-programacao/guia-tv

Opening that webpage, calls https://authservice.apps.meo.pt/Services/GridTv/GridTvMng.svc/getProgramsFromChannels which will request the TV schedule (no auth needed):

curl 'https://authservice.apps.meo.pt/Services/GridTv/GridTvMng.svc/getProgramsFromChannels' \
  -H 'Content-type: application/json; charset=UTF-8' \
  --data-raw '{"service":"channelsguide","channels":["SPT2HD"],"dateStart":"2024-08-21T23:00:00.000Z","dateEnd":"2024-08-22T23:00:00.000Z","accountID":""}'

There is also another endpoint, which is called after login on meogo, but actually is also unprotected: https://meogouser.apps.meo.pt/Services/MeoGo/MeoGo.svc/GetGAProgramsForChannel

The call is something like:

curl 'https://meogouser.apps.meo.pt/Services/MeoGo/MeoGo.svc/GetGAProgramsForChannel?callLetter=SIC&date=&page=1&userAgent=PC_FIREFOX' --compressed -H 'User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.15; rv:129.0) Gecko/20100101 Firefox/129.0' -H 'Accept: */*' -H 'Accept-Language: en-US,en;q=0.5' -H 'Referer: https://meogo.meo.pt/' -H 'Origin: https://meogo.meo.pt' -H 'Connection: keep-alive'
pdrbrnd commented 1 month ago

thanks! that looks promising. I also another person providing me with some options so I will be bringing this app back up as soon as possible