@cloudflare/realtimekit 1.1.0-staging.11 → 1.1.0-staging.16
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/browser.js +15 -15
- package/dist/index.cjs.js +15 -15
- package/dist/index.d.ts +1700 -1654
- package/dist/index.es.js +9082 -8769
- package/dist/index.rn.js +15 -15
- package/dist/ts3.4/dist/index.d.ts +2051 -2006
- package/package.json +1 -1
|
@@ -1,73 +1,9 @@
|
|
|
1
1
|
/// <reference types="node" />
|
|
2
|
-
import EventEmitter$1, { EventEmitter } from 'events';
|
|
3
|
-
import { MessageType as MessageType$1 } from '@protobuf-ts/runtime';
|
|
4
2
|
import * as _dyteinternals_utils from '@dyteinternals/utils';
|
|
5
|
-
import {
|
|
3
|
+
import { MediaVideoQualityType, ViewType, LivestreamViewerMediaQualityType, MediaProductionPermissionType, WaitingRoomTypes, createNewFlagsmithInstance, PresetTypeV2, MediaScreenShareQualityType, PluginAccessControls, RecorderType as RecorderType$1, BorderRadius, BorderWidth, Theme } from '@dyteinternals/utils';
|
|
4
|
+
import { MessageType as MessageType$1 } from '@protobuf-ts/runtime';
|
|
5
|
+
import EventEmitter, { EventEmitter as EventEmitter$1 } from 'events';
|
|
6
6
|
import * as WorkerTimers from 'worker-timers';
|
|
7
|
-
declare global {
|
|
8
|
-
interface SymbolConstructor {
|
|
9
|
-
readonly observable: symbol;
|
|
10
|
-
}
|
|
11
|
-
}
|
|
12
|
-
/**
|
|
13
|
-
Get keys of the given type as strings.
|
|
14
|
-
|
|
15
|
-
Number keys are converted to strings.
|
|
16
|
-
|
|
17
|
-
Use-cases:
|
|
18
|
-
- Get string keys from a type which may have number keys.
|
|
19
|
-
- Makes it possible to index using strings retrieved from template types.
|
|
20
|
-
|
|
21
|
-
@example
|
|
22
|
-
```
|
|
23
|
-
import type {StringKeyOf} from 'type-fest';
|
|
24
|
-
|
|
25
|
-
type Foo = {
|
|
26
|
-
1: number,
|
|
27
|
-
stringKey: string,
|
|
28
|
-
};
|
|
29
|
-
|
|
30
|
-
type StringKeysOfFoo = StringKeyOf<Foo>;
|
|
31
|
-
//=> '1' | 'stringKey'
|
|
32
|
-
```
|
|
33
|
-
|
|
34
|
-
@category Object
|
|
35
|
-
*/
|
|
36
|
-
type StringKeyOf<BaseType> = string;
|
|
37
|
-
declare class RTKEventEmitter<T extends string | symbol> extends EventEmitter {
|
|
38
|
-
constructor();
|
|
39
|
-
emit(event: T, ...args: any[]): boolean;
|
|
40
|
-
on(event: T, callback: (...args: any[]) => void): this;
|
|
41
|
-
addListener(event: T, callback: (...args: any[]) => any): this;
|
|
42
|
-
off(event: T, callback: (...args: any[]) => any): this;
|
|
43
|
-
once(event: T, callback: (...args: any[]) => any): this;
|
|
44
|
-
prependListener(event: T, callback: (...args: any[]) => any): this;
|
|
45
|
-
prependOnceListener(event: T, callback: (...args: any[]) => any): this;
|
|
46
|
-
removeListener(event: T, callback: (...args: any[]) => any): this;
|
|
47
|
-
removeAllListeners(event?: T): this;
|
|
48
|
-
listeners(event: T): Function[];
|
|
49
|
-
listenerCount(event: T): number;
|
|
50
|
-
}
|
|
51
|
-
type EventMap$1 = {
|
|
52
|
-
[key: string]: (...args: any[]) => void;
|
|
53
|
-
};
|
|
54
|
-
type WildCardEvent<T> = {
|
|
55
|
-
['*']: (event: StringKeyOf<T>, ...args: any) => void;
|
|
56
|
-
};
|
|
57
|
-
declare class RTKTypedEventEmitter<Events extends EventMap$1 & WildCardEvent<Events>> extends EventEmitter {
|
|
58
|
-
constructor();
|
|
59
|
-
emit<E extends StringKeyOf<Events>>(event: E, ...args: Parameters<Events[E]>): boolean;
|
|
60
|
-
on<E extends StringKeyOf<Events>>(event: E, callback: Events[E]): this;
|
|
61
|
-
addListener<E extends StringKeyOf<Events>>(event: E, callback: Events[E]): this;
|
|
62
|
-
off<T extends StringKeyOf<Events>>(event: T, callback: Events[T]): this;
|
|
63
|
-
once<T extends StringKeyOf<Events>>(event: T, callback: Events[T]): this;
|
|
64
|
-
prependListener<T extends StringKeyOf<Events>>(event: T, callback: Events[T]): this;
|
|
65
|
-
prependOnceListener<T extends StringKeyOf<Events>>(event: T, callback: Events[T]): this;
|
|
66
|
-
removeListener<T extends StringKeyOf<Events>>(event: T, callback: Events[T]): this;
|
|
67
|
-
removeAllListeners<T extends StringKeyOf<Events>>(event?: T): this;
|
|
68
|
-
listeners<T extends StringKeyOf<Events>>(event: T): Function[];
|
|
69
|
-
listenerCount<T extends StringKeyOf<Events>>(event: T): number;
|
|
70
|
-
}
|
|
71
7
|
/**
|
|
72
8
|
* protolint:disable ENUM_FIELD_NAMES_PREFIX
|
|
73
9
|
*
|
|
@@ -2599,7 +2535,7 @@ interface IVSPlayerLiveLatencyEntry extends EventEntryBase {
|
|
|
2599
2535
|
metaData: IVSPlayerLiveLatencyData;
|
|
2600
2536
|
}
|
|
2601
2537
|
type EventEntry = CallJoinBeginEntry | NetworkQualityTestBeginEntry | NetworkQualityTestEndEntry | BrowserForegroundedEntry | PingStatsEntry | PreCallTestBeginEntry | PreCallTestCompletedEntry | WebSocketConnectedEntry | TransportConnectedEntry | AudioToggleEntry | VideoToggleEntry | ScreenShareToggleEntry | DisconnectEntry | ReconnectEntry | ParticipantRoleToggleEntry | DominantSpeakerEntry | DevicesEntry | SelectedDeviceEntry | MediaPermissionEntry | MediaPlaybackFailureEntry | MediaTrackFailureEntry | ScreenShareRequestedEntry | ExpectedVideoResolutionEntry | ExpectedScreenshareResolutionEntry | TabChangeEntry | BrowserBackgroundedEntry | LegacySwitchEntry | IVSPlayerRebufferingEntry | IVSPlayerAudioBlockedEntry | IVSPlayerPlaybackBlockedEntry | IVSPlayerNetworkUnavailableEntry | IVSPlayerInitializedEntry | IVSPlayerErrorEntry | IVSPlayerRecoverableErrorEntry | IVSPlayerAnalyticsEventEntry | IVSPlayerLiveLatencyEntry | IVSPlayerPlaybackRateChangedEntry | IVSPlayerQualityChangedEntry | IVSPlayerWorkerErrorEntry;
|
|
2602
|
-
declare class EventHandler extends EventEmitter
|
|
2538
|
+
declare class EventHandler extends EventEmitter {
|
|
2603
2539
|
constructor({ logger, peerId, apiHostnames, }: {
|
|
2604
2540
|
logger: RTKLogger$2;
|
|
2605
2541
|
peerId: string;
|
|
@@ -2629,8 +2565,8 @@ declare class ParsedRTCStats {
|
|
|
2629
2565
|
staleProducerStreamMap: boolean;
|
|
2630
2566
|
staleConsumerStreamMap: boolean;
|
|
2631
2567
|
}
|
|
2632
|
-
declare abstract class Measurements extends EventEmitter
|
|
2633
|
-
observer: EventEmitter
|
|
2568
|
+
declare abstract class Measurements extends EventEmitter {
|
|
2569
|
+
observer: EventEmitter;
|
|
2634
2570
|
outboundProducerMap: Map<string, string>;
|
|
2635
2571
|
inboundConsumerMap: Map<string, string>;
|
|
2636
2572
|
consumerPeerIdMap: Map<string, {
|
|
@@ -2721,8 +2657,8 @@ declare abstract class Measurements extends EventEmitter$1 {
|
|
|
2721
2657
|
getNetworkQuality(iceServers: IceServerInfo[]): Promise<NetworkQualityInformation>;
|
|
2722
2658
|
getNetworkInfo(iceServers: IceServerInfo[], skipConnectivityChecks?: boolean): Promise<NetworkInformation | NetworkInformationWithoutConnectivityData>;
|
|
2723
2659
|
}
|
|
2724
|
-
declare class CallStats extends EventEmitter
|
|
2725
|
-
observer: EventEmitter
|
|
2660
|
+
declare class CallStats extends EventEmitter {
|
|
2661
|
+
observer: EventEmitter;
|
|
2726
2662
|
eventHandler: EventHandler;
|
|
2727
2663
|
producers: Map<string, any>;
|
|
2728
2664
|
logger: RTKLogger$2;
|
|
@@ -2791,7 +2727,7 @@ declare class CallStats extends EventEmitter$1 {
|
|
|
2791
2727
|
expectedVideoResolution(frameWidth: number, frameHeight: number, timestamp: Date): void;
|
|
2792
2728
|
expectedScreenshareResolution(frameWidth: number, frameHeight: number, timestamp: Date): void;
|
|
2793
2729
|
}
|
|
2794
|
-
declare class InhouseCallStats extends EventEmitter
|
|
2730
|
+
declare class InhouseCallStats extends EventEmitter {
|
|
2795
2731
|
stats: any;
|
|
2796
2732
|
peerId: string;
|
|
2797
2733
|
backend: CallStats;
|
|
@@ -2845,164 +2781,140 @@ declare class InhouseCallStats extends EventEmitter$1 {
|
|
|
2845
2781
|
expectedVideoResolution(frameWidth: number, frameHeight: number): void;
|
|
2846
2782
|
expectedScreenshareResolution(frameWidth: number, frameHeight: number): void;
|
|
2847
2783
|
}
|
|
2848
|
-
|
|
2849
|
-
|
|
2850
|
-
|
|
2851
|
-
|
|
2852
|
-
customParticipantId: string;
|
|
2853
|
-
}
|
|
2854
|
-
declare class RTKBasicParticipantsMap extends RTKEventEmitter<'participantsUpdate'> {
|
|
2855
|
-
constructor();
|
|
2856
|
-
__set(objId: string, obj: RTKBasicParticipant): Map<string, RTKBasicParticipant>;
|
|
2857
|
-
__clear(): void;
|
|
2858
|
-
get(objId: string): RTKBasicParticipant;
|
|
2859
|
-
toArray(): RTKBasicParticipant[];
|
|
2860
|
-
}
|
|
2861
|
-
type ChatChannelSocketMessage = GetChatChannelResponse;
|
|
2862
|
-
interface ChatChannel {
|
|
2863
|
-
id: string;
|
|
2864
|
-
displayName: string;
|
|
2865
|
-
memberIds: string[];
|
|
2866
|
-
displayPictureUrl?: string;
|
|
2867
|
-
visibility?: string;
|
|
2868
|
-
isDirectMessage?: boolean;
|
|
2869
|
-
latestMessage?: Message;
|
|
2870
|
-
unreadCount: number;
|
|
2871
|
-
}
|
|
2872
|
-
interface UpdateChannelRequestPayload {
|
|
2873
|
-
memberIds?: string[];
|
|
2874
|
-
displayName?: string;
|
|
2875
|
-
displayPictureUrl?: string;
|
|
2876
|
-
visibility?: string;
|
|
2877
|
-
}
|
|
2878
|
-
declare class ChatChannelSocketHandler {
|
|
2879
|
-
constructor(socketService: SocketService);
|
|
2880
|
-
createChannel(displayName: string, memberIds: string[], displayPictureUrl?: string, visibility?: string, isDirectMessage?: boolean): Promise<ChatChannel>;
|
|
2881
|
-
updateChannel(channelId: string, payload: UpdateChannelRequestPayload): Promise<ChatChannel>;
|
|
2882
|
-
static formatChannel(socketChannel: ChatChannel$1): ChatChannel;
|
|
2883
|
-
getChannelMembers(channelId: string): Promise<RTKBasicParticipant[]>;
|
|
2884
|
-
on(event: number, handler: (socketMessage: ChatChannelSocketMessage) => void): void;
|
|
2784
|
+
declare global {
|
|
2785
|
+
interface SymbolConstructor {
|
|
2786
|
+
readonly observable: symbol;
|
|
2787
|
+
}
|
|
2885
2788
|
}
|
|
2886
|
-
|
|
2887
|
-
|
|
2888
|
-
|
|
2889
|
-
|
|
2890
|
-
|
|
2789
|
+
/**
|
|
2790
|
+
Get keys of the given type as strings.
|
|
2791
|
+
|
|
2792
|
+
Number keys are converted to strings.
|
|
2793
|
+
|
|
2794
|
+
Use-cases:
|
|
2795
|
+
- Get string keys from a type which may have number keys.
|
|
2796
|
+
- Makes it possible to index using strings retrieved from template types.
|
|
2797
|
+
|
|
2798
|
+
@example
|
|
2799
|
+
```
|
|
2800
|
+
import type {StringKeyOf} from 'type-fest';
|
|
2801
|
+
|
|
2802
|
+
type Foo = {
|
|
2803
|
+
1: number,
|
|
2804
|
+
stringKey: string,
|
|
2805
|
+
};
|
|
2806
|
+
|
|
2807
|
+
type StringKeysOfFoo = StringKeyOf<Foo>;
|
|
2808
|
+
//=> '1' | 'stringKey'
|
|
2809
|
+
```
|
|
2810
|
+
|
|
2811
|
+
@category Object
|
|
2812
|
+
*/
|
|
2813
|
+
type StringKeyOf<BaseType> = string;
|
|
2814
|
+
declare class RTKEventEmitter<T extends string | symbol> extends EventEmitter$1 {
|
|
2815
|
+
logger: RTKLogger$1 | undefined;
|
|
2816
|
+
constructor(logger: RTKLogger$1);
|
|
2817
|
+
emit(event: T, ...args: any[]): boolean;
|
|
2818
|
+
on(event: T, callback: (...args: any[]) => void): this;
|
|
2819
|
+
addListener(event: T, callback: (...args: any[]) => any): this;
|
|
2820
|
+
off(event: T, callback: (...args: any[]) => any): this;
|
|
2821
|
+
once(event: T, callback: (...args: any[]) => any): this;
|
|
2822
|
+
prependListener(event: T, callback: (...args: any[]) => any): this;
|
|
2823
|
+
prependOnceListener(event: T, callback: (...args: any[]) => any): this;
|
|
2824
|
+
removeListener(event: T, callback: (...args: any[]) => any): this;
|
|
2825
|
+
removeAllListeners(event?: T): this;
|
|
2826
|
+
listeners(event: T): Function[];
|
|
2827
|
+
listenerCount(event: T): number;
|
|
2891
2828
|
}
|
|
2892
|
-
type
|
|
2893
|
-
|
|
2894
|
-
|
|
2895
|
-
|
|
2896
|
-
|
|
2897
|
-
|
|
2829
|
+
type EventMap$1 = {
|
|
2830
|
+
[key: string]: (...args: any[]) => void;
|
|
2831
|
+
};
|
|
2832
|
+
type WildCardEvent<T> = {
|
|
2833
|
+
['*']: (event: StringKeyOf<T>, ...args: any) => void;
|
|
2834
|
+
};
|
|
2835
|
+
declare class RTKTypedEventEmitter<Events extends EventMap$1 & WildCardEvent<Events>> extends EventEmitter$1 {
|
|
2836
|
+
logger: RTKLogger$1 | undefined;
|
|
2837
|
+
constructor(logger: RTKLogger$1);
|
|
2838
|
+
emit<E extends StringKeyOf<Events>>(event: E, ...args: Parameters<Events[E]>): boolean;
|
|
2839
|
+
on<E extends StringKeyOf<Events>>(event: E, callback: Events[E]): this;
|
|
2840
|
+
addListener<E extends StringKeyOf<Events>>(event: E, callback: Events[E]): this;
|
|
2841
|
+
off<T extends StringKeyOf<Events>>(event: T, callback: Events[T]): this;
|
|
2842
|
+
once<T extends StringKeyOf<Events>>(event: T, callback: Events[T]): this;
|
|
2843
|
+
prependListener<T extends StringKeyOf<Events>>(event: T, callback: Events[T]): this;
|
|
2844
|
+
prependOnceListener<T extends StringKeyOf<Events>>(event: T, callback: Events[T]): this;
|
|
2845
|
+
removeListener<T extends StringKeyOf<Events>>(event: T, callback: Events[T]): this;
|
|
2846
|
+
removeAllListeners<T extends StringKeyOf<Events>>(event?: T): this;
|
|
2847
|
+
listeners<T extends StringKeyOf<Events>>(event: T): Function[];
|
|
2848
|
+
listenerCount<T extends StringKeyOf<Events>>(event: T): number;
|
|
2898
2849
|
}
|
|
2899
|
-
|
|
2850
|
+
type StageSocketMessage = GetStageRequestsResponse | GetStagePeersResponse | DenyStageAccessRequest | PeerStatusUpdate;
|
|
2851
|
+
declare class StageSocketHandler {
|
|
2900
2852
|
constructor(socketService: SocketService);
|
|
2901
|
-
|
|
2853
|
+
getStageRequests(): Promise<GetStageRequestsResponse>;
|
|
2854
|
+
requestAccess(): void;
|
|
2855
|
+
cancelRequestAccess(): void;
|
|
2856
|
+
grantAccess(userIds: string[]): Promise<void>;
|
|
2857
|
+
denyAccess(userIds: string[]): Promise<void>;
|
|
2858
|
+
joinStage(): Promise<{
|
|
2902
2859
|
id: string;
|
|
2903
2860
|
payload: Uint8Array;
|
|
2904
2861
|
}>;
|
|
2905
|
-
|
|
2906
|
-
|
|
2907
|
-
|
|
2908
|
-
|
|
2909
|
-
|
|
2910
|
-
editMessage(chatId: string, message: string, payloadType: ChatMessageType, channelId?: string, pinned?: boolean): Promise<ChatMessage>;
|
|
2911
|
-
deleteMessage(chatId: string, channelId?: string): Promise<{
|
|
2912
|
-
channelId?: string;
|
|
2862
|
+
leaveStage(userId: string): Promise<{
|
|
2863
|
+
id: string;
|
|
2864
|
+
payload: Uint8Array;
|
|
2865
|
+
}>;
|
|
2866
|
+
kick(userIds: string[]): Promise<{
|
|
2913
2867
|
id: string;
|
|
2868
|
+
payload: Uint8Array;
|
|
2914
2869
|
}>;
|
|
2915
|
-
|
|
2916
|
-
|
|
2917
|
-
markLastReadMessage(channelId: string, message: Message): Promise<string>;
|
|
2918
|
-
setPinState(message: Message, pin: boolean): Promise<PinChatMessageResponse>;
|
|
2919
|
-
on(event: number, handler: (socketMessage: ChatSocketMessage) => void): void;
|
|
2870
|
+
on(event: number, handler: (socketMessage: StageSocketMessage, messageId?: string) => void): void;
|
|
2871
|
+
getPeerInfo(peerId: string): Promise<PeerInfoResponse>;
|
|
2920
2872
|
}
|
|
2921
|
-
|
|
2922
|
-
|
|
2923
|
-
|
|
2924
|
-
|
|
2925
|
-
|
|
2926
|
-
readonly peers: string[];
|
|
2927
|
-
readonly compulsoryPeers: string[];
|
|
2928
|
-
readonly activeSpeakerPeers: string[];
|
|
2873
|
+
type StageStatus = 'OFF_STAGE' | 'REQUESTED_TO_JOIN_STAGE' | 'ACCEPTED_TO_JOIN_STAGE' | 'ON_STAGE';
|
|
2874
|
+
interface StageRequestPayload {
|
|
2875
|
+
displayName: string;
|
|
2876
|
+
userId: string;
|
|
2877
|
+
peerId: string;
|
|
2929
2878
|
}
|
|
2930
|
-
type
|
|
2931
|
-
['
|
|
2932
|
-
['
|
|
2933
|
-
['
|
|
2934
|
-
|
|
2935
|
-
|
|
2879
|
+
type StageEvents = {
|
|
2880
|
+
['stageAccessRequestUpdate']: (requests?: StageRequestPayload[]) => void;
|
|
2881
|
+
['stageStatusUpdate']: (status: StageStatus) => void;
|
|
2882
|
+
['newStageRequest']: (payload: {
|
|
2883
|
+
count: number;
|
|
2884
|
+
}) => void;
|
|
2885
|
+
['stageRequestApproved']: () => void;
|
|
2886
|
+
['stageRequestRejected']: () => void;
|
|
2936
2887
|
['*']: (eventName: string, ...args: any[]) => void;
|
|
2937
2888
|
};
|
|
2938
|
-
declare class
|
|
2939
|
-
|
|
2940
|
-
|
|
2941
|
-
|
|
2942
|
-
|
|
2943
|
-
|
|
2944
|
-
|
|
2945
|
-
|
|
2946
|
-
|
|
2947
|
-
|
|
2948
|
-
|
|
2949
|
-
|
|
2950
|
-
|
|
2951
|
-
|
|
2952
|
-
removeSource(id: string): void;
|
|
2953
|
-
removePinnedSource(): void;
|
|
2954
|
-
removeAllSources(): void;
|
|
2955
|
-
enable(): void;
|
|
2956
|
-
disable: (partial?: boolean) => void;
|
|
2957
|
-
}
|
|
2958
|
-
type EventHandlerTypes = PeerInfoResponse | GetWaitingRoomRequests | RecordingEvent | UpdatePeersPresetResponse | PeerJoinBroadcastResponse | PeerJoinCompleteResponse | GlobalPeerPinningBroadcastResponse | PeerLeaveResponse | SelectedPeersResponse | SelectedPeersDiffResponse;
|
|
2959
|
-
declare class RoomSocketHandler {
|
|
2960
|
-
socket: SocketService;
|
|
2961
|
-
cleanup(): Promise<void>;
|
|
2962
|
-
constructor(context: Context<RTKContextState>, socketService: SocketService);
|
|
2963
|
-
joinRoom(opts: {
|
|
2964
|
-
name: string;
|
|
2889
|
+
declare class RTKStage extends RTKTypedEventEmitter<StageEvents> {
|
|
2890
|
+
readonly telemetry: RTKTelemetry;
|
|
2891
|
+
constructor(context: Context<RTKContextState>, self: RTKSelf$1, participants: RTKParticipants, stageSocketHandler: StageSocketHandler, roomSocketHandler: RoomSocketHandler);
|
|
2892
|
+
readonly status: StageStatus;
|
|
2893
|
+
getAccessRequests(): {
|
|
2894
|
+
stageRequests: StageRequestPayload[];
|
|
2895
|
+
};
|
|
2896
|
+
requestAccess(): Promise<void>;
|
|
2897
|
+
cancelRequestAccess(): Promise<void>;
|
|
2898
|
+
grantAccess(userIds: string[]): Promise<void>;
|
|
2899
|
+
denyAccess(userIds: string[]): Promise<void>;
|
|
2900
|
+
join(): Promise<void>;
|
|
2901
|
+
leave(): Promise<void>;
|
|
2902
|
+
kick(userIds: string[]): Promise<{
|
|
2965
2903
|
id: string;
|
|
2966
|
-
|
|
2967
|
-
customParticipantId: string;
|
|
2968
|
-
picture?: string;
|
|
2969
|
-
}): Promise<{
|
|
2970
|
-
peer: Peer;
|
|
2904
|
+
payload: Uint8Array;
|
|
2971
2905
|
}>;
|
|
2972
|
-
getAllAddedParticipants(): Promise<RTKBasicParticipant[]>;
|
|
2973
|
-
getRoomPeers(searchQuery: string, limit: number, offset: number): Promise<RoomPeersInfoResponse>;
|
|
2974
|
-
getRoomPeersNonPaginated(): Promise<RoomPeersInfoResponse>;
|
|
2975
|
-
getStagePeers(): Promise<RoomPeersInfoResponse>;
|
|
2976
|
-
getPeerInfo(peerId: string): Promise<PeerInfoResponse>;
|
|
2977
|
-
getRoomState(): Promise<RoomInfoResponse>;
|
|
2978
|
-
getRoomStageState(): Promise<GetRoomStageStateResponse>;
|
|
2979
|
-
broadcastMessage(type: string, payload: BroadcastMessagePayload): Promise<{
|
|
2980
|
-
id: string;
|
|
2981
|
-
payload: Uint8Array;
|
|
2982
|
-
}>;
|
|
2983
|
-
broadcastToMeetings(type: string, meetingIds: string[], payload: BroadcastMessagePayload): Promise<{
|
|
2984
|
-
id: string;
|
|
2985
|
-
payload: Uint8Array;
|
|
2986
|
-
}>;
|
|
2987
|
-
broadcastToPeers(type: string, peerIds: string[], payload: BroadcastMessagePayload): Promise<boolean>;
|
|
2988
|
-
leaveRoom(): Promise<void>;
|
|
2989
|
-
kick(peerId: string): Promise<void>;
|
|
2990
|
-
kickAll(propagateKickAll?: boolean): Promise<void>;
|
|
2991
|
-
getWaitingRoomRequests(): void;
|
|
2992
|
-
acceptWaitingRoomRequest(userIds: string[]): void;
|
|
2993
|
-
rejectWaitingRoomRequest(userIds: string[]): void;
|
|
2994
|
-
updatePermissions(userIds: string[], patch: PresetUpdates): Promise<{
|
|
2995
|
-
id: string;
|
|
2996
|
-
payload: Uint8Array;
|
|
2997
|
-
}>;
|
|
2998
|
-
on(event: number, handler: (message: EventHandlerTypes) => void): void;
|
|
2999
|
-
getUserPermissions(userId: string): Promise<Pick<PresetTypeV2['permissions'], 'chat' | 'polls' | 'plugins'>>;
|
|
3000
2906
|
}
|
|
3001
|
-
|
|
3002
|
-
|
|
3003
|
-
|
|
3004
|
-
|
|
3005
|
-
|
|
2907
|
+
interface ResponseStatus {
|
|
2908
|
+
success: boolean;
|
|
2909
|
+
message: string;
|
|
2910
|
+
}
|
|
2911
|
+
type MediaPermission$1 = 'NOT_REQUESTED' | 'ACCEPTED' | 'DENIED' | 'SYSTEM_DENIED' | 'COULD_NOT_START' | 'NO_DEVICES_AVAILABLE' | 'CANCELED';
|
|
2912
|
+
declare class EnhancedEventEmitter<TransportPromiseEvents> extends EventEmitter$1 {
|
|
2913
|
+
readonly logger: RTKLogger$1;
|
|
2914
|
+
constructor(context: Context<RTKContextState>);
|
|
2915
|
+
safeEmit(event: string, ...args: any[]): boolean;
|
|
2916
|
+
safeEmitAsPromise<T extends keyof TransportPromiseEvents>(event: T, ...args: any[]): Promise<TransportPromiseEvents[T]>;
|
|
2917
|
+
safeEmitAsPromiseWithTimeout<T extends keyof TransportPromiseEvents>(event: T, timeout: number, ...args: any[]): Promise<TransportPromiseEvents[T]>;
|
|
3006
2918
|
}
|
|
3007
2919
|
declare enum TransportState {
|
|
3008
2920
|
NEW = "new",
|
|
@@ -3106,25 +3018,25 @@ type ConsumerOptions = {
|
|
|
3106
3018
|
closeTranscieverOnClose?: boolean;
|
|
3107
3019
|
};
|
|
3108
3020
|
type MediaKind = 'audio' | 'video';
|
|
3109
|
-
declare class Consumer extends EnhancedEventEmitter<TransportPromiseEvents> {
|
|
3110
|
-
readonly rtpReceiver: RTCRtpReceiver;
|
|
3111
|
-
readonly id: string;
|
|
3112
|
-
readonly localId: string;
|
|
3113
|
-
readonly producerId: string;
|
|
3114
|
-
readonly producingTransportId: string;
|
|
3115
|
-
readonly mimeType: string;
|
|
3116
|
-
readonly track: MediaStreamTrack;
|
|
3117
|
-
readonly peerId: string;
|
|
3118
|
-
readonly appData: Record<string, unknown>;
|
|
3119
|
-
readonly transceiver: RTCRtpTransceiver;
|
|
3120
|
-
constructor(opts: ConsumerOptions);
|
|
3121
|
-
readonly closed: boolean;
|
|
3122
|
-
readonly kind: MediaKind;
|
|
3123
|
-
readonly paused: boolean;
|
|
3124
|
-
close(reason?: string, closeTranscieverOnClose?: boolean): void;
|
|
3125
|
-
getStats(): Promise<RTCStatsReport>;
|
|
3126
|
-
pause(): void;
|
|
3127
|
-
resume(): void;
|
|
3021
|
+
declare class Consumer extends EnhancedEventEmitter<TransportPromiseEvents> {
|
|
3022
|
+
readonly rtpReceiver: RTCRtpReceiver;
|
|
3023
|
+
readonly id: string;
|
|
3024
|
+
readonly localId: string;
|
|
3025
|
+
readonly producerId: string;
|
|
3026
|
+
readonly producingTransportId: string;
|
|
3027
|
+
readonly mimeType: string;
|
|
3028
|
+
readonly track: MediaStreamTrack;
|
|
3029
|
+
readonly peerId: string;
|
|
3030
|
+
readonly appData: Record<string, unknown>;
|
|
3031
|
+
readonly transceiver: RTCRtpTransceiver;
|
|
3032
|
+
constructor(context: Context<RTKContextState>, opts: ConsumerOptions);
|
|
3033
|
+
readonly closed: boolean;
|
|
3034
|
+
readonly kind: MediaKind;
|
|
3035
|
+
readonly paused: boolean;
|
|
3036
|
+
close(reason?: string, closeTranscieverOnClose?: boolean): void;
|
|
3037
|
+
getStats(): Promise<RTCStatsReport>;
|
|
3038
|
+
pause(): void;
|
|
3039
|
+
resume(): void;
|
|
3128
3040
|
}
|
|
3129
3041
|
declare const localMediaEvents: readonly [
|
|
3130
3042
|
"AUDIO_TRACK_CHANGE",
|
|
@@ -3226,1589 +3138,1492 @@ type SelfEvents = {
|
|
|
3226
3138
|
['autoplayError']: (error: Error) => void;
|
|
3227
3139
|
['*']: (event: string, ...args: any[]) => void;
|
|
3228
3140
|
};
|
|
3229
|
-
|
|
3230
|
-
|
|
3231
|
-
|
|
3232
|
-
|
|
3233
|
-
|
|
3234
|
-
|
|
3235
|
-
|
|
3236
|
-
|
|
3237
|
-
|
|
3238
|
-
|
|
3239
|
-
|
|
3240
|
-
|
|
3241
|
-
|
|
3242
|
-
|
|
3243
|
-
|
|
3244
|
-
}
|
|
3245
|
-
interface Participant {
|
|
3246
|
-
id: string;
|
|
3247
|
-
userId: string;
|
|
3248
|
-
displayName: string;
|
|
3249
|
-
device?: DeviceConfig;
|
|
3250
|
-
picture?: string;
|
|
3251
|
-
isHost: boolean;
|
|
3252
|
-
flags: {
|
|
3253
|
-
[key: string]: string | boolean;
|
|
3254
|
-
};
|
|
3255
|
-
clientSpecificId?: string;
|
|
3256
|
-
customParticipantId?: string;
|
|
3257
|
-
stageStatus?: StageStatus;
|
|
3258
|
-
audioMuted: boolean;
|
|
3259
|
-
audioTrack: MediaStreamTrack;
|
|
3260
|
-
videoTrack: MediaStreamTrack;
|
|
3261
|
-
videoEnabled: boolean;
|
|
3262
|
-
producers?: ProducerState[];
|
|
3263
|
-
metadata?: {
|
|
3264
|
-
preset_name?: string;
|
|
3265
|
-
};
|
|
3266
|
-
recorderType?: string;
|
|
3267
|
-
}
|
|
3268
|
-
declare class RTKParticipant$1 extends RTKTypedEventEmitter<ParticipantEvents> {
|
|
3269
|
-
id: string;
|
|
3270
|
-
userId: string;
|
|
3271
|
-
name: string;
|
|
3272
|
-
picture: string;
|
|
3273
|
-
isHost: boolean;
|
|
3274
|
-
customParticipantId?: string;
|
|
3275
|
-
readonly clientSpecificId: string;
|
|
3276
|
-
flags: {
|
|
3277
|
-
[key: string]: string | boolean;
|
|
3141
|
+
declare class LocalMediaHandler extends RTKEventEmitter<LocalMediaEvents> {
|
|
3142
|
+
readonly telemetry: RTKTelemetry;
|
|
3143
|
+
audioUpdateInProgress: boolean;
|
|
3144
|
+
videoUpdateInProgress: boolean;
|
|
3145
|
+
constructor(context: Context<RTKContextState>, mediaConstraints: MediaConstraints, isNonPreferredDevice?: (media: MediaDeviceInfo) => boolean, autoSwitchDevice?: boolean);
|
|
3146
|
+
context: Context<RTKContextState>;
|
|
3147
|
+
repopulateAvailableDevices(): Promise<boolean>;
|
|
3148
|
+
setupStreams({ audio, video, }: {
|
|
3149
|
+
audio: boolean;
|
|
3150
|
+
video: boolean;
|
|
3151
|
+
}): Promise<void>;
|
|
3152
|
+
getCurrentDevices(): {
|
|
3153
|
+
audio: MediaDeviceInfo;
|
|
3154
|
+
video: MediaDeviceInfo;
|
|
3155
|
+
speaker: MediaDeviceInfo;
|
|
3278
3156
|
};
|
|
3279
|
-
|
|
3280
|
-
|
|
3281
|
-
|
|
3282
|
-
|
|
3157
|
+
readonly permissions: {
|
|
3158
|
+
audio?: MediaPermission$1;
|
|
3159
|
+
video?: MediaPermission$1;
|
|
3160
|
+
screenshare?: MediaPermission$1;
|
|
3161
|
+
};
|
|
3162
|
+
getAllDevices(): Promise<InputDeviceInfo[]>;
|
|
3163
|
+
getDeviceById(deviceId: string, kind?: 'audioinput' | 'audiooutput' | 'videoinput'): Promise<MediaDeviceInfo>;
|
|
3164
|
+
readonly rawAudioTrack: MediaStreamTrack;
|
|
3165
|
+
readonly audioTrack: MediaStreamTrack;
|
|
3166
|
+
readonly audioEnabled: boolean;
|
|
3167
|
+
enableAudio(customTrack?: MediaStreamTrack): Promise<void>;
|
|
3168
|
+
disableAudio(): void;
|
|
3169
|
+
getAudioDevices(devices?: MediaDeviceInfo[]): Promise<MediaDeviceInfo[]>;
|
|
3170
|
+
setAudioDevice(device: MediaDeviceInfo): Promise<void>;
|
|
3171
|
+
setupSpeaker(): Promise<void>;
|
|
3172
|
+
setSpeakerDevice(device: MediaDeviceInfo): Promise<void>;
|
|
3173
|
+
readonly rawVideoTrack: MediaStreamTrack;
|
|
3174
|
+
readonly videoTrack: MediaStreamTrack;
|
|
3175
|
+
readonly videoEnabled: boolean;
|
|
3176
|
+
enableVideo(customTrack?: MediaStreamTrack): Promise<void>;
|
|
3177
|
+
disableVideo(): void;
|
|
3178
|
+
getVideoDevices(devices?: MediaDeviceInfo[]): Promise<MediaDeviceInfo[]>;
|
|
3179
|
+
setVideoDevice(device: MediaDeviceInfo): Promise<void>;
|
|
3180
|
+
updateVideoConstraints(resolution: VideoQualityConstraints): Promise<void>;
|
|
3181
|
+
readonly screenShareTracks: {
|
|
3283
3182
|
audio: MediaStreamTrack;
|
|
3284
3183
|
video: MediaStreamTrack;
|
|
3285
3184
|
};
|
|
3286
|
-
|
|
3287
|
-
|
|
3288
|
-
|
|
3289
|
-
|
|
3290
|
-
|
|
3291
|
-
|
|
3292
|
-
|
|
3293
|
-
|
|
3294
|
-
|
|
3295
|
-
|
|
3296
|
-
|
|
3297
|
-
|
|
3298
|
-
|
|
3299
|
-
|
|
3300
|
-
|
|
3301
|
-
|
|
3302
|
-
|
|
3303
|
-
|
|
3304
|
-
|
|
3305
|
-
|
|
3306
|
-
|
|
3307
|
-
|
|
3308
|
-
deregisterVideoElement(videoElem?: HTMLVideoElement): void;
|
|
3185
|
+
readonly screenShareEnabled: boolean;
|
|
3186
|
+
enableScreenShare(): Promise<void>;
|
|
3187
|
+
disableScreenShare(): Promise<void>;
|
|
3188
|
+
updateScreenshareConstraints(resolution: VideoQualityConstraints): Promise<void>;
|
|
3189
|
+
getSpeakerDevices(devices?: MediaDeviceInfo[]): Promise<MediaDeviceInfo[]>;
|
|
3190
|
+
addAudioMiddleware(audioMiddleware: AudioMiddleware): Promise<ResponseStatus>;
|
|
3191
|
+
removeAudioMiddleware(audioMiddleware: AudioMiddleware): Promise<ResponseStatus>;
|
|
3192
|
+
removeAllAudioMiddlewares(): Promise<ResponseStatus>;
|
|
3193
|
+
addVideoMiddleware(videoMiddleware: VideoMiddleware): Promise<ResponseStatus>;
|
|
3194
|
+
removeVideoMiddleware(videoMiddleware: VideoMiddleware): Promise<ResponseStatus>;
|
|
3195
|
+
removeAllVideoMiddlewares(): Promise<ResponseStatus>;
|
|
3196
|
+
setVideoMiddlewareGlobalConfig(config: VideoMiddlewareGlobalConfig): Promise<void>;
|
|
3197
|
+
destruct(): void;
|
|
3198
|
+
onDeviceChange(changedDevices: {
|
|
3199
|
+
added: MediaDeviceInfo[];
|
|
3200
|
+
removed: MediaDeviceInfo[];
|
|
3201
|
+
devices: MediaDeviceInfo[];
|
|
3202
|
+
}, skipDeviceChange: boolean): Promise<void>;
|
|
3203
|
+
removeAllTracks(): void;
|
|
3204
|
+
removeAudioTrack(): void;
|
|
3205
|
+
removeVideoTrack(): void;
|
|
3206
|
+
removeDocumentEventListeners(): Promise<void>;
|
|
3309
3207
|
}
|
|
3310
|
-
|
|
3311
|
-
|
|
3312
|
-
|
|
3313
|
-
|
|
3314
|
-
|
|
3315
|
-
|
|
3316
|
-
|
|
3317
|
-
|
|
3318
|
-
|
|
3208
|
+
declare enum MediaPermission {
|
|
3209
|
+
NOT_REQUESTED = 0,
|
|
3210
|
+
ACCEPTED = 1,
|
|
3211
|
+
DENIED = 2,
|
|
3212
|
+
CANCELED = 3,
|
|
3213
|
+
SYSTEM_DENIED = 4,
|
|
3214
|
+
COULD_NOT_START = 5,
|
|
3215
|
+
NO_DEVICES_AVAILABLE = 6
|
|
3216
|
+
}
|
|
3217
|
+
type AudioMiddleware = (audioContext: AudioContext) => Promise<ScriptProcessorNode | AudioWorkletNode>;
|
|
3218
|
+
type VideoMiddleware = (() => Promise<(canvas: HTMLCanvasElement, ctx: CanvasRenderingContext2D) => Promise<void>>) | ((helpers: {
|
|
3219
|
+
canvas: HTMLCanvasElement;
|
|
3220
|
+
WorkerTimers: typeof WorkerTimers;
|
|
3221
|
+
}) => Promise<void>);
|
|
3222
|
+
type VideoMiddlewareGlobalConfig = {
|
|
3223
|
+
disablePerFrameCanvasRendering: boolean;
|
|
3319
3224
|
};
|
|
3320
|
-
type
|
|
3321
|
-
|
|
3322
|
-
|
|
3225
|
+
type PresetMediaConstraints = PresetV2CamelCased['config']['media'];
|
|
3226
|
+
type AudioQualityConstraints = {
|
|
3227
|
+
echoCancellation?: boolean;
|
|
3228
|
+
noiseSupression?: boolean;
|
|
3229
|
+
autoGainControl?: boolean;
|
|
3230
|
+
enableStereo?: boolean;
|
|
3231
|
+
enableHighBitrate?: boolean;
|
|
3323
3232
|
};
|
|
3324
|
-
|
|
3325
|
-
|
|
3326
|
-
|
|
3327
|
-
|
|
3328
|
-
|
|
3329
|
-
|
|
3330
|
-
|
|
3331
|
-
|
|
3332
|
-
|
|
3333
|
-
|
|
3334
|
-
|
|
3335
|
-
|
|
3336
|
-
|
|
3233
|
+
type VideoQualityConstraints = {
|
|
3234
|
+
width: {
|
|
3235
|
+
ideal: number;
|
|
3236
|
+
};
|
|
3237
|
+
height: {
|
|
3238
|
+
ideal: number;
|
|
3239
|
+
};
|
|
3240
|
+
frameRate?: {
|
|
3241
|
+
ideal: number;
|
|
3242
|
+
};
|
|
3243
|
+
};
|
|
3244
|
+
type ScreenshareQualityConstraints = {
|
|
3245
|
+
width?: {
|
|
3246
|
+
max: number;
|
|
3247
|
+
};
|
|
3248
|
+
height?: {
|
|
3249
|
+
max: number;
|
|
3250
|
+
};
|
|
3251
|
+
frameRate?: {
|
|
3252
|
+
ideal: number;
|
|
3253
|
+
max: number;
|
|
3254
|
+
};
|
|
3255
|
+
displaySurface?: 'window' | 'monitor' | 'browser';
|
|
3256
|
+
selfBrowserSurface?: 'include' | 'exclude';
|
|
3257
|
+
};
|
|
3258
|
+
interface RTKMediaTrackConstraints extends MediaTrackConstraints {
|
|
3259
|
+
optional?: Array<object>;
|
|
3337
3260
|
}
|
|
3338
|
-
|
|
3339
|
-
|
|
3340
|
-
Meeting = 1
|
|
3261
|
+
interface RTKMediaStreamConstraints extends MediaStreamConstraints {
|
|
3262
|
+
audio?: boolean | RTKMediaTrackConstraints;
|
|
3341
3263
|
}
|
|
3342
|
-
|
|
3343
|
-
|
|
3344
|
-
|
|
3345
|
-
|
|
3346
|
-
}
|
|
3347
|
-
type MetaEvents = {
|
|
3348
|
-
['mediaConnectionUpdate']: (payload: MediaConnectionUpdate) => void;
|
|
3349
|
-
['socketConnectionUpdate']: (state: SocketConnectionState) => void;
|
|
3350
|
-
['poorConnection']: (payload: {
|
|
3351
|
-
score: number;
|
|
3352
|
-
}) => void;
|
|
3353
|
-
['meetingStartTimeUpdate']: (payload: {
|
|
3354
|
-
meetingStartedTimestamp: Date;
|
|
3355
|
-
}) => void;
|
|
3356
|
-
['transcript']: (t: TranscriptionData) => void;
|
|
3357
|
-
['activeTabUpdate']: (tab: ActiveTab) => void;
|
|
3358
|
-
['selfTabUpdate']: (tab: ActiveTab) => void;
|
|
3359
|
-
['broadcastTabChangesUpdate']: (broadcastTabChanges: boolean) => void;
|
|
3360
|
-
['*']: (event: string, ...args: any[]) => void;
|
|
3264
|
+
type MediaConstraints = {
|
|
3265
|
+
audio?: AudioQualityConstraints;
|
|
3266
|
+
video?: MediaVideoQualityType | VideoQualityConstraints;
|
|
3267
|
+
screenshare?: ScreenshareQualityConstraints;
|
|
3361
3268
|
};
|
|
3362
|
-
|
|
3363
|
-
|
|
3364
|
-
|
|
3365
|
-
|
|
3366
|
-
|
|
3367
|
-
|
|
3368
|
-
|
|
3369
|
-
|
|
3370
|
-
|
|
3371
|
-
|
|
3372
|
-
|
|
3373
|
-
|
|
3374
|
-
|
|
3375
|
-
|
|
3376
|
-
|
|
3377
|
-
|
|
3378
|
-
|
|
3379
|
-
|
|
3269
|
+
type PresetV2CamelCased = {
|
|
3270
|
+
config: {
|
|
3271
|
+
viewType: ViewType;
|
|
3272
|
+
media: {
|
|
3273
|
+
audio: {
|
|
3274
|
+
enableStereo: boolean;
|
|
3275
|
+
enableHighBitrate: boolean;
|
|
3276
|
+
};
|
|
3277
|
+
video: {
|
|
3278
|
+
quality: MediaVideoQualityType;
|
|
3279
|
+
frameRate: number;
|
|
3280
|
+
};
|
|
3281
|
+
screenshare: {
|
|
3282
|
+
quality: MediaScreenShareQualityType;
|
|
3283
|
+
frameRate: number;
|
|
3284
|
+
};
|
|
3285
|
+
};
|
|
3286
|
+
livestreamViewerQualities: LivestreamViewerMediaQualityType[];
|
|
3287
|
+
maxVideoStreams: {
|
|
3288
|
+
mobile: number;
|
|
3289
|
+
desktop: number;
|
|
3290
|
+
};
|
|
3291
|
+
maxScreenshareCount: number;
|
|
3292
|
+
};
|
|
3293
|
+
permissions: {
|
|
3294
|
+
acceptWaitingRequests: boolean;
|
|
3295
|
+
canAcceptProductionRequests: boolean;
|
|
3296
|
+
canEditDisplayName: boolean;
|
|
3297
|
+
canRecord: boolean;
|
|
3298
|
+
canLivestream: boolean;
|
|
3299
|
+
canSpotlight?: boolean;
|
|
3300
|
+
disableParticipantAudio: boolean;
|
|
3301
|
+
disableParticipantScreensharing: boolean;
|
|
3302
|
+
disableParticipantVideo: boolean;
|
|
3303
|
+
kickParticipant: boolean;
|
|
3304
|
+
pinParticipant: boolean;
|
|
3305
|
+
plugins: {
|
|
3306
|
+
canClose: boolean;
|
|
3307
|
+
canStart: boolean;
|
|
3308
|
+
canEditConfig?: boolean;
|
|
3309
|
+
config: {
|
|
3310
|
+
[pluginId: string]: Partial<{
|
|
3311
|
+
accessControl: PluginAccessControls.FULL_ACCESS | PluginAccessControls.VIEW_ONLY;
|
|
3312
|
+
disabled: boolean;
|
|
3313
|
+
handlesViewOnly: boolean;
|
|
3314
|
+
}>;
|
|
3315
|
+
};
|
|
3316
|
+
};
|
|
3317
|
+
waitingRoomType: WaitingRoomTypes;
|
|
3318
|
+
polls: {
|
|
3319
|
+
canCreate: boolean;
|
|
3320
|
+
canVote: boolean;
|
|
3321
|
+
canView: boolean;
|
|
3322
|
+
};
|
|
3323
|
+
media: {
|
|
3324
|
+
video: {
|
|
3325
|
+
canProduce: MediaProductionPermissionType;
|
|
3326
|
+
};
|
|
3327
|
+
audio: {
|
|
3328
|
+
canProduce: MediaProductionPermissionType;
|
|
3329
|
+
};
|
|
3330
|
+
screenshare: {
|
|
3331
|
+
canProduce: MediaProductionPermissionType;
|
|
3332
|
+
};
|
|
3333
|
+
};
|
|
3334
|
+
chat: {
|
|
3335
|
+
public: {
|
|
3336
|
+
canSend: boolean;
|
|
3337
|
+
text: boolean;
|
|
3338
|
+
files: boolean;
|
|
3339
|
+
};
|
|
3340
|
+
private?: {
|
|
3341
|
+
canSend: boolean;
|
|
3342
|
+
canReceive: boolean;
|
|
3343
|
+
text: boolean;
|
|
3344
|
+
files: boolean;
|
|
3345
|
+
};
|
|
3346
|
+
channel?: {
|
|
3347
|
+
canCreate: 'NONE' | 'PRIVATE' | 'PUBLIC' | 'ALL';
|
|
3348
|
+
canDelete: 'NONE' | 'PRIVATE' | 'PUBLIC' | 'ALL';
|
|
3349
|
+
canUpdate: 'NONE' | 'PRIVATE' | 'PUBLIC' | 'ALL';
|
|
3350
|
+
canReadAll: boolean;
|
|
3351
|
+
};
|
|
3352
|
+
message?: {
|
|
3353
|
+
canDelete: 'NONE' | 'SELF' | 'ALL';
|
|
3354
|
+
canEdit: 'NONE' | 'SELF' | 'ALL';
|
|
3355
|
+
deleteCutoffTimeSeconds: number;
|
|
3356
|
+
editCutoffTimeSeconds: number;
|
|
3357
|
+
};
|
|
3358
|
+
};
|
|
3359
|
+
isRecorder?: boolean;
|
|
3360
|
+
recorderType: RecorderType$1;
|
|
3361
|
+
hiddenParticipant: boolean;
|
|
3362
|
+
showParticipantList: boolean;
|
|
3363
|
+
canChangeParticipantPermissions: boolean;
|
|
3364
|
+
connectedMeetings: {
|
|
3365
|
+
canAlterConnectedMeetings: boolean;
|
|
3366
|
+
canSwitchConnectedMeetings: boolean;
|
|
3367
|
+
canSwitchToParentMeeting: boolean;
|
|
3368
|
+
};
|
|
3369
|
+
acceptStageRequests?: boolean;
|
|
3370
|
+
stageEnabled?: boolean;
|
|
3371
|
+
stageAccess?: MediaProductionPermissionType;
|
|
3372
|
+
transcriptionEnabled: boolean;
|
|
3373
|
+
};
|
|
3374
|
+
ui: {
|
|
3375
|
+
designTokens: {
|
|
3376
|
+
borderRadius: BorderRadius;
|
|
3377
|
+
borderWidth: BorderWidth;
|
|
3378
|
+
colors: {
|
|
3379
|
+
brand: {
|
|
3380
|
+
300: string;
|
|
3381
|
+
400: string;
|
|
3382
|
+
500: string;
|
|
3383
|
+
600: string;
|
|
3384
|
+
700: string;
|
|
3385
|
+
};
|
|
3386
|
+
background: {
|
|
3387
|
+
600: string;
|
|
3388
|
+
700: string;
|
|
3389
|
+
800: string;
|
|
3390
|
+
900: string;
|
|
3391
|
+
1000: string;
|
|
3392
|
+
};
|
|
3393
|
+
danger: string;
|
|
3394
|
+
success: string;
|
|
3395
|
+
textOnBrand: string;
|
|
3396
|
+
text: string;
|
|
3397
|
+
videoBg: string;
|
|
3398
|
+
warning: string;
|
|
3399
|
+
};
|
|
3400
|
+
fontFamily?: string;
|
|
3401
|
+
googleFont?: string;
|
|
3402
|
+
logo?: string;
|
|
3403
|
+
spacingBase: number;
|
|
3404
|
+
theme: Theme;
|
|
3405
|
+
};
|
|
3406
|
+
configDiff: any;
|
|
3407
|
+
};
|
|
3408
|
+
version?: string;
|
|
3409
|
+
id?: string;
|
|
3410
|
+
name?: string;
|
|
3411
|
+
};
|
|
3412
|
+
type MaxVideoStreams = PresetV2CamelCased['config']['maxVideoStreams'];
|
|
3413
|
+
declare class RTKThemePreset$1 {
|
|
3414
|
+
private constructor();
|
|
3415
|
+
static fromResponse(preset: PresetV2CamelCased): RTKThemePreset$1;
|
|
3416
|
+
static default(): RTKThemePreset$1;
|
|
3417
|
+
static init(preset?: PresetV2CamelCased, useDefault?: boolean): RTKThemePreset$1;
|
|
3418
|
+
readonly setupScreen: Readonly<{
|
|
3419
|
+
isEnabled: boolean;
|
|
3420
|
+
}>;
|
|
3421
|
+
readonly waitingRoom: Readonly<{
|
|
3422
|
+
isEnabled: boolean;
|
|
3423
|
+
}>;
|
|
3424
|
+
readonly controlBar: Readonly<{
|
|
3425
|
+
isEnabled: boolean;
|
|
3426
|
+
elements?: {
|
|
3427
|
+
chat?: boolean;
|
|
3428
|
+
fullscreen?: boolean;
|
|
3429
|
+
invite?: boolean;
|
|
3430
|
+
layout?: boolean;
|
|
3431
|
+
participants?: boolean;
|
|
3432
|
+
plugins?: boolean;
|
|
3433
|
+
polls?: boolean;
|
|
3434
|
+
reactions?: boolean;
|
|
3435
|
+
screenshare?: boolean;
|
|
3436
|
+
};
|
|
3437
|
+
}>;
|
|
3438
|
+
readonly header: Readonly<{
|
|
3439
|
+
isEnabled: boolean;
|
|
3440
|
+
elements: {
|
|
3441
|
+
logo: string;
|
|
3442
|
+
timer: boolean;
|
|
3443
|
+
title: boolean;
|
|
3444
|
+
participantCount: boolean;
|
|
3445
|
+
changeLayout: boolean;
|
|
3446
|
+
};
|
|
3447
|
+
}>;
|
|
3448
|
+
readonly pipMode: Readonly<boolean>;
|
|
3449
|
+
readonly viewType: Readonly<ViewType>;
|
|
3450
|
+
readonly livestreamViewerQualities: Readonly<LivestreamViewerMediaQualityType[]>;
|
|
3451
|
+
readonly maxVideoStreams: Readonly<MaxVideoStreams>;
|
|
3452
|
+
readonly maxScreenShareCount: Readonly<number>;
|
|
3453
|
+
readonly plugins: Readonly<string[]>;
|
|
3454
|
+
readonly disabledPlugins: Readonly<string[]>;
|
|
3455
|
+
readonly designTokens: Readonly<PresetV2CamelCased['ui']['designTokens']>;
|
|
3456
|
+
readonly configDiff: Readonly<PresetV2CamelCased['ui']['configDiff']>;
|
|
3457
|
+
readonly mediaConstraints: Readonly<PresetMediaConstraints>;
|
|
3458
|
+
readonly name: string;
|
|
3380
3459
|
}
|
|
3381
|
-
type
|
|
3382
|
-
|
|
3383
|
-
|
|
3384
|
-
['
|
|
3460
|
+
type PresetPermissions = PresetV2CamelCased['permissions'];
|
|
3461
|
+
type MediaRoomType = 'HIVE' | 'CF';
|
|
3462
|
+
type PermissionEvents = {
|
|
3463
|
+
['chatUpdate']: () => void;
|
|
3464
|
+
['pollsUpdate']: () => void;
|
|
3465
|
+
['pluginsUpdate']: () => void;
|
|
3466
|
+
['permissionsUpdate']: (patch: PresetUpdates) => void;
|
|
3467
|
+
['*']: () => void;
|
|
3385
3468
|
};
|
|
3386
|
-
declare class
|
|
3387
|
-
|
|
3388
|
-
|
|
3389
|
-
|
|
3390
|
-
|
|
3391
|
-
readonly
|
|
3392
|
-
|
|
3393
|
-
|
|
3394
|
-
|
|
3395
|
-
|
|
3396
|
-
|
|
3397
|
-
|
|
3398
|
-
|
|
3399
|
-
|
|
3400
|
-
|
|
3401
|
-
|
|
3402
|
-
|
|
3403
|
-
|
|
3404
|
-
|
|
3405
|
-
|
|
3406
|
-
|
|
3407
|
-
|
|
3408
|
-
|
|
3409
|
-
|
|
3410
|
-
|
|
3411
|
-
|
|
3412
|
-
|
|
3413
|
-
|
|
3414
|
-
|
|
3415
|
-
|
|
3416
|
-
|
|
3417
|
-
|
|
3418
|
-
|
|
3419
|
-
|
|
3420
|
-
|
|
3421
|
-
|
|
3422
|
-
|
|
3423
|
-
|
|
3424
|
-
|
|
3425
|
-
|
|
3426
|
-
|
|
3427
|
-
|
|
3428
|
-
|
|
3429
|
-
|
|
3430
|
-
|
|
3431
|
-
|
|
3432
|
-
|
|
3433
|
-
|
|
3434
|
-
|
|
3435
|
-
|
|
3436
|
-
getMaxListeners(): number;
|
|
3437
|
-
setMaxListeners(n: number): RTKTypedEventEmitter<{
|
|
3438
|
-
[K in keyof T]: (obj: U, ...args: Parameters<T[K]>) => ReturnType<T[K]>;
|
|
3439
|
-
} & {
|
|
3440
|
-
"*": (event: String, ...args: any[]) => void;
|
|
3441
|
-
} & V>;
|
|
3442
|
-
eventNames(): (string | symbol)[];
|
|
3443
|
-
add(obj: U, emitEvent?: boolean): this;
|
|
3444
|
-
set(objId: string, obj: U, emitEvent?: boolean): this;
|
|
3445
|
-
delete(objId: string, emitEvent?: boolean, removeListeners?: boolean): boolean;
|
|
3446
|
-
clear(emitEvent?: boolean, removeListeners?: boolean): void;
|
|
3447
|
-
toArray(): U[];
|
|
3448
|
-
}
|
|
3449
|
-
type ParticipantMapEvents = {
|
|
3450
|
-
['participantJoined']: (payload: RTKParticipant$1) => void;
|
|
3451
|
-
['participantLeft']: (payload: RTKParticipant$1) => void;
|
|
3452
|
-
['participantsCleared']: () => void;
|
|
3453
|
-
['participantsUpdate']: () => void;
|
|
3454
|
-
['kicked']: (payload: {
|
|
3455
|
-
id: string;
|
|
3456
|
-
}) => void;
|
|
3457
|
-
};
|
|
3458
|
-
declare class RTKParticipantMap$1<T extends Pick<RTKParticipant$1, 'id' | keyof RTKTypedEventEmitter<ParticipantEvents>> = RTKParticipant$1> extends RTKMap<ParticipantEvents, T, ParticipantMapEvents> {
|
|
3459
|
-
constructor(options?: RTKMapEvents<ParticipantMapEvents>);
|
|
3460
|
-
add(participant: T, emitEvent?: boolean): this;
|
|
3461
|
-
clear(emitEvent?: boolean, removeListeners?: boolean): void;
|
|
3462
|
-
delete(participantId: string, emitEvent?: boolean, removeListeners?: boolean): boolean;
|
|
3469
|
+
declare class RTKPermissionsPreset$1 extends RTKTypedEventEmitter<PermissionEvents> {
|
|
3470
|
+
private constructor();
|
|
3471
|
+
static fromResponse(response: PresetPermissions, viewType: ViewType, context: Context<RTKContextState>): RTKPermissionsPreset$1;
|
|
3472
|
+
static default(context: Context<RTKContextState>, viewType: ViewType): RTKPermissionsPreset$1;
|
|
3473
|
+
static init(context: Context<RTKContextState>, viewType: ViewType, response?: PresetPermissions): RTKPermissionsPreset$1;
|
|
3474
|
+
readonly mediaRoomType: Readonly<MediaRoomType>;
|
|
3475
|
+
readonly stageEnabled: Readonly<boolean>;
|
|
3476
|
+
readonly acceptStageRequests: Readonly<boolean>;
|
|
3477
|
+
readonly stageAccess: Readonly<MediaProductionPermissionType>;
|
|
3478
|
+
readonly acceptWaitingRequests: Readonly<boolean>;
|
|
3479
|
+
readonly requestProduceVideo: Readonly<boolean>;
|
|
3480
|
+
readonly requestProduceAudio: Readonly<boolean>;
|
|
3481
|
+
readonly requestProduceScreenshare: Readonly<boolean>;
|
|
3482
|
+
readonly canAllowParticipantAudio: Readonly<boolean>;
|
|
3483
|
+
readonly canAllowParticipantScreensharing: Readonly<boolean>;
|
|
3484
|
+
readonly canAllowParticipantVideo: Readonly<boolean>;
|
|
3485
|
+
readonly canDisableParticipantAudio: Readonly<boolean>;
|
|
3486
|
+
readonly canDisableParticipantVideo: Readonly<boolean>;
|
|
3487
|
+
readonly kickParticipant: Readonly<boolean>;
|
|
3488
|
+
readonly pinParticipant: Readonly<boolean>;
|
|
3489
|
+
readonly canRecord: Readonly<boolean>;
|
|
3490
|
+
readonly waitingRoomType: Readonly<WaitingRoomTypes>;
|
|
3491
|
+
readonly waitingRoomBehaviour: Readonly<WaitingRoomTypes>;
|
|
3492
|
+
readonly plugins: Readonly<PresetPermissions['plugins']>;
|
|
3493
|
+
readonly polls: Readonly<PresetPermissions['polls']>;
|
|
3494
|
+
readonly produceVideo: Readonly<MediaProductionPermissionType>;
|
|
3495
|
+
readonly requestProduce: Readonly<boolean>;
|
|
3496
|
+
readonly canProduceVideo: Readonly<MediaProductionPermissionType>;
|
|
3497
|
+
readonly produceScreenshare: Readonly<MediaProductionPermissionType>;
|
|
3498
|
+
readonly canProduceScreenshare: Readonly<MediaProductionPermissionType>;
|
|
3499
|
+
readonly produceAudio: Readonly<MediaProductionPermissionType>;
|
|
3500
|
+
readonly canProduceAudio: Readonly<MediaProductionPermissionType>;
|
|
3501
|
+
readonly chatPublic: Readonly<PresetPermissions['chat']['public']>;
|
|
3502
|
+
readonly chatPrivate: Readonly<PresetPermissions['chat']['private']>;
|
|
3503
|
+
readonly chatChannel: Readonly<PresetPermissions['chat']['channel']>;
|
|
3504
|
+
readonly chatMessage: Readonly<PresetPermissions['chat']['message']>;
|
|
3505
|
+
readonly connectedMeetings: Readonly<PresetPermissions['connectedMeetings']>;
|
|
3506
|
+
readonly hiddenParticipant: Readonly<boolean>;
|
|
3507
|
+
readonly showParticipantList: Readonly<boolean>;
|
|
3508
|
+
readonly canChangeParticipantRole: Readonly<boolean>;
|
|
3509
|
+
readonly canChangeParticipantPermissions: Readonly<boolean>;
|
|
3510
|
+
readonly canChangeTheme: Readonly<boolean>;
|
|
3511
|
+
readonly canPresent: Readonly<boolean>;
|
|
3512
|
+
readonly acceptPresentRequests: Readonly<boolean>;
|
|
3513
|
+
readonly canEditDisplayName: Readonly<boolean>;
|
|
3514
|
+
readonly maxScreenShareCount: Readonly<number>;
|
|
3515
|
+
readonly isRecorder: Readonly<boolean>;
|
|
3516
|
+
readonly canSpotlight: Readonly<boolean>;
|
|
3517
|
+
readonly canLivestream: Readonly<boolean>;
|
|
3518
|
+
readonly transcriptionEnabled: Readonly<boolean>;
|
|
3463
3519
|
}
|
|
3464
|
-
|
|
3465
|
-
|
|
3466
|
-
|
|
3467
|
-
"MANUAL"
|
|
3468
|
-
];
|
|
3469
|
-
type ViewMode = (typeof modes)[number];
|
|
3470
|
-
interface BroadcastMessagePayload {
|
|
3471
|
-
[key: string]: boolean | number | string | Date | ActiveTab;
|
|
3520
|
+
interface UserDetailsResponseV2 {
|
|
3521
|
+
participant: UserDetailsResponse;
|
|
3522
|
+
preset: PresetV2CamelCased;
|
|
3472
3523
|
}
|
|
3473
|
-
|
|
3474
|
-
|
|
3475
|
-
|
|
3476
|
-
|
|
3477
|
-
|
|
3524
|
+
type LeaveRoomState = 'kicked' | 'ended' | 'left' | 'rejected' | 'connected-meeting' | 'disconnected' | 'failed' | 'stageLeft';
|
|
3525
|
+
declare class RTKSelfMedia$1 extends RTKTypedEventEmitter<SelfEvents> {
|
|
3526
|
+
readonly peerId: string;
|
|
3527
|
+
init(options?: {
|
|
3528
|
+
video?: boolean;
|
|
3529
|
+
audio?: boolean;
|
|
3530
|
+
constraints?: MediaConstraints;
|
|
3531
|
+
}, skipAwaits?: boolean, context?: Context<RTKContextState>): Promise<void>;
|
|
3532
|
+
context: Context<RTKContextState>;
|
|
3533
|
+
readonly audioTrack: MediaStreamTrack;
|
|
3534
|
+
readonly rawAudioTrack: MediaStreamTrack;
|
|
3535
|
+
readonly mediaPermissions: {
|
|
3536
|
+
audio?: MediaPermission$1;
|
|
3537
|
+
video?: MediaPermission$1;
|
|
3538
|
+
screenshare?: MediaPermission$1;
|
|
3539
|
+
};
|
|
3540
|
+
addAudioMiddleware(audioMiddleware: AudioMiddleware): Promise<{
|
|
3541
|
+
success: boolean;
|
|
3542
|
+
message: string;
|
|
3543
|
+
}>;
|
|
3544
|
+
removeAudioMiddleware(audioMiddleware: AudioMiddleware): Promise<{
|
|
3545
|
+
success: boolean;
|
|
3546
|
+
message: string;
|
|
3547
|
+
}>;
|
|
3548
|
+
removeAllAudioMiddlewares(): Promise<{
|
|
3549
|
+
success: boolean;
|
|
3550
|
+
message: string;
|
|
3551
|
+
}>;
|
|
3552
|
+
readonly videoTrack: MediaStreamTrack;
|
|
3553
|
+
readonly rawVideoTrack: MediaStreamTrack;
|
|
3554
|
+
addVideoMiddleware(videoMiddleware: VideoMiddleware): Promise<{
|
|
3555
|
+
success: boolean;
|
|
3556
|
+
message: string;
|
|
3557
|
+
}>;
|
|
3558
|
+
setVideoMiddlewareGlobalConfig(config?: VideoMiddlewareGlobalConfig): Promise<void>;
|
|
3559
|
+
removeVideoMiddleware(videoMiddleware: VideoMiddleware): Promise<{
|
|
3560
|
+
success: boolean;
|
|
3561
|
+
message: string;
|
|
3562
|
+
}>;
|
|
3563
|
+
removeAllVideoMiddlewares(): Promise<{
|
|
3564
|
+
success: boolean;
|
|
3565
|
+
message: string;
|
|
3566
|
+
}>;
|
|
3567
|
+
readonly screenShareTracks: {
|
|
3568
|
+
audio: MediaStreamTrack;
|
|
3569
|
+
video: MediaStreamTrack;
|
|
3570
|
+
};
|
|
3571
|
+
readonly audioEnabled: boolean;
|
|
3572
|
+
readonly videoEnabled: boolean;
|
|
3573
|
+
readonly screenShareEnabled: boolean;
|
|
3574
|
+
enableAudio(): Promise<void>;
|
|
3575
|
+
enableVideo(): Promise<void>;
|
|
3576
|
+
disableAudio(): Promise<void>;
|
|
3577
|
+
enableScreenShare(): Promise<void>;
|
|
3578
|
+
disableScreenShare(): Promise<void>;
|
|
3579
|
+
disableVideo(): Promise<void>;
|
|
3580
|
+
getCurrentDevices(): {
|
|
3581
|
+
audio: MediaDeviceInfo;
|
|
3582
|
+
video: MediaDeviceInfo;
|
|
3583
|
+
speaker: MediaDeviceInfo;
|
|
3584
|
+
};
|
|
3585
|
+
getAudioDevices(): Promise<MediaDeviceInfo[]>;
|
|
3586
|
+
getVideoDevices(): Promise<MediaDeviceInfo[]>;
|
|
3587
|
+
getSpeakerDevices(): Promise<MediaDeviceInfo[]>;
|
|
3588
|
+
getDeviceById(deviceId: string, kind: 'audio' | 'video' | 'speaker'): Promise<MediaDeviceInfo>;
|
|
3589
|
+
setDevice(device: MediaDeviceInfo): Promise<void>;
|
|
3478
3590
|
}
|
|
3479
|
-
|
|
3480
|
-
participantIds: string[];
|
|
3481
|
-
} | {
|
|
3482
|
-
presetNames: string[];
|
|
3483
|
-
} | {
|
|
3484
|
-
meetingIds: string[];
|
|
3485
|
-
};
|
|
3486
|
-
type JoinedPeer = {
|
|
3591
|
+
interface UserDetailsResponse {
|
|
3487
3592
|
id: string;
|
|
3488
|
-
userId: string;
|
|
3489
3593
|
name: string;
|
|
3490
|
-
|
|
3491
|
-
customParticipantId?: string;
|
|
3492
|
-
presetId?: string;
|
|
3594
|
+
email: string;
|
|
3493
3595
|
picture?: string;
|
|
3494
|
-
|
|
3495
|
-
|
|
3496
|
-
|
|
3497
|
-
|
|
3498
|
-
|
|
3499
|
-
};
|
|
3500
|
-
flags?: {
|
|
3501
|
-
hiddenParticipant?: boolean;
|
|
3502
|
-
recorder?: boolean;
|
|
3503
|
-
};
|
|
3504
|
-
};
|
|
3505
|
-
type ParticipantsEvents = {
|
|
3506
|
-
['viewModeChanged']: (payload: {
|
|
3507
|
-
viewMode: string;
|
|
3508
|
-
currentPage: number;
|
|
3509
|
-
pageCount: number;
|
|
3510
|
-
}) => void;
|
|
3511
|
-
['activeSpeaker']: (payload: {
|
|
3512
|
-
peerId: string;
|
|
3513
|
-
volume: number;
|
|
3514
|
-
}) => void;
|
|
3515
|
-
['broadcastedMessage']: (payload: {
|
|
3516
|
-
type: string;
|
|
3517
|
-
payload: BroadcastMessagePayload;
|
|
3518
|
-
timestamp: number;
|
|
3519
|
-
}) => void;
|
|
3520
|
-
['poorConnection']: (payload: {
|
|
3521
|
-
participantId: string;
|
|
3522
|
-
score: number;
|
|
3523
|
-
kind: string;
|
|
3524
|
-
}) => void;
|
|
3525
|
-
['pageChanged']: (payload: {
|
|
3526
|
-
viewMode: string;
|
|
3527
|
-
currentPage: number;
|
|
3528
|
-
pageCount: number;
|
|
3529
|
-
}) => void;
|
|
3530
|
-
['mediaScoreUpdate']: (payload: {
|
|
3531
|
-
kind: string;
|
|
3532
|
-
isScreenshare: boolean;
|
|
3533
|
-
score: number;
|
|
3534
|
-
participantId: string;
|
|
3535
|
-
scoreStats: ConsumerScoreStats;
|
|
3536
|
-
}) => void;
|
|
3537
|
-
['media_decode_error']: (payload: {
|
|
3538
|
-
reason: string;
|
|
3539
|
-
code: '1702' | '1703';
|
|
3540
|
-
}) => void;
|
|
3541
|
-
['*']: (event: string, ...args: any[]) => void;
|
|
3542
|
-
};
|
|
3543
|
-
declare class RTKParticipants$1 extends RTKTypedEventEmitter<ParticipantsEvents> {
|
|
3544
|
-
readonly waitlisted: Readonly<RTKParticipantMap$1<Pick<RTKParticipant$1, Exclude<keyof RTKParticipant$1, 'audioTrack' | 'videoTrack' | 'screenShareTracks'>>>>;
|
|
3545
|
-
readonly joined: Readonly<RTKParticipantMap$1>;
|
|
3546
|
-
readonly active: Readonly<RTKParticipantMap$1>;
|
|
3547
|
-
readonly videoSubscribed: Readonly<RTKParticipantMap$1>;
|
|
3548
|
-
readonly audioSubscribed: Readonly<RTKParticipantMap$1>;
|
|
3549
|
-
readonly pinned: Readonly<RTKParticipantMap$1>;
|
|
3550
|
-
readonly all: Readonly<RTKBasicParticipantsMap>;
|
|
3551
|
-
readonly pip: RTKPip;
|
|
3552
|
-
rateLimitConfig: {
|
|
3553
|
-
maxInvocations: number;
|
|
3554
|
-
period: number;
|
|
3555
|
-
};
|
|
3556
|
-
readonly rateLimits: {
|
|
3557
|
-
maxInvocations: number;
|
|
3558
|
-
period: number;
|
|
3559
|
-
};
|
|
3560
|
-
updateRateLimits(num: number, period: number): void;
|
|
3561
|
-
viewMode: ViewMode;
|
|
3562
|
-
currentPage: number;
|
|
3563
|
-
lastActiveSpeaker: string;
|
|
3564
|
-
selectedPeers: RTKSelectedPeers;
|
|
3565
|
-
constructor(context: Context<RTKContextState>, self: RTKSelf$1, roomSocketHandler: RoomSocketHandler);
|
|
3566
|
-
setupEvents(): void;
|
|
3567
|
-
readonly count: number;
|
|
3568
|
-
readonly maxActiveParticipantsCount: number;
|
|
3569
|
-
setMaxActiveParticipantsCount(limit: number): void;
|
|
3570
|
-
readonly pageCount: number;
|
|
3571
|
-
acceptWaitingRoomRequest(id: string): void;
|
|
3572
|
-
acceptAllWaitingRoomRequest(userIds: string[]): Promise<void>;
|
|
3573
|
-
rejectWaitingRoomRequest(id: string): Promise<void>;
|
|
3574
|
-
setViewMode(viewMode: ViewMode): Promise<void>;
|
|
3575
|
-
subscribe(peerIds: string[], kinds?: ('audio' | 'video' | 'screenshareAudio' | 'screenshareVideo')[]): Promise<void>;
|
|
3576
|
-
unsubscribe(peerIds: string[], kinds?: ('audio' | 'video' | 'screenshareAudio' | 'screenshareVideo')[]): Promise<void>;
|
|
3577
|
-
getPeerIdsForCurrentPage(): string[];
|
|
3578
|
-
setPage(page: number): Promise<void>;
|
|
3579
|
-
disableAllAudio(allowUnmute: boolean): Promise<void>;
|
|
3580
|
-
disableAllVideo(): Promise<void>;
|
|
3581
|
-
disableAudio(participantId: string): Promise<void>;
|
|
3582
|
-
disableVideo(participantId: string): Promise<void>;
|
|
3583
|
-
kick(participantId: string): Promise<void>;
|
|
3584
|
-
kickAll(): Promise<void>;
|
|
3585
|
-
broadcastMessage(type: Exclude<string, 'spotlight'>, payload: BroadcastMessagePayload, target?: BroadcastMessageTarget): Promise<void>;
|
|
3586
|
-
getAllJoinedPeers(searchQuery: string, limit: number, offset: number): Promise<{
|
|
3587
|
-
id: string;
|
|
3588
|
-
userId: string;
|
|
3589
|
-
name: string;
|
|
3590
|
-
displayName: string;
|
|
3591
|
-
stageType: StageStatus;
|
|
3592
|
-
customParticipantId: string;
|
|
3593
|
-
presetId: string;
|
|
3594
|
-
picture: string;
|
|
3595
|
-
waitlisted: boolean;
|
|
3596
|
-
stageStatus: StageStatus;
|
|
3597
|
-
metadata: {
|
|
3598
|
-
preset_name: string;
|
|
3599
|
-
};
|
|
3600
|
-
recorderType: string;
|
|
3601
|
-
flags: {
|
|
3602
|
-
hiddenParticipant: boolean;
|
|
3603
|
-
hidden_participant: boolean;
|
|
3604
|
-
recorder: boolean;
|
|
3605
|
-
};
|
|
3606
|
-
}[]>;
|
|
3607
|
-
updatePermissions(participantIds: string[], permissions: PresetUpdates): Promise<void>;
|
|
3608
|
-
getParticipantsInMeetingPreJoin(): Promise<RoomPeersInfoResponse>;
|
|
3609
|
-
}
|
|
3610
|
-
interface FetchRequestConfig {
|
|
3611
|
-
baseURL?: string;
|
|
3612
|
-
url?: string;
|
|
3613
|
-
method?: string;
|
|
3614
|
-
headers?: Record<string, string>;
|
|
3615
|
-
timeout?: number;
|
|
3616
|
-
retry?: number;
|
|
3617
|
-
retryDelay?: number;
|
|
3618
|
-
responseType?: string;
|
|
3619
|
-
data?: any;
|
|
3620
|
-
params?: Record<string, string>;
|
|
3621
|
-
}
|
|
3622
|
-
interface FetchResponse<T = any> {
|
|
3623
|
-
data: T;
|
|
3624
|
-
status: number;
|
|
3625
|
-
statusText: string;
|
|
3626
|
-
headers: Record<string, string>;
|
|
3627
|
-
config: FetchRequestConfig;
|
|
3628
|
-
}
|
|
3629
|
-
declare class FetchClient {
|
|
3630
|
-
defaults: {
|
|
3631
|
-
baseURL: string;
|
|
3632
|
-
headers: {
|
|
3633
|
-
common: Record<string, string>;
|
|
3634
|
-
};
|
|
3635
|
-
timeout: number;
|
|
3636
|
-
retry: number;
|
|
3637
|
-
retryDelay: number;
|
|
3638
|
-
};
|
|
3639
|
-
constructor(options: {
|
|
3640
|
-
baseURL: string;
|
|
3641
|
-
timeout: number;
|
|
3642
|
-
retry: number;
|
|
3643
|
-
retryDelay: number;
|
|
3644
|
-
responseType?: string;
|
|
3645
|
-
});
|
|
3646
|
-
request<T = any>(config: FetchRequestConfig): Promise<FetchResponse<T>>;
|
|
3647
|
-
get<T = any>(url: string, config?: FetchRequestConfig): Promise<FetchResponse<T>>;
|
|
3648
|
-
post<T = any>(url: string, data?: any, config?: FetchRequestConfig): Promise<FetchResponse<T>>;
|
|
3649
|
-
put<T = any>(url: string, data?: any, config?: FetchRequestConfig): Promise<FetchResponse<T>>;
|
|
3650
|
-
}
|
|
3651
|
-
interface ResponseStatus {
|
|
3652
|
-
success: boolean;
|
|
3653
|
-
message: string;
|
|
3596
|
+
loggedIn?: boolean;
|
|
3597
|
+
scope?: string[];
|
|
3598
|
+
clientSpecificId?: string;
|
|
3599
|
+
customParticipantId?: string;
|
|
3600
|
+
organizationId?: string;
|
|
3654
3601
|
}
|
|
3655
|
-
|
|
3656
|
-
|
|
3657
|
-
|
|
3658
|
-
|
|
3659
|
-
|
|
3660
|
-
|
|
3661
|
-
|
|
3662
|
-
|
|
3663
|
-
|
|
3602
|
+
declare class RTKSelf$1 extends RTKSelfMedia$1 {
|
|
3603
|
+
name: string;
|
|
3604
|
+
picture: string;
|
|
3605
|
+
customParticipantId: string;
|
|
3606
|
+
waitlistStatus: 'accepted' | 'waiting' | 'rejected' | 'none';
|
|
3607
|
+
role: any;
|
|
3608
|
+
userId: string;
|
|
3609
|
+
organizationId: string;
|
|
3610
|
+
supportsRemoteControl: boolean;
|
|
3611
|
+
device: DeviceConfig;
|
|
3612
|
+
readonly telemetry: RTKTelemetry;
|
|
3613
|
+
hidden: boolean;
|
|
3614
|
+
readonly stageStatus: StageStatus;
|
|
3615
|
+
readonly id: string;
|
|
3616
|
+
readonly peerId: string;
|
|
3617
|
+
presetName: string;
|
|
3618
|
+
roomState: 'init' | 'joined' | 'waitlisted' | LeaveRoomState;
|
|
3619
|
+
private constructor();
|
|
3620
|
+
static __init__(context: Context<RTKContextState>, details: UserDetailsResponse, permissions: RTKPermissionsPreset$1, theme: RTKThemePreset$1, presetName: string, skipAwaits?: boolean): Promise<RTKSelf$1>;
|
|
3621
|
+
cleanupEvents(): void;
|
|
3622
|
+
readonly permissions: RTKPermissionsPreset$1;
|
|
3623
|
+
readonly config: RTKThemePreset$1;
|
|
3624
|
+
readonly roomJoined: boolean;
|
|
3625
|
+
setName(name: string): void;
|
|
3626
|
+
setupTracks(options?: {
|
|
3627
|
+
video?: boolean;
|
|
3628
|
+
audio?: boolean;
|
|
3629
|
+
forceReset?: boolean;
|
|
3664
3630
|
}): Promise<void>;
|
|
3665
|
-
|
|
3666
|
-
|
|
3667
|
-
video: MediaDeviceInfo;
|
|
3668
|
-
speaker: MediaDeviceInfo;
|
|
3669
|
-
};
|
|
3670
|
-
readonly permissions: {
|
|
3671
|
-
audio?: MediaPermission$1;
|
|
3672
|
-
video?: MediaPermission$1;
|
|
3673
|
-
screenshare?: MediaPermission$1;
|
|
3674
|
-
};
|
|
3675
|
-
getAllDevices(): Promise<InputDeviceInfo[]>;
|
|
3676
|
-
getDeviceById(deviceId: string, kind?: 'audioinput' | 'audiooutput' | 'videoinput'): Promise<MediaDeviceInfo>;
|
|
3677
|
-
readonly rawAudioTrack: MediaStreamTrack;
|
|
3678
|
-
readonly audioTrack: MediaStreamTrack;
|
|
3679
|
-
readonly audioEnabled: boolean;
|
|
3631
|
+
destructMediaHandler(): Promise<void>;
|
|
3632
|
+
removeDocumentEventListeners(): Promise<void>;
|
|
3680
3633
|
enableAudio(customTrack?: MediaStreamTrack): Promise<void>;
|
|
3681
|
-
disableAudio(): void;
|
|
3682
|
-
getAudioDevices(devices?: MediaDeviceInfo[]): Promise<MediaDeviceInfo[]>;
|
|
3683
|
-
setAudioDevice(device: MediaDeviceInfo): Promise<void>;
|
|
3684
|
-
setupSpeaker(): Promise<void>;
|
|
3685
|
-
setSpeakerDevice(device: MediaDeviceInfo): Promise<void>;
|
|
3686
|
-
readonly rawVideoTrack: MediaStreamTrack;
|
|
3687
|
-
readonly videoTrack: MediaStreamTrack;
|
|
3688
|
-
readonly videoEnabled: boolean;
|
|
3689
3634
|
enableVideo(customTrack?: MediaStreamTrack): Promise<void>;
|
|
3690
|
-
disableVideo(): void;
|
|
3691
|
-
getVideoDevices(devices?: MediaDeviceInfo[]): Promise<MediaDeviceInfo[]>;
|
|
3692
|
-
setVideoDevice(device: MediaDeviceInfo): Promise<void>;
|
|
3693
3635
|
updateVideoConstraints(resolution: VideoQualityConstraints): Promise<void>;
|
|
3694
|
-
readonly screenShareTracks: {
|
|
3695
|
-
audio: MediaStreamTrack;
|
|
3696
|
-
video: MediaStreamTrack;
|
|
3697
|
-
};
|
|
3698
|
-
readonly screenShareEnabled: boolean;
|
|
3699
3636
|
enableScreenShare(): Promise<void>;
|
|
3700
|
-
disableScreenShare(): Promise<void>;
|
|
3701
3637
|
updateScreenshareConstraints(resolution: VideoQualityConstraints): Promise<void>;
|
|
3702
|
-
|
|
3703
|
-
|
|
3704
|
-
|
|
3705
|
-
|
|
3706
|
-
|
|
3707
|
-
|
|
3708
|
-
|
|
3709
|
-
|
|
3710
|
-
|
|
3711
|
-
|
|
3712
|
-
|
|
3713
|
-
|
|
3714
|
-
|
|
3715
|
-
|
|
3716
|
-
|
|
3717
|
-
removeAudioTrack(): void;
|
|
3718
|
-
removeVideoTrack(): void;
|
|
3719
|
-
removeDocumentEventListeners(): Promise<void>;
|
|
3638
|
+
disableAudio(): Promise<void>;
|
|
3639
|
+
disableVideo(): Promise<void>;
|
|
3640
|
+
disableScreenShare(): Promise<void>;
|
|
3641
|
+
getAllDevices(): Promise<InputDeviceInfo[]>;
|
|
3642
|
+
setIsPinned(isPinned: boolean, emitEvent?: boolean): void;
|
|
3643
|
+
readonly isPinned: boolean;
|
|
3644
|
+
pin(): Promise<void>;
|
|
3645
|
+
unpin(): Promise<void>;
|
|
3646
|
+
hide(): Promise<void>;
|
|
3647
|
+
show(): void;
|
|
3648
|
+
setDevice(device: MediaDeviceInfo): Promise<void>;
|
|
3649
|
+
cleanUpTracks(): void;
|
|
3650
|
+
playAudio(): Promise<void>;
|
|
3651
|
+
registerVideoElement(videoElem: HTMLVideoElement, isPreview?: boolean): void;
|
|
3652
|
+
deregisterVideoElement(videoElem?: HTMLVideoElement, isPreview?: boolean): void;
|
|
3720
3653
|
}
|
|
3721
|
-
|
|
3722
|
-
|
|
3723
|
-
|
|
3724
|
-
|
|
3725
|
-
|
|
3726
|
-
SYSTEM_DENIED = 4,
|
|
3727
|
-
COULD_NOT_START = 5,
|
|
3728
|
-
NO_DEVICES_AVAILABLE = 6
|
|
3654
|
+
interface RTKBasicParticipant {
|
|
3655
|
+
userId: string;
|
|
3656
|
+
name?: string;
|
|
3657
|
+
picture?: string;
|
|
3658
|
+
customParticipantId: string;
|
|
3729
3659
|
}
|
|
3730
|
-
|
|
3731
|
-
|
|
3732
|
-
|
|
3733
|
-
|
|
3734
|
-
|
|
3735
|
-
|
|
3736
|
-
disablePerFrameCanvasRendering: boolean;
|
|
3737
|
-
};
|
|
3738
|
-
type PresetMediaConstraints = PresetV2CamelCased['config']['media'];
|
|
3739
|
-
type AudioQualityConstraints = {
|
|
3740
|
-
echoCancellation?: boolean;
|
|
3741
|
-
noiseSupression?: boolean;
|
|
3742
|
-
autoGainControl?: boolean;
|
|
3743
|
-
enableStereo?: boolean;
|
|
3744
|
-
enableHighBitrate?: boolean;
|
|
3745
|
-
};
|
|
3746
|
-
type VideoQualityConstraints = {
|
|
3747
|
-
width: {
|
|
3748
|
-
ideal: number;
|
|
3749
|
-
};
|
|
3750
|
-
height: {
|
|
3751
|
-
ideal: number;
|
|
3752
|
-
};
|
|
3753
|
-
frameRate?: {
|
|
3754
|
-
ideal: number;
|
|
3755
|
-
};
|
|
3756
|
-
};
|
|
3757
|
-
type ScreenshareQualityConstraints = {
|
|
3758
|
-
width?: {
|
|
3759
|
-
max: number;
|
|
3760
|
-
};
|
|
3761
|
-
height?: {
|
|
3762
|
-
max: number;
|
|
3763
|
-
};
|
|
3764
|
-
frameRate?: {
|
|
3765
|
-
ideal: number;
|
|
3766
|
-
max: number;
|
|
3767
|
-
};
|
|
3768
|
-
displaySurface?: 'window' | 'monitor' | 'browser';
|
|
3769
|
-
selfBrowserSurface?: 'include' | 'exclude';
|
|
3770
|
-
};
|
|
3771
|
-
interface RTKMediaTrackConstraints extends MediaTrackConstraints {
|
|
3772
|
-
optional?: Array<object>;
|
|
3660
|
+
declare class RTKBasicParticipantsMap extends RTKEventEmitter<'participantsUpdate'> {
|
|
3661
|
+
constructor(logger: RTKLogger$1);
|
|
3662
|
+
__set(objId: string, obj: RTKBasicParticipant): Map<string, RTKBasicParticipant>;
|
|
3663
|
+
__clear(): void;
|
|
3664
|
+
get(objId: string): RTKBasicParticipant;
|
|
3665
|
+
toArray(): RTKBasicParticipant[];
|
|
3773
3666
|
}
|
|
3774
|
-
|
|
3775
|
-
|
|
3667
|
+
type ChatChannelSocketMessage = GetChatChannelResponse;
|
|
3668
|
+
interface ChatChannel {
|
|
3669
|
+
id: string;
|
|
3670
|
+
displayName: string;
|
|
3671
|
+
memberIds: string[];
|
|
3672
|
+
displayPictureUrl?: string;
|
|
3673
|
+
visibility?: string;
|
|
3674
|
+
isDirectMessage?: boolean;
|
|
3675
|
+
latestMessage?: Message;
|
|
3676
|
+
unreadCount: number;
|
|
3776
3677
|
}
|
|
3777
|
-
|
|
3778
|
-
|
|
3779
|
-
|
|
3780
|
-
|
|
3781
|
-
|
|
3782
|
-
|
|
3783
|
-
|
|
3784
|
-
|
|
3785
|
-
|
|
3786
|
-
|
|
3787
|
-
|
|
3788
|
-
|
|
3789
|
-
|
|
3790
|
-
|
|
3791
|
-
|
|
3792
|
-
|
|
3793
|
-
|
|
3794
|
-
|
|
3795
|
-
|
|
3796
|
-
|
|
3797
|
-
|
|
3798
|
-
|
|
3799
|
-
|
|
3800
|
-
|
|
3801
|
-
|
|
3802
|
-
|
|
3803
|
-
|
|
3804
|
-
|
|
3805
|
-
|
|
3806
|
-
|
|
3807
|
-
|
|
3808
|
-
|
|
3809
|
-
|
|
3810
|
-
|
|
3811
|
-
|
|
3812
|
-
|
|
3813
|
-
disableParticipantAudio: boolean;
|
|
3814
|
-
disableParticipantScreensharing: boolean;
|
|
3815
|
-
disableParticipantVideo: boolean;
|
|
3816
|
-
kickParticipant: boolean;
|
|
3817
|
-
pinParticipant: boolean;
|
|
3818
|
-
plugins: {
|
|
3819
|
-
canClose: boolean;
|
|
3820
|
-
canStart: boolean;
|
|
3821
|
-
canEditConfig?: boolean;
|
|
3822
|
-
config: {
|
|
3823
|
-
[pluginId: string]: Partial<{
|
|
3824
|
-
accessControl: PluginAccessControls.FULL_ACCESS | PluginAccessControls.VIEW_ONLY;
|
|
3825
|
-
disabled: boolean;
|
|
3826
|
-
handlesViewOnly: boolean;
|
|
3827
|
-
}>;
|
|
3828
|
-
};
|
|
3829
|
-
};
|
|
3830
|
-
waitingRoomType: WaitingRoomTypes;
|
|
3831
|
-
polls: {
|
|
3832
|
-
canCreate: boolean;
|
|
3833
|
-
canVote: boolean;
|
|
3834
|
-
canView: boolean;
|
|
3835
|
-
};
|
|
3836
|
-
media: {
|
|
3837
|
-
video: {
|
|
3838
|
-
canProduce: MediaProductionPermissionType;
|
|
3839
|
-
};
|
|
3840
|
-
audio: {
|
|
3841
|
-
canProduce: MediaProductionPermissionType;
|
|
3842
|
-
};
|
|
3843
|
-
screenshare: {
|
|
3844
|
-
canProduce: MediaProductionPermissionType;
|
|
3845
|
-
};
|
|
3846
|
-
};
|
|
3847
|
-
chat: {
|
|
3848
|
-
public: {
|
|
3849
|
-
canSend: boolean;
|
|
3850
|
-
text: boolean;
|
|
3851
|
-
files: boolean;
|
|
3852
|
-
};
|
|
3853
|
-
private?: {
|
|
3854
|
-
canSend: boolean;
|
|
3855
|
-
canReceive: boolean;
|
|
3856
|
-
text: boolean;
|
|
3857
|
-
files: boolean;
|
|
3858
|
-
};
|
|
3859
|
-
channel?: {
|
|
3860
|
-
canCreate: 'NONE' | 'PRIVATE' | 'PUBLIC' | 'ALL';
|
|
3861
|
-
canDelete: 'NONE' | 'PRIVATE' | 'PUBLIC' | 'ALL';
|
|
3862
|
-
canUpdate: 'NONE' | 'PRIVATE' | 'PUBLIC' | 'ALL';
|
|
3863
|
-
canReadAll: boolean;
|
|
3864
|
-
};
|
|
3865
|
-
message?: {
|
|
3866
|
-
canDelete: 'NONE' | 'SELF' | 'ALL';
|
|
3867
|
-
canEdit: 'NONE' | 'SELF' | 'ALL';
|
|
3868
|
-
deleteCutoffTimeSeconds: number;
|
|
3869
|
-
editCutoffTimeSeconds: number;
|
|
3870
|
-
};
|
|
3871
|
-
};
|
|
3872
|
-
isRecorder?: boolean;
|
|
3873
|
-
recorderType: RecorderType$1;
|
|
3874
|
-
hiddenParticipant: boolean;
|
|
3875
|
-
showParticipantList: boolean;
|
|
3876
|
-
canChangeParticipantPermissions: boolean;
|
|
3877
|
-
connectedMeetings: {
|
|
3878
|
-
canAlterConnectedMeetings: boolean;
|
|
3879
|
-
canSwitchConnectedMeetings: boolean;
|
|
3880
|
-
canSwitchToParentMeeting: boolean;
|
|
3881
|
-
};
|
|
3882
|
-
acceptStageRequests?: boolean;
|
|
3883
|
-
stageEnabled?: boolean;
|
|
3884
|
-
stageAccess?: MediaProductionPermissionType;
|
|
3885
|
-
transcriptionEnabled: boolean;
|
|
3886
|
-
};
|
|
3887
|
-
ui: {
|
|
3888
|
-
designTokens: {
|
|
3889
|
-
borderRadius: BorderRadius;
|
|
3890
|
-
borderWidth: BorderWidth;
|
|
3891
|
-
colors: {
|
|
3892
|
-
brand: {
|
|
3893
|
-
300: string;
|
|
3894
|
-
400: string;
|
|
3895
|
-
500: string;
|
|
3896
|
-
600: string;
|
|
3897
|
-
700: string;
|
|
3898
|
-
};
|
|
3899
|
-
background: {
|
|
3900
|
-
600: string;
|
|
3901
|
-
700: string;
|
|
3902
|
-
800: string;
|
|
3903
|
-
900: string;
|
|
3904
|
-
1000: string;
|
|
3905
|
-
};
|
|
3906
|
-
danger: string;
|
|
3907
|
-
success: string;
|
|
3908
|
-
textOnBrand: string;
|
|
3909
|
-
text: string;
|
|
3910
|
-
videoBg: string;
|
|
3911
|
-
warning: string;
|
|
3912
|
-
};
|
|
3913
|
-
fontFamily?: string;
|
|
3914
|
-
googleFont?: string;
|
|
3915
|
-
logo?: string;
|
|
3916
|
-
spacingBase: number;
|
|
3917
|
-
theme: Theme;
|
|
3918
|
-
};
|
|
3919
|
-
configDiff: any;
|
|
3920
|
-
};
|
|
3921
|
-
version?: string;
|
|
3922
|
-
id?: string;
|
|
3923
|
-
name?: string;
|
|
3924
|
-
};
|
|
3925
|
-
type MaxVideoStreams = PresetV2CamelCased['config']['maxVideoStreams'];
|
|
3926
|
-
declare class RTKThemePreset$1 {
|
|
3927
|
-
private constructor();
|
|
3928
|
-
static fromResponse(preset: PresetV2CamelCased): RTKThemePreset$1;
|
|
3929
|
-
static default(): RTKThemePreset$1;
|
|
3930
|
-
static init(preset?: PresetV2CamelCased, useDefault?: boolean): RTKThemePreset$1;
|
|
3931
|
-
readonly setupScreen: Readonly<{
|
|
3932
|
-
isEnabled: boolean;
|
|
3933
|
-
}>;
|
|
3934
|
-
readonly waitingRoom: Readonly<{
|
|
3935
|
-
isEnabled: boolean;
|
|
3936
|
-
}>;
|
|
3937
|
-
readonly controlBar: Readonly<{
|
|
3938
|
-
isEnabled: boolean;
|
|
3939
|
-
elements?: {
|
|
3940
|
-
chat?: boolean;
|
|
3941
|
-
fullscreen?: boolean;
|
|
3942
|
-
invite?: boolean;
|
|
3943
|
-
layout?: boolean;
|
|
3944
|
-
participants?: boolean;
|
|
3945
|
-
plugins?: boolean;
|
|
3946
|
-
polls?: boolean;
|
|
3947
|
-
reactions?: boolean;
|
|
3948
|
-
screenshare?: boolean;
|
|
3949
|
-
};
|
|
3678
|
+
interface UpdateChannelRequestPayload {
|
|
3679
|
+
memberIds?: string[];
|
|
3680
|
+
displayName?: string;
|
|
3681
|
+
displayPictureUrl?: string;
|
|
3682
|
+
visibility?: string;
|
|
3683
|
+
}
|
|
3684
|
+
declare class ChatChannelSocketHandler {
|
|
3685
|
+
readonly telemetry: RTKTelemetry;
|
|
3686
|
+
readonly logger: RTKLogger$1;
|
|
3687
|
+
constructor(context: Context<RTKContextState>, socketService: SocketService);
|
|
3688
|
+
createChannel(displayName: string, memberIds: string[], displayPictureUrl?: string, visibility?: string, isDirectMessage?: boolean): Promise<ChatChannel>;
|
|
3689
|
+
updateChannel(channelId: string, payload: UpdateChannelRequestPayload): Promise<ChatChannel>;
|
|
3690
|
+
static formatChannel(socketChannel: ChatChannel$1): ChatChannel;
|
|
3691
|
+
getChannelMembers(channelId: string): Promise<RTKBasicParticipant[]>;
|
|
3692
|
+
on(event: number, handler: (socketMessage: ChatChannelSocketMessage) => void): void;
|
|
3693
|
+
}
|
|
3694
|
+
declare enum ChatMessageType {
|
|
3695
|
+
TEXT = 0,
|
|
3696
|
+
IMAGE = 1,
|
|
3697
|
+
FILE = 2,
|
|
3698
|
+
CUSTOM = 3
|
|
3699
|
+
}
|
|
3700
|
+
type ChatSocketMessage = SendChatMessageToRoomResponse | SendChatMessageToPeersResponse | EditChatMessageResponse | DeleteChatMessageResponse;
|
|
3701
|
+
interface SearchFilters {
|
|
3702
|
+
channelId?: string;
|
|
3703
|
+
timestamp?: number;
|
|
3704
|
+
size?: number;
|
|
3705
|
+
reversed?: boolean;
|
|
3706
|
+
}
|
|
3707
|
+
declare class ChatSocketHandler {
|
|
3708
|
+
readonly telemetry: RTKTelemetry;
|
|
3709
|
+
readonly logger: RTKLogger$1;
|
|
3710
|
+
constructor(context: Context<RTKContextState>, socketService: SocketService);
|
|
3711
|
+
getChatMessages(): Promise<{
|
|
3712
|
+
id: string;
|
|
3713
|
+
payload: Uint8Array;
|
|
3950
3714
|
}>;
|
|
3951
|
-
|
|
3952
|
-
|
|
3953
|
-
|
|
3954
|
-
|
|
3955
|
-
|
|
3956
|
-
|
|
3957
|
-
|
|
3958
|
-
|
|
3959
|
-
|
|
3715
|
+
getChatMessagesPaginated(timeStamp: number, size: number, reversed: boolean, offset?: number, channelId?: string): Promise<GetPaginatedChatMessageRoomResponse>;
|
|
3716
|
+
sendMessageToRoom(message: string, messageType: ChatMessageType): void;
|
|
3717
|
+
sendMessageToPeers(message: string, messageType: ChatMessageType, peerIds: string[]): void;
|
|
3718
|
+
sendMessageToChannel(message: string, messageType: ChatMessageType, channelId: string): void;
|
|
3719
|
+
sendMessage(message: string, messageType: ChatMessageType, peerIds?: string[], channelId?: string): void;
|
|
3720
|
+
editMessage(chatId: string, message: string, payloadType: ChatMessageType, channelId?: string, pinned?: boolean): Promise<ChatMessage>;
|
|
3721
|
+
deleteMessage(chatId: string, channelId?: string): Promise<{
|
|
3722
|
+
channelId?: string;
|
|
3723
|
+
id: string;
|
|
3960
3724
|
}>;
|
|
3961
|
-
|
|
3962
|
-
|
|
3963
|
-
|
|
3964
|
-
|
|
3965
|
-
|
|
3966
|
-
readonly plugins: Readonly<string[]>;
|
|
3967
|
-
readonly disabledPlugins: Readonly<string[]>;
|
|
3968
|
-
readonly designTokens: Readonly<PresetV2CamelCased['ui']['designTokens']>;
|
|
3969
|
-
readonly configDiff: Readonly<PresetV2CamelCased['ui']['configDiff']>;
|
|
3970
|
-
readonly mediaConstraints: Readonly<PresetMediaConstraints>;
|
|
3971
|
-
readonly name: string;
|
|
3725
|
+
searchMessages(query: string, filters: SearchFilters): Promise<ChatMessage[]>;
|
|
3726
|
+
getAllChannels(): Promise<ChatChannel[]>;
|
|
3727
|
+
markLastReadMessage(channelId: string, message: Message): Promise<string>;
|
|
3728
|
+
setPinState(message: Message, pin: boolean): Promise<PinChatMessageResponse>;
|
|
3729
|
+
on(event: number, handler: (socketMessage: ChatSocketMessage) => void): void;
|
|
3972
3730
|
}
|
|
3973
|
-
|
|
3974
|
-
|
|
3975
|
-
|
|
3976
|
-
|
|
3977
|
-
|
|
3978
|
-
[
|
|
3979
|
-
|
|
3980
|
-
[
|
|
3981
|
-
};
|
|
3982
|
-
declare class RTKPermissionsPreset$1 extends RTKTypedEventEmitter<PermissionEvents> {
|
|
3983
|
-
private constructor();
|
|
3984
|
-
static fromResponse(response: PresetPermissions, viewType: ViewType, context: Context<RTKContextState>): RTKPermissionsPreset$1;
|
|
3985
|
-
static default(context: Context<RTKContextState>, viewType: ViewType): RTKPermissionsPreset$1;
|
|
3986
|
-
static init(context: Context<RTKContextState>, viewType: ViewType, response?: PresetPermissions): RTKPermissionsPreset$1;
|
|
3987
|
-
readonly mediaRoomType: Readonly<MediaRoomType>;
|
|
3988
|
-
readonly stageEnabled: Readonly<boolean>;
|
|
3989
|
-
readonly acceptStageRequests: Readonly<boolean>;
|
|
3990
|
-
readonly stageAccess: Readonly<MediaProductionPermissionType>;
|
|
3991
|
-
readonly acceptWaitingRequests: Readonly<boolean>;
|
|
3992
|
-
readonly requestProduceVideo: Readonly<boolean>;
|
|
3993
|
-
readonly requestProduceAudio: Readonly<boolean>;
|
|
3994
|
-
readonly requestProduceScreenshare: Readonly<boolean>;
|
|
3995
|
-
readonly canAllowParticipantAudio: Readonly<boolean>;
|
|
3996
|
-
readonly canAllowParticipantScreensharing: Readonly<boolean>;
|
|
3997
|
-
readonly canAllowParticipantVideo: Readonly<boolean>;
|
|
3998
|
-
readonly canDisableParticipantAudio: Readonly<boolean>;
|
|
3999
|
-
readonly canDisableParticipantVideo: Readonly<boolean>;
|
|
4000
|
-
readonly kickParticipant: Readonly<boolean>;
|
|
4001
|
-
readonly pinParticipant: Readonly<boolean>;
|
|
4002
|
-
readonly canRecord: Readonly<boolean>;
|
|
4003
|
-
readonly waitingRoomType: Readonly<WaitingRoomTypes>;
|
|
4004
|
-
readonly waitingRoomBehaviour: Readonly<WaitingRoomTypes>;
|
|
4005
|
-
readonly plugins: Readonly<PresetPermissions['plugins']>;
|
|
4006
|
-
readonly polls: Readonly<PresetPermissions['polls']>;
|
|
4007
|
-
readonly produceVideo: Readonly<MediaProductionPermissionType>;
|
|
4008
|
-
readonly requestProduce: Readonly<boolean>;
|
|
4009
|
-
readonly canProduceVideo: Readonly<MediaProductionPermissionType>;
|
|
4010
|
-
readonly produceScreenshare: Readonly<MediaProductionPermissionType>;
|
|
4011
|
-
readonly canProduceScreenshare: Readonly<MediaProductionPermissionType>;
|
|
4012
|
-
readonly produceAudio: Readonly<MediaProductionPermissionType>;
|
|
4013
|
-
readonly canProduceAudio: Readonly<MediaProductionPermissionType>;
|
|
4014
|
-
readonly chatPublic: Readonly<PresetPermissions['chat']['public']>;
|
|
4015
|
-
readonly chatPrivate: Readonly<PresetPermissions['chat']['private']>;
|
|
4016
|
-
readonly chatChannel: Readonly<PresetPermissions['chat']['channel']>;
|
|
4017
|
-
readonly chatMessage: Readonly<PresetPermissions['chat']['message']>;
|
|
4018
|
-
readonly connectedMeetings: Readonly<PresetPermissions['connectedMeetings']>;
|
|
4019
|
-
readonly hiddenParticipant: Readonly<boolean>;
|
|
4020
|
-
readonly showParticipantList: Readonly<boolean>;
|
|
4021
|
-
readonly canChangeParticipantRole: Readonly<boolean>;
|
|
4022
|
-
readonly canChangeParticipantPermissions: Readonly<boolean>;
|
|
4023
|
-
readonly canChangeTheme: Readonly<boolean>;
|
|
4024
|
-
readonly canPresent: Readonly<boolean>;
|
|
4025
|
-
readonly acceptPresentRequests: Readonly<boolean>;
|
|
4026
|
-
readonly canEditDisplayName: Readonly<boolean>;
|
|
4027
|
-
readonly maxScreenShareCount: Readonly<number>;
|
|
4028
|
-
readonly isRecorder: Readonly<boolean>;
|
|
4029
|
-
readonly canSpotlight: Readonly<boolean>;
|
|
4030
|
-
readonly canLivestream: Readonly<boolean>;
|
|
4031
|
-
readonly transcriptionEnabled: Readonly<boolean>;
|
|
4032
|
-
}
|
|
4033
|
-
interface UserDetailsResponseV2 {
|
|
4034
|
-
participant: UserDetailsResponse;
|
|
4035
|
-
preset: PresetV2CamelCased;
|
|
3731
|
+
declare class RTKSelectedPeers {
|
|
3732
|
+
constructor();
|
|
3733
|
+
add(peerId: string, priority: number, context: Context<RTKContextState>): number;
|
|
3734
|
+
delete(peerId: string, context: Context<RTKContextState>): void;
|
|
3735
|
+
index(peerId: string): number;
|
|
3736
|
+
readonly peers: string[];
|
|
3737
|
+
readonly compulsoryPeers: string[];
|
|
3738
|
+
readonly activeSpeakerPeers: string[];
|
|
4036
3739
|
}
|
|
4037
|
-
type
|
|
4038
|
-
|
|
4039
|
-
|
|
4040
|
-
['
|
|
4041
|
-
['
|
|
3740
|
+
type PipEvents = {
|
|
3741
|
+
['cameraToggled']: () => void;
|
|
3742
|
+
['micToggled']: () => void;
|
|
3743
|
+
['hangup']: () => void;
|
|
3744
|
+
['pipStarted']: () => void;
|
|
3745
|
+
['pipEnded']: () => void;
|
|
4042
3746
|
['*']: (eventName: string, ...args: any[]) => void;
|
|
4043
3747
|
};
|
|
4044
|
-
|
|
4045
|
-
|
|
4046
|
-
|
|
4047
|
-
|
|
4048
|
-
|
|
4049
|
-
|
|
3748
|
+
declare class RTKPip extends RTKTypedEventEmitter<PipEvents> {
|
|
3749
|
+
private constructor();
|
|
3750
|
+
static _init(context: Context<RTKContextState>, self: RTKSelf$1): Promise<RTKPip>;
|
|
3751
|
+
overrideIcon(icon: 'handRaise' | 'pin', value: string): Promise<void>;
|
|
3752
|
+
isSupported(): boolean;
|
|
3753
|
+
readonly isActive: boolean;
|
|
3754
|
+
init({ height, width }?: {
|
|
3755
|
+
height?: number;
|
|
3756
|
+
width?: number;
|
|
3757
|
+
}): void;
|
|
3758
|
+
enableSource(source: string): void;
|
|
3759
|
+
disableSource(source: string): void;
|
|
3760
|
+
addSource(id: string, element: HTMLVideoElement, enabled: boolean, pinned?: boolean, displayText?: string, imageUrl?: string, handRaised?: boolean): void;
|
|
3761
|
+
updateSource(id: string, source: any): void;
|
|
3762
|
+
removeSource(id: string): void;
|
|
3763
|
+
removePinnedSource(): void;
|
|
3764
|
+
removeAllSources(): void;
|
|
3765
|
+
enable(): void;
|
|
3766
|
+
disable: (partial?: boolean) => void;
|
|
4050
3767
|
}
|
|
4051
|
-
type
|
|
4052
|
-
|
|
4053
|
-
|
|
4054
|
-
|
|
4055
|
-
|
|
3768
|
+
type TranscriptionData = {
|
|
3769
|
+
id: string;
|
|
3770
|
+
name: string;
|
|
3771
|
+
peerId: string;
|
|
3772
|
+
userId: string;
|
|
3773
|
+
customParticipantId: string;
|
|
3774
|
+
transcript: string;
|
|
3775
|
+
isPartialTranscript: boolean;
|
|
3776
|
+
date: Date;
|
|
4056
3777
|
};
|
|
4057
|
-
|
|
4058
|
-
|
|
4059
|
-
|
|
4060
|
-
|
|
4061
|
-
|
|
4062
|
-
|
|
4063
|
-
|
|
4064
|
-
|
|
4065
|
-
|
|
4066
|
-
|
|
4067
|
-
|
|
4068
|
-
|
|
4069
|
-
|
|
4070
|
-
height?: number;
|
|
4071
|
-
width?: number;
|
|
4072
|
-
codec?: string;
|
|
4073
|
-
};
|
|
3778
|
+
type AiEvents = {
|
|
3779
|
+
['transcript']: (t: TranscriptionData) => void;
|
|
3780
|
+
['*']: (event: string, ...args: any[]) => void;
|
|
3781
|
+
};
|
|
3782
|
+
declare class RTKAi extends RTKTypedEventEmitter<AiEvents> {
|
|
3783
|
+
transcripts: TranscriptionData[];
|
|
3784
|
+
readonly telemetry: RTKTelemetry;
|
|
3785
|
+
constructor(context: Context<RTKContextState>);
|
|
3786
|
+
static init(context: Context<RTKContextState>, transcriptionEnabled: boolean): Promise<RTKAi>;
|
|
3787
|
+
static parseTranscript(transcriptData: string, isPartialTranscript?: boolean): TranscriptionData | undefined;
|
|
3788
|
+
static parseTranscripts(transcriptData: string): TranscriptionData[];
|
|
3789
|
+
getActiveTranscript(): Promise<void>;
|
|
3790
|
+
onTranscript(transcript: TranscriptionData): Promise<void>;
|
|
4074
3791
|
}
|
|
4075
|
-
|
|
4076
|
-
|
|
4077
|
-
|
|
4078
|
-
|
|
3792
|
+
type ActiveTabType = 'screenshare' | 'plugin';
|
|
3793
|
+
interface ActiveTab {
|
|
3794
|
+
type: ActiveTabType;
|
|
3795
|
+
id: string;
|
|
4079
3796
|
}
|
|
4080
|
-
declare
|
|
4081
|
-
|
|
4082
|
-
|
|
4083
|
-
getICEServers(): Promise<any>;
|
|
4084
|
-
getPlugins(): Promise<any[]>;
|
|
4085
|
-
getPluginDetails(pluginId: string): Promise<RTKPluginResponse>;
|
|
4086
|
-
getPluginConfig(pluginBaseUrl: string): Promise<PluginConfig>;
|
|
4087
|
-
authorizePlugin(pluginId: string): Promise<string>;
|
|
4088
|
-
getPresignedUrls(filename: string, viewType: string): Promise<{
|
|
4089
|
-
getLocation: any;
|
|
4090
|
-
putLocation: any;
|
|
4091
|
-
}>;
|
|
4092
|
-
uploadFile(file: File | ReactNativeFile, url: string): Promise<void>;
|
|
4093
|
-
startLivestreaming({ manualIngestion, }: StartLivestreamConfig): Promise<LivestreamResponse>;
|
|
4094
|
-
stopLivestreaming(): Promise<FetchResponse<any>>;
|
|
4095
|
-
getActiveLivestream(): Promise<LivestreamResponse>;
|
|
4096
|
-
getUserDetails(): Promise<UserDetailsResponseV2>;
|
|
4097
|
-
startRecording(config: RecordingConfig, allowMultiple?: boolean): Promise<string>;
|
|
4098
|
-
updateRecording(recordingId: string, action: 'stop' | 'pause' | 'resume'): Promise<FetchResponse<any>>;
|
|
4099
|
-
getActiveRecording(): Promise<{
|
|
4100
|
-
status: string;
|
|
4101
|
-
id: string;
|
|
4102
|
-
}>;
|
|
4103
|
-
getActiveTranscript(): Promise<{
|
|
4104
|
-
transcript: string;
|
|
4105
|
-
}>;
|
|
4106
|
-
getRoomNodeData(): Promise<RoomDetails>;
|
|
3797
|
+
declare enum TabChangeSource {
|
|
3798
|
+
User = 0,
|
|
3799
|
+
Meeting = 1
|
|
4107
3800
|
}
|
|
4108
|
-
|
|
4109
|
-
|
|
4110
|
-
|
|
4111
|
-
|
|
4112
|
-
custom = "custom",
|
|
4113
|
-
poll = "poll"
|
|
3801
|
+
interface MediaConnectionUpdate {
|
|
3802
|
+
transport: 'consuming' | 'producing';
|
|
3803
|
+
state: string;
|
|
3804
|
+
reconnected: boolean;
|
|
4114
3805
|
}
|
|
4115
|
-
|
|
4116
|
-
|
|
4117
|
-
|
|
4118
|
-
|
|
4119
|
-
|
|
4120
|
-
|
|
4121
|
-
|
|
4122
|
-
|
|
4123
|
-
|
|
4124
|
-
|
|
4125
|
-
|
|
4126
|
-
|
|
4127
|
-
|
|
4128
|
-
|
|
3806
|
+
type MetaEvents = {
|
|
3807
|
+
['mediaConnectionUpdate']: (payload: MediaConnectionUpdate) => void;
|
|
3808
|
+
['socketConnectionUpdate']: (state: SocketConnectionState) => void;
|
|
3809
|
+
['poorConnection']: (payload: {
|
|
3810
|
+
score: number;
|
|
3811
|
+
}) => void;
|
|
3812
|
+
['meetingStartTimeUpdate']: (payload: {
|
|
3813
|
+
meetingStartedTimestamp: Date;
|
|
3814
|
+
}) => void;
|
|
3815
|
+
['transcript']: (t: TranscriptionData) => void;
|
|
3816
|
+
['activeTabUpdate']: (tab: ActiveTab) => void;
|
|
3817
|
+
['selfTabUpdate']: (tab: ActiveTab) => void;
|
|
3818
|
+
['broadcastTabChangesUpdate']: (broadcastTabChanges: boolean) => void;
|
|
3819
|
+
['*']: (event: string, ...args: any[]) => void;
|
|
3820
|
+
};
|
|
3821
|
+
declare class RTKMeta$1 extends RTKTypedEventEmitter<MetaEvents> {
|
|
3822
|
+
selfActiveTab: ActiveTab | undefined;
|
|
3823
|
+
readonly socketState: SocketConnectionState;
|
|
3824
|
+
readonly mediaState: MediaConnectionState;
|
|
3825
|
+
broadcastTabChanges: boolean;
|
|
3826
|
+
viewType: string;
|
|
3827
|
+
meetingStartedTimestamp: Date;
|
|
3828
|
+
meetingTitle: string;
|
|
3829
|
+
sessionId: string;
|
|
3830
|
+
constructor(context: Context<RTKContextState>, self: RTKSelf, viewType: string, roomSocketHandler: RoomSocketHandler, meetingTitle: string);
|
|
3831
|
+
readonly meetingId: string;
|
|
3832
|
+
setBroadcastTabChanges(broadcastTabChanges: boolean): void;
|
|
3833
|
+
setSelfActiveTab(spotlightTab: ActiveTab, tabChangeSource: TabChangeSource): void;
|
|
4129
3834
|
}
|
|
4130
|
-
interface
|
|
4131
|
-
|
|
3835
|
+
interface RTKMapEvents<T extends EventMap$1> {
|
|
3836
|
+
onAddEvent?: keyof T;
|
|
3837
|
+
onDeleteEvent?: keyof T;
|
|
3838
|
+
onClearEvent?: keyof T;
|
|
4132
3839
|
}
|
|
4133
|
-
|
|
4134
|
-
|
|
4135
|
-
|
|
4136
|
-
|
|
4137
|
-
|
|
4138
|
-
|
|
4139
|
-
|
|
4140
|
-
|
|
4141
|
-
|
|
4142
|
-
|
|
4143
|
-
|
|
4144
|
-
|
|
4145
|
-
|
|
4146
|
-
|
|
4147
|
-
|
|
4148
|
-
|
|
4149
|
-
|
|
4150
|
-
|
|
4151
|
-
|
|
4152
|
-
|
|
4153
|
-
|
|
4154
|
-
|
|
4155
|
-
|
|
4156
|
-
|
|
4157
|
-
|
|
4158
|
-
|
|
4159
|
-
|
|
4160
|
-
|
|
4161
|
-
|
|
4162
|
-
|
|
4163
|
-
|
|
4164
|
-
|
|
4165
|
-
|
|
4166
|
-
|
|
4167
|
-
|
|
3840
|
+
type ModifyPrependObject<T extends EventMap$1, U> = {
|
|
3841
|
+
[K in keyof T]: (obj: U, ...args: Parameters<T[K]>) => ReturnType<T[K]>;
|
|
3842
|
+
} & {
|
|
3843
|
+
['*']: (event: String, ...args: any[]) => void;
|
|
3844
|
+
};
|
|
3845
|
+
declare class RTKMap<T extends (EventMap$1 & WildCardEvent<T>), U extends {
|
|
3846
|
+
id: string;
|
|
3847
|
+
} & RTKTypedEventEmitter<T>, V extends EventMap$1> extends Map<string, U> {
|
|
3848
|
+
readonly onAddEvent: keyof V;
|
|
3849
|
+
readonly onDeleteEvent: keyof V;
|
|
3850
|
+
readonly onClearEvent: keyof V;
|
|
3851
|
+
constructor(options: RTKMapEvents<V>, logger?: RTKLogger$1);
|
|
3852
|
+
emit<E extends StringKeyOf<ModifyPrependObject<T, U> & V>>(event: E, ...args: Parameters<(V | ModifyPrependObject<T, U>)[E]>): boolean;
|
|
3853
|
+
on<E extends StringKeyOf<ModifyPrependObject<T, U> & V>>(event: E, callback: (ModifyPrependObject<T, U> & V)[E]): RTKTypedEventEmitter<{
|
|
3854
|
+
[K in keyof T]: (obj: U, ...args: Parameters<T[K]>) => ReturnType<T[K]>;
|
|
3855
|
+
} & {
|
|
3856
|
+
"*": (event: String, ...args: any[]) => void;
|
|
3857
|
+
} & V>;
|
|
3858
|
+
addListener<E extends StringKeyOf<ModifyPrependObject<T, U> & V>>(event: E, callback: (ModifyPrependObject<T, U> & V)[E]): RTKTypedEventEmitter<{
|
|
3859
|
+
[K in keyof T]: (obj: U, ...args: Parameters<T[K]>) => ReturnType<T[K]>;
|
|
3860
|
+
} & {
|
|
3861
|
+
"*": (event: String, ...args: any[]) => void;
|
|
3862
|
+
} & V>;
|
|
3863
|
+
off<E extends StringKeyOf<ModifyPrependObject<T, U> & V>>(event: E, callback: (ModifyPrependObject<T, U> & V)[E]): RTKTypedEventEmitter<{
|
|
3864
|
+
[K in keyof T]: (obj: U, ...args: Parameters<T[K]>) => ReturnType<T[K]>;
|
|
3865
|
+
} & {
|
|
3866
|
+
"*": (event: String, ...args: any[]) => void;
|
|
3867
|
+
} & V>;
|
|
3868
|
+
once<E extends StringKeyOf<ModifyPrependObject<T, U> & V>>(event: E, callback: (ModifyPrependObject<T, U> & V)[E]): RTKTypedEventEmitter<{
|
|
3869
|
+
[K in keyof T]: (obj: U, ...args: Parameters<T[K]>) => ReturnType<T[K]>;
|
|
3870
|
+
} & {
|
|
3871
|
+
"*": (event: String, ...args: any[]) => void;
|
|
3872
|
+
} & V>;
|
|
3873
|
+
prependListener<E extends StringKeyOf<ModifyPrependObject<T, U> & V>>(event: E, callback: (ModifyPrependObject<T, U> & V)[E]): RTKTypedEventEmitter<{
|
|
3874
|
+
[K in keyof T]: (obj: U, ...args: Parameters<T[K]>) => ReturnType<T[K]>;
|
|
3875
|
+
} & {
|
|
3876
|
+
"*": (event: String, ...args: any[]) => void;
|
|
3877
|
+
} & V>;
|
|
3878
|
+
prependOnceListener<E extends StringKeyOf<ModifyPrependObject<T, U> & V>>(event: E, callback: (ModifyPrependObject<T, U> & V)[E]): RTKTypedEventEmitter<{
|
|
3879
|
+
[K in keyof T]: (obj: U, ...args: Parameters<T[K]>) => ReturnType<T[K]>;
|
|
3880
|
+
} & {
|
|
3881
|
+
"*": (event: String, ...args: any[]) => void;
|
|
3882
|
+
} & V>;
|
|
3883
|
+
removeListener<E extends StringKeyOf<ModifyPrependObject<T, U> & V>>(event: E, callback: (ModifyPrependObject<T, U> & V)[E]): RTKTypedEventEmitter<{
|
|
3884
|
+
[K in keyof T]: (obj: U, ...args: Parameters<T[K]>) => ReturnType<T[K]>;
|
|
3885
|
+
} & {
|
|
3886
|
+
"*": (event: String, ...args: any[]) => void;
|
|
3887
|
+
} & V>;
|
|
3888
|
+
removeAllListeners<E extends StringKeyOf<ModifyPrependObject<T, U> & V>>(event?: E): RTKTypedEventEmitter<{
|
|
3889
|
+
[K in keyof T]: (obj: U, ...args: Parameters<T[K]>) => ReturnType<T[K]>;
|
|
3890
|
+
} & {
|
|
3891
|
+
"*": (event: String, ...args: any[]) => void;
|
|
3892
|
+
} & V>;
|
|
3893
|
+
listeners<E extends StringKeyOf<ModifyPrependObject<T, U> & V>>(event: E): Function[];
|
|
3894
|
+
listenerCount<E extends StringKeyOf<ModifyPrependObject<T, U> & V>>(event: E): number;
|
|
3895
|
+
getMaxListeners(): number;
|
|
3896
|
+
setMaxListeners(n: number): RTKTypedEventEmitter<{
|
|
3897
|
+
[K in keyof T]: (obj: U, ...args: Parameters<T[K]>) => ReturnType<T[K]>;
|
|
3898
|
+
} & {
|
|
3899
|
+
"*": (event: String, ...args: any[]) => void;
|
|
3900
|
+
} & V>;
|
|
3901
|
+
eventNames(): (string | symbol)[];
|
|
3902
|
+
add(obj: U, emitEvent?: boolean): this;
|
|
3903
|
+
set(objId: string, obj: U, emitEvent?: boolean): this;
|
|
3904
|
+
delete(objId: string, emitEvent?: boolean, removeListeners?: boolean): boolean;
|
|
3905
|
+
clear(emitEvent?: boolean, removeListeners?: boolean): void;
|
|
3906
|
+
toArray(): U[];
|
|
4168
3907
|
}
|
|
4169
|
-
|
|
4170
|
-
|
|
4171
|
-
|
|
4172
|
-
|
|
4173
|
-
|
|
4174
|
-
|
|
4175
|
-
|
|
4176
|
-
|
|
3908
|
+
type ParticipantMapEvents = {
|
|
3909
|
+
['participantJoined']: (payload: RTKParticipant$1) => void;
|
|
3910
|
+
['participantLeft']: (payload: RTKParticipant$1) => void;
|
|
3911
|
+
['participantsCleared']: () => void;
|
|
3912
|
+
['participantsUpdate']: () => void;
|
|
3913
|
+
['kicked']: (payload: {
|
|
3914
|
+
id: string;
|
|
3915
|
+
}) => void;
|
|
3916
|
+
};
|
|
3917
|
+
declare class RTKParticipantMap$1<T extends Pick<RTKParticipant$1, 'id' | keyof RTKTypedEventEmitter<ParticipantEvents>> = RTKParticipant$1> extends RTKMap<ParticipantEvents, T, ParticipantMapEvents> {
|
|
3918
|
+
constructor(logger: RTKLogger, options?: RTKMapEvents<ParticipantMapEvents>);
|
|
3919
|
+
add(participant: T, emitEvent?: boolean): this;
|
|
3920
|
+
clear(emitEvent?: boolean, removeListeners?: boolean): void;
|
|
3921
|
+
delete(participantId: string, emitEvent?: boolean, removeListeners?: boolean): boolean;
|
|
4177
3922
|
}
|
|
4178
|
-
|
|
4179
|
-
|
|
4180
|
-
|
|
3923
|
+
declare const modes: readonly [
|
|
3924
|
+
"ACTIVE_GRID",
|
|
3925
|
+
"PAGINATED",
|
|
3926
|
+
"MANUAL"
|
|
3927
|
+
];
|
|
3928
|
+
type ViewMode = (typeof modes)[number];
|
|
3929
|
+
interface BroadcastMessagePayload {
|
|
3930
|
+
[key: string]: boolean | number | string | Date | ActiveTab;
|
|
4181
3931
|
}
|
|
4182
|
-
interface
|
|
4183
|
-
|
|
4184
|
-
|
|
3932
|
+
interface PeerProducerConfig {
|
|
3933
|
+
audio: boolean;
|
|
3934
|
+
video: boolean;
|
|
3935
|
+
screenshareAudio: boolean;
|
|
3936
|
+
screenshareVideo: boolean;
|
|
4185
3937
|
}
|
|
4186
|
-
type
|
|
4187
|
-
|
|
4188
|
-
|
|
4189
|
-
|
|
4190
|
-
|
|
4191
|
-
|
|
3938
|
+
type BroadcastMessageTarget = {
|
|
3939
|
+
participantIds: string[];
|
|
3940
|
+
} | {
|
|
3941
|
+
presetNames: string[];
|
|
3942
|
+
} | {
|
|
3943
|
+
meetingIds: string[];
|
|
3944
|
+
};
|
|
3945
|
+
type JoinedPeer = {
|
|
3946
|
+
id: string;
|
|
3947
|
+
userId: string;
|
|
3948
|
+
name: string;
|
|
3949
|
+
stageType?: StageStatus;
|
|
3950
|
+
customParticipantId?: string;
|
|
3951
|
+
presetId?: string;
|
|
3952
|
+
picture?: string;
|
|
3953
|
+
waitlisted: boolean;
|
|
3954
|
+
recorderType?: string;
|
|
3955
|
+
stageStatus?: StageStatus;
|
|
3956
|
+
metadata?: {
|
|
3957
|
+
preset_name?: string;
|
|
4192
3958
|
};
|
|
4193
|
-
|
|
4194
|
-
|
|
4195
|
-
|
|
4196
|
-
|
|
4197
|
-
|
|
4198
|
-
|
|
4199
|
-
['
|
|
4200
|
-
|
|
4201
|
-
|
|
3959
|
+
flags?: {
|
|
3960
|
+
hiddenParticipant?: boolean;
|
|
3961
|
+
recorder?: boolean;
|
|
3962
|
+
};
|
|
3963
|
+
};
|
|
3964
|
+
type ParticipantsEvents = {
|
|
3965
|
+
['viewModeChanged']: (payload: {
|
|
3966
|
+
viewMode: string;
|
|
3967
|
+
currentPage: number;
|
|
3968
|
+
pageCount: number;
|
|
3969
|
+
}) => void;
|
|
3970
|
+
['activeSpeaker']: (payload: {
|
|
3971
|
+
peerId: string;
|
|
3972
|
+
volume: number;
|
|
3973
|
+
}) => void;
|
|
3974
|
+
['broadcastedMessage']: (payload: {
|
|
3975
|
+
type: string;
|
|
3976
|
+
payload: BroadcastMessagePayload;
|
|
3977
|
+
timestamp: number;
|
|
3978
|
+
}) => void;
|
|
3979
|
+
['poorConnection']: (payload: {
|
|
3980
|
+
participantId: string;
|
|
3981
|
+
score: number;
|
|
3982
|
+
kind: string;
|
|
3983
|
+
}) => void;
|
|
3984
|
+
['pageChanged']: (payload: {
|
|
3985
|
+
viewMode: string;
|
|
3986
|
+
currentPage: number;
|
|
3987
|
+
pageCount: number;
|
|
3988
|
+
}) => void;
|
|
3989
|
+
['mediaScoreUpdate']: (payload: {
|
|
3990
|
+
kind: string;
|
|
3991
|
+
isScreenshare: boolean;
|
|
3992
|
+
score: number;
|
|
3993
|
+
participantId: string;
|
|
3994
|
+
scoreStats: ConsumerScoreStats;
|
|
3995
|
+
}) => void;
|
|
3996
|
+
['media_decode_error']: (payload: {
|
|
3997
|
+
reason: string;
|
|
3998
|
+
code: '1702' | '1703';
|
|
3999
|
+
}) => void;
|
|
4202
4000
|
['*']: (event: string, ...args: any[]) => void;
|
|
4203
4001
|
};
|
|
4204
|
-
declare class
|
|
4205
|
-
|
|
4206
|
-
|
|
4207
|
-
|
|
4208
|
-
|
|
4209
|
-
|
|
4002
|
+
declare class RTKParticipants$1 extends RTKTypedEventEmitter<ParticipantsEvents> {
|
|
4003
|
+
readonly waitlisted: Readonly<RTKParticipantMap$1<Pick<RTKParticipant$1, Exclude<keyof RTKParticipant$1, 'audioTrack' | 'videoTrack' | 'screenShareTracks'>>>>;
|
|
4004
|
+
readonly joined: Readonly<RTKParticipantMap$1>;
|
|
4005
|
+
readonly active: Readonly<RTKParticipantMap$1>;
|
|
4006
|
+
readonly videoSubscribed: Readonly<RTKParticipantMap$1>;
|
|
4007
|
+
readonly audioSubscribed: Readonly<RTKParticipantMap$1>;
|
|
4008
|
+
readonly pinned: Readonly<RTKParticipantMap$1>;
|
|
4009
|
+
readonly all: Readonly<RTKBasicParticipantsMap>;
|
|
4010
|
+
readonly pip: RTKPip;
|
|
4011
|
+
rateLimitConfig: {
|
|
4012
|
+
maxInvocations: number;
|
|
4013
|
+
period: number;
|
|
4014
|
+
};
|
|
4210
4015
|
readonly rateLimits: {
|
|
4211
4016
|
maxInvocations: number;
|
|
4212
4017
|
period: number;
|
|
4213
4018
|
};
|
|
4214
4019
|
updateRateLimits(num: number, period: number): void;
|
|
4215
|
-
|
|
4216
|
-
|
|
4217
|
-
|
|
4218
|
-
|
|
4219
|
-
|
|
4220
|
-
|
|
4221
|
-
|
|
4222
|
-
|
|
4223
|
-
|
|
4224
|
-
|
|
4225
|
-
|
|
4226
|
-
|
|
4227
|
-
|
|
4228
|
-
|
|
4229
|
-
|
|
4230
|
-
|
|
4231
|
-
|
|
4232
|
-
|
|
4233
|
-
|
|
4234
|
-
|
|
4235
|
-
|
|
4236
|
-
|
|
4237
|
-
|
|
4238
|
-
|
|
4239
|
-
|
|
4240
|
-
|
|
4241
|
-
|
|
4242
|
-
|
|
4243
|
-
|
|
4244
|
-
|
|
4245
|
-
|
|
4246
|
-
|
|
4247
|
-
|
|
4248
|
-
|
|
4249
|
-
|
|
4250
|
-
|
|
4251
|
-
|
|
4252
|
-
|
|
4253
|
-
|
|
4254
|
-
|
|
4255
|
-
|
|
4256
|
-
|
|
4020
|
+
readonly telemetry: RTKTelemetry;
|
|
4021
|
+
viewMode: ViewMode;
|
|
4022
|
+
currentPage: number;
|
|
4023
|
+
lastActiveSpeaker: string;
|
|
4024
|
+
selectedPeers: RTKSelectedPeers;
|
|
4025
|
+
constructor(context: Context<RTKContextState>, self: RTKSelf$1, roomSocketHandler: RoomSocketHandler);
|
|
4026
|
+
setupEvents(): void;
|
|
4027
|
+
readonly count: number;
|
|
4028
|
+
readonly maxActiveParticipantsCount: number;
|
|
4029
|
+
setMaxActiveParticipantsCount(limit: number): void;
|
|
4030
|
+
readonly pageCount: number;
|
|
4031
|
+
acceptWaitingRoomRequest(id: string): void;
|
|
4032
|
+
acceptAllWaitingRoomRequest(userIds: string[]): Promise<void>;
|
|
4033
|
+
rejectWaitingRoomRequest(id: string): Promise<void>;
|
|
4034
|
+
setViewMode(viewMode: ViewMode): Promise<void>;
|
|
4035
|
+
subscribe(peerIds: string[], kinds?: ('audio' | 'video' | 'screenshareAudio' | 'screenshareVideo')[]): Promise<void>;
|
|
4036
|
+
unsubscribe(peerIds: string[], kinds?: ('audio' | 'video' | 'screenshareAudio' | 'screenshareVideo')[]): Promise<void>;
|
|
4037
|
+
getPeerIdsForCurrentPage(): string[];
|
|
4038
|
+
setPage(page: number): Promise<void>;
|
|
4039
|
+
disableAllAudio(allowUnmute: boolean): Promise<void>;
|
|
4040
|
+
disableAllVideo(): Promise<void>;
|
|
4041
|
+
disableAudio(participantId: string): Promise<void>;
|
|
4042
|
+
disableVideo(participantId: string): Promise<void>;
|
|
4043
|
+
kick(participantId: string): Promise<void>;
|
|
4044
|
+
kickAll(): Promise<void>;
|
|
4045
|
+
broadcastMessage(type: Exclude<string, 'spotlight'>, payload: BroadcastMessagePayload, target?: BroadcastMessageTarget): Promise<void>;
|
|
4046
|
+
getAllJoinedPeers(searchQuery: string, limit: number, offset: number): Promise<{
|
|
4047
|
+
id: string;
|
|
4048
|
+
userId: string;
|
|
4049
|
+
name: string;
|
|
4050
|
+
displayName: string;
|
|
4051
|
+
stageType: StageStatus;
|
|
4052
|
+
customParticipantId: string;
|
|
4053
|
+
presetId: string;
|
|
4054
|
+
picture: string;
|
|
4055
|
+
waitlisted: boolean;
|
|
4056
|
+
stageStatus: StageStatus;
|
|
4057
|
+
metadata: {
|
|
4058
|
+
preset_name: string;
|
|
4059
|
+
};
|
|
4060
|
+
recorderType: string;
|
|
4061
|
+
flags: {
|
|
4062
|
+
hiddenParticipant: boolean;
|
|
4063
|
+
hidden_participant: boolean;
|
|
4064
|
+
recorder: boolean;
|
|
4065
|
+
};
|
|
4066
|
+
}[]>;
|
|
4067
|
+
updatePermissions(participantIds: string[], permissions: PresetUpdates): Promise<void>;
|
|
4068
|
+
getParticipantsInMeetingPreJoin(): Promise<RoomPeersInfoResponse>;
|
|
4257
4069
|
}
|
|
4258
|
-
interface
|
|
4259
|
-
|
|
4260
|
-
|
|
4261
|
-
|
|
4262
|
-
|
|
4263
|
-
|
|
4264
|
-
|
|
4070
|
+
interface FetchRequestConfig {
|
|
4071
|
+
baseURL?: string;
|
|
4072
|
+
url?: string;
|
|
4073
|
+
method?: string;
|
|
4074
|
+
headers?: Record<string, string>;
|
|
4075
|
+
timeout?: number;
|
|
4076
|
+
retry?: number;
|
|
4077
|
+
retryDelay?: number;
|
|
4078
|
+
responseType?: string;
|
|
4079
|
+
data?: any;
|
|
4080
|
+
params?: Record<string, string>;
|
|
4265
4081
|
}
|
|
4266
|
-
interface
|
|
4267
|
-
|
|
4268
|
-
|
|
4269
|
-
|
|
4270
|
-
|
|
4271
|
-
|
|
4272
|
-
createdBy: string;
|
|
4273
|
-
createdByUserId: string;
|
|
4274
|
-
voted: string[];
|
|
4082
|
+
interface FetchResponse<T = any> {
|
|
4083
|
+
data: T;
|
|
4084
|
+
status: number;
|
|
4085
|
+
statusText: string;
|
|
4086
|
+
headers: Record<string, string>;
|
|
4087
|
+
config: FetchRequestConfig;
|
|
4275
4088
|
}
|
|
4276
|
-
|
|
4277
|
-
|
|
4278
|
-
|
|
4279
|
-
|
|
4280
|
-
|
|
4281
|
-
|
|
4282
|
-
|
|
4283
|
-
|
|
4284
|
-
|
|
4285
|
-
|
|
4286
|
-
|
|
4287
|
-
|
|
4089
|
+
declare class FetchClient {
|
|
4090
|
+
defaults: {
|
|
4091
|
+
baseURL: string;
|
|
4092
|
+
headers: {
|
|
4093
|
+
common: Record<string, string>;
|
|
4094
|
+
};
|
|
4095
|
+
timeout: number;
|
|
4096
|
+
retry: number;
|
|
4097
|
+
retryDelay: number;
|
|
4098
|
+
};
|
|
4099
|
+
constructor(options: {
|
|
4100
|
+
baseURL: string;
|
|
4101
|
+
timeout: number;
|
|
4102
|
+
retry: number;
|
|
4103
|
+
retryDelay: number;
|
|
4104
|
+
responseType?: string;
|
|
4105
|
+
});
|
|
4106
|
+
request<T = any>(config: FetchRequestConfig): Promise<FetchResponse<T>>;
|
|
4107
|
+
get<T = any>(url: string, config?: FetchRequestConfig): Promise<FetchResponse<T>>;
|
|
4108
|
+
post<T = any>(url: string, data?: any, config?: FetchRequestConfig): Promise<FetchResponse<T>>;
|
|
4109
|
+
put<T = any>(url: string, data?: any, config?: FetchRequestConfig): Promise<FetchResponse<T>>;
|
|
4288
4110
|
}
|
|
4289
|
-
type
|
|
4290
|
-
|
|
4291
|
-
['
|
|
4292
|
-
|
|
4293
|
-
type PluginEvents$1 = {
|
|
4294
|
-
['stateUpdate']: (payload: {
|
|
4295
|
-
active: boolean;
|
|
4296
|
-
pluginId: string;
|
|
4297
|
-
bind?: (...args: any[]) => void;
|
|
4298
|
-
views: any;
|
|
4299
|
-
}) => void;
|
|
4300
|
-
['ready']: () => void;
|
|
4301
|
-
['closed']: () => void;
|
|
4302
|
-
['toggleViewMode']: (...args: any[]) => void;
|
|
4303
|
-
['enabled']: () => void;
|
|
4111
|
+
type LivestreamState = 'IDLE' | 'STARTING' | 'WAITING_ON_MANUAL_INGESTION' | 'LIVESTREAMING' | 'STOPPING';
|
|
4112
|
+
type LivestreamEvents = {
|
|
4113
|
+
['livestreamUpdate']: (state: LivestreamState) => void;
|
|
4114
|
+
['viewerCountUpdate']: (count: number) => void;
|
|
4304
4115
|
['*']: (eventName: string, ...args: any[]) => void;
|
|
4305
4116
|
};
|
|
4306
|
-
|
|
4307
|
-
|
|
4308
|
-
add(plugin: T, emitEvent?: boolean): this;
|
|
4309
|
-
delete(pluginId: string, emitEvent?: boolean, removeListeners?: boolean): boolean;
|
|
4310
|
-
}
|
|
4311
|
-
declare class RTKPlugins$1 {
|
|
4312
|
-
readonly all: RTKPluginMap$1;
|
|
4313
|
-
readonly active: RTKPluginMap$1;
|
|
4314
|
-
constructor();
|
|
4315
|
-
}
|
|
4316
|
-
type PluginSocketMessage = DisablePluginResponse | EnablePluginResponse | PluginEventResponse | PluginStoreResponse | SendChatMessageToPeersResponse | SendChatMessageToRoomResponse;
|
|
4317
|
-
declare class PluginSocketHandler {
|
|
4318
|
-
constructor(socketService: SocketService);
|
|
4319
|
-
addPlugin(pluginId: string, staggered: boolean): void;
|
|
4320
|
-
removePlugin(pluginId: string): void;
|
|
4321
|
-
getActivePlugins(): Promise<EnablePluginsResponse>;
|
|
4322
|
-
customPluginEventToRoom(pluginId: string, data: any, messageId?: string): void;
|
|
4323
|
-
customPluginEventToPeers(pluginId: string, peerIds: string[], data: any, messageId?: string): void;
|
|
4324
|
-
enablePluginForRoom(pluginId: string, messageId?: string): void;
|
|
4325
|
-
enablePluginForPeers(pluginId: string, peerIds: string[], messageId?: string): void;
|
|
4326
|
-
disablePluginForRoom(pluginId: string, messageId?: string): void;
|
|
4327
|
-
disablePluginForPeers(pluginId: string, peerIds: string[], messageId?: string): void;
|
|
4328
|
-
storeInsertKeys(pluginId: string, store: string, insertKeys: {
|
|
4329
|
-
key: string;
|
|
4330
|
-
payload?: any;
|
|
4331
|
-
}[], messageId?: string): void;
|
|
4332
|
-
storeGetKeys(pluginId: string, store: string, getKeys: {
|
|
4333
|
-
key: string;
|
|
4334
|
-
}[], messageId?: string): void;
|
|
4335
|
-
storeDeleteKeys(pluginId: string, store: string, deleteKeys: {
|
|
4336
|
-
key: string;
|
|
4337
|
-
}[], messageId?: string): void;
|
|
4338
|
-
storeDelete(pluginId: string, store: string, messageId?: string): void;
|
|
4339
|
-
getPluginDataOld(pluginId: string, store: string): void;
|
|
4340
|
-
storePluginDataOld(pluginId: string, store: string, data: any): void;
|
|
4341
|
-
on(event: number, handler: (socketMessage: PluginSocketMessage, messageId?: string) => void): void;
|
|
4342
|
-
}
|
|
4343
|
-
declare class RTKSelfMedia extends RTKTypedEventEmitter<SelfEvents> {
|
|
4344
|
-
init(options?: {
|
|
4345
|
-
video?: boolean;
|
|
4346
|
-
audio?: boolean;
|
|
4347
|
-
constraints?: MediaConstraints;
|
|
4348
|
-
}, skipAwaits?: boolean, context?: Context<RTKContextState>): Promise<void>;
|
|
4349
|
-
readonly audioTrack: MediaStreamTrack;
|
|
4350
|
-
readonly rawAudioTrack: MediaStreamTrack;
|
|
4351
|
-
readonly mediaPermissions: {
|
|
4352
|
-
audio?: MediaPermission$1;
|
|
4353
|
-
video?: MediaPermission$1;
|
|
4354
|
-
screenshare?: MediaPermission$1;
|
|
4355
|
-
};
|
|
4356
|
-
addAudioMiddleware(audioMiddleware: AudioMiddleware): Promise<{
|
|
4357
|
-
success: boolean;
|
|
4358
|
-
message: string;
|
|
4359
|
-
}>;
|
|
4360
|
-
removeAudioMiddleware(audioMiddleware: AudioMiddleware): Promise<{
|
|
4361
|
-
success: boolean;
|
|
4362
|
-
message: string;
|
|
4363
|
-
}>;
|
|
4364
|
-
removeAllAudioMiddlewares(): Promise<{
|
|
4365
|
-
success: boolean;
|
|
4366
|
-
message: string;
|
|
4367
|
-
}>;
|
|
4368
|
-
readonly videoTrack: MediaStreamTrack;
|
|
4369
|
-
readonly rawVideoTrack: MediaStreamTrack;
|
|
4370
|
-
addVideoMiddleware(videoMiddleware: VideoMiddleware): Promise<{
|
|
4371
|
-
success: boolean;
|
|
4372
|
-
message: string;
|
|
4373
|
-
}>;
|
|
4374
|
-
setVideoMiddlewareGlobalConfig(config?: VideoMiddlewareGlobalConfig): Promise<void>;
|
|
4375
|
-
removeVideoMiddleware(videoMiddleware: VideoMiddleware): Promise<{
|
|
4376
|
-
success: boolean;
|
|
4377
|
-
message: string;
|
|
4378
|
-
}>;
|
|
4379
|
-
removeAllVideoMiddlewares(): Promise<{
|
|
4380
|
-
success: boolean;
|
|
4381
|
-
message: string;
|
|
4382
|
-
}>;
|
|
4383
|
-
readonly screenShareTracks: {
|
|
4384
|
-
audio: MediaStreamTrack;
|
|
4385
|
-
video: MediaStreamTrack;
|
|
4386
|
-
};
|
|
4387
|
-
readonly audioEnabled: boolean;
|
|
4388
|
-
readonly videoEnabled: boolean;
|
|
4389
|
-
readonly screenShareEnabled: boolean;
|
|
4390
|
-
enableAudio(): Promise<void>;
|
|
4391
|
-
enableVideo(): Promise<void>;
|
|
4392
|
-
disableAudio(): Promise<void>;
|
|
4393
|
-
enableScreenShare(): Promise<void>;
|
|
4394
|
-
disableScreenShare(): Promise<void>;
|
|
4395
|
-
disableVideo(): Promise<void>;
|
|
4396
|
-
getCurrentDevices(): {
|
|
4397
|
-
audio: MediaDeviceInfo;
|
|
4398
|
-
video: MediaDeviceInfo;
|
|
4399
|
-
speaker: MediaDeviceInfo;
|
|
4400
|
-
};
|
|
4401
|
-
getAudioDevices(): Promise<MediaDeviceInfo[]>;
|
|
4402
|
-
getVideoDevices(): Promise<MediaDeviceInfo[]>;
|
|
4403
|
-
getSpeakerDevices(): Promise<MediaDeviceInfo[]>;
|
|
4404
|
-
getDeviceById(deviceId: string, kind: 'audio' | 'video' | 'speaker'): Promise<MediaDeviceInfo>;
|
|
4405
|
-
setDevice(device: MediaDeviceInfo): Promise<void>;
|
|
4406
|
-
}
|
|
4407
|
-
type RecordingState = 'IDLE' | 'STARTING' | 'RECORDING' | 'PAUSED' | 'STOPPING';
|
|
4408
|
-
type RecordingType = 'BROWSER' | 'TRACK' | 'COMPOSITE';
|
|
4409
|
-
type RecordingInfo = {
|
|
4410
|
-
state: RecordingState;
|
|
4411
|
-
id: string;
|
|
4412
|
-
type: RecordingType;
|
|
4117
|
+
type StartLivestreamConfig = {
|
|
4118
|
+
manualIngestion: boolean;
|
|
4413
4119
|
};
|
|
4414
|
-
|
|
4415
|
-
|
|
4416
|
-
|
|
4120
|
+
interface LivestreamIngestionCredentials {
|
|
4121
|
+
ingestionServer: string;
|
|
4122
|
+
streamKey: string;
|
|
4123
|
+
}
|
|
4124
|
+
type LivestreamResponse = {
|
|
4125
|
+
status: string;
|
|
4126
|
+
playbackUrl: string;
|
|
4127
|
+
manualIngest: boolean;
|
|
4128
|
+
ingestionCredentials?: LivestreamIngestionCredentials;
|
|
4417
4129
|
};
|
|
4418
|
-
declare class
|
|
4419
|
-
|
|
4420
|
-
|
|
4421
|
-
|
|
4130
|
+
declare class RTKLivestream$1 extends RTKTypedEventEmitter<LivestreamEvents> {
|
|
4131
|
+
state: LivestreamState;
|
|
4132
|
+
playbackUrl: string | undefined;
|
|
4133
|
+
ingestionCredentials: LivestreamIngestionCredentials;
|
|
4134
|
+
viewerCount: number;
|
|
4135
|
+
readonly telemetry: RTKTelemetry;
|
|
4422
4136
|
constructor(context: Context<RTKContextState>, self: RTKSelf);
|
|
4423
|
-
|
|
4424
|
-
start(
|
|
4425
|
-
|
|
4426
|
-
}): Promise<void>;
|
|
4427
|
-
stop(recordingId?: string): Promise<void>;
|
|
4428
|
-
pause(recordingId?: string): Promise<void>;
|
|
4429
|
-
resume(recordingId?: string): Promise<void>;
|
|
4137
|
+
setLivestreamState(livestreamState: LivestreamState): void;
|
|
4138
|
+
start(livestreamConfig?: StartLivestreamConfig): Promise<void>;
|
|
4139
|
+
stop(): Promise<void>;
|
|
4430
4140
|
}
|
|
4431
|
-
|
|
4432
|
-
|
|
4433
|
-
|
|
4434
|
-
|
|
4435
|
-
|
|
4436
|
-
|
|
4437
|
-
|
|
4438
|
-
|
|
4439
|
-
|
|
4440
|
-
|
|
4441
|
-
|
|
4442
|
-
|
|
4443
|
-
|
|
4444
|
-
|
|
4445
|
-
|
|
4446
|
-
|
|
4447
|
-
|
|
4448
|
-
|
|
4449
|
-
|
|
4450
|
-
|
|
4451
|
-
|
|
4452
|
-
|
|
4453
|
-
|
|
4141
|
+
type PluginSocketMessage = DisablePluginResponse | EnablePluginResponse | PluginEventResponse | PluginStoreResponse | SendChatMessageToPeersResponse | SendChatMessageToRoomResponse;
|
|
4142
|
+
declare class PluginSocketHandler {
|
|
4143
|
+
constructor(context: Context<RTKContextState>, socketService: SocketService);
|
|
4144
|
+
readonly logger: RTKLogger$1;
|
|
4145
|
+
addPlugin(pluginId: string, staggered: boolean): void;
|
|
4146
|
+
removePlugin(pluginId: string): void;
|
|
4147
|
+
getActivePlugins(): Promise<EnablePluginsResponse>;
|
|
4148
|
+
customPluginEventToRoom(pluginId: string, data: any, messageId?: string): void;
|
|
4149
|
+
customPluginEventToPeers(pluginId: string, peerIds: string[], data: any, messageId?: string): void;
|
|
4150
|
+
enablePluginForRoom(pluginId: string, messageId?: string): void;
|
|
4151
|
+
enablePluginForPeers(pluginId: string, peerIds: string[], messageId?: string): void;
|
|
4152
|
+
disablePluginForRoom(pluginId: string, messageId?: string): void;
|
|
4153
|
+
disablePluginForPeers(pluginId: string, peerIds: string[], messageId?: string): void;
|
|
4154
|
+
storeInsertKeys(pluginId: string, store: string, insertKeys: {
|
|
4155
|
+
key: string;
|
|
4156
|
+
payload?: any;
|
|
4157
|
+
}[], messageId?: string): void;
|
|
4158
|
+
storeGetKeys(pluginId: string, store: string, getKeys: {
|
|
4159
|
+
key: string;
|
|
4160
|
+
}[], messageId?: string): void;
|
|
4161
|
+
storeDeleteKeys(pluginId: string, store: string, deleteKeys: {
|
|
4162
|
+
key: string;
|
|
4163
|
+
}[], messageId?: string): void;
|
|
4164
|
+
storeDelete(pluginId: string, store: string, messageId?: string): void;
|
|
4165
|
+
getPluginDataOld(pluginId: string, store: string): void;
|
|
4166
|
+
storePluginDataOld(pluginId: string, store: string, data: any): void;
|
|
4167
|
+
on(event: number, handler: (socketMessage: PluginSocketMessage, messageId?: string) => void): void;
|
|
4168
|
+
}
|
|
4169
|
+
interface RTKPluginResponse {
|
|
4170
|
+
baseURL: string;
|
|
4171
|
+
createdAt: string;
|
|
4172
|
+
description: string;
|
|
4173
|
+
id: string;
|
|
4174
|
+
name: string;
|
|
4175
|
+
organizationId: string;
|
|
4176
|
+
picture: string;
|
|
4177
|
+
private: boolean;
|
|
4178
|
+
published: boolean;
|
|
4179
|
+
staggered: boolean;
|
|
4180
|
+
tags: string[];
|
|
4181
|
+
type: string;
|
|
4182
|
+
updatedAt: string;
|
|
4183
|
+
}
|
|
4184
|
+
interface PluginViews {
|
|
4185
|
+
[viewId: string]: {
|
|
4186
|
+
url: string;
|
|
4187
|
+
suggestedPosition: string;
|
|
4454
4188
|
};
|
|
4455
|
-
_checkCondition(checkTree: any): any;
|
|
4456
|
-
isVersionGreaterThan(version: any): any;
|
|
4457
|
-
isVersionLessThan(version: any): any;
|
|
4458
|
-
isVersionEqualTo(version: any): any;
|
|
4459
4189
|
}
|
|
4460
|
-
|
|
4461
|
-
|
|
4462
|
-
|
|
4463
|
-
|
|
4464
|
-
|
|
4465
|
-
|
|
4466
|
-
|
|
4467
|
-
|
|
4468
|
-
|
|
4469
|
-
|
|
4470
|
-
|
|
4471
|
-
|
|
4472
|
-
|
|
4473
|
-
|
|
4474
|
-
|
|
4475
|
-
|
|
4476
|
-
|
|
4477
|
-
|
|
4478
|
-
|
|
4479
|
-
|
|
4480
|
-
|
|
4481
|
-
|
|
4482
|
-
|
|
4483
|
-
|
|
4484
|
-
|
|
4485
|
-
_getChromiumBasedVersion(): number;
|
|
4486
|
-
isIOSMobile(): boolean;
|
|
4190
|
+
interface PluginConfig {
|
|
4191
|
+
name: string;
|
|
4192
|
+
pluginId: string;
|
|
4193
|
+
version: string;
|
|
4194
|
+
description: string;
|
|
4195
|
+
author?: string;
|
|
4196
|
+
repository?: string;
|
|
4197
|
+
tags?: string[];
|
|
4198
|
+
picture?: string;
|
|
4199
|
+
url?: string;
|
|
4200
|
+
files: {
|
|
4201
|
+
include: string[];
|
|
4202
|
+
exclude?: string[];
|
|
4203
|
+
};
|
|
4204
|
+
views?: PluginViews;
|
|
4205
|
+
contentScript?: string;
|
|
4206
|
+
permissions?: {
|
|
4207
|
+
[key: string]: {
|
|
4208
|
+
default: boolean;
|
|
4209
|
+
description: string;
|
|
4210
|
+
};
|
|
4211
|
+
};
|
|
4212
|
+
config?: {
|
|
4213
|
+
[key: string]: string;
|
|
4214
|
+
};
|
|
4487
4215
|
}
|
|
4488
|
-
|
|
4489
|
-
|
|
4490
|
-
|
|
4491
|
-
|
|
4492
|
-
getAllFeatures(): {
|
|
4493
|
-
[x: string]: _dyteinternals_utils.RTKFlagsEntry;
|
|
4494
|
-
};
|
|
4216
|
+
interface PluginIframeMessage {
|
|
4217
|
+
type: number;
|
|
4218
|
+
uuid: string;
|
|
4219
|
+
payload?: any;
|
|
4495
4220
|
}
|
|
4496
|
-
|
|
4497
|
-
|
|
4498
|
-
|
|
4499
|
-
|
|
4500
|
-
|
|
4501
|
-
|
|
4221
|
+
interface SendDataOptions {
|
|
4222
|
+
eventName: string;
|
|
4223
|
+
data: any;
|
|
4224
|
+
}
|
|
4225
|
+
interface ReactNativeWebViewEvent {
|
|
4226
|
+
nativeEvent: {
|
|
4227
|
+
data: string;
|
|
4228
|
+
};
|
|
4229
|
+
}
|
|
4230
|
+
interface ReactNativeWebView {
|
|
4231
|
+
src: string;
|
|
4232
|
+
allow: string;
|
|
4233
|
+
title: string;
|
|
4234
|
+
props: {
|
|
4235
|
+
onMessage: (event: ReactNativeWebViewEvent) => void;
|
|
4236
|
+
};
|
|
4237
|
+
postMessage: (message: string) => void;
|
|
4238
|
+
}
|
|
4239
|
+
declare const PluginEventKeys: {
|
|
4240
|
+
stateUpdate: string;
|
|
4241
|
+
ready: string;
|
|
4242
|
+
closed: string;
|
|
4243
|
+
toggleViewMode: string;
|
|
4244
|
+
enabled: string;
|
|
4245
|
+
'* ': string;
|
|
4502
4246
|
};
|
|
4503
|
-
|
|
4504
|
-
|
|
4505
|
-
|
|
4506
|
-
|
|
4507
|
-
|
|
4508
|
-
|
|
4247
|
+
type _string = string & {
|
|
4248
|
+
_?: any;
|
|
4249
|
+
};
|
|
4250
|
+
type PluginEvents$1 = keyof typeof PluginEventKeys | _string;
|
|
4251
|
+
declare class RTKPlugin$1 extends RTKEventEmitter<PluginEvents$1> {
|
|
4252
|
+
readonly baseURL: string;
|
|
4253
|
+
readonly createdAt: Date;
|
|
4254
|
+
readonly description: string;
|
|
4255
|
+
readonly id: string;
|
|
4256
|
+
readonly name: string;
|
|
4257
|
+
readonly organizationId: string;
|
|
4258
|
+
readonly picture: string;
|
|
4259
|
+
readonly private: boolean;
|
|
4260
|
+
readonly published: boolean;
|
|
4261
|
+
readonly staggered: boolean;
|
|
4262
|
+
readonly tags: string[];
|
|
4263
|
+
readonly type: string;
|
|
4264
|
+
readonly updatedAt: Date;
|
|
4265
|
+
config?: PluginConfig;
|
|
4266
|
+
active: boolean;
|
|
4267
|
+
iframes: Map<string, {
|
|
4268
|
+
iframe: HTMLIFrameElement | ReactNativeWebView;
|
|
4269
|
+
listener?: (message: MessageEvent) => void;
|
|
4270
|
+
}>;
|
|
4271
|
+
enabledBy: string;
|
|
4272
|
+
readonly telemetry: RTKTelemetry;
|
|
4273
|
+
constructor(context: Context<RTKContextState>, { baseURL, createdAt, description, id, name, organizationId, picture, private: isPrivate, published, staggered, tags, type, updatedAt, }: RTKPluginResponse, pluginSocketHandler: PluginSocketHandler, self: RTKSelf$1, participants: RTKParticipants$1, chat: Readonly<RTKChat$1>, meetingTitle: string);
|
|
4274
|
+
sendIframeEvent(message: PluginIframeMessage): void;
|
|
4275
|
+
sendData(payload: SendDataOptions): void;
|
|
4276
|
+
removePluginView(viewId?: string): void;
|
|
4277
|
+
addPluginView(iframe: HTMLIFrameElement | ReactNativeWebView, viewId?: string): void;
|
|
4278
|
+
activateForSelf(): Promise<void>;
|
|
4279
|
+
deactivateForSelf(): void;
|
|
4280
|
+
enable(): Promise<void>;
|
|
4281
|
+
disable(): void;
|
|
4282
|
+
activate(): Promise<void>;
|
|
4283
|
+
deactivate(): Promise<void>;
|
|
4509
4284
|
}
|
|
4510
|
-
|
|
4511
|
-
|
|
4512
|
-
|
|
4513
|
-
|
|
4514
|
-
|
|
4515
|
-
|
|
4516
|
-
|
|
4517
|
-
|
|
4518
|
-
|
|
4519
|
-
|
|
4520
|
-
|
|
4521
|
-
|
|
4522
|
-
|
|
4523
|
-
|
|
4524
|
-
|
|
4525
|
-
|
|
4526
|
-
|
|
4527
|
-
|
|
4528
|
-
|
|
4529
|
-
|
|
4530
|
-
|
|
4531
|
-
|
|
4532
|
-
|
|
4533
|
-
|
|
4534
|
-
|
|
4535
|
-
|
|
4536
|
-
|
|
4537
|
-
|
|
4538
|
-
|
|
4539
|
-
|
|
4540
|
-
|
|
4541
|
-
|
|
4542
|
-
|
|
4543
|
-
|
|
4544
|
-
|
|
4545
|
-
enabled: boolean;
|
|
4546
|
-
count?: number;
|
|
4547
|
-
maxAllowedCount?: number;
|
|
4548
|
-
permission?: keyof typeof MediaPermission;
|
|
4549
|
-
deviceName?: string;
|
|
4550
|
-
deviceId?: string;
|
|
4551
|
-
audio?: {
|
|
4552
|
-
enabled: boolean;
|
|
4553
|
-
trackId?: string;
|
|
4554
|
-
};
|
|
4555
|
-
video?: {
|
|
4556
|
-
enabled: boolean;
|
|
4557
|
-
trackId?: string;
|
|
4558
|
-
};
|
|
4559
|
-
canProduce?: MediaProductionPermissionType;
|
|
4560
|
-
};
|
|
4561
|
-
};
|
|
4562
|
-
producerInfo?: {
|
|
4563
|
-
peerId: string;
|
|
4564
|
-
producers: ProducerState[];
|
|
4565
|
-
};
|
|
4566
|
-
preferredDevice?: {
|
|
4567
|
-
kind: 'audio' | 'video';
|
|
4568
|
-
preferredDeviceId?: string;
|
|
4569
|
-
lastUsedPreferredDeviceId?: string;
|
|
4570
|
-
};
|
|
4571
|
-
mediaPermissionsErrors?: {
|
|
4572
|
-
kind: 'audio' | 'video' | 'screenshare';
|
|
4573
|
-
message: string;
|
|
4574
|
-
deviceId?: string;
|
|
4575
|
-
};
|
|
4576
|
-
pip?: {
|
|
4577
|
-
id: string;
|
|
4578
|
-
handRaised?: boolean;
|
|
4579
|
-
source?: any;
|
|
4580
|
-
};
|
|
4581
|
-
memoize?: {
|
|
4582
|
-
doubleInvoked?: {
|
|
4583
|
-
property: string;
|
|
4584
|
-
};
|
|
4585
|
-
};
|
|
4586
|
-
dyteClientInitOptions?: RealtimeKitClientOptions;
|
|
4587
|
-
plugin?: {
|
|
4588
|
-
id?: string;
|
|
4589
|
-
name?: string;
|
|
4590
|
-
enabledBy?: string;
|
|
4591
|
-
duration?: number;
|
|
4592
|
-
storeName?: string;
|
|
4593
|
-
data?: any;
|
|
4594
|
-
};
|
|
4595
|
-
roomJoined?: boolean;
|
|
4596
|
-
transport?: {
|
|
4597
|
-
id?: string;
|
|
4598
|
-
type?: 'send' | 'recv';
|
|
4599
|
-
status?: RTCPeerConnectionState | 'reconnecting';
|
|
4600
|
-
lastDisconnectedTime?: string;
|
|
4601
|
-
lastDisconnectedTimeOffset?: number;
|
|
4602
|
-
durationPassed?: number;
|
|
4603
|
-
remoteOfferAnswer?: RTCSessionDescriptionInit;
|
|
4604
|
-
serverId?: string;
|
|
4605
|
-
};
|
|
4606
|
-
iceCandidate?: RTCIceCandidate;
|
|
4607
|
-
iceRestart?: {
|
|
4608
|
-
status?: RTCPeerConnectionState | 'reconnecting';
|
|
4609
|
-
isSendTransport?: boolean;
|
|
4610
|
-
isRecvTransport?: boolean;
|
|
4611
|
-
currentAttempt?: number;
|
|
4612
|
-
};
|
|
4613
|
-
producer?: {
|
|
4614
|
-
id: string;
|
|
4615
|
-
peerId?: string;
|
|
4616
|
-
kind: 'audio' | 'video' | PRODUCERS_TYPE;
|
|
4617
|
-
status?: 'initializing' | 'producing' | 'paused' | 'failed' | 'closing' | 'closed' | 'UNKNOWN';
|
|
4618
|
-
appData: {
|
|
4619
|
-
screenShare?: boolean;
|
|
4620
|
-
supportsRemoteControl?: boolean;
|
|
4621
|
-
};
|
|
4622
|
-
error?: string;
|
|
4623
|
-
closureReason?: string;
|
|
4624
|
-
remoteAnswer?: SessionDescription;
|
|
4625
|
-
trackId?: string;
|
|
4626
|
-
};
|
|
4627
|
-
consumer?: {
|
|
4628
|
-
id: string;
|
|
4629
|
-
peerId?: string;
|
|
4630
|
-
kind?: string;
|
|
4631
|
-
appData?: {
|
|
4632
|
-
screenShare?: boolean;
|
|
4633
|
-
supportsRemoteControl?: boolean;
|
|
4634
|
-
};
|
|
4635
|
-
remotelyPaused?: boolean;
|
|
4636
|
-
producerId?: string;
|
|
4637
|
-
closureReason?: string;
|
|
4638
|
-
sessionDescription?: RTCSessionDescriptionInit;
|
|
4639
|
-
};
|
|
4640
|
-
consumerIds?: string[];
|
|
4641
|
-
consumerState?: ConsumerState;
|
|
4642
|
-
consumerStateMap?: {
|
|
4643
|
-
[key: string]: ConsumerState;
|
|
4644
|
-
};
|
|
4645
|
-
rtcChannel?: {
|
|
4646
|
-
label?: string;
|
|
4647
|
-
message?: DCMessage;
|
|
4648
|
-
messageStringified?: string;
|
|
4649
|
-
};
|
|
4650
|
-
localStorage?: {
|
|
4651
|
-
key?: string;
|
|
4652
|
-
value?: string;
|
|
4653
|
-
};
|
|
4654
|
-
spotlight?: {
|
|
4655
|
-
spotlighter?: {
|
|
4656
|
-
id?: string;
|
|
4657
|
-
};
|
|
4658
|
-
currentTab?: {
|
|
4659
|
-
id?: string;
|
|
4660
|
-
type?: ActiveTabType;
|
|
4661
|
-
};
|
|
4662
|
-
};
|
|
4663
|
-
networkCall?: {
|
|
4664
|
-
status?: number;
|
|
4665
|
-
statusText?: string;
|
|
4666
|
-
baseURL?: string;
|
|
4667
|
-
url?: string;
|
|
4668
|
-
retries?: number;
|
|
4669
|
-
method?: string;
|
|
4670
|
-
isOnline?: string;
|
|
4671
|
-
ip?: any;
|
|
4672
|
-
timezone?: string;
|
|
4673
|
-
};
|
|
4674
|
-
ipInfo?: {
|
|
4675
|
-
city: string;
|
|
4676
|
-
country: string;
|
|
4677
|
-
region: string;
|
|
4678
|
-
loc: string;
|
|
4679
|
-
timezone: string;
|
|
4680
|
-
ip: string;
|
|
4681
|
-
postal: string;
|
|
4682
|
-
};
|
|
4683
|
-
dytePolls?: {
|
|
4684
|
-
hasQuestion?: boolean;
|
|
4685
|
-
optionsLength?: number;
|
|
4686
|
-
};
|
|
4687
|
-
dyteChat?: {
|
|
4688
|
-
imageType?: string;
|
|
4689
|
-
messageType?: string;
|
|
4690
|
-
};
|
|
4691
|
-
dyteParticipant?: {
|
|
4692
|
-
id: string;
|
|
4693
|
-
};
|
|
4694
|
-
actions?: {
|
|
4695
|
-
disableAllAudio?: {
|
|
4696
|
-
allowUnmute?: boolean;
|
|
4697
|
-
};
|
|
4698
|
-
trackRobustness?: {
|
|
4699
|
-
reacquireTrack?: boolean;
|
|
4700
|
-
eventType?: string;
|
|
4701
|
-
};
|
|
4702
|
-
};
|
|
4703
|
-
recording?: {
|
|
4704
|
-
id?: string;
|
|
4705
|
-
state?: RecordingState;
|
|
4706
|
-
};
|
|
4707
|
-
selectedPeer?: {
|
|
4708
|
-
oldIndex?: number;
|
|
4709
|
-
newIndex?: number;
|
|
4710
|
-
peerId?: string;
|
|
4711
|
-
};
|
|
4712
|
-
pageNavigation?: {
|
|
4713
|
-
viewMode: ViewMode;
|
|
4714
|
-
currentPage: number;
|
|
4715
|
-
pageCount: number;
|
|
4716
|
-
maxActiveParticipantsCount: number;
|
|
4717
|
-
settingPage?: number;
|
|
4718
|
-
};
|
|
4719
|
-
connectedMeetings?: {
|
|
4720
|
-
movement?: {
|
|
4721
|
-
sourceMeetingId?: string;
|
|
4722
|
-
destinationMeetingId?: string;
|
|
4723
|
-
totalParticipantsToMove?: number;
|
|
4724
|
-
};
|
|
4725
|
-
};
|
|
4726
|
-
webinar?: {
|
|
4727
|
-
stageStatus?: StageStatus;
|
|
4728
|
-
};
|
|
4729
|
-
livestream?: {
|
|
4730
|
-
stageStatus?: StageStatus;
|
|
4731
|
-
latency?: number;
|
|
4732
|
-
};
|
|
4733
|
-
moduleExists?: {
|
|
4734
|
-
self?: boolean;
|
|
4735
|
-
};
|
|
4736
|
-
performanceObserver?: {
|
|
4737
|
-
api: PerformanceEntry;
|
|
4738
|
-
};
|
|
4739
|
-
dyteLocker?: {
|
|
4740
|
-
methodName: string;
|
|
4741
|
-
lockName: string;
|
|
4742
|
-
};
|
|
4743
|
-
socket?: {
|
|
4744
|
-
retryAttempt: number;
|
|
4745
|
-
};
|
|
4746
|
-
connectionState?: {
|
|
4747
|
-
joinAttempted: boolean;
|
|
4748
|
-
};
|
|
4749
|
-
source?: string;
|
|
4750
|
-
eventListener?: {
|
|
4751
|
-
eventName: string;
|
|
4752
|
-
listenerCount: number;
|
|
4753
|
-
};
|
|
4754
|
-
dataChannelMessageChunk?: {
|
|
4285
|
+
interface RecordingConfig {
|
|
4286
|
+
fileNamePrefix?: string;
|
|
4287
|
+
videoConfig?: {
|
|
4288
|
+
height?: number;
|
|
4289
|
+
width?: number;
|
|
4290
|
+
codec?: string;
|
|
4291
|
+
};
|
|
4292
|
+
}
|
|
4293
|
+
interface ReactNativeFile {
|
|
4294
|
+
uri: string;
|
|
4295
|
+
name: string;
|
|
4296
|
+
type: string;
|
|
4297
|
+
}
|
|
4298
|
+
declare class APIClient extends API {
|
|
4299
|
+
telemetry: RTKTelemetry;
|
|
4300
|
+
constructor(context: Context<RTKContextState>, options?: APIOptions);
|
|
4301
|
+
getIPDetails(): Promise<any>;
|
|
4302
|
+
getICEServers(): Promise<any>;
|
|
4303
|
+
getPlugins(): Promise<any[]>;
|
|
4304
|
+
getPluginDetails(pluginId: string): Promise<RTKPluginResponse>;
|
|
4305
|
+
getPluginConfig(pluginBaseUrl: string): Promise<PluginConfig>;
|
|
4306
|
+
authorizePlugin(pluginId: string): Promise<string>;
|
|
4307
|
+
getPresignedUrls(filename: string, viewType: string): Promise<{
|
|
4308
|
+
getLocation: any;
|
|
4309
|
+
putLocation: any;
|
|
4310
|
+
}>;
|
|
4311
|
+
uploadFile(file: File | ReactNativeFile, url: string): Promise<void>;
|
|
4312
|
+
startLivestreaming({ manualIngestion, }: StartLivestreamConfig): Promise<LivestreamResponse>;
|
|
4313
|
+
stopLivestreaming(): Promise<FetchResponse<any>>;
|
|
4314
|
+
getActiveLivestream(): Promise<LivestreamResponse>;
|
|
4315
|
+
getUserDetails(): Promise<UserDetailsResponseV2>;
|
|
4316
|
+
startRecording(config: RecordingConfig, allowMultiple?: boolean): Promise<string>;
|
|
4317
|
+
updateRecording(recordingId: string, action: 'stop' | 'pause' | 'resume'): Promise<FetchResponse<any>>;
|
|
4318
|
+
getActiveRecording(): Promise<{
|
|
4319
|
+
status: string;
|
|
4755
4320
|
id: string;
|
|
4756
|
-
|
|
4757
|
-
|
|
4758
|
-
|
|
4759
|
-
|
|
4760
|
-
|
|
4761
|
-
|
|
4762
|
-
|
|
4763
|
-
|
|
4764
|
-
|
|
4765
|
-
|
|
4766
|
-
|
|
4767
|
-
|
|
4768
|
-
|
|
4769
|
-
|
|
4770
|
-
|
|
4321
|
+
}>;
|
|
4322
|
+
getActiveTranscript(): Promise<{
|
|
4323
|
+
transcript: string;
|
|
4324
|
+
}>;
|
|
4325
|
+
getRoomNodeData(): Promise<RoomDetails>;
|
|
4326
|
+
}
|
|
4327
|
+
declare enum MessageType {
|
|
4328
|
+
text = "text",
|
|
4329
|
+
image = "image",
|
|
4330
|
+
file = "file",
|
|
4331
|
+
custom = "custom",
|
|
4332
|
+
poll = "poll"
|
|
4333
|
+
}
|
|
4334
|
+
interface BaseMessage<T extends MessageType> {
|
|
4335
|
+
type: T;
|
|
4336
|
+
userId: string;
|
|
4337
|
+
displayName: string;
|
|
4338
|
+
time: Date;
|
|
4339
|
+
timeMs?: number;
|
|
4340
|
+
id: string;
|
|
4341
|
+
isEdited?: boolean;
|
|
4342
|
+
read?: boolean;
|
|
4343
|
+
pluginId?: string;
|
|
4344
|
+
pinned?: boolean;
|
|
4345
|
+
targetUserIds?: string[];
|
|
4346
|
+
channelId?: string;
|
|
4347
|
+
channelIndex?: string;
|
|
4348
|
+
}
|
|
4349
|
+
interface TextMessage extends BaseMessage<MessageType.text> {
|
|
4350
|
+
message: string;
|
|
4351
|
+
}
|
|
4352
|
+
interface CustomMessage extends BaseMessage<MessageType.custom> {
|
|
4353
|
+
message?: string;
|
|
4354
|
+
html?: string;
|
|
4355
|
+
files?: {
|
|
4356
|
+
link: string;
|
|
4357
|
+
type?: string;
|
|
4358
|
+
name?: string;
|
|
4359
|
+
size?: number;
|
|
4360
|
+
}[];
|
|
4361
|
+
images?: {
|
|
4362
|
+
link: string;
|
|
4363
|
+
type?: string;
|
|
4364
|
+
name?: string;
|
|
4365
|
+
size?: number;
|
|
4366
|
+
}[];
|
|
4367
|
+
videos?: {
|
|
4368
|
+
link: string;
|
|
4369
|
+
type?: string;
|
|
4370
|
+
name?: string;
|
|
4371
|
+
size?: number;
|
|
4372
|
+
}[];
|
|
4373
|
+
}
|
|
4374
|
+
interface ImageMessage extends BaseMessage<MessageType.image> {
|
|
4375
|
+
link: string;
|
|
4376
|
+
}
|
|
4377
|
+
interface FileMessage extends BaseMessage<MessageType.file> {
|
|
4378
|
+
name: string;
|
|
4379
|
+
size: number;
|
|
4380
|
+
link: string;
|
|
4381
|
+
}
|
|
4382
|
+
type Message = TextMessage | ImageMessage | FileMessage | CustomMessage;
|
|
4383
|
+
interface TextMessagePayload {
|
|
4384
|
+
type: 'text';
|
|
4385
|
+
message: string;
|
|
4386
|
+
replyTo?: TextMessage;
|
|
4387
|
+
}
|
|
4388
|
+
interface CustomMessagePayload {
|
|
4389
|
+
type: 'custom';
|
|
4390
|
+
message?: string;
|
|
4391
|
+
html?: string;
|
|
4392
|
+
files?: (File | string)[];
|
|
4393
|
+
images?: (File | string)[];
|
|
4394
|
+
videos?: (File | string)[];
|
|
4395
|
+
replyTo?: TextMessage;
|
|
4396
|
+
}
|
|
4397
|
+
interface ImageMessagePayload {
|
|
4398
|
+
type: 'image';
|
|
4399
|
+
image: File;
|
|
4400
|
+
}
|
|
4401
|
+
interface FileMessagePayload {
|
|
4402
|
+
type: 'file';
|
|
4403
|
+
file: File;
|
|
4404
|
+
}
|
|
4405
|
+
type MessagePayload = TextMessagePayload | ImageMessagePayload | FileMessagePayload | CustomMessagePayload;
|
|
4406
|
+
interface ChatUpdateParams {
|
|
4407
|
+
action: 'add' | 'edit' | 'delete';
|
|
4408
|
+
message: Message | {
|
|
4409
|
+
id: string;
|
|
4410
|
+
channelId: string;
|
|
4411
|
+
};
|
|
4412
|
+
messages: Message[];
|
|
4413
|
+
}
|
|
4414
|
+
type ChatEvents = {
|
|
4415
|
+
['chatUpdate']: (payload: ChatUpdateParams) => void;
|
|
4416
|
+
['pinMessage']: (payload: Pick<ChatUpdateParams, Exclude<keyof ChatUpdateParams, 'action'>>) => void;
|
|
4417
|
+
['unpinMessage']: (payload: Pick<ChatUpdateParams, Exclude<keyof ChatUpdateParams, 'action'>>) => void;
|
|
4418
|
+
['channelCreate']: (channel: ChatChannel) => void;
|
|
4419
|
+
['channelMessageUpdate']: (channel: ChatChannel) => void;
|
|
4420
|
+
['channelUpdate']: (channel?: ChatChannel) => void;
|
|
4421
|
+
['*']: (event: string, ...args: any[]) => void;
|
|
4771
4422
|
};
|
|
4772
|
-
|
|
4773
|
-
|
|
4774
|
-
|
|
4775
|
-
|
|
4776
|
-
|
|
4777
|
-
|
|
4778
|
-
|
|
4779
|
-
|
|
4780
|
-
|
|
4781
|
-
|
|
4782
|
-
static readonly logsEndpoint: string;
|
|
4783
|
-
static tracingEnabled: boolean;
|
|
4784
|
-
static initialized: boolean;
|
|
4785
|
-
static readonly logsProcessingInterval = 7000;
|
|
4786
|
-
static logExclusionList: string[];
|
|
4787
|
-
static meetingMetadata: {
|
|
4788
|
-
peerId?: string;
|
|
4789
|
-
roomName?: string;
|
|
4790
|
-
organizationId?: string;
|
|
4791
|
-
sdkVersion?: string;
|
|
4792
|
-
deviceInfo?: object;
|
|
4793
|
-
visitedUrl?: string;
|
|
4794
|
-
userId?: string;
|
|
4423
|
+
declare class RTKChat$1 extends RTKTypedEventEmitter<ChatEvents> {
|
|
4424
|
+
messages: Message[];
|
|
4425
|
+
channels: ChatChannel[];
|
|
4426
|
+
maxTextLimit: number;
|
|
4427
|
+
readonly telemetry: RTKTelemetry;
|
|
4428
|
+
setMaxTextLimit(limit: number): void;
|
|
4429
|
+
constructor(context: Context<RTKContextState>, chatSocketHandler: ChatSocketHandler, chatChannelSocketHandler: ChatChannelSocketHandler, self: RTKSelf$1, participants: RTKParticipants$1);
|
|
4430
|
+
readonly rateLimits: {
|
|
4431
|
+
maxInvocations: number;
|
|
4432
|
+
period: number;
|
|
4795
4433
|
};
|
|
4796
|
-
|
|
4797
|
-
|
|
4798
|
-
|
|
4799
|
-
|
|
4800
|
-
|
|
4801
|
-
|
|
4802
|
-
|
|
4803
|
-
|
|
4434
|
+
updateRateLimits(num: number, period: number): void;
|
|
4435
|
+
sendTextMessage(message: string, peerIds?: string[]): Promise<void>;
|
|
4436
|
+
sendCustomMessage(message: CustomMessagePayload, peerIds?: string[]): Promise<void>;
|
|
4437
|
+
sendImageMessage(image: File | ReactNativeFile, peerIds?: string[]): Promise<void>;
|
|
4438
|
+
sendFileMessage(file: File | ReactNativeFile, peerIds?: string[]): Promise<void>;
|
|
4439
|
+
sendMessage(message: MessagePayload, participantIds?: string[]): Promise<void>;
|
|
4440
|
+
editTextMessage(messageId: string, message: string, channelId?: string): Promise<void>;
|
|
4441
|
+
editImageMessage(messageId: string, image: File | ReactNativeFile, channelId?: string): Promise<void>;
|
|
4442
|
+
editFileMessage(messageId: string, file: File | ReactNativeFile, channelId?: string): Promise<void>;
|
|
4443
|
+
editMessage(messageId: string, message: MessagePayload, channelId?: string): Promise<void>;
|
|
4444
|
+
deleteMessage(messageId: string, channelId?: string): Promise<void>;
|
|
4445
|
+
getMessagesByUser(userId: string): Message[];
|
|
4446
|
+
getMessagesByType(type: keyof typeof MessageType): Message[];
|
|
4447
|
+
pin(id: string): Promise<void>;
|
|
4448
|
+
unpin(id: string): Promise<void>;
|
|
4449
|
+
getMessages(timeStamp: number, size: number, reversed: boolean, offset?: number, channelId?: string): Promise<{
|
|
4450
|
+
messages: Message[];
|
|
4451
|
+
next: boolean;
|
|
4452
|
+
}>;
|
|
4453
|
+
createChannel(channelName: string, memberIds: string[], options?: {
|
|
4454
|
+
displayPictureUrl?: string;
|
|
4455
|
+
visibility?: string;
|
|
4456
|
+
isDirectMessage?: boolean;
|
|
4457
|
+
}): Promise<ChatChannel>;
|
|
4458
|
+
updateChannel(channelId: string, payload: UpdateChannelRequestPayload): Promise<ChatChannel>;
|
|
4459
|
+
sendMessageToChannel(message: MessagePayload, channelId: string, options?: {
|
|
4460
|
+
replyTo?: Message;
|
|
4461
|
+
}): Promise<void>;
|
|
4462
|
+
getChannelMembers(channelId: string): Promise<RTKBasicParticipant[]>;
|
|
4463
|
+
searchMessages(query: string, filters?: SearchFilters): Promise<Message[]>;
|
|
4464
|
+
markLastReadMessage(channelId: string, message: Message): Promise<void>;
|
|
4465
|
+
readonly pinned: Message[];
|
|
4466
|
+
}
|
|
4467
|
+
declare class PollSocketHandler {
|
|
4468
|
+
readonly logger: RTKLogger$1;
|
|
4469
|
+
readonly telemetry: RTKTelemetry;
|
|
4470
|
+
constructor(context: Context<RTKContextState>, socketService: SocketService);
|
|
4471
|
+
getPolls(): Promise<{
|
|
4472
|
+
id: string;
|
|
4473
|
+
payload: Uint8Array;
|
|
4474
|
+
}>;
|
|
4475
|
+
createPoll(question: string, options: string[], anonymous?: boolean, hideVotes?: boolean): boolean;
|
|
4476
|
+
votePoll(id: string, index: number): boolean;
|
|
4477
|
+
on(event: number, handler: (message: UpdatePollResponse) => void): void;
|
|
4478
|
+
removeListeners(event: number): void;
|
|
4479
|
+
}
|
|
4480
|
+
interface PollOption {
|
|
4481
|
+
text: string;
|
|
4482
|
+
votes: {
|
|
4483
|
+
id: string;
|
|
4484
|
+
name: string;
|
|
4485
|
+
}[];
|
|
4486
|
+
count: number;
|
|
4487
|
+
}
|
|
4488
|
+
interface Poll {
|
|
4489
|
+
id: string;
|
|
4490
|
+
question: string;
|
|
4491
|
+
options: PollOption[];
|
|
4492
|
+
anonymous: boolean;
|
|
4493
|
+
hideVotes: boolean;
|
|
4494
|
+
createdBy: string;
|
|
4495
|
+
createdByUserId: string;
|
|
4496
|
+
voted: string[];
|
|
4497
|
+
}
|
|
4498
|
+
type PollsEvents = {
|
|
4499
|
+
['pollsUpdate']: (payload: {
|
|
4500
|
+
polls: Poll[];
|
|
4501
|
+
newPoll: boolean;
|
|
4502
|
+
}) => void;
|
|
4503
|
+
['*']: (eventName: string, ...args: any[]) => void;
|
|
4504
|
+
};
|
|
4505
|
+
declare class RTKPolls$1 extends RTKTypedEventEmitter<PollsEvents> {
|
|
4506
|
+
items: Poll[];
|
|
4507
|
+
constructor(context: Context<RTKContextState>, self: RTKSelf$1, pollSocketHandler: PollSocketHandler);
|
|
4508
|
+
create(question: string, options: string[], anonymous?: boolean, hideVotes?: boolean): Promise<void>;
|
|
4509
|
+
vote(id: string, index: number): Promise<void>;
|
|
4510
|
+
}
|
|
4511
|
+
type PluginMapEvents = {
|
|
4512
|
+
['pluginAdded']: (plugin: RTKPlugin$1) => void;
|
|
4513
|
+
['pluginDeleted']: (plugin: RTKPlugin$1) => void;
|
|
4514
|
+
};
|
|
4515
|
+
type PluginEvents = {
|
|
4516
|
+
['stateUpdate']: (payload: {
|
|
4517
|
+
active: boolean;
|
|
4518
|
+
pluginId: string;
|
|
4519
|
+
bind?: (...args: any[]) => void;
|
|
4520
|
+
views: any;
|
|
4521
|
+
}) => void;
|
|
4522
|
+
['ready']: () => void;
|
|
4523
|
+
['closed']: () => void;
|
|
4524
|
+
['toggleViewMode']: (...args: any[]) => void;
|
|
4525
|
+
['enabled']: () => void;
|
|
4526
|
+
['*']: (eventName: string, ...args: any[]) => void;
|
|
4527
|
+
};
|
|
4528
|
+
declare class RTKPluginMap$1<T extends RTKPlugin$1 = RTKPlugin$1> extends RTKMap<PluginEvents, T, PluginMapEvents> {
|
|
4529
|
+
constructor(logger: RTKLogger$1);
|
|
4530
|
+
add(plugin: T, emitEvent?: boolean): this;
|
|
4531
|
+
delete(pluginId: string, emitEvent?: boolean, removeListeners?: boolean): boolean;
|
|
4532
|
+
}
|
|
4533
|
+
declare class RTKPlugins$1 {
|
|
4534
|
+
readonly all: RTKPluginMap$1;
|
|
4535
|
+
readonly active: RTKPluginMap$1;
|
|
4536
|
+
constructor(logger: RTKLogger);
|
|
4537
|
+
}
|
|
4538
|
+
type RecordingState = 'IDLE' | 'STARTING' | 'RECORDING' | 'PAUSED' | 'STOPPING';
|
|
4539
|
+
type RecordingType = 'BROWSER' | 'TRACK' | 'COMPOSITE';
|
|
4540
|
+
type RecordingInfo = {
|
|
4541
|
+
state: RecordingState;
|
|
4542
|
+
id: string;
|
|
4543
|
+
type: RecordingType;
|
|
4544
|
+
};
|
|
4545
|
+
type RecordingEvents = {
|
|
4546
|
+
['recordingUpdate']: (state: RecordingState) => void;
|
|
4547
|
+
['*']: (eventName: string, ...args: any[]) => void;
|
|
4548
|
+
};
|
|
4549
|
+
declare class RTKRecording$1 extends RTKTypedEventEmitter<RecordingEvents> {
|
|
4550
|
+
recordingPeerIds: string[];
|
|
4551
|
+
readonly recordingState: RecordingState;
|
|
4552
|
+
recordings: RecordingInfo[];
|
|
4553
|
+
constructor(context: Context<RTKContextState>, self: RTKSelf);
|
|
4554
|
+
readonly telemetry: RTKTelemetry;
|
|
4555
|
+
updateRecordings(recordings: RecordingInfo[]): void;
|
|
4556
|
+
start(opts?: {
|
|
4557
|
+
allowMultiple: boolean;
|
|
4558
|
+
}): Promise<void>;
|
|
4559
|
+
stop(recordingId?: string): Promise<void>;
|
|
4560
|
+
pause(recordingId?: string): Promise<void>;
|
|
4561
|
+
resume(recordingId?: string): Promise<void>;
|
|
4804
4562
|
}
|
|
4805
|
-
|
|
4806
|
-
|
|
4807
|
-
|
|
4808
|
-
|
|
4809
|
-
|
|
4810
|
-
|
|
4811
|
-
|
|
4563
|
+
declare class BrowserDetection {
|
|
4564
|
+
_bowser: any;
|
|
4565
|
+
_name: any;
|
|
4566
|
+
_version: any;
|
|
4567
|
+
init(browserInfo?: any): void;
|
|
4568
|
+
getName(): any;
|
|
4569
|
+
isChrome(): boolean;
|
|
4570
|
+
isOpera(): boolean;
|
|
4571
|
+
isFirefox(): boolean;
|
|
4572
|
+
isIExplorer(): boolean;
|
|
4573
|
+
isSafari(): boolean;
|
|
4574
|
+
isNWJS(): boolean;
|
|
4575
|
+
isElectron(): boolean;
|
|
4576
|
+
isReactNative(): boolean;
|
|
4577
|
+
getVersion(): any;
|
|
4578
|
+
isMobile(): boolean;
|
|
4579
|
+
getDeviceInfo: () => {
|
|
4580
|
+
isMobile: boolean;
|
|
4581
|
+
browserName: any;
|
|
4582
|
+
osName: any;
|
|
4583
|
+
browserVersion: any;
|
|
4584
|
+
osVersionName: any;
|
|
4585
|
+
engineName: any;
|
|
4586
|
+
};
|
|
4587
|
+
_checkCondition(checkTree: any): any;
|
|
4588
|
+
isVersionGreaterThan(version: any): any;
|
|
4589
|
+
isVersionLessThan(version: any): any;
|
|
4590
|
+
isVersionEqualTo(version: any): any;
|
|
4591
|
+
}
|
|
4592
|
+
declare class BrowserCapabilities extends BrowserDetection {
|
|
4593
|
+
doesVideoMuteByStreamRemove(): boolean;
|
|
4594
|
+
supportsP2P(): boolean;
|
|
4595
|
+
isChromiumBased(): boolean;
|
|
4596
|
+
isWebKitBased(): boolean;
|
|
4597
|
+
isSupported(): boolean;
|
|
4598
|
+
isUserInteractionRequiredForUnmute(): any;
|
|
4599
|
+
supportsVideoMuteOnConnInterrupted(): boolean;
|
|
4600
|
+
supportsBandwidthStatistics(): boolean;
|
|
4601
|
+
supportsCodecPreferences(): boolean;
|
|
4602
|
+
supportsDeviceChangeEvent(): boolean;
|
|
4603
|
+
supportsLocalCandidateRttStatistics(): boolean;
|
|
4604
|
+
supportsPerformanceObserver(): boolean;
|
|
4605
|
+
supportsReceiverStats(): boolean;
|
|
4606
|
+
supportsRTTStatistics(): boolean;
|
|
4607
|
+
usesPlanB(): boolean;
|
|
4608
|
+
usesSdpMungingForSimulcast(): boolean;
|
|
4609
|
+
usesUnifiedPlan(): boolean;
|
|
4610
|
+
usesNewGumFlow(): boolean;
|
|
4611
|
+
usesAdapter(): boolean;
|
|
4612
|
+
usesRidsForSimulcast(): boolean;
|
|
4613
|
+
supportsGetDisplayMedia(): boolean;
|
|
4614
|
+
supportsInsertableStreams(): boolean;
|
|
4615
|
+
supportsAudioRed(): boolean;
|
|
4616
|
+
supportsSdpSemantics(): boolean;
|
|
4617
|
+
_getChromiumBasedVersion(): number;
|
|
4618
|
+
isIOSMobile(): boolean;
|
|
4619
|
+
}
|
|
4620
|
+
declare class RTKFeatures {
|
|
4621
|
+
constructor(context: Context<RTKContextState>);
|
|
4622
|
+
hasFeature(featureName: string): boolean;
|
|
4623
|
+
getFeatureValue(featureName: string): _dyteinternals_utils.RTKFlagValues;
|
|
4624
|
+
getAllFeatures(): {
|
|
4625
|
+
[x: string]: _dyteinternals_utils.RTKFlagsEntry;
|
|
4626
|
+
};
|
|
4812
4627
|
}
|
|
4813
4628
|
declare class RTKInternals {
|
|
4814
4629
|
logger: typeof RTKLogger$1;
|
|
@@ -4867,6 +4682,13 @@ declare class RTKStoreManager {
|
|
|
4867
4682
|
constructor(context: Context<RTKContextState>, handler: PluginSocketHandler);
|
|
4868
4683
|
create(name: string): Promise<RTKStore$1>;
|
|
4869
4684
|
}
|
|
4685
|
+
declare const enum PRODUCERS_TYPE {
|
|
4686
|
+
WEBCAM = "webcam",
|
|
4687
|
+
WEBCAM_BACKUP = "webcam_backup",
|
|
4688
|
+
MIC = "mic",
|
|
4689
|
+
SCREENSHARE_VIDEO = "screenshare_video",
|
|
4690
|
+
SCREENSHARE_AUDIO = "screenshare_audio"
|
|
4691
|
+
}
|
|
4870
4692
|
interface MediaPermissions {
|
|
4871
4693
|
canProduceAudio?: MediaProductionPermissionType;
|
|
4872
4694
|
canProduceVideo?: MediaProductionPermissionType;
|
|
@@ -4886,6 +4708,8 @@ declare class MediaNodeClient {
|
|
|
4886
4708
|
readonly authToken: string;
|
|
4887
4709
|
readonly e2ee: boolean;
|
|
4888
4710
|
readonly peerId: string;
|
|
4711
|
+
readonly telemetry: RTKTelemetry;
|
|
4712
|
+
readonly logger: RTKLogger$1;
|
|
4889
4713
|
constructor(context: Context<RTKContextState>, nodeType: MediaNodeType, options: MediaNodeClientOptions);
|
|
4890
4714
|
mediaJoined: boolean;
|
|
4891
4715
|
reset(): void;
|
|
@@ -5081,7 +4905,7 @@ interface DefaultOptions {
|
|
|
5081
4905
|
video?: boolean;
|
|
5082
4906
|
audio?: boolean;
|
|
5083
4907
|
recording?: RecordingConfig;
|
|
5084
|
-
mediaHandler?: RTKSelfMedia;
|
|
4908
|
+
mediaHandler?: RTKSelfMedia$1;
|
|
5085
4909
|
autoSwitchAudioDevice?: boolean;
|
|
5086
4910
|
mediaConfiguration?: {
|
|
5087
4911
|
video?: VideoQualityConstraints;
|
|
@@ -5199,7 +5023,7 @@ declare const ERROR_CODES: {
|
|
|
5199
5023
|
};
|
|
5200
5024
|
declare class RTKError extends Error {
|
|
5201
5025
|
code: keyof typeof ERROR_CODES;
|
|
5202
|
-
constructor(message: string, code?: keyof typeof ERROR_CODES, log?: boolean);
|
|
5026
|
+
constructor(message: string, code?: keyof typeof ERROR_CODES, logger?: RTKLogger$1 | undefined, log?: boolean);
|
|
5203
5027
|
}
|
|
5204
5028
|
type EventMap = {
|
|
5205
5029
|
[key: string]: (...args: any[]) => void;
|
|
@@ -5332,7 +5156,7 @@ declare class AudioPlaybackManager extends AudioPlayback {
|
|
|
5332
5156
|
removeParticipantTrack(participantId: string): void;
|
|
5333
5157
|
}
|
|
5334
5158
|
type RTKContextState = {
|
|
5335
|
-
authToken
|
|
5159
|
+
authToken?: string;
|
|
5336
5160
|
peerId?: string;
|
|
5337
5161
|
apiBase?: string;
|
|
5338
5162
|
baseURI?: string;
|
|
@@ -5368,6 +5192,8 @@ type RTKContextState = {
|
|
|
5368
5192
|
audioPlayback?: AudioPlaybackManager;
|
|
5369
5193
|
options?: RealtimeKitClientOptions;
|
|
5370
5194
|
self?: RTKSelf;
|
|
5195
|
+
telemetry?: RTKTelemetry;
|
|
5196
|
+
logger?: RTKLogger$1;
|
|
5371
5197
|
meeting?: RealtimeKitClient;
|
|
5372
5198
|
};
|
|
5373
5199
|
interface Context<T extends Record<string, any>> {
|
|
@@ -5391,277 +5217,487 @@ declare class SocketService {
|
|
|
5391
5217
|
readonly authToken: string;
|
|
5392
5218
|
readonly capabilities: SocketServiceCapabilities;
|
|
5393
5219
|
joinAttempted: boolean;
|
|
5220
|
+
readonly telemetry: RTKTelemetry;
|
|
5221
|
+
readonly logger: RTKLogger$1;
|
|
5394
5222
|
readonly peerId: string;
|
|
5395
5223
|
constructor(context: Context<RTKContextState>, { peerId, meetingId, authToken, capabilities, }: {
|
|
5224
|
+
peerId: string;
|
|
5225
|
+
meetingId: string;
|
|
5226
|
+
authToken: string;
|
|
5227
|
+
capabilities: SocketServiceCapabilities;
|
|
5228
|
+
});
|
|
5229
|
+
updateURL(peerID: string): void;
|
|
5230
|
+
readonly url: string;
|
|
5231
|
+
connect(): Promise<void>;
|
|
5232
|
+
disconnect(): Promise<void>;
|
|
5233
|
+
readonly isConnected: boolean;
|
|
5234
|
+
sendMessage(event: number, protobuf?: Uint8Array, messageId?: string): boolean;
|
|
5235
|
+
sendMessagePromise(event: number, protobuf?: Uint8Array, messageId?: string, resp?: number): Promise<{
|
|
5236
|
+
id: string;
|
|
5237
|
+
payload: Uint8Array;
|
|
5238
|
+
}>;
|
|
5239
|
+
sendMessagePromiseWithTimeout({ event, timeout, protobuf, messageId, resp, }: {
|
|
5240
|
+
timeout: number;
|
|
5241
|
+
event: number;
|
|
5242
|
+
protobuf?: Uint8Array;
|
|
5243
|
+
messageId?: string;
|
|
5244
|
+
resp?: number;
|
|
5245
|
+
}): Promise<{
|
|
5246
|
+
id: string;
|
|
5247
|
+
payload: Uint8Array;
|
|
5248
|
+
}>;
|
|
5249
|
+
on(event: number, listener: (message: {
|
|
5250
|
+
id?: string;
|
|
5251
|
+
payload?: Uint8Array;
|
|
5252
|
+
}) => void): void;
|
|
5253
|
+
onStateEvent(event: SocketStateEvent, listener: (...args: any) => void): void;
|
|
5254
|
+
removeListener(event: number, listener: (message: {
|
|
5255
|
+
id?: string;
|
|
5256
|
+
payload?: Uint8Array;
|
|
5257
|
+
}) => void): void;
|
|
5258
|
+
removeListeners(event: number): void;
|
|
5259
|
+
flush(): any;
|
|
5260
|
+
handleSocketConnectionEvents(): void;
|
|
5261
|
+
}
|
|
5262
|
+
type EventHandlerTypes = PeerInfoResponse | GetWaitingRoomRequests | RecordingEvent | UpdatePeersPresetResponse | PeerJoinBroadcastResponse | PeerJoinCompleteResponse | GlobalPeerPinningBroadcastResponse | PeerLeaveResponse | SelectedPeersResponse | SelectedPeersDiffResponse;
|
|
5263
|
+
declare class RoomSocketHandler {
|
|
5264
|
+
socket: SocketService;
|
|
5265
|
+
readonly telemetry: RTKTelemetry;
|
|
5266
|
+
readonly logger: RTKLogger$1;
|
|
5267
|
+
cleanup(): Promise<void>;
|
|
5268
|
+
constructor(context: Context<RTKContextState>, socketService: SocketService);
|
|
5269
|
+
joinRoom(opts: {
|
|
5270
|
+
name: string;
|
|
5271
|
+
id: string;
|
|
5272
|
+
userId: string;
|
|
5273
|
+
customParticipantId: string;
|
|
5274
|
+
picture?: string;
|
|
5275
|
+
}): Promise<{
|
|
5276
|
+
peer: Peer;
|
|
5277
|
+
}>;
|
|
5278
|
+
getAllAddedParticipants(): Promise<RTKBasicParticipant[]>;
|
|
5279
|
+
getRoomPeers(searchQuery: string, limit: number, offset: number): Promise<RoomPeersInfoResponse>;
|
|
5280
|
+
getRoomPeersNonPaginated(): Promise<RoomPeersInfoResponse>;
|
|
5281
|
+
getStagePeers(): Promise<RoomPeersInfoResponse>;
|
|
5282
|
+
getPeerInfo(peerId: string): Promise<PeerInfoResponse>;
|
|
5283
|
+
getRoomState(): Promise<RoomInfoResponse>;
|
|
5284
|
+
getRoomStageState(): Promise<GetRoomStageStateResponse>;
|
|
5285
|
+
broadcastMessage(type: string, payload: BroadcastMessagePayload): Promise<{
|
|
5286
|
+
id: string;
|
|
5287
|
+
payload: Uint8Array;
|
|
5288
|
+
}>;
|
|
5289
|
+
broadcastToMeetings(type: string, meetingIds: string[], payload: BroadcastMessagePayload): Promise<{
|
|
5290
|
+
id: string;
|
|
5291
|
+
payload: Uint8Array;
|
|
5292
|
+
}>;
|
|
5293
|
+
broadcastToPeers(type: string, peerIds: string[], payload: BroadcastMessagePayload): Promise<boolean>;
|
|
5294
|
+
leaveRoom(): Promise<void>;
|
|
5295
|
+
kick(peerId: string): Promise<void>;
|
|
5296
|
+
kickAll(propagateKickAll?: boolean): Promise<void>;
|
|
5297
|
+
getWaitingRoomRequests(): void;
|
|
5298
|
+
acceptWaitingRoomRequest(userIds: string[]): void;
|
|
5299
|
+
rejectWaitingRoomRequest(userIds: string[]): void;
|
|
5300
|
+
updatePermissions(userIds: string[], patch: PresetUpdates): Promise<{
|
|
5301
|
+
id: string;
|
|
5302
|
+
payload: Uint8Array;
|
|
5303
|
+
}>;
|
|
5304
|
+
on(event: number, handler: (message: EventHandlerTypes) => void): void;
|
|
5305
|
+
getUserPermissions(userId: string): Promise<Pick<PresetTypeV2['permissions'], 'chat' | 'polls' | 'plugins'>>;
|
|
5306
|
+
}
|
|
5307
|
+
interface DeviceConfig {
|
|
5308
|
+
browserName: string;
|
|
5309
|
+
browserVersion: string;
|
|
5310
|
+
isMobile: boolean;
|
|
5311
|
+
engineName: string;
|
|
5312
|
+
osName: string;
|
|
5313
|
+
}
|
|
5314
|
+
interface ProducerState {
|
|
5315
|
+
producerId: string;
|
|
5316
|
+
kind: 'audio' | 'video';
|
|
5317
|
+
pause: boolean;
|
|
5318
|
+
screenShare: boolean;
|
|
5319
|
+
producingTransportId: string;
|
|
5320
|
+
producingPeerId: string;
|
|
5321
|
+
mimeType?: string;
|
|
5322
|
+
}
|
|
5323
|
+
interface Participant {
|
|
5324
|
+
id: string;
|
|
5325
|
+
userId: string;
|
|
5326
|
+
displayName: string;
|
|
5327
|
+
device?: DeviceConfig;
|
|
5328
|
+
picture?: string;
|
|
5329
|
+
isHost: boolean;
|
|
5330
|
+
flags: {
|
|
5331
|
+
[key: string]: string | boolean;
|
|
5332
|
+
};
|
|
5333
|
+
clientSpecificId?: string;
|
|
5334
|
+
customParticipantId?: string;
|
|
5335
|
+
stageStatus?: StageStatus;
|
|
5336
|
+
audioMuted: boolean;
|
|
5337
|
+
audioTrack: MediaStreamTrack;
|
|
5338
|
+
videoTrack: MediaStreamTrack;
|
|
5339
|
+
videoEnabled: boolean;
|
|
5340
|
+
producers?: ProducerState[];
|
|
5341
|
+
metadata?: {
|
|
5342
|
+
preset_name?: string;
|
|
5343
|
+
};
|
|
5344
|
+
recorderType?: string;
|
|
5345
|
+
}
|
|
5346
|
+
declare class RTKParticipant$1 extends RTKTypedEventEmitter<ParticipantEvents> {
|
|
5347
|
+
id: string;
|
|
5348
|
+
userId: string;
|
|
5349
|
+
name: string;
|
|
5350
|
+
picture: string;
|
|
5351
|
+
isHost: boolean;
|
|
5352
|
+
customParticipantId?: string;
|
|
5353
|
+
readonly clientSpecificId: string;
|
|
5354
|
+
flags: {
|
|
5355
|
+
[key: string]: string | boolean;
|
|
5356
|
+
};
|
|
5357
|
+
device: DeviceConfig;
|
|
5358
|
+
videoTrack: MediaStreamTrack;
|
|
5359
|
+
audioTrack: MediaStreamTrack;
|
|
5360
|
+
screenShareTracks: {
|
|
5361
|
+
audio: MediaStreamTrack;
|
|
5362
|
+
video: MediaStreamTrack;
|
|
5363
|
+
};
|
|
5364
|
+
videoEnabled: boolean;
|
|
5365
|
+
audioEnabled: boolean;
|
|
5366
|
+
screenShareEnabled: boolean;
|
|
5367
|
+
producers: ProducerState[];
|
|
5368
|
+
manualProducerConfig: PeerProducerConfig;
|
|
5369
|
+
supportsRemoteControl: boolean;
|
|
5370
|
+
presetName?: string;
|
|
5371
|
+
readonly stageStatus: StageStatus;
|
|
5372
|
+
readonly telemetry: RTKTelemetry;
|
|
5373
|
+
constructor(context: Context<RTKContextState>, participant: Participant, self: RTKSelf, roomSocket: RoomSocketHandler);
|
|
5374
|
+
setVideoEnabled(videoEnabled: boolean, emitEvent?: boolean): void;
|
|
5375
|
+
setAudioEnabled(audioEnabled: boolean, emitEvent?: boolean): void;
|
|
5376
|
+
setScreenShareEnabled(screenShareEnabled: boolean, emitEvent?: boolean): void;
|
|
5377
|
+
pin(): Promise<void>;
|
|
5378
|
+
unpin(): Promise<void>;
|
|
5379
|
+
setIsPinned(isPinned: boolean, emitEvent?: boolean): void;
|
|
5380
|
+
disableAudio(): Promise<void>;
|
|
5381
|
+
kick(): Promise<void>;
|
|
5382
|
+
disableVideo(): Promise<void>;
|
|
5383
|
+
getPermissions(): Promise<Pick<_dyteinternals_utils.Permissions, "plugins" | "polls" | "chat">>;
|
|
5384
|
+
setStageStatus(stageStatus: StageStatus): void;
|
|
5385
|
+
readonly isPinned: boolean;
|
|
5386
|
+
registerVideoElement(videoElem: HTMLVideoElement): void;
|
|
5387
|
+
deregisterVideoElement(videoElem?: HTMLVideoElement): void;
|
|
5388
|
+
}
|
|
5389
|
+
declare function createSafeToLogError(ex: any): {
|
|
5390
|
+
stack?: string;
|
|
5391
|
+
message?: string;
|
|
5392
|
+
name?: string;
|
|
5393
|
+
reason?: string;
|
|
5394
|
+
code?: number | string;
|
|
5395
|
+
};
|
|
5396
|
+
type SupportedEventSeverities = 'info' | 'error' | 'debug' | 'log' | 'warn';
|
|
5397
|
+
type LogData$2 = {
|
|
5398
|
+
error?: ReturnType<typeof createSafeToLogError>;
|
|
5399
|
+
peers?: string;
|
|
5400
|
+
flags?: string | {
|
|
5401
|
+
[key: string]: {
|
|
5402
|
+
enabled: boolean;
|
|
5403
|
+
value: string | number | boolean;
|
|
5404
|
+
};
|
|
5405
|
+
};
|
|
5406
|
+
devices?: string | MediaDeviceInfo[];
|
|
5407
|
+
debuggingHint?: string;
|
|
5408
|
+
constraints?: string | RTKMediaStreamConstraints;
|
|
5409
|
+
timeout?: number;
|
|
5410
|
+
execTime?: number;
|
|
5411
|
+
country?: string;
|
|
5412
|
+
media?: {
|
|
5413
|
+
audio?: {
|
|
5414
|
+
enabled: boolean;
|
|
5415
|
+
deviceName?: string;
|
|
5416
|
+
deviceId?: string;
|
|
5417
|
+
trackId?: string;
|
|
5418
|
+
permission?: keyof typeof MediaPermission;
|
|
5419
|
+
canProduce?: MediaProductionPermissionType;
|
|
5420
|
+
};
|
|
5421
|
+
video?: {
|
|
5422
|
+
enabled?: boolean;
|
|
5423
|
+
deviceName?: string;
|
|
5424
|
+
deviceId?: string;
|
|
5425
|
+
trackId?: string;
|
|
5426
|
+
permission?: keyof typeof MediaPermission;
|
|
5427
|
+
canProduce?: MediaProductionPermissionType;
|
|
5428
|
+
layer?: number;
|
|
5429
|
+
};
|
|
5430
|
+
screenshare?: {
|
|
5431
|
+
enabled: boolean;
|
|
5432
|
+
count?: number;
|
|
5433
|
+
maxAllowedCount?: number;
|
|
5434
|
+
permission?: keyof typeof MediaPermission;
|
|
5435
|
+
deviceName?: string;
|
|
5436
|
+
deviceId?: string;
|
|
5437
|
+
audio?: {
|
|
5438
|
+
enabled: boolean;
|
|
5439
|
+
trackId?: string;
|
|
5440
|
+
};
|
|
5441
|
+
video?: {
|
|
5442
|
+
enabled: boolean;
|
|
5443
|
+
trackId?: string;
|
|
5444
|
+
};
|
|
5445
|
+
canProduce?: MediaProductionPermissionType;
|
|
5446
|
+
};
|
|
5447
|
+
};
|
|
5448
|
+
producerInfo?: {
|
|
5396
5449
|
peerId: string;
|
|
5397
|
-
|
|
5398
|
-
|
|
5399
|
-
|
|
5400
|
-
|
|
5401
|
-
|
|
5402
|
-
|
|
5403
|
-
|
|
5404
|
-
|
|
5405
|
-
|
|
5406
|
-
|
|
5407
|
-
|
|
5408
|
-
|
|
5409
|
-
|
|
5410
|
-
}>;
|
|
5411
|
-
sendMessagePromiseWithTimeout({ event, timeout, protobuf, messageId, resp, }: {
|
|
5412
|
-
timeout: number;
|
|
5413
|
-
event: number;
|
|
5414
|
-
protobuf?: Uint8Array;
|
|
5415
|
-
messageId?: string;
|
|
5416
|
-
resp?: number;
|
|
5417
|
-
}): Promise<{
|
|
5450
|
+
producers: ProducerState[];
|
|
5451
|
+
};
|
|
5452
|
+
preferredDevice?: {
|
|
5453
|
+
kind: 'audio' | 'video';
|
|
5454
|
+
preferredDeviceId?: string;
|
|
5455
|
+
lastUsedPreferredDeviceId?: string;
|
|
5456
|
+
};
|
|
5457
|
+
mediaPermissionsErrors?: {
|
|
5458
|
+
kind: 'audio' | 'video' | 'screenshare';
|
|
5459
|
+
message: string;
|
|
5460
|
+
deviceId?: string;
|
|
5461
|
+
};
|
|
5462
|
+
pip?: {
|
|
5418
5463
|
id: string;
|
|
5419
|
-
|
|
5420
|
-
|
|
5421
|
-
|
|
5464
|
+
handRaised?: boolean;
|
|
5465
|
+
source?: any;
|
|
5466
|
+
};
|
|
5467
|
+
memoize?: {
|
|
5468
|
+
doubleInvoked?: {
|
|
5469
|
+
property: string;
|
|
5470
|
+
};
|
|
5471
|
+
};
|
|
5472
|
+
dyteClientInitOptions?: RealtimeKitClientOptions;
|
|
5473
|
+
plugin?: {
|
|
5422
5474
|
id?: string;
|
|
5423
|
-
|
|
5424
|
-
|
|
5425
|
-
|
|
5426
|
-
|
|
5475
|
+
name?: string;
|
|
5476
|
+
enabledBy?: string;
|
|
5477
|
+
duration?: number;
|
|
5478
|
+
storeName?: string;
|
|
5479
|
+
data?: any;
|
|
5480
|
+
};
|
|
5481
|
+
roomJoined?: boolean;
|
|
5482
|
+
transport?: {
|
|
5427
5483
|
id?: string;
|
|
5428
|
-
|
|
5429
|
-
|
|
5430
|
-
|
|
5431
|
-
|
|
5432
|
-
|
|
5433
|
-
|
|
5434
|
-
|
|
5435
|
-
|
|
5436
|
-
|
|
5437
|
-
|
|
5438
|
-
|
|
5439
|
-
|
|
5440
|
-
|
|
5441
|
-
|
|
5442
|
-
|
|
5443
|
-
|
|
5444
|
-
|
|
5445
|
-
|
|
5446
|
-
|
|
5447
|
-
|
|
5448
|
-
|
|
5449
|
-
|
|
5450
|
-
|
|
5451
|
-
|
|
5452
|
-
|
|
5453
|
-
|
|
5454
|
-
|
|
5455
|
-
|
|
5456
|
-
}
|
|
5457
|
-
|
|
5458
|
-
|
|
5459
|
-
|
|
5460
|
-
|
|
5461
|
-
|
|
5462
|
-
|
|
5463
|
-
|
|
5464
|
-
|
|
5465
|
-
|
|
5466
|
-
|
|
5467
|
-
|
|
5468
|
-
|
|
5469
|
-
|
|
5470
|
-
[
|
|
5471
|
-
|
|
5472
|
-
|
|
5473
|
-
|
|
5474
|
-
|
|
5475
|
-
|
|
5476
|
-
|
|
5477
|
-
|
|
5484
|
+
type?: 'send' | 'recv';
|
|
5485
|
+
status?: RTCPeerConnectionState | 'reconnecting';
|
|
5486
|
+
lastDisconnectedTime?: string;
|
|
5487
|
+
lastDisconnectedTimeOffset?: number;
|
|
5488
|
+
durationPassed?: number;
|
|
5489
|
+
remoteOfferAnswer?: RTCSessionDescriptionInit;
|
|
5490
|
+
serverId?: string;
|
|
5491
|
+
};
|
|
5492
|
+
iceCandidate?: RTCIceCandidate;
|
|
5493
|
+
iceRestart?: {
|
|
5494
|
+
status?: RTCPeerConnectionState | 'reconnecting';
|
|
5495
|
+
isSendTransport?: boolean;
|
|
5496
|
+
isRecvTransport?: boolean;
|
|
5497
|
+
currentAttempt?: number;
|
|
5498
|
+
};
|
|
5499
|
+
producer?: {
|
|
5500
|
+
id: string;
|
|
5501
|
+
peerId?: string;
|
|
5502
|
+
kind: 'audio' | 'video' | PRODUCERS_TYPE;
|
|
5503
|
+
status?: 'initializing' | 'producing' | 'paused' | 'failed' | 'closing' | 'closed' | 'UNKNOWN';
|
|
5504
|
+
appData: {
|
|
5505
|
+
screenShare?: boolean;
|
|
5506
|
+
supportsRemoteControl?: boolean;
|
|
5507
|
+
};
|
|
5508
|
+
error?: string;
|
|
5509
|
+
closureReason?: string;
|
|
5510
|
+
remoteAnswer?: SessionDescription;
|
|
5511
|
+
trackId?: string;
|
|
5512
|
+
};
|
|
5513
|
+
consumer?: {
|
|
5514
|
+
id: string;
|
|
5515
|
+
peerId?: string;
|
|
5516
|
+
kind?: string;
|
|
5517
|
+
appData?: {
|
|
5518
|
+
screenShare?: boolean;
|
|
5519
|
+
supportsRemoteControl?: boolean;
|
|
5520
|
+
};
|
|
5521
|
+
remotelyPaused?: boolean;
|
|
5522
|
+
producerId?: string;
|
|
5523
|
+
closureReason?: string;
|
|
5524
|
+
sessionDescription?: RTCSessionDescriptionInit;
|
|
5525
|
+
};
|
|
5526
|
+
consumerIds?: string[];
|
|
5527
|
+
consumerState?: ConsumerState;
|
|
5528
|
+
consumerStateMap?: {
|
|
5529
|
+
[key: string]: ConsumerState;
|
|
5530
|
+
};
|
|
5531
|
+
rtcChannel?: {
|
|
5532
|
+
label?: string;
|
|
5533
|
+
message?: DCMessage;
|
|
5534
|
+
messageStringified?: string;
|
|
5535
|
+
};
|
|
5536
|
+
localStorage?: {
|
|
5537
|
+
key?: string;
|
|
5538
|
+
value?: string;
|
|
5539
|
+
};
|
|
5540
|
+
spotlight?: {
|
|
5541
|
+
spotlighter?: {
|
|
5542
|
+
id?: string;
|
|
5543
|
+
};
|
|
5544
|
+
currentTab?: {
|
|
5545
|
+
id?: string;
|
|
5546
|
+
type?: ActiveTabType;
|
|
5547
|
+
};
|
|
5548
|
+
};
|
|
5549
|
+
networkCall?: {
|
|
5550
|
+
status?: number;
|
|
5551
|
+
statusText?: string;
|
|
5552
|
+
baseURL?: string;
|
|
5553
|
+
url?: string;
|
|
5554
|
+
retries?: number;
|
|
5555
|
+
method?: string;
|
|
5556
|
+
isOnline?: string;
|
|
5557
|
+
ip?: any;
|
|
5558
|
+
timezone?: string;
|
|
5559
|
+
};
|
|
5560
|
+
ipInfo?: {
|
|
5561
|
+
city: string;
|
|
5562
|
+
country: string;
|
|
5563
|
+
region: string;
|
|
5564
|
+
loc: string;
|
|
5565
|
+
timezone: string;
|
|
5566
|
+
ip: string;
|
|
5567
|
+
postal: string;
|
|
5568
|
+
};
|
|
5569
|
+
dytePolls?: {
|
|
5570
|
+
hasQuestion?: boolean;
|
|
5571
|
+
optionsLength?: number;
|
|
5572
|
+
};
|
|
5573
|
+
dyteChat?: {
|
|
5574
|
+
imageType?: string;
|
|
5575
|
+
messageType?: string;
|
|
5576
|
+
};
|
|
5577
|
+
dyteParticipant?: {
|
|
5578
|
+
id: string;
|
|
5579
|
+
};
|
|
5580
|
+
actions?: {
|
|
5581
|
+
disableAllAudio?: {
|
|
5582
|
+
allowUnmute?: boolean;
|
|
5583
|
+
};
|
|
5584
|
+
trackRobustness?: {
|
|
5585
|
+
reacquireTrack?: boolean;
|
|
5586
|
+
eventType?: string;
|
|
5587
|
+
};
|
|
5588
|
+
};
|
|
5589
|
+
recording?: {
|
|
5590
|
+
id?: string;
|
|
5591
|
+
state?: RecordingState;
|
|
5592
|
+
};
|
|
5593
|
+
selectedPeer?: {
|
|
5594
|
+
oldIndex?: number;
|
|
5595
|
+
newIndex?: number;
|
|
5596
|
+
peerId?: string;
|
|
5478
5597
|
};
|
|
5479
|
-
|
|
5480
|
-
|
|
5481
|
-
|
|
5482
|
-
|
|
5483
|
-
|
|
5484
|
-
|
|
5485
|
-
|
|
5598
|
+
pageNavigation?: {
|
|
5599
|
+
viewMode: ViewMode;
|
|
5600
|
+
currentPage: number;
|
|
5601
|
+
pageCount: number;
|
|
5602
|
+
maxActiveParticipantsCount: number;
|
|
5603
|
+
settingPage?: number;
|
|
5604
|
+
};
|
|
5605
|
+
connectedMeetings?: {
|
|
5606
|
+
movement?: {
|
|
5607
|
+
sourceMeetingId?: string;
|
|
5608
|
+
destinationMeetingId?: string;
|
|
5609
|
+
totalParticipantsToMove?: number;
|
|
5610
|
+
};
|
|
5611
|
+
};
|
|
5612
|
+
webinar?: {
|
|
5613
|
+
stageStatus?: StageStatus;
|
|
5614
|
+
};
|
|
5615
|
+
livestream?: {
|
|
5616
|
+
stageStatus?: StageStatus;
|
|
5617
|
+
latency?: number;
|
|
5618
|
+
};
|
|
5619
|
+
moduleExists?: {
|
|
5620
|
+
self?: boolean;
|
|
5621
|
+
};
|
|
5622
|
+
performanceObserver?: {
|
|
5623
|
+
api: PerformanceEntry;
|
|
5624
|
+
};
|
|
5625
|
+
dyteLocker?: {
|
|
5626
|
+
methodName: string;
|
|
5627
|
+
lockName: string;
|
|
5628
|
+
};
|
|
5629
|
+
socket?: {
|
|
5630
|
+
retryAttempt: number;
|
|
5631
|
+
};
|
|
5632
|
+
connectionState?: {
|
|
5633
|
+
joinAttempted: boolean;
|
|
5634
|
+
};
|
|
5635
|
+
source?: string;
|
|
5636
|
+
eventListener?: {
|
|
5637
|
+
eventName: string;
|
|
5638
|
+
listenerCount: number;
|
|
5639
|
+
};
|
|
5640
|
+
dataChannelMessageChunk?: {
|
|
5486
5641
|
id: string;
|
|
5487
|
-
|
|
5488
|
-
|
|
5489
|
-
|
|
5490
|
-
|
|
5491
|
-
|
|
5492
|
-
|
|
5493
|
-
|
|
5494
|
-
|
|
5495
|
-
|
|
5496
|
-
|
|
5497
|
-
|
|
5498
|
-
|
|
5642
|
+
count: number;
|
|
5643
|
+
chunkIndex: number;
|
|
5644
|
+
chunk: string;
|
|
5645
|
+
transprtId: string;
|
|
5646
|
+
};
|
|
5647
|
+
peerIds?: string[];
|
|
5648
|
+
producers?: ProducerState[];
|
|
5649
|
+
sdp?: RTCSessionDescription['sdp'];
|
|
5650
|
+
awaitQueueTask?: {
|
|
5651
|
+
id?: string | number;
|
|
5652
|
+
metadata?: Record<string, unknown>;
|
|
5653
|
+
queueSizeAtStart?: number;
|
|
5654
|
+
taskStartTime?: number;
|
|
5655
|
+
execTime?: number;
|
|
5656
|
+
};
|
|
5657
|
+
};
|
|
5658
|
+
type EventSeverities = SupportedEventSeverities;
|
|
5659
|
+
type LogData$1 = LogData$2;
|
|
5660
|
+
interface MeetingMetadata {
|
|
5661
|
+
peerId?: string;
|
|
5662
|
+
roomName?: string;
|
|
5499
5663
|
organizationId?: string;
|
|
5664
|
+
sdkVersion?: string;
|
|
5665
|
+
deviceInfo?: object;
|
|
5666
|
+
visitedUrl?: string;
|
|
5667
|
+
userId?: string;
|
|
5500
5668
|
}
|
|
5501
|
-
declare class
|
|
5502
|
-
|
|
5503
|
-
|
|
5504
|
-
|
|
5505
|
-
|
|
5506
|
-
|
|
5507
|
-
|
|
5508
|
-
|
|
5509
|
-
|
|
5510
|
-
|
|
5511
|
-
|
|
5512
|
-
readonly
|
|
5513
|
-
|
|
5514
|
-
|
|
5515
|
-
|
|
5516
|
-
|
|
5517
|
-
static
|
|
5518
|
-
|
|
5519
|
-
|
|
5520
|
-
|
|
5521
|
-
|
|
5522
|
-
|
|
5523
|
-
setupTracks(options?: {
|
|
5524
|
-
video?: boolean;
|
|
5525
|
-
audio?: boolean;
|
|
5526
|
-
forceReset?: boolean;
|
|
5527
|
-
}): Promise<void>;
|
|
5528
|
-
destructMediaHandler(): Promise<void>;
|
|
5529
|
-
removeDocumentEventListeners(): Promise<void>;
|
|
5530
|
-
enableAudio(customTrack?: MediaStreamTrack): Promise<void>;
|
|
5531
|
-
enableVideo(customTrack?: MediaStreamTrack): Promise<void>;
|
|
5532
|
-
updateVideoConstraints(resolution: VideoQualityConstraints): Promise<void>;
|
|
5533
|
-
enableScreenShare(): Promise<void>;
|
|
5534
|
-
updateScreenshareConstraints(resolution: VideoQualityConstraints): Promise<void>;
|
|
5535
|
-
disableAudio(): Promise<void>;
|
|
5536
|
-
disableVideo(): Promise<void>;
|
|
5537
|
-
disableScreenShare(): Promise<void>;
|
|
5538
|
-
getAllDevices(): Promise<InputDeviceInfo[]>;
|
|
5539
|
-
setIsPinned(isPinned: boolean, emitEvent?: boolean): void;
|
|
5540
|
-
readonly isPinned: boolean;
|
|
5541
|
-
pin(): Promise<void>;
|
|
5542
|
-
unpin(): Promise<void>;
|
|
5543
|
-
hide(): Promise<void>;
|
|
5544
|
-
show(): void;
|
|
5545
|
-
setDevice(device: MediaDeviceInfo): Promise<void>;
|
|
5546
|
-
cleanUpTracks(): void;
|
|
5547
|
-
playAudio(): Promise<void>;
|
|
5548
|
-
registerVideoElement(videoElem: HTMLVideoElement, isPreview?: boolean): void;
|
|
5549
|
-
deregisterVideoElement(videoElem?: HTMLVideoElement, isPreview?: boolean): void;
|
|
5550
|
-
}
|
|
5551
|
-
interface RTKPluginResponse {
|
|
5552
|
-
baseURL: string;
|
|
5553
|
-
createdAt: string;
|
|
5554
|
-
description: string;
|
|
5555
|
-
id: string;
|
|
5556
|
-
name: string;
|
|
5557
|
-
organizationId: string;
|
|
5558
|
-
picture: string;
|
|
5559
|
-
private: boolean;
|
|
5560
|
-
published: boolean;
|
|
5561
|
-
staggered: boolean;
|
|
5562
|
-
tags: string[];
|
|
5563
|
-
type: string;
|
|
5564
|
-
updatedAt: string;
|
|
5565
|
-
}
|
|
5566
|
-
interface PluginViews {
|
|
5567
|
-
[viewId: string]: {
|
|
5568
|
-
url: string;
|
|
5569
|
-
suggestedPosition: string;
|
|
5570
|
-
};
|
|
5571
|
-
}
|
|
5572
|
-
interface PluginConfig {
|
|
5573
|
-
name: string;
|
|
5574
|
-
pluginId: string;
|
|
5575
|
-
version: string;
|
|
5576
|
-
description: string;
|
|
5577
|
-
author?: string;
|
|
5578
|
-
repository?: string;
|
|
5579
|
-
tags?: string[];
|
|
5580
|
-
picture?: string;
|
|
5581
|
-
url?: string;
|
|
5582
|
-
files: {
|
|
5583
|
-
include: string[];
|
|
5584
|
-
exclude?: string[];
|
|
5585
|
-
};
|
|
5586
|
-
views?: PluginViews;
|
|
5587
|
-
contentScript?: string;
|
|
5588
|
-
permissions?: {
|
|
5589
|
-
[key: string]: {
|
|
5590
|
-
default: boolean;
|
|
5591
|
-
description: string;
|
|
5592
|
-
};
|
|
5593
|
-
};
|
|
5594
|
-
config?: {
|
|
5595
|
-
[key: string]: string;
|
|
5596
|
-
};
|
|
5597
|
-
}
|
|
5598
|
-
interface PluginIframeMessage {
|
|
5599
|
-
type: number;
|
|
5600
|
-
uuid: string;
|
|
5601
|
-
payload?: any;
|
|
5602
|
-
}
|
|
5603
|
-
interface SendDataOptions {
|
|
5604
|
-
eventName: string;
|
|
5605
|
-
data: any;
|
|
5606
|
-
}
|
|
5607
|
-
interface ReactNativeWebViewEvent {
|
|
5608
|
-
nativeEvent: {
|
|
5609
|
-
data: string;
|
|
5610
|
-
};
|
|
5611
|
-
}
|
|
5612
|
-
interface ReactNativeWebView {
|
|
5613
|
-
src: string;
|
|
5614
|
-
allow: string;
|
|
5615
|
-
title: string;
|
|
5616
|
-
props: {
|
|
5617
|
-
onMessage: (event: ReactNativeWebViewEvent) => void;
|
|
5618
|
-
};
|
|
5619
|
-
postMessage: (message: string) => void;
|
|
5669
|
+
declare class RTKTelemetry {
|
|
5670
|
+
logsCache: {
|
|
5671
|
+
[key: string]: any;
|
|
5672
|
+
}[];
|
|
5673
|
+
logsProcessorTimer: NodeJS.Timer;
|
|
5674
|
+
static location: {
|
|
5675
|
+
country: string;
|
|
5676
|
+
};
|
|
5677
|
+
readonly logsEndpoint: string;
|
|
5678
|
+
tracingEnabled: boolean;
|
|
5679
|
+
initialized: boolean;
|
|
5680
|
+
readonly logsProcessingInterval = 7000;
|
|
5681
|
+
logExclusionList: string[];
|
|
5682
|
+
meetingMetadata: MeetingMetadata;
|
|
5683
|
+
resetPeerId(peerId: string): void;
|
|
5684
|
+
init(context: Context<RTKContextState>, options: MeetingMetadata, enableTracing: boolean): void;
|
|
5685
|
+
static trace(spanName: string, metadata?: LogData$1 | undefined): (_target: Object, _propertyKey: string, descriptor: PropertyDescriptor) => PropertyDescriptor;
|
|
5686
|
+
injectContext(injectionReceiver: any): void;
|
|
5687
|
+
addLogInCurrentSpan(eventSeverity: EventSeverities, eventName: string, metadata?: LogData$1, noCache?: boolean): void;
|
|
5688
|
+
sendOtelLogsToNewRelic(logs: object[]): void;
|
|
5689
|
+
processCachedLogs(): void;
|
|
5690
|
+
destruct(): void;
|
|
5620
5691
|
}
|
|
5621
|
-
|
|
5622
|
-
|
|
5623
|
-
|
|
5624
|
-
|
|
5625
|
-
|
|
5626
|
-
|
|
5627
|
-
|
|
5628
|
-
|
|
5629
|
-
|
|
5630
|
-
_?: any;
|
|
5631
|
-
};
|
|
5632
|
-
type PluginEvents = keyof typeof PluginEventKeys | _string;
|
|
5633
|
-
declare class RTKPlugin$1 extends RTKEventEmitter<PluginEvents> {
|
|
5634
|
-
readonly baseURL: string;
|
|
5635
|
-
readonly createdAt: Date;
|
|
5636
|
-
readonly description: string;
|
|
5637
|
-
readonly id: string;
|
|
5638
|
-
readonly name: string;
|
|
5639
|
-
readonly organizationId: string;
|
|
5640
|
-
readonly picture: string;
|
|
5641
|
-
readonly private: boolean;
|
|
5642
|
-
readonly published: boolean;
|
|
5643
|
-
readonly staggered: boolean;
|
|
5644
|
-
readonly tags: string[];
|
|
5645
|
-
readonly type: string;
|
|
5646
|
-
readonly updatedAt: Date;
|
|
5647
|
-
config?: PluginConfig;
|
|
5648
|
-
active: boolean;
|
|
5649
|
-
iframes: Map<string, {
|
|
5650
|
-
iframe: HTMLIFrameElement | ReactNativeWebView;
|
|
5651
|
-
listener?: (message: MessageEvent) => void;
|
|
5652
|
-
}>;
|
|
5653
|
-
enabledBy: string;
|
|
5654
|
-
constructor(context: Context<RTKContextState>, { baseURL, createdAt, description, id, name, organizationId, picture, private: isPrivate, published, staggered, tags, type, updatedAt, }: RTKPluginResponse, pluginSocketHandler: PluginSocketHandler, self: RTKSelf$1, participants: RTKParticipants$1, chat: Readonly<RTKChat$1>, meetingTitle: string);
|
|
5655
|
-
sendIframeEvent(message: PluginIframeMessage): void;
|
|
5656
|
-
sendData(payload: SendDataOptions): void;
|
|
5657
|
-
removePluginView(viewId?: string): void;
|
|
5658
|
-
addPluginView(iframe: HTMLIFrameElement | ReactNativeWebView, viewId?: string): void;
|
|
5659
|
-
activateForSelf(): Promise<void>;
|
|
5660
|
-
deactivateForSelf(): void;
|
|
5661
|
-
enable(): Promise<void>;
|
|
5662
|
-
disable(): void;
|
|
5663
|
-
activate(): Promise<void>;
|
|
5664
|
-
deactivate(): Promise<void>;
|
|
5692
|
+
type LogData = LogData$1;
|
|
5693
|
+
declare class RTKLogger$1 {
|
|
5694
|
+
readonly telemetry: RTKTelemetry;
|
|
5695
|
+
init(context: Context<RTKContextState>): void;
|
|
5696
|
+
info(humanReadableLogIdentifier: string, logData?: LogData, isCrucial?: boolean): void;
|
|
5697
|
+
error(humanReadableLogIdentifier: string, logData?: LogData, isCrucial?: boolean): void;
|
|
5698
|
+
debug(humanReadableLogIdentifier: string, logData?: LogData, isCrucial?: boolean): void;
|
|
5699
|
+
log(humanReadableLogIdentifier: string, logData?: LogData, isCrucial?: boolean): void;
|
|
5700
|
+
warn(humanReadableLogIdentifier: string, logData?: LogData, isCrucial?: boolean): void;
|
|
5665
5701
|
}
|
|
5666
5702
|
interface IceServerInformation {
|
|
5667
5703
|
url: string;
|
|
@@ -5688,6 +5724,7 @@ declare class API {
|
|
|
5688
5724
|
ipInfo: any;
|
|
5689
5725
|
readonly peerId: string;
|
|
5690
5726
|
context: Context<RTKContextState>;
|
|
5727
|
+
readonly logger: RTKLogger$1;
|
|
5691
5728
|
constructor(context: Context<RTKContextState>, options?: APIOptions);
|
|
5692
5729
|
setAuthToken(token: string, options?: {
|
|
5693
5730
|
bearer?: boolean;
|
|
@@ -5713,6 +5750,12 @@ interface RealtimeKitClientOptions {
|
|
|
5713
5750
|
}
|
|
5714
5751
|
declare class RealtimeKitClient {
|
|
5715
5752
|
private constructor();
|
|
5753
|
+
readonly peerId: string;
|
|
5754
|
+
static initMedia(options?: {
|
|
5755
|
+
video?: boolean;
|
|
5756
|
+
audio?: boolean;
|
|
5757
|
+
constraints?: MediaConstraints;
|
|
5758
|
+
}, skipAwaits?: boolean, cachedUserDetails?: CachedUserDetails): RTKSelfMedia$1;
|
|
5716
5759
|
static init(options: RealtimeKitClientOptions): Promise<RealtimeKitClient>;
|
|
5717
5760
|
join(): Promise<void>;
|
|
5718
5761
|
leave(state?: LeaveRoomState): Promise<void>;
|
|
@@ -5744,6 +5787,7 @@ type RTKPlugins = Readonly<RTKPlugins$1>;
|
|
|
5744
5787
|
type RTKPluginMap = Readonly<RTKPluginMap$1>;
|
|
5745
5788
|
type RTKMeta = Readonly<RTKMeta$1>;
|
|
5746
5789
|
type RTKSelf = Readonly<RTKSelf$1>;
|
|
5790
|
+
type RTKSelfMedia = Readonly<RTKSelfMedia$1>;
|
|
5747
5791
|
type RTKChat = Readonly<RTKChat$1>;
|
|
5748
5792
|
type RTKPolls = Readonly<RTKPolls$1>;
|
|
5749
5793
|
type RTKRecording = Readonly<RTKRecording$1>;
|
|
@@ -5752,6 +5796,7 @@ type RTKStore = RTKStore$1;
|
|
|
5752
5796
|
type RTKConnectedMeetings = Readonly<RTKConnectedMeetings$1>;
|
|
5753
5797
|
type RTKPermissionsPreset = Readonly<RTKPermissionsPreset$1>;
|
|
5754
5798
|
type RTKThemePreset = Readonly<RTKThemePreset$1>;
|
|
5799
|
+
type RTKLogger = RTKLogger$1;
|
|
5755
5800
|
type RTKType = {
|
|
5756
5801
|
callStats?: unknown;
|
|
5757
5802
|
RTKTelemetry?: typeof RTKTelemetry;
|
|
@@ -5769,4 +5814,4 @@ declare global {
|
|
|
5769
5814
|
TransformStream?: any;
|
|
5770
5815
|
}
|
|
5771
5816
|
}
|
|
5772
|
-
export { ActiveTab, ActiveTabType, AudioConsumerScoreStats, AudioMiddleware, AudioProducerScoreStats, BroadcastMessagePayload, ChatChannel, ChatUpdateParams, CustomMessage, DeviceConfig, RTKBasicParticipant, RTKChat, RealtimeKitClientOptions, RTKConnectedMeetings, RTKLivestream, RTKMeta, RTKParticipant, RTKParticipantMap, RTKParticipants, RTKPermissionsPreset, RTKPlugin, RTKPluginMap, RTKPlugins, RTKPolls, RTKRecording, RTKSelf, RTKStore, RTKThemePreset, FileMessage, ImageMessage, JoinedPeer, LeaveRoomState, LivestreamIngestionCredentials, LivestreamState, LogData, MediaConnectionState, MediaConnectionUpdate, MediaKind$1 as MediaKind, MediaPermission, Message, ProducerScoreStats,
|
|
5817
|
+
export { ActiveTab, ActiveTabType, AudioConsumerScoreStats, AudioMiddleware, AudioProducerScoreStats, BroadcastMessagePayload, ChatChannel, ChatUpdateParams, CustomMessage, DeviceConfig, RTKBasicParticipant, RTKChat, RealtimeKitClientOptions, RTKConnectedMeetings, RTKLivestream, RTKMeta, RTKParticipant, RTKParticipantMap, RTKParticipants, RTKPermissionsPreset, RTKPlugin, RTKPluginMap, RTKPlugins, RTKPolls, RTKRecording, RTKSelf, RTKSelfMedia, RTKStore, RTKThemePreset, FileMessage, ImageMessage, JoinedPeer, LeaveRoomState, LivestreamIngestionCredentials, LivestreamState, LogData, MediaConnectionState, MediaConnectionUpdate, MediaKind$1 as MediaKind, MediaPermission, Message, ProducerScoreStats, RecordingState, RequestToJoinType, SocketConnectionState, StageStatus, StartLivestreamConfig, TextMessage, VideoConsumerScoreStats, VideoMiddleware, VideoProducerScoreStats, VideoQualityConstraints, RealtimeKitClient as default, LeaveRoomState as leaveRoomState };
|