mezon-sdk 2.7.87 → 2.7.89

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.
Files changed (39) hide show
  1. package/dist/cjs/api/api.d.ts +906 -289
  2. package/dist/cjs/api/api.js +1050 -119
  3. package/dist/cjs/api/api.js.map +1 -1
  4. package/dist/cjs/api.d.ts +3 -1
  5. package/dist/cjs/api.js +59 -0
  6. package/dist/cjs/api.js.map +1 -1
  7. package/dist/cjs/interfaces/client.d.ts +77 -1
  8. package/dist/cjs/interfaces/client.js +1 -0
  9. package/dist/cjs/interfaces/client.js.map +1 -1
  10. package/dist/cjs/interfaces/socket.d.ts +1 -0
  11. package/dist/cjs/mezon-client/client/MezonClient.js +10 -7
  12. package/dist/cjs/mezon-client/client/MezonClient.js.map +1 -1
  13. package/dist/cjs/mezon-client/structures/Clan.d.ts +3 -1
  14. package/dist/cjs/mezon-client/structures/Clan.js +8 -0
  15. package/dist/cjs/mezon-client/structures/Clan.js.map +1 -1
  16. package/dist/cjs/rtapi/realtime.d.ts +722 -388
  17. package/dist/cjs/rtapi/realtime.js +288 -22
  18. package/dist/cjs/rtapi/realtime.js.map +1 -1
  19. package/dist/esm/api/api.d.ts +906 -289
  20. package/dist/esm/api/api.js +1048 -129
  21. package/dist/esm/api/api.js.map +1 -1
  22. package/dist/esm/api.d.ts +3 -1
  23. package/dist/esm/api.js +59 -0
  24. package/dist/esm/api.js.map +1 -1
  25. package/dist/esm/interfaces/client.d.ts +77 -1
  26. package/dist/esm/interfaces/client.js +1 -0
  27. package/dist/esm/interfaces/client.js.map +1 -1
  28. package/dist/esm/interfaces/socket.d.ts +1 -0
  29. package/dist/esm/mezon-client/client/MezonClient.js +8 -5
  30. package/dist/esm/mezon-client/client/MezonClient.js.map +1 -1
  31. package/dist/esm/mezon-client/structures/Clan.d.ts +3 -1
  32. package/dist/esm/mezon-client/structures/Clan.js +8 -0
  33. package/dist/esm/mezon-client/structures/Clan.js.map +1 -1
  34. package/dist/esm/rtapi/realtime.d.ts +722 -388
  35. package/dist/esm/rtapi/realtime.js +282 -18
  36. package/dist/esm/rtapi/realtime.js.map +1 -1
  37. package/dist/tsconfig.esm.tsbuildinfo +1 -1
  38. package/dist/tsconfig.tsbuildinfo +1 -1
  39. package/package.json +1 -1
@@ -163,6 +163,8 @@ function createBaseEnvelope() {
163
163
  canvas_event: undefined,
164
164
  unpin_message_event: undefined,
165
165
  category_event: undefined,
166
+ handle_participant_meet_state_event: undefined,
167
+ delete_account_event: undefined,
166
168
  };
167
169
  }
168
170
  export const Envelope = {
@@ -395,6 +397,13 @@ export const Envelope = {
395
397
  if (message.category_event !== undefined) {
396
398
  CategoryEvent.encode(message.category_event, writer.uint32(610).fork()).ldelim();
397
399
  }
400
+ if (message.handle_participant_meet_state_event !== undefined) {
401
+ HandleParticipantMeetStateEvent.encode(message.handle_participant_meet_state_event, writer.uint32(618).fork())
402
+ .ldelim();
403
+ }
404
+ if (message.delete_account_event !== undefined) {
405
+ DeleteAccountEvent.encode(message.delete_account_event, writer.uint32(626).fork()).ldelim();
406
+ }
398
407
  return writer;
399
408
  },
400
409
  decode(input, length) {
@@ -860,6 +869,18 @@ export const Envelope = {
860
869
  }
861
870
  message.category_event = CategoryEvent.decode(reader, reader.uint32());
862
871
  continue;
872
+ case 77:
873
+ if (tag !== 618) {
874
+ break;
875
+ }
876
+ message.handle_participant_meet_state_event = HandleParticipantMeetStateEvent.decode(reader, reader.uint32());
877
+ continue;
878
+ case 78:
879
+ if (tag !== 626) {
880
+ break;
881
+ }
882
+ message.delete_account_event = DeleteAccountEvent.decode(reader, reader.uint32());
883
+ continue;
863
884
  }
864
885
  if ((tag & 7) === 4 || tag === 0) {
865
886
  break;
@@ -1044,6 +1065,12 @@ export const Envelope = {
1044
1065
  ? UnpinMessageEvent.fromJSON(object.unpin_message_event)
1045
1066
  : undefined,
1046
1067
  category_event: isSet(object.category_event) ? CategoryEvent.fromJSON(object.category_event) : undefined,
1068
+ handle_participant_meet_state_event: isSet(object.handle_participant_meet_state_event)
1069
+ ? HandleParticipantMeetStateEvent.fromJSON(object.handle_participant_meet_state_event)
1070
+ : undefined,
1071
+ delete_account_event: isSet(object.delete_account_event)
1072
+ ? DeleteAccountEvent.fromJSON(object.delete_account_event)
1073
+ : undefined,
1047
1074
  };
1048
1075
  },
1049
1076
  toJSON(message) {
@@ -1276,6 +1303,12 @@ export const Envelope = {
1276
1303
  if (message.category_event !== undefined) {
1277
1304
  obj.category_event = CategoryEvent.toJSON(message.category_event);
1278
1305
  }
1306
+ if (message.handle_participant_meet_state_event !== undefined) {
1307
+ obj.handle_participant_meet_state_event = HandleParticipantMeetStateEvent.toJSON(message.handle_participant_meet_state_event);
1308
+ }
1309
+ if (message.delete_account_event !== undefined) {
1310
+ obj.delete_account_event = DeleteAccountEvent.toJSON(message.delete_account_event);
1311
+ }
1279
1312
  return obj;
1280
1313
  },
1281
1314
  create(base) {
@@ -1526,6 +1559,13 @@ export const Envelope = {
1526
1559
  message.category_event = (object.category_event !== undefined && object.category_event !== null)
1527
1560
  ? CategoryEvent.fromPartial(object.category_event)
1528
1561
  : undefined;
1562
+ message.handle_participant_meet_state_event =
1563
+ (object.handle_participant_meet_state_event !== undefined && object.handle_participant_meet_state_event !== null)
1564
+ ? HandleParticipantMeetStateEvent.fromPartial(object.handle_participant_meet_state_event)
1565
+ : undefined;
1566
+ message.delete_account_event = (object.delete_account_event !== undefined && object.delete_account_event !== null)
1567
+ ? DeleteAccountEvent.fromPartial(object.delete_account_event)
1568
+ : undefined;
1529
1569
  return message;
1530
1570
  },
1531
1571
  };
@@ -2036,7 +2076,7 @@ export const SFUSignalingFwd = {
2036
2076
  },
2037
2077
  };
2038
2078
  function createBaseAddClanUserEvent() {
2039
- return { clan_id: "", user: undefined };
2079
+ return { clan_id: "", user: undefined, invitor: "" };
2040
2080
  }
2041
2081
  export const AddClanUserEvent = {
2042
2082
  encode(message, writer = _m0.Writer.create()) {
@@ -2046,6 +2086,9 @@ export const AddClanUserEvent = {
2046
2086
  if (message.user !== undefined) {
2047
2087
  UserProfileRedis.encode(message.user, writer.uint32(18).fork()).ldelim();
2048
2088
  }
2089
+ if (message.invitor !== "") {
2090
+ writer.uint32(26).string(message.invitor);
2091
+ }
2049
2092
  return writer;
2050
2093
  },
2051
2094
  decode(input, length) {
@@ -2067,6 +2110,12 @@ export const AddClanUserEvent = {
2067
2110
  }
2068
2111
  message.user = UserProfileRedis.decode(reader, reader.uint32());
2069
2112
  continue;
2113
+ case 3:
2114
+ if (tag !== 26) {
2115
+ break;
2116
+ }
2117
+ message.invitor = reader.string();
2118
+ continue;
2070
2119
  }
2071
2120
  if ((tag & 7) === 4 || tag === 0) {
2072
2121
  break;
@@ -2079,6 +2128,7 @@ export const AddClanUserEvent = {
2079
2128
  return {
2080
2129
  clan_id: isSet(object.clan_id) ? globalThis.String(object.clan_id) : "",
2081
2130
  user: isSet(object.user) ? UserProfileRedis.fromJSON(object.user) : undefined,
2131
+ invitor: isSet(object.invitor) ? globalThis.String(object.invitor) : "",
2082
2132
  };
2083
2133
  },
2084
2134
  toJSON(message) {
@@ -2089,6 +2139,9 @@ export const AddClanUserEvent = {
2089
2139
  if (message.user !== undefined) {
2090
2140
  obj.user = UserProfileRedis.toJSON(message.user);
2091
2141
  }
2142
+ if (message.invitor !== "") {
2143
+ obj.invitor = message.invitor;
2144
+ }
2092
2145
  return obj;
2093
2146
  },
2094
2147
  create(base) {
@@ -2100,6 +2153,7 @@ export const AddClanUserEvent = {
2100
2153
  message.user = (object.user !== undefined && object.user !== null)
2101
2154
  ? UserProfileRedis.fromPartial(object.user)
2102
2155
  : undefined;
2156
+ message.invitor = object.invitor ?? "";
2103
2157
  return message;
2104
2158
  },
2105
2159
  };
@@ -4819,7 +4873,15 @@ export const LastSeenMessageEvent = {
4819
4873
  },
4820
4874
  };
4821
4875
  function createBaseMessageTypingEvent() {
4822
- return { clan_id: "", channel_id: "", sender_id: "", mode: 0, is_public: false };
4876
+ return {
4877
+ clan_id: "",
4878
+ channel_id: "",
4879
+ sender_id: "",
4880
+ mode: 0,
4881
+ is_public: false,
4882
+ sender_username: "",
4883
+ sender_display_name: "",
4884
+ };
4823
4885
  }
4824
4886
  export const MessageTypingEvent = {
4825
4887
  encode(message, writer = _m0.Writer.create()) {
@@ -4838,6 +4900,12 @@ export const MessageTypingEvent = {
4838
4900
  if (message.is_public !== false) {
4839
4901
  writer.uint32(40).bool(message.is_public);
4840
4902
  }
4903
+ if (message.sender_username !== "") {
4904
+ writer.uint32(50).string(message.sender_username);
4905
+ }
4906
+ if (message.sender_display_name !== "") {
4907
+ writer.uint32(58).string(message.sender_display_name);
4908
+ }
4841
4909
  return writer;
4842
4910
  },
4843
4911
  decode(input, length) {
@@ -4877,6 +4945,18 @@ export const MessageTypingEvent = {
4877
4945
  }
4878
4946
  message.is_public = reader.bool();
4879
4947
  continue;
4948
+ case 6:
4949
+ if (tag !== 50) {
4950
+ break;
4951
+ }
4952
+ message.sender_username = reader.string();
4953
+ continue;
4954
+ case 7:
4955
+ if (tag !== 58) {
4956
+ break;
4957
+ }
4958
+ message.sender_display_name = reader.string();
4959
+ continue;
4880
4960
  }
4881
4961
  if ((tag & 7) === 4 || tag === 0) {
4882
4962
  break;
@@ -4892,6 +4972,8 @@ export const MessageTypingEvent = {
4892
4972
  sender_id: isSet(object.sender_id) ? globalThis.String(object.sender_id) : "",
4893
4973
  mode: isSet(object.mode) ? globalThis.Number(object.mode) : 0,
4894
4974
  is_public: isSet(object.is_public) ? globalThis.Boolean(object.is_public) : false,
4975
+ sender_username: isSet(object.sender_username) ? globalThis.String(object.sender_username) : "",
4976
+ sender_display_name: isSet(object.sender_display_name) ? globalThis.String(object.sender_display_name) : "",
4895
4977
  };
4896
4978
  },
4897
4979
  toJSON(message) {
@@ -4911,6 +4993,12 @@ export const MessageTypingEvent = {
4911
4993
  if (message.is_public !== false) {
4912
4994
  obj.is_public = message.is_public;
4913
4995
  }
4996
+ if (message.sender_username !== "") {
4997
+ obj.sender_username = message.sender_username;
4998
+ }
4999
+ if (message.sender_display_name !== "") {
5000
+ obj.sender_display_name = message.sender_display_name;
5001
+ }
4914
5002
  return obj;
4915
5003
  },
4916
5004
  create(base) {
@@ -4923,6 +5011,8 @@ export const MessageTypingEvent = {
4923
5011
  message.sender_id = object.sender_id ?? "";
4924
5012
  message.mode = object.mode ?? 0;
4925
5013
  message.is_public = object.is_public ?? false;
5014
+ message.sender_username = object.sender_username ?? "";
5015
+ message.sender_display_name = object.sender_display_name ?? "";
4926
5016
  return message;
4927
5017
  },
4928
5018
  };
@@ -5750,7 +5840,7 @@ function createBaseChannelCreatedEvent() {
5750
5840
  channel_private: 0,
5751
5841
  channel_type: undefined,
5752
5842
  status: 0,
5753
- app_url: "",
5843
+ app_id: "",
5754
5844
  clan_name: "",
5755
5845
  };
5756
5846
  }
@@ -5783,8 +5873,8 @@ export const ChannelCreatedEvent = {
5783
5873
  if (message.status !== 0) {
5784
5874
  writer.uint32(72).int32(message.status);
5785
5875
  }
5786
- if (message.app_url !== "") {
5787
- writer.uint32(82).string(message.app_url);
5876
+ if (message.app_id !== "") {
5877
+ writer.uint32(82).string(message.app_id);
5788
5878
  }
5789
5879
  if (message.clan_name !== "") {
5790
5880
  writer.uint32(90).string(message.clan_name);
@@ -5856,7 +5946,7 @@ export const ChannelCreatedEvent = {
5856
5946
  if (tag !== 82) {
5857
5947
  break;
5858
5948
  }
5859
- message.app_url = reader.string();
5949
+ message.app_id = reader.string();
5860
5950
  continue;
5861
5951
  case 11:
5862
5952
  if (tag !== 90) {
@@ -5883,7 +5973,7 @@ export const ChannelCreatedEvent = {
5883
5973
  channel_private: isSet(object.channel_private) ? globalThis.Number(object.channel_private) : 0,
5884
5974
  channel_type: isSet(object.channel_type) ? Number(object.channel_type) : undefined,
5885
5975
  status: isSet(object.status) ? globalThis.Number(object.status) : 0,
5886
- app_url: isSet(object.app_url) ? globalThis.String(object.app_url) : "",
5976
+ app_id: isSet(object.app_id) ? globalThis.String(object.app_id) : "",
5887
5977
  clan_name: isSet(object.clan_name) ? globalThis.String(object.clan_name) : "",
5888
5978
  };
5889
5979
  },
@@ -5916,8 +6006,8 @@ export const ChannelCreatedEvent = {
5916
6006
  if (message.status !== 0) {
5917
6007
  obj.status = Math.round(message.status);
5918
6008
  }
5919
- if (message.app_url !== "") {
5920
- obj.app_url = message.app_url;
6009
+ if (message.app_id !== "") {
6010
+ obj.app_id = message.app_id;
5921
6011
  }
5922
6012
  if (message.clan_name !== "") {
5923
6013
  obj.clan_name = message.clan_name;
@@ -5938,7 +6028,7 @@ export const ChannelCreatedEvent = {
5938
6028
  message.channel_private = object.channel_private ?? 0;
5939
6029
  message.channel_type = object.channel_type ?? undefined;
5940
6030
  message.status = object.status ?? 0;
5941
- message.app_url = object.app_url ?? "";
6031
+ message.app_id = object.app_id ?? "";
5942
6032
  message.clan_name = object.clan_name ?? "";
5943
6033
  return message;
5944
6034
  },
@@ -6695,7 +6785,7 @@ function createBaseChannelUpdatedEvent() {
6695
6785
  meeting_code: "",
6696
6786
  is_error: false,
6697
6787
  channel_private: false,
6698
- app_url: "",
6788
+ app_id: "",
6699
6789
  e2ee: 0,
6700
6790
  topic: "",
6701
6791
  age_restricted: 0,
@@ -6737,8 +6827,8 @@ export const ChannelUpdatedEvent = {
6737
6827
  if (message.channel_private !== false) {
6738
6828
  writer.uint32(88).bool(message.channel_private);
6739
6829
  }
6740
- if (message.app_url !== "") {
6741
- writer.uint32(98).string(message.app_url);
6830
+ if (message.app_id !== "") {
6831
+ writer.uint32(98).string(message.app_id);
6742
6832
  }
6743
6833
  if (message.e2ee !== 0) {
6744
6834
  writer.uint32(104).int32(message.e2ee);
@@ -6831,7 +6921,7 @@ export const ChannelUpdatedEvent = {
6831
6921
  if (tag !== 98) {
6832
6922
  break;
6833
6923
  }
6834
- message.app_url = reader.string();
6924
+ message.app_id = reader.string();
6835
6925
  continue;
6836
6926
  case 13:
6837
6927
  if (tag !== 104) {
@@ -6878,7 +6968,7 @@ export const ChannelUpdatedEvent = {
6878
6968
  meeting_code: isSet(object.meeting_code) ? globalThis.String(object.meeting_code) : "",
6879
6969
  is_error: isSet(object.is_error) ? globalThis.Boolean(object.is_error) : false,
6880
6970
  channel_private: isSet(object.channel_private) ? globalThis.Boolean(object.channel_private) : false,
6881
- app_url: isSet(object.app_url) ? globalThis.String(object.app_url) : "",
6971
+ app_id: isSet(object.app_id) ? globalThis.String(object.app_id) : "",
6882
6972
  e2ee: isSet(object.e2ee) ? globalThis.Number(object.e2ee) : 0,
6883
6973
  topic: isSet(object.topic) ? globalThis.String(object.topic) : "",
6884
6974
  age_restricted: isSet(object.age_restricted) ? globalThis.Number(object.age_restricted) : 0,
@@ -6920,8 +7010,8 @@ export const ChannelUpdatedEvent = {
6920
7010
  if (message.channel_private !== false) {
6921
7011
  obj.channel_private = message.channel_private;
6922
7012
  }
6923
- if (message.app_url !== "") {
6924
- obj.app_url = message.app_url;
7013
+ if (message.app_id !== "") {
7014
+ obj.app_id = message.app_id;
6925
7015
  }
6926
7016
  if (message.e2ee !== 0) {
6927
7017
  obj.e2ee = Math.round(message.e2ee);
@@ -6953,7 +7043,7 @@ export const ChannelUpdatedEvent = {
6953
7043
  message.meeting_code = object.meeting_code ?? "";
6954
7044
  message.is_error = object.is_error ?? false;
6955
7045
  message.channel_private = object.channel_private ?? false;
6956
- message.app_url = object.app_url ?? "";
7046
+ message.app_id = object.app_id ?? "";
6957
7047
  message.e2ee = object.e2ee ?? 0;
6958
7048
  message.topic = object.topic ?? "";
6959
7049
  message.age_restricted = object.age_restricted ?? 0;
@@ -8325,6 +8415,8 @@ function createBaseUserProfileRedis() {
8325
8415
  pubkey: "",
8326
8416
  mezon_id: "",
8327
8417
  app_token: "",
8418
+ app_url: "",
8419
+ is_bot: false,
8328
8420
  };
8329
8421
  }
8330
8422
  export const UserProfileRedis = {
@@ -8374,6 +8466,12 @@ export const UserProfileRedis = {
8374
8466
  if (message.app_token !== "") {
8375
8467
  writer.uint32(122).string(message.app_token);
8376
8468
  }
8469
+ if (message.app_url !== "") {
8470
+ writer.uint32(130).string(message.app_url);
8471
+ }
8472
+ if (message.is_bot !== false) {
8473
+ writer.uint32(136).bool(message.is_bot);
8474
+ }
8377
8475
  return writer;
8378
8476
  },
8379
8477
  decode(input, length) {
@@ -8473,6 +8571,18 @@ export const UserProfileRedis = {
8473
8571
  }
8474
8572
  message.app_token = reader.string();
8475
8573
  continue;
8574
+ case 16:
8575
+ if (tag !== 130) {
8576
+ break;
8577
+ }
8578
+ message.app_url = reader.string();
8579
+ continue;
8580
+ case 17:
8581
+ if (tag !== 136) {
8582
+ break;
8583
+ }
8584
+ message.is_bot = reader.bool();
8585
+ continue;
8476
8586
  }
8477
8587
  if ((tag & 7) === 4 || tag === 0) {
8478
8588
  break;
@@ -8502,6 +8612,8 @@ export const UserProfileRedis = {
8502
8612
  pubkey: isSet(object.pubkey) ? globalThis.String(object.pubkey) : "",
8503
8613
  mezon_id: isSet(object.mezon_id) ? globalThis.String(object.mezon_id) : "",
8504
8614
  app_token: isSet(object.app_token) ? globalThis.String(object.app_token) : "",
8615
+ app_url: isSet(object.app_url) ? globalThis.String(object.app_url) : "",
8616
+ is_bot: isSet(object.is_bot) ? globalThis.Boolean(object.is_bot) : false,
8505
8617
  };
8506
8618
  },
8507
8619
  toJSON(message) {
@@ -8551,6 +8663,12 @@ export const UserProfileRedis = {
8551
8663
  if (message.app_token !== "") {
8552
8664
  obj.app_token = message.app_token;
8553
8665
  }
8666
+ if (message.app_url !== "") {
8667
+ obj.app_url = message.app_url;
8668
+ }
8669
+ if (message.is_bot !== false) {
8670
+ obj.is_bot = message.is_bot;
8671
+ }
8554
8672
  return obj;
8555
8673
  },
8556
8674
  create(base) {
@@ -8573,6 +8691,8 @@ export const UserProfileRedis = {
8573
8691
  message.pubkey = object.pubkey ?? "";
8574
8692
  message.mezon_id = object.mezon_id ?? "";
8575
8693
  message.app_token = object.app_token ?? "";
8694
+ message.app_url = object.app_url ?? "";
8695
+ message.is_bot = object.is_bot ?? false;
8576
8696
  return message;
8577
8697
  },
8578
8698
  };
@@ -10136,6 +10256,150 @@ export const UnpinMessageEvent = {
10136
10256
  return message;
10137
10257
  },
10138
10258
  };
10259
+ function createBaseHandleParticipantMeetStateEvent() {
10260
+ return { clan_id: "", channel_id: "", display_name: "", state: 0 };
10261
+ }
10262
+ export const HandleParticipantMeetStateEvent = {
10263
+ encode(message, writer = _m0.Writer.create()) {
10264
+ if (message.clan_id !== "") {
10265
+ writer.uint32(10).string(message.clan_id);
10266
+ }
10267
+ if (message.channel_id !== "") {
10268
+ writer.uint32(18).string(message.channel_id);
10269
+ }
10270
+ if (message.display_name !== "") {
10271
+ writer.uint32(26).string(message.display_name);
10272
+ }
10273
+ if (message.state !== 0) {
10274
+ writer.uint32(32).int32(message.state);
10275
+ }
10276
+ return writer;
10277
+ },
10278
+ decode(input, length) {
10279
+ const reader = input instanceof _m0.Reader ? input : _m0.Reader.create(input);
10280
+ let end = length === undefined ? reader.len : reader.pos + length;
10281
+ const message = createBaseHandleParticipantMeetStateEvent();
10282
+ while (reader.pos < end) {
10283
+ const tag = reader.uint32();
10284
+ switch (tag >>> 3) {
10285
+ case 1:
10286
+ if (tag !== 10) {
10287
+ break;
10288
+ }
10289
+ message.clan_id = reader.string();
10290
+ continue;
10291
+ case 2:
10292
+ if (tag !== 18) {
10293
+ break;
10294
+ }
10295
+ message.channel_id = reader.string();
10296
+ continue;
10297
+ case 3:
10298
+ if (tag !== 26) {
10299
+ break;
10300
+ }
10301
+ message.display_name = reader.string();
10302
+ continue;
10303
+ case 4:
10304
+ if (tag !== 32) {
10305
+ break;
10306
+ }
10307
+ message.state = reader.int32();
10308
+ continue;
10309
+ }
10310
+ if ((tag & 7) === 4 || tag === 0) {
10311
+ break;
10312
+ }
10313
+ reader.skipType(tag & 7);
10314
+ }
10315
+ return message;
10316
+ },
10317
+ fromJSON(object) {
10318
+ return {
10319
+ clan_id: isSet(object.clan_id) ? globalThis.String(object.clan_id) : "",
10320
+ channel_id: isSet(object.channel_id) ? globalThis.String(object.channel_id) : "",
10321
+ display_name: isSet(object.display_name) ? globalThis.String(object.display_name) : "",
10322
+ state: isSet(object.state) ? globalThis.Number(object.state) : 0,
10323
+ };
10324
+ },
10325
+ toJSON(message) {
10326
+ const obj = {};
10327
+ if (message.clan_id !== "") {
10328
+ obj.clan_id = message.clan_id;
10329
+ }
10330
+ if (message.channel_id !== "") {
10331
+ obj.channel_id = message.channel_id;
10332
+ }
10333
+ if (message.display_name !== "") {
10334
+ obj.display_name = message.display_name;
10335
+ }
10336
+ if (message.state !== 0) {
10337
+ obj.state = Math.round(message.state);
10338
+ }
10339
+ return obj;
10340
+ },
10341
+ create(base) {
10342
+ return HandleParticipantMeetStateEvent.fromPartial(base ?? {});
10343
+ },
10344
+ fromPartial(object) {
10345
+ const message = createBaseHandleParticipantMeetStateEvent();
10346
+ message.clan_id = object.clan_id ?? "";
10347
+ message.channel_id = object.channel_id ?? "";
10348
+ message.display_name = object.display_name ?? "";
10349
+ message.state = object.state ?? 0;
10350
+ return message;
10351
+ },
10352
+ };
10353
+ function createBaseDeleteAccountEvent() {
10354
+ return { user_id: "" };
10355
+ }
10356
+ export const DeleteAccountEvent = {
10357
+ encode(message, writer = _m0.Writer.create()) {
10358
+ if (message.user_id !== "") {
10359
+ writer.uint32(10).string(message.user_id);
10360
+ }
10361
+ return writer;
10362
+ },
10363
+ decode(input, length) {
10364
+ const reader = input instanceof _m0.Reader ? input : _m0.Reader.create(input);
10365
+ let end = length === undefined ? reader.len : reader.pos + length;
10366
+ const message = createBaseDeleteAccountEvent();
10367
+ while (reader.pos < end) {
10368
+ const tag = reader.uint32();
10369
+ switch (tag >>> 3) {
10370
+ case 1:
10371
+ if (tag !== 10) {
10372
+ break;
10373
+ }
10374
+ message.user_id = reader.string();
10375
+ continue;
10376
+ }
10377
+ if ((tag & 7) === 4 || tag === 0) {
10378
+ break;
10379
+ }
10380
+ reader.skipType(tag & 7);
10381
+ }
10382
+ return message;
10383
+ },
10384
+ fromJSON(object) {
10385
+ return { user_id: isSet(object.user_id) ? globalThis.String(object.user_id) : "" };
10386
+ },
10387
+ toJSON(message) {
10388
+ const obj = {};
10389
+ if (message.user_id !== "") {
10390
+ obj.user_id = message.user_id;
10391
+ }
10392
+ return obj;
10393
+ },
10394
+ create(base) {
10395
+ return DeleteAccountEvent.fromPartial(base ?? {});
10396
+ },
10397
+ fromPartial(object) {
10398
+ const message = createBaseDeleteAccountEvent();
10399
+ message.user_id = object.user_id ?? "";
10400
+ return message;
10401
+ },
10402
+ };
10139
10403
  function toTimestamp(date) {
10140
10404
  const seconds = Math.trunc(date.getTime() / 1_000);
10141
10405
  const nanos = (date.getTime() % 1_000) * 1_000_000;