forked from livekit/protocol
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathlivekit_room.proto
111 lines (94 loc) · 2.78 KB
/
livekit_room.proto
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
syntax = "proto3";
package livekit;
option go_package = "github.com/livekit/protocol/livekit";
option csharp_namespace = "LiveKit.Proto";
option ruby_package = "LiveKit::Proto";
import "livekit_models.proto";
import "livekit_egress.proto";
// Room service that can be performed on any node
// they are Twirp-based HTTP req/responses
service RoomService {
// Deletes an existing room by name or id. Requires `roomCreate` permission.
// DeleteRoom will disconnect all participants that are currently in the room.
rpc DeleteRoom(DeleteRoomRequest) returns (DeleteRoomResponse);
// Removes a participant from room. Requires `roomAdmin`
rpc RemoveParticipant(RoomParticipantIdentity) returns (RemoveParticipantResponse);
// Mute/unmute a participant's track, Requires `roomAdmin`
rpc MutePublishedTrack(MuteRoomTrackRequest) returns (MuteRoomTrackResponse);
}
message CreateRoomRequest {
// name of the room
string name = 1;
// number of seconds to keep the room open if no one joins
uint32 empty_timeout = 2;
// limit number of participants that can be in a room
uint32 max_participants = 3;
// override the node room is allocated to, for debugging
string node_id = 4;
// metadata of room
string metadata = 5;
// egress
RoomEgress egress = 6;
}
message RoomEgress {
RoomCompositeEgressRequest room = 1;
AutoTrackEgress tracks = 2;
}
message DeleteRoomRequest {
// name of the room
string room = 1;
}
message DeleteRoomResponse {
}
message RoomParticipantIdentity {
// name of the room
string room = 1;
// identity of the participant
string identity = 2;
}
message RemoveParticipantResponse {
}
message MuteRoomTrackRequest {
// name of the room
string room = 1;
string identity = 2;
// sid of the track to mute
string track_sid = 3;
// set to true to mute, false to unmute
bool muted = 4;
}
message MuteRoomTrackResponse {
TrackInfo track = 1;
}
message UpdateParticipantRequest {
string room = 1;
string identity = 2;
// metadata to update. skipping updates if left empty
string metadata = 3;
// set to update the participant's permissions
ParticipantPermission permission = 4;
// display name to update
string name = 5;
}
message UpdateSubscriptionsRequest {
string room = 1;
string identity = 2;
// list of sids of tracks
repeated string track_sids = 3;
// set to true to subscribe, false to unsubscribe from tracks
bool subscribe = 4;
// list of participants and their tracks
repeated ParticipantTracks participant_tracks = 5;
}
message SendDataRequest {
string room = 1;
bytes data = 2;
DataPacket.Kind kind = 3;
repeated string destination_sids = 4;
optional string topic = 5;
}
message UpdateRoomMetadataRequest {
string room = 1;
// metadata to update. skipping updates if left empty
string metadata = 2;
}