News & Announcements User Community Developer Community

Welcome to the RingCentral Community

Please note the community is currently under maintenance and is read-only.

Search
Make sure to review our Terms of Use and Community Guidelines.
  Please note the community is currently under maintenance and is read-only.
Home » Developers
How to manage the participants of a conference call using the webrtc library?
Tags: sdk, conferencing, conference call
Feb 26, 2024 at 9:06am   •   1 replies  •  0 likes
Karla Rosario

So far we are able to start conference calls using the webrtc library and the endpoints to create a conference token and bring in the participants. Is there a way to be able to know when a participant hangs up or when a new participant is brought in so that we can update the interface accordingly (display new participant or remove the one that hung-up)? Also, how can we remove a participant in the conference call?

1 Answer
answered on Feb 27, 2024 at 9:10am  

You can use the telephony session event notifications to catch telephony events to detect participants (added and removed) in a conference call. It is very complicated and I cannot explain how to detect here. Pay attention to the event similar to the example event below when a participant is added to a conference:

{
    "uuid": "1025258805069352046",
    "event": "/restapi/v1.0/account/80964XXXX/extension/622953XXXXX/telephony/sessions",
    "timestamp": "2024-02-27T16:04:52.558Z",
    "subscriptionId": "3ca0ec27-a916-4260-82ad-035752e61da2",
    "ownerId": "6228832XXXX",
    "body": {
      "sequence": 9,
      "sessionId": "1229016182016",
      "telephonySessionId": "s-a0d17b82ddacdz18deb4ee132z1878e190000",
      "serverId": "10.13.23.184.TAM",
      "eventTime": "2024-02-27T16:04:52.223Z",
      "parties": [
        {
          "accountId": "80964XXXX",
          "extensionId": "622953XXXXX",
          "id": "p-a0d17b82ddacdz18deb4ee132z1878e190000-1",
          "direction": "Outbound",
          "to": {
            "phoneNumber": "11119",
            "name": "Paco Vu",
            "extensionId": "622883XXXXX"
          },
          "from": {
            "phoneNumber": "+1650XXXXXXX",
            "name": "Agent 122",
            "extensionId": "622953XXXXX",
            "deviceId": "80254586XXXX"
          },
          "status": {
                                 "code": "Gone",
                                 "reason": "Conference",
                                 "peerId": {
                                        "telephonySessionId": "s-a0d7bfa2dd198z18deb4fcc72z184536c0000",
                                        "sessionId": "0",
                                        "partyId": "p-a0d7bfa2dd198z18deb4fcc72z184536c0000-2"
                                 },
            "rcc": false
          },
          "park": {},
          "missedCall": false,
          "standAlone": false,
          "muted": false
        }
      ],
      "origin": {
        "type": "Call"
      }
    }
  }

And similar to this example event when a participant is removed from the conference call:

{
    "uuid": "6754846377425683265",
    "event": "/restapi/v1.0/account/80964XXXX/extension/622953XXXXX/telephony/sessions",
    "timestamp": "2024-02-27T16:06:13.233Z",
    "subscriptionId": "3ca0ec27-a916-4260-82ad-035752e61da2",
    "ownerId": "6228832XXXX",
    "body": {
      "sequence": 11,
      "sessionId": "1229016182016",
      "telephonySessionId": "s-a0d17b82ddacdz18deb4ee132z1878e190000",
      "serverId": "10.13.23.184.TAM",
      "eventTime": "2024-02-27T16:06:13.166Z",
      "parties": [
        {
          "accountId": "80964XXXX",
          "extensionId": "622953XXXXX",
          "id": "p-a0d17b82ddacdz18deb4ee132z1878e190000-1",
          "direction": "Outbound",
          "to": {
            "phoneNumber": "11119",
            "name": "Paco Vu",
            "extensionId": "622883XXXXX"
          },
          "from": {
            "phoneNumber": "+1650XXXXXXX",
            "name": "Agent 122",
            "extensionId": "622953XXXXX",
            "deviceId": "80254586XXXX"
          },
          "status": {
            "code": "Disconnected",
            "rcc": false
          },
          "park": {},
          "missedCall": false,
          "standAlone": false,
          "muted": false
        }
      ],
      "origin": {
        "type": "Call"
      }
    }
  },

The best way to learn about this is to implement the notification, run a test conference call and print out all the events and learn from the event payloads.

You can call the Delete call party API to delete a party (from the original direct call) and that will disconnect that party from the conference call he was added to the conference call.


 1



A new Community is coming to RingCentral!

Posts are currently read-only as we transition into our new platform.

We thank you for your patience
during this downtime.

Try Workflow Builder

Did you know you can easily automate tasks like responding to SMS, team messages, and more? Plus it's included with RingCentral Video and RingEX plans!

Try RingCentral Workflow Builder

PRODUCTS
RingEX
Message
Video
Phone
OPEN ECOSYSTEM
Developer Platform
APIs
Integrated Apps
App Gallery
Developer support
Games and rewards

RESOURCES
Resource center
Blog
Product Releases
Accessibility
QUICK LINKS
App Download
RingCentral App login
Admin Portal Login
Contact Sales
© 1999-2024 RingCentral, Inc. All rights reserved. Legal Privacy Notice Site Map Contact Us