mezon-js 2.10.79 → 2.10.81

Sign up to get free protection for your applications and to get access to all the features.
package/api.gen.ts CHANGED
@@ -1743,6 +1743,8 @@ export interface ApiNotificationUserChannel {
1743
1743
  notification_setting_type?: number;
1744
1744
  //
1745
1745
  time_mute?: string;
1746
+ //
1747
+ channel_id?: string;
1746
1748
  }
1747
1749
 
1748
1750
  /** */
@@ -2836,6 +2838,14 @@ export interface ApiGetJoinMezonMeetResponse {
2836
2838
  user_name?: string;
2837
2839
  }
2838
2840
 
2841
+ /** */
2842
+ export interface MezonapiCreateRoomChannelApps {
2843
+ //
2844
+ channel_id?: string;
2845
+ //
2846
+ room_name?: string;
2847
+ }
2848
+
2839
2849
  export class MezonApi {
2840
2850
  constructor(
2841
2851
  readonly serverKey: string,
@@ -10846,4 +10856,40 @@ export class MezonApi {
10846
10856
  ),
10847
10857
  ]);
10848
10858
  }
10859
+
10860
+ /** create meeting room */
10861
+ createRoomChannelApps(bearerToken: string,
10862
+ body:MezonapiCreateRoomChannelApps,
10863
+ options: any = {}): Promise<MezonapiCreateRoomChannelApps> {
10864
+
10865
+ if (body === null || body === undefined) {
10866
+ throw new Error("'body' is a required parameter but is null or undefined.");
10867
+ }
10868
+ const urlPath = "/v2/channel-apps/createroom";
10869
+ const queryParams = new Map<string, any>();
10870
+
10871
+ let bodyJson : string = "";
10872
+ bodyJson = JSON.stringify(body || {});
10873
+
10874
+ const fullUrl = this.buildFullUrl(this.basePath, urlPath, queryParams);
10875
+ const fetchOptions = buildFetchOptions("POST", options, bodyJson);
10876
+ if (bearerToken) {
10877
+ fetchOptions.headers["Authorization"] = "Bearer " + bearerToken;
10878
+ }
10879
+
10880
+ return Promise.race([
10881
+ fetch(fullUrl, fetchOptions).then((response) => {
10882
+ if (response.status == 204) {
10883
+ return response;
10884
+ } else if (response.status >= 200 && response.status < 300) {
10885
+ return response.json();
10886
+ } else {
10887
+ throw response;
10888
+ }
10889
+ }),
10890
+ new Promise((_, reject) =>
10891
+ setTimeout(reject, this.timeoutMs, "Request timed out.")
10892
+ ),
10893
+ ]);
10894
+ }
10849
10895
  }
package/client.ts CHANGED
@@ -159,6 +159,7 @@ import {
159
159
  MezonUpdateEventBody,
160
160
  ApiTransactionDetail,
161
161
  ApiGetJoinMezonMeetResponse,
162
+ MezonapiCreateRoomChannelApps,
162
163
  } from "./api.gen";
163
164
 
164
165
  import { Session } from "./session";
@@ -4869,7 +4870,7 @@ export class Client {
4869
4870
  });
4870
4871
  }
4871
4872
 
4872
- //**list sd topic */
4873
+ //**get join mezon meet */
4873
4874
  async getJoinMezonMeet(
4874
4875
  session: Session,
4875
4876
  channelId?:string,
@@ -4889,4 +4890,24 @@ export class Client {
4889
4890
  return Promise.resolve(response);
4890
4891
  });
4891
4892
  }
4893
+
4894
+ //**create room channel apps */
4895
+ async createRoomChannelApps(
4896
+ session: Session,
4897
+ body: MezonapiCreateRoomChannelApps
4898
+ ): Promise<MezonapiCreateRoomChannelApps> {
4899
+ if (
4900
+ this.autoRefreshSession &&
4901
+ session.refresh_token &&
4902
+ session.isexpired((Date.now() + this.expiredTimespanMs) / 1000)
4903
+ ) {
4904
+ await this.sessionRefresh(session);
4905
+ }
4906
+
4907
+ return this.apiClient
4908
+ .createRoomChannelApps(session.token, body)
4909
+ .then((response: MezonapiCreateRoomChannelApps) => {
4910
+ return Promise.resolve(response);
4911
+ });
4912
+ }
4892
4913
  }
package/dist/api.gen.d.ts CHANGED
@@ -1008,6 +1008,7 @@ export interface ApiNotificationUserChannel {
1008
1008
  id?: string;
1009
1009
  notification_setting_type?: number;
1010
1010
  time_mute?: string;
1011
+ channel_id?: string;
1011
1012
  }
1012
1013
  /** */
1013
1014
  export interface ApiStreamHttpCallbackRequest {
@@ -1641,6 +1642,11 @@ export interface ApiGetJoinMezonMeetResponse {
1641
1642
  user_id?: string;
1642
1643
  user_name?: string;
1643
1644
  }
1645
+ /** */
1646
+ export interface MezonapiCreateRoomChannelApps {
1647
+ channel_id?: string;
1648
+ room_name?: string;
1649
+ }
1644
1650
  export declare class MezonApi {
1645
1651
  readonly serverKey: string;
1646
1652
  readonly basePath: string;
@@ -2043,4 +2049,6 @@ export declare class MezonApi {
2043
2049
  updateOnboardingStepByClanId(bearerToken: string, clanId: string, body: MezonUpdateOnboardingStepByClanIdBody, options?: any): Promise<any>;
2044
2050
  /** GetJoinMezonMeet */
2045
2051
  getJoinMezonMeet(bearerToken: string, channelId?: string, roomName?: string, options?: any): Promise<ApiGetJoinMezonMeetResponse>;
2052
+ /** create meeting room */
2053
+ createRoomChannelApps(bearerToken: string, body: MezonapiCreateRoomChannelApps, options?: any): Promise<MezonapiCreateRoomChannelApps>;
2046
2054
  }
package/dist/client.d.ts CHANGED
@@ -13,7 +13,7 @@
13
13
  * See the License for the specific language governing permissions and
14
14
  * limitations under the License.
15
15
  */
16
- import { ApiAccount, ApiAccountCustom, ApiAccountDevice, ApiAccountEmail, ApiAccountFacebook, ApiAccountFacebookInstantGame, ApiAccountGoogle, ApiAccountGameCenter, ApiAccountSteam, ApiChannelDescList, ApiChannelDescription, ApiCreateChannelDescRequest, ApiDeleteRoleRequest, ApiClanDescList, ApiCreateClanDescRequest, ApiClanDesc, ApiCategoryDesc, ApiCategoryDescList, ApiPermissionList, ApiRoleUserList, ApiRole, ApiCreateRoleRequest, ApiAddRoleChannelDescRequest, ApiCreateCategoryDescRequest, ApiUpdateCategoryDescRequest, ApiEvent, ApiUpdateAccountRequest, ApiAccountApple, ApiLinkSteamRequest, ApiClanDescProfile, ApiClanProfile, ApiChannelUserList, ApiClanUserList, ApiLinkInviteUserRequest, ApiLinkInviteUser, ApiInviteUserRes, ApiUploadAttachmentRequest, ApiUploadAttachment, ApiMessageReaction, ApiMessageMention, ApiMessageAttachment, ApiMessageRef, ApiChannelMessageHeader, ApiVoiceChannelUserList, ApiChannelAttachmentList, ApiCreateEventRequest, ApiEventManagement, ApiEventList, ApiDeleteEventRequest, ApiSetDefaultNotificationRequest, ApiSetNotificationRequest, ApiSetMuteNotificationRequest, ApiSearchMessageRequest, ApiSearchMessageResponse, ApiPinMessageRequest, ApiPinMessagesList, ApiDeleteChannelDescRequest, ApiChangeChannelPrivateRequest, ApiClanEmojiCreateRequest, MezonUpdateClanEmojiByIdBody, ApiWebhookCreateRequest, ApiWebhookListResponse, MezonUpdateWebhookByIdBody, ApiWebhookGenerateResponse, ApiCheckDuplicateClanNameResponse, ApiClanStickerAddRequest, MezonUpdateClanStickerByIdBody, MezonChangeChannelCategoryBody, ApiUpdateRoleChannelRequest, ApiAddAppRequest, ApiAppList, ApiApp, MezonUpdateAppBody, ApiSystemMessagesList, ApiSystemMessage, ApiSystemMessageRequest, MezonUpdateSystemMessageBody, ApiUpdateCategoryOrderRequest, ApiGiveCoffeeEvent, ApiListStreamingChannelsResponse, ApiStreamingChannelUserList, ApiRegisterStreamingChannelRequest, ApiRoleList, ApiListChannelAppsResponse, ApiNotificationChannelCategorySettingList, ApiNotificationUserChannel, ApiNotificationSetting, ApiNotifiReactMessage, ApiHashtagDmList, ApiEmojiListedResponse, ApiStickerListedResponse, ApiAllUsersAddChannelResponse, ApiRoleListEventResponse, ApiAllUserClans, ApiUserPermissionInChannelListResponse, ApiPermissionRoleChannelListEventResponse, ApiMarkAsReadRequest, ApiChannelCanvasListResponse, ApiEditChannelCanvasRequest, ApiChannelSettingListResponse, ApiAddFavoriteChannelResponse, ApiRegistFcmDeviceTokenResponse, ApiListUserActivity, ApiCreateActivityRequest, ApiLoginIDResponse, ApiLoginRequest, ApiConfirmLoginRequest, ApiUserActivity, ApiChanEncryptionMethod, ApiGetPubKeysResponse, ApiPubKey, ApiGetKeyServerResp, MezonapiListAuditLog, ApiTokenSentEvent, MezonDeleteWebhookByIdBody, ApiWithdrawTokenRequest, ApiListOnboardingResponse, ApiCreateOnboardingRequest, MezonUpdateOnboardingBody, ApiOnboardingItem, ApiGenerateClanWebhookRequest, ApiGenerateClanWebhookResponse, ApiListClanWebhookResponse, MezonUpdateClanWebhookByIdBody, MezonUpdateClanDescBody, ApiUserStatusUpdate, ApiUserStatus, ApiListOnboardingStepResponse, MezonUpdateOnboardingStepByClanIdBody, ApiWalletLedgerList, ApiSdTopicList, ApiSdTopicRequest, ApiSdTopic, MezonUpdateEventBody, ApiTransactionDetail, ApiGetJoinMezonMeetResponse } from "./api.gen";
16
+ import { ApiAccount, ApiAccountCustom, ApiAccountDevice, ApiAccountEmail, ApiAccountFacebook, ApiAccountFacebookInstantGame, ApiAccountGoogle, ApiAccountGameCenter, ApiAccountSteam, ApiChannelDescList, ApiChannelDescription, ApiCreateChannelDescRequest, ApiDeleteRoleRequest, ApiClanDescList, ApiCreateClanDescRequest, ApiClanDesc, ApiCategoryDesc, ApiCategoryDescList, ApiPermissionList, ApiRoleUserList, ApiRole, ApiCreateRoleRequest, ApiAddRoleChannelDescRequest, ApiCreateCategoryDescRequest, ApiUpdateCategoryDescRequest, ApiEvent, ApiUpdateAccountRequest, ApiAccountApple, ApiLinkSteamRequest, ApiClanDescProfile, ApiClanProfile, ApiChannelUserList, ApiClanUserList, ApiLinkInviteUserRequest, ApiLinkInviteUser, ApiInviteUserRes, ApiUploadAttachmentRequest, ApiUploadAttachment, ApiMessageReaction, ApiMessageMention, ApiMessageAttachment, ApiMessageRef, ApiChannelMessageHeader, ApiVoiceChannelUserList, ApiChannelAttachmentList, ApiCreateEventRequest, ApiEventManagement, ApiEventList, ApiDeleteEventRequest, ApiSetDefaultNotificationRequest, ApiSetNotificationRequest, ApiSetMuteNotificationRequest, ApiSearchMessageRequest, ApiSearchMessageResponse, ApiPinMessageRequest, ApiPinMessagesList, ApiDeleteChannelDescRequest, ApiChangeChannelPrivateRequest, ApiClanEmojiCreateRequest, MezonUpdateClanEmojiByIdBody, ApiWebhookCreateRequest, ApiWebhookListResponse, MezonUpdateWebhookByIdBody, ApiWebhookGenerateResponse, ApiCheckDuplicateClanNameResponse, ApiClanStickerAddRequest, MezonUpdateClanStickerByIdBody, MezonChangeChannelCategoryBody, ApiUpdateRoleChannelRequest, ApiAddAppRequest, ApiAppList, ApiApp, MezonUpdateAppBody, ApiSystemMessagesList, ApiSystemMessage, ApiSystemMessageRequest, MezonUpdateSystemMessageBody, ApiUpdateCategoryOrderRequest, ApiGiveCoffeeEvent, ApiListStreamingChannelsResponse, ApiStreamingChannelUserList, ApiRegisterStreamingChannelRequest, ApiRoleList, ApiListChannelAppsResponse, ApiNotificationChannelCategorySettingList, ApiNotificationUserChannel, ApiNotificationSetting, ApiNotifiReactMessage, ApiHashtagDmList, ApiEmojiListedResponse, ApiStickerListedResponse, ApiAllUsersAddChannelResponse, ApiRoleListEventResponse, ApiAllUserClans, ApiUserPermissionInChannelListResponse, ApiPermissionRoleChannelListEventResponse, ApiMarkAsReadRequest, ApiChannelCanvasListResponse, ApiEditChannelCanvasRequest, ApiChannelSettingListResponse, ApiAddFavoriteChannelResponse, ApiRegistFcmDeviceTokenResponse, ApiListUserActivity, ApiCreateActivityRequest, ApiLoginIDResponse, ApiLoginRequest, ApiConfirmLoginRequest, ApiUserActivity, ApiChanEncryptionMethod, ApiGetPubKeysResponse, ApiPubKey, ApiGetKeyServerResp, MezonapiListAuditLog, ApiTokenSentEvent, MezonDeleteWebhookByIdBody, ApiWithdrawTokenRequest, ApiListOnboardingResponse, ApiCreateOnboardingRequest, MezonUpdateOnboardingBody, ApiOnboardingItem, ApiGenerateClanWebhookRequest, ApiGenerateClanWebhookResponse, ApiListClanWebhookResponse, MezonUpdateClanWebhookByIdBody, MezonUpdateClanDescBody, ApiUserStatusUpdate, ApiUserStatus, ApiListOnboardingStepResponse, MezonUpdateOnboardingStepByClanIdBody, ApiWalletLedgerList, ApiSdTopicList, ApiSdTopicRequest, ApiSdTopic, MezonUpdateEventBody, ApiTransactionDetail, ApiGetJoinMezonMeetResponse, MezonapiCreateRoomChannelApps } from "./api.gen";
17
17
  import { Session } from "./session";
18
18
  import { Socket } from "./socket";
19
19
  import { WebSocketAdapter } from "./web_socket_adapter";
@@ -640,4 +640,5 @@ export declare class Client {
640
640
  createSdTopic(session: Session, request: ApiSdTopicRequest): Promise<ApiSdTopic>;
641
641
  getTopicDetail(session: Session, topicId?: string): Promise<ApiSdTopic>;
642
642
  getJoinMezonMeet(session: Session, channelId?: string, roomName?: string): Promise<ApiGetJoinMezonMeetResponse>;
643
+ createRoomChannelApps(session: Session, body: MezonapiCreateRoomChannelApps): Promise<MezonapiCreateRoomChannelApps>;
643
644
  }
@@ -6984,6 +6984,35 @@ var MezonApi = class {
6984
6984
  )
6985
6985
  ]);
6986
6986
  }
6987
+ /** create meeting room */
6988
+ createRoomChannelApps(bearerToken, body, options = {}) {
6989
+ if (body === null || body === void 0) {
6990
+ throw new Error("'body' is a required parameter but is null or undefined.");
6991
+ }
6992
+ const urlPath = "/v2/channel-apps/createroom";
6993
+ const queryParams = /* @__PURE__ */ new Map();
6994
+ let bodyJson = "";
6995
+ bodyJson = JSON.stringify(body || {});
6996
+ const fullUrl = this.buildFullUrl(this.basePath, urlPath, queryParams);
6997
+ const fetchOptions = buildFetchOptions("POST", options, bodyJson);
6998
+ if (bearerToken) {
6999
+ fetchOptions.headers["Authorization"] = "Bearer " + bearerToken;
7000
+ }
7001
+ return Promise.race([
7002
+ fetch(fullUrl, fetchOptions).then((response) => {
7003
+ if (response.status == 204) {
7004
+ return response;
7005
+ } else if (response.status >= 200 && response.status < 300) {
7006
+ return response.json();
7007
+ } else {
7008
+ throw response;
7009
+ }
7010
+ }),
7011
+ new Promise(
7012
+ (_, reject) => setTimeout(reject, this.timeoutMs, "Request timed out.")
7013
+ )
7014
+ ]);
7015
+ }
6987
7016
  };
6988
7017
 
6989
7018
  // session.ts
@@ -7211,6 +7240,8 @@ var _DefaultSocket = class _DefaultSocket {
7211
7240
  this.onroleevent(message.role_event);
7212
7241
  } else if (message.event_emoji) {
7213
7242
  this.oneventemoji(message.event_emoji);
7243
+ } else if (message.noti_user_channel) {
7244
+ this.oneventnotiuserchannel(message.noti_user_channel);
7214
7245
  } else if (message.webhook_event) {
7215
7246
  this.oneventwebhook(message.webhook_event);
7216
7247
  } else if (message.channel_deleted_event) {
@@ -7552,6 +7583,11 @@ var _DefaultSocket = class _DefaultSocket {
7552
7583
  console.log(eventEmoji);
7553
7584
  }
7554
7585
  }
7586
+ oneventnotiuserchannel(notiUserChannel) {
7587
+ if (this.verbose && window && window.console) {
7588
+ console.log(notiUserChannel);
7589
+ }
7590
+ }
7555
7591
  oneventwebhook(webhook_event) {
7556
7592
  if (this.verbose && window && window.console) {
7557
7593
  console.log(webhook_event);
@@ -10681,7 +10717,7 @@ var Client = class {
10681
10717
  });
10682
10718
  });
10683
10719
  }
10684
- //**list sd topic */
10720
+ //**get join mezon meet */
10685
10721
  getJoinMezonMeet(session, channelId, roomName) {
10686
10722
  return __async(this, null, function* () {
10687
10723
  if (this.autoRefreshSession && session.refresh_token && session.isexpired((Date.now() + this.expiredTimespanMs) / 1e3)) {
@@ -10692,4 +10728,15 @@ var Client = class {
10692
10728
  });
10693
10729
  });
10694
10730
  }
10731
+ //**create room channel apps */
10732
+ createRoomChannelApps(session, body) {
10733
+ return __async(this, null, function* () {
10734
+ if (this.autoRefreshSession && session.refresh_token && session.isexpired((Date.now() + this.expiredTimespanMs) / 1e3)) {
10735
+ yield this.sessionRefresh(session);
10736
+ }
10737
+ return this.apiClient.createRoomChannelApps(session.token, body).then((response) => {
10738
+ return Promise.resolve(response);
10739
+ });
10740
+ });
10741
+ }
10695
10742
  };
@@ -6950,6 +6950,35 @@ var MezonApi = class {
6950
6950
  )
6951
6951
  ]);
6952
6952
  }
6953
+ /** create meeting room */
6954
+ createRoomChannelApps(bearerToken, body, options = {}) {
6955
+ if (body === null || body === void 0) {
6956
+ throw new Error("'body' is a required parameter but is null or undefined.");
6957
+ }
6958
+ const urlPath = "/v2/channel-apps/createroom";
6959
+ const queryParams = /* @__PURE__ */ new Map();
6960
+ let bodyJson = "";
6961
+ bodyJson = JSON.stringify(body || {});
6962
+ const fullUrl = this.buildFullUrl(this.basePath, urlPath, queryParams);
6963
+ const fetchOptions = buildFetchOptions("POST", options, bodyJson);
6964
+ if (bearerToken) {
6965
+ fetchOptions.headers["Authorization"] = "Bearer " + bearerToken;
6966
+ }
6967
+ return Promise.race([
6968
+ fetch(fullUrl, fetchOptions).then((response) => {
6969
+ if (response.status == 204) {
6970
+ return response;
6971
+ } else if (response.status >= 200 && response.status < 300) {
6972
+ return response.json();
6973
+ } else {
6974
+ throw response;
6975
+ }
6976
+ }),
6977
+ new Promise(
6978
+ (_, reject) => setTimeout(reject, this.timeoutMs, "Request timed out.")
6979
+ )
6980
+ ]);
6981
+ }
6953
6982
  };
6954
6983
 
6955
6984
  // session.ts
@@ -7177,6 +7206,8 @@ var _DefaultSocket = class _DefaultSocket {
7177
7206
  this.onroleevent(message.role_event);
7178
7207
  } else if (message.event_emoji) {
7179
7208
  this.oneventemoji(message.event_emoji);
7209
+ } else if (message.noti_user_channel) {
7210
+ this.oneventnotiuserchannel(message.noti_user_channel);
7180
7211
  } else if (message.webhook_event) {
7181
7212
  this.oneventwebhook(message.webhook_event);
7182
7213
  } else if (message.channel_deleted_event) {
@@ -7518,6 +7549,11 @@ var _DefaultSocket = class _DefaultSocket {
7518
7549
  console.log(eventEmoji);
7519
7550
  }
7520
7551
  }
7552
+ oneventnotiuserchannel(notiUserChannel) {
7553
+ if (this.verbose && window && window.console) {
7554
+ console.log(notiUserChannel);
7555
+ }
7556
+ }
7521
7557
  oneventwebhook(webhook_event) {
7522
7558
  if (this.verbose && window && window.console) {
7523
7559
  console.log(webhook_event);
@@ -10647,7 +10683,7 @@ var Client = class {
10647
10683
  });
10648
10684
  });
10649
10685
  }
10650
- //**list sd topic */
10686
+ //**get join mezon meet */
10651
10687
  getJoinMezonMeet(session, channelId, roomName) {
10652
10688
  return __async(this, null, function* () {
10653
10689
  if (this.autoRefreshSession && session.refresh_token && session.isexpired((Date.now() + this.expiredTimespanMs) / 1e3)) {
@@ -10658,6 +10694,17 @@ var Client = class {
10658
10694
  });
10659
10695
  });
10660
10696
  }
10697
+ //**create room channel apps */
10698
+ createRoomChannelApps(session, body) {
10699
+ return __async(this, null, function* () {
10700
+ if (this.autoRefreshSession && session.refresh_token && session.isexpired((Date.now() + this.expiredTimespanMs) / 1e3)) {
10701
+ yield this.sessionRefresh(session);
10702
+ }
10703
+ return this.apiClient.createRoomChannelApps(session.token, body).then((response) => {
10704
+ return Promise.resolve(response);
10705
+ });
10706
+ });
10707
+ }
10661
10708
  };
10662
10709
  export {
10663
10710
  ChannelStreamMode,
package/dist/socket.d.ts CHANGED
@@ -13,7 +13,7 @@
13
13
  * See the License for the specific language governing permissions and
14
14
  * limitations under the License.
15
15
  */
16
- import { ApiChannelDescription, ApiChannelMessageHeader, ApiCreateEventRequest, ApiGiveCoffeeEvent, ApiMessageAttachment, ApiMessageMention, ApiMessageReaction, ApiMessageRef, ApiPermissionUpdate, ApiRole, ApiRpc, ApiTokenSentEvent, ApiUserActivity, ApiWebhook } from "./api.gen";
16
+ import { ApiChannelDescription, ApiChannelMessageHeader, ApiCreateEventRequest, ApiGiveCoffeeEvent, ApiMessageAttachment, ApiMessageMention, ApiMessageReaction, ApiMessageRef, ApiNotificationUserChannel, ApiPermissionUpdate, ApiRole, ApiRpc, ApiTokenSentEvent, ApiUserActivity, ApiWebhook } from "./api.gen";
17
17
  import { Session } from "./session";
18
18
  import { ChannelMessage } from "./client";
19
19
  import { WebSocketAdapter } from "./web_socket_adapter";
@@ -796,6 +796,7 @@ export interface Socket {
796
796
  oneventcreated: (clan_event_created: ApiCreateEventRequest) => void;
797
797
  oncoffeegiven: (give_coffee_event: ApiGiveCoffeeEvent) => void;
798
798
  oneventemoji: (event_emoji: EventEmoji) => void;
799
+ oneventnotiuserchannel: (noti_user_channel: ApiNotificationUserChannel) => void;
799
800
  oneventwebhook: (webhook_event: ApiWebhook) => void;
800
801
  onroleassign: (role_assign_event: RoleAssignedEvent) => void;
801
802
  onstreamingchannelstarted: (streaming_started_event: StreamingStartedEvent) => void;
@@ -861,6 +862,7 @@ export declare class DefaultSocket implements Socket {
861
862
  onchannelcreated(channelCreated: ChannelCreatedEvent): void;
862
863
  onroleevent(roleEvent: RoleEvent): void;
863
864
  oneventemoji(eventEmoji: EventEmoji): void;
865
+ oneventnotiuserchannel(notiUserChannel: ApiNotificationUserChannel): void;
864
866
  oneventwebhook(webhook_event: ApiWebhook): void;
865
867
  onchanneldeleted(channelDeleted: ChannelDeletedEvent): void;
866
868
  onclandeleted(clanDeleted: ClanDeletedEvent): void;
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "mezon-js",
3
3
 
4
- "version": "2.10.79",
4
+ "version": "2.10.81",
5
5
 
6
6
  "scripts": {
7
7
  "build": "npx tsc && npx rollup -c --bundleConfigAsCjs && node build.mjs"
package/socket.ts CHANGED
@@ -24,6 +24,7 @@ import {
24
24
  ApiMessageReaction,
25
25
  ApiMessageRef,
26
26
  ApiNotification,
27
+ ApiNotificationUserChannel,
27
28
  ApiPermissionUpdate,
28
29
  ApiRole,
29
30
  ApiRpc,
@@ -1295,6 +1296,8 @@ export interface Socket {
1295
1296
 
1296
1297
  oneventemoji: (event_emoji: EventEmoji) => void;
1297
1298
 
1299
+ oneventnotiuserchannel: (noti_user_channel: ApiNotificationUserChannel) => void;
1300
+
1298
1301
  oneventwebhook: (webhook_event: ApiWebhook) => void;
1299
1302
 
1300
1303
  onroleassign: (role_assign_event: RoleAssignedEvent) => void;
@@ -1428,6 +1431,8 @@ export class DefaultSocket implements Socket {
1428
1431
  this.onroleevent(message.role_event);
1429
1432
  } else if (message.event_emoji) {
1430
1433
  this.oneventemoji(message.event_emoji);
1434
+ } else if (message.noti_user_channel) {
1435
+ this.oneventnotiuserchannel(message.noti_user_channel);
1431
1436
  } else if (message.webhook_event) {
1432
1437
  this.oneventwebhook(message.webhook_event);
1433
1438
  } else if (message.channel_deleted_event) {
@@ -1800,6 +1805,12 @@ export class DefaultSocket implements Socket {
1800
1805
  }
1801
1806
  }
1802
1807
 
1808
+ oneventnotiuserchannel(notiUserChannel: ApiNotificationUserChannel) {
1809
+ if (this.verbose && window && window.console) {
1810
+ console.log(notiUserChannel);
1811
+ }
1812
+ }
1813
+
1803
1814
  oneventwebhook(webhook_event: ApiWebhook) {
1804
1815
  if (this.verbose && window && window.console) {
1805
1816
  console.log(webhook_event);