Skip to content

Commit 86fd82f

Browse files
committed
update with review comments
1 parent 620e31e commit 86fd82f

File tree

4 files changed

+45
-12
lines changed

4 files changed

+45
-12
lines changed

articles/communication-services/quickstarts/rooms/includes/rooms-quickstart-java.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,7 @@ mvn archetype:generate -DgroupId=com.contoso.app -DartifactId=rooms-quickstart -
3232
```
3333

3434
### Include the package
35+
3536
#### Include the BOM file
3637

3738
Include the `azure-sdk-bom` to your project to take dependency on the General Availability (GA) version of the library. In the following snippet, replace the {bom_version_to_target} placeholder with the version number.

articles/communication-services/quickstarts/rooms/includes/rooms-quickstart-javascript.md

Lines changed: 8 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ Run `npm init` to create a package.json file with default settings.
3535
npm init -y
3636
```
3737

38-
###Install the packages
38+
### Install the packages
3939

4040
Use the `npm install` command to install the below Communication Services SDKs for JavaScript.
4141

@@ -132,15 +132,14 @@ Participants that have been added to a `room` become eligible to join calls.
132132

133133
To remove a participant from a `room` and revoke their access, update the `Participants` list:
134134

135-
//TODO
136-
```csharp
137-
var communicationUser = "<CommunicationUserId1>";
138-
139-
List<CommunicationIdentifier> toRemoveCommunicationUsers = new List<CommunicationIdentifier>();
140-
toRemoveCommunicationUsers.Add(new CommunicationUserIdentifier(communicationUser));
135+
```javascript
136+
// request payload to delete both users from the room
137+
const removeParticipantsRequest = {
138+
participants: [user1.user, user2.user],
139+
};
141140

142-
Response<RoomModel> removeParticipantResponse = await roomsClient.RemoveParticipantsAsync(createdRoomId, toRemoveCommunicationUsers);
143-
RoomModel removeParticipantsRoom = removeParticipantResponse.Value;
141+
// remove both users from the room with the request payload
142+
await roomsClient.removeParticipants(roomId, removeParticipantsRequest);
144143
```
145144

146145
### Delete room

articles/communication-services/quickstarts/rooms/includes/rooms-quickstart-net.md

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,14 @@ cd RoomsQuickstart
3737
dotnet build
3838
```
3939

40+
### Install the package
41+
42+
Install the Azure Communication Rooms client library for .NET with [NuGet][https://www.nuget.org/]:
43+
44+
```console
45+
dotnet add package Azure.Communication.Rooms
46+
```
47+
4048
### Initialize a room client
4149

4250
Create a new `RoomsClient` object that will be used to create new `rooms` and manage their properties and lifecycle. The connection string of your `Communications Service` will be used to authenticate the request. For more information on connection strings, see [this page](../../create-communication-resource.md#access-your-connection-strings-and-service-endpoints).
@@ -99,7 +107,7 @@ toAddCommunicationUsers.Add(new RoomParticipant(new CommunicationUserIdentifier(
99107
toAddCommunicationUsers.Add(new RoomParticipant(new CommunicationUserIdentifier(communicationUser3), "Attendee"));
100108

101109
Response<RoomModel> addParticipantResponse = await roomsClient.AddParticipantsAsync(createdRoomId, toAddCommunicationUsers);
102-
RoomModel addedParticipantsRoom = addParticipantResponse.Value;
110+
ParticipantsCollection addedParticipantsRoom = addParticipantResponse.Value;
103111
```
104112

105113
Participants that have been added to a `room` become eligible to join calls.
@@ -115,7 +123,7 @@ var communicationUser = "<CommunicationUserId1>";
115123
toRemoveCommunicationUsers.Add(new CommunicationUserIdentifier(communicationUser));
116124

117125
Response<RoomModel> removeParticipantResponse = await roomsClient.RemoveParticipantsAsync(createdRoomId, toRemoveCommunicationUsers);
118-
RoomModel removeParticipantsRoom = removeParticipantResponse.Value;
126+
ParticipantsCollection removeParticipantsRoom = removeParticipantResponse.Value;
119127
```
120128

121129
### Delete room

articles/communication-services/quickstarts/rooms/includes/rooms-quickstart-python.md

Lines changed: 26 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,32 @@ In a terminal or console window, create a new folder for your application and na
3030
mkdir acs-rooms-quickstart && cd acs-rooms-quickstart
3131
```
3232

33-
Create a new file called
33+
Create a new file called `rooms-quickstart.py` and add the basic program structure.
34+
35+
```python
36+
from azure.communication.rooms import (
37+
RoomsClient,
38+
RoomParticipant,
39+
RoleType,
40+
RoomJoinPolicy
41+
)
42+
from azure.communication.identity import CommunicationUserIdentifier
43+
44+
class RoomsQuickstart(object):
45+
#room method implementations go here
46+
47+
if __name__ == '__main__':
48+
rooms = RoomsQuickstart()
49+
```
50+
51+
### Install the packages
52+
53+
From a console prompt, navigate to the directory containing the rooms.py file, then execute the following command:
54+
55+
```console
56+
pip install azure_communication_rooms
57+
pip install azure.communication.identity
58+
```
3459

3560
### Initialize a room client
3661

0 commit comments

Comments
 (0)