@vkontakte/calls-sdk 2.8.11-dev.3d9bb708.0 → 2.8.11-dev.48925708.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/CallsSDK.d.ts +22 -14
- package/abstract/BaseApi.d.ts +1 -2
- package/calls-sdk.cjs.js +16 -13
- package/calls-sdk.esm.js +11337 -13
- package/classes/Conversation.d.ts +10 -13
- package/classes/DisplayLayoutRequester.d.ts +36 -0
- package/classes/Logger.d.ts +4 -9
- package/classes/MediaSource.d.ts +1 -4
- package/default/Api.d.ts +1 -3
- package/default/Signaling.d.ts +2 -1
- package/package.json +1 -1
- package/static/Debug.d.ts +4 -4
- package/static/External.d.ts +14 -38
- package/static/Params.d.ts +22 -22
- package/types/ParticipantLayout.d.ts +33 -0
- package/types/PerfStatReporter.d.ts +2 -1
- package/types/SignalingMessage.d.ts +3 -0
- package/types/WebTransport.d.ts +1 -0
- package/classes/CallRegistry.d.ts +0 -18
package/CallsSDK.d.ts
CHANGED
|
@@ -6,7 +6,6 @@ import type { EffectVoiceChange } from '@vkontakte/calls-audio-effects';
|
|
|
6
6
|
import type * as Vmoji from '@vkontakte/calls-vmoji';
|
|
7
7
|
import BaseLogger from './abstract/BaseLogger';
|
|
8
8
|
import { AddParticipantParams } from './abstract/BaseSignaling';
|
|
9
|
-
import Conversation from './classes/Conversation';
|
|
10
9
|
import HangupReason, { HangupReasonData, CustomError } from './classes/HangupReason';
|
|
11
10
|
import { MediaTrackKind } from './classes/MediaSource';
|
|
12
11
|
import { AudienceModeHandsResponse } from './types/AudienceMode';
|
|
@@ -50,7 +49,7 @@ import { IAddMovieParams, IMovieMetaData, IMoviePreview, IOnRemoteMovieData, ISh
|
|
|
50
49
|
import MuteStates, { IMuteParticipantInternalParams, IMuteParticipantParams } from './types/MuteStates';
|
|
51
50
|
import { IAPIBaseUrl, IApiEnv } from './types/Params';
|
|
52
51
|
import { CompositeUserId, IGetParticipantsParameters, OkUserId, ParticipantId, ParticipantListMarker, ParticipantListMarkers, ParticipantListType, ParticipantsStateList, ParticipantStateMapped, ParticipantStateData, ParticipantStateDataKey, ParticipantStateDataValue } from './types/Participant';
|
|
53
|
-
import ParticipantLayout, { Layout, RequestKeyFrame, StopStream } from './types/ParticipantLayout';
|
|
52
|
+
import ParticipantLayout, { DisplayLayoutRequest, Layout, RequestKeyFrame, StopStream } from './types/ParticipantLayout';
|
|
54
53
|
import { ParticipantListChunkParameters } from './types/ParticipantListChunk';
|
|
55
54
|
import ParticipantPriority from './types/ParticipantPriority';
|
|
56
55
|
import { MediaType, ParticipantStreamDescription } from './types/ParticipantStreamDescription';
|
|
@@ -266,11 +265,11 @@ export declare function authorize(authToken?: string, apiBaseUrl?: IAPIBaseUrl):
|
|
|
266
265
|
*
|
|
267
266
|
* @param mediaOptions Нужно ли включать камеру и микрофон
|
|
268
267
|
*/
|
|
269
|
-
export declare function acceptCall(mediaOptions?: MediaOption[]
|
|
268
|
+
export declare function acceptCall(mediaOptions?: MediaOption[]): Promise<ConversationData>;
|
|
270
269
|
/**
|
|
271
270
|
* Отклонить входящий звонок
|
|
272
271
|
*/
|
|
273
|
-
export declare function declineCall(
|
|
272
|
+
export declare function declineCall(): Promise<void>;
|
|
274
273
|
/**
|
|
275
274
|
* Присоединиться к активному звонку
|
|
276
275
|
*
|
|
@@ -293,7 +292,7 @@ export declare function joinCallByLink(joinLink: string, mediaOptions?: MediaOpt
|
|
|
293
292
|
/**
|
|
294
293
|
* Завершить текущий разговор
|
|
295
294
|
*/
|
|
296
|
-
export declare function hangup(
|
|
295
|
+
export declare function hangup(): Promise<void>;
|
|
297
296
|
/**
|
|
298
297
|
* Добавить собеседника в звонок
|
|
299
298
|
*
|
|
@@ -341,7 +340,7 @@ export declare function changeDevice(kind: MediaDeviceKind, deviceId: string): P
|
|
|
341
340
|
* state Включить или выключить захват экрана
|
|
342
341
|
* settings Параметры захваты экрана
|
|
343
342
|
*/
|
|
344
|
-
export declare function captureScreen(stateOrSettings: boolean | ScreenCaptureSettings
|
|
343
|
+
export declare function captureScreen(stateOrSettings: boolean | ScreenCaptureSettings): Promise<void>;
|
|
345
344
|
/**
|
|
346
345
|
* Включить/выключить передачу точек вимоджи
|
|
347
346
|
*
|
|
@@ -362,13 +361,13 @@ export declare function setVideoStream(stream: MediaStream, isScreen?: boolean):
|
|
|
362
361
|
*
|
|
363
362
|
* @param enabled
|
|
364
363
|
*/
|
|
365
|
-
export declare function toggleLocalVideo(enabled: boolean
|
|
364
|
+
export declare function toggleLocalVideo(enabled: boolean): Promise<void>;
|
|
366
365
|
/**
|
|
367
366
|
* Включить или выключить свой микрофон
|
|
368
367
|
*
|
|
369
368
|
* @param enabled
|
|
370
369
|
*/
|
|
371
|
-
export declare function toggleLocalAudio(enabled: boolean
|
|
370
|
+
export declare function toggleLocalAudio(enabled: boolean): Promise<void>;
|
|
372
371
|
/**
|
|
373
372
|
* Изменяет размеры локального видео
|
|
374
373
|
*
|
|
@@ -399,7 +398,7 @@ export declare function changeParticipantState(state: ParticipantStateData, exte
|
|
|
399
398
|
*
|
|
400
399
|
* @param hold - true/false
|
|
401
400
|
*/
|
|
402
|
-
export declare function hold(hold: boolean
|
|
401
|
+
export declare function hold(hold: boolean): Promise<void>;
|
|
403
402
|
/**
|
|
404
403
|
* Принудительно опустить руки участников в текущем сессионном зале админа
|
|
405
404
|
*/
|
|
@@ -411,6 +410,12 @@ export declare function putHandsDown(): Promise<void>;
|
|
|
411
410
|
* @param layout Список приоритетов
|
|
412
411
|
*/
|
|
413
412
|
export declare function updateDisplayLayout(layout: ParticipantLayout[]): Promise<void>;
|
|
413
|
+
/**
|
|
414
|
+
* Запрашивает стримы, которые клиент хочет получать для отображения.
|
|
415
|
+
*
|
|
416
|
+
* @param requests Полный список стримов, которые должны приходить на клиент
|
|
417
|
+
*/
|
|
418
|
+
export declare function requestDisplayLayout(requests: DisplayLayoutRequest[]): Promise<void>;
|
|
414
419
|
/**
|
|
415
420
|
* Выдать или забрать роли в звонке пользователю
|
|
416
421
|
*
|
|
@@ -750,14 +755,17 @@ export declare function requestAsr(request: boolean): Promise<void>;
|
|
|
750
755
|
export declare function startUrlSharing(sharedUrl: string): Promise<void>;
|
|
751
756
|
export declare function stopUrlSharing(): Promise<void>;
|
|
752
757
|
export declare function sendTestCommand(name: string, params?: any): void;
|
|
753
|
-
export declare function startAnalyzingAudio(expectAudio: boolean): void;
|
|
758
|
+
export declare function startAnalyzingAudio(expectAudio: boolean, expectedActiveTracks?: number | null, expectedTrackFrequencies?: number[] | null): void;
|
|
754
759
|
export declare function stopAnalyzingAudio(): void;
|
|
755
|
-
|
|
756
|
-
|
|
757
|
-
|
|
760
|
+
/**
|
|
761
|
+
* Возвращает текущее время, скорректированное на смещение относительно серверного времени.
|
|
762
|
+
* Доступно после установки соединения (начало/присоединение к звонку).
|
|
763
|
+
* Если активного звонка нет — возвращает Date.now().
|
|
764
|
+
*/
|
|
765
|
+
export declare function getSyncedTime(): number;
|
|
758
766
|
/**
|
|
759
767
|
* Версия SDK
|
|
760
768
|
*/
|
|
761
769
|
export declare function version(): string;
|
|
762
|
-
export type { AddParticipantParams, AudienceModeHandsResponse, BrowserName, CompositeUserId, ConversationData, ConversationParams, ConversationResponse, CustomError, ExternalId, ExternalParticipant, ExternalParticipantListChunk, ExternalParticipantListMarker, ExternalParticipantListMarkers as ExternalParticipantMarkers, ExternalParticipantId, GetParticipantsSignalingResponse, GetRoomsSignalingResponse, HangupReasonData, IApiEnv, IAPIBaseUrl, IAsrStartParams, IAsrStopParams, IAsrData, IceServer, JSONArray, JSONObject, JSONType, Layout, MediaModifiers, MediaSettings, MuteStates, OkUserId, ParamsObject, ParticipantId, ParticipantLayout, ParticipantListMarkers, ParticipantListType, ParticipantPriority, ParticipantsStateList, ParticipantStateData, ParticipantStateDataKey, ParticipantStateMapped, ParticipantStreamDescription, ParticipantListChunkParameters, ParticipantListMarker, RequestKeyFrame, Rooms, IGetParticipantsParameters, ScreenCaptureSettings, SignalingMessage, StatResult, StopStream, WaitingHallResponse, IMovieMetaData, IVideoDimentions, IFeedbackExternal, ISharedMovieInfo, ISharedMovieStoppedInfo, ISharedMovieState, ISharedMovieStateResponse, IAddMovieParams, IOnRemoteMovieData, IMoviePreview, IRoomId, Room, RoomsUpdate, RoomParticipantUpdate, IUpdateMovieData, IFeaturesPerRole, IMuteParticipantParams, IMuteParticipantInternalParams, IStartStreamData, IStopStreamData, IPublishStreamData, VmojiError, FastStartHandler, FastStartParams, FastJoinHandler, FastJoinParams, FastJoinResponse, };
|
|
770
|
+
export type { AddParticipantParams, AudienceModeHandsResponse, BrowserName, CompositeUserId, ConversationData, ConversationParams, ConversationResponse, CustomError, ExternalId, ExternalParticipant, ExternalParticipantListChunk, ExternalParticipantListMarker, ExternalParticipantListMarkers as ExternalParticipantMarkers, ExternalParticipantId, DisplayLayoutRequest, GetParticipantsSignalingResponse, GetRoomsSignalingResponse, HangupReasonData, IApiEnv, IAPIBaseUrl, IAsrStartParams, IAsrStopParams, IAsrData, IceServer, JSONArray, JSONObject, JSONType, Layout, MediaModifiers, MediaSettings, MuteStates, OkUserId, ParamsObject, ParticipantId, ParticipantLayout, ParticipantListMarkers, ParticipantListType, ParticipantPriority, ParticipantsStateList, ParticipantStateData, ParticipantStateDataKey, ParticipantStateMapped, ParticipantStreamDescription, ParticipantListChunkParameters, ParticipantListMarker, RequestKeyFrame, Rooms, IGetParticipantsParameters, ScreenCaptureSettings, SignalingMessage, StatResult, StopStream, WaitingHallResponse, IMovieMetaData, IVideoDimentions, IFeedbackExternal, ISharedMovieInfo, ISharedMovieStoppedInfo, ISharedMovieState, ISharedMovieStateResponse, IAddMovieParams, IOnRemoteMovieData, IMoviePreview, IRoomId, Room, RoomsUpdate, RoomParticipantUpdate, IUpdateMovieData, IFeaturesPerRole, IMuteParticipantParams, IMuteParticipantInternalParams, IStartStreamData, IStopStreamData, IPublishStreamData, VmojiError, FastStartHandler, FastStartParams, FastJoinHandler, FastJoinParams, FastJoinResponse, };
|
|
763
771
|
export { Api, AuthData, BaseLogger, CallDirection, CallType, ChatRoomEventType, ConversationOption, DebugMessageType, ExternalIdType, FacingMode, FatalError, HangupReason, HangupType, MediaOption, MediaTrackKind, MediaType, MuteState, ParticipantState, ParticipantStateDataValue, ParticipantStatus, RecordRole, Signaling, SignalingCommandType, SignalingConnectionType, SignalingNotification, UserRole, UserType, TransportTopology, RoomsEventType, ConversationFeature, ArrayDequeue, ApiExternal, VolumeDetector, };
|
package/abstract/BaseApi.d.ts
CHANGED
|
@@ -7,7 +7,7 @@ import { ExternalId, ExternalParticipantId, ExternalUserId } from '../types/Exte
|
|
|
7
7
|
import { CompositeUserId, OkUserId, ParticipantId } from '../types/Participant';
|
|
8
8
|
export type ClientStats = {
|
|
9
9
|
vcid: ConversationData['id'] | null;
|
|
10
|
-
[k: string]: string | number | null;
|
|
10
|
+
[k: string]: string | number | boolean | null;
|
|
11
11
|
};
|
|
12
12
|
export type ClientEvent = {
|
|
13
13
|
timestamp: number;
|
|
@@ -83,7 +83,6 @@ export default abstract class BaseApi {
|
|
|
83
83
|
getDecorativeIdByInitialId(okId: OkUserId | CompositeUserId | ParticipantId): OkUserId | undefined;
|
|
84
84
|
replaceByInitialIdIdIfExists(id: OkUserId | CompositeUserId | ParticipantId): OkUserId;
|
|
85
85
|
hangupConversation(conversationId: string, reason?: HangupType): void;
|
|
86
|
-
sendUserFeedbackStats(conversationId: string, userResponse: number, reason?: string, groupCallUsersCount?: number): void;
|
|
87
86
|
removeHistoryRecords(recordIds: number[]): Promise<void>;
|
|
88
87
|
getServerTime(): Promise<number>;
|
|
89
88
|
cleanup(): void;
|