livekit-server-sdk 0.5.8 → 1.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.eslintrc.js +1 -1
- package/.github/workflows/test.yaml +3 -0
- package/.prettierignore +7 -0
- package/README.md +13 -9
- package/dist/AccessToken.d.ts +5 -0
- package/dist/AccessToken.js +7 -1
- package/dist/AccessToken.js.map +1 -1
- package/dist/AccessToken.test.js +4 -0
- package/dist/AccessToken.test.js.map +1 -1
- package/dist/EgressClient.d.ts +60 -0
- package/dist/EgressClient.js +198 -0
- package/dist/EgressClient.js.map +1 -0
- package/dist/RecordingServiceClient.js +5 -1
- package/dist/RecordingServiceClient.js.map +1 -1
- package/dist/RoomServiceClient.d.ts +1 -2
- package/dist/RoomServiceClient.js.map +1 -1
- package/dist/TwirpRPC.js.map +1 -1
- package/dist/WebhookReceiver.test.js.map +1 -1
- package/dist/grants.d.ts +4 -1
- package/dist/index.d.ts +3 -2
- package/dist/index.js +5 -2
- package/dist/index.js.map +1 -1
- package/dist/proto/google/protobuf/empty.d.ts +6 -2
- package/dist/proto/google/protobuf/empty.js +32 -12
- package/dist/proto/google/protobuf/empty.js.map +1 -1
- package/dist/proto/google/protobuf/timestamp.d.ts +132 -0
- package/dist/proto/google/protobuf/timestamp.js +107 -0
- package/dist/proto/google/protobuf/timestamp.js.map +1 -0
- package/dist/proto/livekit_egress.d.ts +2283 -0
- package/dist/proto/livekit_egress.js +1819 -0
- package/dist/proto/livekit_egress.js.map +1 -0
- package/dist/proto/livekit_models.d.ts +675 -13
- package/dist/proto/livekit_models.js +1414 -838
- package/dist/proto/livekit_models.js.map +1 -1
- package/dist/proto/livekit_recording.d.ts +199 -17
- package/dist/proto/livekit_recording.js +284 -570
- package/dist/proto/livekit_recording.js.map +1 -1
- package/dist/proto/livekit_room.d.ts +566 -34
- package/dist/proto/livekit_room.js +302 -671
- package/dist/proto/livekit_room.js.map +1 -1
- package/dist/proto/livekit_webhook.d.ts +1031 -6
- package/dist/proto/livekit_webhook.js +106 -95
- package/dist/proto/livekit_webhook.js.map +1 -1
- package/package.json +12 -7
|
@@ -1,24 +1,39 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } });
|
|
5
|
+
}) : (function(o, m, k, k2) {
|
|
6
|
+
if (k2 === undefined) k2 = k;
|
|
7
|
+
o[k2] = m[k];
|
|
8
|
+
}));
|
|
9
|
+
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
10
|
+
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
11
|
+
}) : function(o, v) {
|
|
12
|
+
o["default"] = v;
|
|
13
|
+
});
|
|
14
|
+
var __importStar = (this && this.__importStar) || function (mod) {
|
|
15
|
+
if (mod && mod.__esModule) return mod;
|
|
16
|
+
var result = {};
|
|
17
|
+
if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
|
|
18
|
+
__setModuleDefault(result, mod);
|
|
19
|
+
return result;
|
|
20
|
+
};
|
|
2
21
|
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
22
|
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
23
|
};
|
|
5
24
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
-
exports.UpdateRoomMetadataRequest = exports.SendDataResponse = exports.SendDataRequest = exports.UpdateSubscriptionsResponse = exports.UpdateSubscriptionsRequest = exports.UpdateParticipantRequest = exports.
|
|
25
|
+
exports.UpdateRoomMetadataRequest = exports.SendDataResponse = exports.SendDataRequest = exports.UpdateSubscriptionsResponse = exports.UpdateSubscriptionsRequest = exports.UpdateParticipantRequest = exports.MuteRoomTrackResponse = exports.MuteRoomTrackRequest = exports.RemoveParticipantResponse = exports.RoomParticipantIdentity = exports.ListParticipantsResponse = exports.ListParticipantsRequest = exports.DeleteRoomResponse = exports.DeleteRoomRequest = exports.ListRoomsResponse = exports.ListRoomsRequest = exports.CreateRoomRequest = exports.protobufPackage = void 0;
|
|
7
26
|
/* eslint-disable */
|
|
8
27
|
const long_1 = __importDefault(require("long"));
|
|
9
|
-
const
|
|
28
|
+
const _m0 = __importStar(require("protobufjs/minimal"));
|
|
10
29
|
const livekit_models_1 = require("./livekit_models");
|
|
11
|
-
exports.protobufPackage =
|
|
12
|
-
|
|
13
|
-
name:
|
|
14
|
-
|
|
15
|
-
maxParticipants: 0,
|
|
16
|
-
nodeId: "",
|
|
17
|
-
metadata: "",
|
|
18
|
-
};
|
|
30
|
+
exports.protobufPackage = 'livekit';
|
|
31
|
+
function createBaseCreateRoomRequest() {
|
|
32
|
+
return { name: '', emptyTimeout: 0, maxParticipants: 0, nodeId: '', metadata: '' };
|
|
33
|
+
}
|
|
19
34
|
exports.CreateRoomRequest = {
|
|
20
|
-
encode(message, writer =
|
|
21
|
-
if (message.name !==
|
|
35
|
+
encode(message, writer = _m0.Writer.create()) {
|
|
36
|
+
if (message.name !== '') {
|
|
22
37
|
writer.uint32(10).string(message.name);
|
|
23
38
|
}
|
|
24
39
|
if (message.emptyTimeout !== 0) {
|
|
@@ -27,18 +42,18 @@ exports.CreateRoomRequest = {
|
|
|
27
42
|
if (message.maxParticipants !== 0) {
|
|
28
43
|
writer.uint32(24).uint32(message.maxParticipants);
|
|
29
44
|
}
|
|
30
|
-
if (message.nodeId !==
|
|
45
|
+
if (message.nodeId !== '') {
|
|
31
46
|
writer.uint32(34).string(message.nodeId);
|
|
32
47
|
}
|
|
33
|
-
if (message.metadata !==
|
|
48
|
+
if (message.metadata !== '') {
|
|
34
49
|
writer.uint32(42).string(message.metadata);
|
|
35
50
|
}
|
|
36
51
|
return writer;
|
|
37
52
|
},
|
|
38
53
|
decode(input, length) {
|
|
39
|
-
const reader = input instanceof
|
|
54
|
+
const reader = input instanceof _m0.Reader ? input : new _m0.Reader(input);
|
|
40
55
|
let end = length === undefined ? reader.len : reader.pos + length;
|
|
41
|
-
const message =
|
|
56
|
+
const message = createBaseCreateRoomRequest();
|
|
42
57
|
while (reader.pos < end) {
|
|
43
58
|
const tag = reader.uint32();
|
|
44
59
|
switch (tag >>> 3) {
|
|
@@ -65,100 +80,49 @@ exports.CreateRoomRequest = {
|
|
|
65
80
|
return message;
|
|
66
81
|
},
|
|
67
82
|
fromJSON(object) {
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
}
|
|
75
|
-
if (object.emptyTimeout !== undefined && object.emptyTimeout !== null) {
|
|
76
|
-
message.emptyTimeout = Number(object.emptyTimeout);
|
|
77
|
-
}
|
|
78
|
-
else {
|
|
79
|
-
message.emptyTimeout = 0;
|
|
80
|
-
}
|
|
81
|
-
if (object.maxParticipants !== undefined &&
|
|
82
|
-
object.maxParticipants !== null) {
|
|
83
|
-
message.maxParticipants = Number(object.maxParticipants);
|
|
84
|
-
}
|
|
85
|
-
else {
|
|
86
|
-
message.maxParticipants = 0;
|
|
87
|
-
}
|
|
88
|
-
if (object.nodeId !== undefined && object.nodeId !== null) {
|
|
89
|
-
message.nodeId = String(object.nodeId);
|
|
90
|
-
}
|
|
91
|
-
else {
|
|
92
|
-
message.nodeId = "";
|
|
93
|
-
}
|
|
94
|
-
if (object.metadata !== undefined && object.metadata !== null) {
|
|
95
|
-
message.metadata = String(object.metadata);
|
|
96
|
-
}
|
|
97
|
-
else {
|
|
98
|
-
message.metadata = "";
|
|
99
|
-
}
|
|
100
|
-
return message;
|
|
83
|
+
return {
|
|
84
|
+
name: isSet(object.name) ? String(object.name) : '',
|
|
85
|
+
emptyTimeout: isSet(object.emptyTimeout) ? Number(object.emptyTimeout) : 0,
|
|
86
|
+
maxParticipants: isSet(object.maxParticipants) ? Number(object.maxParticipants) : 0,
|
|
87
|
+
nodeId: isSet(object.nodeId) ? String(object.nodeId) : '',
|
|
88
|
+
metadata: isSet(object.metadata) ? String(object.metadata) : '',
|
|
89
|
+
};
|
|
101
90
|
},
|
|
102
91
|
toJSON(message) {
|
|
103
92
|
const obj = {};
|
|
104
93
|
message.name !== undefined && (obj.name = message.name);
|
|
105
|
-
message.emptyTimeout !== undefined &&
|
|
106
|
-
(obj.emptyTimeout = message.emptyTimeout);
|
|
94
|
+
message.emptyTimeout !== undefined && (obj.emptyTimeout = Math.round(message.emptyTimeout));
|
|
107
95
|
message.maxParticipants !== undefined &&
|
|
108
|
-
(obj.maxParticipants = message.maxParticipants);
|
|
96
|
+
(obj.maxParticipants = Math.round(message.maxParticipants));
|
|
109
97
|
message.nodeId !== undefined && (obj.nodeId = message.nodeId);
|
|
110
98
|
message.metadata !== undefined && (obj.metadata = message.metadata);
|
|
111
99
|
return obj;
|
|
112
100
|
},
|
|
113
101
|
fromPartial(object) {
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
if (object.emptyTimeout !== undefined && object.emptyTimeout !== null) {
|
|
122
|
-
message.emptyTimeout = object.emptyTimeout;
|
|
123
|
-
}
|
|
124
|
-
else {
|
|
125
|
-
message.emptyTimeout = 0;
|
|
126
|
-
}
|
|
127
|
-
if (object.maxParticipants !== undefined &&
|
|
128
|
-
object.maxParticipants !== null) {
|
|
129
|
-
message.maxParticipants = object.maxParticipants;
|
|
130
|
-
}
|
|
131
|
-
else {
|
|
132
|
-
message.maxParticipants = 0;
|
|
133
|
-
}
|
|
134
|
-
if (object.nodeId !== undefined && object.nodeId !== null) {
|
|
135
|
-
message.nodeId = object.nodeId;
|
|
136
|
-
}
|
|
137
|
-
else {
|
|
138
|
-
message.nodeId = "";
|
|
139
|
-
}
|
|
140
|
-
if (object.metadata !== undefined && object.metadata !== null) {
|
|
141
|
-
message.metadata = object.metadata;
|
|
142
|
-
}
|
|
143
|
-
else {
|
|
144
|
-
message.metadata = "";
|
|
145
|
-
}
|
|
102
|
+
var _a, _b, _c, _d, _e;
|
|
103
|
+
const message = createBaseCreateRoomRequest();
|
|
104
|
+
message.name = (_a = object.name) !== null && _a !== void 0 ? _a : '';
|
|
105
|
+
message.emptyTimeout = (_b = object.emptyTimeout) !== null && _b !== void 0 ? _b : 0;
|
|
106
|
+
message.maxParticipants = (_c = object.maxParticipants) !== null && _c !== void 0 ? _c : 0;
|
|
107
|
+
message.nodeId = (_d = object.nodeId) !== null && _d !== void 0 ? _d : '';
|
|
108
|
+
message.metadata = (_e = object.metadata) !== null && _e !== void 0 ? _e : '';
|
|
146
109
|
return message;
|
|
147
110
|
},
|
|
148
111
|
};
|
|
149
|
-
|
|
112
|
+
function createBaseListRoomsRequest() {
|
|
113
|
+
return { names: [] };
|
|
114
|
+
}
|
|
150
115
|
exports.ListRoomsRequest = {
|
|
151
|
-
encode(message, writer =
|
|
116
|
+
encode(message, writer = _m0.Writer.create()) {
|
|
152
117
|
for (const v of message.names) {
|
|
153
118
|
writer.uint32(10).string(v);
|
|
154
119
|
}
|
|
155
120
|
return writer;
|
|
156
121
|
},
|
|
157
122
|
decode(input, length) {
|
|
158
|
-
const reader = input instanceof
|
|
123
|
+
const reader = input instanceof _m0.Reader ? input : new _m0.Reader(input);
|
|
159
124
|
let end = length === undefined ? reader.len : reader.pos + length;
|
|
160
|
-
const message =
|
|
161
|
-
message.names = [];
|
|
125
|
+
const message = createBaseListRoomsRequest();
|
|
162
126
|
while (reader.pos < end) {
|
|
163
127
|
const tag = reader.uint32();
|
|
164
128
|
switch (tag >>> 3) {
|
|
@@ -173,14 +137,9 @@ exports.ListRoomsRequest = {
|
|
|
173
137
|
return message;
|
|
174
138
|
},
|
|
175
139
|
fromJSON(object) {
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
for (const e of object.names) {
|
|
180
|
-
message.names.push(String(e));
|
|
181
|
-
}
|
|
182
|
-
}
|
|
183
|
-
return message;
|
|
140
|
+
return {
|
|
141
|
+
names: Array.isArray(object === null || object === void 0 ? void 0 : object.names) ? object.names.map((e) => String(e)) : [],
|
|
142
|
+
};
|
|
184
143
|
},
|
|
185
144
|
toJSON(message) {
|
|
186
145
|
const obj = {};
|
|
@@ -193,29 +152,26 @@ exports.ListRoomsRequest = {
|
|
|
193
152
|
return obj;
|
|
194
153
|
},
|
|
195
154
|
fromPartial(object) {
|
|
196
|
-
|
|
197
|
-
message
|
|
198
|
-
|
|
199
|
-
for (const e of object.names) {
|
|
200
|
-
message.names.push(e);
|
|
201
|
-
}
|
|
202
|
-
}
|
|
155
|
+
var _a;
|
|
156
|
+
const message = createBaseListRoomsRequest();
|
|
157
|
+
message.names = ((_a = object.names) === null || _a === void 0 ? void 0 : _a.map((e) => e)) || [];
|
|
203
158
|
return message;
|
|
204
159
|
},
|
|
205
160
|
};
|
|
206
|
-
|
|
161
|
+
function createBaseListRoomsResponse() {
|
|
162
|
+
return { rooms: [] };
|
|
163
|
+
}
|
|
207
164
|
exports.ListRoomsResponse = {
|
|
208
|
-
encode(message, writer =
|
|
165
|
+
encode(message, writer = _m0.Writer.create()) {
|
|
209
166
|
for (const v of message.rooms) {
|
|
210
167
|
livekit_models_1.Room.encode(v, writer.uint32(10).fork()).ldelim();
|
|
211
168
|
}
|
|
212
169
|
return writer;
|
|
213
170
|
},
|
|
214
171
|
decode(input, length) {
|
|
215
|
-
const reader = input instanceof
|
|
172
|
+
const reader = input instanceof _m0.Reader ? input : new _m0.Reader(input);
|
|
216
173
|
let end = length === undefined ? reader.len : reader.pos + length;
|
|
217
|
-
const message =
|
|
218
|
-
message.rooms = [];
|
|
174
|
+
const message = createBaseListRoomsResponse();
|
|
219
175
|
while (reader.pos < end) {
|
|
220
176
|
const tag = reader.uint32();
|
|
221
177
|
switch (tag >>> 3) {
|
|
@@ -230,14 +186,9 @@ exports.ListRoomsResponse = {
|
|
|
230
186
|
return message;
|
|
231
187
|
},
|
|
232
188
|
fromJSON(object) {
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
for (const e of object.rooms) {
|
|
237
|
-
message.rooms.push(livekit_models_1.Room.fromJSON(e));
|
|
238
|
-
}
|
|
239
|
-
}
|
|
240
|
-
return message;
|
|
189
|
+
return {
|
|
190
|
+
rooms: Array.isArray(object === null || object === void 0 ? void 0 : object.rooms) ? object.rooms.map((e) => livekit_models_1.Room.fromJSON(e)) : [],
|
|
191
|
+
};
|
|
241
192
|
},
|
|
242
193
|
toJSON(message) {
|
|
243
194
|
const obj = {};
|
|
@@ -250,28 +201,26 @@ exports.ListRoomsResponse = {
|
|
|
250
201
|
return obj;
|
|
251
202
|
},
|
|
252
203
|
fromPartial(object) {
|
|
253
|
-
|
|
254
|
-
message
|
|
255
|
-
|
|
256
|
-
for (const e of object.rooms) {
|
|
257
|
-
message.rooms.push(livekit_models_1.Room.fromPartial(e));
|
|
258
|
-
}
|
|
259
|
-
}
|
|
204
|
+
var _a;
|
|
205
|
+
const message = createBaseListRoomsResponse();
|
|
206
|
+
message.rooms = ((_a = object.rooms) === null || _a === void 0 ? void 0 : _a.map((e) => livekit_models_1.Room.fromPartial(e))) || [];
|
|
260
207
|
return message;
|
|
261
208
|
},
|
|
262
209
|
};
|
|
263
|
-
|
|
210
|
+
function createBaseDeleteRoomRequest() {
|
|
211
|
+
return { room: '' };
|
|
212
|
+
}
|
|
264
213
|
exports.DeleteRoomRequest = {
|
|
265
|
-
encode(message, writer =
|
|
266
|
-
if (message.room !==
|
|
214
|
+
encode(message, writer = _m0.Writer.create()) {
|
|
215
|
+
if (message.room !== '') {
|
|
267
216
|
writer.uint32(10).string(message.room);
|
|
268
217
|
}
|
|
269
218
|
return writer;
|
|
270
219
|
},
|
|
271
220
|
decode(input, length) {
|
|
272
|
-
const reader = input instanceof
|
|
221
|
+
const reader = input instanceof _m0.Reader ? input : new _m0.Reader(input);
|
|
273
222
|
let end = length === undefined ? reader.len : reader.pos + length;
|
|
274
|
-
const message =
|
|
223
|
+
const message = createBaseDeleteRoomRequest();
|
|
275
224
|
while (reader.pos < end) {
|
|
276
225
|
const tag = reader.uint32();
|
|
277
226
|
switch (tag >>> 3) {
|
|
@@ -286,14 +235,9 @@ exports.DeleteRoomRequest = {
|
|
|
286
235
|
return message;
|
|
287
236
|
},
|
|
288
237
|
fromJSON(object) {
|
|
289
|
-
|
|
290
|
-
|
|
291
|
-
|
|
292
|
-
}
|
|
293
|
-
else {
|
|
294
|
-
message.room = "";
|
|
295
|
-
}
|
|
296
|
-
return message;
|
|
238
|
+
return {
|
|
239
|
+
room: isSet(object.room) ? String(object.room) : '',
|
|
240
|
+
};
|
|
297
241
|
},
|
|
298
242
|
toJSON(message) {
|
|
299
243
|
const obj = {};
|
|
@@ -301,25 +245,23 @@ exports.DeleteRoomRequest = {
|
|
|
301
245
|
return obj;
|
|
302
246
|
},
|
|
303
247
|
fromPartial(object) {
|
|
304
|
-
|
|
305
|
-
|
|
306
|
-
|
|
307
|
-
}
|
|
308
|
-
else {
|
|
309
|
-
message.room = "";
|
|
310
|
-
}
|
|
248
|
+
var _a;
|
|
249
|
+
const message = createBaseDeleteRoomRequest();
|
|
250
|
+
message.room = (_a = object.room) !== null && _a !== void 0 ? _a : '';
|
|
311
251
|
return message;
|
|
312
252
|
},
|
|
313
253
|
};
|
|
314
|
-
|
|
254
|
+
function createBaseDeleteRoomResponse() {
|
|
255
|
+
return {};
|
|
256
|
+
}
|
|
315
257
|
exports.DeleteRoomResponse = {
|
|
316
|
-
encode(_, writer =
|
|
258
|
+
encode(_, writer = _m0.Writer.create()) {
|
|
317
259
|
return writer;
|
|
318
260
|
},
|
|
319
261
|
decode(input, length) {
|
|
320
|
-
const reader = input instanceof
|
|
262
|
+
const reader = input instanceof _m0.Reader ? input : new _m0.Reader(input);
|
|
321
263
|
let end = length === undefined ? reader.len : reader.pos + length;
|
|
322
|
-
const message =
|
|
264
|
+
const message = createBaseDeleteRoomResponse();
|
|
323
265
|
while (reader.pos < end) {
|
|
324
266
|
const tag = reader.uint32();
|
|
325
267
|
switch (tag >>> 3) {
|
|
@@ -331,30 +273,31 @@ exports.DeleteRoomResponse = {
|
|
|
331
273
|
return message;
|
|
332
274
|
},
|
|
333
275
|
fromJSON(_) {
|
|
334
|
-
|
|
335
|
-
return message;
|
|
276
|
+
return {};
|
|
336
277
|
},
|
|
337
278
|
toJSON(_) {
|
|
338
279
|
const obj = {};
|
|
339
280
|
return obj;
|
|
340
281
|
},
|
|
341
282
|
fromPartial(_) {
|
|
342
|
-
const message =
|
|
283
|
+
const message = createBaseDeleteRoomResponse();
|
|
343
284
|
return message;
|
|
344
285
|
},
|
|
345
286
|
};
|
|
346
|
-
|
|
287
|
+
function createBaseListParticipantsRequest() {
|
|
288
|
+
return { room: '' };
|
|
289
|
+
}
|
|
347
290
|
exports.ListParticipantsRequest = {
|
|
348
|
-
encode(message, writer =
|
|
349
|
-
if (message.room !==
|
|
291
|
+
encode(message, writer = _m0.Writer.create()) {
|
|
292
|
+
if (message.room !== '') {
|
|
350
293
|
writer.uint32(10).string(message.room);
|
|
351
294
|
}
|
|
352
295
|
return writer;
|
|
353
296
|
},
|
|
354
297
|
decode(input, length) {
|
|
355
|
-
const reader = input instanceof
|
|
298
|
+
const reader = input instanceof _m0.Reader ? input : new _m0.Reader(input);
|
|
356
299
|
let end = length === undefined ? reader.len : reader.pos + length;
|
|
357
|
-
const message =
|
|
300
|
+
const message = createBaseListParticipantsRequest();
|
|
358
301
|
while (reader.pos < end) {
|
|
359
302
|
const tag = reader.uint32();
|
|
360
303
|
switch (tag >>> 3) {
|
|
@@ -369,14 +312,9 @@ exports.ListParticipantsRequest = {
|
|
|
369
312
|
return message;
|
|
370
313
|
},
|
|
371
314
|
fromJSON(object) {
|
|
372
|
-
|
|
373
|
-
|
|
374
|
-
|
|
375
|
-
}
|
|
376
|
-
else {
|
|
377
|
-
message.room = "";
|
|
378
|
-
}
|
|
379
|
-
return message;
|
|
315
|
+
return {
|
|
316
|
+
room: isSet(object.room) ? String(object.room) : '',
|
|
317
|
+
};
|
|
380
318
|
},
|
|
381
319
|
toJSON(message) {
|
|
382
320
|
const obj = {};
|
|
@@ -384,29 +322,26 @@ exports.ListParticipantsRequest = {
|
|
|
384
322
|
return obj;
|
|
385
323
|
},
|
|
386
324
|
fromPartial(object) {
|
|
387
|
-
|
|
388
|
-
|
|
389
|
-
|
|
390
|
-
}
|
|
391
|
-
else {
|
|
392
|
-
message.room = "";
|
|
393
|
-
}
|
|
325
|
+
var _a;
|
|
326
|
+
const message = createBaseListParticipantsRequest();
|
|
327
|
+
message.room = (_a = object.room) !== null && _a !== void 0 ? _a : '';
|
|
394
328
|
return message;
|
|
395
329
|
},
|
|
396
330
|
};
|
|
397
|
-
|
|
331
|
+
function createBaseListParticipantsResponse() {
|
|
332
|
+
return { participants: [] };
|
|
333
|
+
}
|
|
398
334
|
exports.ListParticipantsResponse = {
|
|
399
|
-
encode(message, writer =
|
|
335
|
+
encode(message, writer = _m0.Writer.create()) {
|
|
400
336
|
for (const v of message.participants) {
|
|
401
337
|
livekit_models_1.ParticipantInfo.encode(v, writer.uint32(10).fork()).ldelim();
|
|
402
338
|
}
|
|
403
339
|
return writer;
|
|
404
340
|
},
|
|
405
341
|
decode(input, length) {
|
|
406
|
-
const reader = input instanceof
|
|
342
|
+
const reader = input instanceof _m0.Reader ? input : new _m0.Reader(input);
|
|
407
343
|
let end = length === undefined ? reader.len : reader.pos + length;
|
|
408
|
-
const message =
|
|
409
|
-
message.participants = [];
|
|
344
|
+
const message = createBaseListParticipantsResponse();
|
|
410
345
|
while (reader.pos < end) {
|
|
411
346
|
const tag = reader.uint32();
|
|
412
347
|
switch (tag >>> 3) {
|
|
@@ -421,14 +356,11 @@ exports.ListParticipantsResponse = {
|
|
|
421
356
|
return message;
|
|
422
357
|
},
|
|
423
358
|
fromJSON(object) {
|
|
424
|
-
|
|
425
|
-
|
|
426
|
-
|
|
427
|
-
|
|
428
|
-
|
|
429
|
-
}
|
|
430
|
-
}
|
|
431
|
-
return message;
|
|
359
|
+
return {
|
|
360
|
+
participants: Array.isArray(object === null || object === void 0 ? void 0 : object.participants)
|
|
361
|
+
? object.participants.map((e) => livekit_models_1.ParticipantInfo.fromJSON(e))
|
|
362
|
+
: [],
|
|
363
|
+
};
|
|
432
364
|
},
|
|
433
365
|
toJSON(message) {
|
|
434
366
|
const obj = {};
|
|
@@ -441,31 +373,29 @@ exports.ListParticipantsResponse = {
|
|
|
441
373
|
return obj;
|
|
442
374
|
},
|
|
443
375
|
fromPartial(object) {
|
|
444
|
-
|
|
445
|
-
message
|
|
446
|
-
|
|
447
|
-
for (const e of object.participants) {
|
|
448
|
-
message.participants.push(livekit_models_1.ParticipantInfo.fromPartial(e));
|
|
449
|
-
}
|
|
450
|
-
}
|
|
376
|
+
var _a;
|
|
377
|
+
const message = createBaseListParticipantsResponse();
|
|
378
|
+
message.participants = ((_a = object.participants) === null || _a === void 0 ? void 0 : _a.map((e) => livekit_models_1.ParticipantInfo.fromPartial(e))) || [];
|
|
451
379
|
return message;
|
|
452
380
|
},
|
|
453
381
|
};
|
|
454
|
-
|
|
382
|
+
function createBaseRoomParticipantIdentity() {
|
|
383
|
+
return { room: '', identity: '' };
|
|
384
|
+
}
|
|
455
385
|
exports.RoomParticipantIdentity = {
|
|
456
|
-
encode(message, writer =
|
|
457
|
-
if (message.room !==
|
|
386
|
+
encode(message, writer = _m0.Writer.create()) {
|
|
387
|
+
if (message.room !== '') {
|
|
458
388
|
writer.uint32(10).string(message.room);
|
|
459
389
|
}
|
|
460
|
-
if (message.identity !==
|
|
390
|
+
if (message.identity !== '') {
|
|
461
391
|
writer.uint32(18).string(message.identity);
|
|
462
392
|
}
|
|
463
393
|
return writer;
|
|
464
394
|
},
|
|
465
395
|
decode(input, length) {
|
|
466
|
-
const reader = input instanceof
|
|
396
|
+
const reader = input instanceof _m0.Reader ? input : new _m0.Reader(input);
|
|
467
397
|
let end = length === undefined ? reader.len : reader.pos + length;
|
|
468
|
-
const message =
|
|
398
|
+
const message = createBaseRoomParticipantIdentity();
|
|
469
399
|
while (reader.pos < end) {
|
|
470
400
|
const tag = reader.uint32();
|
|
471
401
|
switch (tag >>> 3) {
|
|
@@ -483,20 +413,10 @@ exports.RoomParticipantIdentity = {
|
|
|
483
413
|
return message;
|
|
484
414
|
},
|
|
485
415
|
fromJSON(object) {
|
|
486
|
-
|
|
487
|
-
|
|
488
|
-
|
|
489
|
-
}
|
|
490
|
-
else {
|
|
491
|
-
message.room = "";
|
|
492
|
-
}
|
|
493
|
-
if (object.identity !== undefined && object.identity !== null) {
|
|
494
|
-
message.identity = String(object.identity);
|
|
495
|
-
}
|
|
496
|
-
else {
|
|
497
|
-
message.identity = "";
|
|
498
|
-
}
|
|
499
|
-
return message;
|
|
416
|
+
return {
|
|
417
|
+
room: isSet(object.room) ? String(object.room) : '',
|
|
418
|
+
identity: isSet(object.identity) ? String(object.identity) : '',
|
|
419
|
+
};
|
|
500
420
|
},
|
|
501
421
|
toJSON(message) {
|
|
502
422
|
const obj = {};
|
|
@@ -505,31 +425,24 @@ exports.RoomParticipantIdentity = {
|
|
|
505
425
|
return obj;
|
|
506
426
|
},
|
|
507
427
|
fromPartial(object) {
|
|
508
|
-
|
|
509
|
-
|
|
510
|
-
|
|
511
|
-
|
|
512
|
-
else {
|
|
513
|
-
message.room = "";
|
|
514
|
-
}
|
|
515
|
-
if (object.identity !== undefined && object.identity !== null) {
|
|
516
|
-
message.identity = object.identity;
|
|
517
|
-
}
|
|
518
|
-
else {
|
|
519
|
-
message.identity = "";
|
|
520
|
-
}
|
|
428
|
+
var _a, _b;
|
|
429
|
+
const message = createBaseRoomParticipantIdentity();
|
|
430
|
+
message.room = (_a = object.room) !== null && _a !== void 0 ? _a : '';
|
|
431
|
+
message.identity = (_b = object.identity) !== null && _b !== void 0 ? _b : '';
|
|
521
432
|
return message;
|
|
522
433
|
},
|
|
523
434
|
};
|
|
524
|
-
|
|
435
|
+
function createBaseRemoveParticipantResponse() {
|
|
436
|
+
return {};
|
|
437
|
+
}
|
|
525
438
|
exports.RemoveParticipantResponse = {
|
|
526
|
-
encode(_, writer =
|
|
439
|
+
encode(_, writer = _m0.Writer.create()) {
|
|
527
440
|
return writer;
|
|
528
441
|
},
|
|
529
442
|
decode(input, length) {
|
|
530
|
-
const reader = input instanceof
|
|
443
|
+
const reader = input instanceof _m0.Reader ? input : new _m0.Reader(input);
|
|
531
444
|
let end = length === undefined ? reader.len : reader.pos + length;
|
|
532
|
-
const message =
|
|
445
|
+
const message = createBaseRemoveParticipantResponse();
|
|
533
446
|
while (reader.pos < end) {
|
|
534
447
|
const tag = reader.uint32();
|
|
535
448
|
switch (tag >>> 3) {
|
|
@@ -541,33 +454,29 @@ exports.RemoveParticipantResponse = {
|
|
|
541
454
|
return message;
|
|
542
455
|
},
|
|
543
456
|
fromJSON(_) {
|
|
544
|
-
|
|
545
|
-
return message;
|
|
457
|
+
return {};
|
|
546
458
|
},
|
|
547
459
|
toJSON(_) {
|
|
548
460
|
const obj = {};
|
|
549
461
|
return obj;
|
|
550
462
|
},
|
|
551
463
|
fromPartial(_) {
|
|
552
|
-
const message =
|
|
464
|
+
const message = createBaseRemoveParticipantResponse();
|
|
553
465
|
return message;
|
|
554
466
|
},
|
|
555
467
|
};
|
|
556
|
-
|
|
557
|
-
room:
|
|
558
|
-
|
|
559
|
-
trackSid: "",
|
|
560
|
-
muted: false,
|
|
561
|
-
};
|
|
468
|
+
function createBaseMuteRoomTrackRequest() {
|
|
469
|
+
return { room: '', identity: '', trackSid: '', muted: false };
|
|
470
|
+
}
|
|
562
471
|
exports.MuteRoomTrackRequest = {
|
|
563
|
-
encode(message, writer =
|
|
564
|
-
if (message.room !==
|
|
472
|
+
encode(message, writer = _m0.Writer.create()) {
|
|
473
|
+
if (message.room !== '') {
|
|
565
474
|
writer.uint32(10).string(message.room);
|
|
566
475
|
}
|
|
567
|
-
if (message.identity !==
|
|
476
|
+
if (message.identity !== '') {
|
|
568
477
|
writer.uint32(18).string(message.identity);
|
|
569
478
|
}
|
|
570
|
-
if (message.trackSid !==
|
|
479
|
+
if (message.trackSid !== '') {
|
|
571
480
|
writer.uint32(26).string(message.trackSid);
|
|
572
481
|
}
|
|
573
482
|
if (message.muted === true) {
|
|
@@ -576,9 +485,9 @@ exports.MuteRoomTrackRequest = {
|
|
|
576
485
|
return writer;
|
|
577
486
|
},
|
|
578
487
|
decode(input, length) {
|
|
579
|
-
const reader = input instanceof
|
|
488
|
+
const reader = input instanceof _m0.Reader ? input : new _m0.Reader(input);
|
|
580
489
|
let end = length === undefined ? reader.len : reader.pos + length;
|
|
581
|
-
const message =
|
|
490
|
+
const message = createBaseMuteRoomTrackRequest();
|
|
582
491
|
while (reader.pos < end) {
|
|
583
492
|
const tag = reader.uint32();
|
|
584
493
|
switch (tag >>> 3) {
|
|
@@ -602,32 +511,12 @@ exports.MuteRoomTrackRequest = {
|
|
|
602
511
|
return message;
|
|
603
512
|
},
|
|
604
513
|
fromJSON(object) {
|
|
605
|
-
|
|
606
|
-
|
|
607
|
-
|
|
608
|
-
|
|
609
|
-
|
|
610
|
-
|
|
611
|
-
}
|
|
612
|
-
if (object.identity !== undefined && object.identity !== null) {
|
|
613
|
-
message.identity = String(object.identity);
|
|
614
|
-
}
|
|
615
|
-
else {
|
|
616
|
-
message.identity = "";
|
|
617
|
-
}
|
|
618
|
-
if (object.trackSid !== undefined && object.trackSid !== null) {
|
|
619
|
-
message.trackSid = String(object.trackSid);
|
|
620
|
-
}
|
|
621
|
-
else {
|
|
622
|
-
message.trackSid = "";
|
|
623
|
-
}
|
|
624
|
-
if (object.muted !== undefined && object.muted !== null) {
|
|
625
|
-
message.muted = Boolean(object.muted);
|
|
626
|
-
}
|
|
627
|
-
else {
|
|
628
|
-
message.muted = false;
|
|
629
|
-
}
|
|
630
|
-
return message;
|
|
514
|
+
return {
|
|
515
|
+
room: isSet(object.room) ? String(object.room) : '',
|
|
516
|
+
identity: isSet(object.identity) ? String(object.identity) : '',
|
|
517
|
+
trackSid: isSet(object.trackSid) ? String(object.trackSid) : '',
|
|
518
|
+
muted: isSet(object.muted) ? Boolean(object.muted) : false,
|
|
519
|
+
};
|
|
631
520
|
},
|
|
632
521
|
toJSON(message) {
|
|
633
522
|
const obj = {};
|
|
@@ -638,46 +527,29 @@ exports.MuteRoomTrackRequest = {
|
|
|
638
527
|
return obj;
|
|
639
528
|
},
|
|
640
529
|
fromPartial(object) {
|
|
641
|
-
|
|
642
|
-
|
|
643
|
-
|
|
644
|
-
|
|
645
|
-
|
|
646
|
-
|
|
647
|
-
}
|
|
648
|
-
if (object.identity !== undefined && object.identity !== null) {
|
|
649
|
-
message.identity = object.identity;
|
|
650
|
-
}
|
|
651
|
-
else {
|
|
652
|
-
message.identity = "";
|
|
653
|
-
}
|
|
654
|
-
if (object.trackSid !== undefined && object.trackSid !== null) {
|
|
655
|
-
message.trackSid = object.trackSid;
|
|
656
|
-
}
|
|
657
|
-
else {
|
|
658
|
-
message.trackSid = "";
|
|
659
|
-
}
|
|
660
|
-
if (object.muted !== undefined && object.muted !== null) {
|
|
661
|
-
message.muted = object.muted;
|
|
662
|
-
}
|
|
663
|
-
else {
|
|
664
|
-
message.muted = false;
|
|
665
|
-
}
|
|
530
|
+
var _a, _b, _c, _d;
|
|
531
|
+
const message = createBaseMuteRoomTrackRequest();
|
|
532
|
+
message.room = (_a = object.room) !== null && _a !== void 0 ? _a : '';
|
|
533
|
+
message.identity = (_b = object.identity) !== null && _b !== void 0 ? _b : '';
|
|
534
|
+
message.trackSid = (_c = object.trackSid) !== null && _c !== void 0 ? _c : '';
|
|
535
|
+
message.muted = (_d = object.muted) !== null && _d !== void 0 ? _d : false;
|
|
666
536
|
return message;
|
|
667
537
|
},
|
|
668
538
|
};
|
|
669
|
-
|
|
539
|
+
function createBaseMuteRoomTrackResponse() {
|
|
540
|
+
return { track: undefined };
|
|
541
|
+
}
|
|
670
542
|
exports.MuteRoomTrackResponse = {
|
|
671
|
-
encode(message, writer =
|
|
543
|
+
encode(message, writer = _m0.Writer.create()) {
|
|
672
544
|
if (message.track !== undefined) {
|
|
673
545
|
livekit_models_1.TrackInfo.encode(message.track, writer.uint32(10).fork()).ldelim();
|
|
674
546
|
}
|
|
675
547
|
return writer;
|
|
676
548
|
},
|
|
677
549
|
decode(input, length) {
|
|
678
|
-
const reader = input instanceof
|
|
550
|
+
const reader = input instanceof _m0.Reader ? input : new _m0.Reader(input);
|
|
679
551
|
let end = length === undefined ? reader.len : reader.pos + length;
|
|
680
|
-
const message =
|
|
552
|
+
const message = createBaseMuteRoomTrackResponse();
|
|
681
553
|
while (reader.pos < end) {
|
|
682
554
|
const tag = reader.uint32();
|
|
683
555
|
switch (tag >>> 3) {
|
|
@@ -692,14 +564,9 @@ exports.MuteRoomTrackResponse = {
|
|
|
692
564
|
return message;
|
|
693
565
|
},
|
|
694
566
|
fromJSON(object) {
|
|
695
|
-
|
|
696
|
-
|
|
697
|
-
|
|
698
|
-
}
|
|
699
|
-
else {
|
|
700
|
-
message.track = undefined;
|
|
701
|
-
}
|
|
702
|
-
return message;
|
|
567
|
+
return {
|
|
568
|
+
track: isSet(object.track) ? livekit_models_1.TrackInfo.fromJSON(object.track) : undefined,
|
|
569
|
+
};
|
|
703
570
|
},
|
|
704
571
|
toJSON(message) {
|
|
705
572
|
const obj = {};
|
|
@@ -708,136 +575,37 @@ exports.MuteRoomTrackResponse = {
|
|
|
708
575
|
return obj;
|
|
709
576
|
},
|
|
710
577
|
fromPartial(object) {
|
|
711
|
-
const message =
|
|
712
|
-
|
|
713
|
-
|
|
714
|
-
|
|
715
|
-
|
|
716
|
-
message.track = undefined;
|
|
717
|
-
}
|
|
578
|
+
const message = createBaseMuteRoomTrackResponse();
|
|
579
|
+
message.track =
|
|
580
|
+
object.track !== undefined && object.track !== null
|
|
581
|
+
? livekit_models_1.TrackInfo.fromPartial(object.track)
|
|
582
|
+
: undefined;
|
|
718
583
|
return message;
|
|
719
584
|
},
|
|
720
585
|
};
|
|
721
|
-
|
|
722
|
-
|
|
723
|
-
|
|
724
|
-
canPublishData: false,
|
|
725
|
-
};
|
|
726
|
-
exports.ParticipantPermission = {
|
|
727
|
-
encode(message, writer = minimal_1.default.Writer.create()) {
|
|
728
|
-
if (message.canSubscribe === true) {
|
|
729
|
-
writer.uint32(8).bool(message.canSubscribe);
|
|
730
|
-
}
|
|
731
|
-
if (message.canPublish === true) {
|
|
732
|
-
writer.uint32(16).bool(message.canPublish);
|
|
733
|
-
}
|
|
734
|
-
if (message.canPublishData === true) {
|
|
735
|
-
writer.uint32(24).bool(message.canPublishData);
|
|
736
|
-
}
|
|
737
|
-
return writer;
|
|
738
|
-
},
|
|
739
|
-
decode(input, length) {
|
|
740
|
-
const reader = input instanceof minimal_1.default.Reader ? input : new minimal_1.default.Reader(input);
|
|
741
|
-
let end = length === undefined ? reader.len : reader.pos + length;
|
|
742
|
-
const message = Object.assign({}, baseParticipantPermission);
|
|
743
|
-
while (reader.pos < end) {
|
|
744
|
-
const tag = reader.uint32();
|
|
745
|
-
switch (tag >>> 3) {
|
|
746
|
-
case 1:
|
|
747
|
-
message.canSubscribe = reader.bool();
|
|
748
|
-
break;
|
|
749
|
-
case 2:
|
|
750
|
-
message.canPublish = reader.bool();
|
|
751
|
-
break;
|
|
752
|
-
case 3:
|
|
753
|
-
message.canPublishData = reader.bool();
|
|
754
|
-
break;
|
|
755
|
-
default:
|
|
756
|
-
reader.skipType(tag & 7);
|
|
757
|
-
break;
|
|
758
|
-
}
|
|
759
|
-
}
|
|
760
|
-
return message;
|
|
761
|
-
},
|
|
762
|
-
fromJSON(object) {
|
|
763
|
-
const message = Object.assign({}, baseParticipantPermission);
|
|
764
|
-
if (object.canSubscribe !== undefined && object.canSubscribe !== null) {
|
|
765
|
-
message.canSubscribe = Boolean(object.canSubscribe);
|
|
766
|
-
}
|
|
767
|
-
else {
|
|
768
|
-
message.canSubscribe = false;
|
|
769
|
-
}
|
|
770
|
-
if (object.canPublish !== undefined && object.canPublish !== null) {
|
|
771
|
-
message.canPublish = Boolean(object.canPublish);
|
|
772
|
-
}
|
|
773
|
-
else {
|
|
774
|
-
message.canPublish = false;
|
|
775
|
-
}
|
|
776
|
-
if (object.canPublishData !== undefined && object.canPublishData !== null) {
|
|
777
|
-
message.canPublishData = Boolean(object.canPublishData);
|
|
778
|
-
}
|
|
779
|
-
else {
|
|
780
|
-
message.canPublishData = false;
|
|
781
|
-
}
|
|
782
|
-
return message;
|
|
783
|
-
},
|
|
784
|
-
toJSON(message) {
|
|
785
|
-
const obj = {};
|
|
786
|
-
message.canSubscribe !== undefined &&
|
|
787
|
-
(obj.canSubscribe = message.canSubscribe);
|
|
788
|
-
message.canPublish !== undefined && (obj.canPublish = message.canPublish);
|
|
789
|
-
message.canPublishData !== undefined &&
|
|
790
|
-
(obj.canPublishData = message.canPublishData);
|
|
791
|
-
return obj;
|
|
792
|
-
},
|
|
793
|
-
fromPartial(object) {
|
|
794
|
-
const message = Object.assign({}, baseParticipantPermission);
|
|
795
|
-
if (object.canSubscribe !== undefined && object.canSubscribe !== null) {
|
|
796
|
-
message.canSubscribe = object.canSubscribe;
|
|
797
|
-
}
|
|
798
|
-
else {
|
|
799
|
-
message.canSubscribe = false;
|
|
800
|
-
}
|
|
801
|
-
if (object.canPublish !== undefined && object.canPublish !== null) {
|
|
802
|
-
message.canPublish = object.canPublish;
|
|
803
|
-
}
|
|
804
|
-
else {
|
|
805
|
-
message.canPublish = false;
|
|
806
|
-
}
|
|
807
|
-
if (object.canPublishData !== undefined && object.canPublishData !== null) {
|
|
808
|
-
message.canPublishData = object.canPublishData;
|
|
809
|
-
}
|
|
810
|
-
else {
|
|
811
|
-
message.canPublishData = false;
|
|
812
|
-
}
|
|
813
|
-
return message;
|
|
814
|
-
},
|
|
815
|
-
};
|
|
816
|
-
const baseUpdateParticipantRequest = {
|
|
817
|
-
room: "",
|
|
818
|
-
identity: "",
|
|
819
|
-
metadata: "",
|
|
820
|
-
};
|
|
586
|
+
function createBaseUpdateParticipantRequest() {
|
|
587
|
+
return { room: '', identity: '', metadata: '', permission: undefined };
|
|
588
|
+
}
|
|
821
589
|
exports.UpdateParticipantRequest = {
|
|
822
|
-
encode(message, writer =
|
|
823
|
-
if (message.room !==
|
|
590
|
+
encode(message, writer = _m0.Writer.create()) {
|
|
591
|
+
if (message.room !== '') {
|
|
824
592
|
writer.uint32(10).string(message.room);
|
|
825
593
|
}
|
|
826
|
-
if (message.identity !==
|
|
594
|
+
if (message.identity !== '') {
|
|
827
595
|
writer.uint32(18).string(message.identity);
|
|
828
596
|
}
|
|
829
|
-
if (message.metadata !==
|
|
597
|
+
if (message.metadata !== '') {
|
|
830
598
|
writer.uint32(26).string(message.metadata);
|
|
831
599
|
}
|
|
832
600
|
if (message.permission !== undefined) {
|
|
833
|
-
|
|
601
|
+
livekit_models_1.ParticipantPermission.encode(message.permission, writer.uint32(34).fork()).ldelim();
|
|
834
602
|
}
|
|
835
603
|
return writer;
|
|
836
604
|
},
|
|
837
605
|
decode(input, length) {
|
|
838
|
-
const reader = input instanceof
|
|
606
|
+
const reader = input instanceof _m0.Reader ? input : new _m0.Reader(input);
|
|
839
607
|
let end = length === undefined ? reader.len : reader.pos + length;
|
|
840
|
-
const message =
|
|
608
|
+
const message = createBaseUpdateParticipantRequest();
|
|
841
609
|
while (reader.pos < end) {
|
|
842
610
|
const tag = reader.uint32();
|
|
843
611
|
switch (tag >>> 3) {
|
|
@@ -851,7 +619,7 @@ exports.UpdateParticipantRequest = {
|
|
|
851
619
|
message.metadata = reader.string();
|
|
852
620
|
break;
|
|
853
621
|
case 4:
|
|
854
|
-
message.permission =
|
|
622
|
+
message.permission = livekit_models_1.ParticipantPermission.decode(reader, reader.uint32());
|
|
855
623
|
break;
|
|
856
624
|
default:
|
|
857
625
|
reader.skipType(tag & 7);
|
|
@@ -861,32 +629,14 @@ exports.UpdateParticipantRequest = {
|
|
|
861
629
|
return message;
|
|
862
630
|
},
|
|
863
631
|
fromJSON(object) {
|
|
864
|
-
|
|
865
|
-
|
|
866
|
-
|
|
867
|
-
|
|
868
|
-
|
|
869
|
-
|
|
870
|
-
|
|
871
|
-
|
|
872
|
-
message.identity = String(object.identity);
|
|
873
|
-
}
|
|
874
|
-
else {
|
|
875
|
-
message.identity = "";
|
|
876
|
-
}
|
|
877
|
-
if (object.metadata !== undefined && object.metadata !== null) {
|
|
878
|
-
message.metadata = String(object.metadata);
|
|
879
|
-
}
|
|
880
|
-
else {
|
|
881
|
-
message.metadata = "";
|
|
882
|
-
}
|
|
883
|
-
if (object.permission !== undefined && object.permission !== null) {
|
|
884
|
-
message.permission = exports.ParticipantPermission.fromJSON(object.permission);
|
|
885
|
-
}
|
|
886
|
-
else {
|
|
887
|
-
message.permission = undefined;
|
|
888
|
-
}
|
|
889
|
-
return message;
|
|
632
|
+
return {
|
|
633
|
+
room: isSet(object.room) ? String(object.room) : '',
|
|
634
|
+
identity: isSet(object.identity) ? String(object.identity) : '',
|
|
635
|
+
metadata: isSet(object.metadata) ? String(object.metadata) : '',
|
|
636
|
+
permission: isSet(object.permission)
|
|
637
|
+
? livekit_models_1.ParticipantPermission.fromJSON(object.permission)
|
|
638
|
+
: undefined,
|
|
639
|
+
};
|
|
890
640
|
},
|
|
891
641
|
toJSON(message) {
|
|
892
642
|
const obj = {};
|
|
@@ -895,51 +645,32 @@ exports.UpdateParticipantRequest = {
|
|
|
895
645
|
message.metadata !== undefined && (obj.metadata = message.metadata);
|
|
896
646
|
message.permission !== undefined &&
|
|
897
647
|
(obj.permission = message.permission
|
|
898
|
-
?
|
|
648
|
+
? livekit_models_1.ParticipantPermission.toJSON(message.permission)
|
|
899
649
|
: undefined);
|
|
900
650
|
return obj;
|
|
901
651
|
},
|
|
902
652
|
fromPartial(object) {
|
|
903
|
-
|
|
904
|
-
|
|
905
|
-
|
|
906
|
-
|
|
907
|
-
|
|
908
|
-
|
|
909
|
-
|
|
910
|
-
|
|
911
|
-
|
|
912
|
-
}
|
|
913
|
-
else {
|
|
914
|
-
message.identity = "";
|
|
915
|
-
}
|
|
916
|
-
if (object.metadata !== undefined && object.metadata !== null) {
|
|
917
|
-
message.metadata = object.metadata;
|
|
918
|
-
}
|
|
919
|
-
else {
|
|
920
|
-
message.metadata = "";
|
|
921
|
-
}
|
|
922
|
-
if (object.permission !== undefined && object.permission !== null) {
|
|
923
|
-
message.permission = exports.ParticipantPermission.fromPartial(object.permission);
|
|
924
|
-
}
|
|
925
|
-
else {
|
|
926
|
-
message.permission = undefined;
|
|
927
|
-
}
|
|
653
|
+
var _a, _b, _c;
|
|
654
|
+
const message = createBaseUpdateParticipantRequest();
|
|
655
|
+
message.room = (_a = object.room) !== null && _a !== void 0 ? _a : '';
|
|
656
|
+
message.identity = (_b = object.identity) !== null && _b !== void 0 ? _b : '';
|
|
657
|
+
message.metadata = (_c = object.metadata) !== null && _c !== void 0 ? _c : '';
|
|
658
|
+
message.permission =
|
|
659
|
+
object.permission !== undefined && object.permission !== null
|
|
660
|
+
? livekit_models_1.ParticipantPermission.fromPartial(object.permission)
|
|
661
|
+
: undefined;
|
|
928
662
|
return message;
|
|
929
663
|
},
|
|
930
664
|
};
|
|
931
|
-
|
|
932
|
-
room:
|
|
933
|
-
|
|
934
|
-
trackSids: "",
|
|
935
|
-
subscribe: false,
|
|
936
|
-
};
|
|
665
|
+
function createBaseUpdateSubscriptionsRequest() {
|
|
666
|
+
return { room: '', identity: '', trackSids: [], subscribe: false, participantTracks: [] };
|
|
667
|
+
}
|
|
937
668
|
exports.UpdateSubscriptionsRequest = {
|
|
938
|
-
encode(message, writer =
|
|
939
|
-
if (message.room !==
|
|
669
|
+
encode(message, writer = _m0.Writer.create()) {
|
|
670
|
+
if (message.room !== '') {
|
|
940
671
|
writer.uint32(10).string(message.room);
|
|
941
672
|
}
|
|
942
|
-
if (message.identity !==
|
|
673
|
+
if (message.identity !== '') {
|
|
943
674
|
writer.uint32(18).string(message.identity);
|
|
944
675
|
}
|
|
945
676
|
for (const v of message.trackSids) {
|
|
@@ -954,11 +685,9 @@ exports.UpdateSubscriptionsRequest = {
|
|
|
954
685
|
return writer;
|
|
955
686
|
},
|
|
956
687
|
decode(input, length) {
|
|
957
|
-
const reader = input instanceof
|
|
688
|
+
const reader = input instanceof _m0.Reader ? input : new _m0.Reader(input);
|
|
958
689
|
let end = length === undefined ? reader.len : reader.pos + length;
|
|
959
|
-
const message =
|
|
960
|
-
message.trackSids = [];
|
|
961
|
-
message.participantTracks = [];
|
|
690
|
+
const message = createBaseUpdateSubscriptionsRequest();
|
|
962
691
|
while (reader.pos < end) {
|
|
963
692
|
const tag = reader.uint32();
|
|
964
693
|
switch (tag >>> 3) {
|
|
@@ -985,39 +714,17 @@ exports.UpdateSubscriptionsRequest = {
|
|
|
985
714
|
return message;
|
|
986
715
|
},
|
|
987
716
|
fromJSON(object) {
|
|
988
|
-
|
|
989
|
-
|
|
990
|
-
|
|
991
|
-
|
|
992
|
-
|
|
993
|
-
|
|
994
|
-
|
|
995
|
-
|
|
996
|
-
|
|
997
|
-
|
|
998
|
-
|
|
999
|
-
}
|
|
1000
|
-
else {
|
|
1001
|
-
message.identity = "";
|
|
1002
|
-
}
|
|
1003
|
-
if (object.trackSids !== undefined && object.trackSids !== null) {
|
|
1004
|
-
for (const e of object.trackSids) {
|
|
1005
|
-
message.trackSids.push(String(e));
|
|
1006
|
-
}
|
|
1007
|
-
}
|
|
1008
|
-
if (object.subscribe !== undefined && object.subscribe !== null) {
|
|
1009
|
-
message.subscribe = Boolean(object.subscribe);
|
|
1010
|
-
}
|
|
1011
|
-
else {
|
|
1012
|
-
message.subscribe = false;
|
|
1013
|
-
}
|
|
1014
|
-
if (object.participantTracks !== undefined &&
|
|
1015
|
-
object.participantTracks !== null) {
|
|
1016
|
-
for (const e of object.participantTracks) {
|
|
1017
|
-
message.participantTracks.push(livekit_models_1.ParticipantTracks.fromJSON(e));
|
|
1018
|
-
}
|
|
1019
|
-
}
|
|
1020
|
-
return message;
|
|
717
|
+
return {
|
|
718
|
+
room: isSet(object.room) ? String(object.room) : '',
|
|
719
|
+
identity: isSet(object.identity) ? String(object.identity) : '',
|
|
720
|
+
trackSids: Array.isArray(object === null || object === void 0 ? void 0 : object.trackSids)
|
|
721
|
+
? object.trackSids.map((e) => String(e))
|
|
722
|
+
: [],
|
|
723
|
+
subscribe: isSet(object.subscribe) ? Boolean(object.subscribe) : false,
|
|
724
|
+
participantTracks: Array.isArray(object === null || object === void 0 ? void 0 : object.participantTracks)
|
|
725
|
+
? object.participantTracks.map((e) => livekit_models_1.ParticipantTracks.fromJSON(e))
|
|
726
|
+
: [],
|
|
727
|
+
};
|
|
1021
728
|
},
|
|
1022
729
|
toJSON(message) {
|
|
1023
730
|
const obj = {};
|
|
@@ -1039,50 +746,28 @@ exports.UpdateSubscriptionsRequest = {
|
|
|
1039
746
|
return obj;
|
|
1040
747
|
},
|
|
1041
748
|
fromPartial(object) {
|
|
1042
|
-
|
|
1043
|
-
message
|
|
1044
|
-
message.
|
|
1045
|
-
|
|
1046
|
-
|
|
1047
|
-
|
|
1048
|
-
|
|
1049
|
-
|
|
1050
|
-
}
|
|
1051
|
-
if (object.identity !== undefined && object.identity !== null) {
|
|
1052
|
-
message.identity = object.identity;
|
|
1053
|
-
}
|
|
1054
|
-
else {
|
|
1055
|
-
message.identity = "";
|
|
1056
|
-
}
|
|
1057
|
-
if (object.trackSids !== undefined && object.trackSids !== null) {
|
|
1058
|
-
for (const e of object.trackSids) {
|
|
1059
|
-
message.trackSids.push(e);
|
|
1060
|
-
}
|
|
1061
|
-
}
|
|
1062
|
-
if (object.subscribe !== undefined && object.subscribe !== null) {
|
|
1063
|
-
message.subscribe = object.subscribe;
|
|
1064
|
-
}
|
|
1065
|
-
else {
|
|
1066
|
-
message.subscribe = false;
|
|
1067
|
-
}
|
|
1068
|
-
if (object.participantTracks !== undefined &&
|
|
1069
|
-
object.participantTracks !== null) {
|
|
1070
|
-
for (const e of object.participantTracks) {
|
|
1071
|
-
message.participantTracks.push(livekit_models_1.ParticipantTracks.fromPartial(e));
|
|
1072
|
-
}
|
|
1073
|
-
}
|
|
749
|
+
var _a, _b, _c, _d, _e;
|
|
750
|
+
const message = createBaseUpdateSubscriptionsRequest();
|
|
751
|
+
message.room = (_a = object.room) !== null && _a !== void 0 ? _a : '';
|
|
752
|
+
message.identity = (_b = object.identity) !== null && _b !== void 0 ? _b : '';
|
|
753
|
+
message.trackSids = ((_c = object.trackSids) === null || _c === void 0 ? void 0 : _c.map((e) => e)) || [];
|
|
754
|
+
message.subscribe = (_d = object.subscribe) !== null && _d !== void 0 ? _d : false;
|
|
755
|
+
message.participantTracks =
|
|
756
|
+
((_e = object.participantTracks) === null || _e === void 0 ? void 0 : _e.map((e) => livekit_models_1.ParticipantTracks.fromPartial(e))) || [];
|
|
1074
757
|
return message;
|
|
1075
758
|
},
|
|
1076
759
|
};
|
|
1077
|
-
|
|
760
|
+
function createBaseUpdateSubscriptionsResponse() {
|
|
761
|
+
return {};
|
|
762
|
+
}
|
|
1078
763
|
exports.UpdateSubscriptionsResponse = {
|
|
1079
|
-
encode(_, writer =
|
|
764
|
+
encode(_, writer = _m0.Writer.create()) {
|
|
1080
765
|
return writer;
|
|
1081
766
|
},
|
|
1082
767
|
decode(input, length) {
|
|
1083
|
-
const reader = input instanceof
|
|
768
|
+
const reader = input instanceof _m0.Reader ? input : new _m0.Reader(input);
|
|
1084
769
|
let end = length === undefined ? reader.len : reader.pos + length;
|
|
1085
|
-
const message =
|
|
770
|
+
const message = createBaseUpdateSubscriptionsResponse();
|
|
1086
771
|
while (reader.pos < end) {
|
|
1087
772
|
const tag = reader.uint32();
|
|
1088
773
|
switch (tag >>> 3) {
|
|
@@ -1094,22 +779,23 @@ exports.UpdateSubscriptionsResponse = {
|
|
|
1094
779
|
return message;
|
|
1095
780
|
},
|
|
1096
781
|
fromJSON(_) {
|
|
1097
|
-
|
|
1098
|
-
return message;
|
|
782
|
+
return {};
|
|
1099
783
|
},
|
|
1100
784
|
toJSON(_) {
|
|
1101
785
|
const obj = {};
|
|
1102
786
|
return obj;
|
|
1103
787
|
},
|
|
1104
788
|
fromPartial(_) {
|
|
1105
|
-
const message =
|
|
789
|
+
const message = createBaseUpdateSubscriptionsResponse();
|
|
1106
790
|
return message;
|
|
1107
791
|
},
|
|
1108
792
|
};
|
|
1109
|
-
|
|
793
|
+
function createBaseSendDataRequest() {
|
|
794
|
+
return { room: '', data: new Uint8Array(), kind: 0, destinationSids: [] };
|
|
795
|
+
}
|
|
1110
796
|
exports.SendDataRequest = {
|
|
1111
|
-
encode(message, writer =
|
|
1112
|
-
if (message.room !==
|
|
797
|
+
encode(message, writer = _m0.Writer.create()) {
|
|
798
|
+
if (message.room !== '') {
|
|
1113
799
|
writer.uint32(10).string(message.room);
|
|
1114
800
|
}
|
|
1115
801
|
if (message.data.length !== 0) {
|
|
@@ -1124,11 +810,9 @@ exports.SendDataRequest = {
|
|
|
1124
810
|
return writer;
|
|
1125
811
|
},
|
|
1126
812
|
decode(input, length) {
|
|
1127
|
-
const reader = input instanceof
|
|
813
|
+
const reader = input instanceof _m0.Reader ? input : new _m0.Reader(input);
|
|
1128
814
|
let end = length === undefined ? reader.len : reader.pos + length;
|
|
1129
|
-
const message =
|
|
1130
|
-
message.destinationSids = [];
|
|
1131
|
-
message.data = new Uint8Array();
|
|
815
|
+
const message = createBaseSendDataRequest();
|
|
1132
816
|
while (reader.pos < end) {
|
|
1133
817
|
const tag = reader.uint32();
|
|
1134
818
|
switch (tag >>> 3) {
|
|
@@ -1152,39 +836,21 @@ exports.SendDataRequest = {
|
|
|
1152
836
|
return message;
|
|
1153
837
|
},
|
|
1154
838
|
fromJSON(object) {
|
|
1155
|
-
|
|
1156
|
-
|
|
1157
|
-
|
|
1158
|
-
|
|
1159
|
-
|
|
1160
|
-
|
|
1161
|
-
|
|
1162
|
-
|
|
1163
|
-
}
|
|
1164
|
-
if (object.data !== undefined && object.data !== null) {
|
|
1165
|
-
message.data = bytesFromBase64(object.data);
|
|
1166
|
-
}
|
|
1167
|
-
if (object.kind !== undefined && object.kind !== null) {
|
|
1168
|
-
message.kind = livekit_models_1.dataPacket_KindFromJSON(object.kind);
|
|
1169
|
-
}
|
|
1170
|
-
else {
|
|
1171
|
-
message.kind = 0;
|
|
1172
|
-
}
|
|
1173
|
-
if (object.destinationSids !== undefined &&
|
|
1174
|
-
object.destinationSids !== null) {
|
|
1175
|
-
for (const e of object.destinationSids) {
|
|
1176
|
-
message.destinationSids.push(String(e));
|
|
1177
|
-
}
|
|
1178
|
-
}
|
|
1179
|
-
return message;
|
|
839
|
+
return {
|
|
840
|
+
room: isSet(object.room) ? String(object.room) : '',
|
|
841
|
+
data: isSet(object.data) ? bytesFromBase64(object.data) : new Uint8Array(),
|
|
842
|
+
kind: isSet(object.kind) ? livekit_models_1.dataPacket_KindFromJSON(object.kind) : 0,
|
|
843
|
+
destinationSids: Array.isArray(object === null || object === void 0 ? void 0 : object.destinationSids)
|
|
844
|
+
? object.destinationSids.map((e) => String(e))
|
|
845
|
+
: [],
|
|
846
|
+
};
|
|
1180
847
|
},
|
|
1181
848
|
toJSON(message) {
|
|
1182
849
|
const obj = {};
|
|
1183
850
|
message.room !== undefined && (obj.room = message.room);
|
|
1184
851
|
message.data !== undefined &&
|
|
1185
852
|
(obj.data = base64FromBytes(message.data !== undefined ? message.data : new Uint8Array()));
|
|
1186
|
-
message.kind !== undefined &&
|
|
1187
|
-
(obj.kind = livekit_models_1.dataPacket_KindToJSON(message.kind));
|
|
853
|
+
message.kind !== undefined && (obj.kind = livekit_models_1.dataPacket_KindToJSON(message.kind));
|
|
1188
854
|
if (message.destinationSids) {
|
|
1189
855
|
obj.destinationSids = message.destinationSids.map((e) => e);
|
|
1190
856
|
}
|
|
@@ -1194,44 +860,26 @@ exports.SendDataRequest = {
|
|
|
1194
860
|
return obj;
|
|
1195
861
|
},
|
|
1196
862
|
fromPartial(object) {
|
|
1197
|
-
|
|
1198
|
-
message
|
|
1199
|
-
|
|
1200
|
-
|
|
1201
|
-
|
|
1202
|
-
|
|
1203
|
-
message.room = "";
|
|
1204
|
-
}
|
|
1205
|
-
if (object.data !== undefined && object.data !== null) {
|
|
1206
|
-
message.data = object.data;
|
|
1207
|
-
}
|
|
1208
|
-
else {
|
|
1209
|
-
message.data = new Uint8Array();
|
|
1210
|
-
}
|
|
1211
|
-
if (object.kind !== undefined && object.kind !== null) {
|
|
1212
|
-
message.kind = object.kind;
|
|
1213
|
-
}
|
|
1214
|
-
else {
|
|
1215
|
-
message.kind = 0;
|
|
1216
|
-
}
|
|
1217
|
-
if (object.destinationSids !== undefined &&
|
|
1218
|
-
object.destinationSids !== null) {
|
|
1219
|
-
for (const e of object.destinationSids) {
|
|
1220
|
-
message.destinationSids.push(e);
|
|
1221
|
-
}
|
|
1222
|
-
}
|
|
863
|
+
var _a, _b, _c, _d;
|
|
864
|
+
const message = createBaseSendDataRequest();
|
|
865
|
+
message.room = (_a = object.room) !== null && _a !== void 0 ? _a : '';
|
|
866
|
+
message.data = (_b = object.data) !== null && _b !== void 0 ? _b : new Uint8Array();
|
|
867
|
+
message.kind = (_c = object.kind) !== null && _c !== void 0 ? _c : 0;
|
|
868
|
+
message.destinationSids = ((_d = object.destinationSids) === null || _d === void 0 ? void 0 : _d.map((e) => e)) || [];
|
|
1223
869
|
return message;
|
|
1224
870
|
},
|
|
1225
871
|
};
|
|
1226
|
-
|
|
872
|
+
function createBaseSendDataResponse() {
|
|
873
|
+
return {};
|
|
874
|
+
}
|
|
1227
875
|
exports.SendDataResponse = {
|
|
1228
|
-
encode(_, writer =
|
|
876
|
+
encode(_, writer = _m0.Writer.create()) {
|
|
1229
877
|
return writer;
|
|
1230
878
|
},
|
|
1231
879
|
decode(input, length) {
|
|
1232
|
-
const reader = input instanceof
|
|
880
|
+
const reader = input instanceof _m0.Reader ? input : new _m0.Reader(input);
|
|
1233
881
|
let end = length === undefined ? reader.len : reader.pos + length;
|
|
1234
|
-
const message =
|
|
882
|
+
const message = createBaseSendDataResponse();
|
|
1235
883
|
while (reader.pos < end) {
|
|
1236
884
|
const tag = reader.uint32();
|
|
1237
885
|
switch (tag >>> 3) {
|
|
@@ -1243,33 +891,34 @@ exports.SendDataResponse = {
|
|
|
1243
891
|
return message;
|
|
1244
892
|
},
|
|
1245
893
|
fromJSON(_) {
|
|
1246
|
-
|
|
1247
|
-
return message;
|
|
894
|
+
return {};
|
|
1248
895
|
},
|
|
1249
896
|
toJSON(_) {
|
|
1250
897
|
const obj = {};
|
|
1251
898
|
return obj;
|
|
1252
899
|
},
|
|
1253
900
|
fromPartial(_) {
|
|
1254
|
-
const message =
|
|
901
|
+
const message = createBaseSendDataResponse();
|
|
1255
902
|
return message;
|
|
1256
903
|
},
|
|
1257
904
|
};
|
|
1258
|
-
|
|
905
|
+
function createBaseUpdateRoomMetadataRequest() {
|
|
906
|
+
return { room: '', metadata: '' };
|
|
907
|
+
}
|
|
1259
908
|
exports.UpdateRoomMetadataRequest = {
|
|
1260
|
-
encode(message, writer =
|
|
1261
|
-
if (message.room !==
|
|
909
|
+
encode(message, writer = _m0.Writer.create()) {
|
|
910
|
+
if (message.room !== '') {
|
|
1262
911
|
writer.uint32(10).string(message.room);
|
|
1263
912
|
}
|
|
1264
|
-
if (message.metadata !==
|
|
913
|
+
if (message.metadata !== '') {
|
|
1265
914
|
writer.uint32(18).string(message.metadata);
|
|
1266
915
|
}
|
|
1267
916
|
return writer;
|
|
1268
917
|
},
|
|
1269
918
|
decode(input, length) {
|
|
1270
|
-
const reader = input instanceof
|
|
919
|
+
const reader = input instanceof _m0.Reader ? input : new _m0.Reader(input);
|
|
1271
920
|
let end = length === undefined ? reader.len : reader.pos + length;
|
|
1272
|
-
const message =
|
|
921
|
+
const message = createBaseUpdateRoomMetadataRequest();
|
|
1273
922
|
while (reader.pos < end) {
|
|
1274
923
|
const tag = reader.uint32();
|
|
1275
924
|
switch (tag >>> 3) {
|
|
@@ -1287,20 +936,10 @@ exports.UpdateRoomMetadataRequest = {
|
|
|
1287
936
|
return message;
|
|
1288
937
|
},
|
|
1289
938
|
fromJSON(object) {
|
|
1290
|
-
|
|
1291
|
-
|
|
1292
|
-
|
|
1293
|
-
}
|
|
1294
|
-
else {
|
|
1295
|
-
message.room = "";
|
|
1296
|
-
}
|
|
1297
|
-
if (object.metadata !== undefined && object.metadata !== null) {
|
|
1298
|
-
message.metadata = String(object.metadata);
|
|
1299
|
-
}
|
|
1300
|
-
else {
|
|
1301
|
-
message.metadata = "";
|
|
1302
|
-
}
|
|
1303
|
-
return message;
|
|
939
|
+
return {
|
|
940
|
+
room: isSet(object.room) ? String(object.room) : '',
|
|
941
|
+
metadata: isSet(object.metadata) ? String(object.metadata) : '',
|
|
942
|
+
};
|
|
1304
943
|
},
|
|
1305
944
|
toJSON(message) {
|
|
1306
945
|
const obj = {};
|
|
@@ -1309,35 +948,25 @@ exports.UpdateRoomMetadataRequest = {
|
|
|
1309
948
|
return obj;
|
|
1310
949
|
},
|
|
1311
950
|
fromPartial(object) {
|
|
1312
|
-
|
|
1313
|
-
|
|
1314
|
-
|
|
1315
|
-
|
|
1316
|
-
else {
|
|
1317
|
-
message.room = "";
|
|
1318
|
-
}
|
|
1319
|
-
if (object.metadata !== undefined && object.metadata !== null) {
|
|
1320
|
-
message.metadata = object.metadata;
|
|
1321
|
-
}
|
|
1322
|
-
else {
|
|
1323
|
-
message.metadata = "";
|
|
1324
|
-
}
|
|
951
|
+
var _a, _b;
|
|
952
|
+
const message = createBaseUpdateRoomMetadataRequest();
|
|
953
|
+
message.room = (_a = object.room) !== null && _a !== void 0 ? _a : '';
|
|
954
|
+
message.metadata = (_b = object.metadata) !== null && _b !== void 0 ? _b : '';
|
|
1325
955
|
return message;
|
|
1326
956
|
},
|
|
1327
957
|
};
|
|
1328
958
|
var globalThis = (() => {
|
|
1329
|
-
if (typeof globalThis !==
|
|
959
|
+
if (typeof globalThis !== 'undefined')
|
|
1330
960
|
return globalThis;
|
|
1331
|
-
if (typeof self !==
|
|
961
|
+
if (typeof self !== 'undefined')
|
|
1332
962
|
return self;
|
|
1333
|
-
if (typeof window !==
|
|
963
|
+
if (typeof window !== 'undefined')
|
|
1334
964
|
return window;
|
|
1335
|
-
if (typeof global !==
|
|
965
|
+
if (typeof global !== 'undefined')
|
|
1336
966
|
return global;
|
|
1337
|
-
throw
|
|
967
|
+
throw 'Unable to locate global object';
|
|
1338
968
|
})();
|
|
1339
|
-
const atob = globalThis.atob ||
|
|
1340
|
-
((b64) => globalThis.Buffer.from(b64, "base64").toString("binary"));
|
|
969
|
+
const atob = globalThis.atob || ((b64) => globalThis.Buffer.from(b64, 'base64').toString('binary'));
|
|
1341
970
|
function bytesFromBase64(b64) {
|
|
1342
971
|
const bin = atob(b64);
|
|
1343
972
|
const arr = new Uint8Array(bin.length);
|
|
@@ -1346,17 +975,19 @@ function bytesFromBase64(b64) {
|
|
|
1346
975
|
}
|
|
1347
976
|
return arr;
|
|
1348
977
|
}
|
|
1349
|
-
const btoa = globalThis.btoa ||
|
|
1350
|
-
((bin) => globalThis.Buffer.from(bin, "binary").toString("base64"));
|
|
978
|
+
const btoa = globalThis.btoa || ((bin) => globalThis.Buffer.from(bin, 'binary').toString('base64'));
|
|
1351
979
|
function base64FromBytes(arr) {
|
|
1352
980
|
const bin = [];
|
|
1353
981
|
for (const byte of arr) {
|
|
1354
982
|
bin.push(String.fromCharCode(byte));
|
|
1355
983
|
}
|
|
1356
|
-
return btoa(bin.join(
|
|
984
|
+
return btoa(bin.join(''));
|
|
985
|
+
}
|
|
986
|
+
if (_m0.util.Long !== long_1.default) {
|
|
987
|
+
_m0.util.Long = long_1.default;
|
|
988
|
+
_m0.configure();
|
|
1357
989
|
}
|
|
1358
|
-
|
|
1359
|
-
|
|
1360
|
-
minimal_1.default.configure();
|
|
990
|
+
function isSet(value) {
|
|
991
|
+
return value !== null && value !== undefined;
|
|
1361
992
|
}
|
|
1362
993
|
//# sourceMappingURL=livekit_room.js.map
|