diff --git a/src/TL.Schema.cs b/src/TL.Schema.cs index bff0d83..7f0540b 100644 --- a/src/TL.Schema.cs +++ b/src/TL.Schema.cs @@ -837,6 +837,7 @@ namespace TL has_video = 0x1, /// Field has a value has_stripped_thumb = 0x2, + /// Whether this profile photo is only visible to us (i.e. it was set using Photos_UploadContactProfilePhoto). personal = 0x4, } } @@ -1184,7 +1185,7 @@ namespace TL has_requests_pending = 0x20000, /// Field has a value has_available_reactions = 0x40000, - /// Whether real-time chat translation is disabled. + /// Whether the real-time chat translation popup should be hidden. translations_disabled = 0x80000, } @@ -1372,7 +1373,7 @@ namespace TL antispam = 0x2, /// Whether the participant list is hidden. participants_hidden = 0x4, - /// Whether real-time chat translation is disabled. + /// Whether the real-time chat translation popup should be hidden. translations_disabled = 0x8, } @@ -2079,14 +2080,16 @@ namespace TL { /// Flags, see TL conditional fields public Flags flags; - /// The domain name of the website on which the user has logged in. More about Telegram Login » + /// The user has logged in via Telegram Login »; this field contains the domain name of the website on which the user has logged in. [IfFlag(0)] public string domain; + /// We just gave the specified bot web app permission to send us messages. [IfFlag(2)] public BotApp app; [Flags] public enum Flags : uint { /// Field has a value has_domain = 0x1, + /// We just installed the bot's attachment menu, thus giving the bot permission to send us messages. attach_menu = 0x2, /// Field has a value has_app = 0x4, @@ -2911,6 +2914,7 @@ namespace TL has_personal_photo = 0x200000, /// Field has a value has_fallback_photo = 0x400000, + /// Whether the real-time chat translation popup should be hidden. translations_disabled = 0x800000, } } @@ -4509,10 +4513,11 @@ namespace TL /// Media autosave settings have changed and must be refetched using Account_GetAutoSaveSettings. See [TLDef(0xEC05B097)] public class UpdateAutoSaveSettings : Update { } - /// See + /// 0-N updates of this type may be returned only when invoking Messages_AddChatUser, Channels_InviteToChannel or Messages_CreateChat: it indicates we couldn't add a user to a chat because of their privacy settings; if required, an invite link can be shared with the user, instead. See [TLDef(0xCCF08AD6)] public class UpdateGroupInvitePrivacyForbidden : Update { + /// ID of the user we couldn't add. public long user_id; } @@ -6742,6 +6747,7 @@ namespace TL selective = 0x4, /// Field has a value has_placeholder = 0x8, + /// Requests clients to always show the keyboard when the regular keyboard is hidden. persistent = 0x10, } } @@ -7799,8 +7805,9 @@ namespace TL public long query_id; /// The next offset to use when navigating through results [IfFlag(1)] public string next_offset; - /// Whether the bot requested the user to message them in private + /// Shown as a button on top of the remaining inline result list; if clicked, redirects the user to a private chat with the bot with the specified start parameter. [IfFlag(2)] public InlineBotSwitchPM switch_pm; + /// Shown as a button on top of the remaining inline result list; if clicked, opens the specified bot web app. [IfFlag(3)] public InlineBotWebView switch_webview; /// The results public BotInlineResultBase[] results; @@ -10314,7 +10321,7 @@ namespace TL invites = 0x8000, /// A message was posted in a channel send = 0x10000, - /// Forum-related events + /// Forum-related events forums = 0x20000, } } @@ -13260,7 +13267,9 @@ namespace TL public string message; /// Message entities for styled text [IfFlag(1)] public MessageEntity[] entities; + /// If set, contains additional information about the sponsor to be shown along with the message. [IfFlag(7)] public string sponsor_info; + /// If set, contains additional information about the sponsored message to be shown along with the message. [IfFlag(8)] public string additional_info; [Flags] public enum Flags : uint @@ -13292,6 +13301,7 @@ namespace TL { /// Flags, see TL conditional fields public Flags flags; + /// If set, specifies the minimum number of messages between shown sponsored messages; otherwise, only one sponsored message must be shown after all ordinary messages. [IfFlag(0)] public int posts_between; /// Sponsored messages public SponsoredMessage[] messages; @@ -14067,6 +14077,7 @@ namespace TL { /// Flags, see TL conditional fields public Flags flags; + /// Identifier of the last in-store transaction for the currently used subscription. [IfFlag(3)] public string transaction; /// Duration of subscription in months public int months; @@ -14083,7 +14094,9 @@ namespace TL { /// Field has a value has_store_product = 0x1, + /// Whether this subscription option is currently in use. current = 0x2, + /// Whether this subscription option can be used to upgrade the existing Telegram Premium subscription. can_purchase_upgrade = 0x4, /// Field has a value has_transaction = 0x8, @@ -14242,17 +14255,22 @@ namespace TL { /// Flags, see TL conditional fields public Flags flags; + /// Total number of topics matching query; may be less than the topics contained in topics, in which case pagination is required. public int count; /// Forum topics public ForumTopicBase[] topics; + /// Related messages (contains the messages mentioned by .top_message). public MessageBase[] messages; + /// Related chats public Dictionary chats; + /// Related users public Dictionary users; /// Event count after generation public int pts; [Flags] public enum Flags : uint { + /// Whether the returned topics are ordered by creation date; if set, pagination by next_offset should use .date; otherwise topics are ordered by the last message date, so paginate by the date of the referenced by .top_message. order_by_create_date = 0x1, } /// returns a or for the given Peer @@ -14399,12 +14417,13 @@ namespace TL public MessageEntity[] entities; } - /// Translated text, or no result See Derived classes: + /// Translated text with entities. See Derived classes: public abstract class Messages_TranslatedText : IObject { } - /// See + /// Translated text with entities See [TLDef(0x33DB32F8)] public class Messages_TranslateResult : Messages_TranslatedText { + /// Text+entities, for each input message. public TextWithEntities[] result; } @@ -14521,7 +14540,7 @@ namespace TL } } - /// Contains information about a bot web app See + /// Contains information about a bot web app See [TLDef(0xEB50ADF5)] public class Messages_BotApp : IObject { @@ -14549,11 +14568,13 @@ namespace TL public string url; } - /// See + /// Specifies a bot web app button, shown on top of the inline query results list. See [TLDef(0xB57295D5)] public class InlineBotWebView : IObject { + /// Text of the button public string text; + /// Webapp URL public string url; } diff --git a/src/TL.SchemaFuncs.cs b/src/TL.SchemaFuncs.cs index f7265f8..46b9669 100644 --- a/src/TL.SchemaFuncs.cs +++ b/src/TL.SchemaFuncs.cs @@ -2042,7 +2042,7 @@ namespace TL unsave = unsave, }); - /// Query an inline bot See Possible codes: 400,406,-503 (details) + /// Query an inline bot See Possible codes: -503,400,406 (details) /// The bot to query /// The currently opened chat /// The geolocation, if requested @@ -2066,7 +2066,8 @@ namespace TL /// Vector of results for the inline query /// The maximum amount of time in seconds that the result of the inline query may be cached on the server. Defaults to 300. /// Pass the offset that a client should send in the next query with the same text to receive more results. Pass an empty string if there are no more results or if you don't support pagination. Offset length can't exceed 64 bytes. - /// If passed, clients will display a button with specified text that switches the user to a private chat with the bot and sends the bot a start message with a certain parameter. + /// If passed, clients will display a button on top of the remaining inline result list with the specified text, that switches the user to a private chat with the bot and sends the bot a start message with a certain parameter. + /// If passed, clients will display a button on top of the remaining inline result list with the specified text, that switches the user to the specified bot web app. public static Task Messages_SetInlineBotResults(this Client client, long query_id, InputBotInlineResultBase[] results, int cache_time, string next_offset = null, InlineBotSwitchPM switch_pm = null, InlineBotWebView switch_webview = null, bool gallery = false, bool private_ = false) => client.Invoke(new Messages_SetInlineBotResults { @@ -2156,7 +2157,7 @@ namespace TL entities = entities, }); - /// Press an inline callback button and get a callback answer from the bot See Possible codes: 400,-503 (details) + /// Press an inline callback button and get a callback answer from the bot See Possible codes: -503,400 (details) /// Whether this is a "play game" button /// Where was the inline keyboard sent /// ID of the Message with the inline keyboard @@ -3255,10 +3256,10 @@ namespace TL reaction = reaction, }); - /// Translate a given text See Possible codes: 400 (details) + /// Translate a given text. See Possible codes: 400 (details) /// If the text is a chat message, the peer ID /// A list of message IDs to translate - /// The text to translate + /// A list of styled messages to translate /// Two-letter ISO 639-1 language code of the language to which the message is translated public static Task Messages_TranslateText(this Client client, string to_lang, InputPeer peer = null, int[] id = null, TextWithEntities[] text = null) => client.Invoke(new Messages_TranslateText @@ -3391,6 +3392,7 @@ namespace TL }); /// Open a bot web app. See + /// Whether the webapp was opened by clicking on the switch_webview button shown on top of the inline results list returned by Messages_GetInlineBotResults. /// Bot that owns the webapp /// Web app URL /// Theme parameters » @@ -3592,9 +3594,9 @@ namespace TL hash = hash, }); - /// Toggle real-time chat translation for a certain chat See [bots: ✓] - /// Whether to disable or enable real-time chat translation - /// Peer where to enable or disable real-time chat translation + /// Show or hide the real-time chat translation popup for a certain chat See [bots: ✓] + /// Whether to disable or enable the real-time chat translation popup + /// The peer public static Task Messages_TogglePeerTranslations(this Client client, InputPeer peer, bool disabled = false) => client.Invoke(new Messages_TogglePeerTranslations { @@ -4584,7 +4586,7 @@ namespace TL }); /// Enable or disable the native antispam system. See [bots: ✓] - /// Supergroup ID + /// Supergroup ID. The specified supergroup must have at least telegram_antispam_group_size_min members to enable antispam functionality, as specified by the client configuration parameters. /// Enable or disable the native antispam system. public static Task Channels_ToggleAntiSpam(this Client client, InputChannelBase channel, bool enabled) => client.Invoke(new Channels_ToggleAntiSpam