@stream-io/node-sdk 0.7.40 → 0.7.41
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 +280 -268
- package/dist/index.cjs.js.map +1 -1
- package/dist/index.es.mjs +280 -268
- package/dist/index.es.mjs.map +1 -1
- package/dist/src/gen/chat/ChatApi.d.ts +4 -4
- package/dist/src/gen/feeds/FeedsApi.d.ts +2 -1
- package/dist/src/gen/models/index.d.ts +705 -572
- package/dist/src/gen/video/CallApi.d.ts +14 -3
- package/dist/src/gen/video/VideoApi.d.ts +20 -9
- package/package.json +1 -1
- package/src/gen/chat/ChatApi.ts +14 -10
- package/src/gen/feeds/FeedsApi.ts +36 -0
- package/src/gen/model-decoders/decoders.ts +266 -306
- package/src/gen/models/index.ts +1178 -918
- package/src/gen/moderation/ModerationApi.ts +1 -0
- package/src/gen/video/CallApi.ts +35 -20
- package/src/gen/video/VideoApi.ts +98 -52
|
@@ -670,6 +670,7 @@ export class ModerationApi {
|
|
|
670
670
|
delete_message: request?.delete_message,
|
|
671
671
|
delete_reaction: request?.delete_reaction,
|
|
672
672
|
delete_user: request?.delete_user,
|
|
673
|
+
flag: request?.flag,
|
|
673
674
|
mark_reviewed: request?.mark_reviewed,
|
|
674
675
|
reject_appeal: request?.reject_appeal,
|
|
675
676
|
restore: request?.restore,
|
package/src/gen/video/CallApi.ts
CHANGED
|
@@ -9,6 +9,7 @@ import {
|
|
|
9
9
|
DeleteRecordingResponse,
|
|
10
10
|
DeleteTranscriptionResponse,
|
|
11
11
|
EndCallResponse,
|
|
12
|
+
GetCallParticipantSessionMetricsResponse,
|
|
12
13
|
GetCallReportResponse,
|
|
13
14
|
GetCallResponse,
|
|
14
15
|
GetOrCreateCallRequest,
|
|
@@ -206,6 +207,26 @@ export class CallApi {
|
|
|
206
207
|
return this.videoApi.listRecordings({ id: this.id, type: this.type });
|
|
207
208
|
}
|
|
208
209
|
|
|
210
|
+
startRecording(
|
|
211
|
+
request: StartRecordingRequest & { recording_type: string },
|
|
212
|
+
): Promise<StreamResponse<StartRecordingResponse>> {
|
|
213
|
+
return this.videoApi.startRecording({
|
|
214
|
+
id: this.id,
|
|
215
|
+
type: this.type,
|
|
216
|
+
...request,
|
|
217
|
+
});
|
|
218
|
+
}
|
|
219
|
+
|
|
220
|
+
stopRecording(
|
|
221
|
+
request: StopRecordingRequest & { recording_type: string },
|
|
222
|
+
): Promise<StreamResponse<StopRecordingResponse>> {
|
|
223
|
+
return this.videoApi.stopRecording({
|
|
224
|
+
id: this.id,
|
|
225
|
+
type: this.type,
|
|
226
|
+
...request,
|
|
227
|
+
});
|
|
228
|
+
}
|
|
229
|
+
|
|
209
230
|
getCallReport(request?: {
|
|
210
231
|
session_id?: string;
|
|
211
232
|
}): Promise<StreamResponse<GetCallReportResponse>> {
|
|
@@ -249,6 +270,20 @@ export class CallApi {
|
|
|
249
270
|
});
|
|
250
271
|
}
|
|
251
272
|
|
|
273
|
+
getCallParticipantSessionMetrics(request: {
|
|
274
|
+
session: string;
|
|
275
|
+
user: string;
|
|
276
|
+
user_session: string;
|
|
277
|
+
since?: Date;
|
|
278
|
+
until?: Date;
|
|
279
|
+
}): Promise<StreamResponse<GetCallParticipantSessionMetricsResponse>> {
|
|
280
|
+
return this.videoApi.getCallParticipantSessionMetrics({
|
|
281
|
+
id: this.id,
|
|
282
|
+
type: this.type,
|
|
283
|
+
...request,
|
|
284
|
+
});
|
|
285
|
+
}
|
|
286
|
+
|
|
252
287
|
queryCallParticipantSessions(request: {
|
|
253
288
|
session: string;
|
|
254
289
|
limit?: number;
|
|
@@ -289,16 +324,6 @@ export class CallApi {
|
|
|
289
324
|
});
|
|
290
325
|
}
|
|
291
326
|
|
|
292
|
-
startRecording(
|
|
293
|
-
request?: StartRecordingRequest,
|
|
294
|
-
): Promise<StreamResponse<StartRecordingResponse>> {
|
|
295
|
-
return this.videoApi.startRecording({
|
|
296
|
-
id: this.id,
|
|
297
|
-
type: this.type,
|
|
298
|
-
...request,
|
|
299
|
-
});
|
|
300
|
-
}
|
|
301
|
-
|
|
302
327
|
startTranscription(
|
|
303
328
|
request?: StartTranscriptionRequest,
|
|
304
329
|
): Promise<StreamResponse<StartTranscriptionResponse>> {
|
|
@@ -333,16 +358,6 @@ export class CallApi {
|
|
|
333
358
|
return this.videoApi.stopLive({ id: this.id, type: this.type, ...request });
|
|
334
359
|
}
|
|
335
360
|
|
|
336
|
-
stopRecording(
|
|
337
|
-
request?: StopRecordingRequest,
|
|
338
|
-
): Promise<StreamResponse<StopRecordingResponse>> {
|
|
339
|
-
return this.videoApi.stopRecording({
|
|
340
|
-
id: this.id,
|
|
341
|
-
type: this.type,
|
|
342
|
-
...request,
|
|
343
|
-
});
|
|
344
|
-
}
|
|
345
|
-
|
|
346
361
|
stopTranscription(
|
|
347
362
|
request?: StopTranscriptionRequest,
|
|
348
363
|
): Promise<StreamResponse<StopTranscriptionResponse>> {
|
|
@@ -16,6 +16,7 @@ import {
|
|
|
16
16
|
DeleteTranscriptionResponse,
|
|
17
17
|
EndCallResponse,
|
|
18
18
|
GetActiveCallsStatusResponse,
|
|
19
|
+
GetCallParticipantSessionMetricsResponse,
|
|
19
20
|
GetCallReportResponse,
|
|
20
21
|
GetCallResponse,
|
|
21
22
|
GetCallSessionParticipantStatsDetailsResponse,
|
|
@@ -681,6 +682,68 @@ export class VideoApi {
|
|
|
681
682
|
return { ...response.body, metadata: response.metadata };
|
|
682
683
|
}
|
|
683
684
|
|
|
685
|
+
async startRecording(
|
|
686
|
+
request: StartRecordingRequest & {
|
|
687
|
+
type: string;
|
|
688
|
+
id: string;
|
|
689
|
+
recording_type: string;
|
|
690
|
+
},
|
|
691
|
+
): Promise<StreamResponse<StartRecordingResponse>> {
|
|
692
|
+
const pathParams = {
|
|
693
|
+
type: request?.type,
|
|
694
|
+
id: request?.id,
|
|
695
|
+
recording_type: request?.recording_type,
|
|
696
|
+
};
|
|
697
|
+
const body = {
|
|
698
|
+
recording_external_storage: request?.recording_external_storage,
|
|
699
|
+
};
|
|
700
|
+
|
|
701
|
+
const response = await this.apiClient.sendRequest<
|
|
702
|
+
StreamResponse<StartRecordingResponse>
|
|
703
|
+
>(
|
|
704
|
+
'POST',
|
|
705
|
+
'/api/v2/video/call/{type}/{id}/recordings/{recording_type}/start',
|
|
706
|
+
pathParams,
|
|
707
|
+
undefined,
|
|
708
|
+
body,
|
|
709
|
+
'application/json',
|
|
710
|
+
);
|
|
711
|
+
|
|
712
|
+
decoders.StartRecordingResponse?.(response.body);
|
|
713
|
+
|
|
714
|
+
return { ...response.body, metadata: response.metadata };
|
|
715
|
+
}
|
|
716
|
+
|
|
717
|
+
async stopRecording(
|
|
718
|
+
request: StopRecordingRequest & {
|
|
719
|
+
type: string;
|
|
720
|
+
id: string;
|
|
721
|
+
recording_type: string;
|
|
722
|
+
},
|
|
723
|
+
): Promise<StreamResponse<StopRecordingResponse>> {
|
|
724
|
+
const pathParams = {
|
|
725
|
+
type: request?.type,
|
|
726
|
+
id: request?.id,
|
|
727
|
+
recording_type: request?.recording_type,
|
|
728
|
+
};
|
|
729
|
+
const body = {};
|
|
730
|
+
|
|
731
|
+
const response = await this.apiClient.sendRequest<
|
|
732
|
+
StreamResponse<StopRecordingResponse>
|
|
733
|
+
>(
|
|
734
|
+
'POST',
|
|
735
|
+
'/api/v2/video/call/{type}/{id}/recordings/{recording_type}/stop',
|
|
736
|
+
pathParams,
|
|
737
|
+
undefined,
|
|
738
|
+
body,
|
|
739
|
+
'application/json',
|
|
740
|
+
);
|
|
741
|
+
|
|
742
|
+
decoders.StopRecordingResponse?.(response.body);
|
|
743
|
+
|
|
744
|
+
return { ...response.body, metadata: response.metadata };
|
|
745
|
+
}
|
|
746
|
+
|
|
684
747
|
async getCallReport(request: {
|
|
685
748
|
type: string;
|
|
686
749
|
id: string;
|
|
@@ -811,6 +874,41 @@ export class VideoApi {
|
|
|
811
874
|
return { ...response.body, metadata: response.metadata };
|
|
812
875
|
}
|
|
813
876
|
|
|
877
|
+
async getCallParticipantSessionMetrics(request: {
|
|
878
|
+
type: string;
|
|
879
|
+
id: string;
|
|
880
|
+
session: string;
|
|
881
|
+
user: string;
|
|
882
|
+
user_session: string;
|
|
883
|
+
since?: Date;
|
|
884
|
+
until?: Date;
|
|
885
|
+
}): Promise<StreamResponse<GetCallParticipantSessionMetricsResponse>> {
|
|
886
|
+
const queryParams = {
|
|
887
|
+
since: request?.since,
|
|
888
|
+
until: request?.until,
|
|
889
|
+
};
|
|
890
|
+
const pathParams = {
|
|
891
|
+
type: request?.type,
|
|
892
|
+
id: request?.id,
|
|
893
|
+
session: request?.session,
|
|
894
|
+
user: request?.user,
|
|
895
|
+
user_session: request?.user_session,
|
|
896
|
+
};
|
|
897
|
+
|
|
898
|
+
const response = await this.apiClient.sendRequest<
|
|
899
|
+
StreamResponse<GetCallParticipantSessionMetricsResponse>
|
|
900
|
+
>(
|
|
901
|
+
'GET',
|
|
902
|
+
'/api/v2/video/call/{type}/{id}/session/{session}/participant/{user}/{user_session}/details/track',
|
|
903
|
+
pathParams,
|
|
904
|
+
queryParams,
|
|
905
|
+
);
|
|
906
|
+
|
|
907
|
+
decoders.GetCallParticipantSessionMetricsResponse?.(response.body);
|
|
908
|
+
|
|
909
|
+
return { ...response.body, metadata: response.metadata };
|
|
910
|
+
}
|
|
911
|
+
|
|
814
912
|
async queryCallParticipantSessions(request: {
|
|
815
913
|
type: string;
|
|
816
914
|
id: string;
|
|
@@ -926,33 +1024,6 @@ export class VideoApi {
|
|
|
926
1024
|
return { ...response.body, metadata: response.metadata };
|
|
927
1025
|
}
|
|
928
1026
|
|
|
929
|
-
async startRecording(
|
|
930
|
-
request: StartRecordingRequest & { type: string; id: string },
|
|
931
|
-
): Promise<StreamResponse<StartRecordingResponse>> {
|
|
932
|
-
const pathParams = {
|
|
933
|
-
type: request?.type,
|
|
934
|
-
id: request?.id,
|
|
935
|
-
};
|
|
936
|
-
const body = {
|
|
937
|
-
recording_external_storage: request?.recording_external_storage,
|
|
938
|
-
};
|
|
939
|
-
|
|
940
|
-
const response = await this.apiClient.sendRequest<
|
|
941
|
-
StreamResponse<StartRecordingResponse>
|
|
942
|
-
>(
|
|
943
|
-
'POST',
|
|
944
|
-
'/api/v2/video/call/{type}/{id}/start_recording',
|
|
945
|
-
pathParams,
|
|
946
|
-
undefined,
|
|
947
|
-
body,
|
|
948
|
-
'application/json',
|
|
949
|
-
);
|
|
950
|
-
|
|
951
|
-
decoders.StartRecordingResponse?.(response.body);
|
|
952
|
-
|
|
953
|
-
return { ...response.body, metadata: response.metadata };
|
|
954
|
-
}
|
|
955
|
-
|
|
956
1027
|
async startTranscription(
|
|
957
1028
|
request: StartTranscriptionRequest & { type: string; id: string },
|
|
958
1029
|
): Promise<StreamResponse<StartTranscriptionResponse>> {
|
|
@@ -1089,31 +1160,6 @@ export class VideoApi {
|
|
|
1089
1160
|
return { ...response.body, metadata: response.metadata };
|
|
1090
1161
|
}
|
|
1091
1162
|
|
|
1092
|
-
async stopRecording(
|
|
1093
|
-
request: StopRecordingRequest & { type: string; id: string },
|
|
1094
|
-
): Promise<StreamResponse<StopRecordingResponse>> {
|
|
1095
|
-
const pathParams = {
|
|
1096
|
-
type: request?.type,
|
|
1097
|
-
id: request?.id,
|
|
1098
|
-
};
|
|
1099
|
-
const body = {};
|
|
1100
|
-
|
|
1101
|
-
const response = await this.apiClient.sendRequest<
|
|
1102
|
-
StreamResponse<StopRecordingResponse>
|
|
1103
|
-
>(
|
|
1104
|
-
'POST',
|
|
1105
|
-
'/api/v2/video/call/{type}/{id}/stop_recording',
|
|
1106
|
-
pathParams,
|
|
1107
|
-
undefined,
|
|
1108
|
-
body,
|
|
1109
|
-
'application/json',
|
|
1110
|
-
);
|
|
1111
|
-
|
|
1112
|
-
decoders.StopRecordingResponse?.(response.body);
|
|
1113
|
-
|
|
1114
|
-
return { ...response.body, metadata: response.metadata };
|
|
1115
|
-
}
|
|
1116
|
-
|
|
1117
1163
|
async stopTranscription(
|
|
1118
1164
|
request: StopTranscriptionRequest & { type: string; id: string },
|
|
1119
1165
|
): Promise<StreamResponse<StopTranscriptionResponse>> {
|