@stream-io/node-sdk 0.4.26 → 0.5.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/dist/index.cjs.js +6292 -3831
- package/dist/index.cjs.js.map +1 -1
- package/dist/index.d.ts +3 -1
- package/dist/index.es.mjs +6290 -3832
- package/dist/index.es.mjs.map +1 -1
- package/dist/src/ApiClient.d.ts +15 -0
- package/dist/src/StreamCall.d.ts +2 -2
- package/dist/src/StreamClient.d.ts +10 -1
- package/dist/src/StreamFeed.d.ts +4 -0
- package/dist/src/StreamFeedsClient.d.ts +5 -0
- package/dist/src/StreamVideoClient.d.ts +3 -2
- package/dist/src/gen/chat/ChannelApi.d.ts +29 -30
- package/dist/src/gen/chat/ChatApi.d.ts +145 -180
- package/dist/src/gen/common/CommonApi.d.ts +120 -83
- package/dist/src/gen/feeds/FeedApi.d.ts +25 -0
- package/dist/src/gen/feeds/FeedsApi.d.ts +195 -0
- package/dist/src/gen/models/index.d.ts +1498 -17
- package/dist/src/gen/moderation/ModerationApi.d.ts +28 -27
- package/dist/src/gen/video/CallApi.d.ts +42 -43
- package/dist/src/gen/video/VideoApi.d.ts +90 -89
- package/dist/src/gen-imports.d.ts +5 -0
- package/index.ts +3 -1
- package/package.json +1 -1
- package/src/{BaseApi.ts → ApiClient.ts} +25 -6
- package/src/StreamCall.ts +2 -2
- package/src/StreamClient.ts +51 -14
- package/src/StreamFeed.ts +7 -0
- package/src/StreamFeedsClient.ts +8 -0
- package/src/StreamVideoClient.ts +9 -6
- package/src/gen/chat/ChannelApi.ts +74 -64
- package/src/gen/chat/ChatApi.ts +548 -681
- package/src/gen/common/CommonApi.ts +679 -271
- package/src/gen/feeds/FeedApi.ts +130 -0
- package/src/gen/feeds/FeedsApi.ts +1801 -0
- package/src/gen/model-decoders/{index.ts → decoders.ts} +2294 -276
- package/src/gen/models/index.ts +4233 -2028
- package/src/gen/moderation/ModerationApi.ts +159 -98
- package/src/gen/video/CallApi.ts +97 -108
- package/src/gen/video/VideoApi.ts +294 -207
- package/src/gen-imports.ts +5 -0
- package/dist/src/BaseApi.d.ts +0 -11
- /package/dist/src/gen/model-decoders/{index.d.ts → decoders.d.ts} +0 -0
|
@@ -1,5 +1,4 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { StreamResponse } from '../../types';
|
|
1
|
+
import { ApiClient, StreamResponse } from '../../gen-imports';
|
|
3
2
|
import {
|
|
4
3
|
BlockUserRequest,
|
|
5
4
|
BlockUserResponse,
|
|
@@ -79,24 +78,26 @@ import {
|
|
|
79
78
|
UpdateUserPermissionsRequest,
|
|
80
79
|
UpdateUserPermissionsResponse,
|
|
81
80
|
} from '../models';
|
|
82
|
-
import { decoders } from '../model-decoders';
|
|
81
|
+
import { decoders } from '../model-decoders/decoders';
|
|
83
82
|
|
|
84
|
-
export class VideoApi
|
|
85
|
-
|
|
83
|
+
export class VideoApi {
|
|
84
|
+
constructor(public readonly apiClient: ApiClient) {}
|
|
85
|
+
|
|
86
|
+
async getActiveCallsStatus(): Promise<
|
|
86
87
|
StreamResponse<GetActiveCallsStatusResponse>
|
|
87
|
-
>
|
|
88
|
-
const response = await this.sendRequest<
|
|
88
|
+
> {
|
|
89
|
+
const response = await this.apiClient.sendRequest<
|
|
89
90
|
StreamResponse<GetActiveCallsStatusResponse>
|
|
90
91
|
>('GET', '/api/v2/video/active_calls_status', undefined, undefined);
|
|
91
92
|
|
|
92
93
|
decoders.GetActiveCallsStatusResponse?.(response.body);
|
|
93
94
|
|
|
94
95
|
return { ...response.body, metadata: response.metadata };
|
|
95
|
-
}
|
|
96
|
+
}
|
|
96
97
|
|
|
97
|
-
|
|
98
|
+
async queryUserFeedback(
|
|
98
99
|
request?: QueryUserFeedbackRequest & { full?: boolean },
|
|
99
|
-
): Promise<StreamResponse<QueryUserFeedbackResponse>>
|
|
100
|
+
): Promise<StreamResponse<QueryUserFeedbackResponse>> {
|
|
100
101
|
const queryParams = {
|
|
101
102
|
full: request?.full,
|
|
102
103
|
};
|
|
@@ -108,18 +109,25 @@ export class VideoApi extends BaseApi {
|
|
|
108
109
|
filter_conditions: request?.filter_conditions,
|
|
109
110
|
};
|
|
110
111
|
|
|
111
|
-
const response = await this.sendRequest<
|
|
112
|
+
const response = await this.apiClient.sendRequest<
|
|
112
113
|
StreamResponse<QueryUserFeedbackResponse>
|
|
113
|
-
>(
|
|
114
|
+
>(
|
|
115
|
+
'POST',
|
|
116
|
+
'/api/v2/video/call/feedback',
|
|
117
|
+
undefined,
|
|
118
|
+
queryParams,
|
|
119
|
+
body,
|
|
120
|
+
'application/json',
|
|
121
|
+
);
|
|
114
122
|
|
|
115
123
|
decoders.QueryUserFeedbackResponse?.(response.body);
|
|
116
124
|
|
|
117
125
|
return { ...response.body, metadata: response.metadata };
|
|
118
|
-
}
|
|
126
|
+
}
|
|
119
127
|
|
|
120
|
-
|
|
128
|
+
async queryCallMembers(
|
|
121
129
|
request: QueryCallMembersRequest,
|
|
122
|
-
): Promise<StreamResponse<QueryCallMembersResponse>>
|
|
130
|
+
): Promise<StreamResponse<QueryCallMembersResponse>> {
|
|
123
131
|
const body = {
|
|
124
132
|
id: request?.id,
|
|
125
133
|
type: request?.type,
|
|
@@ -130,18 +138,25 @@ export class VideoApi extends BaseApi {
|
|
|
130
138
|
filter_conditions: request?.filter_conditions,
|
|
131
139
|
};
|
|
132
140
|
|
|
133
|
-
const response = await this.sendRequest<
|
|
141
|
+
const response = await this.apiClient.sendRequest<
|
|
134
142
|
StreamResponse<QueryCallMembersResponse>
|
|
135
|
-
>(
|
|
143
|
+
>(
|
|
144
|
+
'POST',
|
|
145
|
+
'/api/v2/video/call/members',
|
|
146
|
+
undefined,
|
|
147
|
+
undefined,
|
|
148
|
+
body,
|
|
149
|
+
'application/json',
|
|
150
|
+
);
|
|
136
151
|
|
|
137
152
|
decoders.QueryCallMembersResponse?.(response.body);
|
|
138
153
|
|
|
139
154
|
return { ...response.body, metadata: response.metadata };
|
|
140
|
-
}
|
|
155
|
+
}
|
|
141
156
|
|
|
142
|
-
|
|
157
|
+
async queryCallStats(
|
|
143
158
|
request?: QueryCallStatsRequest,
|
|
144
|
-
): Promise<StreamResponse<QueryCallStatsResponse>>
|
|
159
|
+
): Promise<StreamResponse<QueryCallStatsResponse>> {
|
|
145
160
|
const body = {
|
|
146
161
|
limit: request?.limit,
|
|
147
162
|
next: request?.next,
|
|
@@ -150,23 +165,30 @@ export class VideoApi extends BaseApi {
|
|
|
150
165
|
filter_conditions: request?.filter_conditions,
|
|
151
166
|
};
|
|
152
167
|
|
|
153
|
-
const response = await this.sendRequest<
|
|
168
|
+
const response = await this.apiClient.sendRequest<
|
|
154
169
|
StreamResponse<QueryCallStatsResponse>
|
|
155
|
-
>(
|
|
170
|
+
>(
|
|
171
|
+
'POST',
|
|
172
|
+
'/api/v2/video/call/stats',
|
|
173
|
+
undefined,
|
|
174
|
+
undefined,
|
|
175
|
+
body,
|
|
176
|
+
'application/json',
|
|
177
|
+
);
|
|
156
178
|
|
|
157
179
|
decoders.QueryCallStatsResponse?.(response.body);
|
|
158
180
|
|
|
159
181
|
return { ...response.body, metadata: response.metadata };
|
|
160
|
-
}
|
|
182
|
+
}
|
|
161
183
|
|
|
162
|
-
|
|
184
|
+
async getCall(request: {
|
|
163
185
|
type: string;
|
|
164
186
|
id: string;
|
|
165
187
|
members_limit?: number;
|
|
166
188
|
ring?: boolean;
|
|
167
189
|
notify?: boolean;
|
|
168
190
|
video?: boolean;
|
|
169
|
-
}): Promise<StreamResponse<GetCallResponse>>
|
|
191
|
+
}): Promise<StreamResponse<GetCallResponse>> {
|
|
170
192
|
const queryParams = {
|
|
171
193
|
members_limit: request?.members_limit,
|
|
172
194
|
ring: request?.ring,
|
|
@@ -178,21 +200,18 @@ export class VideoApi extends BaseApi {
|
|
|
178
200
|
id: request?.id,
|
|
179
201
|
};
|
|
180
202
|
|
|
181
|
-
const response = await this.sendRequest<
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
pathParams,
|
|
185
|
-
queryParams,
|
|
186
|
-
);
|
|
203
|
+
const response = await this.apiClient.sendRequest<
|
|
204
|
+
StreamResponse<GetCallResponse>
|
|
205
|
+
>('GET', '/api/v2/video/call/{type}/{id}', pathParams, queryParams);
|
|
187
206
|
|
|
188
207
|
decoders.GetCallResponse?.(response.body);
|
|
189
208
|
|
|
190
209
|
return { ...response.body, metadata: response.metadata };
|
|
191
|
-
}
|
|
210
|
+
}
|
|
192
211
|
|
|
193
|
-
|
|
212
|
+
async updateCall(
|
|
194
213
|
request: UpdateCallRequest & { type: string; id: string },
|
|
195
|
-
): Promise<StreamResponse<UpdateCallResponse>>
|
|
214
|
+
): Promise<StreamResponse<UpdateCallResponse>> {
|
|
196
215
|
const pathParams = {
|
|
197
216
|
type: request?.type,
|
|
198
217
|
id: request?.id,
|
|
@@ -203,22 +222,25 @@ export class VideoApi extends BaseApi {
|
|
|
203
222
|
settings_override: request?.settings_override,
|
|
204
223
|
};
|
|
205
224
|
|
|
206
|
-
const response = await this.sendRequest<
|
|
225
|
+
const response = await this.apiClient.sendRequest<
|
|
226
|
+
StreamResponse<UpdateCallResponse>
|
|
227
|
+
>(
|
|
207
228
|
'PATCH',
|
|
208
229
|
'/api/v2/video/call/{type}/{id}',
|
|
209
230
|
pathParams,
|
|
210
231
|
undefined,
|
|
211
232
|
body,
|
|
233
|
+
'application/json',
|
|
212
234
|
);
|
|
213
235
|
|
|
214
236
|
decoders.UpdateCallResponse?.(response.body);
|
|
215
237
|
|
|
216
238
|
return { ...response.body, metadata: response.metadata };
|
|
217
|
-
}
|
|
239
|
+
}
|
|
218
240
|
|
|
219
|
-
|
|
241
|
+
async getOrCreateCall(
|
|
220
242
|
request: GetOrCreateCallRequest & { type: string; id: string },
|
|
221
|
-
): Promise<StreamResponse<GetOrCreateCallResponse>>
|
|
243
|
+
): Promise<StreamResponse<GetOrCreateCallResponse>> {
|
|
222
244
|
const pathParams = {
|
|
223
245
|
type: request?.type,
|
|
224
246
|
id: request?.id,
|
|
@@ -231,18 +253,25 @@ export class VideoApi extends BaseApi {
|
|
|
231
253
|
data: request?.data,
|
|
232
254
|
};
|
|
233
255
|
|
|
234
|
-
const response = await this.sendRequest<
|
|
256
|
+
const response = await this.apiClient.sendRequest<
|
|
235
257
|
StreamResponse<GetOrCreateCallResponse>
|
|
236
|
-
>(
|
|
258
|
+
>(
|
|
259
|
+
'POST',
|
|
260
|
+
'/api/v2/video/call/{type}/{id}',
|
|
261
|
+
pathParams,
|
|
262
|
+
undefined,
|
|
263
|
+
body,
|
|
264
|
+
'application/json',
|
|
265
|
+
);
|
|
237
266
|
|
|
238
267
|
decoders.GetOrCreateCallResponse?.(response.body);
|
|
239
268
|
|
|
240
269
|
return { ...response.body, metadata: response.metadata };
|
|
241
|
-
}
|
|
270
|
+
}
|
|
242
271
|
|
|
243
|
-
|
|
272
|
+
async blockUser(
|
|
244
273
|
request: BlockUserRequest & { type: string; id: string },
|
|
245
|
-
): Promise<StreamResponse<BlockUserResponse>>
|
|
274
|
+
): Promise<StreamResponse<BlockUserResponse>> {
|
|
246
275
|
const pathParams = {
|
|
247
276
|
type: request?.type,
|
|
248
277
|
id: request?.id,
|
|
@@ -251,22 +280,25 @@ export class VideoApi extends BaseApi {
|
|
|
251
280
|
user_id: request?.user_id,
|
|
252
281
|
};
|
|
253
282
|
|
|
254
|
-
const response = await this.sendRequest<
|
|
283
|
+
const response = await this.apiClient.sendRequest<
|
|
284
|
+
StreamResponse<BlockUserResponse>
|
|
285
|
+
>(
|
|
255
286
|
'POST',
|
|
256
287
|
'/api/v2/video/call/{type}/{id}/block',
|
|
257
288
|
pathParams,
|
|
258
289
|
undefined,
|
|
259
290
|
body,
|
|
291
|
+
'application/json',
|
|
260
292
|
);
|
|
261
293
|
|
|
262
294
|
decoders.BlockUserResponse?.(response.body);
|
|
263
295
|
|
|
264
296
|
return { ...response.body, metadata: response.metadata };
|
|
265
|
-
}
|
|
297
|
+
}
|
|
266
298
|
|
|
267
|
-
|
|
299
|
+
async deleteCall(
|
|
268
300
|
request: DeleteCallRequest & { type: string; id: string },
|
|
269
|
-
): Promise<StreamResponse<DeleteCallResponse>>
|
|
301
|
+
): Promise<StreamResponse<DeleteCallResponse>> {
|
|
270
302
|
const pathParams = {
|
|
271
303
|
type: request?.type,
|
|
272
304
|
id: request?.id,
|
|
@@ -275,22 +307,25 @@ export class VideoApi extends BaseApi {
|
|
|
275
307
|
hard: request?.hard,
|
|
276
308
|
};
|
|
277
309
|
|
|
278
|
-
const response = await this.sendRequest<
|
|
310
|
+
const response = await this.apiClient.sendRequest<
|
|
311
|
+
StreamResponse<DeleteCallResponse>
|
|
312
|
+
>(
|
|
279
313
|
'POST',
|
|
280
314
|
'/api/v2/video/call/{type}/{id}/delete',
|
|
281
315
|
pathParams,
|
|
282
316
|
undefined,
|
|
283
317
|
body,
|
|
318
|
+
'application/json',
|
|
284
319
|
);
|
|
285
320
|
|
|
286
321
|
decoders.DeleteCallResponse?.(response.body);
|
|
287
322
|
|
|
288
323
|
return { ...response.body, metadata: response.metadata };
|
|
289
|
-
}
|
|
324
|
+
}
|
|
290
325
|
|
|
291
|
-
|
|
326
|
+
async sendCallEvent(
|
|
292
327
|
request: SendCallEventRequest & { type: string; id: string },
|
|
293
|
-
): Promise<StreamResponse<SendCallEventResponse>>
|
|
328
|
+
): Promise<StreamResponse<SendCallEventResponse>> {
|
|
294
329
|
const pathParams = {
|
|
295
330
|
type: request?.type,
|
|
296
331
|
id: request?.id,
|
|
@@ -301,7 +336,7 @@ export class VideoApi extends BaseApi {
|
|
|
301
336
|
user: request?.user,
|
|
302
337
|
};
|
|
303
338
|
|
|
304
|
-
const response = await this.sendRequest<
|
|
339
|
+
const response = await this.apiClient.sendRequest<
|
|
305
340
|
StreamResponse<SendCallEventResponse>
|
|
306
341
|
>(
|
|
307
342
|
'POST',
|
|
@@ -309,16 +344,17 @@ export class VideoApi extends BaseApi {
|
|
|
309
344
|
pathParams,
|
|
310
345
|
undefined,
|
|
311
346
|
body,
|
|
347
|
+
'application/json',
|
|
312
348
|
);
|
|
313
349
|
|
|
314
350
|
decoders.SendCallEventResponse?.(response.body);
|
|
315
351
|
|
|
316
352
|
return { ...response.body, metadata: response.metadata };
|
|
317
|
-
}
|
|
353
|
+
}
|
|
318
354
|
|
|
319
|
-
|
|
355
|
+
async collectUserFeedback(
|
|
320
356
|
request: CollectUserFeedbackRequest & { type: string; id: string },
|
|
321
|
-
): Promise<StreamResponse<CollectUserFeedbackResponse>>
|
|
357
|
+
): Promise<StreamResponse<CollectUserFeedbackResponse>> {
|
|
322
358
|
const pathParams = {
|
|
323
359
|
type: request?.type,
|
|
324
360
|
id: request?.id,
|
|
@@ -332,7 +368,7 @@ export class VideoApi extends BaseApi {
|
|
|
332
368
|
custom: request?.custom,
|
|
333
369
|
};
|
|
334
370
|
|
|
335
|
-
const response = await this.sendRequest<
|
|
371
|
+
const response = await this.apiClient.sendRequest<
|
|
336
372
|
StreamResponse<CollectUserFeedbackResponse>
|
|
337
373
|
>(
|
|
338
374
|
'POST',
|
|
@@ -340,16 +376,17 @@ export class VideoApi extends BaseApi {
|
|
|
340
376
|
pathParams,
|
|
341
377
|
undefined,
|
|
342
378
|
body,
|
|
379
|
+
'application/json',
|
|
343
380
|
);
|
|
344
381
|
|
|
345
382
|
decoders.CollectUserFeedbackResponse?.(response.body);
|
|
346
383
|
|
|
347
384
|
return { ...response.body, metadata: response.metadata };
|
|
348
|
-
}
|
|
385
|
+
}
|
|
349
386
|
|
|
350
|
-
|
|
387
|
+
async goLive(
|
|
351
388
|
request: GoLiveRequest & { type: string; id: string },
|
|
352
|
-
): Promise<StreamResponse<GoLiveResponse>>
|
|
389
|
+
): Promise<StreamResponse<GoLiveResponse>> {
|
|
353
390
|
const pathParams = {
|
|
354
391
|
type: request?.type,
|
|
355
392
|
id: request?.id,
|
|
@@ -363,29 +400,34 @@ export class VideoApi extends BaseApi {
|
|
|
363
400
|
transcription_storage_name: request?.transcription_storage_name,
|
|
364
401
|
};
|
|
365
402
|
|
|
366
|
-
const response = await this.sendRequest<
|
|
403
|
+
const response = await this.apiClient.sendRequest<
|
|
404
|
+
StreamResponse<GoLiveResponse>
|
|
405
|
+
>(
|
|
367
406
|
'POST',
|
|
368
407
|
'/api/v2/video/call/{type}/{id}/go_live',
|
|
369
408
|
pathParams,
|
|
370
409
|
undefined,
|
|
371
410
|
body,
|
|
411
|
+
'application/json',
|
|
372
412
|
);
|
|
373
413
|
|
|
374
414
|
decoders.GoLiveResponse?.(response.body);
|
|
375
415
|
|
|
376
416
|
return { ...response.body, metadata: response.metadata };
|
|
377
|
-
}
|
|
417
|
+
}
|
|
378
418
|
|
|
379
|
-
|
|
419
|
+
async endCall(request: {
|
|
380
420
|
type: string;
|
|
381
421
|
id: string;
|
|
382
|
-
}): Promise<StreamResponse<EndCallResponse>>
|
|
422
|
+
}): Promise<StreamResponse<EndCallResponse>> {
|
|
383
423
|
const pathParams = {
|
|
384
424
|
type: request?.type,
|
|
385
425
|
id: request?.id,
|
|
386
426
|
};
|
|
387
427
|
|
|
388
|
-
const response = await this.sendRequest<
|
|
428
|
+
const response = await this.apiClient.sendRequest<
|
|
429
|
+
StreamResponse<EndCallResponse>
|
|
430
|
+
>(
|
|
389
431
|
'POST',
|
|
390
432
|
'/api/v2/video/call/{type}/{id}/mark_ended',
|
|
391
433
|
pathParams,
|
|
@@ -395,11 +437,11 @@ export class VideoApi extends BaseApi {
|
|
|
395
437
|
decoders.EndCallResponse?.(response.body);
|
|
396
438
|
|
|
397
439
|
return { ...response.body, metadata: response.metadata };
|
|
398
|
-
}
|
|
440
|
+
}
|
|
399
441
|
|
|
400
|
-
|
|
442
|
+
async updateCallMembers(
|
|
401
443
|
request: UpdateCallMembersRequest & { type: string; id: string },
|
|
402
|
-
): Promise<StreamResponse<UpdateCallMembersResponse>>
|
|
444
|
+
): Promise<StreamResponse<UpdateCallMembersResponse>> {
|
|
403
445
|
const pathParams = {
|
|
404
446
|
type: request?.type,
|
|
405
447
|
id: request?.id,
|
|
@@ -409,7 +451,7 @@ export class VideoApi extends BaseApi {
|
|
|
409
451
|
update_members: request?.update_members,
|
|
410
452
|
};
|
|
411
453
|
|
|
412
|
-
const response = await this.sendRequest<
|
|
454
|
+
const response = await this.apiClient.sendRequest<
|
|
413
455
|
StreamResponse<UpdateCallMembersResponse>
|
|
414
456
|
>(
|
|
415
457
|
'POST',
|
|
@@ -417,16 +459,17 @@ export class VideoApi extends BaseApi {
|
|
|
417
459
|
pathParams,
|
|
418
460
|
undefined,
|
|
419
461
|
body,
|
|
462
|
+
'application/json',
|
|
420
463
|
);
|
|
421
464
|
|
|
422
465
|
decoders.UpdateCallMembersResponse?.(response.body);
|
|
423
466
|
|
|
424
467
|
return { ...response.body, metadata: response.metadata };
|
|
425
|
-
}
|
|
468
|
+
}
|
|
426
469
|
|
|
427
|
-
|
|
470
|
+
async muteUsers(
|
|
428
471
|
request: MuteUsersRequest & { type: string; id: string },
|
|
429
|
-
): Promise<StreamResponse<MuteUsersResponse>>
|
|
472
|
+
): Promise<StreamResponse<MuteUsersResponse>> {
|
|
430
473
|
const pathParams = {
|
|
431
474
|
type: request?.type,
|
|
432
475
|
id: request?.id,
|
|
@@ -442,26 +485,29 @@ export class VideoApi extends BaseApi {
|
|
|
442
485
|
muted_by: request?.muted_by,
|
|
443
486
|
};
|
|
444
487
|
|
|
445
|
-
const response = await this.sendRequest<
|
|
488
|
+
const response = await this.apiClient.sendRequest<
|
|
489
|
+
StreamResponse<MuteUsersResponse>
|
|
490
|
+
>(
|
|
446
491
|
'POST',
|
|
447
492
|
'/api/v2/video/call/{type}/{id}/mute_users',
|
|
448
493
|
pathParams,
|
|
449
494
|
undefined,
|
|
450
495
|
body,
|
|
496
|
+
'application/json',
|
|
451
497
|
);
|
|
452
498
|
|
|
453
499
|
decoders.MuteUsersResponse?.(response.body);
|
|
454
500
|
|
|
455
501
|
return { ...response.body, metadata: response.metadata };
|
|
456
|
-
}
|
|
502
|
+
}
|
|
457
503
|
|
|
458
|
-
|
|
504
|
+
async queryCallParticipants(
|
|
459
505
|
request: QueryCallParticipantsRequest & {
|
|
460
506
|
id: string;
|
|
461
507
|
type: string;
|
|
462
508
|
limit?: number;
|
|
463
509
|
},
|
|
464
|
-
): Promise<StreamResponse<QueryCallParticipantsResponse>>
|
|
510
|
+
): Promise<StreamResponse<QueryCallParticipantsResponse>> {
|
|
465
511
|
const queryParams = {
|
|
466
512
|
limit: request?.limit,
|
|
467
513
|
};
|
|
@@ -473,7 +519,7 @@ export class VideoApi extends BaseApi {
|
|
|
473
519
|
filter_conditions: request?.filter_conditions,
|
|
474
520
|
};
|
|
475
521
|
|
|
476
|
-
const response = await this.sendRequest<
|
|
522
|
+
const response = await this.apiClient.sendRequest<
|
|
477
523
|
StreamResponse<QueryCallParticipantsResponse>
|
|
478
524
|
>(
|
|
479
525
|
'POST',
|
|
@@ -481,16 +527,17 @@ export class VideoApi extends BaseApi {
|
|
|
481
527
|
pathParams,
|
|
482
528
|
queryParams,
|
|
483
529
|
body,
|
|
530
|
+
'application/json',
|
|
484
531
|
);
|
|
485
532
|
|
|
486
533
|
decoders.QueryCallParticipantsResponse?.(response.body);
|
|
487
534
|
|
|
488
535
|
return { ...response.body, metadata: response.metadata };
|
|
489
|
-
}
|
|
536
|
+
}
|
|
490
537
|
|
|
491
|
-
|
|
538
|
+
async videoPin(
|
|
492
539
|
request: PinRequest & { type: string; id: string },
|
|
493
|
-
): Promise<StreamResponse<PinResponse>>
|
|
540
|
+
): Promise<StreamResponse<PinResponse>> {
|
|
494
541
|
const pathParams = {
|
|
495
542
|
type: request?.type,
|
|
496
543
|
id: request?.id,
|
|
@@ -500,29 +547,32 @@ export class VideoApi extends BaseApi {
|
|
|
500
547
|
user_id: request?.user_id,
|
|
501
548
|
};
|
|
502
549
|
|
|
503
|
-
const response = await this.sendRequest<
|
|
550
|
+
const response = await this.apiClient.sendRequest<
|
|
551
|
+
StreamResponse<PinResponse>
|
|
552
|
+
>(
|
|
504
553
|
'POST',
|
|
505
554
|
'/api/v2/video/call/{type}/{id}/pin',
|
|
506
555
|
pathParams,
|
|
507
556
|
undefined,
|
|
508
557
|
body,
|
|
558
|
+
'application/json',
|
|
509
559
|
);
|
|
510
560
|
|
|
511
561
|
decoders.PinResponse?.(response.body);
|
|
512
562
|
|
|
513
563
|
return { ...response.body, metadata: response.metadata };
|
|
514
|
-
}
|
|
564
|
+
}
|
|
515
565
|
|
|
516
|
-
|
|
566
|
+
async listRecordings(request: {
|
|
517
567
|
type: string;
|
|
518
568
|
id: string;
|
|
519
|
-
}): Promise<StreamResponse<ListRecordingsResponse>>
|
|
569
|
+
}): Promise<StreamResponse<ListRecordingsResponse>> {
|
|
520
570
|
const pathParams = {
|
|
521
571
|
type: request?.type,
|
|
522
572
|
id: request?.id,
|
|
523
573
|
};
|
|
524
574
|
|
|
525
|
-
const response = await this.sendRequest<
|
|
575
|
+
const response = await this.apiClient.sendRequest<
|
|
526
576
|
StreamResponse<ListRecordingsResponse>
|
|
527
577
|
>(
|
|
528
578
|
'GET',
|
|
@@ -534,13 +584,13 @@ export class VideoApi extends BaseApi {
|
|
|
534
584
|
decoders.ListRecordingsResponse?.(response.body);
|
|
535
585
|
|
|
536
586
|
return { ...response.body, metadata: response.metadata };
|
|
537
|
-
}
|
|
587
|
+
}
|
|
538
588
|
|
|
539
|
-
|
|
589
|
+
async getCallReport(request: {
|
|
540
590
|
type: string;
|
|
541
591
|
id: string;
|
|
542
592
|
session_id?: string;
|
|
543
|
-
}): Promise<StreamResponse<GetCallReportResponse>>
|
|
593
|
+
}): Promise<StreamResponse<GetCallReportResponse>> {
|
|
544
594
|
const queryParams = {
|
|
545
595
|
session_id: request?.session_id,
|
|
546
596
|
};
|
|
@@ -549,18 +599,18 @@ export class VideoApi extends BaseApi {
|
|
|
549
599
|
id: request?.id,
|
|
550
600
|
};
|
|
551
601
|
|
|
552
|
-
const response = await this.sendRequest<
|
|
602
|
+
const response = await this.apiClient.sendRequest<
|
|
553
603
|
StreamResponse<GetCallReportResponse>
|
|
554
604
|
>('GET', '/api/v2/video/call/{type}/{id}/report', pathParams, queryParams);
|
|
555
605
|
|
|
556
606
|
decoders.GetCallReportResponse?.(response.body);
|
|
557
607
|
|
|
558
608
|
return { ...response.body, metadata: response.metadata };
|
|
559
|
-
}
|
|
609
|
+
}
|
|
560
610
|
|
|
561
|
-
|
|
611
|
+
async startRTMPBroadcasts(
|
|
562
612
|
request: StartRTMPBroadcastsRequest & { type: string; id: string },
|
|
563
|
-
): Promise<StreamResponse<StartRTMPBroadcastsResponse>>
|
|
613
|
+
): Promise<StreamResponse<StartRTMPBroadcastsResponse>> {
|
|
564
614
|
const pathParams = {
|
|
565
615
|
type: request?.type,
|
|
566
616
|
id: request?.id,
|
|
@@ -569,7 +619,7 @@ export class VideoApi extends BaseApi {
|
|
|
569
619
|
broadcasts: request?.broadcasts,
|
|
570
620
|
};
|
|
571
621
|
|
|
572
|
-
const response = await this.sendRequest<
|
|
622
|
+
const response = await this.apiClient.sendRequest<
|
|
573
623
|
StreamResponse<StartRTMPBroadcastsResponse>
|
|
574
624
|
>(
|
|
575
625
|
'POST',
|
|
@@ -577,23 +627,24 @@ export class VideoApi extends BaseApi {
|
|
|
577
627
|
pathParams,
|
|
578
628
|
undefined,
|
|
579
629
|
body,
|
|
630
|
+
'application/json',
|
|
580
631
|
);
|
|
581
632
|
|
|
582
633
|
decoders.StartRTMPBroadcastsResponse?.(response.body);
|
|
583
634
|
|
|
584
635
|
return { ...response.body, metadata: response.metadata };
|
|
585
|
-
}
|
|
636
|
+
}
|
|
586
637
|
|
|
587
|
-
|
|
638
|
+
async stopAllRTMPBroadcasts(request: {
|
|
588
639
|
type: string;
|
|
589
640
|
id: string;
|
|
590
|
-
}): Promise<StreamResponse<StopAllRTMPBroadcastsResponse>>
|
|
641
|
+
}): Promise<StreamResponse<StopAllRTMPBroadcastsResponse>> {
|
|
591
642
|
const pathParams = {
|
|
592
643
|
type: request?.type,
|
|
593
644
|
id: request?.id,
|
|
594
645
|
};
|
|
595
646
|
|
|
596
|
-
const response = await this.sendRequest<
|
|
647
|
+
const response = await this.apiClient.sendRequest<
|
|
597
648
|
StreamResponse<StopAllRTMPBroadcastsResponse>
|
|
598
649
|
>(
|
|
599
650
|
'POST',
|
|
@@ -605,15 +656,15 @@ export class VideoApi extends BaseApi {
|
|
|
605
656
|
decoders.StopAllRTMPBroadcastsResponse?.(response.body);
|
|
606
657
|
|
|
607
658
|
return { ...response.body, metadata: response.metadata };
|
|
608
|
-
}
|
|
659
|
+
}
|
|
609
660
|
|
|
610
|
-
|
|
661
|
+
async stopRTMPBroadcast(
|
|
611
662
|
request: StopRTMPBroadcastsRequest & {
|
|
612
663
|
type: string;
|
|
613
664
|
id: string;
|
|
614
665
|
name: string;
|
|
615
666
|
},
|
|
616
|
-
): Promise<StreamResponse<StopRTMPBroadcastsResponse>>
|
|
667
|
+
): Promise<StreamResponse<StopRTMPBroadcastsResponse>> {
|
|
617
668
|
const pathParams = {
|
|
618
669
|
type: request?.type,
|
|
619
670
|
id: request?.id,
|
|
@@ -621,7 +672,7 @@ export class VideoApi extends BaseApi {
|
|
|
621
672
|
};
|
|
622
673
|
const body = {};
|
|
623
674
|
|
|
624
|
-
const response = await this.sendRequest<
|
|
675
|
+
const response = await this.apiClient.sendRequest<
|
|
625
676
|
StreamResponse<StopRTMPBroadcastsResponse>
|
|
626
677
|
>(
|
|
627
678
|
'POST',
|
|
@@ -629,23 +680,24 @@ export class VideoApi extends BaseApi {
|
|
|
629
680
|
pathParams,
|
|
630
681
|
undefined,
|
|
631
682
|
body,
|
|
683
|
+
'application/json',
|
|
632
684
|
);
|
|
633
685
|
|
|
634
686
|
decoders.StopRTMPBroadcastsResponse?.(response.body);
|
|
635
687
|
|
|
636
688
|
return { ...response.body, metadata: response.metadata };
|
|
637
|
-
}
|
|
689
|
+
}
|
|
638
690
|
|
|
639
|
-
|
|
691
|
+
async startHLSBroadcasting(request: {
|
|
640
692
|
type: string;
|
|
641
693
|
id: string;
|
|
642
|
-
}): Promise<StreamResponse<StartHLSBroadcastingResponse>>
|
|
694
|
+
}): Promise<StreamResponse<StartHLSBroadcastingResponse>> {
|
|
643
695
|
const pathParams = {
|
|
644
696
|
type: request?.type,
|
|
645
697
|
id: request?.id,
|
|
646
698
|
};
|
|
647
699
|
|
|
648
|
-
const response = await this.sendRequest<
|
|
700
|
+
const response = await this.apiClient.sendRequest<
|
|
649
701
|
StreamResponse<StartHLSBroadcastingResponse>
|
|
650
702
|
>(
|
|
651
703
|
'POST',
|
|
@@ -657,11 +709,11 @@ export class VideoApi extends BaseApi {
|
|
|
657
709
|
decoders.StartHLSBroadcastingResponse?.(response.body);
|
|
658
710
|
|
|
659
711
|
return { ...response.body, metadata: response.metadata };
|
|
660
|
-
}
|
|
712
|
+
}
|
|
661
713
|
|
|
662
|
-
|
|
714
|
+
async startClosedCaptions(
|
|
663
715
|
request: StartClosedCaptionsRequest & { type: string; id: string },
|
|
664
|
-
): Promise<StreamResponse<StartClosedCaptionsResponse>>
|
|
716
|
+
): Promise<StreamResponse<StartClosedCaptionsResponse>> {
|
|
665
717
|
const pathParams = {
|
|
666
718
|
type: request?.type,
|
|
667
719
|
id: request?.id,
|
|
@@ -672,7 +724,7 @@ export class VideoApi extends BaseApi {
|
|
|
672
724
|
language: request?.language,
|
|
673
725
|
};
|
|
674
726
|
|
|
675
|
-
const response = await this.sendRequest<
|
|
727
|
+
const response = await this.apiClient.sendRequest<
|
|
676
728
|
StreamResponse<StartClosedCaptionsResponse>
|
|
677
729
|
>(
|
|
678
730
|
'POST',
|
|
@@ -680,16 +732,17 @@ export class VideoApi extends BaseApi {
|
|
|
680
732
|
pathParams,
|
|
681
733
|
undefined,
|
|
682
734
|
body,
|
|
735
|
+
'application/json',
|
|
683
736
|
);
|
|
684
737
|
|
|
685
738
|
decoders.StartClosedCaptionsResponse?.(response.body);
|
|
686
739
|
|
|
687
740
|
return { ...response.body, metadata: response.metadata };
|
|
688
|
-
}
|
|
741
|
+
}
|
|
689
742
|
|
|
690
|
-
|
|
743
|
+
async startFrameRecording(
|
|
691
744
|
request: StartFrameRecordingRequest & { type: string; id: string },
|
|
692
|
-
): Promise<StreamResponse<StartFrameRecordingResponse>>
|
|
745
|
+
): Promise<StreamResponse<StartFrameRecordingResponse>> {
|
|
693
746
|
const pathParams = {
|
|
694
747
|
type: request?.type,
|
|
695
748
|
id: request?.id,
|
|
@@ -698,7 +751,7 @@ export class VideoApi extends BaseApi {
|
|
|
698
751
|
recording_external_storage: request?.recording_external_storage,
|
|
699
752
|
};
|
|
700
753
|
|
|
701
|
-
const response = await this.sendRequest<
|
|
754
|
+
const response = await this.apiClient.sendRequest<
|
|
702
755
|
StreamResponse<StartFrameRecordingResponse>
|
|
703
756
|
>(
|
|
704
757
|
'POST',
|
|
@@ -706,16 +759,17 @@ export class VideoApi extends BaseApi {
|
|
|
706
759
|
pathParams,
|
|
707
760
|
undefined,
|
|
708
761
|
body,
|
|
762
|
+
'application/json',
|
|
709
763
|
);
|
|
710
764
|
|
|
711
765
|
decoders.StartFrameRecordingResponse?.(response.body);
|
|
712
766
|
|
|
713
767
|
return { ...response.body, metadata: response.metadata };
|
|
714
|
-
}
|
|
768
|
+
}
|
|
715
769
|
|
|
716
|
-
|
|
770
|
+
async startRecording(
|
|
717
771
|
request: StartRecordingRequest & { type: string; id: string },
|
|
718
|
-
): Promise<StreamResponse<StartRecordingResponse>>
|
|
772
|
+
): Promise<StreamResponse<StartRecordingResponse>> {
|
|
719
773
|
const pathParams = {
|
|
720
774
|
type: request?.type,
|
|
721
775
|
id: request?.id,
|
|
@@ -724,7 +778,7 @@ export class VideoApi extends BaseApi {
|
|
|
724
778
|
recording_external_storage: request?.recording_external_storage,
|
|
725
779
|
};
|
|
726
780
|
|
|
727
|
-
const response = await this.sendRequest<
|
|
781
|
+
const response = await this.apiClient.sendRequest<
|
|
728
782
|
StreamResponse<StartRecordingResponse>
|
|
729
783
|
>(
|
|
730
784
|
'POST',
|
|
@@ -732,16 +786,17 @@ export class VideoApi extends BaseApi {
|
|
|
732
786
|
pathParams,
|
|
733
787
|
undefined,
|
|
734
788
|
body,
|
|
789
|
+
'application/json',
|
|
735
790
|
);
|
|
736
791
|
|
|
737
792
|
decoders.StartRecordingResponse?.(response.body);
|
|
738
793
|
|
|
739
794
|
return { ...response.body, metadata: response.metadata };
|
|
740
|
-
}
|
|
795
|
+
}
|
|
741
796
|
|
|
742
|
-
|
|
797
|
+
async startTranscription(
|
|
743
798
|
request: StartTranscriptionRequest & { type: string; id: string },
|
|
744
|
-
): Promise<StreamResponse<StartTranscriptionResponse>>
|
|
799
|
+
): Promise<StreamResponse<StartTranscriptionResponse>> {
|
|
745
800
|
const pathParams = {
|
|
746
801
|
type: request?.type,
|
|
747
802
|
id: request?.id,
|
|
@@ -752,7 +807,7 @@ export class VideoApi extends BaseApi {
|
|
|
752
807
|
transcription_external_storage: request?.transcription_external_storage,
|
|
753
808
|
};
|
|
754
809
|
|
|
755
|
-
const response = await this.sendRequest<
|
|
810
|
+
const response = await this.apiClient.sendRequest<
|
|
756
811
|
StreamResponse<StartTranscriptionResponse>
|
|
757
812
|
>(
|
|
758
813
|
'POST',
|
|
@@ -760,23 +815,24 @@ export class VideoApi extends BaseApi {
|
|
|
760
815
|
pathParams,
|
|
761
816
|
undefined,
|
|
762
817
|
body,
|
|
818
|
+
'application/json',
|
|
763
819
|
);
|
|
764
820
|
|
|
765
821
|
decoders.StartTranscriptionResponse?.(response.body);
|
|
766
822
|
|
|
767
823
|
return { ...response.body, metadata: response.metadata };
|
|
768
|
-
}
|
|
824
|
+
}
|
|
769
825
|
|
|
770
|
-
|
|
826
|
+
async stopHLSBroadcasting(request: {
|
|
771
827
|
type: string;
|
|
772
828
|
id: string;
|
|
773
|
-
}): Promise<StreamResponse<StopHLSBroadcastingResponse>>
|
|
829
|
+
}): Promise<StreamResponse<StopHLSBroadcastingResponse>> {
|
|
774
830
|
const pathParams = {
|
|
775
831
|
type: request?.type,
|
|
776
832
|
id: request?.id,
|
|
777
833
|
};
|
|
778
834
|
|
|
779
|
-
const response = await this.sendRequest<
|
|
835
|
+
const response = await this.apiClient.sendRequest<
|
|
780
836
|
StreamResponse<StopHLSBroadcastingResponse>
|
|
781
837
|
>(
|
|
782
838
|
'POST',
|
|
@@ -788,11 +844,11 @@ export class VideoApi extends BaseApi {
|
|
|
788
844
|
decoders.StopHLSBroadcastingResponse?.(response.body);
|
|
789
845
|
|
|
790
846
|
return { ...response.body, metadata: response.metadata };
|
|
791
|
-
}
|
|
847
|
+
}
|
|
792
848
|
|
|
793
|
-
|
|
849
|
+
async stopClosedCaptions(
|
|
794
850
|
request: StopClosedCaptionsRequest & { type: string; id: string },
|
|
795
|
-
): Promise<StreamResponse<StopClosedCaptionsResponse>>
|
|
851
|
+
): Promise<StreamResponse<StopClosedCaptionsResponse>> {
|
|
796
852
|
const pathParams = {
|
|
797
853
|
type: request?.type,
|
|
798
854
|
id: request?.id,
|
|
@@ -801,7 +857,7 @@ export class VideoApi extends BaseApi {
|
|
|
801
857
|
stop_transcription: request?.stop_transcription,
|
|
802
858
|
};
|
|
803
859
|
|
|
804
|
-
const response = await this.sendRequest<
|
|
860
|
+
const response = await this.apiClient.sendRequest<
|
|
805
861
|
StreamResponse<StopClosedCaptionsResponse>
|
|
806
862
|
>(
|
|
807
863
|
'POST',
|
|
@@ -809,23 +865,24 @@ export class VideoApi extends BaseApi {
|
|
|
809
865
|
pathParams,
|
|
810
866
|
undefined,
|
|
811
867
|
body,
|
|
868
|
+
'application/json',
|
|
812
869
|
);
|
|
813
870
|
|
|
814
871
|
decoders.StopClosedCaptionsResponse?.(response.body);
|
|
815
872
|
|
|
816
873
|
return { ...response.body, metadata: response.metadata };
|
|
817
|
-
}
|
|
874
|
+
}
|
|
818
875
|
|
|
819
|
-
|
|
876
|
+
async stopFrameRecording(request: {
|
|
820
877
|
type: string;
|
|
821
878
|
id: string;
|
|
822
|
-
}): Promise<StreamResponse<StopFrameRecordingResponse>>
|
|
879
|
+
}): Promise<StreamResponse<StopFrameRecordingResponse>> {
|
|
823
880
|
const pathParams = {
|
|
824
881
|
type: request?.type,
|
|
825
882
|
id: request?.id,
|
|
826
883
|
};
|
|
827
884
|
|
|
828
|
-
const response = await this.sendRequest<
|
|
885
|
+
const response = await this.apiClient.sendRequest<
|
|
829
886
|
StreamResponse<StopFrameRecordingResponse>
|
|
830
887
|
>(
|
|
831
888
|
'POST',
|
|
@@ -837,11 +894,11 @@ export class VideoApi extends BaseApi {
|
|
|
837
894
|
decoders.StopFrameRecordingResponse?.(response.body);
|
|
838
895
|
|
|
839
896
|
return { ...response.body, metadata: response.metadata };
|
|
840
|
-
}
|
|
897
|
+
}
|
|
841
898
|
|
|
842
|
-
|
|
899
|
+
async stopLive(
|
|
843
900
|
request: StopLiveRequest & { type: string; id: string },
|
|
844
|
-
): Promise<StreamResponse<StopLiveResponse>>
|
|
901
|
+
): Promise<StreamResponse<StopLiveResponse>> {
|
|
845
902
|
const pathParams = {
|
|
846
903
|
type: request?.type,
|
|
847
904
|
id: request?.id,
|
|
@@ -854,29 +911,32 @@ export class VideoApi extends BaseApi {
|
|
|
854
911
|
continue_transcription: request?.continue_transcription,
|
|
855
912
|
};
|
|
856
913
|
|
|
857
|
-
const response = await this.sendRequest<
|
|
914
|
+
const response = await this.apiClient.sendRequest<
|
|
915
|
+
StreamResponse<StopLiveResponse>
|
|
916
|
+
>(
|
|
858
917
|
'POST',
|
|
859
918
|
'/api/v2/video/call/{type}/{id}/stop_live',
|
|
860
919
|
pathParams,
|
|
861
920
|
undefined,
|
|
862
921
|
body,
|
|
922
|
+
'application/json',
|
|
863
923
|
);
|
|
864
924
|
|
|
865
925
|
decoders.StopLiveResponse?.(response.body);
|
|
866
926
|
|
|
867
927
|
return { ...response.body, metadata: response.metadata };
|
|
868
|
-
}
|
|
928
|
+
}
|
|
869
929
|
|
|
870
|
-
|
|
930
|
+
async stopRecording(request: {
|
|
871
931
|
type: string;
|
|
872
932
|
id: string;
|
|
873
|
-
}): Promise<StreamResponse<StopRecordingResponse>>
|
|
933
|
+
}): Promise<StreamResponse<StopRecordingResponse>> {
|
|
874
934
|
const pathParams = {
|
|
875
935
|
type: request?.type,
|
|
876
936
|
id: request?.id,
|
|
877
937
|
};
|
|
878
938
|
|
|
879
|
-
const response = await this.sendRequest<
|
|
939
|
+
const response = await this.apiClient.sendRequest<
|
|
880
940
|
StreamResponse<StopRecordingResponse>
|
|
881
941
|
>(
|
|
882
942
|
'POST',
|
|
@@ -888,11 +948,11 @@ export class VideoApi extends BaseApi {
|
|
|
888
948
|
decoders.StopRecordingResponse?.(response.body);
|
|
889
949
|
|
|
890
950
|
return { ...response.body, metadata: response.metadata };
|
|
891
|
-
}
|
|
951
|
+
}
|
|
892
952
|
|
|
893
|
-
|
|
953
|
+
async stopTranscription(
|
|
894
954
|
request: StopTranscriptionRequest & { type: string; id: string },
|
|
895
|
-
): Promise<StreamResponse<StopTranscriptionResponse>>
|
|
955
|
+
): Promise<StreamResponse<StopTranscriptionResponse>> {
|
|
896
956
|
const pathParams = {
|
|
897
957
|
type: request?.type,
|
|
898
958
|
id: request?.id,
|
|
@@ -901,7 +961,7 @@ export class VideoApi extends BaseApi {
|
|
|
901
961
|
stop_closed_captions: request?.stop_closed_captions,
|
|
902
962
|
};
|
|
903
963
|
|
|
904
|
-
const response = await this.sendRequest<
|
|
964
|
+
const response = await this.apiClient.sendRequest<
|
|
905
965
|
StreamResponse<StopTranscriptionResponse>
|
|
906
966
|
>(
|
|
907
967
|
'POST',
|
|
@@ -909,23 +969,24 @@ export class VideoApi extends BaseApi {
|
|
|
909
969
|
pathParams,
|
|
910
970
|
undefined,
|
|
911
971
|
body,
|
|
972
|
+
'application/json',
|
|
912
973
|
);
|
|
913
974
|
|
|
914
975
|
decoders.StopTranscriptionResponse?.(response.body);
|
|
915
976
|
|
|
916
977
|
return { ...response.body, metadata: response.metadata };
|
|
917
|
-
}
|
|
978
|
+
}
|
|
918
979
|
|
|
919
|
-
|
|
980
|
+
async listTranscriptions(request: {
|
|
920
981
|
type: string;
|
|
921
982
|
id: string;
|
|
922
|
-
}): Promise<StreamResponse<ListTranscriptionsResponse>>
|
|
983
|
+
}): Promise<StreamResponse<ListTranscriptionsResponse>> {
|
|
923
984
|
const pathParams = {
|
|
924
985
|
type: request?.type,
|
|
925
986
|
id: request?.id,
|
|
926
987
|
};
|
|
927
988
|
|
|
928
|
-
const response = await this.sendRequest<
|
|
989
|
+
const response = await this.apiClient.sendRequest<
|
|
929
990
|
StreamResponse<ListTranscriptionsResponse>
|
|
930
991
|
>(
|
|
931
992
|
'GET',
|
|
@@ -937,11 +998,11 @@ export class VideoApi extends BaseApi {
|
|
|
937
998
|
decoders.ListTranscriptionsResponse?.(response.body);
|
|
938
999
|
|
|
939
1000
|
return { ...response.body, metadata: response.metadata };
|
|
940
|
-
}
|
|
1001
|
+
}
|
|
941
1002
|
|
|
942
|
-
|
|
1003
|
+
async unblockUser(
|
|
943
1004
|
request: UnblockUserRequest & { type: string; id: string },
|
|
944
|
-
): Promise<StreamResponse<UnblockUserResponse>>
|
|
1005
|
+
): Promise<StreamResponse<UnblockUserResponse>> {
|
|
945
1006
|
const pathParams = {
|
|
946
1007
|
type: request?.type,
|
|
947
1008
|
id: request?.id,
|
|
@@ -950,7 +1011,7 @@ export class VideoApi extends BaseApi {
|
|
|
950
1011
|
user_id: request?.user_id,
|
|
951
1012
|
};
|
|
952
1013
|
|
|
953
|
-
const response = await this.sendRequest<
|
|
1014
|
+
const response = await this.apiClient.sendRequest<
|
|
954
1015
|
StreamResponse<UnblockUserResponse>
|
|
955
1016
|
>(
|
|
956
1017
|
'POST',
|
|
@@ -958,16 +1019,17 @@ export class VideoApi extends BaseApi {
|
|
|
958
1019
|
pathParams,
|
|
959
1020
|
undefined,
|
|
960
1021
|
body,
|
|
1022
|
+
'application/json',
|
|
961
1023
|
);
|
|
962
1024
|
|
|
963
1025
|
decoders.UnblockUserResponse?.(response.body);
|
|
964
1026
|
|
|
965
1027
|
return { ...response.body, metadata: response.metadata };
|
|
966
|
-
}
|
|
1028
|
+
}
|
|
967
1029
|
|
|
968
|
-
|
|
1030
|
+
async videoUnpin(
|
|
969
1031
|
request: UnpinRequest & { type: string; id: string },
|
|
970
|
-
): Promise<StreamResponse<UnpinResponse>>
|
|
1032
|
+
): Promise<StreamResponse<UnpinResponse>> {
|
|
971
1033
|
const pathParams = {
|
|
972
1034
|
type: request?.type,
|
|
973
1035
|
id: request?.id,
|
|
@@ -977,22 +1039,25 @@ export class VideoApi extends BaseApi {
|
|
|
977
1039
|
user_id: request?.user_id,
|
|
978
1040
|
};
|
|
979
1041
|
|
|
980
|
-
const response = await this.sendRequest<
|
|
1042
|
+
const response = await this.apiClient.sendRequest<
|
|
1043
|
+
StreamResponse<UnpinResponse>
|
|
1044
|
+
>(
|
|
981
1045
|
'POST',
|
|
982
1046
|
'/api/v2/video/call/{type}/{id}/unpin',
|
|
983
1047
|
pathParams,
|
|
984
1048
|
undefined,
|
|
985
1049
|
body,
|
|
1050
|
+
'application/json',
|
|
986
1051
|
);
|
|
987
1052
|
|
|
988
1053
|
decoders.UnpinResponse?.(response.body);
|
|
989
1054
|
|
|
990
1055
|
return { ...response.body, metadata: response.metadata };
|
|
991
|
-
}
|
|
1056
|
+
}
|
|
992
1057
|
|
|
993
|
-
|
|
1058
|
+
async updateUserPermissions(
|
|
994
1059
|
request: UpdateUserPermissionsRequest & { type: string; id: string },
|
|
995
|
-
): Promise<StreamResponse<UpdateUserPermissionsResponse>>
|
|
1060
|
+
): Promise<StreamResponse<UpdateUserPermissionsResponse>> {
|
|
996
1061
|
const pathParams = {
|
|
997
1062
|
type: request?.type,
|
|
998
1063
|
id: request?.id,
|
|
@@ -1003,7 +1068,7 @@ export class VideoApi extends BaseApi {
|
|
|
1003
1068
|
revoke_permissions: request?.revoke_permissions,
|
|
1004
1069
|
};
|
|
1005
1070
|
|
|
1006
|
-
const response = await this.sendRequest<
|
|
1071
|
+
const response = await this.apiClient.sendRequest<
|
|
1007
1072
|
StreamResponse<UpdateUserPermissionsResponse>
|
|
1008
1073
|
>(
|
|
1009
1074
|
'POST',
|
|
@@ -1011,19 +1076,20 @@ export class VideoApi extends BaseApi {
|
|
|
1011
1076
|
pathParams,
|
|
1012
1077
|
undefined,
|
|
1013
1078
|
body,
|
|
1079
|
+
'application/json',
|
|
1014
1080
|
);
|
|
1015
1081
|
|
|
1016
1082
|
decoders.UpdateUserPermissionsResponse?.(response.body);
|
|
1017
1083
|
|
|
1018
1084
|
return { ...response.body, metadata: response.metadata };
|
|
1019
|
-
}
|
|
1085
|
+
}
|
|
1020
1086
|
|
|
1021
|
-
|
|
1087
|
+
async deleteRecording(request: {
|
|
1022
1088
|
type: string;
|
|
1023
1089
|
id: string;
|
|
1024
1090
|
session: string;
|
|
1025
1091
|
filename: string;
|
|
1026
|
-
}): Promise<StreamResponse<DeleteRecordingResponse>>
|
|
1092
|
+
}): Promise<StreamResponse<DeleteRecordingResponse>> {
|
|
1027
1093
|
const pathParams = {
|
|
1028
1094
|
type: request?.type,
|
|
1029
1095
|
id: request?.id,
|
|
@@ -1031,7 +1097,7 @@ export class VideoApi extends BaseApi {
|
|
|
1031
1097
|
filename: request?.filename,
|
|
1032
1098
|
};
|
|
1033
1099
|
|
|
1034
|
-
const response = await this.sendRequest<
|
|
1100
|
+
const response = await this.apiClient.sendRequest<
|
|
1035
1101
|
StreamResponse<DeleteRecordingResponse>
|
|
1036
1102
|
>(
|
|
1037
1103
|
'DELETE',
|
|
@@ -1043,14 +1109,14 @@ export class VideoApi extends BaseApi {
|
|
|
1043
1109
|
decoders.DeleteRecordingResponse?.(response.body);
|
|
1044
1110
|
|
|
1045
1111
|
return { ...response.body, metadata: response.metadata };
|
|
1046
|
-
}
|
|
1112
|
+
}
|
|
1047
1113
|
|
|
1048
|
-
|
|
1114
|
+
async deleteTranscription(request: {
|
|
1049
1115
|
type: string;
|
|
1050
1116
|
id: string;
|
|
1051
1117
|
session: string;
|
|
1052
1118
|
filename: string;
|
|
1053
|
-
}): Promise<StreamResponse<DeleteTranscriptionResponse>>
|
|
1119
|
+
}): Promise<StreamResponse<DeleteTranscriptionResponse>> {
|
|
1054
1120
|
const pathParams = {
|
|
1055
1121
|
type: request?.type,
|
|
1056
1122
|
id: request?.id,
|
|
@@ -1058,7 +1124,7 @@ export class VideoApi extends BaseApi {
|
|
|
1058
1124
|
filename: request?.filename,
|
|
1059
1125
|
};
|
|
1060
1126
|
|
|
1061
|
-
const response = await this.sendRequest<
|
|
1127
|
+
const response = await this.apiClient.sendRequest<
|
|
1062
1128
|
StreamResponse<DeleteTranscriptionResponse>
|
|
1063
1129
|
>(
|
|
1064
1130
|
'DELETE',
|
|
@@ -1070,11 +1136,11 @@ export class VideoApi extends BaseApi {
|
|
|
1070
1136
|
decoders.DeleteTranscriptionResponse?.(response.body);
|
|
1071
1137
|
|
|
1072
1138
|
return { ...response.body, metadata: response.metadata };
|
|
1073
|
-
}
|
|
1139
|
+
}
|
|
1074
1140
|
|
|
1075
|
-
|
|
1141
|
+
async queryCalls(
|
|
1076
1142
|
request?: QueryCallsRequest,
|
|
1077
|
-
): Promise<StreamResponse<QueryCallsResponse>>
|
|
1143
|
+
): Promise<StreamResponse<QueryCallsResponse>> {
|
|
1078
1144
|
const body = {
|
|
1079
1145
|
limit: request?.limit,
|
|
1080
1146
|
next: request?.next,
|
|
@@ -1083,32 +1149,35 @@ export class VideoApi extends BaseApi {
|
|
|
1083
1149
|
filter_conditions: request?.filter_conditions,
|
|
1084
1150
|
};
|
|
1085
1151
|
|
|
1086
|
-
const response = await this.sendRequest<
|
|
1152
|
+
const response = await this.apiClient.sendRequest<
|
|
1153
|
+
StreamResponse<QueryCallsResponse>
|
|
1154
|
+
>(
|
|
1087
1155
|
'POST',
|
|
1088
1156
|
'/api/v2/video/calls',
|
|
1089
1157
|
undefined,
|
|
1090
1158
|
undefined,
|
|
1091
1159
|
body,
|
|
1160
|
+
'application/json',
|
|
1092
1161
|
);
|
|
1093
1162
|
|
|
1094
1163
|
decoders.QueryCallsResponse?.(response.body);
|
|
1095
1164
|
|
|
1096
1165
|
return { ...response.body, metadata: response.metadata };
|
|
1097
|
-
}
|
|
1166
|
+
}
|
|
1098
1167
|
|
|
1099
|
-
|
|
1100
|
-
const response = await this.sendRequest<
|
|
1168
|
+
async listCallTypes(): Promise<StreamResponse<ListCallTypeResponse>> {
|
|
1169
|
+
const response = await this.apiClient.sendRequest<
|
|
1101
1170
|
StreamResponse<ListCallTypeResponse>
|
|
1102
1171
|
>('GET', '/api/v2/video/calltypes', undefined, undefined);
|
|
1103
1172
|
|
|
1104
1173
|
decoders.ListCallTypeResponse?.(response.body);
|
|
1105
1174
|
|
|
1106
1175
|
return { ...response.body, metadata: response.metadata };
|
|
1107
|
-
}
|
|
1176
|
+
}
|
|
1108
1177
|
|
|
1109
|
-
|
|
1178
|
+
async createCallType(
|
|
1110
1179
|
request: CreateCallTypeRequest,
|
|
1111
|
-
): Promise<StreamResponse<CreateCallTypeResponse>>
|
|
1180
|
+
): Promise<StreamResponse<CreateCallTypeResponse>> {
|
|
1112
1181
|
const body = {
|
|
1113
1182
|
name: request?.name,
|
|
1114
1183
|
external_storage: request?.external_storage,
|
|
@@ -1117,23 +1186,30 @@ export class VideoApi extends BaseApi {
|
|
|
1117
1186
|
settings: request?.settings,
|
|
1118
1187
|
};
|
|
1119
1188
|
|
|
1120
|
-
const response = await this.sendRequest<
|
|
1189
|
+
const response = await this.apiClient.sendRequest<
|
|
1121
1190
|
StreamResponse<CreateCallTypeResponse>
|
|
1122
|
-
>(
|
|
1191
|
+
>(
|
|
1192
|
+
'POST',
|
|
1193
|
+
'/api/v2/video/calltypes',
|
|
1194
|
+
undefined,
|
|
1195
|
+
undefined,
|
|
1196
|
+
body,
|
|
1197
|
+
'application/json',
|
|
1198
|
+
);
|
|
1123
1199
|
|
|
1124
1200
|
decoders.CreateCallTypeResponse?.(response.body);
|
|
1125
1201
|
|
|
1126
1202
|
return { ...response.body, metadata: response.metadata };
|
|
1127
|
-
}
|
|
1203
|
+
}
|
|
1128
1204
|
|
|
1129
|
-
|
|
1205
|
+
async deleteCallType(request: {
|
|
1130
1206
|
name: string;
|
|
1131
|
-
}): Promise<StreamResponse<Response>>
|
|
1207
|
+
}): Promise<StreamResponse<Response>> {
|
|
1132
1208
|
const pathParams = {
|
|
1133
1209
|
name: request?.name,
|
|
1134
1210
|
};
|
|
1135
1211
|
|
|
1136
|
-
const response = await this.sendRequest<StreamResponse<Response>>(
|
|
1212
|
+
const response = await this.apiClient.sendRequest<StreamResponse<Response>>(
|
|
1137
1213
|
'DELETE',
|
|
1138
1214
|
'/api/v2/video/calltypes/{name}',
|
|
1139
1215
|
pathParams,
|
|
@@ -1143,27 +1219,27 @@ export class VideoApi extends BaseApi {
|
|
|
1143
1219
|
decoders.Response?.(response.body);
|
|
1144
1220
|
|
|
1145
1221
|
return { ...response.body, metadata: response.metadata };
|
|
1146
|
-
}
|
|
1222
|
+
}
|
|
1147
1223
|
|
|
1148
|
-
|
|
1224
|
+
async getCallType(request: {
|
|
1149
1225
|
name: string;
|
|
1150
|
-
}): Promise<StreamResponse<GetCallTypeResponse>>
|
|
1226
|
+
}): Promise<StreamResponse<GetCallTypeResponse>> {
|
|
1151
1227
|
const pathParams = {
|
|
1152
1228
|
name: request?.name,
|
|
1153
1229
|
};
|
|
1154
1230
|
|
|
1155
|
-
const response = await this.sendRequest<
|
|
1231
|
+
const response = await this.apiClient.sendRequest<
|
|
1156
1232
|
StreamResponse<GetCallTypeResponse>
|
|
1157
1233
|
>('GET', '/api/v2/video/calltypes/{name}', pathParams, undefined);
|
|
1158
1234
|
|
|
1159
1235
|
decoders.GetCallTypeResponse?.(response.body);
|
|
1160
1236
|
|
|
1161
1237
|
return { ...response.body, metadata: response.metadata };
|
|
1162
|
-
}
|
|
1238
|
+
}
|
|
1163
1239
|
|
|
1164
|
-
|
|
1240
|
+
async updateCallType(
|
|
1165
1241
|
request: UpdateCallTypeRequest & { name: string },
|
|
1166
|
-
): Promise<StreamResponse<UpdateCallTypeResponse>>
|
|
1242
|
+
): Promise<StreamResponse<UpdateCallTypeResponse>> {
|
|
1167
1243
|
const pathParams = {
|
|
1168
1244
|
name: request?.name,
|
|
1169
1245
|
};
|
|
@@ -1174,43 +1250,54 @@ export class VideoApi extends BaseApi {
|
|
|
1174
1250
|
settings: request?.settings,
|
|
1175
1251
|
};
|
|
1176
1252
|
|
|
1177
|
-
const response = await this.sendRequest<
|
|
1253
|
+
const response = await this.apiClient.sendRequest<
|
|
1178
1254
|
StreamResponse<UpdateCallTypeResponse>
|
|
1179
|
-
>(
|
|
1255
|
+
>(
|
|
1256
|
+
'PUT',
|
|
1257
|
+
'/api/v2/video/calltypes/{name}',
|
|
1258
|
+
pathParams,
|
|
1259
|
+
undefined,
|
|
1260
|
+
body,
|
|
1261
|
+
'application/json',
|
|
1262
|
+
);
|
|
1180
1263
|
|
|
1181
1264
|
decoders.UpdateCallTypeResponse?.(response.body);
|
|
1182
1265
|
|
|
1183
1266
|
return { ...response.body, metadata: response.metadata };
|
|
1184
|
-
}
|
|
1267
|
+
}
|
|
1185
1268
|
|
|
1186
|
-
|
|
1187
|
-
const response = await this.sendRequest<
|
|
1188
|
-
|
|
1189
|
-
|
|
1190
|
-
undefined,
|
|
1191
|
-
undefined,
|
|
1192
|
-
);
|
|
1269
|
+
async getEdges(): Promise<StreamResponse<GetEdgesResponse>> {
|
|
1270
|
+
const response = await this.apiClient.sendRequest<
|
|
1271
|
+
StreamResponse<GetEdgesResponse>
|
|
1272
|
+
>('GET', '/api/v2/video/edges', undefined, undefined);
|
|
1193
1273
|
|
|
1194
1274
|
decoders.GetEdgesResponse?.(response.body);
|
|
1195
1275
|
|
|
1196
1276
|
return { ...response.body, metadata: response.metadata };
|
|
1197
|
-
}
|
|
1277
|
+
}
|
|
1198
1278
|
|
|
1199
|
-
|
|
1279
|
+
async queryAggregateCallStats(
|
|
1200
1280
|
request?: QueryAggregateCallStatsRequest,
|
|
1201
|
-
): Promise<StreamResponse<QueryAggregateCallStatsResponse>>
|
|
1281
|
+
): Promise<StreamResponse<QueryAggregateCallStatsResponse>> {
|
|
1202
1282
|
const body = {
|
|
1203
1283
|
from: request?.from,
|
|
1204
1284
|
to: request?.to,
|
|
1205
1285
|
report_types: request?.report_types,
|
|
1206
1286
|
};
|
|
1207
1287
|
|
|
1208
|
-
const response = await this.sendRequest<
|
|
1288
|
+
const response = await this.apiClient.sendRequest<
|
|
1209
1289
|
StreamResponse<QueryAggregateCallStatsResponse>
|
|
1210
|
-
>(
|
|
1290
|
+
>(
|
|
1291
|
+
'POST',
|
|
1292
|
+
'/api/v2/video/stats',
|
|
1293
|
+
undefined,
|
|
1294
|
+
undefined,
|
|
1295
|
+
body,
|
|
1296
|
+
'application/json',
|
|
1297
|
+
);
|
|
1211
1298
|
|
|
1212
1299
|
decoders.QueryAggregateCallStatsResponse?.(response.body);
|
|
1213
1300
|
|
|
1214
1301
|
return { ...response.body, metadata: response.metadata };
|
|
1215
|
-
}
|
|
1302
|
+
}
|
|
1216
1303
|
}
|