Embed facebook live with html5 script video player

Is there a way to embed a video on facebook live in an html page, for example using a custom video player script like mediaelementjs? Use rtmp that facebook provide when you live.

I tested with this embed:

<video width="360" height="203" id="player1" src="rtmp://rtmp-api.facebook.com:443/rtmp/1327296050643313?ds=1&s_l=1&a=ATiweM9l1fKQFUUB" autoplay="true" type="video/rtmp" controls="controls"></video> 

and js init

  <script type="text/javascript"> $('video,audio').mediaelementplayer(/* Options */); </script> 

But nothing on the page looks. did someone test the player (maybe html5 player) for facebook live embed on the html page?

thanks

+5
source share
1 answer

Have you checked preview_url ? I haven't tested it, but the documentation seems to have a method of getting a preview in RTMP strem to preview the video you are recording.

Facebook documentation link

The problem for this work will be that preview_url is limited to 4 hours and 10 viewers.

+2
source

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


All Articles