Deepinder Singh Posted April 1, 2020 Share Posted April 1, 2020 I want to check for the viewer count as soon as the user joins, not via REST API. Is there any event on WebSocket or webhook which notifies about user joining the stream to watch it. Link to comment Share on other sites More sharing options...
0 Mahmut As1m Onat Posted April 2, 2020 Share Posted April 2, 2020 Hi, Unfortunately, polling the API is the only way to get an active viewer count. Best, Asim Link to comment Share on other sites More sharing options...
0 Deepinder Singh Posted April 2, 2020 Author Share Posted April 2, 2020 Can we do it with webhooks? Is it easy to make a custom hook for that? Link to comment Share on other sites More sharing options...
0 Deepinder Singh Posted April 3, 2020 Author Share Posted April 3, 2020 @mahmut? any suggestions on this?On Thursday, April 2, 2020 at 8:01:16 PM UTC+5:30, Deepinder Singh wrote:Can we do it with webhooks? Is it easy to make a custom hook for that? Link to comment Share on other sites More sharing options...
0 Mahmut As1m Onat Posted April 4, 2020 Share Posted April 4, 2020 Hi, You can write a script to get the viewer count and send it to the browser if it changes. You should run this script on a machine that has access to the Ant Media Server REST API. I think it is simpler to use polling on a browser but it is possible to create such a webhook. Best, Asim Link to comment Share on other sites More sharing options...
Question
Deepinder Singh
Link to comment
Share on other sites
Top Posters For This Question
3
2
Popular Days
Apr 2
2
Apr 1
1
Apr 3
1
Apr 4
1
Top Posters For This Question
Deepinder Singh 3 posts
Mahmut As1m Onat 2 posts
Popular Days
Apr 2 2020
2 posts
Apr 1 2020
1 post
Apr 3 2020
1 post
Apr 4 2020
1 post
4 answers to this question
Recommended Posts