@mtcute/core 0.29.6 → 0.29.7

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 (62) hide show
  1. package/client.cjs +8 -0
  2. package/client.js +8 -0
  3. package/highlevel/client.d.cts +19 -1
  4. package/highlevel/client.d.ts +19 -1
  5. package/highlevel/methods/bots/answer-bot-guest-chat-query.cjs +26 -0
  6. package/highlevel/methods/bots/answer-bot-guest-chat-query.d.cts +12 -0
  7. package/highlevel/methods/bots/answer-bot-guest-chat-query.d.ts +12 -0
  8. package/highlevel/methods/bots/answer-bot-guest-chat-query.js +21 -0
  9. package/highlevel/methods/messages/send-copy-group.cjs +5 -9
  10. package/highlevel/methods/messages/send-copy-group.js +5 -9
  11. package/highlevel/methods.d.cts +1 -0
  12. package/highlevel/methods.d.ts +1 -0
  13. package/highlevel/storage/service/peers.cjs +1 -0
  14. package/highlevel/storage/service/peers.js +1 -0
  15. package/highlevel/types/media/poll.cjs +14 -0
  16. package/highlevel/types/media/poll.d.cts +6 -0
  17. package/highlevel/types/media/poll.d.ts +6 -0
  18. package/highlevel/types/media/poll.js +14 -0
  19. package/highlevel/types/messages/message.cjs +10 -1
  20. package/highlevel/types/messages/message.d.cts +5 -0
  21. package/highlevel/types/messages/message.d.ts +5 -0
  22. package/highlevel/types/messages/message.js +10 -1
  23. package/highlevel/types/peers/chat-permissions.cjs +6 -0
  24. package/highlevel/types/peers/chat-permissions.d.cts +4 -0
  25. package/highlevel/types/peers/chat-permissions.d.ts +4 -0
  26. package/highlevel/types/peers/chat-permissions.js +6 -0
  27. package/highlevel/types/peers/user.cjs +4 -0
  28. package/highlevel/types/peers/user.d.cts +2 -0
  29. package/highlevel/types/peers/user.d.ts +2 -0
  30. package/highlevel/types/peers/user.js +4 -0
  31. package/highlevel/types/updates/bot-guest-chat-query.cjs +39 -0
  32. package/highlevel/types/updates/bot-guest-chat-query.d.cts +21 -0
  33. package/highlevel/types/updates/bot-guest-chat-query.d.ts +21 -0
  34. package/highlevel/types/updates/bot-guest-chat-query.js +34 -0
  35. package/highlevel/types/updates/index.d.cts +5 -1
  36. package/highlevel/types/updates/index.d.ts +5 -1
  37. package/highlevel/types/updates/parse-update.cjs +3 -0
  38. package/highlevel/types/updates/parse-update.js +3 -0
  39. package/highlevel/updates/manager.cjs +23 -3
  40. package/highlevel/updates/manager.d.cts +1 -0
  41. package/highlevel/updates/manager.d.ts +1 -0
  42. package/highlevel/updates/manager.js +23 -3
  43. package/index.cjs +2 -0
  44. package/index.js +2 -0
  45. package/methods.cjs +2 -0
  46. package/methods.js +2 -0
  47. package/network/network-manager.cjs +1 -1
  48. package/network/network-manager.js +1 -1
  49. package/package.json +1 -1
  50. package/tl/api-schema.json +1 -1
  51. package/tl/binary/reader.cjs +85 -40
  52. package/tl/binary/reader.js +85 -40
  53. package/tl/binary/writer.cjs +349 -143
  54. package/tl/binary/writer.js +349 -143
  55. package/tl/compat/reader.cjs +8 -0
  56. package/tl/compat/reader.js +8 -0
  57. package/tl/index.d.cts +2071 -179
  58. package/tl/index.d.ts +2071 -179
  59. package/tl/inner-tl.cjs +17 -5
  60. package/tl/inner-tl.js +17 -5
  61. package/utils/binary/compat.cjs +5 -0
  62. package/utils/binary/compat.js +5 -0
package/tl/index.d.ts CHANGED
@@ -1,6 +1,6 @@
1
1
  import { default as _Long } from 'long';
2
2
  export declare namespace tl {
3
- const LAYER = 224;
3
+ const LAYER = 225;
4
4
 
5
5
  type Long = _Long;
6
6
  type RawLong = Uint8Array;
@@ -806,6 +806,11 @@ export class RpcError extends Error {
806
806
  * Contact's last name
807
807
  */
808
808
  lastName: string;
809
+ /**
810
+ * A private note for this contact, only visible to us; see
811
+ * <a href="https://corefork.telegram.org/api/contacts#private-notes-for-contacts">here
812
+ * »</a> for more info on contact notes.
813
+ */
809
814
  note?: tl.TypeTextWithEntities;
810
815
  }
811
816
  /**
@@ -1894,9 +1899,22 @@ export class RpcError extends Error {
1894
1899
  * Mini App »</a>.
1895
1900
  */
1896
1901
  botHasMainApp?: boolean;
1902
+ /**
1903
+ * If set, this bot supports
1904
+ * <a href="https://corefork.telegram.org/api/forum#bot-forums">bot
1905
+ * forum topics »</a>.
1906
+ */
1897
1907
  botForumView?: boolean;
1908
+ /**
1909
+ * If set, this bot supports
1910
+ * <a href="https://corefork.telegram.org/api/forum#bot-forums">bot
1911
+ * forum topics »</a>, and users (not just the bot!) are
1912
+ * allowed to create and manage bot forum topics in their
1913
+ * private chat with the bot.
1914
+ */
1898
1915
  botForumCanManageTopics?: boolean;
1899
1916
  botCanManageBots?: boolean;
1917
+ botGuestchat?: boolean;
1900
1918
  /**
1901
1919
  * ID of the user, see
1902
1920
  * <a href="https://corefork.telegram.org/api/peers#peer-id">here
@@ -2313,7 +2331,7 @@ export class RpcError extends Error {
2313
2331
  callNotEmpty?: boolean;
2314
2332
  /**
2315
2333
  * Whether this group is
2316
- * <a href="https://telegram.org/blog/protected-content-delete-by-date-and-more">protected</a>,
2334
+ * <a href="https://telegram.org/blog/content-protection-delete-by-date-and-more">protected</a>,
2317
2335
  * thus does not allow forwarding messages from it
2318
2336
  */
2319
2337
  noforwards?: boolean;
@@ -2515,7 +2533,7 @@ export class RpcError extends Error {
2515
2533
  gigagroup?: boolean;
2516
2534
  /**
2517
2535
  * Whether this channel or group is
2518
- * <a href="https://telegram.org/blog/protected-content-delete-by-date-and-more">protected</a>,
2536
+ * <a href="https://telegram.org/blog/content-protection-delete-by-date-and-more">protected</a>,
2519
2537
  * thus does not allow forwarding messages from it
2520
2538
  */
2521
2539
  noforwards?: boolean;
@@ -2761,6 +2779,11 @@ export class RpcError extends Error {
2761
2779
  * Is this a supergroup
2762
2780
  */
2763
2781
  megagroup?: boolean;
2782
+ /**
2783
+ * If set, this is a
2784
+ * <a href="https://corefork.telegram.org/api/monoforum">monoforum
2785
+ * »</a>.
2786
+ */
2764
2787
  monoforum?: boolean;
2765
2788
  /**
2766
2789
  * Channel ID
@@ -2939,8 +2962,9 @@ export class RpcError extends Error {
2939
2962
  canViewStats?: boolean;
2940
2963
  /**
2941
2964
  * Whether any anonymous admin of this supergroup was blocked:
2942
- * if set, you won't receive messages from anonymous group
2943
- * admins in
2965
+ * if set, you won't receive messages from
2966
+ * <a href="https://corefork.telegram.org/api/rights#anonymous-admins">anonymous
2967
+ * group admins »</a> in
2944
2968
  * <a href="https://corefork.telegram.org/api/discussion">discussion
2945
2969
  * replies via @replies</a>
2946
2970
  */
@@ -3275,7 +3299,8 @@ export class RpcError extends Error {
3275
3299
  mainTab?: tl.TypeProfileTab;
3276
3300
  }
3277
3301
  /**
3278
- * Group member.
3302
+ * <a href="https://corefork.telegram.org/api/channel#basic-groups">Basic
3303
+ * group</a> member (not usable by supergroups).
3279
3304
  */
3280
3305
  interface RawChatParticipant {
3281
3306
  _: 'chatParticipant';
@@ -3291,10 +3316,16 @@ export class RpcError extends Error {
3291
3316
  * Date added to the group
3292
3317
  */
3293
3318
  date: number;
3319
+ /**
3320
+ * The participant's
3321
+ * <a href="https://corefork.telegram.org/api/rank">tag »</a>.
3322
+ */
3294
3323
  rank?: string;
3295
3324
  }
3296
3325
  /**
3297
- * Represents the creator of the group
3326
+ * Represents the creator of the
3327
+ * <a href="https://corefork.telegram.org/api/channel#basic-groups">basic
3328
+ * group »</a>
3298
3329
  */
3299
3330
  interface RawChatParticipantCreator {
3300
3331
  _: 'chatParticipantCreator';
@@ -3302,10 +3333,15 @@ export class RpcError extends Error {
3302
3333
  * ID of the user that created the group
3303
3334
  */
3304
3335
  userId: number;
3336
+ /**
3337
+ * The participant's
3338
+ * <a href="https://corefork.telegram.org/api/rank">tag »</a>.
3339
+ */
3305
3340
  rank?: string;
3306
3341
  }
3307
3342
  /**
3308
- * Chat admin
3343
+ * <a href="https://corefork.telegram.org/api/channel#basic-groups">Basic
3344
+ * group</a> admin (not usable by supergroups).
3309
3345
  */
3310
3346
  interface RawChatParticipantAdmin {
3311
3347
  _: 'chatParticipantAdmin';
@@ -3321,10 +3357,17 @@ export class RpcError extends Error {
3321
3357
  * Date when the user was added
3322
3358
  */
3323
3359
  date: number;
3360
+ /**
3361
+ * The participant's
3362
+ * <a href="https://corefork.telegram.org/api/rank">tag »</a>.
3363
+ */
3324
3364
  rank?: string;
3325
3365
  }
3326
3366
  /**
3327
- * Info on members is unavailable
3367
+ * The full list of members of
3368
+ * <a href="https://corefork.telegram.org/api/channel#basic-groups">basic
3369
+ * groups »</a> is not available to you, because you were
3370
+ * banned.
3328
3371
  */
3329
3372
  interface RawChatParticipantsForbidden {
3330
3373
  _: 'chatParticipantsForbidden';
@@ -3338,7 +3381,10 @@ export class RpcError extends Error {
3338
3381
  selfParticipant?: tl.TypeChatParticipant;
3339
3382
  }
3340
3383
  /**
3341
- * Group members.
3384
+ * Contains the full list of members of
3385
+ * <a href="https://corefork.telegram.org/api/channel#basic-groups">basic
3386
+ * groups »</a>; is <strong>NOT</strong> usable for
3387
+ * supergroups/channels.
3342
3388
  */
3343
3389
  interface RawChatParticipants {
3344
3390
  _: 'chatParticipants';
@@ -3448,7 +3494,7 @@ export class RpcError extends Error {
3448
3494
  pinned?: boolean;
3449
3495
  /**
3450
3496
  * Whether this message is
3451
- * <a href="https://telegram.org/blog/protected-content-delete-by-date-and-more">protected</a>
3497
+ * <a href="https://telegram.org/blog/content-protection-delete-by-date-and-more">protected</a>
3452
3498
  * and thus cannot be forwarded; clients should also prevent
3453
3499
  * users from saving attached media (i.e. videos should only be
3454
3500
  * streamed, photos should be kept in RAM, et cetera).
@@ -3525,6 +3571,15 @@ export class RpcError extends Error {
3525
3571
  * users, even if their boosts have changed.
3526
3572
  */
3527
3573
  fromBoostsApplied?: number;
3574
+ /**
3575
+ * Only in
3576
+ * <a href="https://corefork.telegram.org/api/channel#supergroups">supergroups
3577
+ * »</a> (never basic groups, where this information is
3578
+ * contained
3579
+ * <a href="https://corefork.telegram.org/api/rank">elsewhere
3580
+ * »</a>), contains the sender's
3581
+ * <a href="https://corefork.telegram.org/api/rank">tag »</a>.
3582
+ */
3528
3583
  fromRank?: string;
3529
3584
  /**
3530
3585
  * Peer ID, the chat where this message was sent
@@ -3560,6 +3615,7 @@ export class RpcError extends Error {
3560
3615
  * the user.
3561
3616
  */
3562
3617
  viaBusinessBotId?: number;
3618
+ guestchatViaFrom?: tl.TypePeer;
3563
3619
  /**
3564
3620
  * Reply information
3565
3621
  */
@@ -3678,6 +3734,12 @@ export class RpcError extends Error {
3678
3734
  * full flow.
3679
3735
  */
3680
3736
  suggestedPost?: tl.TypeSuggestedPost;
3737
+ /**
3738
+ * Once sent, this message will be automatically re-scheduled
3739
+ * to be re-sent again this many seconds in the future, see
3740
+ * <a href="https://corefork.telegram.org/api/scheduled-messages#repeating-scheduled-messages">here
3741
+ * »</a> for more info on repeating scheduled messages.
3742
+ */
3681
3743
  scheduleRepeatPeriod?: number;
3682
3744
  summaryFromLanguage?: string;
3683
3745
  }
@@ -5245,6 +5307,11 @@ export class RpcError extends Error {
5245
5307
  * pre-payment for the upgrade of a gift we own</a>.
5246
5308
  */
5247
5309
  upgradeSeparate?: boolean;
5310
+ /**
5311
+ * If set, this gift was acquired in a
5312
+ * <a href="https://corefork.telegram.org/api/auctions">collectible
5313
+ * gifts auction »</a>.
5314
+ */
5248
5315
  auctionAcquired?: boolean;
5249
5316
  /**
5250
5317
  * Info about the gift
@@ -5401,6 +5468,13 @@ export class RpcError extends Error {
5401
5468
  * the specified unixtime.
5402
5469
  */
5403
5470
  canResellAt?: number;
5471
+ /**
5472
+ * If set, the {@link RawStarGiftAttributeOriginalDetails}
5473
+ * attribute of this gift may be removed by paying the
5474
+ * specified amount of stars, see
5475
+ * <a href="https://corefork.telegram.org/api/gifts#dropping-the-original-details-of-an-upgraded-gift">here
5476
+ * »</a> for the full flow.
5477
+ */
5404
5478
  dropOriginalDetailsStars?: Long;
5405
5479
  canCraftAt?: number;
5406
5480
  }
@@ -5612,8 +5686,17 @@ export class RpcError extends Error {
5612
5686
  */
5613
5687
  transactionId?: string;
5614
5688
  }
5689
+ /**
5690
+ * A new birthday was suggested using
5691
+ * {@link users.RawSuggestBirthdayRequest}, see
5692
+ * <a href="https://corefork.telegram.org/api/profile#birthday">here
5693
+ * »</a> for more info on birthdays in the API.
5694
+ */
5615
5695
  interface RawMessageActionSuggestBirthday {
5616
5696
  _: 'messageActionSuggestBirthday';
5697
+ /**
5698
+ * The suggested birthday.
5699
+ */
5617
5700
  birthday: tl.TypeBirthday;
5618
5701
  }
5619
5702
  interface RawMessageActionStarGiftPurchaseOffer {
@@ -5638,17 +5721,60 @@ export class RpcError extends Error {
5638
5721
  _: 'messageActionChangeCreator';
5639
5722
  newCreatorId: number;
5640
5723
  }
5724
+ /**
5725
+ * Emitted only in private chats when enabling or disabling
5726
+ * <a href="https://corefork.telegram.org/api/content-protection#for-users">content
5727
+ * protection »</a>.
5728
+ */
5641
5729
  interface RawMessageActionNoForwardsToggle {
5642
5730
  _: 'messageActionNoForwardsToggle';
5731
+ /**
5732
+ * Previous protection status (if true, the chat was
5733
+ * protected). May be equal to <code>new_value</code> when
5734
+ * replying to requests, see
5735
+ * <a href="https://corefork.telegram.org/api/content-protection#for-users">here
5736
+ * »</a> for more info on the full flow.
5737
+ */
5643
5738
  prevValue: boolean;
5739
+ /**
5740
+ * New protection status.
5741
+ */
5644
5742
  newValue: boolean;
5645
5743
  }
5744
+ /**
5745
+ * Emitted only in private chats if the other side requested to
5746
+ * disable
5747
+ * <a href="https://corefork.telegram.org/api/content-protection#for-users">content
5748
+ * protection »</a>.
5749
+ */
5646
5750
  interface RawMessageActionNoForwardsRequest {
5647
5751
  _: 'messageActionNoForwardsRequest';
5752
+ /**
5753
+ * If set, this request was accepted or rejected by the other
5754
+ * user and thus cannot be used anymore.
5755
+ */
5648
5756
  expired?: boolean;
5757
+ /**
5758
+ * Previous protection status.
5759
+ */
5649
5760
  prevValue: boolean;
5761
+ /**
5762
+ * New requested protection status.
5763
+ */
5650
5764
  newValue: boolean;
5651
5765
  }
5766
+ interface RawMessageActionPollAppendAnswer {
5767
+ _: 'messageActionPollAppendAnswer';
5768
+ answer: tl.TypePollAnswer;
5769
+ }
5770
+ interface RawMessageActionPollDeleteAnswer {
5771
+ _: 'messageActionPollDeleteAnswer';
5772
+ answer: tl.TypePollAnswer;
5773
+ }
5774
+ interface RawMessageActionManagedBotCreated {
5775
+ _: 'messageActionManagedBotCreated';
5776
+ botId: number;
5777
+ }
5652
5778
  /**
5653
5779
  * Chat
5654
5780
  */
@@ -6502,7 +6628,18 @@ export class RpcError extends Error {
6502
6628
  * Gifts »</a>.
6503
6629
  */
6504
6630
  displayGiftsButton?: boolean;
6631
+ /**
6632
+ * If set,
6633
+ * <a href="https://corefork.telegram.org/api/content-protection#for-users">content
6634
+ * protection »</a> was enabled in this private chat by us.
6635
+ */
6505
6636
  noforwardsMyEnabled?: boolean;
6637
+ /**
6638
+ * If set,
6639
+ * <a href="https://corefork.telegram.org/api/content-protection#for-users">content
6640
+ * protection »</a> was enabled in this private chat by this
6641
+ * user.
6642
+ */
6506
6643
  noforwardsPeerEnabled?: boolean;
6507
6644
  unofficialSecurityRisk?: boolean;
6508
6645
  /**
@@ -6715,6 +6852,11 @@ export class RpcError extends Error {
6715
6852
  * »</a> for more info on the music profile tab.
6716
6853
  */
6717
6854
  savedMusic?: tl.TypeDocument;
6855
+ /**
6856
+ * A private note for this contact, only visible to us; see
6857
+ * <a href="https://corefork.telegram.org/api/contacts#private-notes-for-contacts">here
6858
+ * »</a> for more info on contact notes.
6859
+ */
6718
6860
  note?: tl.TypeTextWithEntities;
6719
6861
  botManagerId?: number;
6720
6862
  }
@@ -6870,6 +7012,9 @@ export class RpcError extends Error {
6870
7012
  interface RawInputMessagesFilterPinned {
6871
7013
  _: 'inputMessagesFilterPinned';
6872
7014
  }
7015
+ interface RawInputMessagesFilterPoll {
7016
+ _: 'inputMessagesFilterPoll';
7017
+ }
6873
7018
  /**
6874
7019
  * New message in a private chat or in a
6875
7020
  * <a href="https://core.telegram.org/api/channel#basic-groups">basic
@@ -6939,6 +7084,11 @@ export class RpcError extends Error {
6939
7084
  * User id
6940
7085
  */
6941
7086
  userId: number;
7087
+ /**
7088
+ * If set, this notification was sent within a
7089
+ * <a href="https://corefork.telegram.org/api/forum#bot-forums">bot
7090
+ * forum topic »</a>.
7091
+ */
6942
7092
  topMsgId?: number;
6943
7093
  /**
6944
7094
  * Action type
@@ -6969,12 +7119,18 @@ export class RpcError extends Error {
6969
7119
  action: tl.TypeSendMessageAction;
6970
7120
  }
6971
7121
  /**
6972
- * Composition of chat participants changed.
7122
+ * The participants of a
7123
+ * <a href="https://corefork.telegram.org/api/channel#basic-groups">basic
7124
+ * group »</a> changed.
6973
7125
  */
6974
7126
  interface RawUpdateChatParticipants {
6975
7127
  _: 'updateChatParticipants';
6976
7128
  /**
6977
- * Updated chat participants
7129
+ * Updated chat participants (also contains the
7130
+ * <code>version</code> used to deduplicate/update outdated
7131
+ * chat information as specified
7132
+ * <a href="https://corefork.telegram.org/api/peers#basic-group-updates">here
7133
+ * »</a>).
6978
7134
  */
6979
7135
  participants: tl.TypeChatParticipants;
6980
7136
  }
@@ -7132,12 +7288,17 @@ export class RpcError extends Error {
7132
7288
  */
7133
7289
  date: number;
7134
7290
  /**
7135
- * Chat version number
7291
+ * Used similarly to <code>pts</code> values to
7292
+ * deduplicate/update outdated chat information as specified
7293
+ * <a href="https://corefork.telegram.org/api/peers#basic-group-updates">here
7294
+ * »</a>.
7136
7295
  */
7137
7296
  version: number;
7138
7297
  }
7139
7298
  /**
7140
- * A member has left the group.
7299
+ * A member has left the
7300
+ * <a href="https://corefork.telegram.org/api/channel#basic-groups">basic
7301
+ * group</a>.
7141
7302
  */
7142
7303
  interface RawUpdateChatParticipantDelete {
7143
7304
  _: 'updateChatParticipantDelete';
@@ -7150,8 +7311,10 @@ export class RpcError extends Error {
7150
7311
  */
7151
7312
  userId: number;
7152
7313
  /**
7153
- * Used in basic groups to reorder updates and make sure that
7154
- * all of them was received.
7314
+ * Used similarly to <code>pts</code> values to
7315
+ * deduplicate/update outdated chat information as specified
7316
+ * <a href="https://corefork.telegram.org/api/peers#basic-group-updates">here
7317
+ * »</a>.
7155
7318
  */
7156
7319
  version: number;
7157
7320
  }
@@ -7275,6 +7438,11 @@ export class RpcError extends Error {
7275
7438
  * Peer
7276
7439
  */
7277
7440
  peer: tl.TypePeer;
7441
+ /**
7442
+ * If set, the messages were read only within the specified
7443
+ * <a href="https://corefork.telegram.org/api/forum#bot-forums">bot
7444
+ * forum topic »</a>.
7445
+ */
7278
7446
  topMsgId?: number;
7279
7447
  /**
7280
7448
  * Maximum ID of messages read
@@ -7530,8 +7698,10 @@ export class RpcError extends Error {
7530
7698
  */
7531
7699
  isAdmin: boolean;
7532
7700
  /**
7533
- * Used in basic groups to reorder updates and make sure that
7534
- * all of them was received.
7701
+ * Used similarly to <code>pts</code> values to
7702
+ * deduplicate/update outdated chat information as specified
7703
+ * <a href="https://corefork.telegram.org/api/peers#basic-group-updates">here
7704
+ * »</a>.
7535
7705
  */
7536
7706
  version: number;
7537
7707
  }
@@ -8134,8 +8304,8 @@ export class RpcError extends Error {
8134
8304
  }
8135
8305
  /**
8136
8306
  * Default banned rights in a
8137
- * <a href="https://corefork.telegram.org/api/channel">normal
8138
- * chat</a> were updated
8307
+ * <a href="https://corefork.telegram.org/api/channel#basic-groups">basic
8308
+ * group</a> were updated
8139
8309
  */
8140
8310
  interface RawUpdateChatDefaultBannedRights {
8141
8311
  _: 'updateChatDefaultBannedRights';
@@ -8148,7 +8318,10 @@ export class RpcError extends Error {
8148
8318
  */
8149
8319
  defaultBannedRights: tl.TypeChatBannedRights;
8150
8320
  /**
8151
- * Version
8321
+ * Used similarly to <code>pts</code> values to
8322
+ * deduplicate/update outdated chat information as specified
8323
+ * <a href="https://corefork.telegram.org/api/peers#basic-group-updates">here
8324
+ * »</a>.
8152
8325
  */
8153
8326
  version: number;
8154
8327
  }
@@ -8605,7 +8778,9 @@ export class RpcError extends Error {
8605
8778
  ttlPeriod?: number;
8606
8779
  }
8607
8780
  /**
8608
- * A user has joined or left a specific chat
8781
+ * A user has joined or left a specific
8782
+ * <a href="https://corefork.telegram.org/api/channel#basic-groups">basic
8783
+ * group »</a>
8609
8784
  */
8610
8785
  interface RawUpdateChatParticipant {
8611
8786
  _: 'updateChatParticipant';
@@ -9717,15 +9892,42 @@ export class RpcError extends Error {
9717
9892
  fromId: tl.TypePeer;
9718
9893
  encryptedMessage: Uint8Array;
9719
9894
  }
9895
+ /**
9896
+ * A
9897
+ * <a href="https://corefork.telegram.org/api/forum#forum-topics">forum
9898
+ * topic »</a> was pinned or unpinned.
9899
+ */
9720
9900
  interface RawUpdatePinnedForumTopic {
9721
9901
  _: 'updatePinnedForumTopic';
9902
+ /**
9903
+ * Whether the topic was pinned or unpinned
9904
+ */
9722
9905
  pinned?: boolean;
9906
+ /**
9907
+ * The supergroup forum, private chat (for forum-enabled bots)
9908
+ * or bot forum (for users) where the topic is located.
9909
+ */
9723
9910
  peer: tl.TypePeer;
9911
+ /**
9912
+ * The topic ID
9913
+ */
9724
9914
  topicId: number;
9725
9915
  }
9916
+ /**
9917
+ * The
9918
+ * <a href="https://corefork.telegram.org/api/forum#forum-topics">pinned
9919
+ * topics</a> of a forum have changed.
9920
+ */
9726
9921
  interface RawUpdatePinnedForumTopics {
9727
9922
  _: 'updatePinnedForumTopics';
9923
+ /**
9924
+ * The supergroup forum, private chat (for forum-enabled bots)
9925
+ * or bot forum (for users) where the topic is located.
9926
+ */
9728
9927
  peer: tl.TypePeer;
9928
+ /**
9929
+ * Ordered list containing the IDs of all pinned topics.
9930
+ */
9729
9931
  order?: number[];
9730
9932
  }
9731
9933
  interface RawUpdateDeleteGroupCallMessages {
@@ -9733,14 +9935,43 @@ export class RpcError extends Error {
9733
9935
  call: tl.TypeInputGroupCall;
9734
9936
  messages: number[];
9735
9937
  }
9938
+ /**
9939
+ * Contains updates to
9940
+ * <a href="https://corefork.telegram.org/api/auctions">auction
9941
+ * state, see here »</a> for more info on how to enable these
9942
+ * updates.
9943
+ */
9736
9944
  interface RawUpdateStarGiftAuctionState {
9737
9945
  _: 'updateStarGiftAuctionState';
9946
+ /**
9947
+ * ID of the
9948
+ * <a href="https://corefork.telegram.org/api/gifts#collectible-gifts">collectible
9949
+ * gift »</a> currently being distributed in the auction.
9950
+ */
9738
9951
  giftId: Long;
9952
+ /**
9953
+ * Auction state.
9954
+ */
9739
9955
  state: tl.TypeStarGiftAuctionState;
9740
9956
  }
9957
+ /**
9958
+ * Contains updates to
9959
+ * <a href="https://corefork.telegram.org/api/auctions">auction
9960
+ * state related to the current user, see here »</a> for more
9961
+ * info on how to enable these updates.
9962
+ */
9741
9963
  interface RawUpdateStarGiftAuctionUserState {
9742
9964
  _: 'updateStarGiftAuctionUserState';
9965
+ /**
9966
+ * ID of the
9967
+ * <a href="https://corefork.telegram.org/api/gifts#collectible-gifts">collectible
9968
+ * gift »</a> currently being distributed in the auction.
9969
+ */
9743
9970
  giftId: Long;
9971
+ /**
9972
+ * Auction state related to the current user (i.e. info about
9973
+ * placed bids, won gifts and so on).
9974
+ */
9744
9975
  userState: tl.TypeStarGiftAuctionUserState;
9745
9976
  }
9746
9977
  interface RawUpdateEmojiGameInfo {
@@ -9750,13 +9981,50 @@ export class RpcError extends Error {
9750
9981
  interface RawUpdateStarGiftCraftFail {
9751
9982
  _: 'updateStarGiftCraftFail';
9752
9983
  }
9984
+ /**
9985
+ * The <a href="https://corefork.telegram.org/api/rank">tag
9986
+ * »</a> of a participant of a
9987
+ * <a href="https://corefork.telegram.org/api/channel#basic-groups">basic
9988
+ * group »</a> has changed.
9989
+ */
9753
9990
  interface RawUpdateChatParticipantRank {
9754
9991
  _: 'updateChatParticipantRank';
9992
+ /**
9993
+ * Basic group ID.
9994
+ */
9755
9995
  chatId: number;
9996
+ /**
9997
+ * User ID.
9998
+ */
9756
9999
  userId: number;
10000
+ /**
10001
+ * The new tag.
10002
+ */
9757
10003
  rank: string;
10004
+ /**
10005
+ * Used similarly to <code>pts</code> values to
10006
+ * deduplicate/update outdated chat information as specified
10007
+ * <a href="https://corefork.telegram.org/api/peers#basic-group-updates">here
10008
+ * »</a>.
10009
+ */
9758
10010
  version: number;
9759
10011
  }
10012
+ interface RawUpdateManagedBot {
10013
+ _: 'updateManagedBot';
10014
+ userId: number;
10015
+ botId: number;
10016
+ qts: number;
10017
+ }
10018
+ interface RawUpdateBotGuestChatQuery {
10019
+ _: 'updateBotGuestChatQuery';
10020
+ queryId: Long;
10021
+ message: tl.TypeMessage;
10022
+ referenceMessages?: tl.TypeMessage[];
10023
+ qts: number;
10024
+ }
10025
+ interface RawUpdateAiComposeTones {
10026
+ _: 'updateAiComposeTones';
10027
+ }
9760
10028
  /**
9761
10029
  * Too many updates, it is necessary to execute
9762
10030
  * {@link updates.RawGetDifferenceRequest}.
@@ -10926,9 +11194,23 @@ export class RpcError extends Error {
10926
11194
  */
10927
11195
  emoticon: string;
10928
11196
  }
11197
+ /**
11198
+ * Used by bots to implement
11199
+ * <a href="https://corefork.telegram.org/api/bots/ai#live-message-streaming">live
11200
+ * message streaming »</a>.
11201
+ */
10929
11202
  interface RawSendMessageTextDraftAction {
10930
11203
  _: 'sendMessageTextDraftAction';
11204
+ /**
11205
+ * Live draft ID: used by graphical clients to slightly change
11206
+ * the rendering behavior, see
11207
+ * <a href="https://corefork.telegram.org/api/bots/ai#live-message-streaming">here
11208
+ * »</a> for more info.
11209
+ */
10931
11210
  randomId: Long;
11211
+ /**
11212
+ * The contents of the live draft.
11213
+ */
10932
11214
  text: tl.TypeTextWithEntities;
10933
11215
  }
10934
11216
  /**
@@ -11033,6 +11315,11 @@ export class RpcError extends Error {
11033
11315
  interface RawInputPrivacyKeyNoPaidMessages {
11034
11316
  _: 'inputPrivacyKeyNoPaidMessages';
11035
11317
  }
11318
+ /**
11319
+ * Whether the user can see the
11320
+ * <a href="https://corefork.telegram.org/api/profile#music">songs
11321
+ * we pinned to our profile »</a>.
11322
+ */
11036
11323
  interface RawInputPrivacyKeySavedMusic {
11037
11324
  _: 'inputPrivacyKeySavedMusic';
11038
11325
  }
@@ -11137,6 +11424,11 @@ export class RpcError extends Error {
11137
11424
  interface RawPrivacyKeyNoPaidMessages {
11138
11425
  _: 'privacyKeyNoPaidMessages';
11139
11426
  }
11427
+ /**
11428
+ * Whether the user can see the
11429
+ * <a href="https://corefork.telegram.org/api/profile#music">songs
11430
+ * we pinned to our profile »</a>.
11431
+ */
11140
11432
  interface RawPrivacyKeySavedMusic {
11141
11433
  _: 'privacyKeySavedMusic';
11142
11434
  }
@@ -11596,8 +11888,8 @@ export class RpcError extends Error {
11596
11888
  */
11597
11889
  hash: number;
11598
11890
  /**
11599
- * Type of the web page. One of the following: <!-- start type
11600
- * -->
11891
+ * Type of the web page. One of the following: <!-- start_table
11892
+ * type -->
11601
11893
  *
11602
11894
  *
11603
11895
  *
@@ -11655,6 +11947,8 @@ export class RpcError extends Error {
11655
11947
  *
11656
11948
  * - <code>telegram_message</code>
11657
11949
  *
11950
+ * - <code>telegram_newbot</code>
11951
+ *
11658
11952
  * - <code>telegram_nft</code>
11659
11953
  *
11660
11954
  * - <code>telegram_stickerset</code>
@@ -11675,7 +11969,7 @@ export class RpcError extends Error {
11675
11969
  *
11676
11970
  *
11677
11971
  *
11678
- * <!-- end type -->
11972
+ * <!-- end_table type -->
11679
11973
  */
11680
11974
  type?: string;
11681
11975
  /**
@@ -12332,6 +12626,11 @@ export class RpcError extends Error {
12332
12626
  */
12333
12627
  interface RawKeyboardButton {
12334
12628
  _: 'keyboardButton';
12629
+ /**
12630
+ * Button style, see
12631
+ * <a href="https://corefork.telegram.org/api/bots/buttons#button-styles">here
12632
+ * »</a> for more info on button styles.
12633
+ */
12335
12634
  style?: tl.TypeKeyboardButtonStyle;
12336
12635
  /**
12337
12636
  * Button text
@@ -12343,6 +12642,11 @@ export class RpcError extends Error {
12343
12642
  */
12344
12643
  interface RawKeyboardButtonUrl {
12345
12644
  _: 'keyboardButtonUrl';
12645
+ /**
12646
+ * Button style, see
12647
+ * <a href="https://corefork.telegram.org/api/bots/buttons#button-styles">here
12648
+ * »</a> for more info on button styles.
12649
+ */
12346
12650
  style?: tl.TypeKeyboardButtonStyle;
12347
12651
  /**
12348
12652
  * Button label
@@ -12372,6 +12676,11 @@ export class RpcError extends Error {
12372
12676
  * of a bot to another user.
12373
12677
  */
12374
12678
  requiresPassword?: boolean;
12679
+ /**
12680
+ * Button style, see
12681
+ * <a href="https://corefork.telegram.org/api/bots/buttons#button-styles">here
12682
+ * »</a> for more info on button styles.
12683
+ */
12375
12684
  style?: tl.TypeKeyboardButtonStyle;
12376
12685
  /**
12377
12686
  * Button text
@@ -12387,6 +12696,11 @@ export class RpcError extends Error {
12387
12696
  */
12388
12697
  interface RawKeyboardButtonRequestPhone {
12389
12698
  _: 'keyboardButtonRequestPhone';
12699
+ /**
12700
+ * Button style, see
12701
+ * <a href="https://corefork.telegram.org/api/bots/buttons#button-styles">here
12702
+ * »</a> for more info on button styles.
12703
+ */
12390
12704
  style?: tl.TypeKeyboardButtonStyle;
12391
12705
  /**
12392
12706
  * Button text
@@ -12398,6 +12712,11 @@ export class RpcError extends Error {
12398
12712
  */
12399
12713
  interface RawKeyboardButtonRequestGeoLocation {
12400
12714
  _: 'keyboardButtonRequestGeoLocation';
12715
+ /**
12716
+ * Button style, see
12717
+ * <a href="https://corefork.telegram.org/api/bots/buttons#button-styles">here
12718
+ * »</a> for more info on button styles.
12719
+ */
12401
12720
  style?: tl.TypeKeyboardButtonStyle;
12402
12721
  /**
12403
12722
  * Button text
@@ -12418,6 +12737,11 @@ export class RpcError extends Error {
12418
12737
  * chat's input field.
12419
12738
  */
12420
12739
  samePeer?: boolean;
12740
+ /**
12741
+ * Button style, see
12742
+ * <a href="https://corefork.telegram.org/api/bots/buttons#button-styles">here
12743
+ * »</a> for more info on button styles.
12744
+ */
12421
12745
  style?: tl.TypeKeyboardButtonStyle;
12422
12746
  /**
12423
12747
  * Button label
@@ -12437,6 +12761,11 @@ export class RpcError extends Error {
12437
12761
  */
12438
12762
  interface RawKeyboardButtonGame {
12439
12763
  _: 'keyboardButtonGame';
12764
+ /**
12765
+ * Button style, see
12766
+ * <a href="https://corefork.telegram.org/api/bots/buttons#button-styles">here
12767
+ * »</a> for more info on button styles.
12768
+ */
12440
12769
  style?: tl.TypeKeyboardButtonStyle;
12441
12770
  /**
12442
12771
  * Button text
@@ -12448,6 +12777,11 @@ export class RpcError extends Error {
12448
12777
  */
12449
12778
  interface RawKeyboardButtonBuy {
12450
12779
  _: 'keyboardButtonBuy';
12780
+ /**
12781
+ * Button style, see
12782
+ * <a href="https://corefork.telegram.org/api/bots/buttons#button-styles">here
12783
+ * »</a> for more info on button styles.
12784
+ */
12451
12785
  style?: tl.TypeKeyboardButtonStyle;
12452
12786
  /**
12453
12787
  * Button text
@@ -12478,6 +12812,11 @@ export class RpcError extends Error {
12478
12812
  */
12479
12813
  interface RawKeyboardButtonUrlAuth {
12480
12814
  _: 'keyboardButtonUrlAuth';
12815
+ /**
12816
+ * Button style, see
12817
+ * <a href="https://corefork.telegram.org/api/bots/buttons#button-styles">here
12818
+ * »</a> for more info on button styles.
12819
+ */
12481
12820
  style?: tl.TypeKeyboardButtonStyle;
12482
12821
  /**
12483
12822
  * Button label
@@ -12524,6 +12863,11 @@ export class RpcError extends Error {
12524
12863
  * messages to the user.
12525
12864
  */
12526
12865
  requestWriteAccess?: boolean;
12866
+ /**
12867
+ * Button style, see
12868
+ * <a href="https://corefork.telegram.org/api/bots/buttons#button-styles">here
12869
+ * »</a> for more info on button styles.
12870
+ */
12527
12871
  style?: tl.TypeKeyboardButtonStyle;
12528
12872
  /**
12529
12873
  * Button text
@@ -12567,6 +12911,11 @@ export class RpcError extends Error {
12567
12911
  */
12568
12912
  interface RawKeyboardButtonRequestPoll {
12569
12913
  _: 'keyboardButtonRequestPoll';
12914
+ /**
12915
+ * Button style, see
12916
+ * <a href="https://corefork.telegram.org/api/bots/buttons#button-styles">here
12917
+ * »</a> for more info on button styles.
12918
+ */
12570
12919
  style?: tl.TypeKeyboardButtonStyle;
12571
12920
  /**
12572
12921
  * If set, only quiz polls can be sent
@@ -12582,6 +12931,11 @@ export class RpcError extends Error {
12582
12931
  */
12583
12932
  interface RawInputKeyboardButtonUserProfile {
12584
12933
  _: 'inputKeyboardButtonUserProfile';
12934
+ /**
12935
+ * Button style, see
12936
+ * <a href="https://corefork.telegram.org/api/bots/buttons#button-styles">here
12937
+ * »</a> for more info on button styles.
12938
+ */
12585
12939
  style?: tl.TypeKeyboardButtonStyle;
12586
12940
  /**
12587
12941
  * Button text
@@ -12597,6 +12951,11 @@ export class RpcError extends Error {
12597
12951
  */
12598
12952
  interface RawKeyboardButtonUserProfile {
12599
12953
  _: 'keyboardButtonUserProfile';
12954
+ /**
12955
+ * Button style, see
12956
+ * <a href="https://corefork.telegram.org/api/bots/buttons#button-styles">here
12957
+ * »</a> for more info on button styles.
12958
+ */
12600
12959
  style?: tl.TypeKeyboardButtonStyle;
12601
12960
  /**
12602
12961
  * Button text
@@ -12620,6 +12979,11 @@ export class RpcError extends Error {
12620
12979
  */
12621
12980
  interface RawKeyboardButtonWebView {
12622
12981
  _: 'keyboardButtonWebView';
12982
+ /**
12983
+ * Button style, see
12984
+ * <a href="https://corefork.telegram.org/api/bots/buttons#button-styles">here
12985
+ * »</a> for more info on button styles.
12986
+ */
12623
12987
  style?: tl.TypeKeyboardButtonStyle;
12624
12988
  /**
12625
12989
  * Button text
@@ -12643,6 +13007,11 @@ export class RpcError extends Error {
12643
13007
  */
12644
13008
  interface RawKeyboardButtonSimpleWebView {
12645
13009
  _: 'keyboardButtonSimpleWebView';
13010
+ /**
13011
+ * Button style, see
13012
+ * <a href="https://corefork.telegram.org/api/bots/buttons#button-styles">here
13013
+ * »</a> for more info on button styles.
13014
+ */
12646
13015
  style?: tl.TypeKeyboardButtonStyle;
12647
13016
  /**
12648
13017
  * Button text
@@ -12661,6 +13030,11 @@ export class RpcError extends Error {
12661
13030
  */
12662
13031
  interface RawKeyboardButtonRequestPeer {
12663
13032
  _: 'keyboardButtonRequestPeer';
13033
+ /**
13034
+ * Button style, see
13035
+ * <a href="https://corefork.telegram.org/api/bots/buttons#button-styles">here
13036
+ * »</a> for more info on button styles.
13037
+ */
12664
13038
  style?: tl.TypeKeyboardButtonStyle;
12665
13039
  /**
12666
13040
  * Button text
@@ -12707,6 +13081,11 @@ export class RpcError extends Error {
12707
13081
  * Set this flag to request the peer's photo (if any).
12708
13082
  */
12709
13083
  photoRequested?: boolean;
13084
+ /**
13085
+ * Button style, see
13086
+ * <a href="https://corefork.telegram.org/api/bots/buttons#button-styles">here
13087
+ * »</a> for more info on button styles.
13088
+ */
12710
13089
  style?: tl.TypeKeyboardButtonStyle;
12711
13090
  /**
12712
13091
  * Button text
@@ -12739,6 +13118,11 @@ export class RpcError extends Error {
12739
13118
  */
12740
13119
  interface RawKeyboardButtonCopy {
12741
13120
  _: 'keyboardButtonCopy';
13121
+ /**
13122
+ * Button style, see
13123
+ * <a href="https://corefork.telegram.org/api/bots/buttons#button-styles">here
13124
+ * »</a> for more info on button styles.
13125
+ */
12742
13126
  style?: tl.TypeKeyboardButtonStyle;
12743
13127
  /**
12744
13128
  * Title of the button
@@ -13319,6 +13703,76 @@ export class RpcError extends Error {
13319
13703
  length: number;
13320
13704
  date: number;
13321
13705
  }
13706
+ /**
13707
+ * Represents an diff addition: render it by simply
13708
+ * <u>underlining</u> the specified section and coloring it in
13709
+ * green, see
13710
+ * <a href="https://corefork.telegram.org/api/entities#diff-entities">here
13711
+ * »</a> for more info on how to render diff entities.
13712
+ */
13713
+ interface RawMessageEntityDiffInsert {
13714
+ _: 'messageEntityDiffInsert';
13715
+ /**
13716
+ * Offset of message entity within message (in
13717
+ * <a href="https://corefork.telegram.org/api/entities#entity-length">UTF-16
13718
+ * code units</a>)
13719
+ */
13720
+ offset: number;
13721
+ /**
13722
+ * Length of message entity within message (in
13723
+ * <a href="https://corefork.telegram.org/api/entities#entity-length">UTF-16
13724
+ * code units</a>)
13725
+ */
13726
+ length: number;
13727
+ }
13728
+ /**
13729
+ * Represents an diff replacement, render it as follows:
13730
+ *
13731
+ * See
13732
+ * <a href="https://corefork.telegram.org/api/entities#diff-entities">here
13733
+ * »</a> for more info on how to render diff entities.
13734
+ */
13735
+ interface RawMessageEntityDiffReplace {
13736
+ _: 'messageEntityDiffReplace';
13737
+ /**
13738
+ * Offset of message entity within message (in
13739
+ * <a href="https://corefork.telegram.org/api/entities#entity-length">UTF-16
13740
+ * code units</a>)
13741
+ */
13742
+ offset: number;
13743
+ /**
13744
+ * Length of message entity within message (in
13745
+ * <a href="https://corefork.telegram.org/api/entities#entity-length">UTF-16
13746
+ * code units</a>)
13747
+ */
13748
+ length: number;
13749
+ /**
13750
+ * The chunk of text that was removed.
13751
+ */
13752
+ oldText: string;
13753
+ }
13754
+ /**
13755
+ * Represents an diff deletion: render it by simply
13756
+ * <u>underlining</u> the specified section and coloring it in
13757
+ * red, see
13758
+ * <a href="https://corefork.telegram.org/api/entities#diff-entities">here
13759
+ * »</a> for more info on how to render diff entities.
13760
+ */
13761
+ interface RawMessageEntityDiffDelete {
13762
+ _: 'messageEntityDiffDelete';
13763
+ /**
13764
+ * Offset of message entity within message (in
13765
+ * <a href="https://corefork.telegram.org/api/entities#entity-length">UTF-16
13766
+ * code units</a>)
13767
+ */
13768
+ offset: number;
13769
+ /**
13770
+ * Length of message entity within message (in
13771
+ * <a href="https://corefork.telegram.org/api/entities#entity-length">UTF-16
13772
+ * code units</a>)
13773
+ */
13774
+ length: number;
13775
+ }
13322
13776
  /**
13323
13777
  * Represents the absence of a channel
13324
13778
  */
@@ -13414,6 +13868,10 @@ export class RpcError extends Error {
13414
13868
  * participant.
13415
13869
  */
13416
13870
  subscriptionUntilDate?: number;
13871
+ /**
13872
+ * The participant's
13873
+ * <a href="https://corefork.telegram.org/api/rank">tag »</a>.
13874
+ */
13417
13875
  rank?: string;
13418
13876
  }
13419
13877
  /**
@@ -13444,6 +13902,10 @@ export class RpcError extends Error {
13444
13902
  * participant.
13445
13903
  */
13446
13904
  subscriptionUntilDate?: number;
13905
+ /**
13906
+ * The participant's
13907
+ * <a href="https://corefork.telegram.org/api/rank">tag »</a>.
13908
+ */
13447
13909
  rank?: string;
13448
13910
  }
13449
13911
  /**
@@ -13460,8 +13922,9 @@ export class RpcError extends Error {
13460
13922
  */
13461
13923
  adminRights: tl.TypeChatAdminRights;
13462
13924
  /**
13463
- * The role (rank) of the group creator in the group: just an
13464
- * arbitrary string, <code>admin</code> by default
13925
+ * The participant's
13926
+ * <a href="https://corefork.telegram.org/api/rank">tag »</a>,
13927
+ * defaults to "Owner" if not set.
13465
13928
  */
13466
13929
  rank?: string;
13467
13930
  }
@@ -13501,8 +13964,9 @@ export class RpcError extends Error {
13501
13964
  */
13502
13965
  adminRights: tl.TypeChatAdminRights;
13503
13966
  /**
13504
- * The role (rank) of the admin in the group: just an arbitrary
13505
- * string, <code>admin</code> by default
13967
+ * The participant's
13968
+ * <a href="https://corefork.telegram.org/api/rank">tag »</a>,
13969
+ * defaults to "Admin" if not set.
13506
13970
  */
13507
13971
  rank?: string;
13508
13972
  }
@@ -13532,6 +13996,10 @@ export class RpcError extends Error {
13532
13996
  * <a href="https://corefork.telegram.org/api/rights">rights</a>
13533
13997
  */
13534
13998
  bannedRights: tl.TypeChatBannedRights;
13999
+ /**
14000
+ * The participant's
14001
+ * <a href="https://corefork.telegram.org/api/rank">tag »</a>.
14002
+ */
13535
14003
  rank?: string;
13536
14004
  }
13537
14005
  /**
@@ -14552,6 +15020,9 @@ export class RpcError extends Error {
14552
15020
  interface RawTopPeerCategoryBotsApp {
14553
15021
  _: 'topPeerCategoryBotsApp';
14554
15022
  }
15023
+ interface RawTopPeerCategoryBotsGuestChat {
15024
+ _: 'topPeerCategoryBotsGuestChat';
15025
+ }
14555
15026
  /**
14556
15027
  * Top peer category
14557
15028
  */
@@ -16174,8 +16645,8 @@ export class RpcError extends Error {
16174
16645
  duration?: number;
16175
16646
  }
16176
16647
  /**
16177
- * Identifies an endpoint that can be used to connect to the
16178
- * other user in a phone call
16648
+ * DEPRECATED (libtgvoip): Identifies an endpoint that can be
16649
+ * used to connect to the other user in a phone call
16179
16650
  */
16180
16651
  interface RawPhoneConnection {
16181
16652
  _: 'phoneConnection';
@@ -17100,10 +17571,24 @@ export class RpcError extends Error {
17100
17571
  */
17101
17572
  newValue: boolean;
17102
17573
  }
17574
+ /**
17575
+ * A participant's
17576
+ * <a href="https://corefork.telegram.org/api/rank">tag »</a>
17577
+ * was changed.
17578
+ */
17103
17579
  interface RawChannelAdminLogEventActionParticipantEditRank {
17104
17580
  _: 'channelAdminLogEventActionParticipantEditRank';
17581
+ /**
17582
+ * The user ID.
17583
+ */
17105
17584
  userId: number;
17585
+ /**
17586
+ * The previous tag.
17587
+ */
17106
17588
  prevRank: string;
17589
+ /**
17590
+ * The new tag.
17591
+ */
17107
17592
  newRank: string;
17108
17593
  }
17109
17594
  /**
@@ -18574,6 +19059,11 @@ export class RpcError extends Error {
18574
19059
  addedBy?: tl.TypePeer;
18575
19060
  date?: number;
18576
19061
  }
19062
+ interface RawInputPollAnswer {
19063
+ _: 'inputPollAnswer';
19064
+ text: tl.TypeTextWithEntities;
19065
+ media?: tl.TypeInputMedia;
19066
+ }
18577
19067
  /**
18578
19068
  * Poll
18579
19069
  */
@@ -18607,6 +19097,7 @@ export class RpcError extends Error {
18607
19097
  shuffleAnswers?: boolean;
18608
19098
  hideResultsUntilClose?: boolean;
18609
19099
  creator?: boolean;
19100
+ subscribersOnly?: boolean;
18610
19101
  /**
18611
19102
  * The question of the poll (only
18612
19103
  * <a href="https://corefork.telegram.org/api/premium">Premium</a>
@@ -18633,6 +19124,7 @@ export class RpcError extends Error {
18633
19124
  * close_period.
18634
19125
  */
18635
19126
  closeDate?: number;
19127
+ countriesIso2?: string[];
18636
19128
  hash: Long;
18637
19129
  }
18638
19130
  /**
@@ -18675,6 +19167,7 @@ export class RpcError extends Error {
18675
19167
  */
18676
19168
  min?: boolean;
18677
19169
  hasUnreadVotes?: boolean;
19170
+ canViewStats?: boolean;
18678
19171
  /**
18679
19172
  * Poll results
18680
19173
  */
@@ -18882,23 +19375,22 @@ export class RpcError extends Error {
18882
19375
  */
18883
19376
  sendPolls?: boolean;
18884
19377
  /**
18885
- * If set, does not allow any user to change the description of
18886
- * a
19378
+ * If set, does not allow a user to change the description of a
18887
19379
  * <a href="https://corefork.telegram.org/api/channel">supergroup/chat</a>
18888
19380
  */
18889
19381
  changeInfo?: boolean;
18890
19382
  /**
18891
- * If set, does not allow any user to invite users in a
19383
+ * If set, does not allow a user to invite users in a
18892
19384
  * <a href="https://corefork.telegram.org/api/channel">supergroup/chat</a>
18893
19385
  */
18894
19386
  inviteUsers?: boolean;
18895
19387
  /**
18896
- * If set, does not allow any user to pin messages in a
19388
+ * If set, does not allow a user to pin messages in a
18897
19389
  * <a href="https://corefork.telegram.org/api/channel">supergroup/chat</a>
18898
19390
  */
18899
19391
  pinMessages?: boolean;
18900
19392
  /**
18901
- * If set, does not allow any user to create, delete or modify
19393
+ * If set, does not allow a user to create, delete or modify
18902
19394
  * <a href="https://corefork.telegram.org/api/forum#forum-topics">forum
18903
19395
  * topics »</a>.
18904
19396
  */
@@ -18939,6 +19431,7 @@ export class RpcError extends Error {
18939
19431
  */
18940
19432
  sendPlain?: boolean;
18941
19433
  editRank?: boolean;
19434
+ sendReactions?: boolean;
18942
19435
  /**
18943
19436
  * Validity of said permissions (it is considered forever any
18944
19437
  * value less then 30 seconds or more then 366 days).
@@ -19740,11 +20233,29 @@ export class RpcError extends Error {
19740
20233
  */
19741
20234
  icons: tl.TypeDocument[];
19742
20235
  }
20236
+ /**
20237
+ * Contains info about a
20238
+ * <a href="https://corefork.telegram.org/api/auctions">collectible
20239
+ * gift auction »</a> for a {@link RawWebPage} preview of an
20240
+ * <a href="https://corefork.telegram.org/api/auctions">auction
20241
+ * »</a> (the {@link RawWebPage} will have a <code>type</code>
20242
+ * of <code>telegram_auction</code>).
20243
+ */
19743
20244
  interface RawWebPageAttributeStarGiftAuction {
19744
20245
  _: 'webPageAttributeStarGiftAuction';
20246
+ /**
20247
+ * The gift linked to the auction
20248
+ */
19745
20249
  gift: tl.TypeStarGift;
20250
+ /**
20251
+ * Date when the auction will end (UNIX timestamp)
20252
+ */
19746
20253
  endDate: number;
19747
20254
  }
20255
+ interface RawWebPageAttributeAiComposeTone {
20256
+ _: 'webPageAttributeAiComposeTone';
20257
+ emojiId: Long;
20258
+ }
19748
20259
  /**
19749
20260
  * Credit card info URL provided by the bank
19750
20261
  */
@@ -21809,21 +22320,82 @@ export class RpcError extends Error {
21809
22320
  */
21810
22321
  hash: string;
21811
22322
  }
22323
+ /**
22324
+ * Used to pay for login codes, in case of high cost of SMS
22325
+ * verification codes for the user's country/provider, see
22326
+ * <a href="https://corefork.telegram.org/api/auth#paid-auth">here
22327
+ * »</a> for more info.
22328
+ */
21812
22329
  interface RawInputInvoicePremiumAuthCode {
21813
22330
  _: 'inputInvoicePremiumAuthCode';
22331
+ /**
22332
+ * Must contain an {@link RawInputStorePaymentAuthCode}.
22333
+ */
21814
22334
  purpose: tl.TypeInputStorePaymentPurpose;
21815
22335
  }
22336
+ /**
22337
+ * Used to pay for for the removal of the
22338
+ * {@link RawStarGiftAttributeOriginalDetails} attribute from a
22339
+ * collectible gift, see
22340
+ * <a href="https://corefork.telegram.org/api/gifts#dropping-the-original-details-of-an-upgraded-gift">here
22341
+ * »</a> for the full flow.
22342
+ */
21816
22343
  interface RawInputInvoiceStarGiftDropOriginalDetails {
21817
22344
  _: 'inputInvoiceStarGiftDropOriginalDetails';
22345
+ /**
22346
+ * The collectible gift whose
22347
+ * {@link RawStarGiftAttributeOriginalDetails} attribute should
22348
+ * be removed.
22349
+ */
21818
22350
  stargift: tl.TypeInputSavedStarGift;
21819
22351
  }
22352
+ /**
22353
+ * Used to place a bid in a
22354
+ * <a href="https://corefork.telegram.org/api/auctions">collectible
22355
+ * gift auction »</a>.
22356
+ */
21820
22357
  interface RawInputInvoiceStarGiftAuctionBid {
21821
22358
  _: 'inputInvoiceStarGiftAuctionBid';
22359
+ /**
22360
+ * If set, your name will be hidden if the destination peer
22361
+ * decides to display the gift on their profile (they will
22362
+ * still see that you sent the gift).
22363
+ *
22364
+ * Must not be set when updating an existing bid, as the
22365
+ * value cannot be changed for existing bids.
22366
+ */
21822
22367
  hideName?: boolean;
22368
+ /**
22369
+ * Must be set when increasing an already existing bid.
22370
+ */
21823
22371
  updateBid?: boolean;
22372
+ /**
22373
+ * Identifier of the user or channel (only if
22374
+ * {@link RawChannelFull}.<code>stargifts_available</code> is
22375
+ * set) that will receive the gift.
22376
+ */
21824
22377
  peer?: tl.TypeInputPeer;
22378
+ /**
22379
+ * Identifier of the gift, from
22380
+ * {@link RawStarGift}.<code>id</code>
22381
+ */
21825
22382
  giftId: Long;
22383
+ /**
22384
+ * Total amount of the bid in
22385
+ * <a href="https://corefork.telegram.org/api/stars">Telegram
22386
+ * Stars</a>.
22387
+ */
21826
22388
  bidAmount: Long;
22389
+ /**
22390
+ * Optional message that will be attached with the gift if we
22391
+ * end up winning this round: the maximum length for this field
22392
+ * is specified in the
22393
+ * <a href="https://corefork.telegram.org/api/config#stargifts-message-length-max">stargifts_message_length_max
22394
+ * client configuration value »</a>.
22395
+ *
22396
+ * Must not be set when updating an existing bid, as the
22397
+ * value cannot be changed for existing bids.
22398
+ */
21827
22399
  message?: tl.TypeTextWithEntities;
21828
22400
  }
21829
22401
  /**
@@ -22163,6 +22735,7 @@ export class RpcError extends Error {
22163
22735
  * {@link auth.RawSendCodeRequest}.
22164
22736
  */
22165
22737
  phoneCodeHash: string;
22738
+ premiumDays: number;
22166
22739
  /**
22167
22740
  * Three-letter ISO 4217
22168
22741
  * <a href="https://corefork.telegram.org/bots/payments#supported-currencies">currency</a>
@@ -22621,7 +23194,7 @@ export class RpcError extends Error {
22621
23194
  * log events »</a> and in the
22622
23195
  * {@link messages.RawChannelMessages} constructor: if needed,
22623
23196
  * full information can be fetched using
22624
- * {@link channels.RawGetForumTopicsByIDRequest}.
23197
+ * {@link messages.RawGetForumTopicsByIDRequest}.
22625
23198
  */
22626
23199
  short?: boolean;
22627
23200
  /**
@@ -22639,6 +23212,10 @@ export class RpcError extends Error {
22639
23212
  * Topic creation date
22640
23213
  */
22641
23214
  date: number;
23215
+ /**
23216
+ * Contains the supergroup/private chat where the topic is
23217
+ * located.
23218
+ */
22642
23219
  peer: tl.TypePeer;
22643
23220
  /**
22644
23221
  * Topic title
@@ -22814,6 +23391,12 @@ export class RpcError extends Error {
22814
23391
  */
22815
23392
  botAdminRights?: tl.TypeChatAdminRights;
22816
23393
  }
23394
+ interface RawRequestPeerTypeCreateBot {
23395
+ _: 'requestPeerTypeCreateBot';
23396
+ botManaged?: boolean;
23397
+ suggestedName?: string;
23398
+ suggestedUsername?: string;
23399
+ }
22817
23400
  /**
22818
23401
  * The list of
22819
23402
  * <a href="https://corefork.telegram.org/api/custom-emoji">custom
@@ -23260,7 +23843,7 @@ export class RpcError extends Error {
23260
23843
  min?: boolean;
23261
23844
  /**
23262
23845
  * Whether this story is
23263
- * <a href="https://telegram.org/blog/protected-content-delete-by-date-and-more">protected</a>
23846
+ * <a href="https://telegram.org/blog/content-protection-delete-by-date-and-more">protected</a>
23264
23847
  * and thus cannot be forwarded; clients should also prevent
23265
23848
  * users from saving attached media (i.e. videos should only be
23266
23849
  * streamed, photos should be kept in RAM, et cetera).
@@ -24148,18 +24731,73 @@ export class RpcError extends Error {
24148
24731
  */
24149
24732
  backgroundEmojiId?: Long;
24150
24733
  }
24734
+ /**
24735
+ * Represents a
24736
+ * <a href="https://corefork.telegram.org/api/colors">color
24737
+ * palette »</a> associated to a
24738
+ * <a href="https://corefork.telegram.org/api/gifts#collectible-gifts">collectible
24739
+ * gift »</a>, see
24740
+ * <a href="https://corefork.telegram.org/api/colors#collectible-gift-palettes">here
24741
+ * »</a> for more info.
24742
+ */
24151
24743
  interface RawPeerColorCollectible {
24152
24744
  _: 'peerColorCollectible';
24745
+ /**
24746
+ * ID of the
24747
+ * <a href="https://corefork.telegram.org/api/gifts#collectible-gifts">collectible
24748
+ * gift »</a>.
24749
+ */
24153
24750
  collectibleId: Long;
24751
+ /**
24752
+ * <a href="https://corefork.telegram.org/api/custom-emoji">Custom
24753
+ * emoji ID »</a> of the collectible gift: a single copy of
24754
+ * this custom emoji should be displayed as-is (without
24755
+ * recoloring it, unlike for <code>background_emoji_id</code>)
24756
+ * in the top-right corner of the palette.
24757
+ */
24154
24758
  giftEmojiId: Long;
24759
+ /**
24760
+ * <a href="https://corefork.telegram.org/api/custom-emoji">Custom
24761
+ * emoji ID »</a> used to generate the pattern.
24762
+ */
24155
24763
  backgroundEmojiId: Long;
24764
+ /**
24765
+ * Accent color in RGB24 format, used for reply backgrounds and
24766
+ * the user's name in messages.
24767
+ */
24156
24768
  accentColor: number;
24769
+ /**
24770
+ * 1-3 RGB24 colors to be used in the reply strip.
24771
+ */
24157
24772
  colors: number[];
24773
+ /**
24774
+ * Accent color in RGB24 format, used for reply backgrounds and
24775
+ * the user's name in messages in dark mode (fallback to
24776
+ * <code>accent_color</code> if absent).
24777
+ */
24158
24778
  darkAccentColor?: number;
24779
+ /**
24780
+ * 1-3 RGB24 colors to be used in the reply strip in dark mode
24781
+ * (fallback to <code>colors</code> if absent).
24782
+ */
24159
24783
  darkColors?: number[];
24160
24784
  }
24785
+ /**
24786
+ * Represents a
24787
+ * <a href="https://corefork.telegram.org/api/colors">color
24788
+ * palette »</a> associated to a
24789
+ * <a href="https://corefork.telegram.org/api/gifts#collectible-gifts">collectible
24790
+ * gift »</a>, see
24791
+ * <a href="https://corefork.telegram.org/api/colors#collectible-gift-palettes">here
24792
+ * »</a> for more info.
24793
+ */
24161
24794
  interface RawInputPeerColorCollectible {
24162
24795
  _: 'inputPeerColorCollectible';
24796
+ /**
24797
+ * ID of the
24798
+ * <a href="https://corefork.telegram.org/api/gifts#collectible-gifts">collectible
24799
+ * gift »</a>.
24800
+ */
24163
24801
  collectibleId: Long;
24164
24802
  }
24165
24803
  /**
@@ -25476,8 +26114,20 @@ export class RpcError extends Error {
25476
26114
  * prepaid upgrade of a gift</a>.
25477
26115
  */
25478
26116
  stargiftPrepaidUpgrade?: boolean;
26117
+ /**
26118
+ * Represents payment for the removal of the
26119
+ * {@link RawStarGiftAttributeOriginalDetails} attribute from a
26120
+ * gift, see
26121
+ * <a href="https://corefork.telegram.org/api/gifts#dropping-the-original-details-of-an-upgraded-gift">here
26122
+ * »</a> for the full flow.
26123
+ */
25479
26124
  stargiftDropOriginalDetails?: boolean;
25480
26125
  phonegroupMessage?: boolean;
26126
+ /**
26127
+ * Represents payment for placing a
26128
+ * <a href="https://corefork.telegram.org/api/auctions">collectible
26129
+ * gift auction bid »</a>.
26130
+ */
25481
26131
  stargiftAuctionBid?: boolean;
25482
26132
  offer?: boolean;
25483
26133
  /**
@@ -25999,6 +26649,12 @@ export class RpcError extends Error {
25999
26649
  */
26000
26650
  limitedPerUser?: boolean;
26001
26651
  peerColorAvailable?: boolean;
26652
+ /**
26653
+ * If set, this is a collectible gift that can only be bought
26654
+ * through a
26655
+ * <a href="https://corefork.telegram.org/api/auctions">collectible
26656
+ * gift auction »</a>.
26657
+ */
26002
26658
  auction?: boolean;
26003
26659
  /**
26004
26660
  * Identifier of the gift
@@ -26089,8 +26745,28 @@ export class RpcError extends Error {
26089
26745
  * for the full flow.
26090
26746
  */
26091
26747
  lockedUntilDate?: number;
26748
+ /**
26749
+ * Always set for gifts that can be bought on
26750
+ * <a href="https://corefork.telegram.org/api/auctions">auctions
26751
+ * »</a>, contains the
26752
+ * <a href="https://corefork.telegram.org/api/links#auction-links">auction
26753
+ * deep link slug »</a>.
26754
+ */
26092
26755
  auctionSlug?: string;
26756
+ /**
26757
+ * Always set for gifts that can be bought on
26758
+ * <a href="https://corefork.telegram.org/api/auctions">auctions
26759
+ * »</a>, contains the number of gifts of this kind that are
26760
+ * distributed on every round.
26761
+ */
26093
26762
  giftsPerRound?: number;
26763
+ /**
26764
+ * Always set for gifts that can be bought on
26765
+ * <a href="https://corefork.telegram.org/api/auctions">auctions
26766
+ * »</a>, contains the UNIX timestamp indicating when will the
26767
+ * auction start (or when the auction started, if it points to
26768
+ * the past).
26769
+ */
26094
26770
  auctionStartDate?: number;
26095
26771
  upgradeVariants?: number;
26096
26772
  background?: tl.TypeStarGiftBackground;
@@ -26414,11 +27090,11 @@ export class RpcError extends Error {
26414
27090
  amount: Long;
26415
27091
  /**
26416
27092
  * The decimal amount of Telegram Stars, expressed as nanostars
26417
- * (i.e. 1 nanostar is equal to <code>1/1'000'000'000</code>th
27093
+ * (i.e. 1 nanostar is equal to <code>1/1_000_000_000</code>th
26418
27094
  * (one billionth) of a Telegram Star).
26419
27095
  *
26420
- * This field may also be negative (the allowed range is
26421
- * -999999999 to 999999999).
27096
+ * This field may also be negative (the allowed range is from
27097
+ * <code>-999_999_999</code> to <code>999_999_999</code>).
26422
27098
  */
26423
27099
  nanos: number;
26424
27100
  }
@@ -26705,6 +27381,13 @@ export class RpcError extends Error {
26705
27381
  * to prepay for a gift upgrade separately »</a>.
26706
27382
  */
26707
27383
  prepaidUpgradeHash?: string;
27384
+ /**
27385
+ * If set, the {@link RawStarGiftAttributeOriginalDetails}
27386
+ * attribute of this gift may be removed by paying the
27387
+ * specified amount of stars, see
27388
+ * <a href="https://corefork.telegram.org/api/gifts#dropping-the-original-details-of-an-upgraded-gift">here
27389
+ * »</a> for the full flow.
27390
+ */
26708
27391
  dropOriginalDetailsStars?: Long;
26709
27392
  giftNum?: number;
26710
27393
  canCraftAt?: number;
@@ -26763,7 +27446,8 @@ export class RpcError extends Error {
26763
27446
  }
26764
27447
  /**
26765
27448
  * Send paid reactions as the specified peer, fetched using
26766
- * {@link channels.RawGetSendAsRequest}.
27449
+ * {@link channels.RawGetSendAsRequest} with the
27450
+ * <code>for_paid_reactions</code> flag set.
26767
27451
  */
26768
27452
  interface RawPaidReactionPrivacyPeer {
26769
27453
  _: 'paidReactionPrivacyPeer';
@@ -27308,9 +27992,20 @@ export class RpcError extends Error {
27308
27992
  */
27309
27993
  slug: string;
27310
27994
  }
27995
+ /**
27996
+ * Indicates the price for a
27997
+ * <a href="https://corefork.telegram.org/api/gifts#collectible-gifts">gift
27998
+ * upgrade »</a> starting from a specific point in time.
27999
+ */
27311
28000
  interface RawStarGiftUpgradePrice {
27312
28001
  _: 'starGiftUpgradePrice';
28002
+ /**
28003
+ * UNIX timestamp indicating when the price will be in effect.
28004
+ */
27313
28005
  date: number;
28006
+ /**
28007
+ * Upgrade price.
28008
+ */
27314
28009
  upgradeStars: Long;
27315
28010
  }
27316
28011
  interface RawGroupCallMessage {
@@ -27334,97 +28029,427 @@ export class RpcError extends Error {
27334
28029
  live?: boolean;
27335
28030
  maxId?: number;
27336
28031
  }
28032
+ /**
28033
+ * Describes a bid in an
28034
+ * <a href="https://corefork.telegram.org/api/auctions">auction</a>.
28035
+ */
27337
28036
  interface RawAuctionBidLevel {
27338
28037
  _: 'auctionBidLevel';
28038
+ /**
28039
+ * Position of the bid.
28040
+ */
27339
28041
  pos: number;
28042
+ /**
28043
+ * Amount of the bid in
28044
+ * <a href="https://corefork.telegram.org/api/stars">Telegram
28045
+ * Stars</a>.
28046
+ */
27340
28047
  amount: Long;
28048
+ /**
28049
+ * Date when the bid was placed.
28050
+ */
27341
28051
  date: number;
27342
28052
  }
28053
+ /**
28054
+ * Returned only by auction methods (never by updates) if the
28055
+ * passed <code>version</code> is equal to the remote
28056
+ * <a href="https://corefork.telegram.org/api/auctions">auction
28057
+ * »</a>.<code>version</code>, meaning auction information
28058
+ * hasn't changed over the locally cached version.
28059
+ */
27343
28060
  interface RawStarGiftAuctionStateNotModified {
27344
28061
  _: 'starGiftAuctionStateNotModified';
27345
28062
  }
28063
+ /**
28064
+ * Represents an active or pending
28065
+ * <a href="https://corefork.telegram.org/api/auctions">auction
28066
+ * »</a>.
28067
+ */
27346
28068
  interface RawStarGiftAuctionState {
27347
28069
  _: 'starGiftAuctionState';
28070
+ /**
28071
+ * Only apply incoming {@link RawStarGiftAuctionState}
28072
+ * constructors if the received <code>version</code> is bigger
28073
+ * than the locally cached <code>version</code>.
28074
+ */
27348
28075
  version: number;
28076
+ /**
28077
+ * UNIX timestamp indicating when the auction will start (or
28078
+ * when it started, if it's in the past).
28079
+ */
27349
28080
  startDate: number;
28081
+ /**
28082
+ * UNIX timestamp indicating when the auction will end
28083
+ */
27350
28084
  endDate: number;
28085
+ /**
28086
+ * Minumum allowed bid amount in
28087
+ * <a href="https://corefork.telegram.org/api/stars">Telegram
28088
+ * Stars</a>: only applicable if the user hasn't made a bid
28089
+ * yet, otherwise must be overridden to the value of
28090
+ * {@link RawStarGiftAuctionUserState}.<code>min_bid_amount</code>
28091
+ * (which will be set if and only if the user already made a
28092
+ * bid to this auction).
28093
+ */
27351
28094
  minBidAmount: Long;
28095
+ /**
28096
+ * Contains a sparse list of bids starting from the top bids, a
28097
+ * more detailed description is available in
28098
+ * <a href="https://corefork.telegram.org/api/auctions">the
28099
+ * docs</a>.
28100
+ */
27352
28101
  bidLevels: tl.TypeAuctionBidLevel[];
28102
+ /**
28103
+ * User IDs of the top 3 bidders (the {@link RawUser}
28104
+ * constructors will be returned as
28105
+ * <a href="https://corefork.telegram.org/api/min">min</a>
28106
+ * constructors in the containing object).
28107
+ */
27353
28108
  topBidders: Long[];
28109
+ /**
28110
+ * UNIX timestamp indicating when the current auction round
28111
+ * will end, distributing
28112
+ * {@link RawStarGift}.<code>gifts_per_round</code> gifts to
28113
+ * the top {@link RawStarGift}.<code>gifts_per_round</code>
28114
+ * bidders.
28115
+ */
27354
28116
  nextRoundAt: number;
28117
+ /**
28118
+ * The number of gifts that were distributed in the previous
28119
+ * round (also used to compute the approximated index of the
28120
+ * gift that the current user will receive, <code>last_gift_num
28121
+ * + approx_pos</code>, see
28122
+ * <a href="https://corefork.telegram.org/api/auctions">here
28123
+ * »</a> for more info).
28124
+ */
27355
28125
  lastGiftNum: number;
28126
+ /**
28127
+ * The remaining number of gifts that are yet to be
28128
+ * distributed.
28129
+ */
27356
28130
  giftsLeft: number;
28131
+ /**
28132
+ * The current round number (starting from 1).
28133
+ */
27357
28134
  currentRound: number;
28135
+ /**
28136
+ * The total number of rounds in this auction.
28137
+ */
27358
28138
  totalRounds: number;
28139
+ /**
28140
+ * Detailed round information.
28141
+ */
27359
28142
  rounds: tl.TypeStarGiftAuctionRound[];
27360
28143
  }
28144
+ /**
28145
+ * Represents a finished
28146
+ * <a href="https://corefork.telegram.org/api/auctions">auction
28147
+ * »</a>.
28148
+ */
27361
28149
  interface RawStarGiftAuctionStateFinished {
27362
28150
  _: 'starGiftAuctionStateFinished';
28151
+ /**
28152
+ * UNIX timestamp indicating when the auction started.
28153
+ */
27363
28154
  startDate: number;
28155
+ /**
28156
+ * UNIX timestamp indicating when the auction ended.
28157
+ */
27364
28158
  endDate: number;
28159
+ /**
28160
+ * Average price of distributed gifts.
28161
+ */
27365
28162
  averagePrice: Long;
28163
+ /**
28164
+ * Number of gifts from the auction currently being resold on
28165
+ * Telegram: if set, when the corresponding element is clicked
28166
+ * in graphical clients,
28167
+ * {@link payments.RawGetResaleStarGiftsRequest} should be
28168
+ * invoked with the ID of the gift associated to this auction,
28169
+ * see
28170
+ * <a href="https://corefork.telegram.org/api/auctions">here
28171
+ * »</a> for more info.
28172
+ */
27366
28173
  listedCount?: number;
28174
+ /**
28175
+ * Number of gifts from the auction currently being resold on
28176
+ * <a href="https://fragment.com/">Fragment</a>.
28177
+ */
27367
28178
  fragmentListedCount?: number;
28179
+ /**
28180
+ * Only set if <code>fragment_listed_count</code> is set. If
28181
+ * set, when the corresponding element is clicked in graphical
28182
+ * clients, this URL should be opened.
28183
+ */
27368
28184
  fragmentListedUrl?: string;
27369
28185
  }
28186
+ /**
28187
+ * Contains information about the current user's state in an
28188
+ * <a href="https://corefork.telegram.org/api/auctions">auction
28189
+ * »</a>.
28190
+ *
28191
+ * The <code>bid_amount</code>, <code>bid_date</code>,
28192
+ * <code>bid_peer</code> and <code>min_bid_amount</code> flags
28193
+ * of {@link RawStarGiftAuctionUserState} will all be set if
28194
+ * the user placed a bid in the auction.
28195
+ */
27370
28196
  interface RawStarGiftAuctionUserState {
27371
28197
  _: 'starGiftAuctionUserState';
28198
+ /**
28199
+ * If set, the placed bid was returned to the user, because it
28200
+ * was outbid so much that it fell out of the top
28201
+ * {@link RawStarGiftAuctionState}.<code>gifts_left</code>
28202
+ * positions, meaning that even if no new bids are placed, the
28203
+ * user will never receive any gifts, so the bid was completely
28204
+ * removed from the auction, and in order to participate again
28205
+ * the user must manually make a new bid.
28206
+ */
27372
28207
  returned?: boolean;
28208
+ /**
28209
+ * Contains the amount of the placed bid in
28210
+ * <a href="https://corefork.telegram.org/api/stars">Telegram
28211
+ * Stars</a>.
28212
+ */
27373
28213
  bidAmount?: Long;
28214
+ /**
28215
+ * Contains a UNIX timestamp, indicating when the bid was
28216
+ * placed.
28217
+ */
27374
28218
  bidDate?: number;
28219
+ /**
28220
+ * Contains the minumum allowed bid amount in
28221
+ * <a href="https://corefork.telegram.org/api/stars">Telegram
28222
+ * Stars</a>, if set overrides
28223
+ * {@link RawStarGiftAuctionState}.<code>min_bid_amount</code>
28224
+ * for the current user.
28225
+ */
27375
28226
  minBidAmount?: Long;
28227
+ /**
28228
+ * Contains the peer that will receive the gift, if you end up
28229
+ * winning this round
28230
+ */
27376
28231
  bidPeer?: tl.TypePeer;
28232
+ /**
28233
+ * Contains the number of gifts that were purchased so far in
28234
+ * the auction by the current user.
28235
+ */
27377
28236
  acquiredCount: number;
27378
28237
  }
28238
+ /**
28239
+ * Describes a gift that the current user won in an auction.
28240
+ */
27379
28241
  interface RawStarGiftAuctionAcquiredGift {
27380
28242
  _: 'starGiftAuctionAcquiredGift';
28243
+ /**
28244
+ * If set, your name will be hidden if the destination peer
28245
+ * decides to display the gift on their profile (they will
28246
+ * still see that you sent the gift).
28247
+ */
27381
28248
  nameHidden?: boolean;
28249
+ /**
28250
+ * The peer that received the gift.
28251
+ */
27382
28252
  peer: tl.TypePeer;
28253
+ /**
28254
+ * When was the gift obtained.
28255
+ */
27383
28256
  date: number;
28257
+ /**
28258
+ * The amount in
28259
+ * <a href="https://corefork.telegram.org/api/stars">Telegram
28260
+ * Stars</a> that was bid in order to obtain the gift.
28261
+ */
27384
28262
  bidAmount: Long;
28263
+ /**
28264
+ * The round number where the gift was obtained.
28265
+ */
27385
28266
  round: number;
28267
+ /**
28268
+ * The position of the gift in the auction.
28269
+ */
27386
28270
  pos: number;
28271
+ /**
28272
+ * Optional message that attached with the gift, passed when
28273
+ * making the bid.
28274
+ */
27387
28275
  message?: tl.TypeTextWithEntities;
27388
28276
  giftNum?: number;
27389
28277
  }
28278
+ /**
28279
+ * Contains info about
28280
+ * <a href="https://corefork.telegram.org/api/auctions">an
28281
+ * auction where the user has placed a bid »</a>.
28282
+ */
27390
28283
  interface RawStarGiftActiveAuctionState {
27391
28284
  _: 'starGiftActiveAuctionState';
28285
+ /**
28286
+ * The
28287
+ * <a href="https://corefork.telegram.org/api/gifts#collectible-gifts">collectible
28288
+ * gift »</a> currently being distributed in the auction.
28289
+ */
27392
28290
  gift: tl.TypeStarGift;
28291
+ /**
28292
+ * Auction state
28293
+ */
27393
28294
  state: tl.TypeStarGiftAuctionState;
28295
+ /**
28296
+ * Auction state related to the current user (i.e. info about
28297
+ * placed bids, won gifts and so on).
28298
+ */
27394
28299
  userState: tl.TypeStarGiftAuctionUserState;
27395
28300
  }
28301
+ /**
28302
+ * Used to fetch
28303
+ * <a href="https://corefork.telegram.org/api/auctions">auctions</a>
28304
+ * using the ID of the linked
28305
+ * <a href="https://corefork.telegram.org/api/gifts#collectible-gifts">collectible
28306
+ * gift</a>.
28307
+ */
27396
28308
  interface RawInputStarGiftAuction {
27397
28309
  _: 'inputStarGiftAuction';
28310
+ /**
28311
+ * <a href="https://corefork.telegram.org/api/gifts#collectible-gifts">Collectible
28312
+ * gift ID</a>
28313
+ */
27398
28314
  giftId: Long;
27399
28315
  }
28316
+ /**
28317
+ * Used to fetch
28318
+ * <a href="https://corefork.telegram.org/api/auctions">auctions</a>
28319
+ * using the
28320
+ * <a href="https://corefork.telegram.org/api/links#auction-links">slug
28321
+ * of an auction deep link »</a>.
28322
+ */
27400
28323
  interface RawInputStarGiftAuctionSlug {
27401
28324
  _: 'inputStarGiftAuctionSlug';
28325
+ /**
28326
+ * <a href="https://corefork.telegram.org/api/links#auction-links">Auction
28327
+ * deep link slug »</a>.
28328
+ */
27402
28329
  slug: string;
27403
28330
  }
28331
+ /**
28332
+ * Human-readable info about a passkey associated to an
28333
+ * account, returned when
28334
+ * <a href="https://corefork.telegram.org/api/passkeys#creating-a-passkey">creating
28335
+ * a passkey »</a> or
28336
+ * <a href="https://corefork.telegram.org/api/passkeys#list-passkeys">listing
28337
+ * passkeys »</a>.
28338
+ */
27404
28339
  interface RawPasskey {
27405
28340
  _: 'passkey';
28341
+ /**
28342
+ * Unique passkey ID, usable for example in
28343
+ * {@link account.RawDeletePasskeyRequest}.
28344
+ */
27406
28345
  id: string;
28346
+ /**
28347
+ * Human-readable passkey name
28348
+ */
27407
28349
  name: string;
28350
+ /**
28351
+ * Creation date of the passkey
28352
+ */
27408
28353
  date: number;
28354
+ /**
28355
+ * ID of the
28356
+ * <a href="https://corefork.telegram.org/api/custom-emoji">custom
28357
+ * emoji</a> used as icon for the software or password manager
28358
+ * that created the passkey
28359
+ */
27409
28360
  softwareEmojiId?: Long;
28361
+ /**
28362
+ * Date when the passkey was last used to log in
28363
+ */
27410
28364
  lastUsageDate?: number;
27411
28365
  }
28366
+ /**
28367
+ * WebAuthn registration response used when registering a new
28368
+ * passkey, see
28369
+ * <a href="https://corefork.telegram.org/api/passkeys#creating-a-passkey">here
28370
+ * »</a> for more info on the full flow.
28371
+ *
28372
+ * Generated from the
28373
+ * <a href="https://developer.mozilla.org/en-US/docs/Web/API/AuthenticatorAttestationResponse">AuthenticatorAttestationResponse</a>
28374
+ * object.
28375
+ */
27412
28376
  interface RawInputPasskeyResponseRegister {
27413
28377
  _: 'inputPasskeyResponseRegister';
28378
+ /**
28379
+ * Base64url-decoded <code>clientDataJSON</code> field of an
28380
+ * <a href="https://developer.mozilla.org/en-US/docs/Web/API/AuthenticatorAttestationResponse">AuthenticatorAttestationResponse</a>,
28381
+ * wrapped in {@link RawDataJSON}
28382
+ */
27414
28383
  clientData: tl.TypeDataJSON;
28384
+ /**
28385
+ * Base64url-decoded <code>attestationObject</code> field of an
28386
+ * <a href="https://developer.mozilla.org/en-US/docs/Web/API/AuthenticatorAttestationResponse">AuthenticatorAttestationResponse</a>
28387
+ */
27415
28388
  attestationData: Uint8Array;
27416
28389
  }
28390
+ /**
28391
+ * WebAuthn authentication response used when logging in with a
28392
+ * passkey, see
28393
+ * <a href="https://corefork.telegram.org/api/passkeys#logging-in-with-a-passkey">here
28394
+ * »</a> for more info on the full flow.
28395
+ *
28396
+ * Generated from the
28397
+ * <a href="https://developer.mozilla.org/en-US/docs/Web/API/AuthenticatorAssertionResponse">AuthenticatorAssertionResponse</a>
28398
+ * object.
28399
+ */
27417
28400
  interface RawInputPasskeyResponseLogin {
27418
28401
  _: 'inputPasskeyResponseLogin';
28402
+ /**
28403
+ * Base64url-decoded <code>clientDataJSON</code> field of an
28404
+ * <a href="https://developer.mozilla.org/en-US/docs/Web/API/AuthenticatorAssertionResponse">AuthenticatorAssertionResponse</a>,
28405
+ * wrapped in {@link RawDataJSON}
28406
+ */
27419
28407
  clientData: tl.TypeDataJSON;
28408
+ /**
28409
+ * Base64url-decoded <code>authenticatorData</code> field of an
28410
+ * <a href="https://developer.mozilla.org/en-US/docs/Web/API/AuthenticatorAssertionResponse">AuthenticatorAssertionResponse</a>
28411
+ */
27420
28412
  authenticatorData: Uint8Array;
28413
+ /**
28414
+ * Base64url-decoded <code>signature</code> field of an
28415
+ * <a href="https://developer.mozilla.org/en-US/docs/Web/API/AuthenticatorAssertionResponse">AuthenticatorAssertionResponse</a>
28416
+ */
27421
28417
  signature: Uint8Array;
28418
+ /**
28419
+ * Base64url-decoded <code>userHandle</code> field of an
28420
+ * <a href="https://developer.mozilla.org/en-US/docs/Web/API/AuthenticatorAssertionResponse">AuthenticatorAssertionResponse</a>.
28421
+ * The user handle specified by the server is in
28422
+ * <code><dc_id>:<user_id></code> format.
28423
+ */
27422
28424
  userHandle: string;
27423
28425
  }
28426
+ /**
28427
+ * Public-key passkey credential used both for registration and
28428
+ * for login, see
28429
+ * <a href="https://corefork.telegram.org/api/passkeys#creating-a-passkey">creating
28430
+ * a passkey »</a> and
28431
+ * <a href="https://corefork.telegram.org/api/passkeys#logging-in-with-a-passkey">logging
28432
+ * in with a passkey »</a> for the full flows.
28433
+ */
27424
28434
  interface RawInputPasskeyCredentialPublicKey {
27425
28435
  _: 'inputPasskeyCredentialPublicKey';
28436
+ /**
28437
+ * <code>id</code> field of a
28438
+ * <a href="https://developer.mozilla.org/en-US/docs/Web/API/PublicKeyCredential">PublicKeyCredential</a>,
28439
+ * passed as-is without base64url-decoding when using the JSON
28440
+ * representation
28441
+ */
27426
28442
  id: string;
28443
+ /**
28444
+ * <code>rawId</code> field of a
28445
+ * <a href="https://developer.mozilla.org/en-US/docs/Web/API/PublicKeyCredential">PublicKeyCredential</a>,
28446
+ * passed as-is without base64url-decoding when using the JSON
28447
+ * representation
28448
+ */
27427
28449
  rawId: string;
28450
+ /**
28451
+ * Registration or login response.
28452
+ */
27428
28453
  response: tl.TypeInputPasskeyResponse;
27429
28454
  }
27430
28455
  interface RawInputPasskeyCredentialFirebasePNV {
@@ -27437,16 +28462,54 @@ export class RpcError extends Error {
27437
28462
  edgeColor: number;
27438
28463
  textColor: number;
27439
28464
  }
28465
+ /**
28466
+ * Describes one or more
28467
+ * <a href="https://corefork.telegram.org/api/auctions">collectible
28468
+ * gift auction rounds »</a>.
28469
+ */
27440
28470
  interface RawStarGiftAuctionRound {
27441
28471
  _: 'starGiftAuctionRound';
28472
+ /**
28473
+ * This object describes all rounds starting from
28474
+ * <code>num</code> up until <code>next.num-1</code>
28475
+ * inclusively (<code>next</code> is the next
28476
+ * <a href="https://corefork.telegram.org/type/StarGiftAuctionRound">StarGiftAuctionRound</a>).
28477
+ */
27442
28478
  num: number;
28479
+ /**
28480
+ * Duration in seconds of the round(s).
28481
+ */
27443
28482
  duration: number;
27444
28483
  }
28484
+ /**
28485
+ * Describes one or more extendable
28486
+ * <a href="https://corefork.telegram.org/api/auctions">collectible
28487
+ * gift auction rounds »</a>.
28488
+ */
27445
28489
  interface RawStarGiftAuctionRoundExtendable {
27446
28490
  _: 'starGiftAuctionRoundExtendable';
28491
+ /**
28492
+ * This object describes all rounds starting from
28493
+ * <code>num</code> up until <code>next.num-1</code>
28494
+ * inclusively (<code>next</code> is the next
28495
+ * <a href="https://corefork.telegram.org/type/StarGiftAuctionRound">StarGiftAuctionRound</a>).
28496
+ */
27447
28497
  num: number;
28498
+ /**
28499
+ * Duration in seconds of the round(s).
28500
+ */
27448
28501
  duration: number;
28502
+ /**
28503
+ * The round(s) will be extended by <code>extend_window</code>
28504
+ * if a bid changes the composition/order of the top
28505
+ * <code>extend_top</code> bidders.
28506
+ */
27449
28507
  extendTop: number;
28508
+ /**
28509
+ * The round(s) will be extended by this many seconds if a bid
28510
+ * changes the composition/order of the top
28511
+ * <code>extend_top</code> bidders.
28512
+ */
27450
28513
  extendWindow: number;
27451
28514
  }
27452
28515
  interface RawStarGiftAttributeRarity {
@@ -27465,61 +28528,33 @@ export class RpcError extends Error {
27465
28528
  interface RawStarGiftAttributeRarityLegendary {
27466
28529
  _: 'starGiftAttributeRarityLegendary';
27467
28530
  }
28531
+ /**
28532
+ * This constructor allows setting a custom background color
28533
+ * and custom emoji label for a button, see
28534
+ * <a href="https://corefork.telegram.org/api/bots/buttons#button-styles">here
28535
+ * »</a> for more info.
28536
+ */
27468
28537
  interface RawKeyboardButtonStyle {
27469
28538
  _: 'keyboardButtonStyle';
28539
+ /**
28540
+ * A dark blue color, recommended for main actions.
28541
+ */
27470
28542
  bgPrimary?: boolean;
28543
+ /**
28544
+ * A red color, recommended for destructive actions.
28545
+ */
27471
28546
  bgDanger?: boolean;
28547
+ /**
28548
+ * A green color, recommended for positive actions.
28549
+ */
27472
28550
  bgSuccess?: boolean;
28551
+ /**
28552
+ * The ID of a
28553
+ * <a href="https://corefork.telegram.org/api/custom-emoji">custom
28554
+ * emoji</a> to be displayed before the button's label.
28555
+ */
27473
28556
  icon?: Long;
27474
28557
  }
27475
- interface RawMessageActionPollAppendAnswer {
27476
- _: 'messageActionPollAppendAnswer';
27477
- answer: tl.TypePollAnswer;
27478
- }
27479
- interface RawMessageActionPollDeleteAnswer {
27480
- _: 'messageActionPollDeleteAnswer';
27481
- answer: tl.TypePollAnswer;
27482
- }
27483
- interface RawMessageActionManagedBotCreated {
27484
- _: 'messageActionManagedBotCreated';
27485
- botId: number;
27486
- }
27487
- interface RawInputMessagesFilterPoll {
27488
- _: 'inputMessagesFilterPoll';
27489
- }
27490
- interface RawUpdateManagedBot {
27491
- _: 'updateManagedBot';
27492
- userId: number;
27493
- botId: number;
27494
- qts: number;
27495
- }
27496
- interface RawMessageEntityDiffInsert {
27497
- _: 'messageEntityDiffInsert';
27498
- offset: number;
27499
- length: number;
27500
- }
27501
- interface RawMessageEntityDiffReplace {
27502
- _: 'messageEntityDiffReplace';
27503
- offset: number;
27504
- length: number;
27505
- oldText: string;
27506
- }
27507
- interface RawMessageEntityDiffDelete {
27508
- _: 'messageEntityDiffDelete';
27509
- offset: number;
27510
- length: number;
27511
- }
27512
- interface RawInputPollAnswer {
27513
- _: 'inputPollAnswer';
27514
- text: tl.TypeTextWithEntities;
27515
- media?: tl.TypeInputMedia;
27516
- }
27517
- interface RawRequestPeerTypeCreateBot {
27518
- _: 'requestPeerTypeCreateBot';
27519
- botManaged?: boolean;
27520
- suggestedName?: string;
27521
- suggestedUsername?: string;
27522
- }
27523
28558
  interface RawInputMessageReadMetric {
27524
28559
  _: 'inputMessageReadMetric';
27525
28560
  msgId: number;
@@ -27529,6 +28564,43 @@ export class RpcError extends Error {
27529
28564
  heightToViewportRatioPermille: number;
27530
28565
  seenRangeRatioPermille: number;
27531
28566
  }
28567
+ interface RawInputAiComposeToneDefault {
28568
+ _: 'inputAiComposeToneDefault';
28569
+ tone: string;
28570
+ }
28571
+ interface RawInputAiComposeToneID {
28572
+ _: 'inputAiComposeToneID';
28573
+ id: Long;
28574
+ accessHash: Long;
28575
+ }
28576
+ interface RawInputAiComposeToneSlug {
28577
+ _: 'inputAiComposeToneSlug';
28578
+ slug: string;
28579
+ }
28580
+ interface RawAiComposeTone {
28581
+ _: 'aiComposeTone';
28582
+ creator?: boolean;
28583
+ id: Long;
28584
+ accessHash: Long;
28585
+ slug: string;
28586
+ title: string;
28587
+ emojiId?: Long;
28588
+ prompt?: string;
28589
+ installsCount?: number;
28590
+ authorId?: number;
28591
+ exampleEnglish?: tl.TypeAiComposeToneExample;
28592
+ }
28593
+ interface RawAiComposeToneDefault {
28594
+ _: 'aiComposeToneDefault';
28595
+ tone: string;
28596
+ emojiId: Long;
28597
+ title: string;
28598
+ }
28599
+ interface RawAiComposeToneExample {
28600
+ _: 'aiComposeToneExample';
28601
+ from: tl.TypeTextWithEntities;
28602
+ to: tl.TypeTextWithEntities;
28603
+ }
27532
28604
  /**
27533
28605
  * A
27534
28606
  * <a href="https://corefork.telegram.org/api/forum#forum-topics">forum
@@ -27789,7 +28861,7 @@ export class RpcError extends Error {
27789
28861
  */
27790
28862
  query: X;
27791
28863
  }
27792
- interface RpcCallReturn extends storage.RpcCallReturn, auth.RpcCallReturn, contacts.RpcCallReturn, messages.RpcCallReturn, updates.RpcCallReturn, photos.RpcCallReturn, upload.RpcCallReturn, help.RpcCallReturn, account.RpcCallReturn, channels.RpcCallReturn, payments.RpcCallReturn, phone.RpcCallReturn, stats.RpcCallReturn, stickers.RpcCallReturn, users.RpcCallReturn, chatlists.RpcCallReturn, bots.RpcCallReturn, stories.RpcCallReturn, premium.RpcCallReturn, smsjobs.RpcCallReturn, fragment.RpcCallReturn, mtcute.RpcCallReturn, langpack.RpcCallReturn, folders.RpcCallReturn {
28864
+ interface RpcCallReturn extends storage.RpcCallReturn, auth.RpcCallReturn, contacts.RpcCallReturn, messages.RpcCallReturn, updates.RpcCallReturn, photos.RpcCallReturn, upload.RpcCallReturn, help.RpcCallReturn, account.RpcCallReturn, channels.RpcCallReturn, payments.RpcCallReturn, phone.RpcCallReturn, stats.RpcCallReturn, stickers.RpcCallReturn, users.RpcCallReturn, chatlists.RpcCallReturn, bots.RpcCallReturn, stories.RpcCallReturn, premium.RpcCallReturn, smsjobs.RpcCallReturn, fragment.RpcCallReturn, aicompose.RpcCallReturn, mtcute.RpcCallReturn, langpack.RpcCallReturn, folders.RpcCallReturn {
27793
28865
  'invokeAfterMsg': any
27794
28866
  'invokeAfterMsgs': any
27795
28867
  'initConnection': any
@@ -27896,7 +28968,10 @@ export class RpcError extends Error {
27896
28968
  type TypeChatParticipant = tl.RawChatParticipant | tl.RawChatParticipantCreator | tl.RawChatParticipantAdmin
27897
28969
  function isAnyChatParticipant(o: object): o is TypeChatParticipant
27898
28970
  /**
27899
- * Object contains info on group members.
28971
+ * Contains the full list of members of
28972
+ * <a href="https://corefork.telegram.org/api/channel#basic-groups">basic
28973
+ * groups »</a>; is <strong>NOT</strong> usable for
28974
+ * supergroups/channels.
27900
28975
  */
27901
28976
  type TypeChatParticipants = tl.RawChatParticipantsForbidden | tl.RawChatParticipants
27902
28977
  function isAnyChatParticipants(o: object): o is TypeChatParticipants
@@ -28001,7 +29076,7 @@ export class RpcError extends Error {
28001
29076
  /**
28002
29077
  * Object contains info on events occurred.
28003
29078
  */
28004
- type TypeUpdate = tl.RawUpdateNewMessage | tl.RawUpdateMessageID | tl.RawUpdateDeleteMessages | tl.RawUpdateUserTyping | tl.RawUpdateChatUserTyping | tl.RawUpdateChatParticipants | tl.RawUpdateUserStatus | tl.RawUpdateUserName | tl.RawUpdateNewAuthorization | tl.RawUpdateNewEncryptedMessage | tl.RawUpdateEncryptedChatTyping | tl.RawUpdateEncryption | tl.RawUpdateEncryptedMessagesRead | tl.RawUpdateChatParticipantAdd | tl.RawUpdateChatParticipantDelete | tl.RawUpdateDcOptions | tl.RawUpdateNotifySettings | tl.RawUpdateServiceNotification | tl.RawUpdatePrivacy | tl.RawUpdateUserPhone | tl.RawUpdateReadHistoryInbox | tl.RawUpdateReadHistoryOutbox | tl.RawUpdateWebPage | tl.RawUpdateReadMessagesContents | tl.RawUpdateChannelTooLong | tl.RawUpdateChannel | tl.RawUpdateNewChannelMessage | tl.RawUpdateReadChannelInbox | tl.RawUpdateDeleteChannelMessages | tl.RawUpdateChannelMessageViews | tl.RawUpdateChatParticipantAdmin | tl.RawUpdateNewStickerSet | tl.RawUpdateStickerSetsOrder | tl.RawUpdateStickerSets | tl.RawUpdateSavedGifs | tl.RawUpdateBotInlineQuery | tl.RawUpdateBotInlineSend | tl.RawUpdateEditChannelMessage | tl.RawUpdateBotCallbackQuery | tl.RawUpdateEditMessage | tl.RawUpdateInlineBotCallbackQuery | tl.RawUpdateReadChannelOutbox | tl.RawUpdateDraftMessage | tl.RawUpdateReadFeaturedStickers | tl.RawUpdateRecentStickers | tl.RawUpdateConfig | tl.RawUpdatePtsChanged | tl.RawUpdateChannelWebPage | tl.RawUpdateDialogPinned | tl.RawUpdatePinnedDialogs | tl.RawUpdateBotWebhookJSON | tl.RawUpdateBotWebhookJSONQuery | tl.RawUpdateBotShippingQuery | tl.RawUpdateBotPrecheckoutQuery | tl.RawUpdatePhoneCall | tl.RawUpdateLangPackTooLong | tl.RawUpdateLangPack | tl.RawUpdateFavedStickers | tl.RawUpdateChannelReadMessagesContents | tl.RawUpdateContactsReset | tl.RawUpdateChannelAvailableMessages | tl.RawUpdateDialogUnreadMark | tl.RawUpdateMessagePoll | tl.RawUpdateChatDefaultBannedRights | tl.RawUpdateFolderPeers | tl.RawUpdatePeerSettings | tl.RawUpdatePeerLocated | tl.RawUpdateNewScheduledMessage | tl.RawUpdateDeleteScheduledMessages | tl.RawUpdateTheme | tl.RawUpdateGeoLiveViewed | tl.RawUpdateLoginToken | tl.RawUpdateMessagePollVote | tl.RawUpdateDialogFilter | tl.RawUpdateDialogFilterOrder | tl.RawUpdateDialogFilters | tl.RawUpdatePhoneCallSignalingData | tl.RawUpdateChannelMessageForwards | tl.RawUpdateReadChannelDiscussionInbox | tl.RawUpdateReadChannelDiscussionOutbox | tl.RawUpdatePeerBlocked | tl.RawUpdateChannelUserTyping | tl.RawUpdatePinnedMessages | tl.RawUpdatePinnedChannelMessages | tl.RawUpdateChat | tl.RawUpdateGroupCallParticipants | tl.RawUpdateGroupCall | tl.RawUpdatePeerHistoryTTL | tl.RawUpdateChatParticipant | tl.RawUpdateChannelParticipant | tl.RawUpdateBotStopped | tl.RawUpdateGroupCallConnection | tl.RawUpdateBotCommands | tl.RawUpdatePendingJoinRequests | tl.RawUpdateBotChatInviteRequester | tl.RawUpdateMessageReactions | tl.RawUpdateAttachMenuBots | tl.RawUpdateWebViewResultSent | tl.RawUpdateBotMenuButton | tl.RawUpdateSavedRingtones | tl.RawUpdateTranscribedAudio | tl.RawUpdateReadFeaturedEmojiStickers | tl.RawUpdateUserEmojiStatus | tl.RawUpdateRecentEmojiStatuses | tl.RawUpdateRecentReactions | tl.RawUpdateMoveStickerSetToTop | tl.RawUpdateMessageExtendedMedia | tl.RawUpdateUser | tl.RawUpdateAutoSaveSettings | tl.RawUpdateStory | tl.RawUpdateReadStories | tl.RawUpdateStoryID | tl.RawUpdateStoriesStealthMode | tl.RawUpdateSentStoryReaction | tl.RawUpdateBotChatBoost | tl.RawUpdateChannelViewForumAsMessages | tl.RawUpdatePeerWallpaper | tl.RawUpdateBotMessageReaction | tl.RawUpdateBotMessageReactions | tl.RawUpdateSavedDialogPinned | tl.RawUpdatePinnedSavedDialogs | tl.RawUpdateSavedReactionTags | tl.RawUpdateSmsJob | tl.RawUpdateQuickReplies | tl.RawUpdateNewQuickReply | tl.RawUpdateDeleteQuickReply | tl.RawUpdateQuickReplyMessage | tl.RawUpdateDeleteQuickReplyMessages | tl.RawUpdateBotBusinessConnect | tl.RawUpdateBotNewBusinessMessage | tl.RawUpdateBotEditBusinessMessage | tl.RawUpdateBotDeleteBusinessMessage | tl.RawUpdateNewStoryReaction | tl.RawUpdateStarsBalance | tl.RawUpdateBusinessBotCallbackQuery | tl.RawUpdateStarsRevenueStatus | tl.RawUpdateBotPurchasedPaidMedia | tl.RawUpdatePaidReactionPrivacy | tl.RawUpdateSentPhoneCode | tl.RawUpdateGroupCallChainBlocks | tl.RawUpdateReadMonoForumInbox | tl.RawUpdateReadMonoForumOutbox | tl.RawUpdateMonoForumNoPaidException | tl.RawUpdateGroupCallMessage | tl.RawUpdateGroupCallEncryptedMessage | tl.RawUpdatePinnedForumTopic | tl.RawUpdatePinnedForumTopics | tl.RawUpdateDeleteGroupCallMessages | tl.RawUpdateStarGiftAuctionState | tl.RawUpdateStarGiftAuctionUserState | tl.RawUpdateEmojiGameInfo | tl.RawUpdateStarGiftCraftFail | tl.RawUpdateChatParticipantRank | tl.RawUpdateManagedBot | tl.RawUpdateChannelPinnedTopic | tl.RawUpdateChannelPinnedTopics | tl.mtcute.RawDummyUpdate
29079
+ type TypeUpdate = tl.RawUpdateNewMessage | tl.RawUpdateMessageID | tl.RawUpdateDeleteMessages | tl.RawUpdateUserTyping | tl.RawUpdateChatUserTyping | tl.RawUpdateChatParticipants | tl.RawUpdateUserStatus | tl.RawUpdateUserName | tl.RawUpdateNewAuthorization | tl.RawUpdateNewEncryptedMessage | tl.RawUpdateEncryptedChatTyping | tl.RawUpdateEncryption | tl.RawUpdateEncryptedMessagesRead | tl.RawUpdateChatParticipantAdd | tl.RawUpdateChatParticipantDelete | tl.RawUpdateDcOptions | tl.RawUpdateNotifySettings | tl.RawUpdateServiceNotification | tl.RawUpdatePrivacy | tl.RawUpdateUserPhone | tl.RawUpdateReadHistoryInbox | tl.RawUpdateReadHistoryOutbox | tl.RawUpdateWebPage | tl.RawUpdateReadMessagesContents | tl.RawUpdateChannelTooLong | tl.RawUpdateChannel | tl.RawUpdateNewChannelMessage | tl.RawUpdateReadChannelInbox | tl.RawUpdateDeleteChannelMessages | tl.RawUpdateChannelMessageViews | tl.RawUpdateChatParticipantAdmin | tl.RawUpdateNewStickerSet | tl.RawUpdateStickerSetsOrder | tl.RawUpdateStickerSets | tl.RawUpdateSavedGifs | tl.RawUpdateBotInlineQuery | tl.RawUpdateBotInlineSend | tl.RawUpdateEditChannelMessage | tl.RawUpdateBotCallbackQuery | tl.RawUpdateEditMessage | tl.RawUpdateInlineBotCallbackQuery | tl.RawUpdateReadChannelOutbox | tl.RawUpdateDraftMessage | tl.RawUpdateReadFeaturedStickers | tl.RawUpdateRecentStickers | tl.RawUpdateConfig | tl.RawUpdatePtsChanged | tl.RawUpdateChannelWebPage | tl.RawUpdateDialogPinned | tl.RawUpdatePinnedDialogs | tl.RawUpdateBotWebhookJSON | tl.RawUpdateBotWebhookJSONQuery | tl.RawUpdateBotShippingQuery | tl.RawUpdateBotPrecheckoutQuery | tl.RawUpdatePhoneCall | tl.RawUpdateLangPackTooLong | tl.RawUpdateLangPack | tl.RawUpdateFavedStickers | tl.RawUpdateChannelReadMessagesContents | tl.RawUpdateContactsReset | tl.RawUpdateChannelAvailableMessages | tl.RawUpdateDialogUnreadMark | tl.RawUpdateMessagePoll | tl.RawUpdateChatDefaultBannedRights | tl.RawUpdateFolderPeers | tl.RawUpdatePeerSettings | tl.RawUpdatePeerLocated | tl.RawUpdateNewScheduledMessage | tl.RawUpdateDeleteScheduledMessages | tl.RawUpdateTheme | tl.RawUpdateGeoLiveViewed | tl.RawUpdateLoginToken | tl.RawUpdateMessagePollVote | tl.RawUpdateDialogFilter | tl.RawUpdateDialogFilterOrder | tl.RawUpdateDialogFilters | tl.RawUpdatePhoneCallSignalingData | tl.RawUpdateChannelMessageForwards | tl.RawUpdateReadChannelDiscussionInbox | tl.RawUpdateReadChannelDiscussionOutbox | tl.RawUpdatePeerBlocked | tl.RawUpdateChannelUserTyping | tl.RawUpdatePinnedMessages | tl.RawUpdatePinnedChannelMessages | tl.RawUpdateChat | tl.RawUpdateGroupCallParticipants | tl.RawUpdateGroupCall | tl.RawUpdatePeerHistoryTTL | tl.RawUpdateChatParticipant | tl.RawUpdateChannelParticipant | tl.RawUpdateBotStopped | tl.RawUpdateGroupCallConnection | tl.RawUpdateBotCommands | tl.RawUpdatePendingJoinRequests | tl.RawUpdateBotChatInviteRequester | tl.RawUpdateMessageReactions | tl.RawUpdateAttachMenuBots | tl.RawUpdateWebViewResultSent | tl.RawUpdateBotMenuButton | tl.RawUpdateSavedRingtones | tl.RawUpdateTranscribedAudio | tl.RawUpdateReadFeaturedEmojiStickers | tl.RawUpdateUserEmojiStatus | tl.RawUpdateRecentEmojiStatuses | tl.RawUpdateRecentReactions | tl.RawUpdateMoveStickerSetToTop | tl.RawUpdateMessageExtendedMedia | tl.RawUpdateUser | tl.RawUpdateAutoSaveSettings | tl.RawUpdateStory | tl.RawUpdateReadStories | tl.RawUpdateStoryID | tl.RawUpdateStoriesStealthMode | tl.RawUpdateSentStoryReaction | tl.RawUpdateBotChatBoost | tl.RawUpdateChannelViewForumAsMessages | tl.RawUpdatePeerWallpaper | tl.RawUpdateBotMessageReaction | tl.RawUpdateBotMessageReactions | tl.RawUpdateSavedDialogPinned | tl.RawUpdatePinnedSavedDialogs | tl.RawUpdateSavedReactionTags | tl.RawUpdateSmsJob | tl.RawUpdateQuickReplies | tl.RawUpdateNewQuickReply | tl.RawUpdateDeleteQuickReply | tl.RawUpdateQuickReplyMessage | tl.RawUpdateDeleteQuickReplyMessages | tl.RawUpdateBotBusinessConnect | tl.RawUpdateBotNewBusinessMessage | tl.RawUpdateBotEditBusinessMessage | tl.RawUpdateBotDeleteBusinessMessage | tl.RawUpdateNewStoryReaction | tl.RawUpdateStarsBalance | tl.RawUpdateBusinessBotCallbackQuery | tl.RawUpdateStarsRevenueStatus | tl.RawUpdateBotPurchasedPaidMedia | tl.RawUpdatePaidReactionPrivacy | tl.RawUpdateSentPhoneCode | tl.RawUpdateGroupCallChainBlocks | tl.RawUpdateReadMonoForumInbox | tl.RawUpdateReadMonoForumOutbox | tl.RawUpdateMonoForumNoPaidException | tl.RawUpdateGroupCallMessage | tl.RawUpdateGroupCallEncryptedMessage | tl.RawUpdatePinnedForumTopic | tl.RawUpdatePinnedForumTopics | tl.RawUpdateDeleteGroupCallMessages | tl.RawUpdateStarGiftAuctionState | tl.RawUpdateStarGiftAuctionUserState | tl.RawUpdateEmojiGameInfo | tl.RawUpdateStarGiftCraftFail | tl.RawUpdateChatParticipantRank | tl.RawUpdateManagedBot | tl.RawUpdateBotGuestChatQuery | tl.RawUpdateAiComposeTones | tl.RawUpdateChannelPinnedTopic | tl.RawUpdateChannelPinnedTopics | tl.mtcute.RawDummyUpdate
28005
29080
  function isAnyUpdate(o: object): o is TypeUpdate
28006
29081
  /**
28007
29082
  * Object which is perceived by the client without a call on
@@ -28288,7 +29363,7 @@ export class RpcError extends Error {
28288
29363
  /**
28289
29364
  * Top peer category
28290
29365
  */
28291
- type TypeTopPeerCategory = tl.RawTopPeerCategoryBotsPM | tl.RawTopPeerCategoryBotsInline | tl.RawTopPeerCategoryCorrespondents | tl.RawTopPeerCategoryGroups | tl.RawTopPeerCategoryChannels | tl.RawTopPeerCategoryPhoneCalls | tl.RawTopPeerCategoryForwardUsers | tl.RawTopPeerCategoryForwardChats | tl.RawTopPeerCategoryBotsApp
29366
+ type TypeTopPeerCategory = tl.RawTopPeerCategoryBotsPM | tl.RawTopPeerCategoryBotsInline | tl.RawTopPeerCategoryCorrespondents | tl.RawTopPeerCategoryGroups | tl.RawTopPeerCategoryChannels | tl.RawTopPeerCategoryPhoneCalls | tl.RawTopPeerCategoryForwardUsers | tl.RawTopPeerCategoryForwardChats | tl.RawTopPeerCategoryBotsApp | tl.RawTopPeerCategoryBotsGuestChat
28292
29367
  function isAnyTopPeerCategory(o: object): o is TypeTopPeerCategory
28293
29368
  /**
28294
29369
  * Top peers by top peer category
@@ -28840,7 +29915,7 @@ export class RpcError extends Error {
28840
29915
  /**
28841
29916
  * Webpage attributes
28842
29917
  */
28843
- type TypeWebPageAttribute = tl.RawWebPageAttributeTheme | tl.RawWebPageAttributeStory | tl.RawWebPageAttributeStickerSet | tl.RawWebPageAttributeUniqueStarGift | tl.RawWebPageAttributeStarGiftCollection | tl.RawWebPageAttributeStarGiftAuction
29918
+ type TypeWebPageAttribute = tl.RawWebPageAttributeTheme | tl.RawWebPageAttributeStory | tl.RawWebPageAttributeStickerSet | tl.RawWebPageAttributeUniqueStarGift | tl.RawWebPageAttributeStarGiftCollection | tl.RawWebPageAttributeStarGiftAuction | tl.RawWebPageAttributeAiComposeTone
28844
29919
  function isAnyWebPageAttribute(o: object): o is TypeWebPageAttribute
28845
29920
  /**
28846
29921
  * Credit card info URL provided by the bank
@@ -29927,6 +31002,11 @@ export class RpcError extends Error {
29927
31002
  */
29928
31003
  type TypeInputChatTheme = tl.RawInputChatThemeEmpty | tl.RawInputChatTheme | tl.RawInputChatThemeUniqueGift
29929
31004
  function isAnyInputChatTheme(o: object): o is TypeInputChatTheme
31005
+ /**
31006
+ * Indicates the price for a
31007
+ * <a href="https://corefork.telegram.org/api/gifts#collectible-gifts">gift
31008
+ * upgrade »</a> starting from a specific point in time.
31009
+ */
29930
31010
  type TypeStarGiftUpgradePrice = tl.RawStarGiftUpgradePrice
29931
31011
  function isAnyStarGiftUpgradePrice(o: object): o is TypeStarGiftUpgradePrice
29932
31012
  type TypeGroupCallMessage = tl.RawGroupCallMessage
@@ -29935,18 +31015,48 @@ export class RpcError extends Error {
29935
31015
  function isAnyGroupCallDonor(o: object): o is TypeGroupCallDonor
29936
31016
  type TypeRecentStory = tl.RawRecentStory
29937
31017
  function isAnyRecentStory(o: object): o is TypeRecentStory
31018
+ /**
31019
+ * Describes a bid in an
31020
+ * <a href="https://corefork.telegram.org/api/auctions">auction</a>.
31021
+ */
29938
31022
  type TypeAuctionBidLevel = tl.RawAuctionBidLevel
29939
31023
  function isAnyAuctionBidLevel(o: object): o is TypeAuctionBidLevel
29940
31024
  type TypeStarGiftAuctionState = tl.RawStarGiftAuctionStateNotModified | tl.RawStarGiftAuctionState | tl.RawStarGiftAuctionStateFinished
29941
31025
  function isAnyStarGiftAuctionState(o: object): o is TypeStarGiftAuctionState
31026
+ /**
31027
+ * Contains information about the current user's state in an
31028
+ * <a href="https://corefork.telegram.org/api/auctions">auction
31029
+ * »</a>.
31030
+ *
31031
+ * The <code>bid_amount</code>, <code>bid_date</code>,
31032
+ * <code>bid_peer</code> and <code>min_bid_amount</code> flags
31033
+ * of {@link RawStarGiftAuctionUserState} will all be set if
31034
+ * the user placed a bid in the auction.
31035
+ */
29942
31036
  type TypeStarGiftAuctionUserState = tl.RawStarGiftAuctionUserState
29943
31037
  function isAnyStarGiftAuctionUserState(o: object): o is TypeStarGiftAuctionUserState
31038
+ /**
31039
+ * Describes a gift that the current user won in an auction.
31040
+ */
29944
31041
  type TypeStarGiftAuctionAcquiredGift = tl.RawStarGiftAuctionAcquiredGift
29945
31042
  function isAnyStarGiftAuctionAcquiredGift(o: object): o is TypeStarGiftAuctionAcquiredGift
31043
+ /**
31044
+ * Contains info about
31045
+ * <a href="https://corefork.telegram.org/api/auctions">an
31046
+ * auction where the user has placed a bid »</a>.
31047
+ */
29946
31048
  type TypeStarGiftActiveAuctionState = tl.RawStarGiftActiveAuctionState
29947
31049
  function isAnyStarGiftActiveAuctionState(o: object): o is TypeStarGiftActiveAuctionState
29948
31050
  type TypeInputStarGiftAuction = tl.RawInputStarGiftAuction | tl.RawInputStarGiftAuctionSlug
29949
31051
  function isAnyInputStarGiftAuction(o: object): o is TypeInputStarGiftAuction
31052
+ /**
31053
+ * Human-readable info about a passkey associated to an
31054
+ * account, returned when
31055
+ * <a href="https://corefork.telegram.org/api/passkeys#creating-a-passkey">creating
31056
+ * a passkey »</a> or
31057
+ * <a href="https://corefork.telegram.org/api/passkeys#list-passkeys">listing
31058
+ * passkeys »</a>.
31059
+ */
29950
31060
  type TypePasskey = tl.RawPasskey
29951
31061
  function isAnyPasskey(o: object): o is TypePasskey
29952
31062
  type TypeInputPasskeyResponse = tl.RawInputPasskeyResponseRegister | tl.RawInputPasskeyResponseLogin
@@ -29959,10 +31069,22 @@ export class RpcError extends Error {
29959
31069
  function isAnyStarGiftAuctionRound(o: object): o is TypeStarGiftAuctionRound
29960
31070
  type TypeStarGiftAttributeRarity = tl.RawStarGiftAttributeRarity | tl.RawStarGiftAttributeRarityUncommon | tl.RawStarGiftAttributeRarityRare | tl.RawStarGiftAttributeRarityEpic | tl.RawStarGiftAttributeRarityLegendary
29961
31071
  function isAnyStarGiftAttributeRarity(o: object): o is TypeStarGiftAttributeRarity
31072
+ /**
31073
+ * This constructor allows setting a custom background color
31074
+ * and custom emoji label for a button, see
31075
+ * <a href="https://corefork.telegram.org/api/bots/buttons#button-styles">here
31076
+ * »</a> for more info.
31077
+ */
29962
31078
  type TypeKeyboardButtonStyle = tl.RawKeyboardButtonStyle
29963
31079
  function isAnyKeyboardButtonStyle(o: object): o is TypeKeyboardButtonStyle
29964
31080
  type TypeInputMessageReadMetric = tl.RawInputMessageReadMetric
29965
31081
  function isAnyInputMessageReadMetric(o: object): o is TypeInputMessageReadMetric
31082
+ type TypeInputAiComposeTone = tl.RawInputAiComposeToneDefault | tl.RawInputAiComposeToneID | tl.RawInputAiComposeToneSlug
31083
+ function isAnyInputAiComposeTone(o: object): o is TypeInputAiComposeTone
31084
+ type TypeAiComposeTone = tl.RawAiComposeTone | tl.RawAiComposeToneDefault
31085
+ function isAnyAiComposeTone(o: object): o is TypeAiComposeTone
31086
+ type TypeAiComposeToneExample = tl.RawAiComposeToneExample
31087
+ function isAnyAiComposeToneExample(o: object): o is TypeAiComposeToneExample
29966
31088
 
29967
31089
  namespace storage {
29968
31090
  /**
@@ -30078,12 +31200,15 @@ export class RpcError extends Error {
30078
31200
  * user's country/provider, the user must purchase a
30079
31201
  * <a href="https://corefork.telegram.org/api/premium">Telegram
30080
31202
  * Premium</a> subscription in order to proceed with the
30081
- * login/signup.
31203
+ * login/signup, see
31204
+ * <a href="https://corefork.telegram.org/api/auth#paid-auth">here
31205
+ * »</a> for more info.
30082
31206
  */
30083
31207
  interface RawSentCodePaymentRequired {
30084
31208
  _: 'auth.sentCodePaymentRequired';
30085
31209
  /**
30086
- * Store identifier of the Telegram Premium subscription.
31210
+ * For official apps, tore identifier of the Telegram Premium
31211
+ * subscription.
30087
31212
  */
30088
31213
  storeProduct: string;
30089
31214
  /**
@@ -30100,7 +31225,22 @@ export class RpcError extends Error {
30100
31225
  * The mandatory subject for the email.
30101
31226
  */
30102
31227
  supportEmailSubject: string;
31228
+ premiumDays: number;
31229
+ /**
31230
+ * Three-letter ISO 4217
31231
+ * <a href="https://corefork.telegram.org/bots/payments#supported-currencies">currency</a>
31232
+ * code.
31233
+ */
30103
31234
  currency: string;
31235
+ /**
31236
+ * Total price in the smallest units of the currency (integer,
31237
+ * not float/double). For example, for a price of <code>US$
31238
+ * 1.45</code> pass <code>amount = 145</code>. See the exp
31239
+ * parameter in
31240
+ * <a href="https://corefork.telegram.org/bots/payments/currencies.json">currencies.json</a>,
31241
+ * it shows the number of digits past the decimal point for
31242
+ * each currency (2 for the majority of currencies).
31243
+ */
30104
31244
  amount: Long;
30105
31245
  }
30106
31246
  /**
@@ -30468,8 +31608,19 @@ export class RpcError extends Error {
30468
31608
  */
30469
31609
  futureAuthToken?: Uint8Array;
30470
31610
  }
31611
+ /**
31612
+ * Passkey login options, see
31613
+ * <a href="https://corefork.telegram.org/api/passkeys#logging-in-with-a-passkey">here
31614
+ * »</a> for more info on the full flow.
31615
+ */
30471
31616
  interface RawPasskeyLoginOptions {
30472
31617
  _: 'auth.passkeyLoginOptions';
31618
+ /**
31619
+ * JSON-encoded object whose <code>publicKey</code> field
31620
+ * contains a
31621
+ * <a href="https://developer.mozilla.org/en-US/docs/Web/API/PublicKeyCredentialRequestOptions"><code>PublicKeyCredentialRequestOptions</code></a>
31622
+ * object.
31623
+ */
30473
31624
  options: tl.TypeDataJSON;
30474
31625
  }
30475
31626
  /**
@@ -30967,29 +32118,85 @@ export class RpcError extends Error {
30967
32118
  mnc: string;
30968
32119
  }
30969
32120
  /**
32121
+ * Checks the status of a
32122
+ * <a href="https://corefork.telegram.org/api/auth#paid-auth">login
32123
+ * payment</a>.
32124
+ *
30970
32125
  * RPC method returns {@link tl.auth.TypeSentCode}
30971
32126
  */
30972
32127
  interface RawCheckPaidAuthRequest {
30973
32128
  _: 'auth.checkPaidAuth';
32129
+ /**
32130
+ * Phone number
32131
+ */
30974
32132
  phoneNumber: string;
32133
+ /**
32134
+ * The phone code hash obtained from
32135
+ * {@link auth.RawSendCodeRequest}
32136
+ */
30975
32137
  phoneCodeHash: string;
32138
+ /**
32139
+ * The payment form ID passed to
32140
+ * {@link payments.RawSendPaymentFormRequest}.
32141
+ */
30976
32142
  formId: Long;
30977
32143
  }
30978
32144
  /**
32145
+ * Initialize login with a passkey over an unauthenticated
32146
+ * connection, see
32147
+ * <a href="https://corefork.telegram.org/api/passkeys#logging-in-with-a-passkey">here
32148
+ * »</a> for more info.
32149
+ *
30979
32150
  * RPC method returns {@link tl.auth.TypePasskeyLoginOptions}
30980
32151
  */
30981
32152
  interface RawInitPasskeyLoginRequest {
30982
32153
  _: 'auth.initPasskeyLogin';
32154
+ /**
32155
+ * Application identifier (see
32156
+ * <a href="https://corefork.telegram.org/myapp">App
32157
+ * configuration</a>)
32158
+ */
30983
32159
  apiId: number;
32160
+ /**
32161
+ * Application identifier hash (see
32162
+ * <a href="https://corefork.telegram.org/myapp">App
32163
+ * configuration</a>)
32164
+ */
30984
32165
  apiHash: string;
30985
32166
  }
30986
32167
  /**
32168
+ * Complete login with a passkey over an unauthenticated
32169
+ * connection, see
32170
+ * <a href="https://corefork.telegram.org/api/passkeys#logging-in-with-a-passkey">here
32171
+ * »</a> for more info.
32172
+ *
32173
+ * Must be sent to the user's native DC, as specified by the
32174
+ * <code>user_handle</code> (<code>dcId:userId</code>) returned
32175
+ * in the passkey assertion, see
32176
+ * <a href="https://corefork.telegram.org/api/passkeys#logging-in-with-a-passkey">here
32177
+ * »</a> for the full flow.
32178
+ *
30987
32179
  * RPC method returns {@link tl.auth.TypeAuthorization}
30988
32180
  */
30989
32181
  interface RawFinishPasskeyLoginRequest {
30990
32182
  _: 'auth.finishPasskeyLogin';
32183
+ /**
32184
+ * Passkey assertion result.
32185
+ */
30991
32186
  credential: tl.TypeInputPasskeyCredential;
32187
+ /**
32188
+ * DC ID used for the initial
32189
+ * {@link auth.RawInitPasskeyLoginRequest} request; set only if
32190
+ * the user's DC is different from the DC used for the initial
32191
+ * {@link auth.RawInitPasskeyLoginRequest}.
32192
+ */
30992
32193
  fromDcId?: number;
32194
+ /**
32195
+ * Auth key ID for the connection to <code>from_dc_id</code>
32196
+ * (use the permanent auth key ID if PFS is enabled); set only
32197
+ * if the user's DC is different from the DC used for the
32198
+ * initial {@link auth.RawInitPasskeyLoginRequest}.
32199
+ */
30993
32200
  fromAuthKeyId?: Long;
30994
32201
  }
30995
32202
  interface RpcCallReturn {
@@ -31067,6 +32274,11 @@ export class RpcError extends Error {
31067
32274
  */
31068
32275
  type TypeLoggedOut = tl.auth.RawLoggedOut
31069
32276
  function isAnyLoggedOut(o: object): o is TypeLoggedOut
32277
+ /**
32278
+ * Passkey login options, see
32279
+ * <a href="https://corefork.telegram.org/api/passkeys#logging-in-with-a-passkey">here
32280
+ * »</a> for more info on the full flow.
32281
+ */
31070
32282
  type TypePasskeyLoginOptions = tl.auth.RawPasskeyLoginOptions
31071
32283
  function isAnyPasskeyLoginOptions(o: object): o is TypePasskeyLoginOptions
31072
32284
  }
@@ -31506,6 +32718,7 @@ export class RpcError extends Error {
31506
32718
  * Mini Bot Apps</a>.
31507
32719
  */
31508
32720
  botsApp?: boolean;
32721
+ botsGuestchat?: boolean;
31509
32722
  /**
31510
32723
  * Offset for
31511
32724
  * <a href="https://corefork.telegram.org/api/offsets">pagination</a>
@@ -31604,6 +32817,11 @@ export class RpcError extends Error {
31604
32817
  * to the contact list, without a phone number.
31605
32818
  */
31606
32819
  phone: string;
32820
+ /**
32821
+ * A private note for this contact, only visible to us; see
32822
+ * <a href="https://corefork.telegram.org/api/contacts#private-notes-for-contacts">here
32823
+ * »</a> for more info on contact notes.
32824
+ */
31607
32825
  note?: tl.TypeTextWithEntities;
31608
32826
  }
31609
32827
  /**
@@ -31683,6 +32901,9 @@ export class RpcError extends Error {
31683
32901
  * Resolve a phone number to get user info, if their privacy
31684
32902
  * settings allow it.
31685
32903
  *
32904
+ * Make sure to implement client-side ratelimiting/debounce for
32905
+ * this method, allowing at most 1 call every 3 seconds.
32906
+ *
31686
32907
  * RPC method returns {@link tl.contacts.TypeResolvedPeer}
31687
32908
  */
31688
32909
  interface RawResolvePhoneRequest {
@@ -31794,11 +33015,21 @@ export class RpcError extends Error {
31794
33015
  q: string;
31795
33016
  }
31796
33017
  /**
33018
+ * Update the private note associated to a contact; see
33019
+ * <a href="https://corefork.telegram.org/api/contacts#private-notes-for-contacts">here
33020
+ * »</a> for more info.
33021
+ *
31797
33022
  * RPC method returns boolean
31798
33023
  */
31799
33024
  interface RawUpdateContactNoteRequest {
31800
33025
  _: 'contacts.updateContactNote';
33026
+ /**
33027
+ * The contact.
33028
+ */
31801
33029
  id: tl.TypeInputUser;
33030
+ /**
33031
+ * The note.
33032
+ */
31802
33033
  note: tl.TypeTextWithEntities;
31803
33034
  }
31804
33035
  interface RpcCallReturn {
@@ -33561,9 +34792,24 @@ export class RpcError extends Error {
33561
34792
  params: number[];
33562
34793
  playsLeft?: number;
33563
34794
  }
34795
+ /**
34796
+ * Represents a message modified by AI.
34797
+ */
33564
34798
  interface RawComposedMessageWithAI {
33565
34799
  _: 'messages.composedMessageWithAI';
34800
+ /**
34801
+ * The modified message.
34802
+ */
33566
34803
  resultText: tl.TypeTextWithEntities;
34804
+ /**
34805
+ * If <strong>only</strong> the proofreading mode
34806
+ * ({@link messages.RawComposeMessageWithAIRequest}.<code>proofread</code>)
34807
+ * is enabled, this field will be populated with a
34808
+ * "pre-rendered" diff between the old and the new message text
34809
+ * using <strong>only</strong>
34810
+ * <a href="https://corefork.telegram.org/api/entities#diff-entities">diff
34811
+ * entities »</a>.
34812
+ */
33567
34813
  diffText?: tl.TypeTextWithEntities;
33568
34814
  }
33569
34815
  /**
@@ -33885,7 +35131,7 @@ export class RpcError extends Error {
33885
35131
  /**
33886
35132
  * Only for bots, disallows forwarding and saving of the
33887
35133
  * messages, even if the destination chat doesn't have
33888
- * <a href="https://telegram.org/blog/protected-content-delete-by-date-and-more">content
35134
+ * <a href="https://telegram.org/blog/content-protection-delete-by-date-and-more">content
33889
35135
  * protection</a> enabled
33890
35136
  */
33891
35137
  noforwards?: boolean;
@@ -33944,6 +35190,12 @@ export class RpcError extends Error {
33944
35190
  * messages</a>
33945
35191
  */
33946
35192
  scheduleDate?: number;
35193
+ /**
35194
+ * Once sent, this message will be automatically re-scheduled
35195
+ * to be re-sent again this many seconds in the future, see
35196
+ * <a href="https://corefork.telegram.org/api/scheduled-messages#repeating-scheduled-messages">here
35197
+ * »</a> for more info on repeating scheduled messages.
35198
+ */
33947
35199
  scheduleRepeatPeriod?: number;
33948
35200
  /**
33949
35201
  * Send this message as the specified peer
@@ -34000,7 +35252,7 @@ export class RpcError extends Error {
34000
35252
  /**
34001
35253
  * Only for bots, disallows forwarding and saving of the
34002
35254
  * messages, even if the destination chat doesn't have
34003
- * <a href="https://telegram.org/blog/protected-content-delete-by-date-and-more">content
35255
+ * <a href="https://telegram.org/blog/content-protection-delete-by-date-and-more">content
34004
35256
  * protection</a> enabled
34005
35257
  */
34006
35258
  noforwards?: boolean;
@@ -34060,6 +35312,12 @@ export class RpcError extends Error {
34060
35312
  * messages</a>
34061
35313
  */
34062
35314
  scheduleDate?: number;
35315
+ /**
35316
+ * Once sent, this message will be automatically re-scheduled
35317
+ * to be re-sent again this many seconds in the future, see
35318
+ * <a href="https://corefork.telegram.org/api/scheduled-messages#repeating-scheduled-messages">here
35319
+ * »</a> for more info on repeating scheduled messages.
35320
+ */
34063
35321
  scheduleRepeatPeriod?: number;
34064
35322
  /**
34065
35323
  * Send this message as the specified peer
@@ -34127,7 +35385,7 @@ export class RpcError extends Error {
34127
35385
  /**
34128
35386
  * Only for bots, disallows further re-forwarding and saving of
34129
35387
  * the messages, even if the destination chat doesn't have
34130
- * <a href="https://telegram.org/blog/protected-content-delete-by-date-and-more">content
35388
+ * <a href="https://telegram.org/blog/content-protection-delete-by-date-and-more">content
34131
35389
  * protection</a> enabled
34132
35390
  */
34133
35391
  noforwards?: boolean;
@@ -34172,6 +35430,12 @@ export class RpcError extends Error {
34172
35430
  * Scheduled message date for scheduled messages
34173
35431
  */
34174
35432
  scheduleDate?: number;
35433
+ /**
35434
+ * Once sent, this message will be automatically re-scheduled
35435
+ * to be re-sent again this many seconds in the future, see
35436
+ * <a href="https://corefork.telegram.org/api/scheduled-messages#repeating-scheduled-messages">here
35437
+ * »</a> for more info on repeating scheduled messages.
35438
+ */
34175
35439
  scheduleRepeatPeriod?: number;
34176
35440
  /**
34177
35441
  * Forward the messages as the specified peer
@@ -34183,6 +35447,11 @@ export class RpcError extends Error {
34183
35447
  * reply shortcut »</a>, instead.
34184
35448
  */
34185
35449
  quickReplyShortcut?: tl.TypeInputQuickReplyShortcut;
35450
+ /**
35451
+ * Specifies a
35452
+ * <a href="https://corefork.telegram.org/api/effects">message
35453
+ * effect »</a> to use for the message.
35454
+ */
34186
35455
  effect?: Long;
34187
35456
  /**
34188
35457
  * Start playing the video at the specified timestamp
@@ -35242,6 +36511,12 @@ export class RpcError extends Error {
35242
36511
  * messages</a>
35243
36512
  */
35244
36513
  scheduleDate?: number;
36514
+ /**
36515
+ * Once sent, this message will be automatically re-scheduled
36516
+ * to be re-sent again this many seconds in the future, see
36517
+ * <a href="https://corefork.telegram.org/api/scheduled-messages#repeating-scheduled-messages">here
36518
+ * »</a> for more info on repeating scheduled messages.
36519
+ */
35245
36520
  scheduleRepeatPeriod?: number;
35246
36521
  /**
35247
36522
  * If specified, edits a
@@ -36023,7 +37298,7 @@ export class RpcError extends Error {
36023
37298
  /**
36024
37299
  * Only for bots, disallows forwarding and saving of the
36025
37300
  * messages, even if the destination chat doesn't have
36026
- * <a href="https://telegram.org/blog/protected-content-delete-by-date-and-more">content
37301
+ * <a href="https://telegram.org/blog/content-protection-delete-by-date-and-more">content
36027
37302
  * protection</a> enabled
36028
37303
  */
36029
37304
  noforwards?: boolean;
@@ -37352,8 +38627,8 @@ export class RpcError extends Error {
37352
38627
  }
37353
38628
  /**
37354
38629
  * Enable or disable
37355
- * <a href="https://telegram.org/blog/protected-content-delete-by-date-and-more">content
37356
- * protection</a> on a channel or chat
38630
+ * <a href="https://corefork.telegram.org/api/content-protection">content
38631
+ * protection</a> on a channel, group or private chat.
37357
38632
  *
37358
38633
  * RPC method returns {@link tl.TypeUpdates}
37359
38634
  */
@@ -37367,6 +38642,12 @@ export class RpcError extends Error {
37367
38642
  * Enable or disable content protection
37368
38643
  */
37369
38644
  enabled: boolean;
38645
+ /**
38646
+ * Used only inside private chats to accept or refuse a request
38647
+ * to disable content protection, see
38648
+ * <a href="https://corefork.telegram.org/api/content-protection#for-users">here
38649
+ * »</a> for more info on the full flow.
38650
+ */
37370
38651
  requestMsgId?: number;
37371
38652
  }
37372
38653
  /**
@@ -39139,15 +40420,11 @@ export class RpcError extends Error {
39139
40420
  count: number;
39140
40421
  /**
39141
40422
  * Unique client message ID required to prevent message
39142
- * resending.
39143
- *
39144
- * <strong>Note</strong>: this argument <strong>must</strong>
39145
- * be composed of a 64-bit integer where the lower 32 bits are
39146
- * random, and the higher 32 bits <strong>are equal to the
39147
- * current unixtime</strong>, i.e. <code>uint64_t random_id =
39148
- * (time() << 32) | ((uint64_t)random_uint32_t())</code>: this
39149
- * differs from the <code>random_id</code> format of all other
39150
- * methods in the API, which just take 64 random bits.
40423
+ * resending. <strong>Note</strong>: this argument
40424
+ * <strong>must</strong> be composed of a 64-bit integer where
40425
+ * the lower 32 bits are random, and the higher 32 bits
40426
+ * <strong>are equal to the current unixtime</strong>, i.e.
40427
+ * `uint64_t random_id = (time() << 32)
39151
40428
  */
39152
40429
  randomId: Long;
39153
40430
  /**
@@ -39538,87 +40815,230 @@ export class RpcError extends Error {
39538
40815
  rejectComment?: string;
39539
40816
  }
39540
40817
  /**
40818
+ * Get <a href="https://corefork.telegram.org/api/forum">topics
40819
+ * of a forum</a>
40820
+ *
39541
40821
  * RPC method returns {@link tl.messages.TypeForumTopics}
39542
40822
  */
39543
40823
  interface RawGetForumTopicsRequest {
39544
40824
  _: 'messages.getForumTopics';
40825
+ /**
40826
+ * The supergroup forum, private chat (for forum-enabled bots)
40827
+ * or bot forum (for users) where the topic is located.
40828
+ */
39545
40829
  peer: tl.TypeInputPeer;
40830
+ /**
40831
+ * Search query
40832
+ */
39546
40833
  q?: string;
39547
40834
  /**
39548
40835
  * <a href="https://corefork.telegram.org/api/offsets">Offsets
39549
- * for pagination, for more info click here</a>
40836
+ * for pagination, for more info click here</a>, date of the
40837
+ * last message of the last found topic. Use 0 or any date in
40838
+ * the future to get results from the last topic.
39550
40839
  */
39551
40840
  offsetDate: number;
39552
40841
  /**
39553
40842
  * <a href="https://corefork.telegram.org/api/offsets">Offsets
39554
- * for pagination, for more info click here</a>
40843
+ * for pagination, for more info click here</a>, ID of the last
40844
+ * message of the last found topic (or initially
40845
+ * <code>0</code>).
39555
40846
  */
39556
40847
  offsetId: number;
40848
+ /**
40849
+ * <a href="https://corefork.telegram.org/api/offsets">Offsets
40850
+ * for pagination, for more info click here</a>, ID of the last
40851
+ * found topic (or initially <code>0</code>).
40852
+ */
39557
40853
  offsetTopic: number;
39558
40854
  /**
39559
40855
  * Maximum number of results to return,
39560
40856
  * <a href="https://corefork.telegram.org/api/offsets">see
39561
- * pagination</a>
40857
+ * pagination</a>. For optimal performance, the number of
40858
+ * returned topics is chosen by the server and can be smaller
40859
+ * than the specified limit.
39562
40860
  */
39563
40861
  limit: number;
39564
40862
  }
39565
40863
  /**
40864
+ * Get forum topics by their ID
40865
+ *
39566
40866
  * RPC method returns {@link tl.messages.TypeForumTopics}
39567
40867
  */
39568
40868
  interface RawGetForumTopicsByIDRequest {
39569
40869
  _: 'messages.getForumTopicsByID';
40870
+ /**
40871
+ * The supergroup forum, private chat (for forum-enabled bots)
40872
+ * or bot forum (for users) where the topic is located.
40873
+ */
39570
40874
  peer: tl.TypeInputPeer;
40875
+ /**
40876
+ * Topic IDs
40877
+ */
39571
40878
  topics: number[];
39572
40879
  }
39573
40880
  /**
40881
+ * Edit <a href="https://corefork.telegram.org/api/forum">forum
40882
+ * topic</a>.
40883
+ *
39574
40884
  * RPC method returns {@link tl.TypeUpdates}
39575
40885
  */
39576
40886
  interface RawEditForumTopicRequest {
39577
40887
  _: 'messages.editForumTopic';
40888
+ /**
40889
+ * The supergroup forum, private chat (for forum-enabled bots)
40890
+ * or bot forum (for users) where the topic is located.
40891
+ */
39578
40892
  peer: tl.TypeInputPeer;
40893
+ /**
40894
+ * Topic ID
40895
+ */
39579
40896
  topicId: number;
40897
+ /**
40898
+ * If present, will update the topic title (maximum UTF-8
40899
+ * length: 128).
40900
+ */
39580
40901
  title?: string;
40902
+ /**
40903
+ * If present, updates the
40904
+ * <a href="https://corefork.telegram.org/api/custom-emoji">custom
40905
+ * emoji</a> used as topic icon.
40906
+ * <a href="https://corefork.telegram.org/api/premium">Telegram
40907
+ * Premium</a> users can use any custom emoji, other users can
40908
+ * only use the custom emojis contained in the
40909
+ * {@link RawInputStickerSetEmojiDefaultTopicIcons} emoji pack.
40910
+ * Pass 0 to switch to the fallback topic icon.
40911
+ */
39581
40912
  iconEmojiId?: Long;
40913
+ /**
40914
+ * If present, will update the open/closed status of the topic.
40915
+ */
39582
40916
  closed?: boolean;
40917
+ /**
40918
+ * If present, will hide/unhide the topic (only valid for the
40919
+ * "General" topic, <code>id=1</code>).
40920
+ */
39583
40921
  hidden?: boolean;
39584
40922
  }
39585
40923
  /**
40924
+ * Pin or unpin
40925
+ * <a href="https://corefork.telegram.org/api/forum">forum
40926
+ * topics</a>
40927
+ *
39586
40928
  * RPC method returns {@link tl.TypeUpdates}
39587
40929
  */
39588
40930
  interface RawUpdatePinnedForumTopicRequest {
39589
40931
  _: 'messages.updatePinnedForumTopic';
40932
+ /**
40933
+ * The supergroup forum, private chat (for forum-enabled bots)
40934
+ * or bot forum (for users) where the topic is located.
40935
+ */
39590
40936
  peer: tl.TypeInputPeer;
40937
+ /**
40938
+ * <a href="https://corefork.telegram.org/api/forum">Forum
40939
+ * topic ID</a>
40940
+ */
39591
40941
  topicId: number;
40942
+ /**
40943
+ * Whether to pin or unpin the topic
40944
+ */
39592
40945
  pinned: boolean;
39593
40946
  }
39594
40947
  /**
40948
+ * Reorder pinned forum topics
40949
+ *
39595
40950
  * RPC method returns {@link tl.TypeUpdates}
39596
40951
  */
39597
40952
  interface RawReorderPinnedForumTopicsRequest {
39598
40953
  _: 'messages.reorderPinnedForumTopics';
40954
+ /**
40955
+ * If not set, the order of only the topics present both
40956
+ * server-side and in <code>order</code> will be changed (i.e.
40957
+ * mentioning topics not pinned server-side in
40958
+ * <code>order</code> will not pin them, and not mentioning
40959
+ * topics pinned server-side will not unpin them).
40960
+ *
40961
+ * If set, the entire server-side pinned topic list will be
40962
+ * replaced with <code>order</code> (i.e. mentioning topics not
40963
+ * pinned server-side in <code>order</code> will pin them, and
40964
+ * not mentioning topics pinned server-side will unpin them)
40965
+ */
39599
40966
  force?: boolean;
40967
+ /**
40968
+ * The supergroup forum, private chat (for forum-enabled bots)
40969
+ * or bot forum (for users) where the topic is located.
40970
+ */
39600
40971
  peer: tl.TypeInputPeer;
40972
+ /**
40973
+ * <a href="https://corefork.telegram.org/api/forum">Topic IDs
40974
+ * »</a>
40975
+ */
39601
40976
  order: number[];
39602
40977
  }
39603
40978
  /**
40979
+ * Create a
40980
+ * <a href="https://corefork.telegram.org/api/forum">forum
40981
+ * topic</a>.
40982
+ *
39604
40983
  * RPC method returns {@link tl.TypeUpdates}
39605
40984
  */
39606
40985
  interface RawCreateForumTopicRequest {
39607
40986
  _: 'messages.createForumTopic';
39608
40987
  titleMissing?: boolean;
40988
+ /**
40989
+ * The supergroup, private chat (for forum-enabled bots) or
40990
+ * forum bot (for users) where to create the topic.
40991
+ */
39609
40992
  peer: tl.TypeInputPeer;
40993
+ /**
40994
+ * Topic title (maximum UTF-8 length: 128)
40995
+ */
39610
40996
  title: string;
40997
+ /**
40998
+ * If no custom emoji icon is specified, specifies the color of
40999
+ * the fallback topic icon (RGB), one of <code>0x6FB9F0</code>,
41000
+ * <code>0xFFD67E</code>, <code>0xCB86DB</code>,
41001
+ * <code>0x8EEE98</code>, <code>0xFF93B2</code>, or
41002
+ * <code>0xFB6F5F</code>.
41003
+ */
39611
41004
  iconColor?: number;
41005
+ /**
41006
+ * ID of the
41007
+ * <a href="https://corefork.telegram.org/api/custom-emoji">custom
41008
+ * emoji</a> used as topic icon.
41009
+ * <a href="https://corefork.telegram.org/api/premium">Telegram
41010
+ * Premium</a> users can use any custom emoji, other users can
41011
+ * only use the custom emojis contained in the
41012
+ * {@link RawInputStickerSetEmojiDefaultTopicIcons} emoji pack.
41013
+ */
39612
41014
  iconEmojiId?: Long;
41015
+ /**
41016
+ * Unique client message ID to prevent duplicate sending of the
41017
+ * same event
41018
+ */
39613
41019
  randomId: Long;
41020
+ /**
41021
+ * Create the topic as the specified peer
41022
+ */
39614
41023
  sendAs?: tl.TypeInputPeer;
39615
41024
  }
39616
41025
  /**
41026
+ * Delete message history of a
41027
+ * <a href="https://corefork.telegram.org/api/forum">forum
41028
+ * topic</a>
41029
+ *
39617
41030
  * RPC method returns {@link tl.messages.TypeAffectedHistory}
39618
41031
  */
39619
41032
  interface RawDeleteTopicHistoryRequest {
39620
41033
  _: 'messages.deleteTopicHistory';
41034
+ /**
41035
+ * The supergroup forum, private chat (for forum-enabled bots)
41036
+ * or bot forum (for users) where the topic is located.
41037
+ */
39621
41038
  peer: tl.TypeInputPeer;
41039
+ /**
41040
+ * Topic ID
41041
+ */
39622
41042
  topMsgId: number;
39623
41043
  }
39624
41044
  /**
@@ -39628,11 +41048,21 @@ export class RpcError extends Error {
39628
41048
  _: 'messages.getEmojiGameInfo';
39629
41049
  }
39630
41050
  /**
41051
+ * Summarize the contents of a message with AI, see
41052
+ * <a href="https://corefork.telegram.org/api/ai#summarize-messages">here
41053
+ * »</a> for more info.
41054
+ *
39631
41055
  * RPC method returns {@link tl.TypeTextWithEntities}
39632
41056
  */
39633
41057
  interface RawSummarizeTextRequest {
39634
41058
  _: 'messages.summarizeText';
41059
+ /**
41060
+ * The peer where the message is located.
41061
+ */
39635
41062
  peer: tl.TypeInputPeer;
41063
+ /**
41064
+ * Message ID.
41065
+ */
39636
41066
  id: number;
39637
41067
  toLang?: string;
39638
41068
  tone?: string;
@@ -39654,12 +41084,24 @@ export class RpcError extends Error {
39654
41084
  peer: tl.TypeInputPeer;
39655
41085
  }
39656
41086
  /**
41087
+ * Edit a group participant's
41088
+ * <a href="https://corefork.telegram.org/api/rank">tag »</a>.
41089
+ *
39657
41090
  * RPC method returns {@link tl.TypeUpdates}
39658
41091
  */
39659
41092
  interface RawEditChatParticipantRankRequest {
39660
41093
  _: 'messages.editChatParticipantRank';
41094
+ /**
41095
+ * The basic group/supergroup.
41096
+ */
39661
41097
  peer: tl.TypeInputPeer;
41098
+ /**
41099
+ * The participant.
41100
+ */
39662
41101
  participant: tl.TypeInputPeer;
41102
+ /**
41103
+ * The new tag.
41104
+ */
39663
41105
  rank: string;
39664
41106
  }
39665
41107
  /**
@@ -39678,16 +41120,37 @@ export class RpcError extends Error {
39678
41120
  matchCode: string;
39679
41121
  }
39680
41122
  /**
41123
+ * Invokes telegram's AI Editor that can translate, transform,
41124
+ * fixup and/or emojify your message in a number of different
41125
+ * ways, privately powered by
41126
+ * <a href="https://cocoon.org/">Cocoon</a>, see
41127
+ * <a href="https://corefork.telegram.org/api/ai#compose-messages">here
41128
+ * »</a> for more info!
41129
+ *
41130
+ * All of the modes specified below can be combined.
41131
+ *
39681
41132
  * RPC method returns
39682
41133
  * {@link tl.messages.TypeComposedMessageWithAI}
39683
41134
  */
39684
41135
  interface RawComposeMessageWithAIRequest {
39685
41136
  _: 'messages.composeMessageWithAI';
41137
+ /**
41138
+ * If set, proofreads and fixes mistakes in the message
41139
+ */
39686
41140
  proofread?: boolean;
41141
+ /**
41142
+ * If set, adds emojis to the message
41143
+ */
39687
41144
  emojify?: boolean;
41145
+ /**
41146
+ * The message
41147
+ */
39688
41148
  text: tl.TypeTextWithEntities;
41149
+ /**
41150
+ * If set, translates the message to the specified language
41151
+ */
39689
41152
  translateToLang?: string;
39690
- changeTone?: string;
41153
+ tone?: tl.TypeInputAiComposeTone;
39691
41154
  }
39692
41155
  /**
39693
41156
  * RPC method returns boolean
@@ -39730,8 +41193,21 @@ export class RpcError extends Error {
39730
41193
  _: 'messages.getUnreadPollVotes';
39731
41194
  peer: tl.TypeInputPeer;
39732
41195
  topMsgId?: number;
41196
+ /**
41197
+ * <a href="https://corefork.telegram.org/api/offsets">Offsets
41198
+ * for pagination, for more info click here</a>
41199
+ */
39733
41200
  offsetId: number;
41201
+ /**
41202
+ * <a href="https://corefork.telegram.org/api/offsets">Offsets
41203
+ * for pagination, for more info click here</a>
41204
+ */
39734
41205
  addOffset: number;
41206
+ /**
41207
+ * Maximum number of results to return,
41208
+ * <a href="https://corefork.telegram.org/api/offsets">see
41209
+ * pagination</a>
41210
+ */
39735
41211
  limit: number;
39736
41212
  maxId: number;
39737
41213
  minId: number;
@@ -39744,6 +41220,42 @@ export class RpcError extends Error {
39744
41220
  peer: tl.TypeInputPeer;
39745
41221
  topMsgId?: number;
39746
41222
  }
41223
+ /**
41224
+ * RPC method returns {@link tl.TypeInputBotInlineMessageID}
41225
+ */
41226
+ interface RawSetBotGuestChatResultRequest {
41227
+ _: 'messages.setBotGuestChatResult';
41228
+ queryId: Long;
41229
+ result: tl.TypeInputBotInlineResult;
41230
+ }
41231
+ /**
41232
+ * RPC method returns boolean
41233
+ */
41234
+ interface RawDeleteParticipantReactionsRequest {
41235
+ _: 'messages.deleteParticipantReactions';
41236
+ peer: tl.TypeInputPeer;
41237
+ participant: tl.TypeInputPeer;
41238
+ }
41239
+ /**
41240
+ * RPC method returns {@link tl.TypeUpdates}
41241
+ */
41242
+ interface RawDeleteParticipantReactionRequest {
41243
+ _: 'messages.deleteParticipantReaction';
41244
+ peer: tl.TypeInputPeer;
41245
+ msgId: number;
41246
+ participant: tl.TypeInputPeer;
41247
+ }
41248
+ /**
41249
+ * RPC method returns {@link tl.messages.TypeMessages}
41250
+ */
41251
+ interface RawGetPersonalChannelHistoryRequest {
41252
+ _: 'messages.getPersonalChannelHistory';
41253
+ userId: tl.TypeInputUser;
41254
+ limit: number;
41255
+ maxId: number;
41256
+ minId: number;
41257
+ hash: Long;
41258
+ }
39747
41259
  interface RpcCallReturn {
39748
41260
  'messages.getMessages': tl.messages.TypeMessages
39749
41261
  'messages.getDialogs': tl.messages.TypeDialogs
@@ -39996,6 +41508,10 @@ export class RpcError extends Error {
39996
41508
  'messages.deletePollAnswer': tl.TypeUpdates
39997
41509
  'messages.getUnreadPollVotes': tl.messages.TypeMessages
39998
41510
  'messages.readPollVotes': tl.messages.TypeAffectedHistory
41511
+ 'messages.setBotGuestChatResult': tl.TypeInputBotInlineMessageID
41512
+ 'messages.deleteParticipantReactions': boolean
41513
+ 'messages.deleteParticipantReaction': tl.TypeUpdates
41514
+ 'messages.getPersonalChannelHistory': tl.messages.TypeMessages
39999
41515
  }
40000
41516
  /**
40001
41517
  * Object contains a list of chats with messages and auxiliary
@@ -40350,6 +41866,9 @@ export class RpcError extends Error {
40350
41866
  function isAnyEmojiGameOutcome(o: object): o is TypeEmojiGameOutcome
40351
41867
  type TypeEmojiGameInfo = tl.messages.RawEmojiGameUnavailable | tl.messages.RawEmojiGameDiceInfo
40352
41868
  function isAnyEmojiGameInfo(o: object): o is TypeEmojiGameInfo
41869
+ /**
41870
+ * Represents a message modified by AI.
41871
+ */
40353
41872
  type TypeComposedMessageWithAI = tl.messages.RawComposedMessageWithAI
40354
41873
  function isAnyComposedMessageWithAI(o: object): o is TypeComposedMessageWithAI
40355
41874
  }
@@ -41742,9 +43261,9 @@ export class RpcError extends Error {
41742
43261
  * inclusive, in which case a palette containing a single color
41743
43262
  * from the following colors should be used: red, orange,
41744
43263
  * violet, green, cyan, blue, pink for indexes 0 to 6 (i.e. the
41745
- * same colors used for randomized fallback
41746
- * <a href="https://corefork.telegram.org/api/colors">message
41747
- * accent colors</a>).
43264
+ * same colors used for the
43265
+ * <a href="https://corefork.telegram.org/api/colors#randomized-fallback-color-palette">randomized
43266
+ * fallback color palette</a>).
41748
43267
  */
41749
43268
  colors?: tl.help.TypePeerColorSet;
41750
43269
  /**
@@ -42913,12 +44432,32 @@ export class RpcError extends Error {
42913
44432
  */
42914
44433
  ids: Long[];
42915
44434
  }
44435
+ /**
44436
+ * List of
44437
+ * <a href="https://corefork.telegram.org/api/passkeys#list-passkeys">passkeys
44438
+ * »</a> associated to the current account.
44439
+ */
42916
44440
  interface RawPasskeys {
42917
44441
  _: 'account.passkeys';
44442
+ /**
44443
+ * List of passkeys that can be used to log into the current
44444
+ * account
44445
+ */
42918
44446
  passkeys: tl.TypePasskey[];
42919
44447
  }
44448
+ /**
44449
+ * Passkey registration options, see
44450
+ * <a href="https://corefork.telegram.org/api/passkeys#creating-a-passkey">here
44451
+ * »</a> for more info on the full flow.
44452
+ */
42920
44453
  interface RawPasskeyRegistrationOptions {
42921
44454
  _: 'account.passkeyRegistrationOptions';
44455
+ /**
44456
+ * JSON-encoded object whose <code>publicKey</code> field
44457
+ * contains a
44458
+ * <a href="https://developer.mozilla.org/en-US/docs/Web/API/PublicKeyCredentialCreationOptions"><code>PublicKeyCredentialCreationOptions</code></a>
44459
+ * object.
44460
+ */
42922
44461
  options: tl.TypeDataJSON;
42923
44462
  }
42924
44463
  /**
@@ -45029,13 +46568,20 @@ export class RpcError extends Error {
45029
46568
  _: 'account.getUniqueGiftChatThemes';
45030
46569
  /**
45031
46570
  * Offset for
45032
- * <a href="https://corefork.telegram.org/api/offsets">pagination</a>.
46571
+ * <a href="https://corefork.telegram.org/api/offsets">pagination</a>,
46572
+ * intially an empty string, then equal the value of the last
46573
+ * returned
46574
+ * {@link account.RawChatThemes}.<code>next_offset</code> (if
46575
+ * set).
45033
46576
  */
45034
46577
  offset: string;
45035
46578
  /**
45036
46579
  * Maximum number of results to return,
45037
46580
  * <a href="https://corefork.telegram.org/api/offsets">see
45038
- * pagination</a>
46581
+ * pagination</a>. Note that the server may return less than
46582
+ * <code>limit</code> results, even if the actual number of
46583
+ * remaining results is <code>>= limit</code>, paginate to
46584
+ * fetch them all.
45039
46585
  */
45040
46586
  limit: number;
45041
46587
  /**
@@ -45046,6 +46592,10 @@ export class RpcError extends Error {
45046
46592
  hash: Long;
45047
46593
  }
45048
46594
  /**
46595
+ * Initialize passkey registration for the current account, see
46596
+ * <a href="https://corefork.telegram.org/api/passkeys#creating-a-passkey">here
46597
+ * »</a> for more info on the full flow.
46598
+ *
45049
46599
  * RPC method returns
45050
46600
  * {@link tl.account.TypePasskeyRegistrationOptions}
45051
46601
  */
@@ -45053,23 +46603,44 @@ export class RpcError extends Error {
45053
46603
  _: 'account.initPasskeyRegistration';
45054
46604
  }
45055
46605
  /**
46606
+ * Complete passkey registration for the current account, see
46607
+ * <a href="https://corefork.telegram.org/api/passkeys#creating-a-passkey">here
46608
+ * »</a> for more info on the full flow.
46609
+ *
45056
46610
  * RPC method returns {@link tl.TypePasskey}
45057
46611
  */
45058
46612
  interface RawRegisterPasskeyRequest {
45059
46613
  _: 'account.registerPasskey';
46614
+ /**
46615
+ * Registration result.
46616
+ */
45060
46617
  credential: tl.TypeInputPasskeyCredential;
45061
46618
  }
45062
46619
  /**
46620
+ * List the passkeys associated to the current account that can
46621
+ * be used to log in, see
46622
+ * <a href="https://corefork.telegram.org/api/passkeys#list-passkeys">here
46623
+ * »</a> for more info on passkeys.
46624
+ *
45063
46625
  * RPC method returns {@link tl.account.TypePasskeys}
45064
46626
  */
45065
46627
  interface RawGetPasskeysRequest {
45066
46628
  _: 'account.getPasskeys';
45067
46629
  }
45068
46630
  /**
46631
+ * Delete a passkey associated to the current account, see
46632
+ * <a href="https://corefork.telegram.org/api/passkeys#delete-passkeys">here
46633
+ * »</a> for more info.
46634
+ *
45069
46635
  * RPC method returns boolean
45070
46636
  */
45071
46637
  interface RawDeletePasskeyRequest {
45072
46638
  _: 'account.deletePasskey';
46639
+ /**
46640
+ * Identifier of the passkey to delete, taken from
46641
+ * {@link RawPasskey}.<code>id</code>, usually obtained using
46642
+ * {@link account.RawGetPasskeysRequest}.
46643
+ */
45073
46644
  id: string;
45074
46645
  }
45075
46646
  interface RpcCallReturn {
@@ -45349,8 +46920,18 @@ export class RpcError extends Error {
45349
46920
  */
45350
46921
  type TypeSavedMusicIds = tl.account.RawSavedMusicIdsNotModified | tl.account.RawSavedMusicIds
45351
46922
  function isAnySavedMusicIds(o: object): o is TypeSavedMusicIds
46923
+ /**
46924
+ * List of
46925
+ * <a href="https://corefork.telegram.org/api/passkeys#list-passkeys">passkeys
46926
+ * »</a> associated to the current account.
46927
+ */
45352
46928
  type TypePasskeys = tl.account.RawPasskeys
45353
46929
  function isAnyPasskeys(o: object): o is TypePasskeys
46930
+ /**
46931
+ * Passkey registration options, see
46932
+ * <a href="https://corefork.telegram.org/api/passkeys#creating-a-passkey">here
46933
+ * »</a> for more info on the full flow.
46934
+ */
45354
46935
  type TypePasskeyRegistrationOptions = tl.account.RawPasskeyRegistrationOptions
45355
46936
  function isAnyPasskeyRegistrationOptions(o: object): o is TypePasskeyRegistrationOptions
45356
46937
  }
@@ -45710,7 +47291,8 @@ export class RpcError extends Error {
45710
47291
  adminRights: tl.TypeChatAdminRights;
45711
47292
  /**
45712
47293
  * Indicates the role (rank) of the admin in the group: just an
45713
- * arbitrary string
47294
+ * arbitrary string. If the flag is not set, the rank is left
47295
+ * unchanged.
45714
47296
  */
45715
47297
  rank?: string;
45716
47298
  }
@@ -46770,9 +48352,7 @@ export class RpcError extends Error {
46770
48352
  /**
46771
48353
  * Create a
46772
48354
  * <a href="https://corefork.telegram.org/api/forum">forum
46773
- * topic</a>; requires
46774
- * <a href="https://corefork.telegram.org/api/rights"><code>manage_topics</code>
46775
- * rights</a>.
48355
+ * topic</a>.
46776
48356
  *
46777
48357
  * RPC method returns {@link tl.TypeUpdates}
46778
48358
  */
@@ -46878,9 +48458,7 @@ export class RpcError extends Error {
46878
48458
  }
46879
48459
  /**
46880
48460
  * Edit <a href="https://corefork.telegram.org/api/forum">forum
46881
- * topic</a>; requires
46882
- * <a href="https://corefork.telegram.org/api/rights"><code>manage_topics</code>
46883
- * rights</a>.
48461
+ * topic</a>.
46884
48462
  *
46885
48463
  * RPC method returns {@link tl.TypeUpdates}
46886
48464
  */
@@ -47780,7 +49358,21 @@ export class RpcError extends Error {
47780
49358
  * Possible gift attributes
47781
49359
  */
47782
49360
  sampleAttributes: tl.TypeStarGiftAttribute[];
49361
+ /**
49362
+ * Contains a similar list of upgrade prices and timestamps,
49363
+ * not as granular as in <code>next_prices</code> (i.e. prices
49364
+ * are approximately 1 month apart), to be used mainly to scale
49365
+ * the price graph, and to show a more general future overview
49366
+ * of the upgrade price.
49367
+ */
47783
49368
  prices: tl.TypeStarGiftUpgradePrice[];
49369
+ /**
49370
+ * Contains the current upgrade price and a list of future
49371
+ * prices, each associated to a UNIX timestamp that indicates
49372
+ * when the price comes in effect (the current price is valid
49373
+ * only until the next one comes into effect, and so on for all
49374
+ * prices in the list).
49375
+ */
47784
49376
  nextPrices: tl.TypeStarGiftUpgradePrice[];
47785
49377
  }
47786
49378
  /**
@@ -48026,28 +49618,91 @@ export class RpcError extends Error {
48026
49618
  */
48027
49619
  reason: tl.TypeTextWithEntities;
48028
49620
  }
49621
+ /**
49622
+ * Describes a
49623
+ * <a href="https://corefork.telegram.org/api/auctions">collectible
49624
+ * gift auction »</a>.
49625
+ */
48029
49626
  interface RawStarGiftAuctionState {
48030
49627
  _: 'payments.starGiftAuctionState';
49628
+ /**
49629
+ * The gift currently being distributed in the auction.
49630
+ */
48031
49631
  gift: tl.TypeStarGift;
49632
+ /**
49633
+ * Auction state.
49634
+ */
48032
49635
  state: tl.TypeStarGiftAuctionState;
49636
+ /**
49637
+ * Auction state related to the current user (i.e. info about
49638
+ * placed bids, won gifts, and so on).
49639
+ */
48033
49640
  userState: tl.TypeStarGiftAuctionUserState;
49641
+ /**
49642
+ * Re-invoke the
49643
+ * {@link payments.RawGetStarGiftAuctionStateRequest} method
49644
+ * after <code>timeout</code> seconds to keep receiving auction
49645
+ * updates, see
49646
+ * <a href="https://corefork.telegram.org/api/auctions">here
49647
+ * »</a> for more info on the full flow.
49648
+ */
48034
49649
  timeout: number;
49650
+ /**
49651
+ * Mentioned users
49652
+ */
48035
49653
  users: tl.TypeUser[];
49654
+ /**
49655
+ * Mentioned chats
49656
+ */
48036
49657
  chats: tl.TypeChat[];
48037
49658
  }
49659
+ /**
49660
+ * Describes all the gifts that the current user won in an
49661
+ * <a href="https://corefork.telegram.org/api/auctions">auction</a>.
49662
+ */
48038
49663
  interface RawStarGiftAuctionAcquiredGifts {
48039
49664
  _: 'payments.starGiftAuctionAcquiredGifts';
49665
+ /**
49666
+ * The gifts
49667
+ */
48040
49668
  gifts: tl.TypeStarGiftAuctionAcquiredGift[];
49669
+ /**
49670
+ * Mentioned users
49671
+ */
48041
49672
  users: tl.TypeUser[];
49673
+ /**
49674
+ * Mentioned chats
49675
+ */
48042
49676
  chats: tl.TypeChat[];
48043
49677
  }
49678
+ /**
49679
+ * The list of currently active
49680
+ * <a href="https://corefork.telegram.org/api/auctions">gift
49681
+ * auctions</a> <strong>where the user has placed a
49682
+ * bid</strong> hasn't changed.
49683
+ */
48044
49684
  interface RawStarGiftActiveAuctionsNotModified {
48045
49685
  _: 'payments.starGiftActiveAuctionsNotModified';
48046
49686
  }
49687
+ /**
49688
+ * Describes all currently active
49689
+ * <a href="https://corefork.telegram.org/api/auctions">gift
49690
+ * auctions</a> <strong>where the user has placed a
49691
+ * bid</strong>.
49692
+ */
48047
49693
  interface RawStarGiftActiveAuctions {
48048
49694
  _: 'payments.starGiftActiveAuctions';
49695
+ /**
49696
+ * Auctions where the user has placed a bid
49697
+ */
48049
49698
  auctions: tl.TypeStarGiftActiveAuctionState[];
49699
+ /**
49700
+ * Mentioned users
49701
+ */
48050
49702
  users: tl.TypeUser[];
49703
+ /**
49704
+ * Mentioned chats
49705
+ */
48051
49706
  chats: tl.TypeChat[];
48052
49707
  }
48053
49708
  interface RawStarGiftUpgradeAttributes {
@@ -48331,7 +49986,7 @@ export class RpcError extends Error {
48331
49986
  * <a href="https://corefork.telegram.org/api/stars">Telegram
48332
49987
  * Stars balance</a> of the current account (with
48333
49988
  * peer={@link RawInputPeerSelf}), or the stars balance of the
48334
- * bot specified in <code>peer</code>.
49989
+ * bot or channel specified in <code>peer</code>.
48335
49990
  *
48336
49991
  * RPC method returns {@link tl.payments.TypeStarsStatus}
48337
49992
  */
@@ -49143,6 +50798,7 @@ export class RpcError extends Error {
49143
50798
  */
49144
50799
  sortByNum?: boolean;
49145
50800
  forCraft?: boolean;
50801
+ starsOnly?: boolean;
49146
50802
  /**
49147
50803
  * If a previous call to the method was made and
49148
50804
  * {@link payments.RawResaleStarGifts}.<code>attributes_hash</code>
@@ -49168,7 +50824,6 @@ export class RpcError extends Error {
49168
50824
  * of that type are allowed.
49169
50825
  */
49170
50826
  attributes?: tl.TypeStarGiftAttributeId[];
49171
- starsOnly?: boolean;
49172
50827
  /**
49173
50828
  * Offset for pagination. If not equal to an empty string,
49174
50829
  * {@link payments.RawResaleStarGifts}.<code>counters</code>
@@ -49353,28 +51008,61 @@ export class RpcError extends Error {
49353
51008
  giftId: Long;
49354
51009
  }
49355
51010
  /**
51011
+ * Returns info about a
51012
+ * <a href="https://corefork.telegram.org/api/auctions">collectible
51013
+ * gift auction »</a>; also subscribes the user to auction
51014
+ * updates, see
51015
+ * <a href="https://corefork.telegram.org/api/auctions">here
51016
+ * »</a> for more info on the full flow.
51017
+ *
49356
51018
  * RPC method returns
49357
51019
  * {@link tl.payments.TypeStarGiftAuctionState}
49358
51020
  */
49359
51021
  interface RawGetStarGiftAuctionStateRequest {
49360
51022
  _: 'payments.getStarGiftAuctionState';
51023
+ /**
51024
+ * Either the ID of the gift linked to the auction, or an
51025
+ * <a href="https://corefork.telegram.org/api/links#auction-links">auction
51026
+ * deep link slug »</a>.
51027
+ */
49361
51028
  auction: tl.TypeInputStarGiftAuction;
51029
+ /**
51030
+ * Initially <code>0</code>, then set to the returned
51031
+ * {@link RawStarGiftAuctionState}.<code>version</code>, to
51032
+ * avoid refetching results if they haven't changed.
51033
+ */
49362
51034
  version: number;
49363
51035
  }
49364
51036
  /**
51037
+ * Fetches all the gifts that the current user won in an
51038
+ * <a href="https://corefork.telegram.org/api/auctions">auction</a>.
51039
+ *
49365
51040
  * RPC method returns
49366
51041
  * {@link tl.payments.TypeStarGiftAuctionAcquiredGifts}
49367
51042
  */
49368
51043
  interface RawGetStarGiftAuctionAcquiredGiftsRequest {
49369
51044
  _: 'payments.getStarGiftAuctionAcquiredGifts';
51045
+ /**
51046
+ * The gift ID linked to the auction.
51047
+ */
49370
51048
  giftId: Long;
49371
51049
  }
49372
51050
  /**
51051
+ * Fetches all currently active
51052
+ * <a href="https://corefork.telegram.org/api/auctions">gift
51053
+ * auctions</a> <strong>where the user has placed a
51054
+ * bid</strong>.
51055
+ *
49373
51056
  * RPC method returns
49374
51057
  * {@link tl.payments.TypeStarGiftActiveAuctions}
49375
51058
  */
49376
51059
  interface RawGetStarGiftActiveAuctionsRequest {
49377
51060
  _: 'payments.getStarGiftActiveAuctions';
51061
+ /**
51062
+ * Hash generated
51063
+ * <a href="https://corefork.telegram.org/api/auctions">as
51064
+ * specified here »</a>
51065
+ */
49378
51066
  hash: Long;
49379
51067
  }
49380
51068
  /**
@@ -49651,8 +51339,17 @@ export class RpcError extends Error {
49651
51339
  */
49652
51340
  type TypeCheckCanSendGiftResult = tl.payments.RawCheckCanSendGiftResultOk | tl.payments.RawCheckCanSendGiftResultFail
49653
51341
  function isAnyCheckCanSendGiftResult(o: object): o is TypeCheckCanSendGiftResult
51342
+ /**
51343
+ * Describes a
51344
+ * <a href="https://corefork.telegram.org/api/auctions">collectible
51345
+ * gift auction »</a>.
51346
+ */
49654
51347
  type TypeStarGiftAuctionState = tl.payments.RawStarGiftAuctionState
49655
51348
  function isAnyStarGiftAuctionState(o: object): o is TypeStarGiftAuctionState
51349
+ /**
51350
+ * Describes all the gifts that the current user won in an
51351
+ * <a href="https://corefork.telegram.org/api/auctions">auction</a>.
51352
+ */
49656
51353
  type TypeStarGiftAuctionAcquiredGifts = tl.payments.RawStarGiftAuctionAcquiredGifts
49657
51354
  function isAnyStarGiftAuctionAcquiredGifts(o: object): o is TypeStarGiftAuctionAcquiredGifts
49658
51355
  type TypeStarGiftActiveAuctions = tl.payments.RawStarGiftActiveAuctionsNotModified | tl.payments.RawStarGiftActiveAuctions
@@ -49798,8 +51495,8 @@ export class RpcError extends Error {
49798
51495
  users: tl.TypeUser[];
49799
51496
  }
49800
51497
  /**
49801
- * Get phone call configuration to be passed to libtgvoip's
49802
- * shared config
51498
+ * DEPRECATED: Get phone call configuration to be passed to the
51499
+ * libtgvoip (deprecated) shared config.
49803
51500
  *
49804
51501
  * RPC method returns {@link tl.TypeDataJSON}
49805
51502
  */
@@ -49807,7 +51504,9 @@ export class RpcError extends Error {
49807
51504
  _: 'phone.getCallConfig';
49808
51505
  }
49809
51506
  /**
49810
- * Start a telegram phone call
51507
+ * Start a telegram phone call, see
51508
+ * <a href="https://corefork.telegram.org/api/calls#one-to-one-calls">here
51509
+ * »</a> for more info on the full flow.
49811
51510
  *
49812
51511
  * RPC method returns {@link tl.phone.TypePhoneCall}
49813
51512
  */
@@ -49836,7 +51535,9 @@ export class RpcError extends Error {
49836
51535
  protocol: tl.TypePhoneCallProtocol;
49837
51536
  }
49838
51537
  /**
49839
- * Accept incoming call
51538
+ * Accept incoming call, see
51539
+ * <a href="https://corefork.telegram.org/api/calls#one-to-one-calls">here
51540
+ * »</a> for more info on the full flow.
49840
51541
  *
49841
51542
  * RPC method returns {@link tl.phone.TypePhoneCall}
49842
51543
  */
@@ -49858,7 +51559,9 @@ export class RpcError extends Error {
49858
51559
  }
49859
51560
  /**
49860
51561
  * <a href="https://corefork.telegram.org/api/end-to-end/voice-calls">Complete
49861
- * phone call E2E encryption key exchange »</a>
51562
+ * phone call E2E encryption key exchange »</a>, see
51563
+ * <a href="https://corefork.telegram.org/api/calls#one-to-one-calls">here
51564
+ * »</a> for more info on the full flow.
49862
51565
  *
49863
51566
  * RPC method returns {@link tl.phone.TypePhoneCall}
49864
51567
  */
@@ -49885,7 +51588,9 @@ export class RpcError extends Error {
49885
51588
  /**
49886
51589
  * Optional: notify the server that the user is currently busy
49887
51590
  * in a call: this will automatically refuse all incoming phone
49888
- * calls until the current phone call is ended.
51591
+ * calls until the current phone call is ended, see
51592
+ * <a href="https://corefork.telegram.org/api/calls#one-to-one-calls">here
51593
+ * »</a> for more info on the full flow.
49889
51594
  *
49890
51595
  * RPC method returns boolean
49891
51596
  */
@@ -49897,7 +51602,9 @@ export class RpcError extends Error {
49897
51602
  peer: tl.TypeInputPhoneCall;
49898
51603
  }
49899
51604
  /**
49900
- * Refuse or end running call
51605
+ * Refuse or end running call, see
51606
+ * <a href="https://corefork.telegram.org/api/calls#one-to-one-calls">here
51607
+ * »</a> for more info on the full flow.
49901
51608
  *
49902
51609
  * RPC method returns {@link tl.TypeUpdates}
49903
51610
  */
@@ -49926,7 +51633,9 @@ export class RpcError extends Error {
49926
51633
  }
49927
51634
  /**
49928
51635
  * Rate a call, returns info about the rating message sent to
49929
- * the official VoIP bot.
51636
+ * the official VoIP bot, see
51637
+ * <a href="https://corefork.telegram.org/api/calls#call-rating">here
51638
+ * »</a> for more info on the full flow.
49930
51639
  *
49931
51640
  * RPC method returns {@link tl.TypeUpdates}
49932
51641
  */
@@ -49934,7 +51643,8 @@ export class RpcError extends Error {
49934
51643
  _: 'phone.setCallRating';
49935
51644
  /**
49936
51645
  * Whether the user decided on their own initiative to rate the
49937
- * call
51646
+ * call, must NOT be set if rating was requested by the server
51647
+ * with {@link RawPhoneCallDiscarded}.<code>need_rating</code>.
49938
51648
  */
49939
51649
  userInitiative?: boolean;
49940
51650
  /**
@@ -49946,7 +51656,9 @@ export class RpcError extends Error {
49946
51656
  */
49947
51657
  rating: number;
49948
51658
  /**
49949
- * An additional comment
51659
+ * An additional comment with problem hashtags, see
51660
+ * <a href="https://corefork.telegram.org/api/calls#call-rating">here
51661
+ * »</a> for more info on the full flow.
49950
51662
  */
49951
51663
  comment: string;
49952
51664
  }
@@ -49962,7 +51674,7 @@ export class RpcError extends Error {
49962
51674
  */
49963
51675
  peer: tl.TypeInputPhoneCall;
49964
51676
  /**
49965
- * Debug statistics obtained from libtgvoip
51677
+ * Debug statistics obtained from tgcalls
49966
51678
  */
49967
51679
  debug: tl.TypeDataJSON;
49968
51680
  }
@@ -50457,7 +52169,7 @@ export class RpcError extends Error {
50457
52169
  revoke: boolean;
50458
52170
  }
50459
52171
  /**
50460
- * Save phone call debug information
52172
+ * Deprecated: send libtgvoip phone call debug information
50461
52173
  *
50462
52174
  * RPC method returns boolean
50463
52175
  */
@@ -50468,7 +52180,7 @@ export class RpcError extends Error {
50468
52180
  */
50469
52181
  peer: tl.TypeInputPhoneCall;
50470
52182
  /**
50471
- * Logs
52183
+ * Libtgvoip logs
50472
52184
  */
50473
52185
  file: tl.TypeInputFile;
50474
52186
  }
@@ -51050,6 +52762,10 @@ export class RpcError extends Error {
51050
52762
  */
51051
52763
  users: tl.TypeUser[];
51052
52764
  }
52765
+ interface RawPollStats {
52766
+ _: 'stats.pollStats';
52767
+ votesGraph: tl.TypeStatsGraph;
52768
+ }
51053
52769
  /**
51054
52770
  * Get
51055
52771
  * <a href="https://corefork.telegram.org/api/stats">channel
@@ -51216,6 +52932,15 @@ export class RpcError extends Error {
51216
52932
  */
51217
52933
  limit: number;
51218
52934
  }
52935
+ /**
52936
+ * RPC method returns {@link tl.stats.TypePollStats}
52937
+ */
52938
+ interface RawGetPollStatsRequest {
52939
+ _: 'stats.getPollStats';
52940
+ dark?: boolean;
52941
+ peer: tl.TypeInputPeer;
52942
+ msgId: number;
52943
+ }
51219
52944
  interface RpcCallReturn {
51220
52945
  'stats.getBroadcastStats': tl.stats.TypeBroadcastStats
51221
52946
  'stats.loadAsyncGraph': tl.TypeStatsGraph
@@ -51224,6 +52949,7 @@ export class RpcError extends Error {
51224
52949
  'stats.getMessageStats': tl.stats.TypeMessageStats
51225
52950
  'stats.getStoryStats': tl.stats.TypeStoryStats
51226
52951
  'stats.getStoryPublicForwards': tl.stats.TypePublicForwards
52952
+ 'stats.getPollStats': tl.stats.TypePollStats
51227
52953
  }
51228
52954
  /**
51229
52955
  * Channel statistics
@@ -51255,6 +52981,8 @@ export class RpcError extends Error {
51255
52981
  */
51256
52982
  type TypePublicForwards = tl.stats.RawPublicForwards
51257
52983
  function isAnyPublicForwards(o: object): o is TypePublicForwards
52984
+ type TypePollStats = tl.stats.RawPollStats
52985
+ function isAnyPollStats(o: object): o is TypePollStats
51258
52986
  }
51259
52987
 
51260
52988
  namespace stickers {
@@ -51723,11 +53451,21 @@ export class RpcError extends Error {
51723
53451
  documents: tl.TypeInputDocument[];
51724
53452
  }
51725
53453
  /**
53454
+ * Suggest a birthday to another user, see
53455
+ * <a href="https://corefork.telegram.org/api/profile#birthday">here
53456
+ * »</a> for more info on birthdays in the API.
53457
+ *
51726
53458
  * RPC method returns {@link tl.TypeUpdates}
51727
53459
  */
51728
53460
  interface RawSuggestBirthdayRequest {
51729
53461
  _: 'users.suggestBirthday';
53462
+ /**
53463
+ * The user that will receive the suggested birthday date.
53464
+ */
51730
53465
  id: tl.TypeInputUser;
53466
+ /**
53467
+ * The birthday to suggest.
53468
+ */
51731
53469
  birthday: tl.TypeBirthday;
51732
53470
  }
51733
53471
  interface RpcCallReturn {
@@ -52212,6 +53950,11 @@ export class RpcError extends Error {
52212
53950
  _: 'bots.requestedButton';
52213
53951
  webappReqId: string;
52214
53952
  }
53953
+ interface RawAccessSettings {
53954
+ _: 'bots.accessSettings';
53955
+ restricted?: boolean;
53956
+ addUsers?: tl.TypeUser[];
53957
+ }
52215
53958
  /**
52216
53959
  * Sends a custom request; for bots only
52217
53960
  *
@@ -52909,6 +54652,22 @@ export class RpcError extends Error {
52909
54652
  bot: tl.TypeInputUser;
52910
54653
  webappReqId: string;
52911
54654
  }
54655
+ /**
54656
+ * RPC method returns {@link tl.bots.TypeAccessSettings}
54657
+ */
54658
+ interface RawGetAccessSettingsRequest {
54659
+ _: 'bots.getAccessSettings';
54660
+ bot: tl.TypeInputUser;
54661
+ }
54662
+ /**
54663
+ * RPC method returns boolean
54664
+ */
54665
+ interface RawEditAccessSettingsRequest {
54666
+ _: 'bots.editAccessSettings';
54667
+ restricted?: boolean;
54668
+ bot: tl.TypeInputUser;
54669
+ addUsers?: tl.TypeInputUser[];
54670
+ }
52912
54671
  interface RpcCallReturn {
52913
54672
  'bots.sendCustomRequest': tl.TypeDataJSON
52914
54673
  'bots.answerWebhookJSONQuery': boolean
@@ -52945,6 +54704,8 @@ export class RpcError extends Error {
52945
54704
  'bots.exportBotToken': tl.bots.TypeExportedBotToken
52946
54705
  'bots.requestWebViewButton': tl.bots.TypeRequestedButton
52947
54706
  'bots.getRequestedWebViewButton': tl.TypeKeyboardButton
54707
+ 'bots.getAccessSettings': tl.bots.TypeAccessSettings
54708
+ 'bots.editAccessSettings': boolean
52948
54709
  }
52949
54710
  /**
52950
54711
  * Localized name, about text and description of a bot.
@@ -52971,6 +54732,8 @@ export class RpcError extends Error {
52971
54732
  function isAnyExportedBotToken(o: object): o is TypeExportedBotToken
52972
54733
  type TypeRequestedButton = tl.bots.RawRequestedButton
52973
54734
  function isAnyRequestedButton(o: object): o is TypeRequestedButton
54735
+ type TypeAccessSettings = tl.bots.RawAccessSettings
54736
+ function isAnyAccessSettings(o: object): o is TypeAccessSettings
52974
54737
  }
52975
54738
 
52976
54739
  namespace stories {
@@ -54641,6 +56404,87 @@ export class RpcError extends Error {
54641
56404
  function isAnyCollectibleInfo(o: object): o is TypeCollectibleInfo
54642
56405
  }
54643
56406
 
56407
+ namespace aicompose {
56408
+ interface RawTonesNotModified {
56409
+ _: 'aicompose.tonesNotModified';
56410
+ }
56411
+ interface RawTones {
56412
+ _: 'aicompose.tones';
56413
+ hash: Long;
56414
+ tones: tl.TypeAiComposeTone[];
56415
+ users: tl.TypeUser[];
56416
+ }
56417
+ /**
56418
+ * RPC method returns {@link tl.TypeAiComposeTone}
56419
+ */
56420
+ interface RawCreateToneRequest {
56421
+ _: 'aicompose.createTone';
56422
+ displayAuthor?: boolean;
56423
+ emojiId: Long;
56424
+ title: string;
56425
+ prompt: string;
56426
+ }
56427
+ /**
56428
+ * RPC method returns {@link tl.TypeAiComposeTone}
56429
+ */
56430
+ interface RawUpdateToneRequest {
56431
+ _: 'aicompose.updateTone';
56432
+ tone: tl.TypeInputAiComposeTone;
56433
+ displayAuthor?: boolean;
56434
+ emojiId?: Long;
56435
+ title?: string;
56436
+ prompt?: string;
56437
+ }
56438
+ /**
56439
+ * RPC method returns boolean
56440
+ */
56441
+ interface RawSaveToneRequest {
56442
+ _: 'aicompose.saveTone';
56443
+ tone: tl.TypeInputAiComposeTone;
56444
+ unsave: boolean;
56445
+ }
56446
+ /**
56447
+ * RPC method returns boolean
56448
+ */
56449
+ interface RawDeleteToneRequest {
56450
+ _: 'aicompose.deleteTone';
56451
+ tone: tl.TypeInputAiComposeTone;
56452
+ }
56453
+ /**
56454
+ * RPC method returns {@link tl.aicompose.TypeTones}
56455
+ */
56456
+ interface RawGetToneRequest {
56457
+ _: 'aicompose.getTone';
56458
+ tone: tl.TypeInputAiComposeTone;
56459
+ }
56460
+ /**
56461
+ * RPC method returns {@link tl.aicompose.TypeTones}
56462
+ */
56463
+ interface RawGetTonesRequest {
56464
+ _: 'aicompose.getTones';
56465
+ hash: Long;
56466
+ }
56467
+ /**
56468
+ * RPC method returns {@link tl.TypeAiComposeToneExample}
56469
+ */
56470
+ interface RawGetToneExampleRequest {
56471
+ _: 'aicompose.getToneExample';
56472
+ tone: tl.TypeInputAiComposeTone;
56473
+ num: number;
56474
+ }
56475
+ interface RpcCallReturn {
56476
+ 'aicompose.createTone': tl.TypeAiComposeTone
56477
+ 'aicompose.updateTone': tl.TypeAiComposeTone
56478
+ 'aicompose.saveTone': boolean
56479
+ 'aicompose.deleteTone': boolean
56480
+ 'aicompose.getTone': tl.aicompose.TypeTones
56481
+ 'aicompose.getTones': tl.aicompose.TypeTones
56482
+ 'aicompose.getToneExample': tl.TypeAiComposeToneExample
56483
+ }
56484
+ type TypeTones = tl.aicompose.RawTonesNotModified | tl.aicompose.RawTones
56485
+ function isAnyTones(o: object): o is TypeTones
56486
+ }
56487
+
54644
56488
  namespace mtcute {
54645
56489
  interface RawDummyUpdate {
54646
56490
  _: 'mtcute.dummyUpdate';
@@ -54671,7 +56515,7 @@ export class RpcError extends Error {
54671
56515
  /**
54672
56516
  * Object contains info on events occurred.
54673
56517
  */
54674
- type TypeUpdate = tl.RawUpdateNewMessage | tl.RawUpdateMessageID | tl.RawUpdateDeleteMessages | tl.RawUpdateUserTyping | tl.RawUpdateChatUserTyping | tl.RawUpdateChatParticipants | tl.RawUpdateUserStatus | tl.RawUpdateUserName | tl.RawUpdateNewAuthorization | tl.RawUpdateNewEncryptedMessage | tl.RawUpdateEncryptedChatTyping | tl.RawUpdateEncryption | tl.RawUpdateEncryptedMessagesRead | tl.RawUpdateChatParticipantAdd | tl.RawUpdateChatParticipantDelete | tl.RawUpdateDcOptions | tl.RawUpdateNotifySettings | tl.RawUpdateServiceNotification | tl.RawUpdatePrivacy | tl.RawUpdateUserPhone | tl.RawUpdateReadHistoryInbox | tl.RawUpdateReadHistoryOutbox | tl.RawUpdateWebPage | tl.RawUpdateReadMessagesContents | tl.RawUpdateChannelTooLong | tl.RawUpdateChannel | tl.RawUpdateNewChannelMessage | tl.RawUpdateReadChannelInbox | tl.RawUpdateDeleteChannelMessages | tl.RawUpdateChannelMessageViews | tl.RawUpdateChatParticipantAdmin | tl.RawUpdateNewStickerSet | tl.RawUpdateStickerSetsOrder | tl.RawUpdateStickerSets | tl.RawUpdateSavedGifs | tl.RawUpdateBotInlineQuery | tl.RawUpdateBotInlineSend | tl.RawUpdateEditChannelMessage | tl.RawUpdateBotCallbackQuery | tl.RawUpdateEditMessage | tl.RawUpdateInlineBotCallbackQuery | tl.RawUpdateReadChannelOutbox | tl.RawUpdateDraftMessage | tl.RawUpdateReadFeaturedStickers | tl.RawUpdateRecentStickers | tl.RawUpdateConfig | tl.RawUpdatePtsChanged | tl.RawUpdateChannelWebPage | tl.RawUpdateDialogPinned | tl.RawUpdatePinnedDialogs | tl.RawUpdateBotWebhookJSON | tl.RawUpdateBotWebhookJSONQuery | tl.RawUpdateBotShippingQuery | tl.RawUpdateBotPrecheckoutQuery | tl.RawUpdatePhoneCall | tl.RawUpdateLangPackTooLong | tl.RawUpdateLangPack | tl.RawUpdateFavedStickers | tl.RawUpdateChannelReadMessagesContents | tl.RawUpdateContactsReset | tl.RawUpdateChannelAvailableMessages | tl.RawUpdateDialogUnreadMark | tl.RawUpdateMessagePoll | tl.RawUpdateChatDefaultBannedRights | tl.RawUpdateFolderPeers | tl.RawUpdatePeerSettings | tl.RawUpdatePeerLocated | tl.RawUpdateNewScheduledMessage | tl.RawUpdateDeleteScheduledMessages | tl.RawUpdateTheme | tl.RawUpdateGeoLiveViewed | tl.RawUpdateLoginToken | tl.RawUpdateMessagePollVote | tl.RawUpdateDialogFilter | tl.RawUpdateDialogFilterOrder | tl.RawUpdateDialogFilters | tl.RawUpdatePhoneCallSignalingData | tl.RawUpdateChannelMessageForwards | tl.RawUpdateReadChannelDiscussionInbox | tl.RawUpdateReadChannelDiscussionOutbox | tl.RawUpdatePeerBlocked | tl.RawUpdateChannelUserTyping | tl.RawUpdatePinnedMessages | tl.RawUpdatePinnedChannelMessages | tl.RawUpdateChat | tl.RawUpdateGroupCallParticipants | tl.RawUpdateGroupCall | tl.RawUpdatePeerHistoryTTL | tl.RawUpdateChatParticipant | tl.RawUpdateChannelParticipant | tl.RawUpdateBotStopped | tl.RawUpdateGroupCallConnection | tl.RawUpdateBotCommands | tl.RawUpdatePendingJoinRequests | tl.RawUpdateBotChatInviteRequester | tl.RawUpdateMessageReactions | tl.RawUpdateAttachMenuBots | tl.RawUpdateWebViewResultSent | tl.RawUpdateBotMenuButton | tl.RawUpdateSavedRingtones | tl.RawUpdateTranscribedAudio | tl.RawUpdateReadFeaturedEmojiStickers | tl.RawUpdateUserEmojiStatus | tl.RawUpdateRecentEmojiStatuses | tl.RawUpdateRecentReactions | tl.RawUpdateMoveStickerSetToTop | tl.RawUpdateMessageExtendedMedia | tl.RawUpdateUser | tl.RawUpdateAutoSaveSettings | tl.RawUpdateStory | tl.RawUpdateReadStories | tl.RawUpdateStoryID | tl.RawUpdateStoriesStealthMode | tl.RawUpdateSentStoryReaction | tl.RawUpdateBotChatBoost | tl.RawUpdateChannelViewForumAsMessages | tl.RawUpdatePeerWallpaper | tl.RawUpdateBotMessageReaction | tl.RawUpdateBotMessageReactions | tl.RawUpdateSavedDialogPinned | tl.RawUpdatePinnedSavedDialogs | tl.RawUpdateSavedReactionTags | tl.RawUpdateSmsJob | tl.RawUpdateQuickReplies | tl.RawUpdateNewQuickReply | tl.RawUpdateDeleteQuickReply | tl.RawUpdateQuickReplyMessage | tl.RawUpdateDeleteQuickReplyMessages | tl.RawUpdateBotBusinessConnect | tl.RawUpdateBotNewBusinessMessage | tl.RawUpdateBotEditBusinessMessage | tl.RawUpdateBotDeleteBusinessMessage | tl.RawUpdateNewStoryReaction | tl.RawUpdateStarsBalance | tl.RawUpdateBusinessBotCallbackQuery | tl.RawUpdateStarsRevenueStatus | tl.RawUpdateBotPurchasedPaidMedia | tl.RawUpdatePaidReactionPrivacy | tl.RawUpdateSentPhoneCode | tl.RawUpdateGroupCallChainBlocks | tl.RawUpdateReadMonoForumInbox | tl.RawUpdateReadMonoForumOutbox | tl.RawUpdateMonoForumNoPaidException | tl.RawUpdateGroupCallMessage | tl.RawUpdateGroupCallEncryptedMessage | tl.RawUpdatePinnedForumTopic | tl.RawUpdatePinnedForumTopics | tl.RawUpdateDeleteGroupCallMessages | tl.RawUpdateStarGiftAuctionState | tl.RawUpdateStarGiftAuctionUserState | tl.RawUpdateEmojiGameInfo | tl.RawUpdateStarGiftCraftFail | tl.RawUpdateChatParticipantRank | tl.RawUpdateManagedBot | tl.RawUpdateChannelPinnedTopic | tl.RawUpdateChannelPinnedTopics | tl.mtcute.RawDummyUpdate
56518
+ type TypeUpdate = tl.RawUpdateNewMessage | tl.RawUpdateMessageID | tl.RawUpdateDeleteMessages | tl.RawUpdateUserTyping | tl.RawUpdateChatUserTyping | tl.RawUpdateChatParticipants | tl.RawUpdateUserStatus | tl.RawUpdateUserName | tl.RawUpdateNewAuthorization | tl.RawUpdateNewEncryptedMessage | tl.RawUpdateEncryptedChatTyping | tl.RawUpdateEncryption | tl.RawUpdateEncryptedMessagesRead | tl.RawUpdateChatParticipantAdd | tl.RawUpdateChatParticipantDelete | tl.RawUpdateDcOptions | tl.RawUpdateNotifySettings | tl.RawUpdateServiceNotification | tl.RawUpdatePrivacy | tl.RawUpdateUserPhone | tl.RawUpdateReadHistoryInbox | tl.RawUpdateReadHistoryOutbox | tl.RawUpdateWebPage | tl.RawUpdateReadMessagesContents | tl.RawUpdateChannelTooLong | tl.RawUpdateChannel | tl.RawUpdateNewChannelMessage | tl.RawUpdateReadChannelInbox | tl.RawUpdateDeleteChannelMessages | tl.RawUpdateChannelMessageViews | tl.RawUpdateChatParticipantAdmin | tl.RawUpdateNewStickerSet | tl.RawUpdateStickerSetsOrder | tl.RawUpdateStickerSets | tl.RawUpdateSavedGifs | tl.RawUpdateBotInlineQuery | tl.RawUpdateBotInlineSend | tl.RawUpdateEditChannelMessage | tl.RawUpdateBotCallbackQuery | tl.RawUpdateEditMessage | tl.RawUpdateInlineBotCallbackQuery | tl.RawUpdateReadChannelOutbox | tl.RawUpdateDraftMessage | tl.RawUpdateReadFeaturedStickers | tl.RawUpdateRecentStickers | tl.RawUpdateConfig | tl.RawUpdatePtsChanged | tl.RawUpdateChannelWebPage | tl.RawUpdateDialogPinned | tl.RawUpdatePinnedDialogs | tl.RawUpdateBotWebhookJSON | tl.RawUpdateBotWebhookJSONQuery | tl.RawUpdateBotShippingQuery | tl.RawUpdateBotPrecheckoutQuery | tl.RawUpdatePhoneCall | tl.RawUpdateLangPackTooLong | tl.RawUpdateLangPack | tl.RawUpdateFavedStickers | tl.RawUpdateChannelReadMessagesContents | tl.RawUpdateContactsReset | tl.RawUpdateChannelAvailableMessages | tl.RawUpdateDialogUnreadMark | tl.RawUpdateMessagePoll | tl.RawUpdateChatDefaultBannedRights | tl.RawUpdateFolderPeers | tl.RawUpdatePeerSettings | tl.RawUpdatePeerLocated | tl.RawUpdateNewScheduledMessage | tl.RawUpdateDeleteScheduledMessages | tl.RawUpdateTheme | tl.RawUpdateGeoLiveViewed | tl.RawUpdateLoginToken | tl.RawUpdateMessagePollVote | tl.RawUpdateDialogFilter | tl.RawUpdateDialogFilterOrder | tl.RawUpdateDialogFilters | tl.RawUpdatePhoneCallSignalingData | tl.RawUpdateChannelMessageForwards | tl.RawUpdateReadChannelDiscussionInbox | tl.RawUpdateReadChannelDiscussionOutbox | tl.RawUpdatePeerBlocked | tl.RawUpdateChannelUserTyping | tl.RawUpdatePinnedMessages | tl.RawUpdatePinnedChannelMessages | tl.RawUpdateChat | tl.RawUpdateGroupCallParticipants | tl.RawUpdateGroupCall | tl.RawUpdatePeerHistoryTTL | tl.RawUpdateChatParticipant | tl.RawUpdateChannelParticipant | tl.RawUpdateBotStopped | tl.RawUpdateGroupCallConnection | tl.RawUpdateBotCommands | tl.RawUpdatePendingJoinRequests | tl.RawUpdateBotChatInviteRequester | tl.RawUpdateMessageReactions | tl.RawUpdateAttachMenuBots | tl.RawUpdateWebViewResultSent | tl.RawUpdateBotMenuButton | tl.RawUpdateSavedRingtones | tl.RawUpdateTranscribedAudio | tl.RawUpdateReadFeaturedEmojiStickers | tl.RawUpdateUserEmojiStatus | tl.RawUpdateRecentEmojiStatuses | tl.RawUpdateRecentReactions | tl.RawUpdateMoveStickerSetToTop | tl.RawUpdateMessageExtendedMedia | tl.RawUpdateUser | tl.RawUpdateAutoSaveSettings | tl.RawUpdateStory | tl.RawUpdateReadStories | tl.RawUpdateStoryID | tl.RawUpdateStoriesStealthMode | tl.RawUpdateSentStoryReaction | tl.RawUpdateBotChatBoost | tl.RawUpdateChannelViewForumAsMessages | tl.RawUpdatePeerWallpaper | tl.RawUpdateBotMessageReaction | tl.RawUpdateBotMessageReactions | tl.RawUpdateSavedDialogPinned | tl.RawUpdatePinnedSavedDialogs | tl.RawUpdateSavedReactionTags | tl.RawUpdateSmsJob | tl.RawUpdateQuickReplies | tl.RawUpdateNewQuickReply | tl.RawUpdateDeleteQuickReply | tl.RawUpdateQuickReplyMessage | tl.RawUpdateDeleteQuickReplyMessages | tl.RawUpdateBotBusinessConnect | tl.RawUpdateBotNewBusinessMessage | tl.RawUpdateBotEditBusinessMessage | tl.RawUpdateBotDeleteBusinessMessage | tl.RawUpdateNewStoryReaction | tl.RawUpdateStarsBalance | tl.RawUpdateBusinessBotCallbackQuery | tl.RawUpdateStarsRevenueStatus | tl.RawUpdateBotPurchasedPaidMedia | tl.RawUpdatePaidReactionPrivacy | tl.RawUpdateSentPhoneCode | tl.RawUpdateGroupCallChainBlocks | tl.RawUpdateReadMonoForumInbox | tl.RawUpdateReadMonoForumOutbox | tl.RawUpdateMonoForumNoPaidException | tl.RawUpdateGroupCallMessage | tl.RawUpdateGroupCallEncryptedMessage | tl.RawUpdatePinnedForumTopic | tl.RawUpdatePinnedForumTopics | tl.RawUpdateDeleteGroupCallMessages | tl.RawUpdateStarGiftAuctionState | tl.RawUpdateStarGiftAuctionUserState | tl.RawUpdateEmojiGameInfo | tl.RawUpdateStarGiftCraftFail | tl.RawUpdateChatParticipantRank | tl.RawUpdateManagedBot | tl.RawUpdateBotGuestChatQuery | tl.RawUpdateAiComposeTones | tl.RawUpdateChannelPinnedTopic | tl.RawUpdateChannelPinnedTopics | tl.mtcute.RawDummyUpdate
54675
56519
  function isAnyUpdate(o: object): o is TypeUpdate
54676
56520
  /**
54677
56521
  * Peer
@@ -55250,6 +57094,17 @@ export class RpcError extends Error {
55250
57094
  | tl.messages.RawEditChatParticipantRankRequest
55251
57095
  | tl.messages.RawDeclineUrlAuthRequest
55252
57096
  | tl.messages.RawCheckUrlAuthMatchCodeRequest
57097
+ | tl.messages.RawComposeMessageWithAIRequest
57098
+ | tl.messages.RawReportReadMetricsRequest
57099
+ | tl.messages.RawReportMusicListenRequest
57100
+ | tl.messages.RawAddPollAnswerRequest
57101
+ | tl.messages.RawDeletePollAnswerRequest
57102
+ | tl.messages.RawGetUnreadPollVotesRequest
57103
+ | tl.messages.RawReadPollVotesRequest
57104
+ | tl.messages.RawSetBotGuestChatResultRequest
57105
+ | tl.messages.RawDeleteParticipantReactionsRequest
57106
+ | tl.messages.RawDeleteParticipantReactionRequest
57107
+ | tl.messages.RawGetPersonalChannelHistoryRequest
55253
57108
  | tl.updates.RawGetStateRequest
55254
57109
  | tl.updates.RawGetDifferenceRequest
55255
57110
  | tl.updates.RawGetChannelDifferenceRequest
@@ -55379,6 +57234,13 @@ export class RpcError extends Error {
55379
57234
  | tl.bots.RawUpdateStarRefProgramRequest
55380
57235
  | tl.bots.RawSetCustomVerificationRequest
55381
57236
  | tl.bots.RawGetBotRecommendationsRequest
57237
+ | tl.bots.RawCheckUsernameRequest
57238
+ | tl.bots.RawCreateBotRequest
57239
+ | tl.bots.RawExportBotTokenRequest
57240
+ | tl.bots.RawRequestWebViewButtonRequest
57241
+ | tl.bots.RawGetRequestedWebViewButtonRequest
57242
+ | tl.bots.RawGetAccessSettingsRequest
57243
+ | tl.bots.RawEditAccessSettingsRequest
55382
57244
  | tl.payments.RawGetPaymentFormRequest
55383
57245
  | tl.payments.RawGetPaymentReceiptRequest
55384
57246
  | tl.payments.RawValidateRequestedInfoRequest
@@ -55511,6 +57373,7 @@ export class RpcError extends Error {
55511
57373
  | tl.stats.RawGetMessageStatsRequest
55512
57374
  | tl.stats.RawGetStoryStatsRequest
55513
57375
  | tl.stats.RawGetStoryPublicForwardsRequest
57376
+ | tl.stats.RawGetPollStatsRequest
55514
57377
  | tl.chatlists.RawExportChatlistInviteRequest
55515
57378
  | tl.chatlists.RawDeleteExportedInviteRequest
55516
57379
  | tl.chatlists.RawEditExportedInviteRequest
@@ -55568,18 +57431,13 @@ export class RpcError extends Error {
55568
57431
  | tl.smsjobs.RawGetSmsJobRequest
55569
57432
  | tl.smsjobs.RawFinishJobRequest
55570
57433
  | tl.fragment.RawGetCollectibleInfoRequest
55571
- | tl.messages.RawComposeMessageWithAIRequest
55572
- | tl.messages.RawReportReadMetricsRequest
55573
- | tl.messages.RawReportMusicListenRequest
55574
- | tl.messages.RawAddPollAnswerRequest
55575
- | tl.messages.RawDeletePollAnswerRequest
55576
- | tl.messages.RawGetUnreadPollVotesRequest
55577
- | tl.messages.RawReadPollVotesRequest
55578
- | tl.bots.RawCheckUsernameRequest
55579
- | tl.bots.RawCreateBotRequest
55580
- | tl.bots.RawExportBotTokenRequest
55581
- | tl.bots.RawRequestWebViewButtonRequest
55582
- | tl.bots.RawGetRequestedWebViewButtonRequest
57434
+ | tl.aicompose.RawCreateToneRequest
57435
+ | tl.aicompose.RawUpdateToneRequest
57436
+ | tl.aicompose.RawSaveToneRequest
57437
+ | tl.aicompose.RawDeleteToneRequest
57438
+ | tl.aicompose.RawGetToneRequest
57439
+ | tl.aicompose.RawGetTonesRequest
57440
+ | tl.aicompose.RawGetToneExampleRequest
55583
57441
  | tl.channels.RawEditCreatorRequest
55584
57442
  | tl.channels.RawCreateForumTopicRequest
55585
57443
  | tl.channels.RawGetForumTopicsRequest
@@ -55769,6 +57627,9 @@ export class RpcError extends Error {
55769
57627
  | tl.RawMessageActionChangeCreator
55770
57628
  | tl.RawMessageActionNoForwardsToggle
55771
57629
  | tl.RawMessageActionNoForwardsRequest
57630
+ | tl.RawMessageActionPollAppendAnswer
57631
+ | tl.RawMessageActionPollDeleteAnswer
57632
+ | tl.RawMessageActionManagedBotCreated
55772
57633
  | tl.RawDialog
55773
57634
  | tl.RawDialogFolder
55774
57635
  | tl.RawPhotoEmpty
@@ -55844,6 +57705,7 @@ export class RpcError extends Error {
55844
57705
  | tl.RawInputMessagesFilterGeo
55845
57706
  | tl.RawInputMessagesFilterContacts
55846
57707
  | tl.RawInputMessagesFilterPinned
57708
+ | tl.RawInputMessagesFilterPoll
55847
57709
  | tl.RawUpdateNewMessage
55848
57710
  | tl.RawUpdateMessageID
55849
57711
  | tl.RawUpdateDeleteMessages
@@ -55997,6 +57859,9 @@ export class RpcError extends Error {
55997
57859
  | tl.RawUpdateEmojiGameInfo
55998
57860
  | tl.RawUpdateStarGiftCraftFail
55999
57861
  | tl.RawUpdateChatParticipantRank
57862
+ | tl.RawUpdateManagedBot
57863
+ | tl.RawUpdateBotGuestChatQuery
57864
+ | tl.RawUpdateAiComposeTones
56000
57865
  | tl.updates.RawState
56001
57866
  | tl.updates.RawDifferenceEmpty
56002
57867
  | tl.updates.RawDifference
@@ -56214,6 +58079,9 @@ export class RpcError extends Error {
56214
58079
  | tl.RawMessageEntityCustomEmoji
56215
58080
  | tl.RawMessageEntityBlockquote
56216
58081
  | tl.RawMessageEntityFormattedDate
58082
+ | tl.RawMessageEntityDiffInsert
58083
+ | tl.RawMessageEntityDiffReplace
58084
+ | tl.RawMessageEntityDiffDelete
56217
58085
  | tl.RawInputChannelEmpty
56218
58086
  | tl.RawInputChannel
56219
58087
  | tl.RawInputChannelFromMessage
@@ -56300,6 +58168,7 @@ export class RpcError extends Error {
56300
58168
  | tl.RawTopPeerCategoryForwardUsers
56301
58169
  | tl.RawTopPeerCategoryForwardChats
56302
58170
  | tl.RawTopPeerCategoryBotsApp
58171
+ | tl.RawTopPeerCategoryBotsGuestChat
56303
58172
  | tl.RawTopPeerCategoryPeers
56304
58173
  | tl.contacts.RawTopPeersNotModified
56305
58174
  | tl.contacts.RawTopPeers
@@ -56578,6 +58447,7 @@ export class RpcError extends Error {
56578
58447
  | tl.help.RawUserInfoEmpty
56579
58448
  | tl.help.RawUserInfo
56580
58449
  | tl.RawPollAnswer
58450
+ | tl.RawInputPollAnswer
56581
58451
  | tl.RawPoll
56582
58452
  | tl.RawPollAnswerVoters
56583
58453
  | tl.RawPollResults
@@ -56634,6 +58504,7 @@ export class RpcError extends Error {
56634
58504
  | tl.RawWebPageAttributeUniqueStarGift
56635
58505
  | tl.RawWebPageAttributeStarGiftCollection
56636
58506
  | tl.RawWebPageAttributeStarGiftAuction
58507
+ | tl.RawWebPageAttributeAiComposeTone
56637
58508
  | tl.messages.RawVotesList
56638
58509
  | tl.RawBankCardOpenUrl
56639
58510
  | tl.payments.RawBankCardData
@@ -56823,6 +58694,7 @@ export class RpcError extends Error {
56823
58694
  | tl.RawRequestPeerTypeUser
56824
58695
  | tl.RawRequestPeerTypeChat
56825
58696
  | tl.RawRequestPeerTypeBroadcast
58697
+ | tl.RawRequestPeerTypeCreateBot
56826
58698
  | tl.RawEmojiListNotModified
56827
58699
  | tl.RawEmojiList
56828
58700
  | tl.RawEmojiGroup
@@ -57134,20 +59006,20 @@ export class RpcError extends Error {
57134
59006
  | tl.RawStarGiftAttributeRarityEpic
57135
59007
  | tl.RawStarGiftAttributeRarityLegendary
57136
59008
  | tl.RawKeyboardButtonStyle
57137
- | tl.RawMessageActionPollAppendAnswer
57138
- | tl.RawMessageActionPollDeleteAnswer
57139
- | tl.RawMessageActionManagedBotCreated
57140
- | tl.RawInputMessagesFilterPoll
57141
- | tl.RawUpdateManagedBot
57142
- | tl.RawMessageEntityDiffInsert
57143
- | tl.RawMessageEntityDiffReplace
57144
- | tl.RawMessageEntityDiffDelete
57145
- | tl.RawInputPollAnswer
57146
- | tl.RawRequestPeerTypeCreateBot
57147
59009
  | tl.RawInputMessageReadMetric
57148
59010
  | tl.bots.RawExportedBotToken
57149
59011
  | tl.bots.RawRequestedButton
57150
59012
  | tl.messages.RawComposedMessageWithAI
59013
+ | tl.stats.RawPollStats
59014
+ | tl.RawInputAiComposeToneDefault
59015
+ | tl.RawInputAiComposeToneID
59016
+ | tl.RawInputAiComposeToneSlug
59017
+ | tl.RawAiComposeTone
59018
+ | tl.RawAiComposeToneDefault
59019
+ | tl.aicompose.RawTonesNotModified
59020
+ | tl.aicompose.RawTones
59021
+ | tl.RawAiComposeToneExample
59022
+ | tl.bots.RawAccessSettings
57151
59023
  | tl.RawUpdateChannelPinnedTopic
57152
59024
  | tl.RawUpdateChannelPinnedTopics
57153
59025
  | tl.mtcute.RawDummyUpdate
@@ -57592,6 +59464,17 @@ export class RpcError extends Error {
57592
59464
  | tl.messages.RawEditChatParticipantRankRequest
57593
59465
  | tl.messages.RawDeclineUrlAuthRequest
57594
59466
  | tl.messages.RawCheckUrlAuthMatchCodeRequest
59467
+ | tl.messages.RawComposeMessageWithAIRequest
59468
+ | tl.messages.RawReportReadMetricsRequest
59469
+ | tl.messages.RawReportMusicListenRequest
59470
+ | tl.messages.RawAddPollAnswerRequest
59471
+ | tl.messages.RawDeletePollAnswerRequest
59472
+ | tl.messages.RawGetUnreadPollVotesRequest
59473
+ | tl.messages.RawReadPollVotesRequest
59474
+ | tl.messages.RawSetBotGuestChatResultRequest
59475
+ | tl.messages.RawDeleteParticipantReactionsRequest
59476
+ | tl.messages.RawDeleteParticipantReactionRequest
59477
+ | tl.messages.RawGetPersonalChannelHistoryRequest
57595
59478
  | tl.updates.RawGetStateRequest
57596
59479
  | tl.updates.RawGetDifferenceRequest
57597
59480
  | tl.updates.RawGetChannelDifferenceRequest
@@ -57721,6 +59604,13 @@ export class RpcError extends Error {
57721
59604
  | tl.bots.RawUpdateStarRefProgramRequest
57722
59605
  | tl.bots.RawSetCustomVerificationRequest
57723
59606
  | tl.bots.RawGetBotRecommendationsRequest
59607
+ | tl.bots.RawCheckUsernameRequest
59608
+ | tl.bots.RawCreateBotRequest
59609
+ | tl.bots.RawExportBotTokenRequest
59610
+ | tl.bots.RawRequestWebViewButtonRequest
59611
+ | tl.bots.RawGetRequestedWebViewButtonRequest
59612
+ | tl.bots.RawGetAccessSettingsRequest
59613
+ | tl.bots.RawEditAccessSettingsRequest
57724
59614
  | tl.payments.RawGetPaymentFormRequest
57725
59615
  | tl.payments.RawGetPaymentReceiptRequest
57726
59616
  | tl.payments.RawValidateRequestedInfoRequest
@@ -57853,6 +59743,7 @@ export class RpcError extends Error {
57853
59743
  | tl.stats.RawGetMessageStatsRequest
57854
59744
  | tl.stats.RawGetStoryStatsRequest
57855
59745
  | tl.stats.RawGetStoryPublicForwardsRequest
59746
+ | tl.stats.RawGetPollStatsRequest
57856
59747
  | tl.chatlists.RawExportChatlistInviteRequest
57857
59748
  | tl.chatlists.RawDeleteExportedInviteRequest
57858
59749
  | tl.chatlists.RawEditExportedInviteRequest
@@ -57910,18 +59801,13 @@ export class RpcError extends Error {
57910
59801
  | tl.smsjobs.RawGetSmsJobRequest
57911
59802
  | tl.smsjobs.RawFinishJobRequest
57912
59803
  | tl.fragment.RawGetCollectibleInfoRequest
57913
- | tl.messages.RawComposeMessageWithAIRequest
57914
- | tl.messages.RawReportReadMetricsRequest
57915
- | tl.messages.RawReportMusicListenRequest
57916
- | tl.messages.RawAddPollAnswerRequest
57917
- | tl.messages.RawDeletePollAnswerRequest
57918
- | tl.messages.RawGetUnreadPollVotesRequest
57919
- | tl.messages.RawReadPollVotesRequest
57920
- | tl.bots.RawCheckUsernameRequest
57921
- | tl.bots.RawCreateBotRequest
57922
- | tl.bots.RawExportBotTokenRequest
57923
- | tl.bots.RawRequestWebViewButtonRequest
57924
- | tl.bots.RawGetRequestedWebViewButtonRequest
59804
+ | tl.aicompose.RawCreateToneRequest
59805
+ | tl.aicompose.RawUpdateToneRequest
59806
+ | tl.aicompose.RawSaveToneRequest
59807
+ | tl.aicompose.RawDeleteToneRequest
59808
+ | tl.aicompose.RawGetToneRequest
59809
+ | tl.aicompose.RawGetTonesRequest
59810
+ | tl.aicompose.RawGetToneExampleRequest
57925
59811
  | tl.channels.RawEditCreatorRequest
57926
59812
  | tl.channels.RawCreateForumTopicRequest
57927
59813
  | tl.channels.RawGetForumTopicsRequest
@@ -58306,6 +60192,9 @@ export declare function isAnyStarGiftAuctionRound(o: object): o is tl.TypeStarGi
58306
60192
  export declare function isAnyStarGiftAttributeRarity(o: object): o is tl.TypeStarGiftAttributeRarity
58307
60193
  export declare function isAnyKeyboardButtonStyle(o: object): o is tl.TypeKeyboardButtonStyle
58308
60194
  export declare function isAnyInputMessageReadMetric(o: object): o is tl.TypeInputMessageReadMetric
60195
+ export declare function isAnyInputAiComposeTone(o: object): o is tl.TypeInputAiComposeTone
60196
+ export declare function isAnyAiComposeTone(o: object): o is tl.TypeAiComposeTone
60197
+ export declare function isAnyAiComposeToneExample(o: object): o is tl.TypeAiComposeToneExample
58309
60198
  export declare function isAnyStorage_FileType(o: object): o is tl.storage.TypeFileType
58310
60199
  export declare function isAnyAuth_SentCode(o: object): o is tl.auth.TypeSentCode
58311
60200
  export declare function isAnyAuth_Authorization(o: object): o is tl.auth.TypeAuthorization
@@ -58489,6 +60378,7 @@ export declare function isAnyStats_MegagroupStats(o: object): o is tl.stats.Type
58489
60378
  export declare function isAnyStats_MessageStats(o: object): o is tl.stats.TypeMessageStats
58490
60379
  export declare function isAnyStats_StoryStats(o: object): o is tl.stats.TypeStoryStats
58491
60380
  export declare function isAnyStats_PublicForwards(o: object): o is tl.stats.TypePublicForwards
60381
+ export declare function isAnyStats_PollStats(o: object): o is tl.stats.TypePollStats
58492
60382
  export declare function isAnyStickers_SuggestedShortName(o: object): o is tl.stickers.TypeSuggestedShortName
58493
60383
  export declare function isAnyUsers_UserFull(o: object): o is tl.users.TypeUserFull
58494
60384
  export declare function isAnyUsers_Users(o: object): o is tl.users.TypeUsers
@@ -58502,6 +60392,7 @@ export declare function isAnyBots_PopularAppBots(o: object): o is tl.bots.TypePo
58502
60392
  export declare function isAnyBots_PreviewInfo(o: object): o is tl.bots.TypePreviewInfo
58503
60393
  export declare function isAnyBots_ExportedBotToken(o: object): o is tl.bots.TypeExportedBotToken
58504
60394
  export declare function isAnyBots_RequestedButton(o: object): o is tl.bots.TypeRequestedButton
60395
+ export declare function isAnyBots_AccessSettings(o: object): o is tl.bots.TypeAccessSettings
58505
60396
  export declare function isAnyStories_AllStories(o: object): o is tl.stories.TypeAllStories
58506
60397
  export declare function isAnyStories_Stories(o: object): o is tl.stories.TypeStories
58507
60398
  export declare function isAnyStories_StoryViewsList(o: object): o is tl.stories.TypeStoryViewsList
@@ -58517,6 +60408,7 @@ export declare function isAnyPremium_BoostsStatus(o: object): o is tl.premium.Ty
58517
60408
  export declare function isAnySmsjobs_EligibilityToJoin(o: object): o is tl.smsjobs.TypeEligibilityToJoin
58518
60409
  export declare function isAnySmsjobs_Status(o: object): o is tl.smsjobs.TypeStatus
58519
60410
  export declare function isAnyFragment_CollectibleInfo(o: object): o is tl.fragment.TypeCollectibleInfo
60411
+ export declare function isAnyAicompose_Tones(o: object): o is tl.aicompose.TypeTones
58520
60412
  export declare function isAnyMtcute_Update(o: object): o is tl.mtcute.TypeUpdate
58521
60413
  export declare function isAnyMtcute_InputPeer(o: object): o is tl.mtcute.TypeInputPeer
58522
60414