Anyone know how I can get my local news web stream to link with Channels? So I can watch my news live? Thanks
You’ll need to use the web inspector of your browser to try to find the steaming url.
I’ve done this in the past and was unsuccessful. Local news affiliates use outside providers for their streams so they end up being more protected than you’d think. The urls for the streams go stale real fast.
which news link is it
Depending on what market you are in, you may want to check out the fHDHR NewsOn plugin. This assumes you have some technical chops. Not an end-user product.
They use auth tokens that expire after a certain time. Add to that they renew about every 6 seconds. Like Pluto streams.
(News ON) The station, WKRN, my ABC affiliate isn't on their list.
Dead already. Those M3U streams are usually only for about 6 seconds, and they're valid for about half an hour?
interesting, I played it for a few mins. Obviously they rotate it quickly. It also seems to vary with the source. I have BBC streams running for months
Looks like the stream URL changes very frequently but you can grab it from the host's API here: https://tkx.apis.anvato.net/rest/v2/mcp/video/adsty8DLenyvgkQ1?anvack=q261XAm2qKEKnu1pqrHrRsYmO1k4PmMB
You could probably write a PHP script to extract the stream URL and redirect to it so it will play via Channels.
Had a friend write me a Python script to run a webserver on Linux, and call to the root M3U stream, which was split, and had to be joined. It all works. (attached code below)
However I need the loaded M3U into Channels to refresh on EVERY view/call/record command sent to it.
Does anyone know a M3U or add on to this Python script I could add to make Channels reload the internal M3U?
from http.server import BaseHTTPRequestHandler, HTTPServer
import requests
import json
URL = "https://tkx.apis.anvato.net/rest/v2/mcp/video/adsty8DLenyvgkQ1?anvack=q261XAm2qKEKnu1pqrHrRsYmO1k4PmMB"
PORT = 8099
class MyServer(BaseHTTPRequestHandler):
def _gout(self, out):
self.wfile.write(out.encode("utf-8"))
def do_GET(self):
print("Getting data")
connection = requests.get(URL)
res = connection.text[22:-1]
dec = json.loads(res)
new_url = dec['published_urls'][0]['embed_url']
print("Got URL: ", new_url)
print(new_url)
self.send_response(200)
self.send_header("Content-type","audio/x-mpegurl")
self.end_headers()
self._gout("#EXTM3U\n")
self._gout('#EXTINF:-1, channel-id="wkrn-2.1", channel-number="2.6", ABC\n')
self._gout(new_url)
self._gout('\n')
print("Finished")
if __name__=='__main__':
print("Serving on port",PORT)
with HTTPServer(("0.0.0.0",PORT), MyServer) as httpd:
httpd.serve_forever()
You would need your python server to create and redirect to the streaming link on demand. See the tablo-for-channels project for an example.
Thanks! Is this on this site? I also need to make a custom guide data. The news feed airs all the time, and airs at the same as the on air station. Right now I'm linking to the WKRN channel for guide data. But would prefer a better solution.
For the time being. Is there a command I can use to refresh that m3u stream without having to pull up the web GUI each time?
This is what I've been doing for a local news station on VUit. I haven't found a better solution except maybe using Webgrabplus to make a custom, repeating xmltv. There are definitely ways to scrape but that's beyond my abilities.
Ok I was able to get a refresh every time by using a PC M3U file that points to the server address on my Linux machine. Now I need to know if I can schedule a advanced recording in Channels when I've made a custom channel, with NO EPG data? I want to just set a time, channel, and duration. I am unsure how to create a custom EPG entry.
This is the thread you're looking for:
This method may be unnecessary. I have found that while my local news channel M3U link DOES expire after a day or 2, after some period of time (without trying to access it) the link starts working again. I waited like 3 months before trying it again. So you need to wait between a few days and 3 months.
Not sure if this works for all local news stations. My station is a Hurst-owned station.
I suspect that the link URL code is randomly generated and then checked against an expired database that flushes itself out on a FIFO basis. It is also possible that Hurst stopped making links expire.
I debated whether or not to post this info so as not to kill the golden goose. But there are only like 80k of us. And if we are willing to wait for link to be resurrected, they should let us stream. If it is a problem, they can integrate the commercials in the stream instead of showing station logo.