From 5f411d45f983bb7acd570f2cf01e0eb27ba46791 Mon Sep 17 00:00:00 2001 From: Wizou <11647984+wiz0u@users.noreply.github.com> Date: Sat, 16 Aug 2025 13:01:43 +0200 Subject: [PATCH] API Layer 211.2: StarsTransaction flag posts_search --- src/TL.Schema.cs | 73 ++++++++++++++--- src/TL.SchemaFuncs.cs | 186 +++++++++++++++++++++--------------------- src/TL.Table.cs | 2 +- 3 files changed, 157 insertions(+), 104 deletions(-) diff --git a/src/TL.Schema.cs b/src/TL.Schema.cs index 21e4c2b..299c969 100644 --- a/src/TL.Schema.cs +++ b/src/TL.Schema.cs @@ -2945,10 +2945,14 @@ namespace TL [IfFlag(1)] public TextWithEntities message; /// The receiver of this gift may convert it to this many Telegram Stars, instead of displaying it on their profile page.
convert_stars will be equal to stars only if the gift was bought using recently bought Telegram Stars, otherwise it will be less than stars.
[IfFlag(4)] public long convert_stars; + /// If set, this gift was upgraded to a collectible gift, and the corresponding is available at the specified message ID. [IfFlag(5)] public int upgrade_msg_id; [IfFlag(8)] public long upgrade_stars; + /// Sender of the gift (unset for anonymous gifts). [IfFlag(11)] public Peer from_id; + /// Receiver of the gift. [IfFlag(12)] public Peer peer; + /// For channel gifts, ID to use in s. [IfFlag(12)] public long saved_id; [Flags] public enum Flags : uint @@ -2963,10 +2967,13 @@ namespace TL converted = 0x8, /// Field has a value has_convert_stars = 0x10, + /// This gift was upgraded to a collectible gift ». upgraded = 0x20, /// Field has a value has_upgrade_stars = 0x100, + /// This gift is not available anymore because a request to refund the payment related to this gift was made, and the money was returned. refunded = 0x200, + /// If set, this gift can be upgraded to a collectible gift; can only be set for the receiver of a gift. can_upgrade = 0x400, /// Field has a value has_from_id = 0x800, @@ -2974,31 +2981,42 @@ namespace TL has_peer = 0x1000, } } - /// See + /// A gift » was upgraded to a collectible gift ». See [TLDef(0x34F762F3)] public sealed partial class MessageActionStarGiftUnique : MessageAction { /// Extra bits of information, use flags.HasFlag(...) to test for those public Flags flags; + /// The collectible gift. public StarGiftBase gift; [IfFlag(3)] public DateTime can_export_at; + /// If set, indicates that the gift can be transferred » to another user by paying the specified amount of stars. [IfFlag(4)] public long transfer_stars; + /// Sender of the gift (unset for anonymous gifts). [IfFlag(6)] public Peer from_id; + /// Receiver of the gift. [IfFlag(7)] public Peer peer; + /// For channel gifts, ID to use in s. [IfFlag(7)] public long saved_id; [IfFlag(8)] public StarsAmountBase resale_amount; + /// If set, indicates that the current gift can't be transferred » yet: the owner will be able to transfer it at the specified unixtime. [IfFlag(9)] public DateTime can_transfer_at; + /// If set, indicates that the current gift can't be resold » yet: the owner will be able to put it up for sale at the specified unixtime. [IfFlag(10)] public DateTime can_resell_at; [Flags] public enum Flags : uint { + /// If set, this collectible was upgraded » to a collectible gift from a previously received or sent (depending on the out flag of the containing ) non-collectible gift. upgrade = 0x1, + /// If set, this collectible was transferred (either to the current user or by the current user to the other user in the private chat, depending on the out flag of the containing ). transferred = 0x2, + /// If set, this gift is visible on the user or channel's profile page; can only be set for the receiver of a gift. saved = 0x4, /// Field has a value has_can_export_at = 0x8, /// Field has a value has_transfer_stars = 0x10, + /// This gift was upgraded to a collectible gift » and then re-downgraded to a regular gift because a request to refund the payment related to the upgrade was made, and the money was returned. refunded = 0x20, /// Field has a value has_from_id = 0x40, @@ -7584,7 +7602,7 @@ namespace TL public string display_url; /// Hash used for caching, for more info click here public int hash; - /// Type of the web page. One of the following:

- video
- gif
- photo
- document
- profile
- telegram_background
- telegram_theme
- telegram_story
- telegram_channel
- telegram_channel_request
- telegram_megagroup
- telegram_chat
- telegram_megagroup_request
- telegram_chat_request
- telegram_album
- telegram_message
- telegram_bot
- telegram_voicechat
- telegram_livestream
- telegram_call
- telegram_user
- telegram_botapp
- telegram_channel_boost
- telegram_group_boost
- telegram_giftcode
- telegram_stickerset

+ /// Type of the web page. One of the following:

- video
- gif
- photo
- document
- profile
- telegram_background
- telegram_theme
- telegram_story
- telegram_channel
- telegram_channel_request
- telegram_megagroup
- telegram_chat
- telegram_megagroup_request
- telegram_chat_request
- telegram_album
- telegram_message
- telegram_bot
- telegram_voicechat
- telegram_livestream
- telegram_call
- telegram_user
- telegram_botapp
- telegram_channel_boost
- telegram_group_boost
- telegram_giftcode
- telegram_stickerset
- telegram_story_album
- telegram_collection

[IfFlag(0)] public string type; /// Short name of the site (e.g., Google Docs, App Store) [IfFlag(1)] public string site_name; @@ -19749,6 +19767,7 @@ namespace TL stargift_resale = 0x400000, /// Fields and have a value has_ads_proceeds_from_date = 0x800000, + posts_search = 0x1000000, } } @@ -20186,12 +20205,13 @@ namespace TL public override string Title => title; public override Peer ReleasedBy => released_by; } - /// See + /// Represents a collectible star gift, see here » for more info. See [TLDef(0x3A274D50)] public sealed partial class StarGiftUnique : StarGiftBase { /// Extra bits of information, use flags.HasFlag(...) to test for those public Flags flags; + /// Identifier of the gift. public long id; public string title; public string slug; @@ -20224,6 +20244,7 @@ namespace TL resale_ton_only = 0x80, } + /// Identifier of the gift. public override long ID => id; public override int AvailabilityTotal => availability_total; public override string Title => title; @@ -20526,45 +20547,62 @@ namespace TL public string description; } - /// See Derived classes: , , , + /// An attribute of a collectible gift ». See Derived classes: , , , public abstract partial class StarGiftAttribute : IObject { } - /// See + /// The model of a collectible gift ». See [TLDef(0x39D99013)] public sealed partial class StarGiftAttributeModel : StarGiftAttribute { + /// Name of the model public string name; + /// The sticker representing the upgraded gift public DocumentBase document; + /// The number of upgraded gifts that receive this backdrop for each 1000 gifts upgraded. public int rarity_permille; } - /// See + /// A sticker applied on the backdrop of a collectible gift » using a repeating pattern. See [TLDef(0x13ACFF19)] public sealed partial class StarGiftAttributePattern : StarGiftAttribute { + /// Name of the symbol public string name; + /// The symbol public DocumentBase document; + /// The number of upgraded gifts that receive this backdrop for each 1000 gifts upgraded. public int rarity_permille; } - /// See + /// The backdrop of a collectible gift ». See [TLDef(0xD93D859C)] public sealed partial class StarGiftAttributeBackdrop : StarGiftAttribute { + /// Name of the backdrop public string name; + /// Unique ID of the backdrop public int backdrop_id; + /// Color of the center of the backdrop in RGB24 format. public int center_color; + /// Color of the edges of the backdrop in RGB24 format. public int edge_color; + /// Color of the applied on the backdrop in RGB24 format. public int pattern_color; + /// Color of the text on the backdrop in RGB24 format. public int text_color; + /// The number of upgraded gifts that receive this backdrop for each 1000 gifts upgraded. public int rarity_permille; } - /// See + /// Info about the sender, receiver and message attached to the original gift », before it was upgraded to a collectible gift ». See [TLDef(0xE0BFF26C)] public sealed partial class StarGiftAttributeOriginalDetails : StarGiftAttribute { /// Extra bits of information, use flags.HasFlag(...) to test for those public Flags flags; + /// Original sender of the gift, absent if the gift was private. [IfFlag(0)] public Peer sender_id; + /// Original receiver of the gift. public Peer recipient_id; + /// When was the gift sent. public DateTime date; + /// Original message attached to the gift, if present. [IfFlag(1)] public TextWithEntities message; [Flags] public enum Flags : uint @@ -20576,10 +20614,11 @@ namespace TL } } - /// See + /// A preview of the possible attributes (chosen randomly) a gift » can receive after upgrading it to a collectible gift », see here » for more info. See [TLDef(0x167BD90B)] public sealed partial class Payments_StarGiftUpgradePreview : IObject { + /// Possible gift attributes public StarGiftAttribute[] sample_attributes; } @@ -20690,17 +20729,20 @@ namespace TL /// See Derived classes: , , public abstract partial class InputSavedStarGift : IObject { } - /// See + /// A gift received in a private chat with another user. See [TLDef(0x69279795)] public sealed partial class InputSavedStarGiftUser : InputSavedStarGift { + /// ID of the with the with the gift. public int msg_id; } - /// See + /// A gift received by a channel we own. See [TLDef(0xF101AA7F)] public sealed partial class InputSavedStarGiftChat : InputSavedStarGift { + /// The channel. public InputPeer peer; + /// ID of the gift, must be the saved_id of a /. public long saved_id; } /// See @@ -20957,6 +20999,7 @@ namespace TL [TLDef(0x1B0E4F07)] public sealed partial class StarsRating : IObject { + /// Extra bits of information, use flags.HasFlag(...) to test for those public Flags flags; public int level; public long current_level_stars; @@ -20965,6 +21008,7 @@ namespace TL [Flags] public enum Flags : uint { + /// Field has a value has_next_level_stars = 0x1, } } @@ -20973,6 +21017,7 @@ namespace TL [TLDef(0x9D6B13B0)] public sealed partial class StarGiftCollection : IObject { + /// Extra bits of information, use flags.HasFlag(...) to test for those public Flags flags; public int collection_id; public string title; @@ -20982,6 +21027,7 @@ namespace TL [Flags] public enum Flags : uint { + /// Field has a value has_icon = 0x1, } } @@ -20998,6 +21044,7 @@ namespace TL [TLDef(0x9325705A)] public sealed partial class StoryAlbum : IObject { + /// Extra bits of information, use flags.HasFlag(...) to test for those public Flags flags; public int album_id; public string title; @@ -21006,7 +21053,9 @@ namespace TL [Flags] public enum Flags : uint { + /// Field has a value has_icon_photo = 0x1, + /// Field has a value has_icon_video = 0x2, } } @@ -21024,6 +21073,7 @@ namespace TL [TLDef(0x3E0B5B6A)] public sealed partial class SearchPostsFlood : IObject { + /// Extra bits of information, use flags.HasFlag(...) to test for those public Flags flags; public int total_daily; public int remains; @@ -21033,6 +21083,7 @@ namespace TL [Flags] public enum Flags : uint { query_is_free = 0x1, + /// Field has a value has_wait_till = 0x2, } } diff --git a/src/TL.SchemaFuncs.cs b/src/TL.SchemaFuncs.cs index c10d6f0..9ea3dd5 100644 --- a/src/TL.SchemaFuncs.cs +++ b/src/TL.SchemaFuncs.cs @@ -54,7 +54,7 @@ namespace TL query = query, }); - /// Invoke the specified query using the specified API layer See Possible codes: 400,403,406 (details) + /// Invoke the specified query using the specified API layer See Possible codes: -504,400,403,406 (details) /// The layer to use /// The query public static Task InvokeWithLayer(this Client client, int layer, IMethod query) @@ -212,7 +212,7 @@ namespace TL bytes = bytes, }); - /// Binds a temporary authorization key temp_auth_key_id to the permanent authorization key perm_auth_key_id. Each permanent key may only be bound to one temporary key at a time, binding a new temporary key overwrites the previous one. See [bots: ✓] Possible codes: 400 (details) + /// Binds a temporary authorization key temp_auth_key_id to the permanent authorization key perm_auth_key_id. Each permanent key may only be bound to one temporary key at a time, binding a new temporary key overwrites the previous one. See [bots: ✓] Possible codes: -504,400 (details) /// Permanent auth_key_id to bind to /// Random long from Binding message contents /// Unix timestamp to invalidate temporary key, see Binding message contents @@ -298,7 +298,7 @@ namespace TL except_auth_keys = except_auth_keys, }); - /// Generate a login token, for login via QR code.
The generated login token should be encoded using base64url, then shown as a tg://login?token=base64encodedtoken deep link » in the QR code. See Possible codes: 400 (details)
+ /// Generate a login token, for login via QR code.
The generated login token should be encoded using base64url, then shown as a tg://login?token=base64encodedtoken deep link » in the QR code. See Possible codes: -504,400 (details)
/// Application identifier (see. App configuration) /// Application identifier hash (see. App configuration) /// List of already logged-in user IDs, to prevent logging in twice with the same user @@ -452,7 +452,7 @@ namespace TL about = about, }); - /// Updates online user status. See + /// Updates online user status. See Possible codes: -504 (details) /// If is transmitted, user status will change to . public static Task Account_UpdateStatus(this Client client, bool offline) => client.Invoke(new Account_UpdateStatus @@ -1425,7 +1425,7 @@ namespace TL settings = settings, }); - /// See [bots: ✓] + /// See /// a null value means account.emojiStatusesNotModified public static Task Account_GetCollectibleEmojiStatuses(this Client client, long hash = default) => client.Invoke(new Account_GetCollectibleEmojiStatuses @@ -1433,7 +1433,7 @@ namespace TL hash = hash, }); - /// Get the number of stars we have received from the specified user thanks to paid messages »; the received amount will be equal to the sent amount multiplied by stars_paid_message_commission_permille divided by 1000. See [bots: ✓] + /// Get the number of stars we have received from the specified user thanks to paid messages »; the received amount will be equal to the sent amount multiplied by stars_paid_message_commission_permille divided by 1000. See Possible codes: 400 (details) /// If set, can contain the ID of a monoforum (channel direct messages) to obtain the number of stars the user has spent to send us direct messages via the channel. /// The user that paid to send us messages. public static Task Account_GetPaidMessagesRevenue(this Client client, InputUserBase user_id, InputPeer parent_peer = null) @@ -1444,9 +1444,9 @@ namespace TL user_id = user_id, }); - /// Allow a user to send us messages without paying if paid messages » are enabled. See [bots: ✓] + /// Allow a user to send us messages without paying if paid messages » are enabled. See Possible codes: 400 (details) /// If set and require_payment is not set, refunds the amounts the user has already paid us to send us messages (directly or via a monoforum). - /// If set, requires the user to pay in order to send us messages (can only be used by monoforums, not users, i.e. parent_peer must be set if this flag is set; users must instead use the privacy setting to remove a previously added exemption).
If not set, allows the user to send us messages without paying (can be used by both monoforums and users). + /// If set, requires the user to pay in order to send us messages.
Can only be set by monoforums, not users, i.e. parent_peer must be set if this flag is set; users must instead use the privacy setting to remove a previously added exemption.
If not set, allows the user to send us messages without paying (can be unset by both monoforums and users). /// If set, applies the setting within the monoforum aka direct messages » (pass the ID of the monoforum, not the ID of the associated channel). /// The user to exempt or unexempt. public static Task Account_ToggleNoPaidMessagesException(this Client client, InputUserBase user_id, InputPeer parent_peer = null, bool refund_charged = false, bool require_payment = false) @@ -1457,7 +1457,7 @@ namespace TL user_id = user_id, }); - /// Returns basic user info according to their identifiers. See [bots: ✓] Possible codes: 400 (details) + /// Returns basic user info according to their identifiers. See [bots: ✓] Possible codes: -504,400 (details) /// List of user identifiers public static Task Users_GetUsers(this Client client, params InputUserBase[] id) => client.Invoke(new Users_GetUsers @@ -1465,7 +1465,7 @@ namespace TL id = id, }); - /// Returns extended user info by ID. See [bots: ✓] Possible codes: 400 (details) + /// Returns extended user info by ID. See [bots: ✓] Possible codes: -504,400 (details) /// User ID public static Task Users_GetFullUser(this Client client, InputUserBase id) => client.Invoke(new Users_GetFullUser @@ -1483,7 +1483,7 @@ namespace TL errors = errors, }); - /// Check whether we can write to the specified users, used to implement bulk checks for Premium-only messages » and paid messages ». See [bots: ✓] + /// Check whether we can write to the specified users, used to implement bulk checks for Premium-only messages » and paid messages ». See /// Users to check. public static Task Users_GetRequirementsToContact(this Client client, params InputUserBase[] id) => client.Invoke(new Users_GetRequirementsToContact @@ -1580,7 +1580,7 @@ namespace TL limit = limit, }); - /// Resolve a @username to get peer info See [bots: ✓] Possible codes: 400 (details) + /// Resolve a @username to get peer info See [bots: ✓] Possible codes: -504,400 (details) /// @username to resolve /// Referrer ID from referral links ». public static Task Contacts_ResolveUsername(this Client client, string username, string referer = null) @@ -1740,7 +1740,7 @@ namespace TL { }); - /// See [bots: ✓] + /// See Possible codes: 400 (details) /// a null value means contacts.sponsoredPeersEmpty public static Task Contacts_GetSponsoredPeers(this Client client, string q) => client.Invoke(new Contacts_GetSponsoredPeers @@ -1748,7 +1748,7 @@ namespace TL q = q, }); - /// This method is only for basic Chat. See Terminology in the README to understand what this means
Search for a similar method name starting with Channels_ if you're dealing with a
Returns the list of messages by their IDs. See [bots: ✓]
+ /// This method is only for basic Chat. See Terminology in the README to understand what this means
Search for a similar method name starting with Channels_ if you're dealing with a
Returns the list of messages by their IDs. See
[bots: ✓] Possible codes: -504 (details)
/// Message ID list public static Task Messages_GetMessages(this Client client, params InputMessage[] id) => client.Invoke(new Messages_GetMessages @@ -1756,7 +1756,7 @@ namespace TL id = id, }); - /// Returns the current user dialog list. See Possible codes: 400,403 (details) + /// Returns the current user dialog list. See Possible codes: -504,400,403 (details) /// Exclude pinned dialogs /// Peer folder ID, for more info click here /// Offsets for pagination, for more info click here @@ -1776,7 +1776,7 @@ namespace TL hash = hash, }); - /// Returns the conversation history with one interlocutor / within a chat See Possible codes: 400,406 (details) + /// Returns the conversation history with one interlocutor / within a chat See Possible codes: -504,400,406 (details) /// Target peer /// Only return messages starting from the specified message ID /// Only return messages sent before the specified date @@ -1880,7 +1880,7 @@ namespace TL max_id = max_id, }); - /// Sends a current user typing event (see for all event types) to a conversation partner or group. See [bots: ✓] Possible codes: 400,403,406 (details) + /// Sends a current user typing event (see for all event types) to a conversation partner or group. See [bots: ✓] Possible codes: -504,400,403,406 (details) /// Target user or group /// Topic ID /// Type of action @@ -1893,7 +1893,7 @@ namespace TL action = action, }); - /// Sends a message to a chat See [bots: ✓] Possible codes: 400,403,404,406,420,500 (details) + /// Sends a message to a chat See [bots: ✓] Possible codes: -504,400,403,404,406,420,500 (details) /// Set this flag to disable generation of the webpage preview /// Send this message silently (no notifications for the receivers) /// Send this message as background message @@ -1931,7 +1931,7 @@ namespace TL suggested_post = suggested_post, }); - /// Send a media See [bots: ✓] Possible codes: 400,403,406,420,500 (details) + /// Send a media See [bots: ✓] Possible codes: -504,400,403,406,420,500 (details) /// Send message silently (no notification should be triggered) /// Send message in background /// Clear the draft @@ -2095,7 +2095,7 @@ namespace TL user_id = user_id, }); - /// Creates a new chat. See Possible codes: 400,406,500 (details) + /// Creates a new chat. See Possible codes: 400,403,500 (details) /// List of user IDs to be invited /// Chat name /// Time-to-live of all messages that will be sent in the chat: once message.date+message.ttl_period === time(), the message will be deleted on the server, and must be deleted locally as well. You can use Messages_SetDefaultHistoryTTL to edit this value later. @@ -2118,7 +2118,7 @@ namespace TL random_length = random_length, }); - /// Sends a request to start a secret chat to the user. See Possible codes: 400 (details) + /// Sends a request to start a secret chat to the user. See Possible codes: 400,403 (details) /// User ID /// Unique client request ID required to prevent resending. This also doubles as the chat ID. /// A = g ^ a mod p, see Wikipedia @@ -2288,7 +2288,7 @@ namespace TL subscription_pricing = subscription_pricing, }); - /// Check the validity of a chat invite link and get basic info about it See Possible codes: 400,406 (details) + /// Check the validity of a chat invite link and get basic info about it See Possible codes: -504,400,406 (details) /// Invite hash from chat invite deep link ». public static Task Messages_CheckChatInvite(this Client client, string hash) => client.Invoke(new Messages_CheckChatInvite @@ -2347,7 +2347,7 @@ namespace TL start_param = start_param, }); - /// Get and increase the view counter of a message sent or forwarded from a channel See Possible codes: 400,406 (details) + /// Get and increase the view counter of a message sent or forwarded from a channel See Possible codes: -504,400,406 (details) /// Peer where the message was found /// ID of message /// Whether to mark the message as viewed and increment the view counter @@ -2602,7 +2602,7 @@ namespace TL cache_time = cache_time, }); - /// Get dialog info of specified peers See Possible codes: 400,406 (details) + /// Get dialog info of specified peers See Possible codes: -504,400,406 (details) /// Peers public static Task Messages_GetPeerDialogs(this Client client, params InputDialogPeerBase[] peers) => client.Invoke(new Messages_GetPeerDialogs @@ -2846,7 +2846,7 @@ namespace TL error = error, }); - /// Upload a file and associate it to a chat (without actually sending it to the chat) See [bots: ✓] Possible codes: 400,403 (details) + /// Upload a file and associate it to a chat (without actually sending it to the chat) See [bots: ✓] Possible codes: -504,400,403 (details) /// Whether the media will be used only in the specified business connection », and not directly by the bot. /// The chat, can be for bots and for users. /// File uploaded in chunks as described in files » @@ -2891,7 +2891,7 @@ namespace TL unfave = unfave, }); - /// Get unread messages where we were mentioned See Possible codes: 400 (details) + /// Get unread messages where we were mentioned See Possible codes: -504,400 (details) /// Peer where to look for mentions /// If set, considers only messages within the specified forum topic /// Offsets for pagination, for more info click here @@ -2912,7 +2912,7 @@ namespace TL min_id = min_id, }); - /// Mark mentions as read See Possible codes: 400 (details) + /// Mark mentions as read See Possible codes: -504,400 (details) /// Dialog /// Mark as read only mentions within the specified forum topic public static Task Messages_ReadMentions(this Client client, InputPeer peer, int? top_msg_id = null) @@ -3692,7 +3692,7 @@ namespace TL reaction = reaction, }); - /// Translate a given text. See Possible codes: 400,500 (details) + /// Translate a given text. See Possible codes: 400,406,500 (details) /// If the text is a chat message, the peer ID /// A list of message IDs to translate /// A list of styled messages to translate @@ -4192,7 +4192,7 @@ namespace TL order = order, }); - /// Fetch the full list of saved message tags created by the user. See + /// Fetch the full list of saved message tags created by the user. See Possible codes: 400 (details) /// If set, returns tags only used in the specified saved message dialog. /// Hash used for caching, for more info click here. /// a null value means messages.savedReactionTagsNotModified @@ -4436,7 +4436,7 @@ namespace TL { }); - /// Mark a specific sponsored message » as read See + /// Mark a specific sponsored message » as read See Possible codes: -504 (details) /// The ad's unique ID. public static Task Messages_ViewSponsoredMessage(this Client client, byte[] random_id) => client.Invoke(new Messages_ViewSponsoredMessage @@ -4465,7 +4465,7 @@ namespace TL option = option, }); - /// Get a list of sponsored messages for a peer, see here » for more info. See + /// Get a list of sponsored messages for a peer, see here » for more info. See Possible codes: 400 (details) /// The currently open channel/bot. /// a null value means messages.sponsoredMessagesEmpty public static Task Messages_GetSponsoredMessages(this Client client, InputPeer peer, int? msg_id = null) @@ -4529,7 +4529,7 @@ namespace TL id = id, }); - /// See [bots: ✓] + /// See public static Task Messages_GetSavedDialogsByID(this Client client, InputPeer[] ids, InputPeer parent_peer = null) => client.Invoke(new Messages_GetSavedDialogsByID { @@ -4538,7 +4538,7 @@ namespace TL ids = ids, }); - /// See [bots: ✓] + /// See Possible codes: 400 (details) public static Task Messages_ReadSavedHistory(this Client client, InputPeer parent_peer, InputPeer peer, int max_id = default) => client.Invoke(new Messages_ReadSavedHistory { @@ -4547,7 +4547,7 @@ namespace TL max_id = max_id, }); - /// See [bots: ✓] + /// See Possible codes: 400 (details) public static Task Messages_ToggleTodoCompleted(this Client client, InputPeer peer, int msg_id, int[] completed, params int[] incompleted) => client.Invoke(new Messages_ToggleTodoCompleted { @@ -4557,7 +4557,7 @@ namespace TL incompleted = incompleted, }); - /// See [bots: ✓] + /// See Possible codes: 400 (details) public static Task Messages_AppendTodoList(this Client client, InputPeer peer, int msg_id, params TodoItem[] list) => client.Invoke(new Messages_AppendTodoList { @@ -4566,7 +4566,7 @@ namespace TL list = list, }); - /// See [bots: ✓] + /// See Possible codes: 400 (details) public static Task Messages_ToggleSuggestedPostApproval(this Client client, InputPeer peer, int msg_id, DateTime? schedule_date = null, string reject_comment = null, bool reject = false) => client.Invoke(new Messages_ToggleSuggestedPostApproval { @@ -4577,13 +4577,13 @@ namespace TL reject_comment = reject_comment, }); - /// Returns a current state of updates. See [bots: ✓] + /// Returns a current state of updates. See [bots: ✓] Possible codes: -504 (details) public static Task Updates_GetState(this Client client) => client.Invoke(new Updates_GetState { }); - /// Get new updates. See [bots: ✓] Possible codes: 400,403,500 (details) + /// Get new updates. See [bots: ✓] Possible codes: -504,400,403,500 (details) /// PTS, see updates. /// PTS limit /// For fast updating: if provided and pts + pts_total_limit < remote pts, will be returned.
Simply tells the server to not return the difference if it is bigger than pts_total_limit
If the remote pts is too big (> ~4000000), this field will default to 1000000 @@ -4602,7 +4602,7 @@ namespace TL qts_limit = qts_limit ?? default, }); - /// Returns the difference between the current state of updates of a certain channel and transmitted. See [bots: ✓] Possible codes: 400,403,406,500 (details) + /// Returns the difference between the current state of updates of a certain channel and transmitted. See [bots: ✓] Possible codes: -504,400,403,406,500 (details) /// Set to true to skip some possibly unneeded updates and reduce server-side load /// The channel /// Messsage filter @@ -4742,7 +4742,7 @@ namespace TL limit = limit, }); - /// Download a CDN file. See Possible codes: 400 (details) + /// Download a CDN file. See Possible codes: 400,404 (details) /// File token /// Offset of chunk to download /// Length of chunk to download @@ -4764,7 +4764,7 @@ namespace TL request_token = request_token, }); - /// Get SHA256 hashes for verifying downloaded CDN files See [bots: ✓] Possible codes: 400 (details) + /// Get SHA256 hashes for verifying downloaded CDN files See [bots: ✓] Possible codes: -504,400 (details) /// File /// Offset from which to start getting hashes public static Task Upload_GetCdnFileHashes(this Client client, byte[] file_token, long offset = default) @@ -4784,7 +4784,7 @@ namespace TL offset = offset, }); - /// Returns current configuration, including data center configuration. See [bots: ✓] Possible codes: 400,403 (details) + /// Returns current configuration, including data center configuration. See [bots: ✓] Possible codes: -504,400,403 (details) public static Task Help_GetConfig(this Client client) => client.Invoke(new Help_GetConfig { @@ -4827,7 +4827,7 @@ namespace TL message = message, }); - /// Get configuration for CDN file downloads. See [bots: ✓] + /// Get configuration for CDN file downloads. See [bots: ✓] Possible codes: -504 (details) public static Task Help_GetCdnConfig(this Client client) => client.Invoke(new Help_GetCdnConfig { @@ -4986,7 +4986,7 @@ namespace TL hash = hash, }); - /// Mark channel/supergroup history as read See Possible codes: 400,406 (details) + /// Mark channel/supergroup history as read See Possible codes: -504,400,406 (details) /// Channel/supergroup /// ID of message up to which messages should be marked as read public static Task Channels_ReadHistory(this Client client, InputChannelBase channel, int max_id = default) @@ -4996,7 +4996,7 @@ namespace TL max_id = max_id, }); - /// Delete messages in a channel/supergroup See [bots: ✓] Possible codes: 400,403,406 (details) + /// Delete messages in a channel/supergroup See [bots: ✓] Possible codes: 400,403,406,420 (details) /// Channel/supergroup /// IDs of messages to delete public static Task Channels_DeleteMessages(this Client client, InputChannelBase channel, params int[] id) @@ -5018,7 +5018,7 @@ namespace TL id = id, }); - /// Get channel/supergroup messages See [bots: ✓] Possible codes: 400,406 (details) + /// Get channel/supergroup messages See [bots: ✓] Possible codes: -504,400,406 (details) /// Channel/supergroup /// IDs of messages to get public static Task Channels_GetMessages(this Client client, InputChannelBase channel, params InputMessage[] id) @@ -5028,7 +5028,7 @@ namespace TL id = id, }); - /// Get the participants of a supergroup/channel See [bots: ✓] Possible codes: 400,403,406 (details) + /// Get the participants of a supergroup/channel See [bots: ✓] Possible codes: -504,400,403,406 (details) /// Channel /// Which participant types to fetch /// Offset @@ -5055,7 +5055,7 @@ namespace TL participant = participant, }); - /// Get info about channels/supergroups See [bots: ✓] Possible codes: 400,406 (details) + /// Get info about channels/supergroups See [bots: ✓] Possible codes: -504,400,406 (details) /// IDs of channels/supergroups to get info about public static Task Channels_GetChannels(this Client client, params InputChannelBase[] id) => client.Invoke(new Channels_GetChannels @@ -5063,7 +5063,7 @@ namespace TL id = id, }); - /// Get full info about a supergroup, gigagroup or channel See [bots: ✓] Possible codes: 400,403,406 (details) + /// Get full info about a supergroup, gigagroup or channel See [bots: ✓] Possible codes: -504,400,403,406 (details) /// The channel, supergroup or gigagroup to get info about public static Task Channels_GetFullChannel(this Client client, InputChannelBase channel) => client.Invoke(new Channels_GetFullChannel @@ -5071,7 +5071,7 @@ namespace TL channel = channel, }); - /// Create a supergroup/channel. See Possible codes: 400,406,500 (details) + /// Create a supergroup/channel. See Possible codes: 400,403,500 (details) /// Whether to create a channel /// Whether to create a supergroup /// Whether the supergroup is being created to import messages from a foreign chat service using Messages_InitHistoryImport @@ -5146,7 +5146,7 @@ namespace TL username = username, }); - /// Join a channel/supergroup See Possible codes: 400,406 (details) + /// Join a channel/supergroup See Possible codes: -504,400,406,420 (details) /// Channel/supergroup to join public static Task Channels_JoinChannel(this Client client, InputChannelBase channel) => client.Invoke(new Channels_JoinChannel @@ -5289,7 +5289,7 @@ namespace TL enabled = enabled, }); - /// Get a list of channels/supergroups we left, requires a takeout session, see here » for more info. See Possible codes: 403 (details) + /// Get a list of channels/supergroups we left, requires a takeout session, see here » for more info. See Possible codes: 400,403 (details) /// Offset for pagination public static Task Channels_GetLeftChannels(this Client client, int offset = default) => client.Invoke(new Channels_GetLeftChannels @@ -5520,7 +5520,7 @@ namespace TL pinned = pinned, }); - /// Delete message history of a forum topic See [bots: ✓] Possible codes: 400 (details) + /// Delete message history of a forum topic See [bots: ✓] Possible codes: 400,403 (details) /// Forum /// Topic ID public static Task Channels_DeleteTopicHistory(this Client client, InputChannelBase channel, int top_msg_id) @@ -5596,7 +5596,7 @@ namespace TL enabled = enabled, }); - /// Obtain a list of similarly themed public channels, selected based on similarities in their subscriber bases. See Possible codes: 400 (details) + /// Obtain a list of similarly themed public channels, selected based on similarities in their subscriber bases. See Possible codes: -504,400 (details) /// The method will return channels related to the passed channel. If not set, the method will returns channels related to channels the user has joined. public static Task Channels_GetChannelRecommendations(this Client client, InputChannelBase channel = null) => client.Invoke(new Channels_GetChannelRecommendations @@ -5645,7 +5645,7 @@ namespace TL restricted = restricted, }); - /// Globally search for posts from public channels » (including those we aren't a member of) containing a specific hashtag. See + /// Globally search for posts from public channels » (including those we aren't a member of) containing a specific hashtag. See Possible codes: 420 (details) /// The hashtag to search, without the # character. /// Initially 0, then set to the next_rate parameter of messages.messagesSlice /// Offsets for pagination, for more info click here @@ -5664,7 +5664,7 @@ namespace TL allow_paid_stars = allow_paid_stars ?? default, }); - /// Enable or disable paid messages » in this supergroup or monoforum. See [bots: ✓] + /// Enable or disable paid messages » in this supergroup or monoforum. See Possible codes: 400 (details) /// Only usable for channels, enables or disables the associated monoforum aka direct messages. /// Pass the supergroup ID for supergroups and the ID of the channel to modify the setting in the associated monoforum. /// Specifies the required amount of Telegram Stars users must pay to send messages to the supergroup or monoforum. @@ -5676,7 +5676,7 @@ namespace TL send_paid_messages_stars = send_paid_messages_stars, }); - /// See [bots: ✓] + /// See Possible codes: 400 (details) public static Task Channels_ToggleAutotranslation(this Client client, InputChannelBase channel, bool enabled) => client.Invoke(new Channels_ToggleAutotranslation { @@ -5684,7 +5684,7 @@ namespace TL enabled = enabled, }); - /// See [bots: ✓] + /// See Possible codes: 400 (details) public static Task Channels_GetMessageAuthor(this Client client, InputChannelBase channel, int id) => client.Invoke(new Channels_GetMessageAuthor { @@ -6016,7 +6016,7 @@ namespace TL bot = bot, }); - /// Get a payment form See Possible codes: 400 (details) + /// Get a payment form See Possible codes: 400,403,406 (details) /// Invoice /// Theme parameters » public static Task Payments_GetPaymentForm(this Client client, InputInvoice invoice, DataJSON theme_params = null) @@ -6172,7 +6172,7 @@ namespace TL { }); - /// Get the current Telegram Stars balance of the current account (with peer=), or the stars balance of the bot specified in peer. See Possible codes: 400 (details) + /// Get the current Telegram Stars balance of the current account (with peer=), or the stars balance of the bot specified in peer. See Possible codes: 400,403 (details) /// Peer of which to get the balance. public static Task Payments_GetStarsStatus(this Client client, InputPeer peer, bool ton = false) => client.Invoke(new Payments_GetStarsStatus @@ -6199,7 +6199,7 @@ namespace TL limit = limit, }); - /// Make a payment using Telegram Stars, see here » for more info. See Possible codes: 400 (details) + /// Make a payment using Telegram Stars, see here » for more info. See Possible codes: 400,403,406 (details) /// Payment form ID /// Invoice public static Task Payments_SendStarsForm(this Client client, long form_id, InputInvoice invoice) @@ -6409,7 +6409,8 @@ namespace TL link = link, }); - /// See + /// Obtain a preview of the possible attributes (chosen randomly) a gift » can receive after upgrading it to a collectible gift », see here » for more info. See Possible codes: 400 (details) + /// The gift to upgrade. public static Task Payments_GetStarGiftUpgradePreview(this Client client, long gift_id) => client.Invoke(new Payments_GetStarGiftUpgradePreview { @@ -6432,14 +6433,14 @@ namespace TL to_id = to_id, }); - /// See [bots: ✓] + /// See Possible codes: 400 (details) public static Task Payments_GetUniqueStarGift(this Client client, string slug) => client.Invoke(new Payments_GetUniqueStarGift { slug = slug, }); - /// See [bots: ✓] + /// See Possible codes: 400 (details) /// Maximum number of results to return, see pagination public static Task Payments_GetSavedStarGifts(this Client client, InputPeer peer, string offset, int limit = int.MaxValue, int? collection_id = null, bool exclude_unsaved = false, bool exclude_saved = false, bool exclude_unlimited = false, bool exclude_limited = false, bool exclude_unique = false, bool sort_by_value = false) => client.Invoke(new Payments_GetSavedStarGifts @@ -6451,14 +6452,14 @@ namespace TL limit = limit, }); - /// See [bots: ✓] + /// See Possible codes: 400 (details) public static Task Payments_GetSavedStarGift(this Client client, params InputSavedStarGift[] stargift) => client.Invoke(new Payments_GetSavedStarGift { stargift = stargift, }); - /// See [bots: ✓] + /// See Possible codes: 400 (details) public static Task Payments_GetStarGiftWithdrawalUrl(this Client client, InputSavedStarGift stargift, InputCheckPasswordSRP password) => client.Invoke(new Payments_GetStarGiftWithdrawalUrl { @@ -6466,7 +6467,7 @@ namespace TL password = password, }); - /// See [bots: ✓] + /// See Possible codes: 400 (details) public static Task Payments_ToggleChatStarGiftNotifications(this Client client, InputPeer peer, bool enabled = false) => client.Invoke(new Payments_ToggleChatStarGiftNotifications { @@ -6474,7 +6475,7 @@ namespace TL peer = peer, }); - /// See [bots: ✓] + /// See Possible codes: 400 (details) public static Task Payments_ToggleStarGiftsPinnedToTop(this Client client, InputPeer peer, params InputSavedStarGift[] stargift) => client.Invoke(new Payments_ToggleStarGiftsPinnedToTop { @@ -6482,14 +6483,14 @@ namespace TL stargift = stargift, }); - /// See [bots: ✓] + /// See Possible codes: 406 (details) public static Task Payments_CanPurchaseStore(this Client client, InputStorePaymentPurpose purpose) => client.Invoke(new Payments_CanPurchaseStore { purpose = purpose, }); - /// See [bots: ✓] + /// See Possible codes: -504,400 (details) /// Maximum number of results to return, see pagination public static Task Payments_GetResaleStarGifts(this Client client, long gift_id, string offset, int limit = int.MaxValue, long? attributes_hash = null, StarGiftAttributeId[] attributes = null, bool sort_by_price = false, bool sort_by_num = false) => client.Invoke(new Payments_GetResaleStarGifts @@ -6502,7 +6503,7 @@ namespace TL limit = limit, }); - /// See [bots: ✓] + /// See Possible codes: 400 (details) public static Task Payments_UpdateStarGiftPrice(this Client client, InputSavedStarGift stargift, StarsAmountBase resell_amount) => client.Invoke(new Payments_UpdateStarGiftPrice { @@ -6510,7 +6511,7 @@ namespace TL resell_amount = resell_amount, }); - /// See + /// See Possible codes: 400 (details) public static Task Payments_CreateStarGiftCollection(this Client client, InputPeer peer, string title, params InputSavedStarGift[] stargift) => client.Invoke(new Payments_CreateStarGiftCollection { @@ -6519,7 +6520,7 @@ namespace TL stargift = stargift, }); - /// See + /// See Possible codes: 400 (details) public static Task Payments_UpdateStarGiftCollection(this Client client, InputPeer peer, int collection_id, string title = null, InputSavedStarGift[] delete_stargift = null, InputSavedStarGift[] add_stargift = null, InputSavedStarGift[] order = null) => client.Invoke(new Payments_UpdateStarGiftCollection { @@ -6532,7 +6533,7 @@ namespace TL order = order, }); - /// See + /// See Possible codes: 400 (details) public static Task Payments_ReorderStarGiftCollections(this Client client, InputPeer peer, params int[] order) => client.Invoke(new Payments_ReorderStarGiftCollections { @@ -6540,7 +6541,7 @@ namespace TL order = order, }); - /// See + /// See Possible codes: 400 (details) public static Task Payments_DeleteStarGiftCollection(this Client client, InputPeer peer, int collection_id) => client.Invoke(new Payments_DeleteStarGiftCollection { @@ -6548,7 +6549,7 @@ namespace TL collection_id = collection_id, }); - /// See + /// See Possible codes: 400 (details) /// a null value means payments.starGiftCollectionsNotModified public static Task Payments_GetStarGiftCollections(this Client client, InputPeer peer, long hash = default) => client.Invoke(new Payments_GetStarGiftCollections @@ -6693,7 +6694,7 @@ namespace TL { }); - /// Start a telegram phone call See Possible codes: 400,403 (details) + /// Start a telegram phone call See Possible codes: 400,403,500 (details) /// Whether to start a video call /// Destination of the phone call /// Random ID to avoid resending the same object @@ -7044,7 +7045,7 @@ namespace TL file = file, }); - /// Create and optionally join a new conference call. See [bots: ✓] + /// Create and optionally join a new conference call. See /// If set, mute our microphone when joining the call (can only be used if join is set). /// If set, our video stream is disabled (can only be used if join is set). /// If set, also join the call, otherwise just create the call link. @@ -7062,7 +7063,7 @@ namespace TL params_ = params_, }); - /// See [bots: ✓] + /// See Possible codes: 400 (details) public static Task Phone_DeleteConferenceCallParticipants(this Client client, InputGroupCallBase call, long[] ids, byte[] block, bool only_left = false, bool kick = false) => client.Invoke(new Phone_DeleteConferenceCallParticipants { @@ -7072,7 +7073,7 @@ namespace TL block = block, }); - /// See [bots: ✓] + /// See Possible codes: 400 (details) public static Task Phone_SendConferenceCallBroadcast(this Client client, InputGroupCallBase call, byte[] block) => client.Invoke(new Phone_SendConferenceCallBroadcast { @@ -7080,7 +7081,7 @@ namespace TL block = block, }); - /// See [bots: ✓] + /// See Possible codes: 400 (details) public static Task Phone_InviteConferenceCallParticipant(this Client client, InputGroupCallBase call, InputUserBase user_id, bool video = false) => client.Invoke(new Phone_InviteConferenceCallParticipant { @@ -7089,14 +7090,14 @@ namespace TL user_id = user_id, }); - /// See [bots: ✓] + /// See Possible codes: 400 (details) public static Task Phone_DeclineConferenceCallInvite(this Client client, int msg_id) => client.Invoke(new Phone_DeclineConferenceCallInvite { msg_id = msg_id, }); - /// See [bots: ✓] + /// See Possible codes: 400 (details) /// Maximum number of results to return, see pagination public static Task Phone_GetGroupCallChainBlocks(this Client client, InputGroupCallBase call, int sub_chain_id, int offset = default, int limit = int.MaxValue) => client.Invoke(new Phone_GetGroupCallChainBlocks @@ -7417,7 +7418,7 @@ namespace TL privacy_rules = privacy_rules, }); - /// Deletes some posted stories. See Possible codes: 400 (details) + /// Deletes some posted stories. See Possible codes: 400,403 (details) /// Channel/user from where to delete stories. /// IDs of stories to delete. public static Task Stories_DeleteStories(this Client client, InputPeer peer, params int[] id) @@ -7532,7 +7533,7 @@ namespace TL limit = limit, }); - /// Obtain info about the view count, forward count, reactions and recent viewers of one or more stories. See Possible codes: 400 (details) + /// Obtain info about the view count, forward count, reactions and recent viewers of one or more stories. See Possible codes: -504,400 (details) /// Peer whose stories should be fetched /// Story IDs public static Task Stories_GetStoriesViews(this Client client, InputPeer peer, params int[] id) @@ -7672,7 +7673,7 @@ namespace TL limit = limit, }); - /// See + /// See Possible codes: 400 (details) public static Task Stories_CreateAlbum(this Client client, InputPeer peer, string title, params int[] stories) => client.Invoke(new Stories_CreateAlbum { @@ -7681,7 +7682,7 @@ namespace TL stories = stories, }); - /// See + /// See Possible codes: 400 (details) public static Task Stories_UpdateAlbum(this Client client, InputPeer peer, int album_id, string title = null, int[] delete_stories = null, int[] add_stories = null, int[] order = null) => client.Invoke(new Stories_UpdateAlbum { @@ -7694,7 +7695,7 @@ namespace TL order = order, }); - /// See + /// See Possible codes: 400 (details) public static Task Stories_ReorderAlbums(this Client client, InputPeer peer, params int[] order) => client.Invoke(new Stories_ReorderAlbums { @@ -7702,7 +7703,7 @@ namespace TL order = order, }); - /// See + /// See Possible codes: 400 (details) public static Task Stories_DeleteAlbum(this Client client, InputPeer peer, int album_id) => client.Invoke(new Stories_DeleteAlbum { @@ -7710,7 +7711,7 @@ namespace TL album_id = album_id, }); - /// See + /// See Possible codes: 400 (details) /// a null value means stories.albumsNotModified public static Task Stories_GetAlbums(this Client client, InputPeer peer, long hash = default) => client.Invoke(new Stories_GetAlbums @@ -7719,7 +7720,8 @@ namespace TL hash = hash, }); - /// See + /// See Possible codes: 400 (details) + /// Maximum number of results to return, see pagination public static Task Stories_GetAlbumStories(this Client client, InputPeer peer, int album_id, int offset = default, int limit = int.MaxValue) => client.Invoke(new Stories_GetAlbumStories { @@ -7760,7 +7762,7 @@ namespace TL peer = peer, }); - /// Gets the current number of boosts of a channel/supergroup. See Possible codes: 400 (details) + /// Gets the current number of boosts of a channel/supergroup. See Possible codes: -504,400 (details) /// The peer. public static Task Premium_GetBoostsStatus(this Client client, InputPeer peer) => client.Invoke(new Premium_GetBoostsStatus diff --git a/src/TL.Table.cs b/src/TL.Table.cs index 3479f87..3be9440 100644 --- a/src/TL.Table.cs +++ b/src/TL.Table.cs @@ -6,7 +6,7 @@ namespace TL { public static partial class Layer { - public const int Version = 211; // fetched 31/07/2025 22:39:04 + public const int Version = 211; // fetched 16/08/2025 00:21:53 internal const int SecretChats = 144; internal const int MTProto2 = 73; internal const uint VectorCtor = 0x1CB5C415;