@fishjam-cloud/js-server-sdk 0.23.0 → 0.24.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.d.mts CHANGED
@@ -1,6 +1,44 @@
1
1
  import { BinaryWriter, BinaryReader } from '@bufbuild/protobuf/wire';
2
2
  import axios from 'axios';
3
3
 
4
+ /**
5
+ * Output audio options
6
+ * @export
7
+ * @interface AgentOutput
8
+ */
9
+ interface AgentOutput {
10
+ /**
11
+ *
12
+ * @type {AudioFormat}
13
+ * @memberof AgentOutput
14
+ */
15
+ 'audioFormat'?: AudioFormat;
16
+ /**
17
+ *
18
+ * @type {AudioSampleRate}
19
+ * @memberof AgentOutput
20
+ */
21
+ 'audioSampleRate'?: AudioSampleRate;
22
+ }
23
+ /**
24
+ * The format of the output audio
25
+ * @export
26
+ * @enum {string}
27
+ */
28
+ declare const AudioFormat: {
29
+ readonly Pcm16: "pcm16";
30
+ };
31
+ type AudioFormat = typeof AudioFormat[keyof typeof AudioFormat];
32
+ /**
33
+ * The sample rate of the output audio
34
+ * @export
35
+ * @enum {string}
36
+ */
37
+ declare const AudioSampleRate: {
38
+ readonly NUMBER_16000: 16000;
39
+ readonly NUMBER_24000: 24000;
40
+ };
41
+ type AudioSampleRate = typeof AudioSampleRate[keyof typeof AudioSampleRate];
4
42
  /**
5
43
  * Describes peer status
6
44
  * @export
@@ -32,11 +70,11 @@ interface Peer$1 {
32
70
  */
33
71
  'subscribeMode': SubscribeMode;
34
72
  /**
35
- * Describes peer\'s subscriptions in manual mode
36
- * @type {Array<string>}
73
+ *
74
+ * @type {Subscriptions}
37
75
  * @memberof Peer
38
76
  */
39
- 'subscriptions': Array<string>;
77
+ 'subscriptions': Subscriptions;
40
78
  /**
41
79
  * List of all peer\'s tracks
42
80
  * @type {Array<Track>}
@@ -64,62 +102,23 @@ type PeerOptions = PeerOptionsAgent | PeerOptionsWebRTC;
64
102
  interface PeerOptionsAgent {
65
103
  /**
66
104
  *
67
- * @type {PeerOptionsAgentOutput}
105
+ * @type {AgentOutput}
68
106
  * @memberof PeerOptionsAgent
69
107
  */
70
- 'output'?: PeerOptionsAgentOutput;
108
+ 'output'?: AgentOutput;
71
109
  /**
72
- * Configuration of peer\'s subscribing policy
73
- * @type {string}
110
+ *
111
+ * @type {SubscribeMode}
74
112
  * @memberof PeerOptionsAgent
75
113
  */
76
- 'subscribeMode'?: PeerOptionsAgentSubscribeModeEnum;
114
+ 'subscribeMode'?: SubscribeMode;
77
115
  }
78
- declare const PeerOptionsAgentSubscribeModeEnum: {
79
- readonly Auto: "auto";
80
- readonly Manual: "manual";
81
- };
82
- type PeerOptionsAgentSubscribeModeEnum = typeof PeerOptionsAgentSubscribeModeEnum[keyof typeof PeerOptionsAgentSubscribeModeEnum];
83
- /**
84
- * Output audio options
85
- * @export
86
- * @interface PeerOptionsAgentOutput
87
- */
88
- interface PeerOptionsAgentOutput {
89
- /**
90
- * The format of the output audio
91
- * @type {string}
92
- * @memberof PeerOptionsAgentOutput
93
- */
94
- 'audioFormat'?: PeerOptionsAgentOutputAudioFormatEnum;
95
- /**
96
- * The sample rate of the output audio
97
- * @type {number}
98
- * @memberof PeerOptionsAgentOutput
99
- */
100
- 'audioSampleRate'?: PeerOptionsAgentOutputAudioSampleRateEnum;
101
- }
102
- declare const PeerOptionsAgentOutputAudioFormatEnum: {
103
- readonly Pcm16: "pcm16";
104
- };
105
- type PeerOptionsAgentOutputAudioFormatEnum = typeof PeerOptionsAgentOutputAudioFormatEnum[keyof typeof PeerOptionsAgentOutputAudioFormatEnum];
106
- declare const PeerOptionsAgentOutputAudioSampleRateEnum: {
107
- readonly NUMBER_16000: 16000;
108
- readonly NUMBER_24000: 24000;
109
- };
110
- type PeerOptionsAgentOutputAudioSampleRateEnum = typeof PeerOptionsAgentOutputAudioSampleRateEnum[keyof typeof PeerOptionsAgentOutputAudioSampleRateEnum];
111
116
  /**
112
117
  * Options specific to the WebRTC peer
113
118
  * @export
114
119
  * @interface PeerOptionsWebRTC
115
120
  */
116
121
  interface PeerOptionsWebRTC {
117
- /**
118
- * Enables the peer to use simulcast
119
- * @type {boolean}
120
- * @memberof PeerOptionsWebRTC
121
- */
122
- 'enableSimulcast'?: boolean;
123
122
  /**
124
123
  * Custom peer metadata
125
124
  * @type {{ [key: string]: any; }}
@@ -129,17 +128,12 @@ interface PeerOptionsWebRTC {
129
128
  [key: string]: any;
130
129
  };
131
130
  /**
132
- * Configuration of peer\'s subscribing policy
133
- * @type {string}
131
+ *
132
+ * @type {SubscribeMode}
134
133
  * @memberof PeerOptionsWebRTC
135
134
  */
136
- 'subscribeMode'?: PeerOptionsWebRTCSubscribeModeEnum;
135
+ 'subscribeMode'?: SubscribeMode;
137
136
  }
138
- declare const PeerOptionsWebRTCSubscribeModeEnum: {
139
- readonly Auto: "auto";
140
- readonly Manual: "manual";
141
- };
142
- type PeerOptionsWebRTCSubscribeModeEnum = typeof PeerOptionsWebRTCSubscribeModeEnum[keyof typeof PeerOptionsWebRTCSubscribeModeEnum];
143
137
  /**
144
138
  * Informs about the peer status
145
139
  * @export
@@ -179,17 +173,17 @@ interface RoomConfig {
179
173
  */
180
174
  'public'?: boolean;
181
175
  /**
182
- * The use-case of the room. If not provided, this defaults to conference.
183
- * @type {string}
176
+ *
177
+ * @type {RoomType}
184
178
  * @memberof RoomConfig
185
179
  */
186
- 'roomType'?: RoomConfigRoomTypeEnum;
180
+ 'roomType'?: RoomType;
187
181
  /**
188
- * Enforces video codec for each peer in the room
189
- * @type {string}
182
+ *
183
+ * @type {VideoCodec}
190
184
  * @memberof RoomConfig
191
185
  */
192
- 'videoCodec'?: RoomConfigVideoCodecEnum;
186
+ 'videoCodec'?: VideoCodec;
193
187
  /**
194
188
  * URL where Fishjam notifications will be sent
195
189
  * @type {string}
@@ -197,7 +191,12 @@ interface RoomConfig {
197
191
  */
198
192
  'webhookUrl'?: string | null;
199
193
  }
200
- declare const RoomConfigRoomTypeEnum: {
194
+ /**
195
+ * The use-case of the room. If not provided, this defaults to conference.
196
+ * @export
197
+ * @enum {string}
198
+ */
199
+ declare const RoomType: {
201
200
  readonly FullFeature: "full_feature";
202
201
  readonly AudioOnly: "audio_only";
203
202
  readonly Broadcaster: "broadcaster";
@@ -205,12 +204,7 @@ declare const RoomConfigRoomTypeEnum: {
205
204
  readonly Conference: "conference";
206
205
  readonly AudioOnlyLivestream: "audio_only_livestream";
207
206
  };
208
- type RoomConfigRoomTypeEnum = typeof RoomConfigRoomTypeEnum[keyof typeof RoomConfigRoomTypeEnum];
209
- declare const RoomConfigVideoCodecEnum: {
210
- readonly H264: "h264";
211
- readonly Vp8: "vp8";
212
- };
213
- type RoomConfigVideoCodecEnum = typeof RoomConfigVideoCodecEnum[keyof typeof RoomConfigVideoCodecEnum];
207
+ type RoomType = typeof RoomType[keyof typeof RoomType];
214
208
  /**
215
209
  * Token for authorizing broadcaster streamer connection
216
210
  * @export
@@ -234,6 +228,25 @@ declare const SubscribeMode: {
234
228
  readonly Manual: "manual";
235
229
  };
236
230
  type SubscribeMode = typeof SubscribeMode[keyof typeof SubscribeMode];
231
+ /**
232
+ * Describes peer\'s subscriptions in manual mode
233
+ * @export
234
+ * @interface Subscriptions
235
+ */
236
+ interface Subscriptions {
237
+ /**
238
+ * List of peer IDs this peer subscribes to
239
+ * @type {Array<string>}
240
+ * @memberof Subscriptions
241
+ */
242
+ 'peers': Array<string>;
243
+ /**
244
+ * List of track IDs this peer subscribes to
245
+ * @type {Array<string>}
246
+ * @memberof Subscriptions
247
+ */
248
+ 'tracks': Array<string>;
249
+ }
237
250
  /**
238
251
  * Describes media track of a Peer
239
252
  * @export
@@ -254,16 +267,31 @@ interface Track$1 {
254
267
  'metadata'?: object | null;
255
268
  /**
256
269
  *
257
- * @type {string}
270
+ * @type {TrackType}
258
271
  * @memberof Track
259
272
  */
260
- 'type'?: TrackTypeEnum;
273
+ 'type'?: TrackType$2;
261
274
  }
262
- declare const TrackTypeEnum: {
275
+ /**
276
+ *
277
+ * @export
278
+ * @enum {string}
279
+ */
280
+ declare const TrackType$2: {
263
281
  readonly Audio: "audio";
264
282
  readonly Video: "video";
265
283
  };
266
- type TrackTypeEnum = typeof TrackTypeEnum[keyof typeof TrackTypeEnum];
284
+ type TrackType$2 = typeof TrackType$2[keyof typeof TrackType$2];
285
+ /**
286
+ * Enforces video codec for each peer in the room
287
+ * @export
288
+ * @enum {string}
289
+ */
290
+ declare const VideoCodec: {
291
+ readonly H264: "h264";
292
+ readonly Vp8: "vp8";
293
+ };
294
+ type VideoCodec = typeof VideoCodec[keyof typeof VideoCodec];
267
295
  /**
268
296
  * Token for authorizing broadcaster viewer connection
269
297
  * @export
@@ -750,7 +778,7 @@ declare class FishjamAgent extends FishjamAgent_base {
750
778
  */
751
779
  createTrack(codecParameters: AudioCodecParameters, metadata?: object): AgentTrack;
752
780
  /**
753
- * Interrupt track indentified by `trackId`.
781
+ * Interrupt track identified by `trackId`.
754
782
  *
755
783
  * Any audio that has been sent by the agent, but not played
756
784
  * by Fishjam will be cleared and be prevented from playing.
@@ -882,4 +910,4 @@ declare class ServiceUnavailableException extends FishjamBaseException {
882
910
  declare class UnknownException extends FishjamBaseException {
883
911
  }
884
912
 
885
- export { type AgentCallbacks, type AgentEvents, type AgentTrack, type AudioCodecParameters, BadRequestException, type Brand, type CloseEventHandler, type ErrorEventHandler, type ExpectedAgentEvents, type ExpectedEvents, FishjamAgent, FishjamBaseException, FishjamClient, type FishjamConfig, FishjamNotFoundException, FishjamWSNotifier, ForbiddenException, type IncomingTrackData, MissingFishjamIdException, type NotificationEvents, type OutgoingTrackData, type Peer, type PeerAdded, type PeerConnected, type PeerCrashed, type PeerDeleted, type PeerDisconnected, type PeerId, type PeerMetadataUpdated, PeerNotFoundException, type PeerOptions, type PeerOptionsAgent, type PeerOptionsWebRTC, PeerStatus, type Room, type RoomConfig, RoomConfigRoomTypeEnum, RoomConfigVideoCodecEnum, type RoomCrashed, type RoomCreated, type RoomDeleted, type RoomId, RoomNotFoundException, ServerMessage, ServiceUnavailableException, type StreamConnected, type StreamDisconnected, type StreamerToken, type TrackAdded, type TrackId, type TrackMetadataUpdated, type TrackRemoved, type TrackType, UnauthorizedException, UnknownException, type ViewerConnected, type ViewerDisconnected, type ViewerToken };
913
+ export { type AgentCallbacks, type AgentEvents, type AgentTrack, type AudioCodecParameters, BadRequestException, type Brand, type CloseEventHandler, type ErrorEventHandler, type ExpectedAgentEvents, type ExpectedEvents, FishjamAgent, FishjamBaseException, FishjamClient, type FishjamConfig, FishjamNotFoundException, FishjamWSNotifier, ForbiddenException, type IncomingTrackData, MissingFishjamIdException, type NotificationEvents, type OutgoingTrackData, type Peer, type PeerAdded, type PeerConnected, type PeerCrashed, type PeerDeleted, type PeerDisconnected, type PeerId, type PeerMetadataUpdated, PeerNotFoundException, type PeerOptions, type PeerOptionsAgent, type PeerOptionsWebRTC, PeerStatus, type Room, type RoomConfig, type RoomCrashed, type RoomCreated, type RoomDeleted, type RoomId, RoomNotFoundException, RoomType, ServerMessage, ServiceUnavailableException, type StreamConnected, type StreamDisconnected, type StreamerToken, type TrackAdded, type TrackId, type TrackMetadataUpdated, type TrackRemoved, type TrackType, UnauthorizedException, UnknownException, VideoCodec, type ViewerConnected, type ViewerDisconnected, type ViewerToken };
package/dist/index.d.ts CHANGED
@@ -1,6 +1,44 @@
1
1
  import { BinaryWriter, BinaryReader } from '@bufbuild/protobuf/wire';
2
2
  import axios from 'axios';
3
3
 
4
+ /**
5
+ * Output audio options
6
+ * @export
7
+ * @interface AgentOutput
8
+ */
9
+ interface AgentOutput {
10
+ /**
11
+ *
12
+ * @type {AudioFormat}
13
+ * @memberof AgentOutput
14
+ */
15
+ 'audioFormat'?: AudioFormat;
16
+ /**
17
+ *
18
+ * @type {AudioSampleRate}
19
+ * @memberof AgentOutput
20
+ */
21
+ 'audioSampleRate'?: AudioSampleRate;
22
+ }
23
+ /**
24
+ * The format of the output audio
25
+ * @export
26
+ * @enum {string}
27
+ */
28
+ declare const AudioFormat: {
29
+ readonly Pcm16: "pcm16";
30
+ };
31
+ type AudioFormat = typeof AudioFormat[keyof typeof AudioFormat];
32
+ /**
33
+ * The sample rate of the output audio
34
+ * @export
35
+ * @enum {string}
36
+ */
37
+ declare const AudioSampleRate: {
38
+ readonly NUMBER_16000: 16000;
39
+ readonly NUMBER_24000: 24000;
40
+ };
41
+ type AudioSampleRate = typeof AudioSampleRate[keyof typeof AudioSampleRate];
4
42
  /**
5
43
  * Describes peer status
6
44
  * @export
@@ -32,11 +70,11 @@ interface Peer$1 {
32
70
  */
33
71
  'subscribeMode': SubscribeMode;
34
72
  /**
35
- * Describes peer\'s subscriptions in manual mode
36
- * @type {Array<string>}
73
+ *
74
+ * @type {Subscriptions}
37
75
  * @memberof Peer
38
76
  */
39
- 'subscriptions': Array<string>;
77
+ 'subscriptions': Subscriptions;
40
78
  /**
41
79
  * List of all peer\'s tracks
42
80
  * @type {Array<Track>}
@@ -64,62 +102,23 @@ type PeerOptions = PeerOptionsAgent | PeerOptionsWebRTC;
64
102
  interface PeerOptionsAgent {
65
103
  /**
66
104
  *
67
- * @type {PeerOptionsAgentOutput}
105
+ * @type {AgentOutput}
68
106
  * @memberof PeerOptionsAgent
69
107
  */
70
- 'output'?: PeerOptionsAgentOutput;
108
+ 'output'?: AgentOutput;
71
109
  /**
72
- * Configuration of peer\'s subscribing policy
73
- * @type {string}
110
+ *
111
+ * @type {SubscribeMode}
74
112
  * @memberof PeerOptionsAgent
75
113
  */
76
- 'subscribeMode'?: PeerOptionsAgentSubscribeModeEnum;
114
+ 'subscribeMode'?: SubscribeMode;
77
115
  }
78
- declare const PeerOptionsAgentSubscribeModeEnum: {
79
- readonly Auto: "auto";
80
- readonly Manual: "manual";
81
- };
82
- type PeerOptionsAgentSubscribeModeEnum = typeof PeerOptionsAgentSubscribeModeEnum[keyof typeof PeerOptionsAgentSubscribeModeEnum];
83
- /**
84
- * Output audio options
85
- * @export
86
- * @interface PeerOptionsAgentOutput
87
- */
88
- interface PeerOptionsAgentOutput {
89
- /**
90
- * The format of the output audio
91
- * @type {string}
92
- * @memberof PeerOptionsAgentOutput
93
- */
94
- 'audioFormat'?: PeerOptionsAgentOutputAudioFormatEnum;
95
- /**
96
- * The sample rate of the output audio
97
- * @type {number}
98
- * @memberof PeerOptionsAgentOutput
99
- */
100
- 'audioSampleRate'?: PeerOptionsAgentOutputAudioSampleRateEnum;
101
- }
102
- declare const PeerOptionsAgentOutputAudioFormatEnum: {
103
- readonly Pcm16: "pcm16";
104
- };
105
- type PeerOptionsAgentOutputAudioFormatEnum = typeof PeerOptionsAgentOutputAudioFormatEnum[keyof typeof PeerOptionsAgentOutputAudioFormatEnum];
106
- declare const PeerOptionsAgentOutputAudioSampleRateEnum: {
107
- readonly NUMBER_16000: 16000;
108
- readonly NUMBER_24000: 24000;
109
- };
110
- type PeerOptionsAgentOutputAudioSampleRateEnum = typeof PeerOptionsAgentOutputAudioSampleRateEnum[keyof typeof PeerOptionsAgentOutputAudioSampleRateEnum];
111
116
  /**
112
117
  * Options specific to the WebRTC peer
113
118
  * @export
114
119
  * @interface PeerOptionsWebRTC
115
120
  */
116
121
  interface PeerOptionsWebRTC {
117
- /**
118
- * Enables the peer to use simulcast
119
- * @type {boolean}
120
- * @memberof PeerOptionsWebRTC
121
- */
122
- 'enableSimulcast'?: boolean;
123
122
  /**
124
123
  * Custom peer metadata
125
124
  * @type {{ [key: string]: any; }}
@@ -129,17 +128,12 @@ interface PeerOptionsWebRTC {
129
128
  [key: string]: any;
130
129
  };
131
130
  /**
132
- * Configuration of peer\'s subscribing policy
133
- * @type {string}
131
+ *
132
+ * @type {SubscribeMode}
134
133
  * @memberof PeerOptionsWebRTC
135
134
  */
136
- 'subscribeMode'?: PeerOptionsWebRTCSubscribeModeEnum;
135
+ 'subscribeMode'?: SubscribeMode;
137
136
  }
138
- declare const PeerOptionsWebRTCSubscribeModeEnum: {
139
- readonly Auto: "auto";
140
- readonly Manual: "manual";
141
- };
142
- type PeerOptionsWebRTCSubscribeModeEnum = typeof PeerOptionsWebRTCSubscribeModeEnum[keyof typeof PeerOptionsWebRTCSubscribeModeEnum];
143
137
  /**
144
138
  * Informs about the peer status
145
139
  * @export
@@ -179,17 +173,17 @@ interface RoomConfig {
179
173
  */
180
174
  'public'?: boolean;
181
175
  /**
182
- * The use-case of the room. If not provided, this defaults to conference.
183
- * @type {string}
176
+ *
177
+ * @type {RoomType}
184
178
  * @memberof RoomConfig
185
179
  */
186
- 'roomType'?: RoomConfigRoomTypeEnum;
180
+ 'roomType'?: RoomType;
187
181
  /**
188
- * Enforces video codec for each peer in the room
189
- * @type {string}
182
+ *
183
+ * @type {VideoCodec}
190
184
  * @memberof RoomConfig
191
185
  */
192
- 'videoCodec'?: RoomConfigVideoCodecEnum;
186
+ 'videoCodec'?: VideoCodec;
193
187
  /**
194
188
  * URL where Fishjam notifications will be sent
195
189
  * @type {string}
@@ -197,7 +191,12 @@ interface RoomConfig {
197
191
  */
198
192
  'webhookUrl'?: string | null;
199
193
  }
200
- declare const RoomConfigRoomTypeEnum: {
194
+ /**
195
+ * The use-case of the room. If not provided, this defaults to conference.
196
+ * @export
197
+ * @enum {string}
198
+ */
199
+ declare const RoomType: {
201
200
  readonly FullFeature: "full_feature";
202
201
  readonly AudioOnly: "audio_only";
203
202
  readonly Broadcaster: "broadcaster";
@@ -205,12 +204,7 @@ declare const RoomConfigRoomTypeEnum: {
205
204
  readonly Conference: "conference";
206
205
  readonly AudioOnlyLivestream: "audio_only_livestream";
207
206
  };
208
- type RoomConfigRoomTypeEnum = typeof RoomConfigRoomTypeEnum[keyof typeof RoomConfigRoomTypeEnum];
209
- declare const RoomConfigVideoCodecEnum: {
210
- readonly H264: "h264";
211
- readonly Vp8: "vp8";
212
- };
213
- type RoomConfigVideoCodecEnum = typeof RoomConfigVideoCodecEnum[keyof typeof RoomConfigVideoCodecEnum];
207
+ type RoomType = typeof RoomType[keyof typeof RoomType];
214
208
  /**
215
209
  * Token for authorizing broadcaster streamer connection
216
210
  * @export
@@ -234,6 +228,25 @@ declare const SubscribeMode: {
234
228
  readonly Manual: "manual";
235
229
  };
236
230
  type SubscribeMode = typeof SubscribeMode[keyof typeof SubscribeMode];
231
+ /**
232
+ * Describes peer\'s subscriptions in manual mode
233
+ * @export
234
+ * @interface Subscriptions
235
+ */
236
+ interface Subscriptions {
237
+ /**
238
+ * List of peer IDs this peer subscribes to
239
+ * @type {Array<string>}
240
+ * @memberof Subscriptions
241
+ */
242
+ 'peers': Array<string>;
243
+ /**
244
+ * List of track IDs this peer subscribes to
245
+ * @type {Array<string>}
246
+ * @memberof Subscriptions
247
+ */
248
+ 'tracks': Array<string>;
249
+ }
237
250
  /**
238
251
  * Describes media track of a Peer
239
252
  * @export
@@ -254,16 +267,31 @@ interface Track$1 {
254
267
  'metadata'?: object | null;
255
268
  /**
256
269
  *
257
- * @type {string}
270
+ * @type {TrackType}
258
271
  * @memberof Track
259
272
  */
260
- 'type'?: TrackTypeEnum;
273
+ 'type'?: TrackType$2;
261
274
  }
262
- declare const TrackTypeEnum: {
275
+ /**
276
+ *
277
+ * @export
278
+ * @enum {string}
279
+ */
280
+ declare const TrackType$2: {
263
281
  readonly Audio: "audio";
264
282
  readonly Video: "video";
265
283
  };
266
- type TrackTypeEnum = typeof TrackTypeEnum[keyof typeof TrackTypeEnum];
284
+ type TrackType$2 = typeof TrackType$2[keyof typeof TrackType$2];
285
+ /**
286
+ * Enforces video codec for each peer in the room
287
+ * @export
288
+ * @enum {string}
289
+ */
290
+ declare const VideoCodec: {
291
+ readonly H264: "h264";
292
+ readonly Vp8: "vp8";
293
+ };
294
+ type VideoCodec = typeof VideoCodec[keyof typeof VideoCodec];
267
295
  /**
268
296
  * Token for authorizing broadcaster viewer connection
269
297
  * @export
@@ -750,7 +778,7 @@ declare class FishjamAgent extends FishjamAgent_base {
750
778
  */
751
779
  createTrack(codecParameters: AudioCodecParameters, metadata?: object): AgentTrack;
752
780
  /**
753
- * Interrupt track indentified by `trackId`.
781
+ * Interrupt track identified by `trackId`.
754
782
  *
755
783
  * Any audio that has been sent by the agent, but not played
756
784
  * by Fishjam will be cleared and be prevented from playing.
@@ -882,4 +910,4 @@ declare class ServiceUnavailableException extends FishjamBaseException {
882
910
  declare class UnknownException extends FishjamBaseException {
883
911
  }
884
912
 
885
- export { type AgentCallbacks, type AgentEvents, type AgentTrack, type AudioCodecParameters, BadRequestException, type Brand, type CloseEventHandler, type ErrorEventHandler, type ExpectedAgentEvents, type ExpectedEvents, FishjamAgent, FishjamBaseException, FishjamClient, type FishjamConfig, FishjamNotFoundException, FishjamWSNotifier, ForbiddenException, type IncomingTrackData, MissingFishjamIdException, type NotificationEvents, type OutgoingTrackData, type Peer, type PeerAdded, type PeerConnected, type PeerCrashed, type PeerDeleted, type PeerDisconnected, type PeerId, type PeerMetadataUpdated, PeerNotFoundException, type PeerOptions, type PeerOptionsAgent, type PeerOptionsWebRTC, PeerStatus, type Room, type RoomConfig, RoomConfigRoomTypeEnum, RoomConfigVideoCodecEnum, type RoomCrashed, type RoomCreated, type RoomDeleted, type RoomId, RoomNotFoundException, ServerMessage, ServiceUnavailableException, type StreamConnected, type StreamDisconnected, type StreamerToken, type TrackAdded, type TrackId, type TrackMetadataUpdated, type TrackRemoved, type TrackType, UnauthorizedException, UnknownException, type ViewerConnected, type ViewerDisconnected, type ViewerToken };
913
+ export { type AgentCallbacks, type AgentEvents, type AgentTrack, type AudioCodecParameters, BadRequestException, type Brand, type CloseEventHandler, type ErrorEventHandler, type ExpectedAgentEvents, type ExpectedEvents, FishjamAgent, FishjamBaseException, FishjamClient, type FishjamConfig, FishjamNotFoundException, FishjamWSNotifier, ForbiddenException, type IncomingTrackData, MissingFishjamIdException, type NotificationEvents, type OutgoingTrackData, type Peer, type PeerAdded, type PeerConnected, type PeerCrashed, type PeerDeleted, type PeerDisconnected, type PeerId, type PeerMetadataUpdated, PeerNotFoundException, type PeerOptions, type PeerOptionsAgent, type PeerOptionsWebRTC, PeerStatus, type Room, type RoomConfig, type RoomCrashed, type RoomCreated, type RoomDeleted, type RoomId, RoomNotFoundException, RoomType, ServerMessage, ServiceUnavailableException, type StreamConnected, type StreamDisconnected, type StreamerToken, type TrackAdded, type TrackId, type TrackMetadataUpdated, type TrackRemoved, type TrackType, UnauthorizedException, UnknownException, VideoCodec, type ViewerConnected, type ViewerDisconnected, type ViewerToken };
package/dist/index.js CHANGED
@@ -10787,19 +10787,16 @@ var require_dist = __commonJS({
10787
10787
  });
10788
10788
  var index_exports2 = {};
10789
10789
  __export2(index_exports2, {
10790
+ AudioFormat: () => AudioFormat,
10791
+ AudioSampleRate: () => AudioSampleRate,
10790
10792
  Configuration: () => Configuration,
10791
- PeerOptionsAgentOutputAudioFormatEnum: () => PeerOptionsAgentOutputAudioFormatEnum,
10792
- PeerOptionsAgentOutputAudioSampleRateEnum: () => PeerOptionsAgentOutputAudioSampleRateEnum,
10793
- PeerOptionsAgentSubscribeModeEnum: () => PeerOptionsAgentSubscribeModeEnum,
10794
- PeerOptionsWebRTCSubscribeModeEnum: () => PeerOptionsWebRTCSubscribeModeEnum,
10795
10793
  PeerStatus: () => PeerStatus2,
10796
10794
  PeerType: () => PeerType,
10797
10795
  RoomApi: () => RoomApi2,
10798
10796
  RoomApiAxiosParamCreator: () => RoomApiAxiosParamCreator,
10799
10797
  RoomApiFactory: () => RoomApiFactory,
10800
10798
  RoomApiFp: () => RoomApiFp,
10801
- RoomConfigRoomTypeEnum: () => RoomConfigRoomTypeEnum2,
10802
- RoomConfigVideoCodecEnum: () => RoomConfigVideoCodecEnum2,
10799
+ RoomType: () => RoomType2,
10803
10800
  StreamApi: () => StreamApi,
10804
10801
  StreamApiAxiosParamCreator: () => StreamApiAxiosParamCreator,
10805
10802
  StreamApiFactory: () => StreamApiFactory,
@@ -10810,7 +10807,8 @@ var require_dist = __commonJS({
10810
10807
  StreamerApiFp: () => StreamerApiFp,
10811
10808
  StreamerStatusEnum: () => StreamerStatusEnum,
10812
10809
  SubscribeMode: () => SubscribeMode,
10813
- TrackTypeEnum: () => TrackTypeEnum,
10810
+ TrackType: () => TrackType,
10811
+ VideoCodec: () => VideoCodec2,
10814
10812
  ViewerApi: () => ViewerApi2,
10815
10813
  ViewerApiAxiosParamCreator: () => ViewerApiAxiosParamCreator,
10816
10814
  ViewerApiFactory: () => ViewerApiFactory,
@@ -14055,21 +14053,13 @@ var require_dist = __commonJS({
14055
14053
  return axios22.request(axiosRequestArgs);
14056
14054
  };
14057
14055
  };
14058
- var PeerOptionsAgentSubscribeModeEnum = {
14059
- Auto: "auto",
14060
- Manual: "manual"
14061
- };
14062
- var PeerOptionsAgentOutputAudioFormatEnum = {
14056
+ var AudioFormat = {
14063
14057
  Pcm16: "pcm16"
14064
14058
  };
14065
- var PeerOptionsAgentOutputAudioSampleRateEnum = {
14059
+ var AudioSampleRate = {
14066
14060
  NUMBER_16000: 16e3,
14067
14061
  NUMBER_24000: 24e3
14068
14062
  };
14069
- var PeerOptionsWebRTCSubscribeModeEnum = {
14070
- Auto: "auto",
14071
- Manual: "manual"
14072
- };
14073
14063
  var PeerStatus2 = {
14074
14064
  Connected: "connected",
14075
14065
  Disconnected: "disconnected"
@@ -14078,7 +14068,7 @@ var require_dist = __commonJS({
14078
14068
  Webrtc: "webrtc",
14079
14069
  Agent: "agent"
14080
14070
  };
14081
- var RoomConfigRoomTypeEnum2 = {
14071
+ var RoomType2 = {
14082
14072
  FullFeature: "full_feature",
14083
14073
  AudioOnly: "audio_only",
14084
14074
  Broadcaster: "broadcaster",
@@ -14086,10 +14076,6 @@ var require_dist = __commonJS({
14086
14076
  Conference: "conference",
14087
14077
  AudioOnlyLivestream: "audio_only_livestream"
14088
14078
  };
14089
- var RoomConfigVideoCodecEnum2 = {
14090
- H264: "h264",
14091
- Vp8: "vp8"
14092
- };
14093
14079
  var StreamerStatusEnum = {
14094
14080
  Connected: "connected",
14095
14081
  Disconnected: "disconnected"
@@ -14098,10 +14084,14 @@ var require_dist = __commonJS({
14098
14084
  Auto: "auto",
14099
14085
  Manual: "manual"
14100
14086
  };
14101
- var TrackTypeEnum = {
14087
+ var TrackType = {
14102
14088
  Audio: "audio",
14103
14089
  Video: "video"
14104
14090
  };
14091
+ var VideoCodec2 = {
14092
+ H264: "h264",
14093
+ Vp8: "vp8"
14094
+ };
14105
14095
  var ViewerStatusEnum = {
14106
14096
  Connected: "connected",
14107
14097
  Disconnected: "disconnected"
@@ -19428,14 +19418,14 @@ __export(index_exports, {
19428
19418
  PeerOptionsWebRTC: () => import_fishjam_openapi2.PeerOptionsWebRTC,
19429
19419
  PeerStatus: () => import_fishjam_openapi2.PeerStatus,
19430
19420
  RoomConfig: () => import_fishjam_openapi2.RoomConfig,
19431
- RoomConfigRoomTypeEnum: () => import_fishjam_openapi2.RoomConfigRoomTypeEnum,
19432
- RoomConfigVideoCodecEnum: () => import_fishjam_openapi2.RoomConfigVideoCodecEnum,
19433
19421
  RoomNotFoundException: () => RoomNotFoundException,
19422
+ RoomType: () => import_fishjam_openapi2.RoomType,
19434
19423
  ServerMessage: () => import_fishjam_proto3.ServerMessage,
19435
19424
  ServiceUnavailableException: () => ServiceUnavailableException,
19436
19425
  StreamerToken: () => import_fishjam_openapi2.StreamerToken,
19437
19426
  UnauthorizedException: () => UnauthorizedException,
19438
19427
  UnknownException: () => UnknownException,
19428
+ VideoCodec: () => import_fishjam_openapi2.VideoCodec,
19439
19429
  ViewerToken: () => import_fishjam_openapi2.ViewerToken
19440
19430
  });
19441
19431
  module.exports = __toCommonJS(index_exports);
@@ -19596,7 +19586,7 @@ var FishjamAgent = class extends import_events2.EventEmitter {
19596
19586
  return track;
19597
19587
  }
19598
19588
  /**
19599
- * Interrupt track indentified by `trackId`.
19589
+ * Interrupt track identified by `trackId`.
19600
19590
  *
19601
19591
  * Any audio that has been sent by the agent, but not played
19602
19592
  * by Fishjam will be cleared and be prevented from playing.
@@ -19885,14 +19875,14 @@ var FishjamClient = class {
19885
19875
  PeerOptionsWebRTC,
19886
19876
  PeerStatus,
19887
19877
  RoomConfig,
19888
- RoomConfigRoomTypeEnum,
19889
- RoomConfigVideoCodecEnum,
19890
19878
  RoomNotFoundException,
19879
+ RoomType,
19891
19880
  ServerMessage,
19892
19881
  ServiceUnavailableException,
19893
19882
  StreamerToken,
19894
19883
  UnauthorizedException,
19895
19884
  UnknownException,
19885
+ VideoCodec,
19896
19886
  ViewerToken
19897
19887
  });
19898
19888
  /*! Bundled license information:
package/dist/index.mjs CHANGED
@@ -10761,19 +10761,16 @@ var require_dist = __commonJS({
10761
10761
  });
10762
10762
  var index_exports = {};
10763
10763
  __export(index_exports, {
10764
+ AudioFormat: () => AudioFormat,
10765
+ AudioSampleRate: () => AudioSampleRate,
10764
10766
  Configuration: () => Configuration,
10765
- PeerOptionsAgentOutputAudioFormatEnum: () => PeerOptionsAgentOutputAudioFormatEnum,
10766
- PeerOptionsAgentOutputAudioSampleRateEnum: () => PeerOptionsAgentOutputAudioSampleRateEnum,
10767
- PeerOptionsAgentSubscribeModeEnum: () => PeerOptionsAgentSubscribeModeEnum,
10768
- PeerOptionsWebRTCSubscribeModeEnum: () => PeerOptionsWebRTCSubscribeModeEnum,
10769
10767
  PeerStatus: () => PeerStatus2,
10770
10768
  PeerType: () => PeerType,
10771
10769
  RoomApi: () => RoomApi2,
10772
10770
  RoomApiAxiosParamCreator: () => RoomApiAxiosParamCreator,
10773
10771
  RoomApiFactory: () => RoomApiFactory,
10774
10772
  RoomApiFp: () => RoomApiFp,
10775
- RoomConfigRoomTypeEnum: () => RoomConfigRoomTypeEnum2,
10776
- RoomConfigVideoCodecEnum: () => RoomConfigVideoCodecEnum2,
10773
+ RoomType: () => RoomType2,
10777
10774
  StreamApi: () => StreamApi,
10778
10775
  StreamApiAxiosParamCreator: () => StreamApiAxiosParamCreator,
10779
10776
  StreamApiFactory: () => StreamApiFactory,
@@ -10784,7 +10781,8 @@ var require_dist = __commonJS({
10784
10781
  StreamerApiFp: () => StreamerApiFp,
10785
10782
  StreamerStatusEnum: () => StreamerStatusEnum,
10786
10783
  SubscribeMode: () => SubscribeMode,
10787
- TrackTypeEnum: () => TrackTypeEnum,
10784
+ TrackType: () => TrackType,
10785
+ VideoCodec: () => VideoCodec2,
10788
10786
  ViewerApi: () => ViewerApi2,
10789
10787
  ViewerApiAxiosParamCreator: () => ViewerApiAxiosParamCreator,
10790
10788
  ViewerApiFactory: () => ViewerApiFactory,
@@ -14029,21 +14027,13 @@ var require_dist = __commonJS({
14029
14027
  return axios22.request(axiosRequestArgs);
14030
14028
  };
14031
14029
  };
14032
- var PeerOptionsAgentSubscribeModeEnum = {
14033
- Auto: "auto",
14034
- Manual: "manual"
14035
- };
14036
- var PeerOptionsAgentOutputAudioFormatEnum = {
14030
+ var AudioFormat = {
14037
14031
  Pcm16: "pcm16"
14038
14032
  };
14039
- var PeerOptionsAgentOutputAudioSampleRateEnum = {
14033
+ var AudioSampleRate = {
14040
14034
  NUMBER_16000: 16e3,
14041
14035
  NUMBER_24000: 24e3
14042
14036
  };
14043
- var PeerOptionsWebRTCSubscribeModeEnum = {
14044
- Auto: "auto",
14045
- Manual: "manual"
14046
- };
14047
14037
  var PeerStatus2 = {
14048
14038
  Connected: "connected",
14049
14039
  Disconnected: "disconnected"
@@ -14052,7 +14042,7 @@ var require_dist = __commonJS({
14052
14042
  Webrtc: "webrtc",
14053
14043
  Agent: "agent"
14054
14044
  };
14055
- var RoomConfigRoomTypeEnum2 = {
14045
+ var RoomType2 = {
14056
14046
  FullFeature: "full_feature",
14057
14047
  AudioOnly: "audio_only",
14058
14048
  Broadcaster: "broadcaster",
@@ -14060,10 +14050,6 @@ var require_dist = __commonJS({
14060
14050
  Conference: "conference",
14061
14051
  AudioOnlyLivestream: "audio_only_livestream"
14062
14052
  };
14063
- var RoomConfigVideoCodecEnum2 = {
14064
- H264: "h264",
14065
- Vp8: "vp8"
14066
- };
14067
14053
  var StreamerStatusEnum = {
14068
14054
  Connected: "connected",
14069
14055
  Disconnected: "disconnected"
@@ -14072,10 +14058,14 @@ var require_dist = __commonJS({
14072
14058
  Auto: "auto",
14073
14059
  Manual: "manual"
14074
14060
  };
14075
- var TrackTypeEnum = {
14061
+ var TrackType = {
14076
14062
  Audio: "audio",
14077
14063
  Video: "video"
14078
14064
  };
14065
+ var VideoCodec2 = {
14066
+ H264: "h264",
14067
+ Vp8: "vp8"
14068
+ };
14079
14069
  var ViewerStatusEnum = {
14080
14070
  Connected: "connected",
14081
14071
  Disconnected: "disconnected"
@@ -19543,7 +19533,7 @@ var FishjamAgent = class extends EventEmitter2 {
19543
19533
  return track;
19544
19534
  }
19545
19535
  /**
19546
- * Interrupt track indentified by `trackId`.
19536
+ * Interrupt track identified by `trackId`.
19547
19537
  *
19548
19538
  * Any audio that has been sent by the agent, but not played
19549
19539
  * by Fishjam will be cleared and be prevented from playing.
@@ -19821,10 +19811,10 @@ var export_PeerOptionsAgent = import_fishjam_openapi2.PeerOptionsAgent;
19821
19811
  var export_PeerOptionsWebRTC = import_fishjam_openapi2.PeerOptionsWebRTC;
19822
19812
  var export_PeerStatus = import_fishjam_openapi2.PeerStatus;
19823
19813
  var export_RoomConfig = import_fishjam_openapi2.RoomConfig;
19824
- var export_RoomConfigRoomTypeEnum = import_fishjam_openapi2.RoomConfigRoomTypeEnum;
19825
- var export_RoomConfigVideoCodecEnum = import_fishjam_openapi2.RoomConfigVideoCodecEnum;
19814
+ var export_RoomType = import_fishjam_openapi2.RoomType;
19826
19815
  var export_ServerMessage = import_fishjam_proto3.ServerMessage;
19827
19816
  var export_StreamerToken = import_fishjam_openapi2.StreamerToken;
19817
+ var export_VideoCodec = import_fishjam_openapi2.VideoCodec;
19828
19818
  var export_ViewerToken = import_fishjam_openapi2.ViewerToken;
19829
19819
  export {
19830
19820
  BadRequestException,
@@ -19841,14 +19831,14 @@ export {
19841
19831
  export_PeerOptionsWebRTC as PeerOptionsWebRTC,
19842
19832
  export_PeerStatus as PeerStatus,
19843
19833
  export_RoomConfig as RoomConfig,
19844
- export_RoomConfigRoomTypeEnum as RoomConfigRoomTypeEnum,
19845
- export_RoomConfigVideoCodecEnum as RoomConfigVideoCodecEnum,
19846
19834
  RoomNotFoundException,
19835
+ export_RoomType as RoomType,
19847
19836
  export_ServerMessage as ServerMessage,
19848
19837
  ServiceUnavailableException,
19849
19838
  export_StreamerToken as StreamerToken,
19850
19839
  UnauthorizedException,
19851
19840
  UnknownException,
19841
+ export_VideoCodec as VideoCodec,
19852
19842
  export_ViewerToken as ViewerToken
19853
19843
  };
19854
19844
  /*! Bundled license information:
@@ -27,7 +27,7 @@ module.exports = __toCommonJS(gemini_exports);
27
27
  // package.json
28
28
  var package_default = {
29
29
  name: "@fishjam-cloud/js-server-sdk",
30
- version: "0.23.0",
30
+ version: "0.24.0",
31
31
  description: "Fishjam server SDK for JavaScript",
32
32
  homepage: "https://github.com/fishjam-cloud/js-server-sdk",
33
33
  author: "Fishjam Team",
@@ -5,7 +5,7 @@ import {
5
5
  // package.json
6
6
  var package_default = {
7
7
  name: "@fishjam-cloud/js-server-sdk",
8
- version: "0.23.0",
8
+ version: "0.24.0",
9
9
  description: "Fishjam server SDK for JavaScript",
10
10
  homepage: "https://github.com/fishjam-cloud/js-server-sdk",
11
11
  author: "Fishjam Team",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@fishjam-cloud/js-server-sdk",
3
- "version": "0.23.0",
3
+ "version": "0.24.0",
4
4
  "description": "Fishjam server SDK for JavaScript",
5
5
  "homepage": "https://github.com/fishjam-cloud/js-server-sdk",
6
6
  "author": "Fishjam Team",
@@ -65,8 +65,8 @@
65
65
  }
66
66
  },
67
67
  "devDependencies": {
68
- "@fishjam-cloud/fishjam-openapi": "0.23.0",
69
- "@fishjam-cloud/fishjam-proto": "0.23.0",
68
+ "@fishjam-cloud/fishjam-openapi": "0.24.0",
69
+ "@fishjam-cloud/fishjam-proto": "0.24.0",
70
70
  "@openapitools/openapi-generator-cli": "^2.18.4",
71
71
  "@types/node": "^22.13.16",
72
72
  "@types/websocket": "^1.0.10",