mezon-js 2.10.60 → 2.10.62

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/client.ts CHANGED
@@ -204,6 +204,12 @@ export enum WebrtcSignalingType {
204
204
  WEBRTC_SDP_QUIT = 4,
205
205
  }
206
206
 
207
+ export enum SFUSignalingType {
208
+ JOINE = 0,
209
+ LEAVE = 1,
210
+ TALK = 2,
211
+ }
212
+
207
213
  /** Response for an RPC function executed on the server. */
208
214
  export interface RpcResponse {
209
215
  /** The identifier of the function. */
package/dist/client.d.ts CHANGED
@@ -47,6 +47,11 @@ export declare enum WebrtcSignalingType {
47
47
  WEBRTC_ICE_CANDIDATE = 3,
48
48
  WEBRTC_SDP_QUIT = 4
49
49
  }
50
+ export declare enum SFUSignalingType {
51
+ JOINE = 0,
52
+ LEAVE = 1,
53
+ TALK = 2
54
+ }
50
55
  /** Response for an RPC function executed on the server. */
51
56
  export interface RpcResponse {
52
57
  /** The identifier of the function. */
@@ -59,6 +59,7 @@ __export(mezon_js_exports, {
59
59
  Client: () => Client,
60
60
  DefaultSocket: () => DefaultSocket,
61
61
  NotificationType: () => NotificationType,
62
+ SFUSignalingType: () => SFUSignalingType,
62
63
  Session: () => Session,
63
64
  WebSocketAdapterText: () => WebSocketAdapterText,
64
65
  WebrtcSignalingType: () => WebrtcSignalingType,
@@ -8087,6 +8088,12 @@ var WebrtcSignalingType = /* @__PURE__ */ ((WebrtcSignalingType2) => {
8087
8088
  WebrtcSignalingType2[WebrtcSignalingType2["WEBRTC_SDP_QUIT"] = 4] = "WEBRTC_SDP_QUIT";
8088
8089
  return WebrtcSignalingType2;
8089
8090
  })(WebrtcSignalingType || {});
8091
+ var SFUSignalingType = /* @__PURE__ */ ((SFUSignalingType2) => {
8092
+ SFUSignalingType2[SFUSignalingType2["JOINE"] = 0] = "JOINE";
8093
+ SFUSignalingType2[SFUSignalingType2["LEAVE"] = 1] = "LEAVE";
8094
+ SFUSignalingType2[SFUSignalingType2["TALK"] = 2] = "TALK";
8095
+ return SFUSignalingType2;
8096
+ })(SFUSignalingType || {});
8090
8097
  var Client = class {
8091
8098
  constructor(serverkey = DEFAULT_SERVER_KEY, host = DEFAULT_HOST, port = DEFAULT_PORT, useSSL = false, timeout = DEFAULT_TIMEOUT_MS, autoRefreshSession = true) {
8092
8099
  this.serverkey = serverkey;
@@ -8053,6 +8053,12 @@ var WebrtcSignalingType = /* @__PURE__ */ ((WebrtcSignalingType2) => {
8053
8053
  WebrtcSignalingType2[WebrtcSignalingType2["WEBRTC_SDP_QUIT"] = 4] = "WEBRTC_SDP_QUIT";
8054
8054
  return WebrtcSignalingType2;
8055
8055
  })(WebrtcSignalingType || {});
8056
+ var SFUSignalingType = /* @__PURE__ */ ((SFUSignalingType2) => {
8057
+ SFUSignalingType2[SFUSignalingType2["JOINE"] = 0] = "JOINE";
8058
+ SFUSignalingType2[SFUSignalingType2["LEAVE"] = 1] = "LEAVE";
8059
+ SFUSignalingType2[SFUSignalingType2["TALK"] = 2] = "TALK";
8060
+ return SFUSignalingType2;
8061
+ })(SFUSignalingType || {});
8056
8062
  var Client = class {
8057
8063
  constructor(serverkey = DEFAULT_SERVER_KEY, host = DEFAULT_HOST, port = DEFAULT_PORT, useSSL = false, timeout = DEFAULT_TIMEOUT_MS, autoRefreshSession = true) {
8058
8064
  this.serverkey = serverkey;
@@ -10614,6 +10620,7 @@ export {
10614
10620
  Client,
10615
10621
  DefaultSocket,
10616
10622
  NotificationType,
10623
+ SFUSignalingType,
10617
10624
  Session,
10618
10625
  WebSocketAdapterText,
10619
10626
  WebrtcSignalingType,
package/dist/socket.d.ts CHANGED
@@ -701,7 +701,7 @@ export interface Socket {
701
701
  handleMessageButtonClick: (message_id: string, channel_id: string, button_id: string, sender_id: string, user_id: string, extra_data: string) => Promise<MessageButtonClicked>;
702
702
  handleDropdownBoxSelected: (message_id: string, channel_id: string, selectbox_id: string, sender_id: string, user_id: string, value: Array<string>) => Promise<DropdownBoxSelected>;
703
703
  forwardWebrtcSignaling: (receiverId: string, dataType: number, jsonData: string, channelId: string, caller_id: string) => Promise<WebrtcSignalingFwd>;
704
- forwardSFUSignaling: (receiverId: string, dataType: number, jsonData: string, channelId: string, caller_id: string) => Promise<SFUSignalingFwd>;
704
+ forwardSFUSignaling: (user_id: string, data_type: number, json_data: string, channel_id: string, clan_id: string) => Promise<SFUSignalingFwd>;
705
705
  makeCallPush: (receiverId: string, jsonData: string, channelId: string, caller_id: string) => Promise<IncomingCallPush>;
706
706
  writeChannelAppEvent: (clan_id: string, channel_id: string, action: number) => Promise<ChannelAppEvent>;
707
707
  /** Handle disconnect events received from the socket. */
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "mezon-js",
3
3
 
4
- "version": "2.10.60",
4
+ "version": "2.10.62",
5
5
 
6
6
  "scripts": {
7
7
  "build": "npx tsc && npx rollup -c --bundleConfigAsCjs && node build.mjs"
package/socket.ts CHANGED
@@ -1114,11 +1114,11 @@ export interface Socket {
1114
1114
  ) => Promise<WebrtcSignalingFwd>;
1115
1115
 
1116
1116
  forwardSFUSignaling: (
1117
- receiverId: string,
1118
- dataType: number,
1119
- jsonData: string,
1120
- channelId: string,
1121
- caller_id: string
1117
+ user_id: string,
1118
+ data_type: number,
1119
+ json_data: string,
1120
+ channel_id: string,
1121
+ clan_id: string
1122
1122
  ) => Promise<SFUSignalingFwd>;
1123
1123
 
1124
1124
  makeCallPush: (