RTMP: check if stream is enabled through Python

I have several Flash streams and I want to display only active / live / online streams. Can someone provide some sample code that can check the status of the stream? or indicate where I can capture it (I think Red5 and RTMPy should have this, but I have absolutely no experience with RTMP, there is also an RTMP specification, but the wiki says that it is incomplete)? My target language is Python, but code in any language will be useful.

+3
source share
1 answer

If the connection fails or the connection fails, the code below will display an error message.

from twisted.internet import reactor
from rtmpy.client import ClientFactory

reactor.connectTCP('localhost', 1935, ClientFactory())
reactor.run()
+2
source

Source: https://habr.com/ru/post/1777291/


All Articles