You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Lobby admit and reject are the apis on `Call` or `TeamsCall`. It allows user to admit and reject participants from Teams meeting lobby.
16
16
17
-
# Manage participants in Teams meeting Lobby
17
+
# Manage Teams meeting Lobby
18
18
19
19
In this article, you will learn how to admit and reject participants from Microsoft Teams meetings lobby by using Azure Communication Service calling SDKs.
20
20
@@ -26,7 +26,7 @@ In this article, you will learn how to admit and reject participants from Micros
26
26
- Optional: Complete the quickstart to [add voice calling to your application](../../quickstarts/voice-video-calling/getting-started-with-calling.md)
27
27
28
28
User ends up in the lobby depending on Microsoft Teams configuration. The controls are described here:
29
-
[Learn more about Teams configuration ](https://learn.microsoft.com/en-us/azure/communication-services/concepts/interop/guest/teams-administration)
29
+
[Learn more about Teams configuration ](../../concepts/interop/guest/teams-administration.md)
30
30
31
31
Microsoft 365 or Azure Communication Services users can admit or reject users from lobby, if they are connected to Teams meeting and have Organizer, Co-organizer, or Presenter meeting role.
32
32
[Learn more about meeting roles](https://support.microsoft.com/office/roles-in-a-teams-meeting-c16fa7d0-1666-4dde-8686-0a0bfe16e019)
@@ -41,15 +41,58 @@ The first thing is to get the `Call` or `TeamsCall` object of admitter: [Learn h
41
41
42
42
To know who is in the lobby, you could check the state of a remote participant. The `remoteParticipant` with `InLobby` state indicates that remote participant is in lobby.
console.log(`${remoteParticipant._displayName} is in the lobby`);
64
+
}
65
+
// Subscribe to remoteParticipant's 'stateChanged' event for value changes.
66
+
remoteParticipant.on('stateChanged', () => {
67
+
console.log(`Remote participant state changed: ${remoteParticipant.state}`);
68
+
if(remoteParticipant.state==='InLobby'){
69
+
console.log(`${remoteParticipant._displayName} is in the lobby`);
70
+
}
71
+
elseif(remoteParticipant.state==='Connected'){
72
+
console.log(`${remoteParticipant._displayName} is in the meeting`);
73
+
}
74
+
});
75
+
} catch (error) {
76
+
console.error(error);
77
+
}
78
+
}
79
+
80
+
call.on('remoteParticipantsUpdated', args=> {
81
+
args.added.forEach(p=> {
82
+
subscribeToRemoteParticipant(p);
83
+
});
84
+
args.removed.forEach(p=> {
85
+
console.log(`${p._displayName} leave the meeting`);
86
+
});
87
+
});
88
+
89
+
call.remoteParticipants.forEach(p=> {
90
+
subscribeToRemoteParticipant(p);
91
+
});
92
+
```
93
+
52
94
Before admit or reject `remoteParticipant` with `InLobby` state, you could get the identifier for a remote participant:
95
+
53
96
```js
54
97
constidentifier=remoteParticipant.identifier;
55
98
```
@@ -66,6 +109,7 @@ The `identifier` can be one of the following `CommunicationIdentifier` types:
66
109
To admit, reject or admit all users from the lobby, you can use the `admit`, `rejectParticipant` and `admitAll` asynchronous APIs:
67
110
68
111
You can admit specific user to the Teams meeting from lobby by calling the method `admit` on the object `TeamsCall` or `Call`. The method accepts identifiers `MicrosoftTeamsUserIdentifier`, `CommunicationUserIdentifier`, `PhoneNumberIdentifier` or `UnknownIdentifier` as input.
0 commit comments