@mtcute/core 0.29.7 → 0.30.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.
Files changed (90) hide show
  1. package/highlevel/client.d.cts +4 -6
  2. package/highlevel/client.d.ts +4 -6
  3. package/highlevel/methods/chats/join-chat.cjs +38 -16
  4. package/highlevel/methods/chats/join-chat.d.cts +20 -6
  5. package/highlevel/methods/chats/join-chat.d.ts +20 -6
  6. package/highlevel/methods/chats/join-chat.js +38 -16
  7. package/highlevel/methods/chats/save-draft.d.cts +4 -1
  8. package/highlevel/methods/chats/save-draft.d.ts +4 -1
  9. package/highlevel/methods.d.cts +2 -0
  10. package/highlevel/methods.d.ts +2 -0
  11. package/highlevel/storage/service/peers.cjs +1 -0
  12. package/highlevel/storage/service/peers.js +1 -0
  13. package/highlevel/types/files/utils.d.cts +1 -1
  14. package/highlevel/types/files/utils.d.ts +1 -1
  15. package/highlevel/types/messages/index.d.cts +1 -0
  16. package/highlevel/types/messages/index.d.ts +1 -0
  17. package/highlevel/types/messages/message.cjs +5 -0
  18. package/highlevel/types/messages/message.d.cts +3 -0
  19. package/highlevel/types/messages/message.d.ts +3 -0
  20. package/highlevel/types/messages/message.js +5 -0
  21. package/highlevel/types/messages/rich-message.cjs +50 -0
  22. package/highlevel/types/messages/rich-message.d.cts +18 -0
  23. package/highlevel/types/messages/rich-message.d.ts +18 -0
  24. package/highlevel/types/messages/rich-message.js +45 -0
  25. package/highlevel/types/peers/full-chat.cjs +6 -0
  26. package/highlevel/types/peers/full-chat.d.cts +2 -0
  27. package/highlevel/types/peers/full-chat.d.ts +2 -0
  28. package/highlevel/types/peers/full-chat.js +6 -0
  29. package/highlevel/types/peers/user.cjs +4 -0
  30. package/highlevel/types/peers/user.d.cts +2 -0
  31. package/highlevel/types/peers/user.d.ts +2 -0
  32. package/highlevel/types/peers/user.js +4 -0
  33. package/highlevel/types/updates/user-typing-update.cjs +2 -0
  34. package/highlevel/types/updates/user-typing-update.js +2 -0
  35. package/highlevel/updates/manager.cjs +191 -0
  36. package/highlevel/updates/manager.js +191 -0
  37. package/highlevel/utils/inspectable.cjs +1 -0
  38. package/highlevel/utils/inspectable.d.cts +1 -0
  39. package/highlevel/utils/inspectable.d.ts +1 -0
  40. package/highlevel/utils/inspectable.js +1 -0
  41. package/index.cjs +2 -0
  42. package/index.js +2 -0
  43. package/network/flood-control.cjs +149 -0
  44. package/network/flood-control.d.cts +79 -0
  45. package/network/flood-control.d.ts +79 -0
  46. package/network/flood-control.js +144 -0
  47. package/network/flood-control.test.d.cts +1 -0
  48. package/network/flood-control.test.d.ts +1 -0
  49. package/network/mtproto-session.cjs +1 -21
  50. package/network/mtproto-session.d.cts +1 -5
  51. package/network/mtproto-session.d.ts +1 -5
  52. package/network/mtproto-session.js +2 -22
  53. package/network/multi-session-connection.cjs +26 -16
  54. package/network/multi-session-connection.d.cts +1 -1
  55. package/network/multi-session-connection.d.ts +1 -1
  56. package/network/multi-session-connection.js +26 -16
  57. package/network/multi-session-connection.test.d.cts +1 -0
  58. package/network/multi-session-connection.test.d.ts +1 -0
  59. package/network/network-manager.cjs +3 -2
  60. package/network/network-manager.d.cts +12 -0
  61. package/network/network-manager.d.ts +12 -0
  62. package/network/network-manager.js +3 -2
  63. package/network/persistent-connection.cjs +25 -1
  64. package/network/persistent-connection.d.cts +5 -0
  65. package/network/persistent-connection.d.ts +5 -0
  66. package/network/persistent-connection.js +25 -1
  67. package/network/session-connection.cjs +5 -10
  68. package/network/session-connection.d.cts +0 -2
  69. package/network/session-connection.d.ts +0 -2
  70. package/network/session-connection.js +5 -10
  71. package/package.json +1 -1
  72. package/tl/api-schema.json +1 -1
  73. package/tl/binary/reader.cjs +176 -26
  74. package/tl/binary/reader.js +176 -26
  75. package/tl/binary/writer.cjs +439 -20
  76. package/tl/binary/writer.js +439 -20
  77. package/tl/compat/reader.cjs +23 -0
  78. package/tl/compat/reader.js +23 -0
  79. package/tl/index.d.cts +414 -14
  80. package/tl/index.d.ts +414 -14
  81. package/tl/inner-tl.cjs +20 -8
  82. package/tl/inner-tl.js +20 -8
  83. package/utils/binary/compat.cjs +79 -0
  84. package/utils/binary/compat.js +79 -0
  85. package/utils/index.d.cts +1 -0
  86. package/utils/index.d.ts +1 -0
  87. package/utils/long-utils.cjs +10 -0
  88. package/utils/long-utils.js +10 -0
  89. package/utils.cjs +7 -0
  90. package/utils.js +8 -1
@@ -562,6 +562,7 @@ var m = {
562
562
  if (v.botForumCanManageTopics === true) flags2 |= 131072;
563
563
  if (v.botCanManageBots === true) flags2 |= 262144;
564
564
  if (v.botGuestchat === true) flags2 |= 524288;
565
+ if (v.botGuard === true) flags2 |= 1048576;
565
566
  w.uint(flags2);
566
567
  w.int53(h(v, "id"));
567
568
  if (_accessHash) w.long(v.accessHash);
@@ -819,7 +820,7 @@ var m = {
819
820
  if (_reactionsLimit) w.int(v.reactionsLimit);
820
821
  },
821
822
  "channelFull": function(w, v) {
822
- w.uint(3839931037);
823
+ w.uint(2689502522);
823
824
  var flags = 0;
824
825
  var _participantsCount = v.participantsCount !== void 0;
825
826
  if (_participantsCount) flags |= 1;
@@ -916,6 +917,8 @@ var m = {
916
917
  if (_sendPaidMessagesStars) flags2 |= 2097152;
917
918
  var _mainTab = v.mainTab !== void 0;
918
919
  if (_mainTab) flags2 |= 4194304;
920
+ var _guardBotId = v.guardBotId !== void 0;
921
+ if (_guardBotId) flags2 |= 8388608;
919
922
  w.uint(flags2);
920
923
  w.int53(h(v, "id"));
921
924
  w.string(h(v, "about"));
@@ -962,6 +965,7 @@ var m = {
962
965
  if (_stargiftsCount) w.int(v.stargiftsCount);
963
966
  if (_sendPaidMessagesStars) w.long(v.sendPaidMessagesStars);
964
967
  if (_mainTab) w.object(v.mainTab);
968
+ if (_guardBotId) w.int53(v.guardBotId);
965
969
  },
966
970
  "chatParticipant": function(w, v) {
967
971
  w.uint(954703838);
@@ -1033,7 +1037,7 @@ var m = {
1033
1037
  if (_peerId) w.object(v.peerId);
1034
1038
  },
1035
1039
  "message": function(w, v) {
1036
- w.uint(2515496747);
1040
+ w.uint(1979759059);
1037
1041
  var flags = 0;
1038
1042
  if (v.out === true) flags |= 2;
1039
1043
  var _fwdFrom = v.fwdFrom !== void 0;
@@ -1108,6 +1112,8 @@ var m = {
1108
1112
  if (_summaryFromLanguage) flags2 |= 2048;
1109
1113
  var _fromRank = v.fromRank !== void 0;
1110
1114
  if (_fromRank) flags2 |= 4096;
1115
+ var _richMessage = v.richMessage !== void 0;
1116
+ if (_richMessage) flags2 |= 8192;
1111
1117
  var _guestchatViaFrom = v.guestchatViaFrom !== void 0;
1112
1118
  if (_guestchatViaFrom) flags2 |= 524288;
1113
1119
  w.uint(flags2);
@@ -1144,6 +1150,7 @@ var m = {
1144
1150
  if (_suggestedPost) w.object(v.suggestedPost);
1145
1151
  if (_scheduleRepeatPeriod) w.int(v.scheduleRepeatPeriod);
1146
1152
  if (_summaryFromLanguage) w.string(v.summaryFromLanguage);
1153
+ if (_richMessage) w.object(v.richMessage);
1147
1154
  },
1148
1155
  "messageService": function(w, v) {
1149
1156
  w.uint(2055212554);
@@ -3328,13 +3335,18 @@ var m = {
3328
3335
  w.vector(w.int53, h(v, "recentRequesters"));
3329
3336
  },
3330
3337
  "updateBotChatInviteRequester": function(w, v) {
3331
- w.uint(299870598);
3338
+ w.uint(2092125561);
3339
+ var flags = 0;
3340
+ var _queryId = v.queryId !== void 0;
3341
+ if (_queryId) flags |= 1;
3342
+ w.uint(flags);
3332
3343
  w.object(h(v, "peer"));
3333
3344
  w.int(h(v, "date"));
3334
3345
  w.int53(h(v, "userId"));
3335
3346
  w.string(h(v, "about"));
3336
3347
  w.object(h(v, "invite"));
3337
3348
  w.int(h(v, "qts"));
3349
+ if (_queryId) w.long(v.queryId);
3338
3350
  },
3339
3351
  "updateMessageReactions": function(w, v) {
3340
3352
  w.uint(506035194);
@@ -6064,7 +6076,7 @@ var m = {
6064
6076
  if (_date) w.int(v.date);
6065
6077
  },
6066
6078
  "draftMessage": function(w, v) {
6067
- w.uint(2531960299);
6079
+ w.uint(1627271828);
6068
6080
  var flags = 0;
6069
6081
  if (v.noWebpage === true) flags |= 2;
6070
6082
  var _entities = v.entities && v.entities.length;
@@ -6078,6 +6090,8 @@ var m = {
6078
6090
  if (_effect) flags |= 128;
6079
6091
  var _suggestedPost = v.suggestedPost !== void 0;
6080
6092
  if (_suggestedPost) flags |= 256;
6093
+ var _richMessage = v.richMessage !== void 0;
6094
+ if (_richMessage) flags |= 512;
6081
6095
  w.uint(flags);
6082
6096
  if (_replyTo) w.object(v.replyTo);
6083
6097
  w.string(h(v, "message"));
@@ -6086,6 +6100,7 @@ var m = {
6086
6100
  w.int(h(v, "date"));
6087
6101
  if (_effect) w.long(v.effect);
6088
6102
  if (_suggestedPost) w.object(v.suggestedPost);
6103
+ if (_richMessage) w.object(v.richMessage);
6089
6104
  },
6090
6105
  "messages.featuredStickersNotModified": function(w, v) {
6091
6106
  w.uint(3336309862);
@@ -6329,6 +6344,7 @@ var m = {
6329
6344
  var _webpageId = v.webpageId !== void 0;
6330
6345
  var _flags_0 = _url || _webpageId;
6331
6346
  if (_flags_0) flags |= 1;
6347
+ if (v.spoiler === true) flags |= 2;
6332
6348
  w.uint(flags);
6333
6349
  w.long(h(v, "photoId"));
6334
6350
  w.object(h(v, "caption"));
@@ -6340,6 +6356,7 @@ var m = {
6340
6356
  var flags = 0;
6341
6357
  if (v.autoplay === true) flags |= 1;
6342
6358
  if (v.loop === true) flags |= 2;
6359
+ if (v.spoiler === true) flags |= 4;
6343
6360
  w.uint(flags);
6344
6361
  w.long(h(v, "videoId"));
6345
6362
  w.object(h(v, "caption"));
@@ -6414,8 +6431,17 @@ var m = {
6414
6431
  w.vector(w.object, h(v, "rows"));
6415
6432
  },
6416
6433
  "pageBlockOrderedList": function(w, v) {
6417
- w.uint(2592793057);
6434
+ w.uint(534181569);
6435
+ var flags = 0;
6436
+ var _start = v.start !== void 0;
6437
+ if (_start) flags |= 1;
6438
+ var _type = v.type !== void 0;
6439
+ if (_type) flags |= 2;
6440
+ if (v.reversed === true) flags |= 4;
6441
+ w.uint(flags);
6418
6442
  w.vector(w.object, h(v, "items"));
6443
+ if (_start) w.int(v.start);
6444
+ if (_type) w.string(v.type);
6419
6445
  },
6420
6446
  "pageBlockDetails": function(w, v) {
6421
6447
  w.uint(1987480557);
@@ -7726,22 +7752,54 @@ var m = {
7726
7752
  w.object(h(v, "credit"));
7727
7753
  },
7728
7754
  "pageListItemText": function(w, v) {
7729
- w.uint(3106911949);
7755
+ w.uint(794323004);
7756
+ var flags = 0;
7757
+ if (v.checkbox === true) flags |= 1;
7758
+ if (v.checked === true) flags |= 2;
7759
+ w.uint(flags);
7730
7760
  w.object(h(v, "text"));
7731
7761
  },
7732
7762
  "pageListItemBlocks": function(w, v) {
7733
- w.uint(635466748);
7763
+ w.uint(1674209194);
7764
+ var flags = 0;
7765
+ if (v.checkbox === true) flags |= 1;
7766
+ if (v.checked === true) flags |= 2;
7767
+ w.uint(flags);
7734
7768
  w.vector(w.object, h(v, "blocks"));
7735
7769
  },
7736
7770
  "pageListOrderedItemText": function(w, v) {
7737
- w.uint(1577484359);
7738
- w.string(h(v, "num"));
7771
+ w.uint(352522633);
7772
+ var flags = 0;
7773
+ if (v.checkbox === true) flags |= 1;
7774
+ if (v.checked === true) flags |= 2;
7775
+ var _num = v.num !== void 0;
7776
+ if (_num) flags |= 4;
7777
+ var _value = v.value !== void 0;
7778
+ if (_value) flags |= 8;
7779
+ var _type = v.type !== void 0;
7780
+ if (_type) flags |= 16;
7781
+ w.uint(flags);
7782
+ if (_num) w.string(v.num);
7739
7783
  w.object(h(v, "text"));
7784
+ if (_value) w.int(v.value);
7785
+ if (_type) w.string(v.type);
7740
7786
  },
7741
7787
  "pageListOrderedItemBlocks": function(w, v) {
7742
- w.uint(2564655414);
7743
- w.string(h(v, "num"));
7788
+ w.uint(2415056368);
7789
+ var flags = 0;
7790
+ if (v.checkbox === true) flags |= 1;
7791
+ if (v.checked === true) flags |= 2;
7792
+ var _num = v.num !== void 0;
7793
+ if (_num) flags |= 4;
7794
+ var _value = v.value !== void 0;
7795
+ if (_value) flags |= 8;
7796
+ var _type = v.type !== void 0;
7797
+ if (_type) flags |= 16;
7798
+ w.uint(flags);
7799
+ if (_num) w.string(v.num);
7744
7800
  w.vector(w.object, h(v, "blocks"));
7801
+ if (_value) w.int(v.value);
7802
+ if (_type) w.string(v.type);
7745
7803
  },
7746
7804
  "pageRelatedArticle": function(w, v) {
7747
7805
  w.uint(3012615176);
@@ -8653,6 +8711,7 @@ var m = {
8653
8711
  if (_todoItemId) flags |= 2048;
8654
8712
  var _pollOption = v.pollOption !== void 0;
8655
8713
  if (_pollOption) flags |= 4096;
8714
+ if (v.replyToEphemeral === true) flags |= 8192;
8656
8715
  w.uint(flags);
8657
8716
  if (_replyToMsgId) w.int(v.replyToMsgId);
8658
8717
  if (_replyToPeerId) w.object(v.replyToPeerId);
@@ -9264,6 +9323,7 @@ var m = {
9264
9323
  if (_queryId) flags |= 1;
9265
9324
  if (v.fullsize === true) flags |= 2;
9266
9325
  if (v.fullscreen === true) flags |= 4;
9326
+ if (v.sameOrigin === true) flags |= 8;
9267
9327
  w.uint(flags);
9268
9328
  if (_queryId) w.long(v.queryId);
9269
9329
  w.string(h(v, "url"));
@@ -10893,12 +10953,21 @@ var m = {
10893
10953
  w.uint(1603398491);
10894
10954
  },
10895
10955
  "connectedBot": function(w, v) {
10896
- w.uint(3445908332);
10956
+ w.uint(54448129);
10897
10957
  var flags = 0;
10958
+ var _device = v.device !== void 0;
10959
+ if (_device) flags |= 1;
10960
+ var _date = v.date !== void 0;
10961
+ if (_date) flags |= 2;
10962
+ var _location = v.location !== void 0;
10963
+ if (_location) flags |= 4;
10898
10964
  w.uint(flags);
10899
10965
  w.int53(h(v, "botId"));
10900
10966
  w.object(h(v, "recipients"));
10901
10967
  w.object(h(v, "rights"));
10968
+ if (_device) w.string(v.device);
10969
+ if (_date) w.int(v.date);
10970
+ if (_location) w.string(v.location);
10902
10971
  },
10903
10972
  "account.connectedBots": function(w, v) {
10904
10973
  w.uint(400029819);
@@ -12617,6 +12686,288 @@ var m = {
12617
12686
  w.uint(flags);
12618
12687
  if (_addUsers) w.vector(w.object, v.addUsers);
12619
12688
  },
12689
+ "updateJoinChatWebViewDecision": function(w, v) {
12690
+ w.uint(3182198384);
12691
+ w.object(h(v, "peer"));
12692
+ w.long(h(v, "queryId"));
12693
+ w.object(h(v, "result"));
12694
+ },
12695
+ "updateNewBotConnection": function(w, v) {
12696
+ w.uint(2988475302);
12697
+ var flags = 0;
12698
+ if (v.confirmed === true) flags |= 1;
12699
+ var _date = v.date !== void 0;
12700
+ var _device = v.device !== void 0;
12701
+ var _location = v.location !== void 0;
12702
+ var _flags_1 = _date || _device || _location;
12703
+ if (_flags_1) flags |= 2;
12704
+ w.uint(flags);
12705
+ w.int53(h(v, "botId"));
12706
+ if (_flags_1) w.int(v.date);
12707
+ if (_flags_1) w.string(v.device);
12708
+ if (_flags_1) w.string(v.location);
12709
+ },
12710
+ "updateWebBrowserSettings": function(w, v) {
12711
+ w.uint(3281660638);
12712
+ var flags = 0;
12713
+ if (v.openExternalBrowser === true) flags |= 1;
12714
+ if (v.displayCloseButton === true) flags |= 2;
12715
+ w.uint(flags);
12716
+ },
12717
+ "updateWebBrowserException": function(w, v) {
12718
+ w.uint(335872721);
12719
+ var flags = 0;
12720
+ var _openExternalBrowser = v.openExternalBrowser !== void 0;
12721
+ if (_openExternalBrowser) flags |= 1;
12722
+ if (v.delete === true) flags |= 2;
12723
+ w.uint(flags);
12724
+ if (_openExternalBrowser) w.boolean(v.openExternalBrowser);
12725
+ w.object(h(v, "exception"));
12726
+ },
12727
+ "inputSendMessageRichMessageDraftAction": function(w, v) {
12728
+ w.uint(3803331409);
12729
+ w.long(h(v, "randomId"));
12730
+ w.object(h(v, "richMessage"));
12731
+ },
12732
+ "sendMessageRichMessageDraftAction": function(w, v) {
12733
+ w.uint(2731222265);
12734
+ w.long(h(v, "randomId"));
12735
+ w.object(h(v, "richMessage"));
12736
+ },
12737
+ "inputBotInlineMessageRichMessage": function(w, v) {
12738
+ w.uint(3023959404);
12739
+ var flags = 0;
12740
+ var _replyMarkup = v.replyMarkup !== void 0;
12741
+ if (_replyMarkup) flags |= 4;
12742
+ w.uint(flags);
12743
+ if (_replyMarkup) w.object(v.replyMarkup);
12744
+ w.object(h(v, "richMessage"));
12745
+ },
12746
+ "botInlineMessageRichMessage": function(w, v) {
12747
+ w.uint(174161531);
12748
+ var flags = 0;
12749
+ var _replyMarkup = v.replyMarkup !== void 0;
12750
+ if (_replyMarkup) flags |= 4;
12751
+ w.uint(flags);
12752
+ if (_replyMarkup) w.object(v.replyMarkup);
12753
+ w.object(h(v, "richMessage"));
12754
+ },
12755
+ "textMath": function(w, v) {
12756
+ w.uint(2637081751);
12757
+ w.string(h(v, "source"));
12758
+ },
12759
+ "textCustomEmoji": function(w, v) {
12760
+ w.uint(2724288192);
12761
+ w.long(h(v, "documentId"));
12762
+ w.string(h(v, "alt"));
12763
+ },
12764
+ "textSpoiler": function(w, v) {
12765
+ w.uint(1277844834);
12766
+ w.object(h(v, "text"));
12767
+ },
12768
+ "textMention": function(w, v) {
12769
+ w.uint(3441741636);
12770
+ w.object(h(v, "text"));
12771
+ },
12772
+ "textHashtag": function(w, v) {
12773
+ w.uint(1368728810);
12774
+ w.object(h(v, "text"));
12775
+ },
12776
+ "textBotCommand": function(w, v) {
12777
+ w.uint(50276819);
12778
+ w.object(h(v, "text"));
12779
+ },
12780
+ "textCashtag": function(w, v) {
12781
+ w.uint(2073958401);
12782
+ w.object(h(v, "text"));
12783
+ },
12784
+ "textAutoUrl": function(w, v) {
12785
+ w.uint(2892661674);
12786
+ w.object(h(v, "text"));
12787
+ },
12788
+ "textAutoEmail": function(w, v) {
12789
+ w.uint(3310789725);
12790
+ w.object(h(v, "text"));
12791
+ },
12792
+ "textAutoPhone": function(w, v) {
12793
+ w.uint(616720265);
12794
+ w.object(h(v, "text"));
12795
+ },
12796
+ "textBankCard": function(w, v) {
12797
+ w.uint(3109454125);
12798
+ w.object(h(v, "text"));
12799
+ },
12800
+ "textMentionName": function(w, v) {
12801
+ w.uint(27917308);
12802
+ w.object(h(v, "text"));
12803
+ w.int53(h(v, "userId"));
12804
+ },
12805
+ "textDate": function(w, v) {
12806
+ w.uint(2780061227);
12807
+ var flags = 0;
12808
+ if (v.relative === true) flags |= 1;
12809
+ if (v.shortTime === true) flags |= 2;
12810
+ if (v.longTime === true) flags |= 4;
12811
+ if (v.shortDate === true) flags |= 8;
12812
+ if (v.longDate === true) flags |= 16;
12813
+ if (v.dayOfWeek === true) flags |= 32;
12814
+ w.uint(flags);
12815
+ w.object(h(v, "text"));
12816
+ w.int(h(v, "date"));
12817
+ },
12818
+ "pageBlockHeading1": function(w, v) {
12819
+ w.uint(3137275695);
12820
+ w.object(h(v, "text"));
12821
+ },
12822
+ "pageBlockHeading2": function(w, v) {
12823
+ w.uint(158018284);
12824
+ w.object(h(v, "text"));
12825
+ },
12826
+ "pageBlockHeading3": function(w, v) {
12827
+ w.uint(1743204781);
12828
+ w.object(h(v, "text"));
12829
+ },
12830
+ "pageBlockHeading4": function(w, v) {
12831
+ w.uint(3039983403);
12832
+ w.object(h(v, "text"));
12833
+ },
12834
+ "pageBlockHeading5": function(w, v) {
12835
+ w.uint(3686689898);
12836
+ w.object(h(v, "text"));
12837
+ },
12838
+ "pageBlockHeading6": function(w, v) {
12839
+ w.uint(1747599785);
12840
+ w.object(h(v, "text"));
12841
+ },
12842
+ "pageBlockMath": function(w, v) {
12843
+ w.uint(1493699616);
12844
+ w.string(h(v, "source"));
12845
+ },
12846
+ "pageBlockThinking": function(w, v) {
12847
+ w.uint(1009361890);
12848
+ w.object(h(v, "text"));
12849
+ },
12850
+ "inputPageBlockMap": function(w, v) {
12851
+ w.uint(1464557951);
12852
+ w.object(h(v, "geo"));
12853
+ w.int(h(v, "zoom"));
12854
+ w.int(h(v, "w"));
12855
+ w.int(h(v, "h"));
12856
+ w.object(h(v, "caption"));
12857
+ },
12858
+ "pageBlockBlockquoteBlocks": function(w, v) {
12859
+ w.uint(242108356);
12860
+ w.vector(w.object, h(v, "blocks"));
12861
+ w.object(h(v, "caption"));
12862
+ },
12863
+ "messages.chatInviteJoinResultOk": function(w, v) {
12864
+ w.uint(1146512295);
12865
+ w.object(h(v, "updates"));
12866
+ },
12867
+ "messages.chatInviteJoinResultWebView": function(w, v) {
12868
+ w.uint(793887543);
12869
+ w.int53(h(v, "botId"));
12870
+ w.object(h(v, "webview"));
12871
+ w.vector(w.object, h(v, "users"));
12872
+ },
12873
+ "joinChatBotResultApproved": function(w) {
12874
+ w.uint(2920622697);
12875
+ },
12876
+ "joinChatBotResultDeclined": function(w) {
12877
+ w.uint(251265428);
12878
+ },
12879
+ "joinChatBotResultQueued": function(w) {
12880
+ w.uint(2560862272);
12881
+ },
12882
+ "joinChatBotResultWebView": function(w, v) {
12883
+ w.uint(3605248019);
12884
+ w.string(h(v, "url"));
12885
+ },
12886
+ "webDomainException": function(w, v) {
12887
+ w.uint(2470225303);
12888
+ var flags = 0;
12889
+ var _favicon = v.favicon !== void 0;
12890
+ if (_favicon) flags |= 1;
12891
+ w.uint(flags);
12892
+ w.string(h(v, "domain"));
12893
+ w.string(h(v, "url"));
12894
+ w.string(h(v, "title"));
12895
+ if (_favicon) w.long(v.favicon);
12896
+ },
12897
+ "account.webBrowserSettingsNotModified": function(w) {
12898
+ w.uint(3273428814);
12899
+ },
12900
+ "account.webBrowserSettings": function(w, v) {
12901
+ w.uint(2045480115);
12902
+ var flags = 0;
12903
+ if (v.openExternalBrowser === true) flags |= 1;
12904
+ if (v.displayCloseButton === true) flags |= 2;
12905
+ w.uint(flags);
12906
+ w.vector(w.object, h(v, "externalExceptions"));
12907
+ w.vector(w.object, h(v, "inappExceptions"));
12908
+ w.long(h(v, "hash"));
12909
+ },
12910
+ "richMessage": function(w, v) {
12911
+ w.uint(3136527755);
12912
+ var flags = 0;
12913
+ if (v.rtl === true) flags |= 1;
12914
+ if (v.part === true) flags |= 2;
12915
+ w.uint(flags);
12916
+ w.vector(w.object, h(v, "blocks"));
12917
+ w.vector(w.object, h(v, "photos"));
12918
+ w.vector(w.object, h(v, "documents"));
12919
+ },
12920
+ "inputRichMessage": function(w, v) {
12921
+ w.uint(3838069244);
12922
+ var flags = 0;
12923
+ if (v.rtl === true) flags |= 1;
12924
+ if (v.noautolink === true) flags |= 2;
12925
+ var _photos = v.photos && v.photos.length;
12926
+ if (_photos) flags |= 4;
12927
+ var _documents = v.documents && v.documents.length;
12928
+ if (_documents) flags |= 8;
12929
+ var _users = v.users && v.users.length;
12930
+ if (_users) flags |= 16;
12931
+ w.uint(flags);
12932
+ w.vector(w.object, h(v, "blocks"));
12933
+ if (_photos) w.vector(w.object, v.photos);
12934
+ if (_documents) w.vector(w.object, v.documents);
12935
+ if (_users) w.vector(w.object, v.users);
12936
+ },
12937
+ "inputRichMessageHTML": function(w, v) {
12938
+ w.uint(3572151633);
12939
+ var flags = 0;
12940
+ if (v.rtl === true) flags |= 1;
12941
+ if (v.noautolink === true) flags |= 2;
12942
+ var _photos = v.photos && v.photos.length;
12943
+ if (_photos) flags |= 4;
12944
+ var _documents = v.documents && v.documents.length;
12945
+ if (_documents) flags |= 8;
12946
+ var _users = v.users && v.users.length;
12947
+ if (_users) flags |= 16;
12948
+ w.uint(flags);
12949
+ w.string(h(v, "html"));
12950
+ if (_photos) w.vector(w.object, v.photos);
12951
+ if (_documents) w.vector(w.object, v.documents);
12952
+ if (_users) w.vector(w.object, v.users);
12953
+ },
12954
+ "inputRichMessageMarkdown": function(w, v) {
12955
+ w.uint(162300294);
12956
+ var flags = 0;
12957
+ if (v.rtl === true) flags |= 1;
12958
+ if (v.noautolink === true) flags |= 2;
12959
+ var _photos = v.photos && v.photos.length;
12960
+ if (_photos) flags |= 4;
12961
+ var _documents = v.documents && v.documents.length;
12962
+ if (_documents) flags |= 8;
12963
+ var _users = v.users && v.users.length;
12964
+ if (_users) flags |= 16;
12965
+ w.uint(flags);
12966
+ w.string(h(v, "markdown"));
12967
+ if (_photos) w.vector(w.object, v.photos);
12968
+ if (_documents) w.vector(w.object, v.documents);
12969
+ if (_users) w.vector(w.object, v.users);
12970
+ },
12620
12971
  "updateChannelPinnedTopic": function(w, v) {
12621
12972
  w.uint(422509539);
12622
12973
  var flags = 0;
@@ -13629,7 +13980,11 @@ var m = {
13629
13980
  w.int(h(v, "limit"));
13630
13981
  },
13631
13982
  "contacts.search": function(w, v) {
13632
- w.uint(301470424);
13983
+ w.uint(99978511);
13984
+ var flags = 0;
13985
+ if (v.broadcasts === true) flags |= 1;
13986
+ if (v.bots === true) flags |= 2;
13987
+ w.uint(flags);
13633
13988
  w.string(h(v, "q"));
13634
13989
  w.int(h(v, "limit"));
13635
13990
  },
@@ -13845,7 +14200,7 @@ var m = {
13845
14200
  w.object(h(v, "action"));
13846
14201
  },
13847
14202
  "messages.sendMessage": function(w, v) {
13848
- w.uint(1415369050);
14203
+ w.uint(4277440354);
13849
14204
  var flags = 0;
13850
14205
  var _replyTo = v.replyTo !== void 0;
13851
14206
  if (_replyTo) flags |= 1;
@@ -13873,6 +14228,8 @@ var m = {
13873
14228
  if (_allowPaidStars) flags |= 2097152;
13874
14229
  var _suggestedPost = v.suggestedPost !== void 0;
13875
14230
  if (_suggestedPost) flags |= 4194304;
14231
+ var _richMessage = v.richMessage !== void 0;
14232
+ if (_richMessage) flags |= 8388608;
13876
14233
  var _scheduleRepeatPeriod = v.scheduleRepeatPeriod !== void 0;
13877
14234
  if (_scheduleRepeatPeriod) flags |= 16777216;
13878
14235
  w.uint(flags);
@@ -13889,6 +14246,7 @@ var m = {
13889
14246
  if (_effect) w.long(v.effect);
13890
14247
  if (_allowPaidStars) w.long(v.allowPaidStars);
13891
14248
  if (_suggestedPost) w.object(v.suggestedPost);
14249
+ if (_richMessage) w.object(v.richMessage);
13892
14250
  },
13893
14251
  "messages.sendMedia": function(w, v) {
13894
14252
  w.uint(53536639);
@@ -14153,7 +14511,7 @@ var m = {
14153
14511
  w.string(h(v, "hash"));
14154
14512
  },
14155
14513
  "messages.importChatInvite": function(w, v) {
14156
- w.uint(1817183516);
14514
+ w.uint(3734061934);
14157
14515
  w.string(h(v, "hash"));
14158
14516
  },
14159
14517
  "messages.getStickerSet": function(w, v) {
@@ -14300,7 +14658,7 @@ var m = {
14300
14658
  w.int(h(v, "id"));
14301
14659
  },
14302
14660
  "messages.editMessage": function(w, v) {
14303
- w.uint(1374175969);
14661
+ w.uint(2970019436);
14304
14662
  var flags = 0;
14305
14663
  if (v.noWebpage === true) flags |= 2;
14306
14664
  var _replyMarkup = v.replyMarkup !== void 0;
@@ -14318,6 +14676,8 @@ var m = {
14318
14676
  if (_quickReplyShortcutId) flags |= 131072;
14319
14677
  var _scheduleRepeatPeriod = v.scheduleRepeatPeriod !== void 0;
14320
14678
  if (_scheduleRepeatPeriod) flags |= 262144;
14679
+ var _richMessage = v.richMessage !== void 0;
14680
+ if (_richMessage) flags |= 8388608;
14321
14681
  w.uint(flags);
14322
14682
  w.object(h(v, "peer"));
14323
14683
  w.int(h(v, "id"));
@@ -14328,9 +14688,10 @@ var m = {
14328
14688
  if (_scheduleDate) w.int(v.scheduleDate);
14329
14689
  if (_scheduleRepeatPeriod) w.int(v.scheduleRepeatPeriod);
14330
14690
  if (_quickReplyShortcutId) w.int(v.quickReplyShortcutId);
14691
+ if (_richMessage) w.object(v.richMessage);
14331
14692
  },
14332
14693
  "messages.editInlineBotMessage": function(w, v) {
14333
- w.uint(2203418042);
14694
+ w.uint(2753805137);
14334
14695
  var flags = 0;
14335
14696
  if (v.noWebpage === true) flags |= 2;
14336
14697
  var _replyMarkup = v.replyMarkup !== void 0;
@@ -14342,12 +14703,15 @@ var m = {
14342
14703
  var _media = v.media !== void 0;
14343
14704
  if (_media) flags |= 16384;
14344
14705
  if (v.invertMedia === true) flags |= 65536;
14706
+ var _richMessage = v.richMessage !== void 0;
14707
+ if (_richMessage) flags |= 8388608;
14345
14708
  w.uint(flags);
14346
14709
  w.object(h(v, "id"));
14347
14710
  if (_message) w.string(v.message);
14348
14711
  if (_media) w.object(v.media);
14349
14712
  if (_replyMarkup) w.object(v.replyMarkup);
14350
14713
  if (_entities) w.vector(w.object, v.entities);
14714
+ if (_richMessage) w.object(v.richMessage);
14351
14715
  },
14352
14716
  "messages.getBotCallbackAnswer": function(w, v) {
14353
14717
  w.uint(2470627847);
@@ -14382,7 +14746,7 @@ var m = {
14382
14746
  w.vector(w.object, h(v, "peers"));
14383
14747
  },
14384
14748
  "messages.saveDraft": function(w, v) {
14385
- w.uint(1420701838);
14749
+ w.uint(2903482716);
14386
14750
  var flags = 0;
14387
14751
  if (v.noWebpage === true) flags |= 2;
14388
14752
  var _entities = v.entities && v.entities.length;
@@ -14396,6 +14760,8 @@ var m = {
14396
14760
  if (_effect) flags |= 128;
14397
14761
  var _suggestedPost = v.suggestedPost !== void 0;
14398
14762
  if (_suggestedPost) flags |= 256;
14763
+ var _richMessage = v.richMessage !== void 0;
14764
+ if (_richMessage) flags |= 512;
14399
14765
  w.uint(flags);
14400
14766
  if (_replyTo) w.object(v.replyTo);
14401
14767
  w.object(h(v, "peer"));
@@ -14404,6 +14770,7 @@ var m = {
14404
14770
  if (_media) w.object(v.media);
14405
14771
  if (_effect) w.long(v.effect);
14406
14772
  if (_suggestedPost) w.object(v.suggestedPost);
14773
+ if (_richMessage) w.object(v.richMessage);
14407
14774
  },
14408
14775
  "messages.getAllDrafts": function(w) {
14409
14776
  w.uint(1782549861);
@@ -16224,7 +16591,7 @@ var m = {
16224
16591
  w.string(h(v, "username"));
16225
16592
  },
16226
16593
  "channels.joinChannel": function(w, v) {
16227
- w.uint(615851205);
16594
+ w.uint(2137660962);
16228
16595
  w.object(h(v, "channel"));
16229
16596
  },
16230
16597
  "channels.leaveChannel": function(w, v) {
@@ -16359,9 +16726,15 @@ var m = {
16359
16726
  w.boolean(h(v, "enabled"));
16360
16727
  },
16361
16728
  "channels.toggleJoinRequest": function(w, v) {
16362
- w.uint(1277789622);
16729
+ w.uint(248260120);
16730
+ var flags = 0;
16731
+ var _guardBot = v.guardBot !== void 0;
16732
+ if (_guardBot) flags |= 1;
16733
+ if (v.applyToInvites === true) flags |= 2;
16734
+ w.uint(flags);
16363
16735
  w.object(h(v, "channel"));
16364
16736
  w.boolean(h(v, "enabled"));
16737
+ if (_guardBot) w.object(v.guardBot);
16365
16738
  },
16366
16739
  "channels.reorderUsernames": function(w, v) {
16367
16740
  w.uint(3025988893);
@@ -18121,6 +18494,44 @@ var m = {
18121
18494
  w.object(h(v, "tone"));
18122
18495
  w.int(h(v, "num"));
18123
18496
  },
18497
+ "account.confirmBotConnection": function(w, v) {
18498
+ w.uint(1743593320);
18499
+ w.object(h(v, "botId"));
18500
+ },
18501
+ "account.getWebBrowserSettings": function(w, v) {
18502
+ w.uint(1449482088);
18503
+ w.long(h(v, "hash"));
18504
+ },
18505
+ "account.updateWebBrowserSettings": function(w, v) {
18506
+ w.uint(2598339326);
18507
+ var flags = 0;
18508
+ if (v.openExternalBrowser === true) flags |= 1;
18509
+ if (v.displayCloseButton === true) flags |= 2;
18510
+ w.uint(flags);
18511
+ },
18512
+ "account.toggleWebBrowserSettingsException": function(w, v) {
18513
+ w.uint(1626161705);
18514
+ var flags = 0;
18515
+ var _openExternalBrowser = v.openExternalBrowser !== void 0;
18516
+ if (_openExternalBrowser) flags |= 1;
18517
+ if (v.delete === true) flags |= 2;
18518
+ w.uint(flags);
18519
+ if (_openExternalBrowser) w.boolean(v.openExternalBrowser);
18520
+ w.string(h(v, "url"));
18521
+ },
18522
+ "account.deleteWebBrowserSettingsExceptions": function(w) {
18523
+ w.uint(2258663005);
18524
+ },
18525
+ "messages.getRichMessage": function(w, v) {
18526
+ w.uint(1343580623);
18527
+ w.object(h(v, "peer"));
18528
+ w.int(h(v, "id"));
18529
+ },
18530
+ "bots.setJoinChatResults": function(w, v) {
18531
+ w.uint(3877259280);
18532
+ w.long(h(v, "queryId"));
18533
+ w.object(h(v, "result"));
18534
+ },
18124
18535
  "channels.editCreator": function(w, v) {
18125
18536
  w.uint(2402864415);
18126
18537
  w.object(h(v, "channel"));
@@ -18994,6 +19405,11 @@ var m = {
18994
19405
  "inputMessageReadMetric": 32,
18995
19406
  "inputAiComposeToneID": 20,
18996
19407
  "aicompose.tonesNotModified": 4,
19408
+ "updateWebBrowserSettings": 8,
19409
+ "joinChatBotResultApproved": 4,
19410
+ "joinChatBotResultDeclined": 4,
19411
+ "joinChatBotResultQueued": 4,
19412
+ "account.webBrowserSettingsNotModified": 4,
18997
19413
  "updateChannelPinnedTopic": 20,
18998
19414
  "auth.logOut": 4,
18999
19415
  "auth.resetAuthorizations": 4,
@@ -19158,6 +19574,9 @@ var m = {
19158
19574
  "smsjobs.updateSettings": 8,
19159
19575
  "smsjobs.getStatus": 4,
19160
19576
  "aicompose.getTones": 12,
19577
+ "account.getWebBrowserSettings": 12,
19578
+ "account.updateWebBrowserSettings": 8,
19579
+ "account.deleteWebBrowserSettingsExceptions": 4,
19161
19580
  "mt_dh_gen_ok": 52,
19162
19581
  "mt_dh_gen_retry": 52,
19163
19582
  "mt_dh_gen_fail": 52,