Jump to content
  • 0

Is there a Webhook when someone subscribes to a broadcast and leaves a broadcast?


Hamit
 Share

Question

Is there a Webhook when someone subscribes to a broadcast and leaves a broadcast?
I can’t find anything in the documentation.
We have the following use case scenario:
- User A starts broadcasting
- User B subscribed to the broadcast
- For every minute passed we need to deduct some credits from user B
With the Webhook that someone had subscribed we can run a custom function in our api which will start the timer function and automatically deduct every minute.
Do you have any suggestions?

Link to comment
Share on other sites

  • Answers 4
  • Created
  • Last Reply

Top Posters For This Question

4 answers to this question

Recommended Posts

  • 0
50 minutes ago, Hamit said:

Is there a Webhook when someone subscribes to a broadcast and leaves a broadcast?
I can’t find anything in the documentation.
We have the following use case scenario:
- User A starts broadcasting
- User B subscribed to the broadcast
- For every minute passed we need to deduct some credits from user B
With the Webhook that someone had subscribed we can run a custom function in our api which will start the timer function and automatically deduct every minute.
Do you have any suggestions?

Since ant media does not have this facility via plugins, the other way would be to add the code in web.handler (application) https://github.com/ant-media/StreamApp/blob/master/src/main/webapp/WEB-INF/red5-web.xml#L60. That means making a custom webapp.

 

Other hackish way is to poll the REST APPI frequently to determine if a new connection has joined in and trigger a webbook.

Link to comment
Share on other sites

 Share

×
×
  • Create New...