Cloudron makes it easy to run web apps like WordPress, Nextcloud, GitLab on your server. Find out more or install now.


Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Bookmarks
  • Search
Skins
  • Light
  • Brite
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Brand Logo

Cloudron Forum

Apps - Status | Demo | Docs | Install
  1. Cloudron Forum
  2. MiroTalk
  3. Mirotalk SFU remote room control

Mirotalk SFU remote room control

Scheduled Pinned Locked Moved MiroTalk
4 Posts 3 Posters 13 Views 3 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • P Offline
    P Offline
    pdurante1981
    wrote last edited by
    #1

    Looking at the existing API endpoints for Mirotalk SFU I didn't see a way in which we could remotely end meetings. We were looking to build a video conferencing app that has billable minutes. We needed a way in which to remotely end a call if a person has used all minutes for their call. Unless I should be using some other Mirotalk product? Let me know. Thanks!

    MiroTalkM 1 Reply Last reply
    0
    • nebulonN Offline
      nebulonN Offline
      nebulon
      Staff
      wrote last edited by
      #2

      This is probably a question for the mirotalk upstream project. @mirotalk is sometimes around here in the forum, so maybe he sees this. I guess since you try to build a business on top of mirotalk, might be worth making contact there to see if this is somehow impacted by the license of mirotalk.

      1 Reply Last reply
      0
      • P pdurante1981

        Looking at the existing API endpoints for Mirotalk SFU I didn't see a way in which we could remotely end meetings. We were looking to build a video conferencing app that has billable minutes. We needed a way in which to remotely end a call if a person has used all minutes for their call. Unless I should be using some other Mirotalk product? Let me know. Thanks!

        MiroTalkM Offline
        MiroTalkM Offline
        MiroTalk
        App Maintainer
        wrote last edited by
        #3

        Hi @pdurante1981 πŸ‘‹

        For commercial use, an Extended License is required. You can purchase it directly from CodeCanyon here:
        https://codecanyon.net/user/miroslavpejic85/portfolio

        Regarding call duration, this is supported in both MiroTalk SFU and MiroTalk P2P.

        There are two ways to control room duration:


        1️⃣ Create a room with a duration (via URL)

        • SFU: https://sfu.mirotalk.com/customizeRoom
        • P2P: https://p2p.mirotalk.com/customizeRoom

        Pass the duration parameter in HH:MM:SS format (e.g. 00:30:00).

        Docs:

        • SFU Join Room API: https://docs.mirotalk.com/mirotalk-sfu/join-room/
        • P2P Join Room API: https://docs.mirotalk.com/mirotalk-p2p/join-room/

        2️⃣ Set duration via API (recommended for billing systems)

        Include:

        duration=HH:MM:SS
        

        Example: 00:30:00

        Direct Join API:

        • SFU: https://docs.mirotalk.com/mirotalk-sfu/api/#direct-join-entry-point
        • P2P: https://docs.mirotalk.com/mirotalk-p2p/api/#direct-join-entry-point

        When the timer expires, the room closes automatically.


        πŸ”’ Also check Moderation settings

        In the room settings β†’ Moderation, there is an option:

        When presenter leaves the room β†’ disconnect all participants

        You can end the meeting for everyone that way as well.


        At the moment there isn’t a dedicated endpoint to forcibly close a specific room on demand, but that makes sense for billing use cases, I’ll add it to the roadmap πŸ‘

        1 Reply Last reply
        1
        • MiroTalkM Offline
          MiroTalkM Offline
          MiroTalk
          App Maintainer
          wrote last edited by
          #4

          Great news @pdurante1981 @nebulon πŸ‘‹

          The Meeting END API has been implemented in MiroTalk SFU v2.1.20.

          This allows you to remotely terminate an active meeting by room name, perfect for billable minutes or subscription-based systems.


          βœ… New Endpoint

          DELETE /api/v1/meeting/:room
          

          What it does:

          • Disconnects all connected peers
          • Optionally redirects them to a custom URL
          • Disables the β€œbeforeunload” confirmation popup when ended via API
          • Protected via API secret key
          • Fully documented in Swagger
          • Includes example scripts (JS, Shell, Python, PHP)
          • Covered by unit tests

          πŸ” Enable the Feature

          In your env file:

          API_KEY_SECRET=mirotalksfu_default_secret
          API_ALLOW_MEETING_END=true
          

          By default, this endpoint is disabled for security reasons.


          πŸš€ Quick Examples

          End meeting (peers return to home page)

          curl -X DELETE http://localhost:3010/api/v1/meeting/test \
            -H "authorization: mirotalksfu_default_secret" \
            -H "Content-Type: application/json"
          

          End meeting with custom redirect

          curl -X DELETE http://localhost:3010/api/v1/meeting/test \
            -H "authorization: mirotalksfu_default_secret" \
            -H "Content-Type: application/json" \
            -d '{"redirect": "https://docs.mirotalk.com/about"}'
          

          πŸ“˜ Documentation

          Full API reference:
          https://docs.mirotalk.com/mirotalk-sfu/api/#meeting-end-entry-point


          This should now fully cover your use case for remotely ending meetings when user minutes expire πŸ‘

          🐳 Docker image build is currently in progress...

          1 Reply Last reply
          1
          Reply
          • Reply as topic
          Log in to reply
          • Oldest to Newest
          • Newest to Oldest
          • Most Votes


          • Login

          • Don't have an account? Register

          • Login or register to search.
          • First post
            Last post
          0
          • Categories
          • Recent
          • Tags
          • Popular
          • Bookmarks
          • Search