mezon-js 2.11.14 → 2.11.15

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.
@@ -8152,7 +8152,7 @@ var _DefaultSocket = class _DefaultSocket {
8152
8152
  return response.message_typing_event;
8153
8153
  });
8154
8154
  }
8155
- writeLastSeenMessage(clan_id, channel_id, mode, message_id, timestamp_seconds) {
8155
+ writeLastSeenMessage(clan_id, channel_id, mode, message_id, timestamp_seconds, badge_count) {
8156
8156
  return __async(this, null, function* () {
8157
8157
  const response = yield this.send({
8158
8158
  last_seen_message_event: {
@@ -8160,7 +8160,8 @@ var _DefaultSocket = class _DefaultSocket {
8160
8160
  channel_id,
8161
8161
  mode,
8162
8162
  message_id,
8163
- timestamp_seconds
8163
+ timestamp_seconds,
8164
+ badge_count
8164
8165
  }
8165
8166
  });
8166
8167
  return response.last_seen_message_event;
@@ -8118,7 +8118,7 @@ var _DefaultSocket = class _DefaultSocket {
8118
8118
  return response.message_typing_event;
8119
8119
  });
8120
8120
  }
8121
- writeLastSeenMessage(clan_id, channel_id, mode, message_id, timestamp_seconds) {
8121
+ writeLastSeenMessage(clan_id, channel_id, mode, message_id, timestamp_seconds, badge_count) {
8122
8122
  return __async(this, null, function* () {
8123
8123
  const response = yield this.send({
8124
8124
  last_seen_message_event: {
@@ -8126,7 +8126,8 @@ var _DefaultSocket = class _DefaultSocket {
8126
8126
  channel_id,
8127
8127
  mode,
8128
8128
  message_id,
8129
- timestamp_seconds
8129
+ timestamp_seconds,
8130
+ badge_count
8130
8131
  }
8131
8132
  });
8132
8133
  return response.last_seen_message_event;
package/dist/socket.d.ts CHANGED
@@ -168,6 +168,7 @@ export interface LastSeenMessageEvent {
168
168
  channel_label: string;
169
169
  /** The unique ID of this message. */
170
170
  message_id: string;
171
+ badge_count: number;
171
172
  }
172
173
  /** User is typing */
173
174
  export interface MessageTypingEvent {
@@ -335,6 +336,7 @@ export interface ChannelUpdatedEvent {
335
336
  topic: string;
336
337
  age_restricted: number;
337
338
  is_active_thread: boolean;
339
+ active: number;
338
340
  }
339
341
  export interface ChannelCreatedEvent {
340
342
  clan_id: string;
@@ -752,7 +754,7 @@ export interface Socket {
752
754
  /** Send message reaction */
753
755
  writeMessageReaction(id: string, clan_id: string, channel_id: string, mode: number, is_public: boolean, message_id: string, emoji_id: string, emoji: string, count: number, message_sender_id: string, action_delete: boolean, topic_id?: string, emoji_recent_id?: string): Promise<ApiMessageReaction>;
754
756
  /** Send last seen message */
755
- writeLastSeenMessage(clan_id: string, channel_id: string, mode: number, message_id: string, timestamp_seconds: number): Promise<LastSeenMessageEvent>;
757
+ writeLastSeenMessage(clan_id: string, channel_id: string, mode: number, message_id: string, timestamp_seconds: number, badge_count: number): Promise<LastSeenMessageEvent>;
756
758
  /** Send last pin message */
757
759
  writeLastPinMessage(clan_id: string, channel_id: string, mode: number, is_public: boolean, message_id: string, timestamp_seconds: number, operation: number): Promise<LastPinMessageEvent>;
758
760
  /** Send custom user status */
@@ -953,7 +955,7 @@ export declare class DefaultSocket implements Socket {
953
955
  writeChatMessage(clan_id: string, channel_id: string, mode: number, is_public: boolean, content: any, mentions?: Array<ApiMessageMention>, attachments?: Array<ApiMessageAttachment>, references?: Array<ApiMessageRef>, anonymous_message?: boolean, mention_everyone?: Boolean, avatar?: string, code?: number, topic_id?: string): Promise<ChannelMessageAck>;
954
956
  writeMessageReaction(id: string, clan_id: string, channel_id: string, mode: number, is_public: boolean, message_id: string, emoji_id: string, emoji: string, count: number, message_sender_id: string, action_delete: boolean, topic_id?: string, emoji_recent_id?: string): Promise<ApiMessageReaction>;
955
957
  writeMessageTyping(clan_id: string, channel_id: string, mode: number, is_public: boolean): Promise<MessageTypingEvent>;
956
- writeLastSeenMessage(clan_id: string, channel_id: string, mode: number, message_id: string, timestamp_seconds: number): Promise<LastSeenMessageEvent>;
958
+ writeLastSeenMessage(clan_id: string, channel_id: string, mode: number, message_id: string, timestamp_seconds: number, badge_count: number): Promise<LastSeenMessageEvent>;
957
959
  writeLastPinMessage(clan_id: string, channel_id: string, mode: number, is_public: boolean, message_id: string, timestamp_seconds: number, operation: number): Promise<LastPinMessageEvent>;
958
960
  writeVoiceJoined(id: string, clanId: string, clanName: string, voiceChannelId: string, voiceChannelLabel: string, participant: string, lastScreenshot: string): Promise<VoiceJoinedEvent>;
959
961
  writeVoiceLeaved(id: string, clanId: string, voiceChannelId: string, voiceUserId: string): Promise<VoiceLeavedEvent>;
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "mezon-js",
3
3
 
4
- "version": "2.11.14",
4
+ "version": "2.11.15",
5
5
 
6
6
  "scripts": {
7
7
  "build": "npx tsc && npx rollup -c --bundleConfigAsCjs && node build.mjs"
package/socket.ts CHANGED
@@ -245,6 +245,8 @@ export interface LastSeenMessageEvent {
245
245
  channel_label: string;
246
246
  /** The unique ID of this message. */
247
247
  message_id: string;
248
+ //
249
+ badge_count: number;
248
250
  }
249
251
 
250
252
  /** User is typing */
@@ -494,6 +496,8 @@ export interface ChannelUpdatedEvent {
494
496
  age_restricted: number;
495
497
  //
496
498
  is_active_thread: boolean;
499
+ //
500
+ active: number;
497
501
  }
498
502
 
499
503
  export interface ChannelCreatedEvent {
@@ -1138,7 +1142,8 @@ export interface Socket {
1138
1142
  channel_id: string,
1139
1143
  mode: number,
1140
1144
  message_id: string,
1141
- timestamp_seconds: number
1145
+ timestamp_seconds: number,
1146
+ badge_count: number
1142
1147
  ): Promise<LastSeenMessageEvent>;
1143
1148
 
1144
1149
  /** Send last pin message */
@@ -2380,7 +2385,8 @@ export class DefaultSocket implements Socket {
2380
2385
  channel_id: string,
2381
2386
  mode: number,
2382
2387
  message_id: string,
2383
- timestamp_seconds: number
2388
+ timestamp_seconds: number,
2389
+ badge_count: number
2384
2390
  ): Promise<LastSeenMessageEvent> {
2385
2391
  const response = await this.send({
2386
2392
  last_seen_message_event: {
@@ -2389,6 +2395,7 @@ export class DefaultSocket implements Socket {
2389
2395
  mode: mode,
2390
2396
  message_id: message_id,
2391
2397
  timestamp_seconds: timestamp_seconds,
2398
+ badge_count: badge_count,
2392
2399
  },
2393
2400
  });
2394
2401
  return response.last_seen_message_event;