From 037333e597d9ab22e173695aca0e18baa3ad47d4 Mon Sep 17 00:00:00 2001 From: GitHub Date: Thu, 15 Aug 2024 07:45:19 +0000 Subject: [PATCH] feat(schema): update TDLib to the latest layer --- _schema/tdapi.tl | 236 +- tdapi/tl_add_message_reaction_gen.go | 3 +- tdapi/tl_add_paid_message_reaction_gen.go | 307 ++ tdapi/tl_bot_info_gen.go | 168 +- tdapi/tl_bot_transaction_purpose_gen.go | 569 +++ tdapi/tl_channel_transaction_purpose_gen.go | 751 +++ tdapi/tl_chat_event_action_gen.go | 181 + tdapi/tl_chat_invite_link_gen.go | 138 +- tdapi/tl_chat_invite_link_info_gen.go | 127 +- ..._chat_invite_link_subscription_info_gen.go | 263 ++ tdapi/tl_chat_member_status_gen.go | 64 +- ...reate_chat_subscription_invite_link_gen.go | 272 ++ ..._edit_chat_subscription_invite_link_gen.go | 271 ++ tdapi/tl_edit_star_subscription_gen.go | 237 + ...l_get_active_live_location_messages_gen.go | 169 - tdapi/tl_get_chat_invite_link_members_gen.go | 77 +- tdapi/tl_get_chat_story_interactions_gen.go | 3 +- tdapi/tl_get_message_added_reactions_gen.go | 8 +- tdapi/tl_get_star_subscriptions_gen.go | 239 + tdapi/tl_get_star_transactions_gen.go | 88 +- tdapi/tl_internal_link_type_gen.go | 216 + tdapi/tl_link_preview_type_gen.go | 80 +- tdapi/tl_message_gen.go | 274 +- tdapi/tl_message_properties_gen.go | 150 +- tdapi/tl_message_reactions_gen.go | 132 +- tdapi/tl_paid_reactor_gen.go | 341 ++ tdapi/tl_reaction_type_gen.go | 146 + tdapi/tl_registry_gen.go | 4082 +++++++++-------- tdapi/tl_remove_message_reaction_gen.go | 2 +- ...move_pending_paid_message_reactions_gen.go | 237 + tdapi/tl_reuse_star_subscription_gen.go | 206 + tdapi/tl_set_default_reaction_type_gen.go | 2 +- tdapi/tl_set_story_reaction_gen.go | 4 +- tdapi/tl_sponsored_message_gen.go | 3 +- tdapi/tl_star_subscription_gen.go | 434 ++ tdapi/tl_star_subscription_pricing_gen.go | 227 + tdapi/tl_star_subscriptions_gen.go | 323 ++ tdapi/tl_star_transaction_partner_gen.go | 488 +- tdapi/tl_suggested_action_gen.go | 146 + tdapi/tl_supergroup_full_info_gen.go | 202 +- tdapi/tl_supergroup_gen.go | 190 +- tdapi/tl_telegram_payment_purpose_gen.go | 186 +- ..._paid_message_reaction_is_anonymous_gen.go | 272 ++ .../tl_toggle_supergroup_sign_messages_gen.go | 64 +- tdapi/tl_update_gen.go | 209 + 45 files changed, 9784 insertions(+), 3003 deletions(-) create mode 100644 tdapi/tl_add_paid_message_reaction_gen.go create mode 100644 tdapi/tl_bot_transaction_purpose_gen.go create mode 100644 tdapi/tl_channel_transaction_purpose_gen.go create mode 100644 tdapi/tl_chat_invite_link_subscription_info_gen.go create mode 100644 tdapi/tl_create_chat_subscription_invite_link_gen.go create mode 100644 tdapi/tl_edit_chat_subscription_invite_link_gen.go create mode 100644 tdapi/tl_edit_star_subscription_gen.go delete mode 100644 tdapi/tl_get_active_live_location_messages_gen.go create mode 100644 tdapi/tl_get_star_subscriptions_gen.go create mode 100644 tdapi/tl_paid_reactor_gen.go create mode 100644 tdapi/tl_remove_pending_paid_message_reactions_gen.go create mode 100644 tdapi/tl_reuse_star_subscription_gen.go create mode 100644 tdapi/tl_star_subscription_gen.go create mode 100644 tdapi/tl_star_subscription_pricing_gen.go create mode 100644 tdapi/tl_star_subscriptions_gen.go create mode 100644 tdapi/tl_toggle_paid_message_reaction_is_anonymous_gen.go diff --git a/_schema/tdapi.tl b/_schema/tdapi.tl index 0d448c304b..0a6842b29f 100644 --- a/_schema/tdapi.tl +++ b/_schema/tdapi.tl @@ -1,7 +1,7 @@ // Code generated by ./cmd/dltl, DO NOT EDIT. // // Source: https://raw.githubusercontent.com/tdlib/td/master/td/generate/scheme/td_api.tl -// SHA256: d1e8d9ca578190c75e48ce1095887073e20b2968bb45530d25fa84521cc5d685 +// SHA256: ed98fc1c685881d72e357a361de2d2c7b40fa7f397c8d3036f21761de0fba1ce double#2210c154 ? = Double; @@ -810,6 +810,29 @@ chatPermissions#f8f25a79 can_send_basic_messages:Bool can_send_audios:Bool can_s //@is_anonymous True, if the administrator isn't shown in the chat member list and sends messages anonymously; applicable to supergroups only chatAdministratorRights#5f4f9044 can_manage_chat:Bool can_change_info:Bool can_post_messages:Bool can_edit_messages:Bool can_delete_messages:Bool can_invite_users:Bool can_restrict_members:Bool can_pin_messages:Bool can_manage_topics:Bool can_promote_members:Bool can_manage_video_chats:Bool can_post_stories:Bool can_edit_stories:Bool can_delete_stories:Bool is_anonymous:Bool = ChatAdministratorRights; +//@description Describes subscription plan paid in Telegram Stars +//@period The number of seconds between consecutive Telegram Star debiting +//@star_count The amount of Telegram Stars that must be paid for each period +starSubscriptionPricing#96a28856 period:int32 star_count:int53 = StarSubscriptionPricing; + +//@description Contains information about subscription to a channel chat paid in Telegram Stars +//@id Unique identifier of the subscription +//@chat_id Identifier of the channel chat that is subscribed +//@expiration_date Point in time (Unix timestamp) when the subscription will expire or expired +//@can_reuse True, if the subscription is active and the user can use the method reuseStarSubscription to join the subscribed chat again +//@is_canceled True, if the subscription was canceled +//@is_expiring True, if the subscription expires soon and there are no enough Telegram Stars on the user's balance to extend it +//@invite_link The invite link that can be used to renew the subscription if it has been expired; may be empty, if the link isn't available anymore +//@pricing The subscription plan +starSubscription#6caf0ade id:string chat_id:int53 expiration_date:int32 can_reuse:Bool is_canceled:Bool is_expiring:Bool invite_link:string pricing:starSubscriptionPricing = StarSubscription; + +//@description Represents a list of Telegram Star subscriptions +//@star_count The amount of owned Telegram Stars +//@subscriptions List of subbscriptions for Telegram Stars +//@required_star_count The number of Telegram Stars required to buy to extend subscriptions expiring soon +//@next_offset The offset for the next request. If empty, then there are no more results +starSubscriptions#f7a7ae44 star_count:int53 subscriptions:vector required_star_count:int53 next_offset:string = StarSubscriptions; + //@description Contains information about a product that can be paid with invoice //@title Product title //@param_description Product description @@ -875,6 +898,32 @@ starTransactionDirectionIncoming#b2cabe46 = StarTransactionDirection; //@description The transaction is outgoing and decreases the number of owned Telegram Stars starTransactionDirectionOutgoing#6e83b5a0 = StarTransactionDirection; +//@class BotTransactionPurpose @description Describes purpose of a transaction with a bot + +//@description Paid media were bought +//@media The bought media if the trancastion wasn't refunded +botTransactionPurposePaidMedia#9593b72f media:vector = BotTransactionPurpose; + +//@description User bought a product from the bot +//@product_info Information about the bought product; may be null if not applicable +//@invoice_payload Invoice payload; for bots only +botTransactionPurposeInvoicePayment#699860ac product_info:productInfo invoice_payload:bytes = BotTransactionPurpose; + +//@class ChannelTransactionPurpose @description Describes purpose of a transaction with a channel + +//@description Paid media were bought +//@message_id Identifier of the corresponding message with paid media; can be an identifier of a deleted message +//@media The bought media if the trancastion wasn't refunded +channelTransactionPurposePaidMedia#b00b2258 message_id:int53 media:vector = ChannelTransactionPurpose; + +//@description User joined the channel and subscribed to regular payments in Telegram Stars +//@period The number of seconds between consecutive Telegram Star debiting +channelTransactionPurposeJoin#ed83dd90 period:int32 = ChannelTransactionPurpose; + +//@description User paid for a reaction +//@message_id Identifier of the reacted message; can be an identifier of a deleted message +channelTransactionPurposeReaction#2ca05bee message_id:int53 = ChannelTransactionPurpose; + //@class StarTransactionPartner @description Describes source or recipient of a transaction with Telegram Stars //@description The transaction is a transaction with Telegram through a bot @@ -894,16 +943,19 @@ starTransactionPartnerFragment#da1849b5 withdrawal_state:RevenueWithdrawalState starTransactionPartnerTelegramAds#91f9c6b = StarTransactionPartner; //@description The transaction is a transaction with a bot -//@user_id Identifier of the bot for the user, or the user for the bot -//@product_info Information about the bought product; may be null if not applicable -//@invoice_payload Invoice payload; for bots only -starTransactionPartnerBot#298ce3d9 user_id:int53 product_info:productInfo invoice_payload:bytes = StarTransactionPartner; +//@user_id Identifier of the bot +//@purpose Purpose of the transaction +starTransactionPartnerBot#4ece3a40 user_id:int53 purpose:BotTransactionPurpose = StarTransactionPartner; + +//@description The transaction is a transaction with a business account +//@user_id Identifier of the business account user +//@media The bought media if the trancastion wasn't refunded +starTransactionPartnerBusiness#7af9fb52 user_id:int53 media:vector = StarTransactionPartner; //@description The transaction is a transaction with a channel chat //@chat_id Identifier of the chat -//@paid_media_message_id Identifier of the corresponding message with paid media; can be an identifier of a deleted message -//@media Information about the bought media -starTransactionPartnerChannel#44b29c29 chat_id:int53 paid_media_message_id:int53 media:vector = StarTransactionPartner; +//@purpose Purpose of the transaction +starTransactionPartnerChannel#7c04767e chat_id:int53 purpose:ChannelTransactionPurpose = StarTransactionPartner; //@description The transaction is a gift of Telegram Stars from another user //@user_id Identifier of the user; 0 if the gift was anonymous @@ -1039,6 +1091,7 @@ user#18552c62 id:int53 first_name:string last_name:string usernames:usernames ph //@animation Animation shown in the chat with the bot if the chat is empty; may be null //@menu_button Information about a button to show instead of the bot commands menu button; may be null if ordinary bot commands menu must be shown //@commands List of the bot commands +//@privacy_policy_url The HTTP link to the privacy policy of the bot. If empty, then /privacy command must be used if supported by the bot. If the command isn't supported, then https://telegram.org/privacy-tpa must be opened //@default_group_administrator_rights Default administrator rights for adding the bot to basic group and supergroup chats; may be null //@default_channel_administrator_rights Default administrator rights for adding the bot to channels; may be null //@has_media_previews True, if the bot has media previews @@ -1046,7 +1099,7 @@ user#18552c62 id:int53 first_name:string last_name:string usernames:usernames ph //@edit_description_link The internal link, which can be used to edit bot description; may be null //@edit_description_media_link The internal link, which can be used to edit the photo or animation shown in the chat with the bot if the chat is empty; may be null //@edit_settings_link The internal link, which can be used to edit bot settings; may be null -botInfo#32ab8617 short_description:string description:string photo:photo animation:animation menu_button:botMenuButton commands:vector default_group_administrator_rights:chatAdministratorRights default_channel_administrator_rights:chatAdministratorRights has_media_previews:Bool edit_commands_link:InternalLinkType edit_description_link:InternalLinkType edit_description_media_link:InternalLinkType edit_settings_link:InternalLinkType = BotInfo; +botInfo#9902b940 short_description:string description:string photo:photo animation:animation menu_button:botMenuButton commands:vector privacy_policy_url:string default_group_administrator_rights:chatAdministratorRights default_channel_administrator_rights:chatAdministratorRights has_media_previews:Bool edit_commands_link:InternalLinkType edit_description_link:InternalLinkType edit_description_media_link:InternalLinkType edit_settings_link:InternalLinkType = BotInfo; //@description Contains full information about a user //@personal_photo User profile photo set by the current user for the contact; may be null. If null and user.profile_photo is null, then the photo is empty; otherwise, it is unknown. @@ -1106,7 +1159,8 @@ chatMemberStatusCreator#f6764afe custom_title:string is_anonymous:Bool is_member chatMemberStatusAdministrator#fbd3841d custom_title:string can_be_edited:Bool rights:chatAdministratorRights = ChatMemberStatus; //@description The user is a member of the chat, without any additional privileges or restrictions -chatMemberStatusMember#32597455 = ChatMemberStatus; +//@member_until_date Point in time (Unix timestamp) when the user will be removed from the chat because of the expired subscription; 0 if never. Ignored in setChatMemberStatus +chatMemberStatusMember#fe0cec16 member_until_date:int32 = ChatMemberStatus; //@description The user is under certain restrictions in the chat. Not supported in basic groups and channels //@is_member True, if the user is a member of the chat @@ -1196,13 +1250,15 @@ supergroupMembersFilterBots#1d5571a6 = SupergroupMembersFilter; //@date Point in time (Unix timestamp) when the link was created //@edit_date Point in time (Unix timestamp) when the link was last edited; 0 if never or unknown //@expiration_date Point in time (Unix timestamp) when the link will expire; 0 if never +//@subscription_pricing Information about subscription plan that is applied to the users joining the chat by the link; may be null if the link doesn't require subscription //@member_limit The maximum number of members, which can join the chat using the link simultaneously; 0 if not limited. Always 0 if the link requires approval //@member_count Number of chat members, which joined the chat using the link +//@expired_member_count Number of chat members, which joined the chat using the link, but have already left because of expired subscription; for subscription links only //@pending_join_request_count Number of pending join requests created using this link //@creates_join_request True, if the link only creates join request. If true, total number of joining members will be unlimited //@is_primary True, if the link is primary. Primary invite link can't have name, expiration date, or usage limit. There is exactly one primary invite link for each administrator with can_invite_users right at a given time //@is_revoked True, if the link was revoked -chatInviteLink#f3bb8d04 invite_link:string name:string creator_user_id:int53 date:int32 edit_date:int32 expiration_date:int32 member_limit:int32 member_count:int32 pending_join_request_count:int32 creates_join_request:Bool is_primary:Bool is_revoked:Bool = ChatInviteLink; +chatInviteLink#c6eb6530 invite_link:string name:string creator_user_id:int53 date:int32 edit_date:int32 expiration_date:int32 subscription_pricing:starSubscriptionPricing member_limit:int32 member_count:int32 expired_member_count:int32 pending_join_request_count:int32 creates_join_request:Bool is_primary:Bool is_revoked:Bool = ChatInviteLink; //@description Contains a list of chat invite links //@total_count Approximate total number of chat invite links found @@ -1242,6 +1298,12 @@ inviteLinkChatTypeSupergroup#3de86758 = InviteLinkChatType; //@description The link is an invite link for a channel inviteLinkChatTypeChannel#3012ef0b = InviteLinkChatType; +//@description Contains information about subscription plan that must be paid by the user to use a chat invite link +//@pricing Information about subscription plan that must be paid by the user to use the link +//@can_reuse True, if the user has already paid for the subscription and can use joinChatByInviteLink to join the subscribed chat again +//@form_id Identifier of the payment form to use for subscription payment; 0 if the subscription can't be paid +chatInviteLinkSubscriptionInfo#38cf7368 pricing:starSubscriptionPricing can_reuse:Bool form_id:int64 = ChatInviteLinkSubscriptionInfo; + //@description Contains information about a chat invite link //@chat_id Chat identifier of the invite link; 0 if the user has no access to the chat before joining //@accessible_for If non-zero, the amount of time for which read access to the chat will remain available, in seconds @@ -1252,12 +1314,13 @@ inviteLinkChatTypeChannel#3012ef0b = InviteLinkChatType; //@param_description Chat description //@member_count Number of members in the chat //@member_user_ids User identifiers of some chat members that may be known to the current user +//@subscription_info Information about subscription plan that must be paid by the user to use the link; may be null if the link doesn't require subscription //@creates_join_request True, if the link only creates join request //@is_public True, if the chat is a public supergroup or channel, i.e. it has a username or it is a location-based supergroup //@is_verified True, if the chat is verified //@is_scam True, if many users reported this chat as a scam //@is_fake True, if many users reported this chat as a fake account -chatInviteLinkInfo#829e9f23 chat_id:int53 accessible_for:int32 type:InviteLinkChatType title:string photo:chatPhotoInfo accent_color_id:int32 description:string member_count:int32 member_user_ids:vector creates_join_request:Bool is_public:Bool is_verified:Bool is_scam:Bool is_fake:Bool = ChatInviteLinkInfo; +chatInviteLinkInfo#95bf0ec4 chat_id:int53 accessible_for:int32 type:InviteLinkChatType title:string photo:chatPhotoInfo accent_color_id:int32 description:string member_count:int32 member_user_ids:vector subscription_info:chatInviteLinkSubscriptionInfo creates_join_request:Bool is_public:Bool is_verified:Bool is_scam:Bool is_fake:Bool = ChatInviteLinkInfo; //@description Describes a user that sent a join request and waits for administrator approval //@user_id User identifier @@ -1303,7 +1366,8 @@ basicGroupFullInfo#d62e521e photo:chatPhoto description:string creator_user_id:i //@boost_level Approximate boost level for the chat //@has_linked_chat True, if the channel has a discussion group, or the supergroup is the designated discussion group for a channel //@has_location True, if the supergroup is connected to a location, i.e. the supergroup is a location-based supergroup -//@sign_messages True, if messages sent to the channel need to contain information about the sender. This field is only applicable to channels +//@sign_messages True, if messages sent to the channel contains name of the sender. This field is only applicable to channels +//@show_message_sender True, if messages sent to the channel have information about the sender user. This field is only applicable to channels //@join_to_send_messages True, if users need to join the supergroup before they can send messages. Always true for channels and non-discussion supergroups //@join_by_request True, if all users directly joining the supergroup need to be approved by supergroup administrators. Always false for channels and supergroups without username, location, or a linked chat //@is_slow_mode_enabled True, if the slow mode is enabled in the supergroup @@ -1311,12 +1375,13 @@ basicGroupFullInfo#d62e521e photo:chatPhoto description:string creator_user_id:i //@is_broadcast_group True, if the supergroup is a broadcast group, i.e. only administrators can send messages and there is no limit on the number of members //@is_forum True, if the supergroup is a forum with topics //@is_verified True, if the supergroup or channel is verified +//@has_sensitive_content True, if content of media messages in the supergroup or channel chat must be hidden with 18+ spoiler //@restriction_reason If non-empty, contains a human-readable description of the reason why access to this supergroup or channel must be restricted //@is_scam True, if many users reported this supergroup or channel as a scam //@is_fake True, if many users reported this supergroup or channel as a fake account //@has_active_stories True, if the supergroup or channel has non-expired stories available to the current user //@has_unread_active_stories True, if the supergroup or channel has unread non-expired stories available to the current user -supergroup#39a14289 id:int53 usernames:usernames date:int32 status:ChatMemberStatus member_count:int32 boost_level:int32 has_linked_chat:Bool has_location:Bool sign_messages:Bool join_to_send_messages:Bool join_by_request:Bool is_slow_mode_enabled:Bool is_channel:Bool is_broadcast_group:Bool is_forum:Bool is_verified:Bool restriction_reason:string is_scam:Bool is_fake:Bool has_active_stories:Bool has_unread_active_stories:Bool = Supergroup; +supergroup#ca7c2ce id:int53 usernames:usernames date:int32 status:ChatMemberStatus member_count:int32 boost_level:int32 has_linked_chat:Bool has_location:Bool sign_messages:Bool show_message_sender:Bool join_to_send_messages:Bool join_by_request:Bool is_slow_mode_enabled:Bool is_channel:Bool is_broadcast_group:Bool is_forum:Bool is_verified:Bool has_sensitive_content:Bool restriction_reason:string is_scam:Bool is_fake:Bool has_active_stories:Bool has_unread_active_stories:Bool = Supergroup; //@description Contains full information about a supergroup or channel //@photo Chat photo; may be null if empty or unknown. If non-null, then it is the same photo as in chat.photo @@ -1328,6 +1393,7 @@ supergroup#39a14289 id:int53 usernames:usernames date:int32 status:ChatMemberSta //@linked_chat_id Chat identifier of a discussion group for the channel, or a channel, for which the supergroup is the designated discussion group; 0 if none or unknown //@slow_mode_delay Delay between consecutive sent messages for non-administrator supergroup members, in seconds //@slow_mode_delay_expires_in Time left before next message can be sent in the supergroup, in seconds. An updateSupergroupFullInfo update is not triggered when value of this field changes, but both new and old values are non-zero +//@can_enable_paid_reaction True, if paid reaction can be enabled in the channel chat; for channels only //@can_get_members True, if members of the chat can be retrieved via getSupergroupMembers or searchChatMembers //@has_hidden_members True, if non-administrators can receive only administrators and bots using getSupergroupMembers or searchChatMembers //@can_hide_members True, if non-administrators and non-bots can be hidden in responses to getSupergroupMembers and searchChatMembers for non-administrators @@ -1351,7 +1417,7 @@ supergroup#39a14289 id:int53 usernames:usernames date:int32 status:ChatMemberSta //@bot_commands List of commands of bots in the group //@upgraded_from_basic_group_id Identifier of the basic group from which supergroup was upgraded; 0 if none //@upgraded_from_max_message_id Identifier of the last message in the basic group from which supergroup was upgraded; 0 if none -supergroupFullInfo#32925d5a photo:chatPhoto description:string member_count:int32 administrator_count:int32 restricted_count:int32 banned_count:int32 linked_chat_id:int53 slow_mode_delay:int32 slow_mode_delay_expires_in:double can_get_members:Bool has_hidden_members:Bool can_hide_members:Bool can_set_sticker_set:Bool can_set_location:Bool can_get_statistics:Bool can_get_revenue_statistics:Bool can_get_star_revenue_statistics:Bool can_toggle_aggressive_anti_spam:Bool is_all_history_available:Bool can_have_sponsored_messages:Bool has_aggressive_anti_spam_enabled:Bool has_paid_media_allowed:Bool has_pinned_stories:Bool my_boost_count:int32 unrestrict_boost_count:int32 sticker_set_id:int64 custom_emoji_sticker_set_id:int64 location:chatLocation invite_link:chatInviteLink bot_commands:vector upgraded_from_basic_group_id:int53 upgraded_from_max_message_id:int53 = SupergroupFullInfo; +supergroupFullInfo#1ea45bb photo:chatPhoto description:string member_count:int32 administrator_count:int32 restricted_count:int32 banned_count:int32 linked_chat_id:int53 slow_mode_delay:int32 slow_mode_delay_expires_in:double can_enable_paid_reaction:Bool can_get_members:Bool has_hidden_members:Bool can_hide_members:Bool can_set_sticker_set:Bool can_set_location:Bool can_get_statistics:Bool can_get_revenue_statistics:Bool can_get_star_revenue_statistics:Bool can_toggle_aggressive_anti_spam:Bool is_all_history_available:Bool can_have_sponsored_messages:Bool has_aggressive_anti_spam_enabled:Bool has_paid_media_allowed:Bool has_pinned_stories:Bool my_boost_count:int32 unrestrict_boost_count:int32 sticker_set_id:int64 custom_emoji_sticker_set_id:int64 location:chatLocation invite_link:chatInviteLink bot_commands:vector upgraded_from_basic_group_id:int53 upgraded_from_max_message_id:int53 = SupergroupFullInfo; //@class SecretChatState @description Describes the current secret chat state @@ -1464,6 +1530,17 @@ reactionTypeEmoji#8c3e22c8 emoji:string = ReactionType; //@custom_emoji_id Unique identifier of the custom emoji reactionTypeCustomEmoji#c50b42f3 custom_emoji_id:int64 = ReactionType; +//@description The paid reaction in a channel chat +reactionTypePaid#1a0152ed = ReactionType; + +//@description Contains information about a user that added paid reactions +//@sender_id Identifier of the user or chat that added the reactions; may be null for anonymous reactors that aren't the current user +//@star_count Number of Telegram Stars added +//@is_top True, if the reactor is one of the most active reactors; can be false if the reactor is the current user +//@is_me True, if the paid reaction was added by the current user +//@is_anonymous True, if the reactor is anonymous +paidReactor#9d379008 sender_id:MessageSender star_count:int32 is_top:Bool is_me:Bool is_anonymous:Bool = PaidReactor; + //@description Contains information about a forwarded message //@origin Origin of the forwarded message //@date Point in time (Unix timestamp) when the message was originally sent @@ -1495,7 +1572,9 @@ messageReaction#7d9e9864 type:ReactionType total_count:int32 is_chosen:Bool used //@description Contains a list of reactions added to a message //@reactions List of added reactions //@are_tags True, if the reactions are tags and Telegram Premium users can filter messages by them -messageReactions#91986cd8 reactions:vector are_tags:Bool = MessageReactions; +//@paid_reactors Information about top users that added the paid reaction +//@can_get_added_reactions True, if the list of added reactions is available using getMessageAddedReactions +messageReactions#9d558cb reactions:vector are_tags:Bool paid_reactors:vector can_get_added_reactions:Bool = MessageReactions; //@description Contains information about interactions with a message //@view_count Number of times the message was viewed @@ -1627,10 +1706,11 @@ factCheck#c185f918 text:formattedText country_code:string = FactCheck; //@author_signature For channel posts and anonymous group messages, optional author signature //@media_album_id Unique identifier of an album this message belongs to; 0 if none. Only audios, documents, photos and videos can be grouped together in albums //@effect_id Unique identifier of the effect added to the message; 0 if none +//@has_sensitive_content True, if media content of the message must be hidden with 18+ spoiler //@restriction_reason If non-empty, contains a human-readable description of the reason why access to this message must be restricted //@content Content of the message //@reply_markup Reply markup for the message; may be null if none -message#dc764ddc id:int53 sender_id:MessageSender chat_id:int53 sending_state:MessageSendingState scheduling_state:MessageSchedulingState is_outgoing:Bool is_pinned:Bool is_from_offline:Bool can_be_saved:Bool has_timestamped_media:Bool is_channel_post:Bool is_topic_message:Bool contains_unread_mention:Bool date:int32 edit_date:int32 forward_info:messageForwardInfo import_info:messageImportInfo interaction_info:messageInteractionInfo unread_reactions:vector fact_check:factCheck reply_to:MessageReplyTo message_thread_id:int53 saved_messages_topic_id:int53 self_destruct_type:MessageSelfDestructType self_destruct_in:double auto_delete_in:double via_bot_user_id:int53 sender_business_bot_user_id:int53 sender_boost_count:int32 author_signature:string media_album_id:int64 effect_id:int64 restriction_reason:string content:MessageContent reply_markup:ReplyMarkup = Message; +message#a9c04bbc id:int53 sender_id:MessageSender chat_id:int53 sending_state:MessageSendingState scheduling_state:MessageSchedulingState is_outgoing:Bool is_pinned:Bool is_from_offline:Bool can_be_saved:Bool has_timestamped_media:Bool is_channel_post:Bool is_topic_message:Bool contains_unread_mention:Bool date:int32 edit_date:int32 forward_info:messageForwardInfo import_info:messageImportInfo interaction_info:messageInteractionInfo unread_reactions:vector fact_check:factCheck reply_to:MessageReplyTo message_thread_id:int53 saved_messages_topic_id:int53 self_destruct_type:MessageSelfDestructType self_destruct_in:double auto_delete_in:double via_bot_user_id:int53 sender_business_bot_user_id:int53 sender_boost_count:int32 author_signature:string media_album_id:int64 effect_id:int64 has_sensitive_content:Bool restriction_reason:string content:MessageContent reply_markup:ReplyMarkup = Message; //@description Contains a list of messages //@total_count Approximate total number of messages found @@ -1721,7 +1801,7 @@ messageSponsor#77c251de url:string photo:photo info:string = MessageSponsor; //@message_id Message identifier; unique for the chat to which the sponsored message belongs among both ordinary and sponsored messages //@is_recommended True, if the message needs to be labeled as "recommended" instead of "sponsored" //@can_be_reported True, if the message can be reported to Telegram moderators through reportChatSponsoredMessage -//@content Content of the message. Currently, can be only of the type messageText +//@content Content of the message. Currently, can be only of the types messageText, messageAnimation, messagePhoto, or messageVideo //@sponsor Information about the sponsor of the message //@title Title of the sponsored message //@button_text Text for the message action button @@ -1963,7 +2043,7 @@ chatPosition#dae48755 list:ChatList order:int64 is_pinned:Bool source:ChatSource //@class ChatAvailableReactions @description Describes reactions available in the chat -//@description All reactions are available in the chat +//@description All reactions are available in the chat, excluding the paid reaction and custom reactions in channel chats //@max_reaction_count The maximum allowed number of reactions per message; 1-11 chatAvailableReactionsAll#29600b97 max_reaction_count:int32 = ChatAvailableReactions; @@ -2694,7 +2774,8 @@ linkPreviewTypeAudio#572c6b78 url:string mime_type:string audio:audio duration:i //@description The link is a link to a background. Link preview title and description are available only for filled backgrounds //@document Document with the background; may be null for filled backgrounds -linkPreviewTypeBackground#6dc50386 document:document = LinkPreviewType; +//@background_type Type of the background; may be null if unknown +linkPreviewTypeBackground#3a48a1e0 document:document background_type:BackgroundType = LinkPreviewType; //@description The link is a link to boost a channel chat //@photo Photo of the chat; may be null @@ -2755,8 +2836,8 @@ linkPreviewTypePremiumGiftCode#4e0d80b1 = LinkPreviewType; //@description The link is a link to a shareable chat folder linkPreviewTypeShareableChatFolder#805ab33c = LinkPreviewType; -//@description The link is a link to a sticker message -//@sticker The sticker +//@description The link is a link to a sticker +//@sticker The sticker. It can be an arbitrary WEBP image and can have dimensions bigger than 512 linkPreviewTypeSticker#245f4d25 sticker:sticker = LinkPreviewType; //@description The link is a link to a sticker set @@ -4122,7 +4203,6 @@ inputMessageForwarded#651a73f8 from_chat_id:int53 message_id:int53 in_game_share //@can_be_saved True, if content of the message can be saved locally or copied using inputMessageForwarded or forwardMessages with copy options //@can_be_shared_in_story True, if the message can be shared in a story using inputStoryAreaTypeMessage //@can_edit_scheduling_state True, if scheduling state of the message can be edited -//@can_get_added_reactions True, if the list of added reactions is available using getMessageAddedReactions //@can_get_embedding_code True, if code for message embedding can be received using getMessageEmbeddingCode //@can_get_link True, if a link can be generated for the message using getMessageLink //@can_get_media_timestamp_links True, if media timestamp links can be generated for media timestamp entities in the message text, caption or link preview description using getMessageLink @@ -4136,7 +4216,7 @@ inputMessageForwarded#651a73f8 from_chat_id:int53 message_id:int53 in_game_share //@can_report_supergroup_spam True, if the message can be reported using reportSupergroupSpam //@can_set_fact_check True, if fact check for the message can be changed through setMessageFactCheck //@need_show_statistics True, if message statistics must be available from context menu of the message -messageProperties#5ae4cb28 can_be_deleted_only_for_self:Bool can_be_deleted_for_all_users:Bool can_be_edited:Bool can_be_forwarded:Bool can_be_paid:Bool can_be_pinned:Bool can_be_replied:Bool can_be_replied_in_another_chat:Bool can_be_saved:Bool can_be_shared_in_story:Bool can_edit_scheduling_state:Bool can_get_added_reactions:Bool can_get_embedding_code:Bool can_get_link:Bool can_get_media_timestamp_links:Bool can_get_message_thread:Bool can_get_read_date:Bool can_get_statistics:Bool can_get_viewers:Bool can_recognize_speech:Bool can_report_chat:Bool can_report_reactions:Bool can_report_supergroup_spam:Bool can_set_fact_check:Bool need_show_statistics:Bool = MessageProperties; +messageProperties#11deeec2 can_be_deleted_only_for_self:Bool can_be_deleted_for_all_users:Bool can_be_edited:Bool can_be_forwarded:Bool can_be_paid:Bool can_be_pinned:Bool can_be_replied:Bool can_be_replied_in_another_chat:Bool can_be_saved:Bool can_be_shared_in_story:Bool can_edit_scheduling_state:Bool can_get_embedding_code:Bool can_get_link:Bool can_get_media_timestamp_links:Bool can_get_message_thread:Bool can_get_read_date:Bool can_get_statistics:Bool can_get_viewers:Bool can_recognize_speech:Bool can_report_chat:Bool can_report_reactions:Bool can_report_supergroup_spam:Bool can_set_fact_check:Bool need_show_statistics:Bool = MessageProperties; //@class SearchMessagesFilter @description Represents a filter for message search results @@ -5603,6 +5683,10 @@ chatEventHasAggressiveAntiSpamEnabledToggled#f8875702 has_aggressive_anti_spam_e //@sign_messages New value of sign_messages chatEventSignMessagesToggled#b1b9281e sign_messages:Bool = ChatEventAction; +//@description The show_message_sender setting of a channel was toggled +//@show_message_sender New value of show_message_sender +chatEventShowMessageSenderToggled#d0a747e3 show_message_sender:Bool = ChatEventAction; + //@description A chat invite link was edited //@old_invite_link Previous information about the invite link //@new_invite_link New information about the invite link @@ -6061,6 +6145,10 @@ telegramPaymentPurposeStars#e273ee52 currency:string amount:int53 star_count:int //@star_count Number of bought Telegram Stars telegramPaymentPurposeGiftedStars#91b68a36 user_id:int53 currency:string amount:int53 star_count:int53 = TelegramPaymentPurpose; +//@description The user joins a chat and subscribes to regular payments in Telegram Stars +//@invite_link Invite link to use +telegramPaymentPurposeJoinChat#8ddd6788 invite_link:string = TelegramPaymentPurpose; + //@class DeviceToken @description Represents a data needed to subscribe for push notifications through registerDevice method. //@description A token for Firebase Cloud Messaging @@ -6875,7 +6963,12 @@ internalLinkTypeBotStartInGroup#ca0d8cce bot_username:string start_parameter:str //@link_name Name of the link internalLinkTypeBusinessChat#a03ae9d7 link_name:string = InternalLinkType; -//@description The link is a link to the change phone number section of the app +//@description The link is a link to the Telegram Star purchase section of the application +//@star_count The number of Telegram Stars that must be owned by the user +//@purpose Purpose of Telegram Star purchase. Arbitrary string specified by the server, for example, "subs" if the Telegram Stars are required to extend channel subscriptions +internalLinkTypeBuyStars#a94cc347 star_count:int53 purpose:string = InternalLinkType; + +//@description The link is a link to the change phone number section of the application internalLinkTypeChangePhoneNumber#f0275b01 = InternalLinkType; //@description The link is a link to boost a Telegram chat. Call getChatBoostLinkInfo with the given URL to process the link. @@ -6886,17 +6979,17 @@ internalLinkTypeChatBoost#d549fd40 url:string = InternalLinkType; //@invite_link Internal representation of the invite link internalLinkTypeChatFolderInvite#89b2493e invite_link:string = InternalLinkType; -//@description The link is a link to the folder section of the app settings +//@description The link is a link to the folder section of the application settings internalLinkTypeChatFolderSettings#bfff055c = InternalLinkType; //@description The link is a chat invite link. Call checkChatInviteLink with the given invite link to process the link. //@invite_link Internal representation of the invite link internalLinkTypeChatInvite#198c3cd9 invite_link:string = InternalLinkType; -//@description The link is a link to the default message auto-delete timer settings section of the app settings +//@description The link is a link to the default message auto-delete timer settings section of the application settings internalLinkTypeDefaultMessageAutoDeleteTimerSettings#2baaf931 = InternalLinkType; -//@description The link is a link to the edit profile section of the app settings +//@description The link is a link to the edit profile section of the application settings internalLinkTypeEditProfileSettings#c30e5066 = InternalLinkType; //@description The link is a link to a game. Call searchPublicChat with the given bot username, check that the user is a bot, @@ -6917,7 +7010,7 @@ internalLinkTypeInvoice#f34c6dac invoice_name:string = InternalLinkType; //@language_pack_id Language pack identifier internalLinkTypeLanguagePack#a9870d6c language_pack_id:string = InternalLinkType; -//@description The link is a link to the language section of the app settings +//@description The link is a link to the language section of the application settings internalLinkTypeLanguageSettings#b019e6e6 = InternalLinkType; //@description The link is a link to the main Web App of a bot. Call searchPublicChat with the given bot username, check that the user is a bot and has the main Web App. @@ -6960,7 +7053,7 @@ internalLinkTypePremiumGift#5ad56d41 referrer:string = InternalLinkType; //@code The Telegram Premium gift code internalLinkTypePremiumGiftCode#de5c9892 code:string = InternalLinkType; -//@description The link is a link to the privacy and security section of the app settings +//@description The link is a link to the privacy and security section of the application settings internalLinkTypePrivacyAndSecuritySettings#ad5f6acf = InternalLinkType; //@description The link is a link to a proxy. Call addProxy with the given parameters to process the link and add the proxy @@ -6998,7 +7091,7 @@ internalLinkTypeStory#57bce647 story_sender_username:string story_id:int32 = Int //@theme_name Name of the theme internalLinkTypeTheme#f405f807 theme_name:string = InternalLinkType; -//@description The link is a link to the theme section of the app settings +//@description The link is a link to the theme section of the application settings internalLinkTypeThemeSettings#c14d3916 = InternalLinkType; //@description The link is an unknown tg: link. Call getDeepLinkInfo to process the link @@ -7366,6 +7459,9 @@ suggestedActionSetBirthdate#eabd9b02 = SuggestedAction; //@manage_premium_subscription_url A URL for managing Telegram Premium subscription suggestedActionExtendPremium#de405cca manage_premium_subscription_url:string = SuggestedAction; +//@description Suggests the user to extend their expiring Telegram Star subscriptions. Call getStarSubscriptions with only_expiring == true +suggestedActionExtendStarSubscriptions#fd32d556 = SuggestedAction; + //@description Contains a counter //@count Count count#4d38f104 count:int32 = Count; @@ -8277,6 +8373,10 @@ updateDefaultReactionType#4b615105 reaction_type:ReactionType = Update; //@tags The new tags updateSavedMessagesTags#7386424a saved_messages_topic_id:int53 tags:savedMessagesTags = Update; +//@description The list of messages with active live location that need to be updated by the application has changed. The list is persistent across application restarts only if the message database is used +//@messages The list of messages with active live locations +updateActiveLiveLocationMessages#a20b9b1f messages:vector = Update; + //@description The number of Telegram Stars owned by the current user has changed //@star_count The new number of Telegram Stars owned updateOwnedStarCount#de995b79 star_count:int53 = Update; @@ -9064,9 +9164,6 @@ deleteAllCallMessages#a897d1f3 revoke:Bool = Ok; //@limit The maximum number of messages to be returned searchChatRecentLocationMessages#38a37ee6 chat_id:int53 limit:int32 = Messages; -//@description Returns all active live locations that need to be updated by the application. The list is persistent across application restarts only if the message database is used -getActiveLiveLocationMessages#ab093691 = Messages; - //@description Returns the last message sent in a chat no later than the specified date //@chat_id Chat identifier //@date Point in time (Unix timestamp) relative to which to search for messages @@ -9570,7 +9667,7 @@ clearRecentReactions#4d61c752 = Ok; //@description Adds a reaction or a tag to a message. Use getMessageAvailableReactions to receive the list of available reactions for the message //@chat_id Identifier of the chat to which the message belongs //@message_id Identifier of the message -//@reaction_type Type of the reaction to add +//@reaction_type Type of the reaction to add. Use addPaidMessageReaction instead to add the paid reaction //@is_big Pass true if the reaction is added with a big animation //@update_recent_reactions Pass true if the reaction needs to be added to recent reactions; tags are never added to the list of recent reactions addMessageReaction#549855ed chat_id:int53 message_id:int53 reaction_type:ReactionType is_big:Bool update_recent_reactions:Bool = Ok; @@ -9578,9 +9675,27 @@ addMessageReaction#549855ed chat_id:int53 message_id:int53 reaction_type:Reactio //@description Removes a reaction from a message. A chosen reaction can always be removed //@chat_id Identifier of the chat to which the message belongs //@message_id Identifier of the message -//@reaction_type Type of the reaction to remove +//@reaction_type Type of the reaction to remove. The paid reaction can't be removed removeMessageReaction#97474d7b chat_id:int53 message_id:int53 reaction_type:ReactionType = Ok; +//@description Adds the paid message reaction to a message. Use getMessageAvailableReactions to receive the list of available reactions for the message +//@chat_id Identifier of the chat to which the message belongs +//@message_id Identifier of the message +//@star_count Number of Telegram Stars to be used for the reaction; 1-getOption("paid_reaction_star_count_max") +//@is_anonymous Pass true to make paid reaction of the user on the message anonymous; pass false to make the user's profile visible among top reactors +addPaidMessageReaction#542fae53 chat_id:int53 message_id:int53 star_count:int53 is_anonymous:Bool = Ok; + +//@description Removes all pending paid reactions on a message. Can be called within 5 seconds after the last addPaidMessageReaction call +//@chat_id Identifier of the chat to which the message belongs +//@message_id Identifier of the message +removePendingPaidMessageReactions#41949cfb chat_id:int53 message_id:int53 = Ok; + +//@description Changes whether the paid message reaction of the user to a message is anonymous. The message must have paid reaction added by the user +//@chat_id Identifier of the chat to which the message belongs +//@message_id Identifier of the message +//@is_anonymous Pass true to make paid reaction of the user on the message anonymous; pass false to make the user's profile visible among top reactors +togglePaidMessageReactionIsAnonymous#9774db11 chat_id:int53 message_id:int53 is_anonymous:Bool = Ok; + //@description Sets reactions on a message; for bots only //@chat_id Identifier of the chat to which the message belongs //@message_id Identifier of the message @@ -9590,14 +9705,14 @@ setMessageReactions#71fa9e8f chat_id:int53 message_id:int53 reaction_types:vecto //@description Returns reactions added for a message, along with their sender //@chat_id Identifier of the chat to which the message belongs -//@message_id Identifier of the message. Use messageProperties.can_get_added_reactions to check whether added reactions can be received for the message -//@reaction_type Type of the reactions to return; pass null to return all added reactions +//@message_id Identifier of the message. Use message.interaction_info.reactions.can_get_added_reactions to check whether added reactions can be received for the message +//@reaction_type Type of the reactions to return; pass null to return all added reactions; reactionTypePaid isn't supported //@offset Offset of the first entry to return as received from the previous request; use empty string to get the first chunk of results //@limit The maximum number of reactions to be returned; must be positive and can't be greater than 100 getMessageAddedReactions#7dc6ae52 chat_id:int53 message_id:int53 reaction_type:ReactionType offset:string limit:int32 = AddedReactions; //@description Changes type of default reaction for the current user -//@reaction_type New type of the default reaction +//@reaction_type New type of the default reaction. The paid reaction can't be set as default setDefaultReactionType#65038a3d reaction_type:ReactionType = Ok; //@description Returns tags used in Saved Messages or a Saved Messages topic @@ -10442,7 +10557,7 @@ getStoryAvailableReactions#23854d3b row_size:int32 = AvailableReactions; //@description Changes chosen reaction on a story that has already been sent //@story_sender_chat_id The identifier of the sender of the story //@story_id The identifier of the story -//@reaction_type Type of the reaction to set; pass null to remove the reaction. `reactionTypeCustomEmoji` reactions can be used only by Telegram Premium users +//@reaction_type Type of the reaction to set; pass null to remove the reaction. Custom emoji reactions can be used only by Telegram Premium users. Paid reactions can't be set //@update_recent_reactions Pass true if the reaction needs to be added to recent reactions setStoryReaction#ac8b4fa7 story_sender_chat_id:int53 story_id:int32 reaction_type:ReactionType update_recent_reactions:Bool = Ok; @@ -10459,7 +10574,7 @@ getStoryInteractions#1cd1400d story_id:int32 query:string only_contacts:Bool pre //@description Returns interactions with a story posted in a chat. Can be used only if story is posted on behalf of a chat and the user is an administrator in the chat //@story_sender_chat_id The identifier of the sender of the story //@story_id Story identifier -//@reaction_type Pass the default heart reaction or a suggested reaction type to receive only interactions with the specified reaction type; pass null to receive all interactions +//@reaction_type Pass the default heart reaction or a suggested reaction type to receive only interactions with the specified reaction type; pass null to receive all interactions; reactionTypePaid isn't supported //@prefer_forwards Pass true to get forwards and reposts first, then reactions, then other views; pass false to get interactions sorted just by interaction date //@offset Offset of the first entry to return as received from the previous request; use empty string to get the first chunk of results //@limit The maximum number of story interactions to return @@ -10680,7 +10795,13 @@ replacePrimaryChatInviteLink#3f9e7b9d chat_id:int53 = ChatInviteLink; //@creates_join_request Pass true if users joining the chat via the link need to be approved by chat administrators. In this case, member_limit must be 0 createChatInviteLink#1126a341 chat_id:int53 name:string expiration_date:int32 member_limit:int32 creates_join_request:Bool = ChatInviteLink; -//@description Edits a non-primary invite link for a chat. Available for basic groups, supergroups, and channels. Requires administrator privileges and can_invite_users right in the chat for own links and owner privileges for other links +//@description Creates a new subscription invite link for a channel chat. Requires can_invite_users right in the chat +//@chat_id Chat identifier +//@name Invite link name; 0-32 characters +//@subscription_pricing Information about subscription plan that will be applied to the users joining the chat via the link. +createChatSubscriptionInviteLink#226b65 chat_id:int53 name:string subscription_pricing:starSubscriptionPricing = ChatInviteLink; + +//@description Edits a non-primary invite link for a chat. Available for basic groups, supergroups, and channels. //@chat_id Chat identifier //@invite_link Invite link to be edited //@name Invite link name; 0-32 characters @@ -10689,6 +10810,12 @@ createChatInviteLink#1126a341 chat_id:int53 name:string expiration_date:int32 me //@creates_join_request Pass true if users joining the chat via the link need to be approved by chat administrators. In this case, member_limit must be 0 editChatInviteLink#4eb23d7c chat_id:int53 invite_link:string name:string expiration_date:int32 member_limit:int32 creates_join_request:Bool = ChatInviteLink; +//@description Edits a subscription invite link for a channel chat. Requires can_invite_users right in the chat for own links and owner privileges for other links +//@chat_id Chat identifier +//@invite_link Invite link to be edited +//@name Invite link name; 0-32 characters +editChatSubscriptionInviteLink#c74445d3 chat_id:int53 invite_link:string name:string = ChatInviteLink; + //@description Returns information about an invite link. Requires administrator privileges and can_invite_users right in the chat to get own links and owner privileges to get other links //@chat_id Chat identifier //@invite_link Invite link to get @@ -10710,9 +10837,10 @@ getChatInviteLinks#34a55cac chat_id:int53 creator_user_id:int53 is_revoked:Bool //@description Returns chat members joined a chat via an invite link. Requires administrator privileges and can_invite_users right in the chat for own links and owner privileges for other links //@chat_id Chat identifier //@invite_link Invite link for which to return chat members +//@only_with_expired_subscription Pass true if the link is a subscription link and only members with expired subscription must be returned //@offset_member A chat member from which to return next chat members; pass null to get results from the beginning //@limit The maximum number of chat members to return; up to 100 -getChatInviteLinkMembers#c5b6199a chat_id:int53 invite_link:string offset_member:chatInviteLinkMember limit:int32 = ChatInviteLinkMembers; +getChatInviteLinkMembers#6704ed3c chat_id:int53 invite_link:string only_with_expired_subscription:Bool offset_member:chatInviteLinkMember limit:int32 = ChatInviteLinkMembers; //@description Revokes invite link for a chat. Available for basic groups, supergroups, and channels. Requires administrator privileges and can_invite_users right in the chat for own links and owner privileges for other links. //@chat_id Chat identifier @@ -11570,10 +11698,11 @@ setSupergroupCustomEmojiStickerSet#4f3552af supergroup_id:int53 custom_emoji_sti //@unrestrict_boost_count New value of the unrestrict_boost_count supergroup setting; 0-8. Use 0 to remove the setting setSupergroupUnrestrictBoostCount#39ce30a3 supergroup_id:int53 unrestrict_boost_count:int32 = Ok; -//@description Toggles whether sender signature is added to sent messages in a channel; requires can_change_info member right +//@description Toggles whether sender signature or link to the account is added to sent messages in a channel; requires can_change_info member right //@supergroup_id Identifier of the channel //@sign_messages New value of sign_messages -toggleSupergroupSignMessages#44efd524 supergroup_id:int53 sign_messages:Bool = Ok; +//@show_message_sender New value of show_message_sender +toggleSupergroupSignMessages#221c1fcb supergroup_id:int53 sign_messages:Bool show_message_sender:Bool = Ok; //@description Toggles whether joining is mandatory to send messages to a discussion supergroup; requires can_restrict_members administrator right //@supergroup_id Identifier of the supergroup that isn't a broadcast group @@ -12188,10 +12317,16 @@ getStarGiftPaymentOptions#e22760e3 user_id:int53 = StarPaymentOptions; //@description Returns the list of Telegram Star transactions for the specified owner //@owner_id Identifier of the owner of the Telegram Stars; can be the identifier of the current user, identifier of an owned bot, +//@subscription_id If non-empty, only transactions related to the Star Subscription will be returned //@direction Direction of the transactions to receive; pass null to get all transactions //@offset Offset of the first transaction to return as received from the previous request; use empty string to get the first chunk of results //@limit The maximum number of transactions to return -getStarTransactions#eb1e109d owner_id:MessageSender direction:StarTransactionDirection offset:string limit:int32 = StarTransactions; +getStarTransactions#f096f8f1 owner_id:MessageSender subscription_id:string direction:StarTransactionDirection offset:string limit:int32 = StarTransactions; + +//@description Returns the list of Telegram Star subscriptions for the current user +//@only_expiring Pass true to receive only expiring subscriptions for which there are no enough Telegram Stars to extend +//@offset Offset of the first subscription to return as received from the previous request; use empty string to get the first chunk of results +getStarSubscriptions#d9c7b2ec only_expiring:Bool offset:string = StarSubscriptions; //@description Checks whether an in-store purchase is possible. Must be called before any in-store purchase //@purpose Transaction purpose @@ -12209,6 +12344,15 @@ assignAppStoreTransaction#86f30bb0 receipt:bytes purpose:StorePaymentPurpose = O //@purpose Transaction purpose assignGooglePlayTransaction#8939bca4 package_name:string store_product_id:string purchase_token:string purpose:StorePaymentPurpose = Ok; +//@description Cancels or reenables Telegram Star subscription to a channel +//@subscription_id Identifier of the subscription to change +//@is_canceled New value of is_canceled +editStarSubscription#7a1a3918 subscription_id:string is_canceled:Bool = Ok; + +//@description Reuses an active subscription and joins the subscribed chat again +//@subscription_id Identifier of the subscription +reuseStarSubscription#2e677441 subscription_id:string = Ok; + //@description Returns information about features, available to Business users //@source Source of the request; pass null if the method is called from settings or some non-standard source getBusinessFeatures#c4906001 source:BusinessFeature = BusinessFeatures; diff --git a/tdapi/tl_add_message_reaction_gen.go b/tdapi/tl_add_message_reaction_gen.go index 64f0a4ade7..0a93083f67 100644 --- a/tdapi/tl_add_message_reaction_gen.go +++ b/tdapi/tl_add_message_reaction_gen.go @@ -37,7 +37,8 @@ type AddMessageReactionRequest struct { ChatID int64 // Identifier of the message MessageID int64 - // Type of the reaction to add + // Type of the reaction to add. Use addPaidMessageReaction instead to add the paid + // reaction ReactionType ReactionTypeClass // Pass true if the reaction is added with a big animation IsBig bool diff --git a/tdapi/tl_add_paid_message_reaction_gen.go b/tdapi/tl_add_paid_message_reaction_gen.go new file mode 100644 index 0000000000..c90a657016 --- /dev/null +++ b/tdapi/tl_add_paid_message_reaction_gen.go @@ -0,0 +1,307 @@ +// Code generated by gotdgen, DO NOT EDIT. + +package tdapi + +import ( + "context" + "errors" + "fmt" + "sort" + "strings" + + "go.uber.org/multierr" + + "github.com/gotd/td/bin" + "github.com/gotd/td/tdjson" + "github.com/gotd/td/tdp" + "github.com/gotd/td/tgerr" +) + +// No-op definition for keeping imports. +var ( + _ = bin.Buffer{} + _ = context.Background() + _ = fmt.Stringer(nil) + _ = strings.Builder{} + _ = errors.Is + _ = multierr.AppendInto + _ = sort.Ints + _ = tdp.Format + _ = tgerr.Error{} + _ = tdjson.Encoder{} +) + +// AddPaidMessageReactionRequest represents TL type `addPaidMessageReaction#542fae53`. +type AddPaidMessageReactionRequest struct { + // Identifier of the chat to which the message belongs + ChatID int64 + // Identifier of the message + MessageID int64 + // Number of Telegram Stars to be used for the reaction; + // 1-getOption("paid_reaction_star_count_max") + StarCount int64 + // Pass true to make paid reaction of the user on the message anonymous; pass false to + // make the user's profile visible among top reactors + IsAnonymous bool +} + +// AddPaidMessageReactionRequestTypeID is TL type id of AddPaidMessageReactionRequest. +const AddPaidMessageReactionRequestTypeID = 0x542fae53 + +// Ensuring interfaces in compile-time for AddPaidMessageReactionRequest. +var ( + _ bin.Encoder = &AddPaidMessageReactionRequest{} + _ bin.Decoder = &AddPaidMessageReactionRequest{} + _ bin.BareEncoder = &AddPaidMessageReactionRequest{} + _ bin.BareDecoder = &AddPaidMessageReactionRequest{} +) + +func (a *AddPaidMessageReactionRequest) Zero() bool { + if a == nil { + return true + } + if !(a.ChatID == 0) { + return false + } + if !(a.MessageID == 0) { + return false + } + if !(a.StarCount == 0) { + return false + } + if !(a.IsAnonymous == false) { + return false + } + + return true +} + +// String implements fmt.Stringer. +func (a *AddPaidMessageReactionRequest) String() string { + if a == nil { + return "AddPaidMessageReactionRequest(nil)" + } + type Alias AddPaidMessageReactionRequest + return fmt.Sprintf("AddPaidMessageReactionRequest%+v", Alias(*a)) +} + +// TypeID returns type id in TL schema. +// +// See https://core.telegram.org/mtproto/TL-tl#remarks. +func (*AddPaidMessageReactionRequest) TypeID() uint32 { + return AddPaidMessageReactionRequestTypeID +} + +// TypeName returns name of type in TL schema. +func (*AddPaidMessageReactionRequest) TypeName() string { + return "addPaidMessageReaction" +} + +// TypeInfo returns info about TL type. +func (a *AddPaidMessageReactionRequest) TypeInfo() tdp.Type { + typ := tdp.Type{ + Name: "addPaidMessageReaction", + ID: AddPaidMessageReactionRequestTypeID, + } + if a == nil { + typ.Null = true + return typ + } + typ.Fields = []tdp.Field{ + { + Name: "ChatID", + SchemaName: "chat_id", + }, + { + Name: "MessageID", + SchemaName: "message_id", + }, + { + Name: "StarCount", + SchemaName: "star_count", + }, + { + Name: "IsAnonymous", + SchemaName: "is_anonymous", + }, + } + return typ +} + +// Encode implements bin.Encoder. +func (a *AddPaidMessageReactionRequest) Encode(b *bin.Buffer) error { + if a == nil { + return fmt.Errorf("can't encode addPaidMessageReaction#542fae53 as nil") + } + b.PutID(AddPaidMessageReactionRequestTypeID) + return a.EncodeBare(b) +} + +// EncodeBare implements bin.BareEncoder. +func (a *AddPaidMessageReactionRequest) EncodeBare(b *bin.Buffer) error { + if a == nil { + return fmt.Errorf("can't encode addPaidMessageReaction#542fae53 as nil") + } + b.PutInt53(a.ChatID) + b.PutInt53(a.MessageID) + b.PutInt53(a.StarCount) + b.PutBool(a.IsAnonymous) + return nil +} + +// Decode implements bin.Decoder. +func (a *AddPaidMessageReactionRequest) Decode(b *bin.Buffer) error { + if a == nil { + return fmt.Errorf("can't decode addPaidMessageReaction#542fae53 to nil") + } + if err := b.ConsumeID(AddPaidMessageReactionRequestTypeID); err != nil { + return fmt.Errorf("unable to decode addPaidMessageReaction#542fae53: %w", err) + } + return a.DecodeBare(b) +} + +// DecodeBare implements bin.BareDecoder. +func (a *AddPaidMessageReactionRequest) DecodeBare(b *bin.Buffer) error { + if a == nil { + return fmt.Errorf("can't decode addPaidMessageReaction#542fae53 to nil") + } + { + value, err := b.Int53() + if err != nil { + return fmt.Errorf("unable to decode addPaidMessageReaction#542fae53: field chat_id: %w", err) + } + a.ChatID = value + } + { + value, err := b.Int53() + if err != nil { + return fmt.Errorf("unable to decode addPaidMessageReaction#542fae53: field message_id: %w", err) + } + a.MessageID = value + } + { + value, err := b.Int53() + if err != nil { + return fmt.Errorf("unable to decode addPaidMessageReaction#542fae53: field star_count: %w", err) + } + a.StarCount = value + } + { + value, err := b.Bool() + if err != nil { + return fmt.Errorf("unable to decode addPaidMessageReaction#542fae53: field is_anonymous: %w", err) + } + a.IsAnonymous = value + } + return nil +} + +// EncodeTDLibJSON implements tdjson.TDLibEncoder. +func (a *AddPaidMessageReactionRequest) EncodeTDLibJSON(b tdjson.Encoder) error { + if a == nil { + return fmt.Errorf("can't encode addPaidMessageReaction#542fae53 as nil") + } + b.ObjStart() + b.PutID("addPaidMessageReaction") + b.Comma() + b.FieldStart("chat_id") + b.PutInt53(a.ChatID) + b.Comma() + b.FieldStart("message_id") + b.PutInt53(a.MessageID) + b.Comma() + b.FieldStart("star_count") + b.PutInt53(a.StarCount) + b.Comma() + b.FieldStart("is_anonymous") + b.PutBool(a.IsAnonymous) + b.Comma() + b.StripComma() + b.ObjEnd() + return nil +} + +// DecodeTDLibJSON implements tdjson.TDLibDecoder. +func (a *AddPaidMessageReactionRequest) DecodeTDLibJSON(b tdjson.Decoder) error { + if a == nil { + return fmt.Errorf("can't decode addPaidMessageReaction#542fae53 to nil") + } + + return b.Obj(func(b tdjson.Decoder, key []byte) error { + switch string(key) { + case tdjson.TypeField: + if err := b.ConsumeID("addPaidMessageReaction"); err != nil { + return fmt.Errorf("unable to decode addPaidMessageReaction#542fae53: %w", err) + } + case "chat_id": + value, err := b.Int53() + if err != nil { + return fmt.Errorf("unable to decode addPaidMessageReaction#542fae53: field chat_id: %w", err) + } + a.ChatID = value + case "message_id": + value, err := b.Int53() + if err != nil { + return fmt.Errorf("unable to decode addPaidMessageReaction#542fae53: field message_id: %w", err) + } + a.MessageID = value + case "star_count": + value, err := b.Int53() + if err != nil { + return fmt.Errorf("unable to decode addPaidMessageReaction#542fae53: field star_count: %w", err) + } + a.StarCount = value + case "is_anonymous": + value, err := b.Bool() + if err != nil { + return fmt.Errorf("unable to decode addPaidMessageReaction#542fae53: field is_anonymous: %w", err) + } + a.IsAnonymous = value + default: + return b.Skip() + } + return nil + }) +} + +// GetChatID returns value of ChatID field. +func (a *AddPaidMessageReactionRequest) GetChatID() (value int64) { + if a == nil { + return + } + return a.ChatID +} + +// GetMessageID returns value of MessageID field. +func (a *AddPaidMessageReactionRequest) GetMessageID() (value int64) { + if a == nil { + return + } + return a.MessageID +} + +// GetStarCount returns value of StarCount field. +func (a *AddPaidMessageReactionRequest) GetStarCount() (value int64) { + if a == nil { + return + } + return a.StarCount +} + +// GetIsAnonymous returns value of IsAnonymous field. +func (a *AddPaidMessageReactionRequest) GetIsAnonymous() (value bool) { + if a == nil { + return + } + return a.IsAnonymous +} + +// AddPaidMessageReaction invokes method addPaidMessageReaction#542fae53 returning error if any. +func (c *Client) AddPaidMessageReaction(ctx context.Context, request *AddPaidMessageReactionRequest) error { + var ok Ok + + if err := c.rpc.Invoke(ctx, request, &ok); err != nil { + return err + } + return nil +} diff --git a/tdapi/tl_bot_info_gen.go b/tdapi/tl_bot_info_gen.go index d1efa37c13..2ea52b45ef 100644 --- a/tdapi/tl_bot_info_gen.go +++ b/tdapi/tl_bot_info_gen.go @@ -31,7 +31,7 @@ var ( _ = tdjson.Encoder{} ) -// BotInfo represents TL type `botInfo#32ab8617`. +// BotInfo represents TL type `botInfo#9902b940`. type BotInfo struct { // The text that is shown on the bot's profile page and is sent together with the link // when users share the bot @@ -47,6 +47,10 @@ type BotInfo struct { MenuButton BotMenuButton // List of the bot commands Commands []BotCommand + // The HTTP link to the privacy policy of the bot. If empty, then /privacy command must + // be used if supported by the bot. If the command isn't supported, then https://telegram + // org/privacy-tpa must be opened + PrivacyPolicyURL string // Default administrator rights for adding the bot to basic group and supergroup chats; // may be null DefaultGroupAdministratorRights ChatAdministratorRights @@ -66,7 +70,7 @@ type BotInfo struct { } // BotInfoTypeID is TL type id of BotInfo. -const BotInfoTypeID = 0x32ab8617 +const BotInfoTypeID = 0x9902b940 // Ensuring interfaces in compile-time for BotInfo. var ( @@ -98,6 +102,9 @@ func (b *BotInfo) Zero() bool { if !(b.Commands == nil) { return false } + if !(b.PrivacyPolicyURL == "") { + return false + } if !(b.DefaultGroupAdministratorRights.Zero()) { return false } @@ -179,6 +186,10 @@ func (b *BotInfo) TypeInfo() tdp.Type { Name: "Commands", SchemaName: "commands", }, + { + Name: "PrivacyPolicyURL", + SchemaName: "privacy_policy_url", + }, { Name: "DefaultGroupAdministratorRights", SchemaName: "default_group_administrator_rights", @@ -214,7 +225,7 @@ func (b *BotInfo) TypeInfo() tdp.Type { // Encode implements bin.Encoder. func (b *BotInfo) Encode(buf *bin.Buffer) error { if b == nil { - return fmt.Errorf("can't encode botInfo#32ab8617 as nil") + return fmt.Errorf("can't encode botInfo#9902b940 as nil") } buf.PutID(BotInfoTypeID) return b.EncodeBare(buf) @@ -223,55 +234,56 @@ func (b *BotInfo) Encode(buf *bin.Buffer) error { // EncodeBare implements bin.BareEncoder. func (b *BotInfo) EncodeBare(buf *bin.Buffer) error { if b == nil { - return fmt.Errorf("can't encode botInfo#32ab8617 as nil") + return fmt.Errorf("can't encode botInfo#9902b940 as nil") } buf.PutString(b.ShortDescription) buf.PutString(b.Description) if err := b.Photo.Encode(buf); err != nil { - return fmt.Errorf("unable to encode botInfo#32ab8617: field photo: %w", err) + return fmt.Errorf("unable to encode botInfo#9902b940: field photo: %w", err) } if err := b.Animation.Encode(buf); err != nil { - return fmt.Errorf("unable to encode botInfo#32ab8617: field animation: %w", err) + return fmt.Errorf("unable to encode botInfo#9902b940: field animation: %w", err) } if err := b.MenuButton.Encode(buf); err != nil { - return fmt.Errorf("unable to encode botInfo#32ab8617: field menu_button: %w", err) + return fmt.Errorf("unable to encode botInfo#9902b940: field menu_button: %w", err) } buf.PutInt(len(b.Commands)) for idx, v := range b.Commands { if err := v.EncodeBare(buf); err != nil { - return fmt.Errorf("unable to encode bare botInfo#32ab8617: field commands element with index %d: %w", idx, err) + return fmt.Errorf("unable to encode bare botInfo#9902b940: field commands element with index %d: %w", idx, err) } } + buf.PutString(b.PrivacyPolicyURL) if err := b.DefaultGroupAdministratorRights.Encode(buf); err != nil { - return fmt.Errorf("unable to encode botInfo#32ab8617: field default_group_administrator_rights: %w", err) + return fmt.Errorf("unable to encode botInfo#9902b940: field default_group_administrator_rights: %w", err) } if err := b.DefaultChannelAdministratorRights.Encode(buf); err != nil { - return fmt.Errorf("unable to encode botInfo#32ab8617: field default_channel_administrator_rights: %w", err) + return fmt.Errorf("unable to encode botInfo#9902b940: field default_channel_administrator_rights: %w", err) } buf.PutBool(b.HasMediaPreviews) if b.EditCommandsLink == nil { - return fmt.Errorf("unable to encode botInfo#32ab8617: field edit_commands_link is nil") + return fmt.Errorf("unable to encode botInfo#9902b940: field edit_commands_link is nil") } if err := b.EditCommandsLink.Encode(buf); err != nil { - return fmt.Errorf("unable to encode botInfo#32ab8617: field edit_commands_link: %w", err) + return fmt.Errorf("unable to encode botInfo#9902b940: field edit_commands_link: %w", err) } if b.EditDescriptionLink == nil { - return fmt.Errorf("unable to encode botInfo#32ab8617: field edit_description_link is nil") + return fmt.Errorf("unable to encode botInfo#9902b940: field edit_description_link is nil") } if err := b.EditDescriptionLink.Encode(buf); err != nil { - return fmt.Errorf("unable to encode botInfo#32ab8617: field edit_description_link: %w", err) + return fmt.Errorf("unable to encode botInfo#9902b940: field edit_description_link: %w", err) } if b.EditDescriptionMediaLink == nil { - return fmt.Errorf("unable to encode botInfo#32ab8617: field edit_description_media_link is nil") + return fmt.Errorf("unable to encode botInfo#9902b940: field edit_description_media_link is nil") } if err := b.EditDescriptionMediaLink.Encode(buf); err != nil { - return fmt.Errorf("unable to encode botInfo#32ab8617: field edit_description_media_link: %w", err) + return fmt.Errorf("unable to encode botInfo#9902b940: field edit_description_media_link: %w", err) } if b.EditSettingsLink == nil { - return fmt.Errorf("unable to encode botInfo#32ab8617: field edit_settings_link is nil") + return fmt.Errorf("unable to encode botInfo#9902b940: field edit_settings_link is nil") } if err := b.EditSettingsLink.Encode(buf); err != nil { - return fmt.Errorf("unable to encode botInfo#32ab8617: field edit_settings_link: %w", err) + return fmt.Errorf("unable to encode botInfo#9902b940: field edit_settings_link: %w", err) } return nil } @@ -279,10 +291,10 @@ func (b *BotInfo) EncodeBare(buf *bin.Buffer) error { // Decode implements bin.Decoder. func (b *BotInfo) Decode(buf *bin.Buffer) error { if b == nil { - return fmt.Errorf("can't decode botInfo#32ab8617 to nil") + return fmt.Errorf("can't decode botInfo#9902b940 to nil") } if err := buf.ConsumeID(BotInfoTypeID); err != nil { - return fmt.Errorf("unable to decode botInfo#32ab8617: %w", err) + return fmt.Errorf("unable to decode botInfo#9902b940: %w", err) } return b.DecodeBare(buf) } @@ -290,41 +302,41 @@ func (b *BotInfo) Decode(buf *bin.Buffer) error { // DecodeBare implements bin.BareDecoder. func (b *BotInfo) DecodeBare(buf *bin.Buffer) error { if b == nil { - return fmt.Errorf("can't decode botInfo#32ab8617 to nil") + return fmt.Errorf("can't decode botInfo#9902b940 to nil") } { value, err := buf.String() if err != nil { - return fmt.Errorf("unable to decode botInfo#32ab8617: field short_description: %w", err) + return fmt.Errorf("unable to decode botInfo#9902b940: field short_description: %w", err) } b.ShortDescription = value } { value, err := buf.String() if err != nil { - return fmt.Errorf("unable to decode botInfo#32ab8617: field description: %w", err) + return fmt.Errorf("unable to decode botInfo#9902b940: field description: %w", err) } b.Description = value } { if err := b.Photo.Decode(buf); err != nil { - return fmt.Errorf("unable to decode botInfo#32ab8617: field photo: %w", err) + return fmt.Errorf("unable to decode botInfo#9902b940: field photo: %w", err) } } { if err := b.Animation.Decode(buf); err != nil { - return fmt.Errorf("unable to decode botInfo#32ab8617: field animation: %w", err) + return fmt.Errorf("unable to decode botInfo#9902b940: field animation: %w", err) } } { if err := b.MenuButton.Decode(buf); err != nil { - return fmt.Errorf("unable to decode botInfo#32ab8617: field menu_button: %w", err) + return fmt.Errorf("unable to decode botInfo#9902b940: field menu_button: %w", err) } } { headerLen, err := buf.Int() if err != nil { - return fmt.Errorf("unable to decode botInfo#32ab8617: field commands: %w", err) + return fmt.Errorf("unable to decode botInfo#9902b940: field commands: %w", err) } if headerLen > 0 { @@ -333,53 +345,60 @@ func (b *BotInfo) DecodeBare(buf *bin.Buffer) error { for idx := 0; idx < headerLen; idx++ { var value BotCommand if err := value.DecodeBare(buf); err != nil { - return fmt.Errorf("unable to decode bare botInfo#32ab8617: field commands: %w", err) + return fmt.Errorf("unable to decode bare botInfo#9902b940: field commands: %w", err) } b.Commands = append(b.Commands, value) } } + { + value, err := buf.String() + if err != nil { + return fmt.Errorf("unable to decode botInfo#9902b940: field privacy_policy_url: %w", err) + } + b.PrivacyPolicyURL = value + } { if err := b.DefaultGroupAdministratorRights.Decode(buf); err != nil { - return fmt.Errorf("unable to decode botInfo#32ab8617: field default_group_administrator_rights: %w", err) + return fmt.Errorf("unable to decode botInfo#9902b940: field default_group_administrator_rights: %w", err) } } { if err := b.DefaultChannelAdministratorRights.Decode(buf); err != nil { - return fmt.Errorf("unable to decode botInfo#32ab8617: field default_channel_administrator_rights: %w", err) + return fmt.Errorf("unable to decode botInfo#9902b940: field default_channel_administrator_rights: %w", err) } } { value, err := buf.Bool() if err != nil { - return fmt.Errorf("unable to decode botInfo#32ab8617: field has_media_previews: %w", err) + return fmt.Errorf("unable to decode botInfo#9902b940: field has_media_previews: %w", err) } b.HasMediaPreviews = value } { value, err := DecodeInternalLinkType(buf) if err != nil { - return fmt.Errorf("unable to decode botInfo#32ab8617: field edit_commands_link: %w", err) + return fmt.Errorf("unable to decode botInfo#9902b940: field edit_commands_link: %w", err) } b.EditCommandsLink = value } { value, err := DecodeInternalLinkType(buf) if err != nil { - return fmt.Errorf("unable to decode botInfo#32ab8617: field edit_description_link: %w", err) + return fmt.Errorf("unable to decode botInfo#9902b940: field edit_description_link: %w", err) } b.EditDescriptionLink = value } { value, err := DecodeInternalLinkType(buf) if err != nil { - return fmt.Errorf("unable to decode botInfo#32ab8617: field edit_description_media_link: %w", err) + return fmt.Errorf("unable to decode botInfo#9902b940: field edit_description_media_link: %w", err) } b.EditDescriptionMediaLink = value } { value, err := DecodeInternalLinkType(buf) if err != nil { - return fmt.Errorf("unable to decode botInfo#32ab8617: field edit_settings_link: %w", err) + return fmt.Errorf("unable to decode botInfo#9902b940: field edit_settings_link: %w", err) } b.EditSettingsLink = value } @@ -389,7 +408,7 @@ func (b *BotInfo) DecodeBare(buf *bin.Buffer) error { // EncodeTDLibJSON implements tdjson.TDLibEncoder. func (b *BotInfo) EncodeTDLibJSON(buf tdjson.Encoder) error { if b == nil { - return fmt.Errorf("can't encode botInfo#32ab8617 as nil") + return fmt.Errorf("can't encode botInfo#9902b940 as nil") } buf.ObjStart() buf.PutID("botInfo") @@ -402,38 +421,41 @@ func (b *BotInfo) EncodeTDLibJSON(buf tdjson.Encoder) error { buf.Comma() buf.FieldStart("photo") if err := b.Photo.EncodeTDLibJSON(buf); err != nil { - return fmt.Errorf("unable to encode botInfo#32ab8617: field photo: %w", err) + return fmt.Errorf("unable to encode botInfo#9902b940: field photo: %w", err) } buf.Comma() buf.FieldStart("animation") if err := b.Animation.EncodeTDLibJSON(buf); err != nil { - return fmt.Errorf("unable to encode botInfo#32ab8617: field animation: %w", err) + return fmt.Errorf("unable to encode botInfo#9902b940: field animation: %w", err) } buf.Comma() buf.FieldStart("menu_button") if err := b.MenuButton.EncodeTDLibJSON(buf); err != nil { - return fmt.Errorf("unable to encode botInfo#32ab8617: field menu_button: %w", err) + return fmt.Errorf("unable to encode botInfo#9902b940: field menu_button: %w", err) } buf.Comma() buf.FieldStart("commands") buf.ArrStart() for idx, v := range b.Commands { if err := v.EncodeTDLibJSON(buf); err != nil { - return fmt.Errorf("unable to encode botInfo#32ab8617: field commands element with index %d: %w", idx, err) + return fmt.Errorf("unable to encode botInfo#9902b940: field commands element with index %d: %w", idx, err) } buf.Comma() } buf.StripComma() buf.ArrEnd() buf.Comma() + buf.FieldStart("privacy_policy_url") + buf.PutString(b.PrivacyPolicyURL) + buf.Comma() buf.FieldStart("default_group_administrator_rights") if err := b.DefaultGroupAdministratorRights.EncodeTDLibJSON(buf); err != nil { - return fmt.Errorf("unable to encode botInfo#32ab8617: field default_group_administrator_rights: %w", err) + return fmt.Errorf("unable to encode botInfo#9902b940: field default_group_administrator_rights: %w", err) } buf.Comma() buf.FieldStart("default_channel_administrator_rights") if err := b.DefaultChannelAdministratorRights.EncodeTDLibJSON(buf); err != nil { - return fmt.Errorf("unable to encode botInfo#32ab8617: field default_channel_administrator_rights: %w", err) + return fmt.Errorf("unable to encode botInfo#9902b940: field default_channel_administrator_rights: %w", err) } buf.Comma() buf.FieldStart("has_media_previews") @@ -441,34 +463,34 @@ func (b *BotInfo) EncodeTDLibJSON(buf tdjson.Encoder) error { buf.Comma() buf.FieldStart("edit_commands_link") if b.EditCommandsLink == nil { - return fmt.Errorf("unable to encode botInfo#32ab8617: field edit_commands_link is nil") + return fmt.Errorf("unable to encode botInfo#9902b940: field edit_commands_link is nil") } if err := b.EditCommandsLink.EncodeTDLibJSON(buf); err != nil { - return fmt.Errorf("unable to encode botInfo#32ab8617: field edit_commands_link: %w", err) + return fmt.Errorf("unable to encode botInfo#9902b940: field edit_commands_link: %w", err) } buf.Comma() buf.FieldStart("edit_description_link") if b.EditDescriptionLink == nil { - return fmt.Errorf("unable to encode botInfo#32ab8617: field edit_description_link is nil") + return fmt.Errorf("unable to encode botInfo#9902b940: field edit_description_link is nil") } if err := b.EditDescriptionLink.EncodeTDLibJSON(buf); err != nil { - return fmt.Errorf("unable to encode botInfo#32ab8617: field edit_description_link: %w", err) + return fmt.Errorf("unable to encode botInfo#9902b940: field edit_description_link: %w", err) } buf.Comma() buf.FieldStart("edit_description_media_link") if b.EditDescriptionMediaLink == nil { - return fmt.Errorf("unable to encode botInfo#32ab8617: field edit_description_media_link is nil") + return fmt.Errorf("unable to encode botInfo#9902b940: field edit_description_media_link is nil") } if err := b.EditDescriptionMediaLink.EncodeTDLibJSON(buf); err != nil { - return fmt.Errorf("unable to encode botInfo#32ab8617: field edit_description_media_link: %w", err) + return fmt.Errorf("unable to encode botInfo#9902b940: field edit_description_media_link: %w", err) } buf.Comma() buf.FieldStart("edit_settings_link") if b.EditSettingsLink == nil { - return fmt.Errorf("unable to encode botInfo#32ab8617: field edit_settings_link is nil") + return fmt.Errorf("unable to encode botInfo#9902b940: field edit_settings_link is nil") } if err := b.EditSettingsLink.EncodeTDLibJSON(buf); err != nil { - return fmt.Errorf("unable to encode botInfo#32ab8617: field edit_settings_link: %w", err) + return fmt.Errorf("unable to encode botInfo#9902b940: field edit_settings_link: %w", err) } buf.Comma() buf.StripComma() @@ -479,86 +501,92 @@ func (b *BotInfo) EncodeTDLibJSON(buf tdjson.Encoder) error { // DecodeTDLibJSON implements tdjson.TDLibDecoder. func (b *BotInfo) DecodeTDLibJSON(buf tdjson.Decoder) error { if b == nil { - return fmt.Errorf("can't decode botInfo#32ab8617 to nil") + return fmt.Errorf("can't decode botInfo#9902b940 to nil") } return buf.Obj(func(buf tdjson.Decoder, key []byte) error { switch string(key) { case tdjson.TypeField: if err := buf.ConsumeID("botInfo"); err != nil { - return fmt.Errorf("unable to decode botInfo#32ab8617: %w", err) + return fmt.Errorf("unable to decode botInfo#9902b940: %w", err) } case "short_description": value, err := buf.String() if err != nil { - return fmt.Errorf("unable to decode botInfo#32ab8617: field short_description: %w", err) + return fmt.Errorf("unable to decode botInfo#9902b940: field short_description: %w", err) } b.ShortDescription = value case "description": value, err := buf.String() if err != nil { - return fmt.Errorf("unable to decode botInfo#32ab8617: field description: %w", err) + return fmt.Errorf("unable to decode botInfo#9902b940: field description: %w", err) } b.Description = value case "photo": if err := b.Photo.DecodeTDLibJSON(buf); err != nil { - return fmt.Errorf("unable to decode botInfo#32ab8617: field photo: %w", err) + return fmt.Errorf("unable to decode botInfo#9902b940: field photo: %w", err) } case "animation": if err := b.Animation.DecodeTDLibJSON(buf); err != nil { - return fmt.Errorf("unable to decode botInfo#32ab8617: field animation: %w", err) + return fmt.Errorf("unable to decode botInfo#9902b940: field animation: %w", err) } case "menu_button": if err := b.MenuButton.DecodeTDLibJSON(buf); err != nil { - return fmt.Errorf("unable to decode botInfo#32ab8617: field menu_button: %w", err) + return fmt.Errorf("unable to decode botInfo#9902b940: field menu_button: %w", err) } case "commands": if err := buf.Arr(func(buf tdjson.Decoder) error { var value BotCommand if err := value.DecodeTDLibJSON(buf); err != nil { - return fmt.Errorf("unable to decode botInfo#32ab8617: field commands: %w", err) + return fmt.Errorf("unable to decode botInfo#9902b940: field commands: %w", err) } b.Commands = append(b.Commands, value) return nil }); err != nil { - return fmt.Errorf("unable to decode botInfo#32ab8617: field commands: %w", err) + return fmt.Errorf("unable to decode botInfo#9902b940: field commands: %w", err) } + case "privacy_policy_url": + value, err := buf.String() + if err != nil { + return fmt.Errorf("unable to decode botInfo#9902b940: field privacy_policy_url: %w", err) + } + b.PrivacyPolicyURL = value case "default_group_administrator_rights": if err := b.DefaultGroupAdministratorRights.DecodeTDLibJSON(buf); err != nil { - return fmt.Errorf("unable to decode botInfo#32ab8617: field default_group_administrator_rights: %w", err) + return fmt.Errorf("unable to decode botInfo#9902b940: field default_group_administrator_rights: %w", err) } case "default_channel_administrator_rights": if err := b.DefaultChannelAdministratorRights.DecodeTDLibJSON(buf); err != nil { - return fmt.Errorf("unable to decode botInfo#32ab8617: field default_channel_administrator_rights: %w", err) + return fmt.Errorf("unable to decode botInfo#9902b940: field default_channel_administrator_rights: %w", err) } case "has_media_previews": value, err := buf.Bool() if err != nil { - return fmt.Errorf("unable to decode botInfo#32ab8617: field has_media_previews: %w", err) + return fmt.Errorf("unable to decode botInfo#9902b940: field has_media_previews: %w", err) } b.HasMediaPreviews = value case "edit_commands_link": value, err := DecodeTDLibJSONInternalLinkType(buf) if err != nil { - return fmt.Errorf("unable to decode botInfo#32ab8617: field edit_commands_link: %w", err) + return fmt.Errorf("unable to decode botInfo#9902b940: field edit_commands_link: %w", err) } b.EditCommandsLink = value case "edit_description_link": value, err := DecodeTDLibJSONInternalLinkType(buf) if err != nil { - return fmt.Errorf("unable to decode botInfo#32ab8617: field edit_description_link: %w", err) + return fmt.Errorf("unable to decode botInfo#9902b940: field edit_description_link: %w", err) } b.EditDescriptionLink = value case "edit_description_media_link": value, err := DecodeTDLibJSONInternalLinkType(buf) if err != nil { - return fmt.Errorf("unable to decode botInfo#32ab8617: field edit_description_media_link: %w", err) + return fmt.Errorf("unable to decode botInfo#9902b940: field edit_description_media_link: %w", err) } b.EditDescriptionMediaLink = value case "edit_settings_link": value, err := DecodeTDLibJSONInternalLinkType(buf) if err != nil { - return fmt.Errorf("unable to decode botInfo#32ab8617: field edit_settings_link: %w", err) + return fmt.Errorf("unable to decode botInfo#9902b940: field edit_settings_link: %w", err) } b.EditSettingsLink = value default: @@ -616,6 +644,14 @@ func (b *BotInfo) GetCommands() (value []BotCommand) { return b.Commands } +// GetPrivacyPolicyURL returns value of PrivacyPolicyURL field. +func (b *BotInfo) GetPrivacyPolicyURL() (value string) { + if b == nil { + return + } + return b.PrivacyPolicyURL +} + // GetDefaultGroupAdministratorRights returns value of DefaultGroupAdministratorRights field. func (b *BotInfo) GetDefaultGroupAdministratorRights() (value ChatAdministratorRights) { if b == nil { diff --git a/tdapi/tl_bot_transaction_purpose_gen.go b/tdapi/tl_bot_transaction_purpose_gen.go new file mode 100644 index 0000000000..a97b33c35c --- /dev/null +++ b/tdapi/tl_bot_transaction_purpose_gen.go @@ -0,0 +1,569 @@ +// Code generated by gotdgen, DO NOT EDIT. + +package tdapi + +import ( + "context" + "errors" + "fmt" + "sort" + "strings" + + "go.uber.org/multierr" + + "github.com/gotd/td/bin" + "github.com/gotd/td/tdjson" + "github.com/gotd/td/tdp" + "github.com/gotd/td/tgerr" +) + +// No-op definition for keeping imports. +var ( + _ = bin.Buffer{} + _ = context.Background() + _ = fmt.Stringer(nil) + _ = strings.Builder{} + _ = errors.Is + _ = multierr.AppendInto + _ = sort.Ints + _ = tdp.Format + _ = tgerr.Error{} + _ = tdjson.Encoder{} +) + +// BotTransactionPurposePaidMedia represents TL type `botTransactionPurposePaidMedia#9593b72f`. +type BotTransactionPurposePaidMedia struct { + // The bought media if the trancastion wasn't refunded + Media []PaidMediaClass +} + +// BotTransactionPurposePaidMediaTypeID is TL type id of BotTransactionPurposePaidMedia. +const BotTransactionPurposePaidMediaTypeID = 0x9593b72f + +// construct implements constructor of BotTransactionPurposeClass. +func (b BotTransactionPurposePaidMedia) construct() BotTransactionPurposeClass { return &b } + +// Ensuring interfaces in compile-time for BotTransactionPurposePaidMedia. +var ( + _ bin.Encoder = &BotTransactionPurposePaidMedia{} + _ bin.Decoder = &BotTransactionPurposePaidMedia{} + _ bin.BareEncoder = &BotTransactionPurposePaidMedia{} + _ bin.BareDecoder = &BotTransactionPurposePaidMedia{} + + _ BotTransactionPurposeClass = &BotTransactionPurposePaidMedia{} +) + +func (b *BotTransactionPurposePaidMedia) Zero() bool { + if b == nil { + return true + } + if !(b.Media == nil) { + return false + } + + return true +} + +// String implements fmt.Stringer. +func (b *BotTransactionPurposePaidMedia) String() string { + if b == nil { + return "BotTransactionPurposePaidMedia(nil)" + } + type Alias BotTransactionPurposePaidMedia + return fmt.Sprintf("BotTransactionPurposePaidMedia%+v", Alias(*b)) +} + +// TypeID returns type id in TL schema. +// +// See https://core.telegram.org/mtproto/TL-tl#remarks. +func (*BotTransactionPurposePaidMedia) TypeID() uint32 { + return BotTransactionPurposePaidMediaTypeID +} + +// TypeName returns name of type in TL schema. +func (*BotTransactionPurposePaidMedia) TypeName() string { + return "botTransactionPurposePaidMedia" +} + +// TypeInfo returns info about TL type. +func (b *BotTransactionPurposePaidMedia) TypeInfo() tdp.Type { + typ := tdp.Type{ + Name: "botTransactionPurposePaidMedia", + ID: BotTransactionPurposePaidMediaTypeID, + } + if b == nil { + typ.Null = true + return typ + } + typ.Fields = []tdp.Field{ + { + Name: "Media", + SchemaName: "media", + }, + } + return typ +} + +// Encode implements bin.Encoder. +func (b *BotTransactionPurposePaidMedia) Encode(buf *bin.Buffer) error { + if b == nil { + return fmt.Errorf("can't encode botTransactionPurposePaidMedia#9593b72f as nil") + } + buf.PutID(BotTransactionPurposePaidMediaTypeID) + return b.EncodeBare(buf) +} + +// EncodeBare implements bin.BareEncoder. +func (b *BotTransactionPurposePaidMedia) EncodeBare(buf *bin.Buffer) error { + if b == nil { + return fmt.Errorf("can't encode botTransactionPurposePaidMedia#9593b72f as nil") + } + buf.PutInt(len(b.Media)) + for idx, v := range b.Media { + if v == nil { + return fmt.Errorf("unable to encode botTransactionPurposePaidMedia#9593b72f: field media element with index %d is nil", idx) + } + if err := v.EncodeBare(buf); err != nil { + return fmt.Errorf("unable to encode bare botTransactionPurposePaidMedia#9593b72f: field media element with index %d: %w", idx, err) + } + } + return nil +} + +// Decode implements bin.Decoder. +func (b *BotTransactionPurposePaidMedia) Decode(buf *bin.Buffer) error { + if b == nil { + return fmt.Errorf("can't decode botTransactionPurposePaidMedia#9593b72f to nil") + } + if err := buf.ConsumeID(BotTransactionPurposePaidMediaTypeID); err != nil { + return fmt.Errorf("unable to decode botTransactionPurposePaidMedia#9593b72f: %w", err) + } + return b.DecodeBare(buf) +} + +// DecodeBare implements bin.BareDecoder. +func (b *BotTransactionPurposePaidMedia) DecodeBare(buf *bin.Buffer) error { + if b == nil { + return fmt.Errorf("can't decode botTransactionPurposePaidMedia#9593b72f to nil") + } + { + headerLen, err := buf.Int() + if err != nil { + return fmt.Errorf("unable to decode botTransactionPurposePaidMedia#9593b72f: field media: %w", err) + } + + if headerLen > 0 { + b.Media = make([]PaidMediaClass, 0, headerLen%bin.PreallocateLimit) + } + for idx := 0; idx < headerLen; idx++ { + value, err := DecodePaidMedia(buf) + if err != nil { + return fmt.Errorf("unable to decode botTransactionPurposePaidMedia#9593b72f: field media: %w", err) + } + b.Media = append(b.Media, value) + } + } + return nil +} + +// EncodeTDLibJSON implements tdjson.TDLibEncoder. +func (b *BotTransactionPurposePaidMedia) EncodeTDLibJSON(buf tdjson.Encoder) error { + if b == nil { + return fmt.Errorf("can't encode botTransactionPurposePaidMedia#9593b72f as nil") + } + buf.ObjStart() + buf.PutID("botTransactionPurposePaidMedia") + buf.Comma() + buf.FieldStart("media") + buf.ArrStart() + for idx, v := range b.Media { + if v == nil { + return fmt.Errorf("unable to encode botTransactionPurposePaidMedia#9593b72f: field media element with index %d is nil", idx) + } + if err := v.EncodeTDLibJSON(buf); err != nil { + return fmt.Errorf("unable to encode botTransactionPurposePaidMedia#9593b72f: field media element with index %d: %w", idx, err) + } + buf.Comma() + } + buf.StripComma() + buf.ArrEnd() + buf.Comma() + buf.StripComma() + buf.ObjEnd() + return nil +} + +// DecodeTDLibJSON implements tdjson.TDLibDecoder. +func (b *BotTransactionPurposePaidMedia) DecodeTDLibJSON(buf tdjson.Decoder) error { + if b == nil { + return fmt.Errorf("can't decode botTransactionPurposePaidMedia#9593b72f to nil") + } + + return buf.Obj(func(buf tdjson.Decoder, key []byte) error { + switch string(key) { + case tdjson.TypeField: + if err := buf.ConsumeID("botTransactionPurposePaidMedia"); err != nil { + return fmt.Errorf("unable to decode botTransactionPurposePaidMedia#9593b72f: %w", err) + } + case "media": + if err := buf.Arr(func(buf tdjson.Decoder) error { + value, err := DecodeTDLibJSONPaidMedia(buf) + if err != nil { + return fmt.Errorf("unable to decode botTransactionPurposePaidMedia#9593b72f: field media: %w", err) + } + b.Media = append(b.Media, value) + return nil + }); err != nil { + return fmt.Errorf("unable to decode botTransactionPurposePaidMedia#9593b72f: field media: %w", err) + } + default: + return buf.Skip() + } + return nil + }) +} + +// GetMedia returns value of Media field. +func (b *BotTransactionPurposePaidMedia) GetMedia() (value []PaidMediaClass) { + if b == nil { + return + } + return b.Media +} + +// BotTransactionPurposeInvoicePayment represents TL type `botTransactionPurposeInvoicePayment#699860ac`. +type BotTransactionPurposeInvoicePayment struct { + // Information about the bought product; may be null if not applicable + ProductInfo ProductInfo + // Invoice payload; for bots only + InvoicePayload []byte +} + +// BotTransactionPurposeInvoicePaymentTypeID is TL type id of BotTransactionPurposeInvoicePayment. +const BotTransactionPurposeInvoicePaymentTypeID = 0x699860ac + +// construct implements constructor of BotTransactionPurposeClass. +func (b BotTransactionPurposeInvoicePayment) construct() BotTransactionPurposeClass { return &b } + +// Ensuring interfaces in compile-time for BotTransactionPurposeInvoicePayment. +var ( + _ bin.Encoder = &BotTransactionPurposeInvoicePayment{} + _ bin.Decoder = &BotTransactionPurposeInvoicePayment{} + _ bin.BareEncoder = &BotTransactionPurposeInvoicePayment{} + _ bin.BareDecoder = &BotTransactionPurposeInvoicePayment{} + + _ BotTransactionPurposeClass = &BotTransactionPurposeInvoicePayment{} +) + +func (b *BotTransactionPurposeInvoicePayment) Zero() bool { + if b == nil { + return true + } + if !(b.ProductInfo.Zero()) { + return false + } + if !(b.InvoicePayload == nil) { + return false + } + + return true +} + +// String implements fmt.Stringer. +func (b *BotTransactionPurposeInvoicePayment) String() string { + if b == nil { + return "BotTransactionPurposeInvoicePayment(nil)" + } + type Alias BotTransactionPurposeInvoicePayment + return fmt.Sprintf("BotTransactionPurposeInvoicePayment%+v", Alias(*b)) +} + +// TypeID returns type id in TL schema. +// +// See https://core.telegram.org/mtproto/TL-tl#remarks. +func (*BotTransactionPurposeInvoicePayment) TypeID() uint32 { + return BotTransactionPurposeInvoicePaymentTypeID +} + +// TypeName returns name of type in TL schema. +func (*BotTransactionPurposeInvoicePayment) TypeName() string { + return "botTransactionPurposeInvoicePayment" +} + +// TypeInfo returns info about TL type. +func (b *BotTransactionPurposeInvoicePayment) TypeInfo() tdp.Type { + typ := tdp.Type{ + Name: "botTransactionPurposeInvoicePayment", + ID: BotTransactionPurposeInvoicePaymentTypeID, + } + if b == nil { + typ.Null = true + return typ + } + typ.Fields = []tdp.Field{ + { + Name: "ProductInfo", + SchemaName: "product_info", + }, + { + Name: "InvoicePayload", + SchemaName: "invoice_payload", + }, + } + return typ +} + +// Encode implements bin.Encoder. +func (b *BotTransactionPurposeInvoicePayment) Encode(buf *bin.Buffer) error { + if b == nil { + return fmt.Errorf("can't encode botTransactionPurposeInvoicePayment#699860ac as nil") + } + buf.PutID(BotTransactionPurposeInvoicePaymentTypeID) + return b.EncodeBare(buf) +} + +// EncodeBare implements bin.BareEncoder. +func (b *BotTransactionPurposeInvoicePayment) EncodeBare(buf *bin.Buffer) error { + if b == nil { + return fmt.Errorf("can't encode botTransactionPurposeInvoicePayment#699860ac as nil") + } + if err := b.ProductInfo.Encode(buf); err != nil { + return fmt.Errorf("unable to encode botTransactionPurposeInvoicePayment#699860ac: field product_info: %w", err) + } + buf.PutBytes(b.InvoicePayload) + return nil +} + +// Decode implements bin.Decoder. +func (b *BotTransactionPurposeInvoicePayment) Decode(buf *bin.Buffer) error { + if b == nil { + return fmt.Errorf("can't decode botTransactionPurposeInvoicePayment#699860ac to nil") + } + if err := buf.ConsumeID(BotTransactionPurposeInvoicePaymentTypeID); err != nil { + return fmt.Errorf("unable to decode botTransactionPurposeInvoicePayment#699860ac: %w", err) + } + return b.DecodeBare(buf) +} + +// DecodeBare implements bin.BareDecoder. +func (b *BotTransactionPurposeInvoicePayment) DecodeBare(buf *bin.Buffer) error { + if b == nil { + return fmt.Errorf("can't decode botTransactionPurposeInvoicePayment#699860ac to nil") + } + { + if err := b.ProductInfo.Decode(buf); err != nil { + return fmt.Errorf("unable to decode botTransactionPurposeInvoicePayment#699860ac: field product_info: %w", err) + } + } + { + value, err := buf.Bytes() + if err != nil { + return fmt.Errorf("unable to decode botTransactionPurposeInvoicePayment#699860ac: field invoice_payload: %w", err) + } + b.InvoicePayload = value + } + return nil +} + +// EncodeTDLibJSON implements tdjson.TDLibEncoder. +func (b *BotTransactionPurposeInvoicePayment) EncodeTDLibJSON(buf tdjson.Encoder) error { + if b == nil { + return fmt.Errorf("can't encode botTransactionPurposeInvoicePayment#699860ac as nil") + } + buf.ObjStart() + buf.PutID("botTransactionPurposeInvoicePayment") + buf.Comma() + buf.FieldStart("product_info") + if err := b.ProductInfo.EncodeTDLibJSON(buf); err != nil { + return fmt.Errorf("unable to encode botTransactionPurposeInvoicePayment#699860ac: field product_info: %w", err) + } + buf.Comma() + buf.FieldStart("invoice_payload") + buf.PutBytes(b.InvoicePayload) + buf.Comma() + buf.StripComma() + buf.ObjEnd() + return nil +} + +// DecodeTDLibJSON implements tdjson.TDLibDecoder. +func (b *BotTransactionPurposeInvoicePayment) DecodeTDLibJSON(buf tdjson.Decoder) error { + if b == nil { + return fmt.Errorf("can't decode botTransactionPurposeInvoicePayment#699860ac to nil") + } + + return buf.Obj(func(buf tdjson.Decoder, key []byte) error { + switch string(key) { + case tdjson.TypeField: + if err := buf.ConsumeID("botTransactionPurposeInvoicePayment"); err != nil { + return fmt.Errorf("unable to decode botTransactionPurposeInvoicePayment#699860ac: %w", err) + } + case "product_info": + if err := b.ProductInfo.DecodeTDLibJSON(buf); err != nil { + return fmt.Errorf("unable to decode botTransactionPurposeInvoicePayment#699860ac: field product_info: %w", err) + } + case "invoice_payload": + value, err := buf.Bytes() + if err != nil { + return fmt.Errorf("unable to decode botTransactionPurposeInvoicePayment#699860ac: field invoice_payload: %w", err) + } + b.InvoicePayload = value + default: + return buf.Skip() + } + return nil + }) +} + +// GetProductInfo returns value of ProductInfo field. +func (b *BotTransactionPurposeInvoicePayment) GetProductInfo() (value ProductInfo) { + if b == nil { + return + } + return b.ProductInfo +} + +// GetInvoicePayload returns value of InvoicePayload field. +func (b *BotTransactionPurposeInvoicePayment) GetInvoicePayload() (value []byte) { + if b == nil { + return + } + return b.InvoicePayload +} + +// BotTransactionPurposeClassName is schema name of BotTransactionPurposeClass. +const BotTransactionPurposeClassName = "BotTransactionPurpose" + +// BotTransactionPurposeClass represents BotTransactionPurpose generic type. +// +// Example: +// +// g, err := tdapi.DecodeBotTransactionPurpose(buf) +// if err != nil { +// panic(err) +// } +// switch v := g.(type) { +// case *tdapi.BotTransactionPurposePaidMedia: // botTransactionPurposePaidMedia#9593b72f +// case *tdapi.BotTransactionPurposeInvoicePayment: // botTransactionPurposeInvoicePayment#699860ac +// default: panic(v) +// } +type BotTransactionPurposeClass interface { + bin.Encoder + bin.Decoder + bin.BareEncoder + bin.BareDecoder + construct() BotTransactionPurposeClass + + // TypeID returns type id in TL schema. + // + // See https://core.telegram.org/mtproto/TL-tl#remarks. + TypeID() uint32 + // TypeName returns name of type in TL schema. + TypeName() string + // String implements fmt.Stringer. + String() string + // Zero returns true if current object has a zero value. + Zero() bool + + EncodeTDLibJSON(b tdjson.Encoder) error + DecodeTDLibJSON(b tdjson.Decoder) error +} + +// DecodeBotTransactionPurpose implements binary de-serialization for BotTransactionPurposeClass. +func DecodeBotTransactionPurpose(buf *bin.Buffer) (BotTransactionPurposeClass, error) { + id, err := buf.PeekID() + if err != nil { + return nil, err + } + switch id { + case BotTransactionPurposePaidMediaTypeID: + // Decoding botTransactionPurposePaidMedia#9593b72f. + v := BotTransactionPurposePaidMedia{} + if err := v.Decode(buf); err != nil { + return nil, fmt.Errorf("unable to decode BotTransactionPurposeClass: %w", err) + } + return &v, nil + case BotTransactionPurposeInvoicePaymentTypeID: + // Decoding botTransactionPurposeInvoicePayment#699860ac. + v := BotTransactionPurposeInvoicePayment{} + if err := v.Decode(buf); err != nil { + return nil, fmt.Errorf("unable to decode BotTransactionPurposeClass: %w", err) + } + return &v, nil + default: + return nil, fmt.Errorf("unable to decode BotTransactionPurposeClass: %w", bin.NewUnexpectedID(id)) + } +} + +// DecodeTDLibJSONBotTransactionPurpose implements binary de-serialization for BotTransactionPurposeClass. +func DecodeTDLibJSONBotTransactionPurpose(buf tdjson.Decoder) (BotTransactionPurposeClass, error) { + id, err := buf.FindTypeID() + if err != nil { + return nil, err + } + switch id { + case "botTransactionPurposePaidMedia": + // Decoding botTransactionPurposePaidMedia#9593b72f. + v := BotTransactionPurposePaidMedia{} + if err := v.DecodeTDLibJSON(buf); err != nil { + return nil, fmt.Errorf("unable to decode BotTransactionPurposeClass: %w", err) + } + return &v, nil + case "botTransactionPurposeInvoicePayment": + // Decoding botTransactionPurposeInvoicePayment#699860ac. + v := BotTransactionPurposeInvoicePayment{} + if err := v.DecodeTDLibJSON(buf); err != nil { + return nil, fmt.Errorf("unable to decode BotTransactionPurposeClass: %w", err) + } + return &v, nil + default: + return nil, fmt.Errorf("unable to decode BotTransactionPurposeClass: %w", tdjson.NewUnexpectedID(id)) + } +} + +// BotTransactionPurpose boxes the BotTransactionPurposeClass providing a helper. +type BotTransactionPurposeBox struct { + BotTransactionPurpose BotTransactionPurposeClass +} + +// Decode implements bin.Decoder for BotTransactionPurposeBox. +func (b *BotTransactionPurposeBox) Decode(buf *bin.Buffer) error { + if b == nil { + return fmt.Errorf("unable to decode BotTransactionPurposeBox to nil") + } + v, err := DecodeBotTransactionPurpose(buf) + if err != nil { + return fmt.Errorf("unable to decode boxed value: %w", err) + } + b.BotTransactionPurpose = v + return nil +} + +// Encode implements bin.Encode for BotTransactionPurposeBox. +func (b *BotTransactionPurposeBox) Encode(buf *bin.Buffer) error { + if b == nil || b.BotTransactionPurpose == nil { + return fmt.Errorf("unable to encode BotTransactionPurposeClass as nil") + } + return b.BotTransactionPurpose.Encode(buf) +} + +// DecodeTDLibJSON implements bin.Decoder for BotTransactionPurposeBox. +func (b *BotTransactionPurposeBox) DecodeTDLibJSON(buf tdjson.Decoder) error { + if b == nil { + return fmt.Errorf("unable to decode BotTransactionPurposeBox to nil") + } + v, err := DecodeTDLibJSONBotTransactionPurpose(buf) + if err != nil { + return fmt.Errorf("unable to decode boxed value: %w", err) + } + b.BotTransactionPurpose = v + return nil +} + +// EncodeTDLibJSON implements bin.Encode for BotTransactionPurposeBox. +func (b *BotTransactionPurposeBox) EncodeTDLibJSON(buf tdjson.Encoder) error { + if b == nil || b.BotTransactionPurpose == nil { + return fmt.Errorf("unable to encode BotTransactionPurposeClass as nil") + } + return b.BotTransactionPurpose.EncodeTDLibJSON(buf) +} diff --git a/tdapi/tl_channel_transaction_purpose_gen.go b/tdapi/tl_channel_transaction_purpose_gen.go new file mode 100644 index 0000000000..dd4541d4e9 --- /dev/null +++ b/tdapi/tl_channel_transaction_purpose_gen.go @@ -0,0 +1,751 @@ +// Code generated by gotdgen, DO NOT EDIT. + +package tdapi + +import ( + "context" + "errors" + "fmt" + "sort" + "strings" + + "go.uber.org/multierr" + + "github.com/gotd/td/bin" + "github.com/gotd/td/tdjson" + "github.com/gotd/td/tdp" + "github.com/gotd/td/tgerr" +) + +// No-op definition for keeping imports. +var ( + _ = bin.Buffer{} + _ = context.Background() + _ = fmt.Stringer(nil) + _ = strings.Builder{} + _ = errors.Is + _ = multierr.AppendInto + _ = sort.Ints + _ = tdp.Format + _ = tgerr.Error{} + _ = tdjson.Encoder{} +) + +// ChannelTransactionPurposePaidMedia represents TL type `channelTransactionPurposePaidMedia#b00b2258`. +type ChannelTransactionPurposePaidMedia struct { + // Identifier of the corresponding message with paid media; can be an identifier of a + // deleted message + MessageID int64 + // The bought media if the trancastion wasn't refunded + Media []PaidMediaClass +} + +// ChannelTransactionPurposePaidMediaTypeID is TL type id of ChannelTransactionPurposePaidMedia. +const ChannelTransactionPurposePaidMediaTypeID = 0xb00b2258 + +// construct implements constructor of ChannelTransactionPurposeClass. +func (c ChannelTransactionPurposePaidMedia) construct() ChannelTransactionPurposeClass { return &c } + +// Ensuring interfaces in compile-time for ChannelTransactionPurposePaidMedia. +var ( + _ bin.Encoder = &ChannelTransactionPurposePaidMedia{} + _ bin.Decoder = &ChannelTransactionPurposePaidMedia{} + _ bin.BareEncoder = &ChannelTransactionPurposePaidMedia{} + _ bin.BareDecoder = &ChannelTransactionPurposePaidMedia{} + + _ ChannelTransactionPurposeClass = &ChannelTransactionPurposePaidMedia{} +) + +func (c *ChannelTransactionPurposePaidMedia) Zero() bool { + if c == nil { + return true + } + if !(c.MessageID == 0) { + return false + } + if !(c.Media == nil) { + return false + } + + return true +} + +// String implements fmt.Stringer. +func (c *ChannelTransactionPurposePaidMedia) String() string { + if c == nil { + return "ChannelTransactionPurposePaidMedia(nil)" + } + type Alias ChannelTransactionPurposePaidMedia + return fmt.Sprintf("ChannelTransactionPurposePaidMedia%+v", Alias(*c)) +} + +// TypeID returns type id in TL schema. +// +// See https://core.telegram.org/mtproto/TL-tl#remarks. +func (*ChannelTransactionPurposePaidMedia) TypeID() uint32 { + return ChannelTransactionPurposePaidMediaTypeID +} + +// TypeName returns name of type in TL schema. +func (*ChannelTransactionPurposePaidMedia) TypeName() string { + return "channelTransactionPurposePaidMedia" +} + +// TypeInfo returns info about TL type. +func (c *ChannelTransactionPurposePaidMedia) TypeInfo() tdp.Type { + typ := tdp.Type{ + Name: "channelTransactionPurposePaidMedia", + ID: ChannelTransactionPurposePaidMediaTypeID, + } + if c == nil { + typ.Null = true + return typ + } + typ.Fields = []tdp.Field{ + { + Name: "MessageID", + SchemaName: "message_id", + }, + { + Name: "Media", + SchemaName: "media", + }, + } + return typ +} + +// Encode implements bin.Encoder. +func (c *ChannelTransactionPurposePaidMedia) Encode(b *bin.Buffer) error { + if c == nil { + return fmt.Errorf("can't encode channelTransactionPurposePaidMedia#b00b2258 as nil") + } + b.PutID(ChannelTransactionPurposePaidMediaTypeID) + return c.EncodeBare(b) +} + +// EncodeBare implements bin.BareEncoder. +func (c *ChannelTransactionPurposePaidMedia) EncodeBare(b *bin.Buffer) error { + if c == nil { + return fmt.Errorf("can't encode channelTransactionPurposePaidMedia#b00b2258 as nil") + } + b.PutInt53(c.MessageID) + b.PutInt(len(c.Media)) + for idx, v := range c.Media { + if v == nil { + return fmt.Errorf("unable to encode channelTransactionPurposePaidMedia#b00b2258: field media element with index %d is nil", idx) + } + if err := v.EncodeBare(b); err != nil { + return fmt.Errorf("unable to encode bare channelTransactionPurposePaidMedia#b00b2258: field media element with index %d: %w", idx, err) + } + } + return nil +} + +// Decode implements bin.Decoder. +func (c *ChannelTransactionPurposePaidMedia) Decode(b *bin.Buffer) error { + if c == nil { + return fmt.Errorf("can't decode channelTransactionPurposePaidMedia#b00b2258 to nil") + } + if err := b.ConsumeID(ChannelTransactionPurposePaidMediaTypeID); err != nil { + return fmt.Errorf("unable to decode channelTransactionPurposePaidMedia#b00b2258: %w", err) + } + return c.DecodeBare(b) +} + +// DecodeBare implements bin.BareDecoder. +func (c *ChannelTransactionPurposePaidMedia) DecodeBare(b *bin.Buffer) error { + if c == nil { + return fmt.Errorf("can't decode channelTransactionPurposePaidMedia#b00b2258 to nil") + } + { + value, err := b.Int53() + if err != nil { + return fmt.Errorf("unable to decode channelTransactionPurposePaidMedia#b00b2258: field message_id: %w", err) + } + c.MessageID = value + } + { + headerLen, err := b.Int() + if err != nil { + return fmt.Errorf("unable to decode channelTransactionPurposePaidMedia#b00b2258: field media: %w", err) + } + + if headerLen > 0 { + c.Media = make([]PaidMediaClass, 0, headerLen%bin.PreallocateLimit) + } + for idx := 0; idx < headerLen; idx++ { + value, err := DecodePaidMedia(b) + if err != nil { + return fmt.Errorf("unable to decode channelTransactionPurposePaidMedia#b00b2258: field media: %w", err) + } + c.Media = append(c.Media, value) + } + } + return nil +} + +// EncodeTDLibJSON implements tdjson.TDLibEncoder. +func (c *ChannelTransactionPurposePaidMedia) EncodeTDLibJSON(b tdjson.Encoder) error { + if c == nil { + return fmt.Errorf("can't encode channelTransactionPurposePaidMedia#b00b2258 as nil") + } + b.ObjStart() + b.PutID("channelTransactionPurposePaidMedia") + b.Comma() + b.FieldStart("message_id") + b.PutInt53(c.MessageID) + b.Comma() + b.FieldStart("media") + b.ArrStart() + for idx, v := range c.Media { + if v == nil { + return fmt.Errorf("unable to encode channelTransactionPurposePaidMedia#b00b2258: field media element with index %d is nil", idx) + } + if err := v.EncodeTDLibJSON(b); err != nil { + return fmt.Errorf("unable to encode channelTransactionPurposePaidMedia#b00b2258: field media element with index %d: %w", idx, err) + } + b.Comma() + } + b.StripComma() + b.ArrEnd() + b.Comma() + b.StripComma() + b.ObjEnd() + return nil +} + +// DecodeTDLibJSON implements tdjson.TDLibDecoder. +func (c *ChannelTransactionPurposePaidMedia) DecodeTDLibJSON(b tdjson.Decoder) error { + if c == nil { + return fmt.Errorf("can't decode channelTransactionPurposePaidMedia#b00b2258 to nil") + } + + return b.Obj(func(b tdjson.Decoder, key []byte) error { + switch string(key) { + case tdjson.TypeField: + if err := b.ConsumeID("channelTransactionPurposePaidMedia"); err != nil { + return fmt.Errorf("unable to decode channelTransactionPurposePaidMedia#b00b2258: %w", err) + } + case "message_id": + value, err := b.Int53() + if err != nil { + return fmt.Errorf("unable to decode channelTransactionPurposePaidMedia#b00b2258: field message_id: %w", err) + } + c.MessageID = value + case "media": + if err := b.Arr(func(b tdjson.Decoder) error { + value, err := DecodeTDLibJSONPaidMedia(b) + if err != nil { + return fmt.Errorf("unable to decode channelTransactionPurposePaidMedia#b00b2258: field media: %w", err) + } + c.Media = append(c.Media, value) + return nil + }); err != nil { + return fmt.Errorf("unable to decode channelTransactionPurposePaidMedia#b00b2258: field media: %w", err) + } + default: + return b.Skip() + } + return nil + }) +} + +// GetMessageID returns value of MessageID field. +func (c *ChannelTransactionPurposePaidMedia) GetMessageID() (value int64) { + if c == nil { + return + } + return c.MessageID +} + +// GetMedia returns value of Media field. +func (c *ChannelTransactionPurposePaidMedia) GetMedia() (value []PaidMediaClass) { + if c == nil { + return + } + return c.Media +} + +// ChannelTransactionPurposeJoin represents TL type `channelTransactionPurposeJoin#ed83dd90`. +type ChannelTransactionPurposeJoin struct { + // The number of seconds between consecutive Telegram Star debiting + Period int32 +} + +// ChannelTransactionPurposeJoinTypeID is TL type id of ChannelTransactionPurposeJoin. +const ChannelTransactionPurposeJoinTypeID = 0xed83dd90 + +// construct implements constructor of ChannelTransactionPurposeClass. +func (c ChannelTransactionPurposeJoin) construct() ChannelTransactionPurposeClass { return &c } + +// Ensuring interfaces in compile-time for ChannelTransactionPurposeJoin. +var ( + _ bin.Encoder = &ChannelTransactionPurposeJoin{} + _ bin.Decoder = &ChannelTransactionPurposeJoin{} + _ bin.BareEncoder = &ChannelTransactionPurposeJoin{} + _ bin.BareDecoder = &ChannelTransactionPurposeJoin{} + + _ ChannelTransactionPurposeClass = &ChannelTransactionPurposeJoin{} +) + +func (c *ChannelTransactionPurposeJoin) Zero() bool { + if c == nil { + return true + } + if !(c.Period == 0) { + return false + } + + return true +} + +// String implements fmt.Stringer. +func (c *ChannelTransactionPurposeJoin) String() string { + if c == nil { + return "ChannelTransactionPurposeJoin(nil)" + } + type Alias ChannelTransactionPurposeJoin + return fmt.Sprintf("ChannelTransactionPurposeJoin%+v", Alias(*c)) +} + +// TypeID returns type id in TL schema. +// +// See https://core.telegram.org/mtproto/TL-tl#remarks. +func (*ChannelTransactionPurposeJoin) TypeID() uint32 { + return ChannelTransactionPurposeJoinTypeID +} + +// TypeName returns name of type in TL schema. +func (*ChannelTransactionPurposeJoin) TypeName() string { + return "channelTransactionPurposeJoin" +} + +// TypeInfo returns info about TL type. +func (c *ChannelTransactionPurposeJoin) TypeInfo() tdp.Type { + typ := tdp.Type{ + Name: "channelTransactionPurposeJoin", + ID: ChannelTransactionPurposeJoinTypeID, + } + if c == nil { + typ.Null = true + return typ + } + typ.Fields = []tdp.Field{ + { + Name: "Period", + SchemaName: "period", + }, + } + return typ +} + +// Encode implements bin.Encoder. +func (c *ChannelTransactionPurposeJoin) Encode(b *bin.Buffer) error { + if c == nil { + return fmt.Errorf("can't encode channelTransactionPurposeJoin#ed83dd90 as nil") + } + b.PutID(ChannelTransactionPurposeJoinTypeID) + return c.EncodeBare(b) +} + +// EncodeBare implements bin.BareEncoder. +func (c *ChannelTransactionPurposeJoin) EncodeBare(b *bin.Buffer) error { + if c == nil { + return fmt.Errorf("can't encode channelTransactionPurposeJoin#ed83dd90 as nil") + } + b.PutInt32(c.Period) + return nil +} + +// Decode implements bin.Decoder. +func (c *ChannelTransactionPurposeJoin) Decode(b *bin.Buffer) error { + if c == nil { + return fmt.Errorf("can't decode channelTransactionPurposeJoin#ed83dd90 to nil") + } + if err := b.ConsumeID(ChannelTransactionPurposeJoinTypeID); err != nil { + return fmt.Errorf("unable to decode channelTransactionPurposeJoin#ed83dd90: %w", err) + } + return c.DecodeBare(b) +} + +// DecodeBare implements bin.BareDecoder. +func (c *ChannelTransactionPurposeJoin) DecodeBare(b *bin.Buffer) error { + if c == nil { + return fmt.Errorf("can't decode channelTransactionPurposeJoin#ed83dd90 to nil") + } + { + value, err := b.Int32() + if err != nil { + return fmt.Errorf("unable to decode channelTransactionPurposeJoin#ed83dd90: field period: %w", err) + } + c.Period = value + } + return nil +} + +// EncodeTDLibJSON implements tdjson.TDLibEncoder. +func (c *ChannelTransactionPurposeJoin) EncodeTDLibJSON(b tdjson.Encoder) error { + if c == nil { + return fmt.Errorf("can't encode channelTransactionPurposeJoin#ed83dd90 as nil") + } + b.ObjStart() + b.PutID("channelTransactionPurposeJoin") + b.Comma() + b.FieldStart("period") + b.PutInt32(c.Period) + b.Comma() + b.StripComma() + b.ObjEnd() + return nil +} + +// DecodeTDLibJSON implements tdjson.TDLibDecoder. +func (c *ChannelTransactionPurposeJoin) DecodeTDLibJSON(b tdjson.Decoder) error { + if c == nil { + return fmt.Errorf("can't decode channelTransactionPurposeJoin#ed83dd90 to nil") + } + + return b.Obj(func(b tdjson.Decoder, key []byte) error { + switch string(key) { + case tdjson.TypeField: + if err := b.ConsumeID("channelTransactionPurposeJoin"); err != nil { + return fmt.Errorf("unable to decode channelTransactionPurposeJoin#ed83dd90: %w", err) + } + case "period": + value, err := b.Int32() + if err != nil { + return fmt.Errorf("unable to decode channelTransactionPurposeJoin#ed83dd90: field period: %w", err) + } + c.Period = value + default: + return b.Skip() + } + return nil + }) +} + +// GetPeriod returns value of Period field. +func (c *ChannelTransactionPurposeJoin) GetPeriod() (value int32) { + if c == nil { + return + } + return c.Period +} + +// ChannelTransactionPurposeReaction represents TL type `channelTransactionPurposeReaction#2ca05bee`. +type ChannelTransactionPurposeReaction struct { + // Identifier of the reacted message; can be an identifier of a deleted message + MessageID int64 +} + +// ChannelTransactionPurposeReactionTypeID is TL type id of ChannelTransactionPurposeReaction. +const ChannelTransactionPurposeReactionTypeID = 0x2ca05bee + +// construct implements constructor of ChannelTransactionPurposeClass. +func (c ChannelTransactionPurposeReaction) construct() ChannelTransactionPurposeClass { return &c } + +// Ensuring interfaces in compile-time for ChannelTransactionPurposeReaction. +var ( + _ bin.Encoder = &ChannelTransactionPurposeReaction{} + _ bin.Decoder = &ChannelTransactionPurposeReaction{} + _ bin.BareEncoder = &ChannelTransactionPurposeReaction{} + _ bin.BareDecoder = &ChannelTransactionPurposeReaction{} + + _ ChannelTransactionPurposeClass = &ChannelTransactionPurposeReaction{} +) + +func (c *ChannelTransactionPurposeReaction) Zero() bool { + if c == nil { + return true + } + if !(c.MessageID == 0) { + return false + } + + return true +} + +// String implements fmt.Stringer. +func (c *ChannelTransactionPurposeReaction) String() string { + if c == nil { + return "ChannelTransactionPurposeReaction(nil)" + } + type Alias ChannelTransactionPurposeReaction + return fmt.Sprintf("ChannelTransactionPurposeReaction%+v", Alias(*c)) +} + +// TypeID returns type id in TL schema. +// +// See https://core.telegram.org/mtproto/TL-tl#remarks. +func (*ChannelTransactionPurposeReaction) TypeID() uint32 { + return ChannelTransactionPurposeReactionTypeID +} + +// TypeName returns name of type in TL schema. +func (*ChannelTransactionPurposeReaction) TypeName() string { + return "channelTransactionPurposeReaction" +} + +// TypeInfo returns info about TL type. +func (c *ChannelTransactionPurposeReaction) TypeInfo() tdp.Type { + typ := tdp.Type{ + Name: "channelTransactionPurposeReaction", + ID: ChannelTransactionPurposeReactionTypeID, + } + if c == nil { + typ.Null = true + return typ + } + typ.Fields = []tdp.Field{ + { + Name: "MessageID", + SchemaName: "message_id", + }, + } + return typ +} + +// Encode implements bin.Encoder. +func (c *ChannelTransactionPurposeReaction) Encode(b *bin.Buffer) error { + if c == nil { + return fmt.Errorf("can't encode channelTransactionPurposeReaction#2ca05bee as nil") + } + b.PutID(ChannelTransactionPurposeReactionTypeID) + return c.EncodeBare(b) +} + +// EncodeBare implements bin.BareEncoder. +func (c *ChannelTransactionPurposeReaction) EncodeBare(b *bin.Buffer) error { + if c == nil { + return fmt.Errorf("can't encode channelTransactionPurposeReaction#2ca05bee as nil") + } + b.PutInt53(c.MessageID) + return nil +} + +// Decode implements bin.Decoder. +func (c *ChannelTransactionPurposeReaction) Decode(b *bin.Buffer) error { + if c == nil { + return fmt.Errorf("can't decode channelTransactionPurposeReaction#2ca05bee to nil") + } + if err := b.ConsumeID(ChannelTransactionPurposeReactionTypeID); err != nil { + return fmt.Errorf("unable to decode channelTransactionPurposeReaction#2ca05bee: %w", err) + } + return c.DecodeBare(b) +} + +// DecodeBare implements bin.BareDecoder. +func (c *ChannelTransactionPurposeReaction) DecodeBare(b *bin.Buffer) error { + if c == nil { + return fmt.Errorf("can't decode channelTransactionPurposeReaction#2ca05bee to nil") + } + { + value, err := b.Int53() + if err != nil { + return fmt.Errorf("unable to decode channelTransactionPurposeReaction#2ca05bee: field message_id: %w", err) + } + c.MessageID = value + } + return nil +} + +// EncodeTDLibJSON implements tdjson.TDLibEncoder. +func (c *ChannelTransactionPurposeReaction) EncodeTDLibJSON(b tdjson.Encoder) error { + if c == nil { + return fmt.Errorf("can't encode channelTransactionPurposeReaction#2ca05bee as nil") + } + b.ObjStart() + b.PutID("channelTransactionPurposeReaction") + b.Comma() + b.FieldStart("message_id") + b.PutInt53(c.MessageID) + b.Comma() + b.StripComma() + b.ObjEnd() + return nil +} + +// DecodeTDLibJSON implements tdjson.TDLibDecoder. +func (c *ChannelTransactionPurposeReaction) DecodeTDLibJSON(b tdjson.Decoder) error { + if c == nil { + return fmt.Errorf("can't decode channelTransactionPurposeReaction#2ca05bee to nil") + } + + return b.Obj(func(b tdjson.Decoder, key []byte) error { + switch string(key) { + case tdjson.TypeField: + if err := b.ConsumeID("channelTransactionPurposeReaction"); err != nil { + return fmt.Errorf("unable to decode channelTransactionPurposeReaction#2ca05bee: %w", err) + } + case "message_id": + value, err := b.Int53() + if err != nil { + return fmt.Errorf("unable to decode channelTransactionPurposeReaction#2ca05bee: field message_id: %w", err) + } + c.MessageID = value + default: + return b.Skip() + } + return nil + }) +} + +// GetMessageID returns value of MessageID field. +func (c *ChannelTransactionPurposeReaction) GetMessageID() (value int64) { + if c == nil { + return + } + return c.MessageID +} + +// ChannelTransactionPurposeClassName is schema name of ChannelTransactionPurposeClass. +const ChannelTransactionPurposeClassName = "ChannelTransactionPurpose" + +// ChannelTransactionPurposeClass represents ChannelTransactionPurpose generic type. +// +// Example: +// +// g, err := tdapi.DecodeChannelTransactionPurpose(buf) +// if err != nil { +// panic(err) +// } +// switch v := g.(type) { +// case *tdapi.ChannelTransactionPurposePaidMedia: // channelTransactionPurposePaidMedia#b00b2258 +// case *tdapi.ChannelTransactionPurposeJoin: // channelTransactionPurposeJoin#ed83dd90 +// case *tdapi.ChannelTransactionPurposeReaction: // channelTransactionPurposeReaction#2ca05bee +// default: panic(v) +// } +type ChannelTransactionPurposeClass interface { + bin.Encoder + bin.Decoder + bin.BareEncoder + bin.BareDecoder + construct() ChannelTransactionPurposeClass + + // TypeID returns type id in TL schema. + // + // See https://core.telegram.org/mtproto/TL-tl#remarks. + TypeID() uint32 + // TypeName returns name of type in TL schema. + TypeName() string + // String implements fmt.Stringer. + String() string + // Zero returns true if current object has a zero value. + Zero() bool + + EncodeTDLibJSON(b tdjson.Encoder) error + DecodeTDLibJSON(b tdjson.Decoder) error +} + +// DecodeChannelTransactionPurpose implements binary de-serialization for ChannelTransactionPurposeClass. +func DecodeChannelTransactionPurpose(buf *bin.Buffer) (ChannelTransactionPurposeClass, error) { + id, err := buf.PeekID() + if err != nil { + return nil, err + } + switch id { + case ChannelTransactionPurposePaidMediaTypeID: + // Decoding channelTransactionPurposePaidMedia#b00b2258. + v := ChannelTransactionPurposePaidMedia{} + if err := v.Decode(buf); err != nil { + return nil, fmt.Errorf("unable to decode ChannelTransactionPurposeClass: %w", err) + } + return &v, nil + case ChannelTransactionPurposeJoinTypeID: + // Decoding channelTransactionPurposeJoin#ed83dd90. + v := ChannelTransactionPurposeJoin{} + if err := v.Decode(buf); err != nil { + return nil, fmt.Errorf("unable to decode ChannelTransactionPurposeClass: %w", err) + } + return &v, nil + case ChannelTransactionPurposeReactionTypeID: + // Decoding channelTransactionPurposeReaction#2ca05bee. + v := ChannelTransactionPurposeReaction{} + if err := v.Decode(buf); err != nil { + return nil, fmt.Errorf("unable to decode ChannelTransactionPurposeClass: %w", err) + } + return &v, nil + default: + return nil, fmt.Errorf("unable to decode ChannelTransactionPurposeClass: %w", bin.NewUnexpectedID(id)) + } +} + +// DecodeTDLibJSONChannelTransactionPurpose implements binary de-serialization for ChannelTransactionPurposeClass. +func DecodeTDLibJSONChannelTransactionPurpose(buf tdjson.Decoder) (ChannelTransactionPurposeClass, error) { + id, err := buf.FindTypeID() + if err != nil { + return nil, err + } + switch id { + case "channelTransactionPurposePaidMedia": + // Decoding channelTransactionPurposePaidMedia#b00b2258. + v := ChannelTransactionPurposePaidMedia{} + if err := v.DecodeTDLibJSON(buf); err != nil { + return nil, fmt.Errorf("unable to decode ChannelTransactionPurposeClass: %w", err) + } + return &v, nil + case "channelTransactionPurposeJoin": + // Decoding channelTransactionPurposeJoin#ed83dd90. + v := ChannelTransactionPurposeJoin{} + if err := v.DecodeTDLibJSON(buf); err != nil { + return nil, fmt.Errorf("unable to decode ChannelTransactionPurposeClass: %w", err) + } + return &v, nil + case "channelTransactionPurposeReaction": + // Decoding channelTransactionPurposeReaction#2ca05bee. + v := ChannelTransactionPurposeReaction{} + if err := v.DecodeTDLibJSON(buf); err != nil { + return nil, fmt.Errorf("unable to decode ChannelTransactionPurposeClass: %w", err) + } + return &v, nil + default: + return nil, fmt.Errorf("unable to decode ChannelTransactionPurposeClass: %w", tdjson.NewUnexpectedID(id)) + } +} + +// ChannelTransactionPurpose boxes the ChannelTransactionPurposeClass providing a helper. +type ChannelTransactionPurposeBox struct { + ChannelTransactionPurpose ChannelTransactionPurposeClass +} + +// Decode implements bin.Decoder for ChannelTransactionPurposeBox. +func (b *ChannelTransactionPurposeBox) Decode(buf *bin.Buffer) error { + if b == nil { + return fmt.Errorf("unable to decode ChannelTransactionPurposeBox to nil") + } + v, err := DecodeChannelTransactionPurpose(buf) + if err != nil { + return fmt.Errorf("unable to decode boxed value: %w", err) + } + b.ChannelTransactionPurpose = v + return nil +} + +// Encode implements bin.Encode for ChannelTransactionPurposeBox. +func (b *ChannelTransactionPurposeBox) Encode(buf *bin.Buffer) error { + if b == nil || b.ChannelTransactionPurpose == nil { + return fmt.Errorf("unable to encode ChannelTransactionPurposeClass as nil") + } + return b.ChannelTransactionPurpose.Encode(buf) +} + +// DecodeTDLibJSON implements bin.Decoder for ChannelTransactionPurposeBox. +func (b *ChannelTransactionPurposeBox) DecodeTDLibJSON(buf tdjson.Decoder) error { + if b == nil { + return fmt.Errorf("unable to decode ChannelTransactionPurposeBox to nil") + } + v, err := DecodeTDLibJSONChannelTransactionPurpose(buf) + if err != nil { + return fmt.Errorf("unable to decode boxed value: %w", err) + } + b.ChannelTransactionPurpose = v + return nil +} + +// EncodeTDLibJSON implements bin.Encode for ChannelTransactionPurposeBox. +func (b *ChannelTransactionPurposeBox) EncodeTDLibJSON(buf tdjson.Encoder) error { + if b == nil || b.ChannelTransactionPurpose == nil { + return fmt.Errorf("unable to encode ChannelTransactionPurposeClass as nil") + } + return b.ChannelTransactionPurpose.EncodeTDLibJSON(buf) +} diff --git a/tdapi/tl_chat_event_action_gen.go b/tdapi/tl_chat_event_action_gen.go index 3d9e78aeb1..6b24d5fe29 100644 --- a/tdapi/tl_chat_event_action_gen.go +++ b/tdapi/tl_chat_event_action_gen.go @@ -6754,6 +6754,172 @@ func (c *ChatEventSignMessagesToggled) GetSignMessages() (value bool) { return c.SignMessages } +// ChatEventShowMessageSenderToggled represents TL type `chatEventShowMessageSenderToggled#d0a747e3`. +type ChatEventShowMessageSenderToggled struct { + // New value of show_message_sender + ShowMessageSender bool +} + +// ChatEventShowMessageSenderToggledTypeID is TL type id of ChatEventShowMessageSenderToggled. +const ChatEventShowMessageSenderToggledTypeID = 0xd0a747e3 + +// construct implements constructor of ChatEventActionClass. +func (c ChatEventShowMessageSenderToggled) construct() ChatEventActionClass { return &c } + +// Ensuring interfaces in compile-time for ChatEventShowMessageSenderToggled. +var ( + _ bin.Encoder = &ChatEventShowMessageSenderToggled{} + _ bin.Decoder = &ChatEventShowMessageSenderToggled{} + _ bin.BareEncoder = &ChatEventShowMessageSenderToggled{} + _ bin.BareDecoder = &ChatEventShowMessageSenderToggled{} + + _ ChatEventActionClass = &ChatEventShowMessageSenderToggled{} +) + +func (c *ChatEventShowMessageSenderToggled) Zero() bool { + if c == nil { + return true + } + if !(c.ShowMessageSender == false) { + return false + } + + return true +} + +// String implements fmt.Stringer. +func (c *ChatEventShowMessageSenderToggled) String() string { + if c == nil { + return "ChatEventShowMessageSenderToggled(nil)" + } + type Alias ChatEventShowMessageSenderToggled + return fmt.Sprintf("ChatEventShowMessageSenderToggled%+v", Alias(*c)) +} + +// TypeID returns type id in TL schema. +// +// See https://core.telegram.org/mtproto/TL-tl#remarks. +func (*ChatEventShowMessageSenderToggled) TypeID() uint32 { + return ChatEventShowMessageSenderToggledTypeID +} + +// TypeName returns name of type in TL schema. +func (*ChatEventShowMessageSenderToggled) TypeName() string { + return "chatEventShowMessageSenderToggled" +} + +// TypeInfo returns info about TL type. +func (c *ChatEventShowMessageSenderToggled) TypeInfo() tdp.Type { + typ := tdp.Type{ + Name: "chatEventShowMessageSenderToggled", + ID: ChatEventShowMessageSenderToggledTypeID, + } + if c == nil { + typ.Null = true + return typ + } + typ.Fields = []tdp.Field{ + { + Name: "ShowMessageSender", + SchemaName: "show_message_sender", + }, + } + return typ +} + +// Encode implements bin.Encoder. +func (c *ChatEventShowMessageSenderToggled) Encode(b *bin.Buffer) error { + if c == nil { + return fmt.Errorf("can't encode chatEventShowMessageSenderToggled#d0a747e3 as nil") + } + b.PutID(ChatEventShowMessageSenderToggledTypeID) + return c.EncodeBare(b) +} + +// EncodeBare implements bin.BareEncoder. +func (c *ChatEventShowMessageSenderToggled) EncodeBare(b *bin.Buffer) error { + if c == nil { + return fmt.Errorf("can't encode chatEventShowMessageSenderToggled#d0a747e3 as nil") + } + b.PutBool(c.ShowMessageSender) + return nil +} + +// Decode implements bin.Decoder. +func (c *ChatEventShowMessageSenderToggled) Decode(b *bin.Buffer) error { + if c == nil { + return fmt.Errorf("can't decode chatEventShowMessageSenderToggled#d0a747e3 to nil") + } + if err := b.ConsumeID(ChatEventShowMessageSenderToggledTypeID); err != nil { + return fmt.Errorf("unable to decode chatEventShowMessageSenderToggled#d0a747e3: %w", err) + } + return c.DecodeBare(b) +} + +// DecodeBare implements bin.BareDecoder. +func (c *ChatEventShowMessageSenderToggled) DecodeBare(b *bin.Buffer) error { + if c == nil { + return fmt.Errorf("can't decode chatEventShowMessageSenderToggled#d0a747e3 to nil") + } + { + value, err := b.Bool() + if err != nil { + return fmt.Errorf("unable to decode chatEventShowMessageSenderToggled#d0a747e3: field show_message_sender: %w", err) + } + c.ShowMessageSender = value + } + return nil +} + +// EncodeTDLibJSON implements tdjson.TDLibEncoder. +func (c *ChatEventShowMessageSenderToggled) EncodeTDLibJSON(b tdjson.Encoder) error { + if c == nil { + return fmt.Errorf("can't encode chatEventShowMessageSenderToggled#d0a747e3 as nil") + } + b.ObjStart() + b.PutID("chatEventShowMessageSenderToggled") + b.Comma() + b.FieldStart("show_message_sender") + b.PutBool(c.ShowMessageSender) + b.Comma() + b.StripComma() + b.ObjEnd() + return nil +} + +// DecodeTDLibJSON implements tdjson.TDLibDecoder. +func (c *ChatEventShowMessageSenderToggled) DecodeTDLibJSON(b tdjson.Decoder) error { + if c == nil { + return fmt.Errorf("can't decode chatEventShowMessageSenderToggled#d0a747e3 to nil") + } + + return b.Obj(func(b tdjson.Decoder, key []byte) error { + switch string(key) { + case tdjson.TypeField: + if err := b.ConsumeID("chatEventShowMessageSenderToggled"); err != nil { + return fmt.Errorf("unable to decode chatEventShowMessageSenderToggled#d0a747e3: %w", err) + } + case "show_message_sender": + value, err := b.Bool() + if err != nil { + return fmt.Errorf("unable to decode chatEventShowMessageSenderToggled#d0a747e3: field show_message_sender: %w", err) + } + c.ShowMessageSender = value + default: + return b.Skip() + } + return nil + }) +} + +// GetShowMessageSender returns value of ShowMessageSender field. +func (c *ChatEventShowMessageSenderToggled) GetShowMessageSender() (value bool) { + if c == nil { + return + } + return c.ShowMessageSender +} + // ChatEventInviteLinkEdited represents TL type `chatEventInviteLinkEdited#e4920d62`. type ChatEventInviteLinkEdited struct { // Previous information about the invite link @@ -9482,6 +9648,7 @@ const ChatEventActionClassName = "ChatEventAction" // case *tdapi.ChatEventIsAllHistoryAvailableToggled: // chatEventIsAllHistoryAvailableToggled#a0b03c15 // case *tdapi.ChatEventHasAggressiveAntiSpamEnabledToggled: // chatEventHasAggressiveAntiSpamEnabledToggled#f8875702 // case *tdapi.ChatEventSignMessagesToggled: // chatEventSignMessagesToggled#b1b9281e +// case *tdapi.ChatEventShowMessageSenderToggled: // chatEventShowMessageSenderToggled#d0a747e3 // case *tdapi.ChatEventInviteLinkEdited: // chatEventInviteLinkEdited#e4920d62 // case *tdapi.ChatEventInviteLinkRevoked: // chatEventInviteLinkRevoked#a1dbffe3 // case *tdapi.ChatEventInviteLinkDeleted: // chatEventInviteLinkDeleted#acda6167 @@ -9766,6 +9933,13 @@ func DecodeChatEventAction(buf *bin.Buffer) (ChatEventActionClass, error) { return nil, fmt.Errorf("unable to decode ChatEventActionClass: %w", err) } return &v, nil + case ChatEventShowMessageSenderToggledTypeID: + // Decoding chatEventShowMessageSenderToggled#d0a747e3. + v := ChatEventShowMessageSenderToggled{} + if err := v.Decode(buf); err != nil { + return nil, fmt.Errorf("unable to decode ChatEventActionClass: %w", err) + } + return &v, nil case ChatEventInviteLinkEditedTypeID: // Decoding chatEventInviteLinkEdited#e4920d62. v := ChatEventInviteLinkEdited{} @@ -10121,6 +10295,13 @@ func DecodeTDLibJSONChatEventAction(buf tdjson.Decoder) (ChatEventActionClass, e return nil, fmt.Errorf("unable to decode ChatEventActionClass: %w", err) } return &v, nil + case "chatEventShowMessageSenderToggled": + // Decoding chatEventShowMessageSenderToggled#d0a747e3. + v := ChatEventShowMessageSenderToggled{} + if err := v.DecodeTDLibJSON(buf); err != nil { + return nil, fmt.Errorf("unable to decode ChatEventActionClass: %w", err) + } + return &v, nil case "chatEventInviteLinkEdited": // Decoding chatEventInviteLinkEdited#e4920d62. v := ChatEventInviteLinkEdited{} diff --git a/tdapi/tl_chat_invite_link_gen.go b/tdapi/tl_chat_invite_link_gen.go index 9428aaae34..41de06247c 100644 --- a/tdapi/tl_chat_invite_link_gen.go +++ b/tdapi/tl_chat_invite_link_gen.go @@ -31,7 +31,7 @@ var ( _ = tdjson.Encoder{} ) -// ChatInviteLink represents TL type `chatInviteLink#f3bb8d04`. +// ChatInviteLink represents TL type `chatInviteLink#c6eb6530`. type ChatInviteLink struct { // Chat invite link InviteLink string @@ -45,11 +45,17 @@ type ChatInviteLink struct { EditDate int32 // Point in time (Unix timestamp) when the link will expire; 0 if never ExpirationDate int32 + // Information about subscription plan that is applied to the users joining the chat by + // the link; may be null if the link doesn't require subscription + SubscriptionPricing StarSubscriptionPricing // The maximum number of members, which can join the chat using the link simultaneously; // 0 if not limited. Always 0 if the link requires approval MemberLimit int32 // Number of chat members, which joined the chat using the link MemberCount int32 + // Number of chat members, which joined the chat using the link, but have already left + // because of expired subscription; for subscription links only + ExpiredMemberCount int32 // Number of pending join requests created using this link PendingJoinRequestCount int32 // True, if the link only creates join request. If true, total number of joining members @@ -64,7 +70,7 @@ type ChatInviteLink struct { } // ChatInviteLinkTypeID is TL type id of ChatInviteLink. -const ChatInviteLinkTypeID = 0xf3bb8d04 +const ChatInviteLinkTypeID = 0xc6eb6530 // Ensuring interfaces in compile-time for ChatInviteLink. var ( @@ -96,12 +102,18 @@ func (c *ChatInviteLink) Zero() bool { if !(c.ExpirationDate == 0) { return false } + if !(c.SubscriptionPricing.Zero()) { + return false + } if !(c.MemberLimit == 0) { return false } if !(c.MemberCount == 0) { return false } + if !(c.ExpiredMemberCount == 0) { + return false + } if !(c.PendingJoinRequestCount == 0) { return false } @@ -174,6 +186,10 @@ func (c *ChatInviteLink) TypeInfo() tdp.Type { Name: "ExpirationDate", SchemaName: "expiration_date", }, + { + Name: "SubscriptionPricing", + SchemaName: "subscription_pricing", + }, { Name: "MemberLimit", SchemaName: "member_limit", @@ -182,6 +198,10 @@ func (c *ChatInviteLink) TypeInfo() tdp.Type { Name: "MemberCount", SchemaName: "member_count", }, + { + Name: "ExpiredMemberCount", + SchemaName: "expired_member_count", + }, { Name: "PendingJoinRequestCount", SchemaName: "pending_join_request_count", @@ -205,7 +225,7 @@ func (c *ChatInviteLink) TypeInfo() tdp.Type { // Encode implements bin.Encoder. func (c *ChatInviteLink) Encode(b *bin.Buffer) error { if c == nil { - return fmt.Errorf("can't encode chatInviteLink#f3bb8d04 as nil") + return fmt.Errorf("can't encode chatInviteLink#c6eb6530 as nil") } b.PutID(ChatInviteLinkTypeID) return c.EncodeBare(b) @@ -214,7 +234,7 @@ func (c *ChatInviteLink) Encode(b *bin.Buffer) error { // EncodeBare implements bin.BareEncoder. func (c *ChatInviteLink) EncodeBare(b *bin.Buffer) error { if c == nil { - return fmt.Errorf("can't encode chatInviteLink#f3bb8d04 as nil") + return fmt.Errorf("can't encode chatInviteLink#c6eb6530 as nil") } b.PutString(c.InviteLink) b.PutString(c.Name) @@ -222,8 +242,12 @@ func (c *ChatInviteLink) EncodeBare(b *bin.Buffer) error { b.PutInt32(c.Date) b.PutInt32(c.EditDate) b.PutInt32(c.ExpirationDate) + if err := c.SubscriptionPricing.Encode(b); err != nil { + return fmt.Errorf("unable to encode chatInviteLink#c6eb6530: field subscription_pricing: %w", err) + } b.PutInt32(c.MemberLimit) b.PutInt32(c.MemberCount) + b.PutInt32(c.ExpiredMemberCount) b.PutInt32(c.PendingJoinRequestCount) b.PutBool(c.CreatesJoinRequest) b.PutBool(c.IsPrimary) @@ -234,10 +258,10 @@ func (c *ChatInviteLink) EncodeBare(b *bin.Buffer) error { // Decode implements bin.Decoder. func (c *ChatInviteLink) Decode(b *bin.Buffer) error { if c == nil { - return fmt.Errorf("can't decode chatInviteLink#f3bb8d04 to nil") + return fmt.Errorf("can't decode chatInviteLink#c6eb6530 to nil") } if err := b.ConsumeID(ChatInviteLinkTypeID); err != nil { - return fmt.Errorf("unable to decode chatInviteLink#f3bb8d04: %w", err) + return fmt.Errorf("unable to decode chatInviteLink#c6eb6530: %w", err) } return c.DecodeBare(b) } @@ -245,89 +269,101 @@ func (c *ChatInviteLink) Decode(b *bin.Buffer) error { // DecodeBare implements bin.BareDecoder. func (c *ChatInviteLink) DecodeBare(b *bin.Buffer) error { if c == nil { - return fmt.Errorf("can't decode chatInviteLink#f3bb8d04 to nil") + return fmt.Errorf("can't decode chatInviteLink#c6eb6530 to nil") } { value, err := b.String() if err != nil { - return fmt.Errorf("unable to decode chatInviteLink#f3bb8d04: field invite_link: %w", err) + return fmt.Errorf("unable to decode chatInviteLink#c6eb6530: field invite_link: %w", err) } c.InviteLink = value } { value, err := b.String() if err != nil { - return fmt.Errorf("unable to decode chatInviteLink#f3bb8d04: field name: %w", err) + return fmt.Errorf("unable to decode chatInviteLink#c6eb6530: field name: %w", err) } c.Name = value } { value, err := b.Int53() if err != nil { - return fmt.Errorf("unable to decode chatInviteLink#f3bb8d04: field creator_user_id: %w", err) + return fmt.Errorf("unable to decode chatInviteLink#c6eb6530: field creator_user_id: %w", err) } c.CreatorUserID = value } { value, err := b.Int32() if err != nil { - return fmt.Errorf("unable to decode chatInviteLink#f3bb8d04: field date: %w", err) + return fmt.Errorf("unable to decode chatInviteLink#c6eb6530: field date: %w", err) } c.Date = value } { value, err := b.Int32() if err != nil { - return fmt.Errorf("unable to decode chatInviteLink#f3bb8d04: field edit_date: %w", err) + return fmt.Errorf("unable to decode chatInviteLink#c6eb6530: field edit_date: %w", err) } c.EditDate = value } { value, err := b.Int32() if err != nil { - return fmt.Errorf("unable to decode chatInviteLink#f3bb8d04: field expiration_date: %w", err) + return fmt.Errorf("unable to decode chatInviteLink#c6eb6530: field expiration_date: %w", err) } c.ExpirationDate = value } + { + if err := c.SubscriptionPricing.Decode(b); err != nil { + return fmt.Errorf("unable to decode chatInviteLink#c6eb6530: field subscription_pricing: %w", err) + } + } { value, err := b.Int32() if err != nil { - return fmt.Errorf("unable to decode chatInviteLink#f3bb8d04: field member_limit: %w", err) + return fmt.Errorf("unable to decode chatInviteLink#c6eb6530: field member_limit: %w", err) } c.MemberLimit = value } { value, err := b.Int32() if err != nil { - return fmt.Errorf("unable to decode chatInviteLink#f3bb8d04: field member_count: %w", err) + return fmt.Errorf("unable to decode chatInviteLink#c6eb6530: field member_count: %w", err) } c.MemberCount = value } { value, err := b.Int32() if err != nil { - return fmt.Errorf("unable to decode chatInviteLink#f3bb8d04: field pending_join_request_count: %w", err) + return fmt.Errorf("unable to decode chatInviteLink#c6eb6530: field expired_member_count: %w", err) + } + c.ExpiredMemberCount = value + } + { + value, err := b.Int32() + if err != nil { + return fmt.Errorf("unable to decode chatInviteLink#c6eb6530: field pending_join_request_count: %w", err) } c.PendingJoinRequestCount = value } { value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode chatInviteLink#f3bb8d04: field creates_join_request: %w", err) + return fmt.Errorf("unable to decode chatInviteLink#c6eb6530: field creates_join_request: %w", err) } c.CreatesJoinRequest = value } { value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode chatInviteLink#f3bb8d04: field is_primary: %w", err) + return fmt.Errorf("unable to decode chatInviteLink#c6eb6530: field is_primary: %w", err) } c.IsPrimary = value } { value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode chatInviteLink#f3bb8d04: field is_revoked: %w", err) + return fmt.Errorf("unable to decode chatInviteLink#c6eb6530: field is_revoked: %w", err) } c.IsRevoked = value } @@ -337,7 +373,7 @@ func (c *ChatInviteLink) DecodeBare(b *bin.Buffer) error { // EncodeTDLibJSON implements tdjson.TDLibEncoder. func (c *ChatInviteLink) EncodeTDLibJSON(b tdjson.Encoder) error { if c == nil { - return fmt.Errorf("can't encode chatInviteLink#f3bb8d04 as nil") + return fmt.Errorf("can't encode chatInviteLink#c6eb6530 as nil") } b.ObjStart() b.PutID("chatInviteLink") @@ -360,12 +396,20 @@ func (c *ChatInviteLink) EncodeTDLibJSON(b tdjson.Encoder) error { b.FieldStart("expiration_date") b.PutInt32(c.ExpirationDate) b.Comma() + b.FieldStart("subscription_pricing") + if err := c.SubscriptionPricing.EncodeTDLibJSON(b); err != nil { + return fmt.Errorf("unable to encode chatInviteLink#c6eb6530: field subscription_pricing: %w", err) + } + b.Comma() b.FieldStart("member_limit") b.PutInt32(c.MemberLimit) b.Comma() b.FieldStart("member_count") b.PutInt32(c.MemberCount) b.Comma() + b.FieldStart("expired_member_count") + b.PutInt32(c.ExpiredMemberCount) + b.Comma() b.FieldStart("pending_join_request_count") b.PutInt32(c.PendingJoinRequestCount) b.Comma() @@ -386,85 +430,95 @@ func (c *ChatInviteLink) EncodeTDLibJSON(b tdjson.Encoder) error { // DecodeTDLibJSON implements tdjson.TDLibDecoder. func (c *ChatInviteLink) DecodeTDLibJSON(b tdjson.Decoder) error { if c == nil { - return fmt.Errorf("can't decode chatInviteLink#f3bb8d04 to nil") + return fmt.Errorf("can't decode chatInviteLink#c6eb6530 to nil") } return b.Obj(func(b tdjson.Decoder, key []byte) error { switch string(key) { case tdjson.TypeField: if err := b.ConsumeID("chatInviteLink"); err != nil { - return fmt.Errorf("unable to decode chatInviteLink#f3bb8d04: %w", err) + return fmt.Errorf("unable to decode chatInviteLink#c6eb6530: %w", err) } case "invite_link": value, err := b.String() if err != nil { - return fmt.Errorf("unable to decode chatInviteLink#f3bb8d04: field invite_link: %w", err) + return fmt.Errorf("unable to decode chatInviteLink#c6eb6530: field invite_link: %w", err) } c.InviteLink = value case "name": value, err := b.String() if err != nil { - return fmt.Errorf("unable to decode chatInviteLink#f3bb8d04: field name: %w", err) + return fmt.Errorf("unable to decode chatInviteLink#c6eb6530: field name: %w", err) } c.Name = value case "creator_user_id": value, err := b.Int53() if err != nil { - return fmt.Errorf("unable to decode chatInviteLink#f3bb8d04: field creator_user_id: %w", err) + return fmt.Errorf("unable to decode chatInviteLink#c6eb6530: field creator_user_id: %w", err) } c.CreatorUserID = value case "date": value, err := b.Int32() if err != nil { - return fmt.Errorf("unable to decode chatInviteLink#f3bb8d04: field date: %w", err) + return fmt.Errorf("unable to decode chatInviteLink#c6eb6530: field date: %w", err) } c.Date = value case "edit_date": value, err := b.Int32() if err != nil { - return fmt.Errorf("unable to decode chatInviteLink#f3bb8d04: field edit_date: %w", err) + return fmt.Errorf("unable to decode chatInviteLink#c6eb6530: field edit_date: %w", err) } c.EditDate = value case "expiration_date": value, err := b.Int32() if err != nil { - return fmt.Errorf("unable to decode chatInviteLink#f3bb8d04: field expiration_date: %w", err) + return fmt.Errorf("unable to decode chatInviteLink#c6eb6530: field expiration_date: %w", err) } c.ExpirationDate = value + case "subscription_pricing": + if err := c.SubscriptionPricing.DecodeTDLibJSON(b); err != nil { + return fmt.Errorf("unable to decode chatInviteLink#c6eb6530: field subscription_pricing: %w", err) + } case "member_limit": value, err := b.Int32() if err != nil { - return fmt.Errorf("unable to decode chatInviteLink#f3bb8d04: field member_limit: %w", err) + return fmt.Errorf("unable to decode chatInviteLink#c6eb6530: field member_limit: %w", err) } c.MemberLimit = value case "member_count": value, err := b.Int32() if err != nil { - return fmt.Errorf("unable to decode chatInviteLink#f3bb8d04: field member_count: %w", err) + return fmt.Errorf("unable to decode chatInviteLink#c6eb6530: field member_count: %w", err) } c.MemberCount = value + case "expired_member_count": + value, err := b.Int32() + if err != nil { + return fmt.Errorf("unable to decode chatInviteLink#c6eb6530: field expired_member_count: %w", err) + } + c.ExpiredMemberCount = value case "pending_join_request_count": value, err := b.Int32() if err != nil { - return fmt.Errorf("unable to decode chatInviteLink#f3bb8d04: field pending_join_request_count: %w", err) + return fmt.Errorf("unable to decode chatInviteLink#c6eb6530: field pending_join_request_count: %w", err) } c.PendingJoinRequestCount = value case "creates_join_request": value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode chatInviteLink#f3bb8d04: field creates_join_request: %w", err) + return fmt.Errorf("unable to decode chatInviteLink#c6eb6530: field creates_join_request: %w", err) } c.CreatesJoinRequest = value case "is_primary": value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode chatInviteLink#f3bb8d04: field is_primary: %w", err) + return fmt.Errorf("unable to decode chatInviteLink#c6eb6530: field is_primary: %w", err) } c.IsPrimary = value case "is_revoked": value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode chatInviteLink#f3bb8d04: field is_revoked: %w", err) + return fmt.Errorf("unable to decode chatInviteLink#c6eb6530: field is_revoked: %w", err) } c.IsRevoked = value default: @@ -522,6 +576,14 @@ func (c *ChatInviteLink) GetExpirationDate() (value int32) { return c.ExpirationDate } +// GetSubscriptionPricing returns value of SubscriptionPricing field. +func (c *ChatInviteLink) GetSubscriptionPricing() (value StarSubscriptionPricing) { + if c == nil { + return + } + return c.SubscriptionPricing +} + // GetMemberLimit returns value of MemberLimit field. func (c *ChatInviteLink) GetMemberLimit() (value int32) { if c == nil { @@ -538,6 +600,14 @@ func (c *ChatInviteLink) GetMemberCount() (value int32) { return c.MemberCount } +// GetExpiredMemberCount returns value of ExpiredMemberCount field. +func (c *ChatInviteLink) GetExpiredMemberCount() (value int32) { + if c == nil { + return + } + return c.ExpiredMemberCount +} + // GetPendingJoinRequestCount returns value of PendingJoinRequestCount field. func (c *ChatInviteLink) GetPendingJoinRequestCount() (value int32) { if c == nil { diff --git a/tdapi/tl_chat_invite_link_info_gen.go b/tdapi/tl_chat_invite_link_info_gen.go index b696c74512..39d0b32d73 100644 --- a/tdapi/tl_chat_invite_link_info_gen.go +++ b/tdapi/tl_chat_invite_link_info_gen.go @@ -31,7 +31,7 @@ var ( _ = tdjson.Encoder{} ) -// ChatInviteLinkInfo represents TL type `chatInviteLinkInfo#829e9f23`. +// ChatInviteLinkInfo represents TL type `chatInviteLinkInfo#95bf0ec4`. type ChatInviteLinkInfo struct { // Chat identifier of the invite link; 0 if the user has no access to the chat before // joining @@ -53,6 +53,9 @@ type ChatInviteLinkInfo struct { MemberCount int32 // User identifiers of some chat members that may be known to the current user MemberUserIDs []int64 + // Information about subscription plan that must be paid by the user to use the link; may + // be null if the link doesn't require subscription + SubscriptionInfo ChatInviteLinkSubscriptionInfo // True, if the link only creates join request CreatesJoinRequest bool // True, if the chat is a public supergroup or channel, i.e. it has a username or it is a @@ -67,7 +70,7 @@ type ChatInviteLinkInfo struct { } // ChatInviteLinkInfoTypeID is TL type id of ChatInviteLinkInfo. -const ChatInviteLinkInfoTypeID = 0x829e9f23 +const ChatInviteLinkInfoTypeID = 0x95bf0ec4 // Ensuring interfaces in compile-time for ChatInviteLinkInfo. var ( @@ -108,6 +111,9 @@ func (c *ChatInviteLinkInfo) Zero() bool { if !(c.MemberUserIDs == nil) { return false } + if !(c.SubscriptionInfo.Zero()) { + return false + } if !(c.CreatesJoinRequest == false) { return false } @@ -195,6 +201,10 @@ func (c *ChatInviteLinkInfo) TypeInfo() tdp.Type { Name: "MemberUserIDs", SchemaName: "member_user_ids", }, + { + Name: "SubscriptionInfo", + SchemaName: "subscription_info", + }, { Name: "CreatesJoinRequest", SchemaName: "creates_join_request", @@ -222,7 +232,7 @@ func (c *ChatInviteLinkInfo) TypeInfo() tdp.Type { // Encode implements bin.Encoder. func (c *ChatInviteLinkInfo) Encode(b *bin.Buffer) error { if c == nil { - return fmt.Errorf("can't encode chatInviteLinkInfo#829e9f23 as nil") + return fmt.Errorf("can't encode chatInviteLinkInfo#95bf0ec4 as nil") } b.PutID(ChatInviteLinkInfoTypeID) return c.EncodeBare(b) @@ -231,19 +241,19 @@ func (c *ChatInviteLinkInfo) Encode(b *bin.Buffer) error { // EncodeBare implements bin.BareEncoder. func (c *ChatInviteLinkInfo) EncodeBare(b *bin.Buffer) error { if c == nil { - return fmt.Errorf("can't encode chatInviteLinkInfo#829e9f23 as nil") + return fmt.Errorf("can't encode chatInviteLinkInfo#95bf0ec4 as nil") } b.PutInt53(c.ChatID) b.PutInt32(c.AccessibleFor) if c.Type == nil { - return fmt.Errorf("unable to encode chatInviteLinkInfo#829e9f23: field type is nil") + return fmt.Errorf("unable to encode chatInviteLinkInfo#95bf0ec4: field type is nil") } if err := c.Type.Encode(b); err != nil { - return fmt.Errorf("unable to encode chatInviteLinkInfo#829e9f23: field type: %w", err) + return fmt.Errorf("unable to encode chatInviteLinkInfo#95bf0ec4: field type: %w", err) } b.PutString(c.Title) if err := c.Photo.Encode(b); err != nil { - return fmt.Errorf("unable to encode chatInviteLinkInfo#829e9f23: field photo: %w", err) + return fmt.Errorf("unable to encode chatInviteLinkInfo#95bf0ec4: field photo: %w", err) } b.PutInt32(c.AccentColorID) b.PutString(c.Description) @@ -252,6 +262,9 @@ func (c *ChatInviteLinkInfo) EncodeBare(b *bin.Buffer) error { for _, v := range c.MemberUserIDs { b.PutInt53(v) } + if err := c.SubscriptionInfo.Encode(b); err != nil { + return fmt.Errorf("unable to encode chatInviteLinkInfo#95bf0ec4: field subscription_info: %w", err) + } b.PutBool(c.CreatesJoinRequest) b.PutBool(c.IsPublic) b.PutBool(c.IsVerified) @@ -263,10 +276,10 @@ func (c *ChatInviteLinkInfo) EncodeBare(b *bin.Buffer) error { // Decode implements bin.Decoder. func (c *ChatInviteLinkInfo) Decode(b *bin.Buffer) error { if c == nil { - return fmt.Errorf("can't decode chatInviteLinkInfo#829e9f23 to nil") + return fmt.Errorf("can't decode chatInviteLinkInfo#95bf0ec4 to nil") } if err := b.ConsumeID(ChatInviteLinkInfoTypeID); err != nil { - return fmt.Errorf("unable to decode chatInviteLinkInfo#829e9f23: %w", err) + return fmt.Errorf("unable to decode chatInviteLinkInfo#95bf0ec4: %w", err) } return c.DecodeBare(b) } @@ -274,66 +287,66 @@ func (c *ChatInviteLinkInfo) Decode(b *bin.Buffer) error { // DecodeBare implements bin.BareDecoder. func (c *ChatInviteLinkInfo) DecodeBare(b *bin.Buffer) error { if c == nil { - return fmt.Errorf("can't decode chatInviteLinkInfo#829e9f23 to nil") + return fmt.Errorf("can't decode chatInviteLinkInfo#95bf0ec4 to nil") } { value, err := b.Int53() if err != nil { - return fmt.Errorf("unable to decode chatInviteLinkInfo#829e9f23: field chat_id: %w", err) + return fmt.Errorf("unable to decode chatInviteLinkInfo#95bf0ec4: field chat_id: %w", err) } c.ChatID = value } { value, err := b.Int32() if err != nil { - return fmt.Errorf("unable to decode chatInviteLinkInfo#829e9f23: field accessible_for: %w", err) + return fmt.Errorf("unable to decode chatInviteLinkInfo#95bf0ec4: field accessible_for: %w", err) } c.AccessibleFor = value } { value, err := DecodeInviteLinkChatType(b) if err != nil { - return fmt.Errorf("unable to decode chatInviteLinkInfo#829e9f23: field type: %w", err) + return fmt.Errorf("unable to decode chatInviteLinkInfo#95bf0ec4: field type: %w", err) } c.Type = value } { value, err := b.String() if err != nil { - return fmt.Errorf("unable to decode chatInviteLinkInfo#829e9f23: field title: %w", err) + return fmt.Errorf("unable to decode chatInviteLinkInfo#95bf0ec4: field title: %w", err) } c.Title = value } { if err := c.Photo.Decode(b); err != nil { - return fmt.Errorf("unable to decode chatInviteLinkInfo#829e9f23: field photo: %w", err) + return fmt.Errorf("unable to decode chatInviteLinkInfo#95bf0ec4: field photo: %w", err) } } { value, err := b.Int32() if err != nil { - return fmt.Errorf("unable to decode chatInviteLinkInfo#829e9f23: field accent_color_id: %w", err) + return fmt.Errorf("unable to decode chatInviteLinkInfo#95bf0ec4: field accent_color_id: %w", err) } c.AccentColorID = value } { value, err := b.String() if err != nil { - return fmt.Errorf("unable to decode chatInviteLinkInfo#829e9f23: field description: %w", err) + return fmt.Errorf("unable to decode chatInviteLinkInfo#95bf0ec4: field description: %w", err) } c.Description = value } { value, err := b.Int32() if err != nil { - return fmt.Errorf("unable to decode chatInviteLinkInfo#829e9f23: field member_count: %w", err) + return fmt.Errorf("unable to decode chatInviteLinkInfo#95bf0ec4: field member_count: %w", err) } c.MemberCount = value } { headerLen, err := b.Int() if err != nil { - return fmt.Errorf("unable to decode chatInviteLinkInfo#829e9f23: field member_user_ids: %w", err) + return fmt.Errorf("unable to decode chatInviteLinkInfo#95bf0ec4: field member_user_ids: %w", err) } if headerLen > 0 { @@ -342,43 +355,48 @@ func (c *ChatInviteLinkInfo) DecodeBare(b *bin.Buffer) error { for idx := 0; idx < headerLen; idx++ { value, err := b.Int53() if err != nil { - return fmt.Errorf("unable to decode chatInviteLinkInfo#829e9f23: field member_user_ids: %w", err) + return fmt.Errorf("unable to decode chatInviteLinkInfo#95bf0ec4: field member_user_ids: %w", err) } c.MemberUserIDs = append(c.MemberUserIDs, value) } } + { + if err := c.SubscriptionInfo.Decode(b); err != nil { + return fmt.Errorf("unable to decode chatInviteLinkInfo#95bf0ec4: field subscription_info: %w", err) + } + } { value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode chatInviteLinkInfo#829e9f23: field creates_join_request: %w", err) + return fmt.Errorf("unable to decode chatInviteLinkInfo#95bf0ec4: field creates_join_request: %w", err) } c.CreatesJoinRequest = value } { value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode chatInviteLinkInfo#829e9f23: field is_public: %w", err) + return fmt.Errorf("unable to decode chatInviteLinkInfo#95bf0ec4: field is_public: %w", err) } c.IsPublic = value } { value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode chatInviteLinkInfo#829e9f23: field is_verified: %w", err) + return fmt.Errorf("unable to decode chatInviteLinkInfo#95bf0ec4: field is_verified: %w", err) } c.IsVerified = value } { value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode chatInviteLinkInfo#829e9f23: field is_scam: %w", err) + return fmt.Errorf("unable to decode chatInviteLinkInfo#95bf0ec4: field is_scam: %w", err) } c.IsScam = value } { value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode chatInviteLinkInfo#829e9f23: field is_fake: %w", err) + return fmt.Errorf("unable to decode chatInviteLinkInfo#95bf0ec4: field is_fake: %w", err) } c.IsFake = value } @@ -388,7 +406,7 @@ func (c *ChatInviteLinkInfo) DecodeBare(b *bin.Buffer) error { // EncodeTDLibJSON implements tdjson.TDLibEncoder. func (c *ChatInviteLinkInfo) EncodeTDLibJSON(b tdjson.Encoder) error { if c == nil { - return fmt.Errorf("can't encode chatInviteLinkInfo#829e9f23 as nil") + return fmt.Errorf("can't encode chatInviteLinkInfo#95bf0ec4 as nil") } b.ObjStart() b.PutID("chatInviteLinkInfo") @@ -401,10 +419,10 @@ func (c *ChatInviteLinkInfo) EncodeTDLibJSON(b tdjson.Encoder) error { b.Comma() b.FieldStart("type") if c.Type == nil { - return fmt.Errorf("unable to encode chatInviteLinkInfo#829e9f23: field type is nil") + return fmt.Errorf("unable to encode chatInviteLinkInfo#95bf0ec4: field type is nil") } if err := c.Type.EncodeTDLibJSON(b); err != nil { - return fmt.Errorf("unable to encode chatInviteLinkInfo#829e9f23: field type: %w", err) + return fmt.Errorf("unable to encode chatInviteLinkInfo#95bf0ec4: field type: %w", err) } b.Comma() b.FieldStart("title") @@ -412,7 +430,7 @@ func (c *ChatInviteLinkInfo) EncodeTDLibJSON(b tdjson.Encoder) error { b.Comma() b.FieldStart("photo") if err := c.Photo.EncodeTDLibJSON(b); err != nil { - return fmt.Errorf("unable to encode chatInviteLinkInfo#829e9f23: field photo: %w", err) + return fmt.Errorf("unable to encode chatInviteLinkInfo#95bf0ec4: field photo: %w", err) } b.Comma() b.FieldStart("accent_color_id") @@ -433,6 +451,11 @@ func (c *ChatInviteLinkInfo) EncodeTDLibJSON(b tdjson.Encoder) error { b.StripComma() b.ArrEnd() b.Comma() + b.FieldStart("subscription_info") + if err := c.SubscriptionInfo.EncodeTDLibJSON(b); err != nil { + return fmt.Errorf("unable to encode chatInviteLinkInfo#95bf0ec4: field subscription_info: %w", err) + } + b.Comma() b.FieldStart("creates_join_request") b.PutBool(c.CreatesJoinRequest) b.Comma() @@ -456,100 +479,104 @@ func (c *ChatInviteLinkInfo) EncodeTDLibJSON(b tdjson.Encoder) error { // DecodeTDLibJSON implements tdjson.TDLibDecoder. func (c *ChatInviteLinkInfo) DecodeTDLibJSON(b tdjson.Decoder) error { if c == nil { - return fmt.Errorf("can't decode chatInviteLinkInfo#829e9f23 to nil") + return fmt.Errorf("can't decode chatInviteLinkInfo#95bf0ec4 to nil") } return b.Obj(func(b tdjson.Decoder, key []byte) error { switch string(key) { case tdjson.TypeField: if err := b.ConsumeID("chatInviteLinkInfo"); err != nil { - return fmt.Errorf("unable to decode chatInviteLinkInfo#829e9f23: %w", err) + return fmt.Errorf("unable to decode chatInviteLinkInfo#95bf0ec4: %w", err) } case "chat_id": value, err := b.Int53() if err != nil { - return fmt.Errorf("unable to decode chatInviteLinkInfo#829e9f23: field chat_id: %w", err) + return fmt.Errorf("unable to decode chatInviteLinkInfo#95bf0ec4: field chat_id: %w", err) } c.ChatID = value case "accessible_for": value, err := b.Int32() if err != nil { - return fmt.Errorf("unable to decode chatInviteLinkInfo#829e9f23: field accessible_for: %w", err) + return fmt.Errorf("unable to decode chatInviteLinkInfo#95bf0ec4: field accessible_for: %w", err) } c.AccessibleFor = value case "type": value, err := DecodeTDLibJSONInviteLinkChatType(b) if err != nil { - return fmt.Errorf("unable to decode chatInviteLinkInfo#829e9f23: field type: %w", err) + return fmt.Errorf("unable to decode chatInviteLinkInfo#95bf0ec4: field type: %w", err) } c.Type = value case "title": value, err := b.String() if err != nil { - return fmt.Errorf("unable to decode chatInviteLinkInfo#829e9f23: field title: %w", err) + return fmt.Errorf("unable to decode chatInviteLinkInfo#95bf0ec4: field title: %w", err) } c.Title = value case "photo": if err := c.Photo.DecodeTDLibJSON(b); err != nil { - return fmt.Errorf("unable to decode chatInviteLinkInfo#829e9f23: field photo: %w", err) + return fmt.Errorf("unable to decode chatInviteLinkInfo#95bf0ec4: field photo: %w", err) } case "accent_color_id": value, err := b.Int32() if err != nil { - return fmt.Errorf("unable to decode chatInviteLinkInfo#829e9f23: field accent_color_id: %w", err) + return fmt.Errorf("unable to decode chatInviteLinkInfo#95bf0ec4: field accent_color_id: %w", err) } c.AccentColorID = value case "description": value, err := b.String() if err != nil { - return fmt.Errorf("unable to decode chatInviteLinkInfo#829e9f23: field description: %w", err) + return fmt.Errorf("unable to decode chatInviteLinkInfo#95bf0ec4: field description: %w", err) } c.Description = value case "member_count": value, err := b.Int32() if err != nil { - return fmt.Errorf("unable to decode chatInviteLinkInfo#829e9f23: field member_count: %w", err) + return fmt.Errorf("unable to decode chatInviteLinkInfo#95bf0ec4: field member_count: %w", err) } c.MemberCount = value case "member_user_ids": if err := b.Arr(func(b tdjson.Decoder) error { value, err := b.Int53() if err != nil { - return fmt.Errorf("unable to decode chatInviteLinkInfo#829e9f23: field member_user_ids: %w", err) + return fmt.Errorf("unable to decode chatInviteLinkInfo#95bf0ec4: field member_user_ids: %w", err) } c.MemberUserIDs = append(c.MemberUserIDs, value) return nil }); err != nil { - return fmt.Errorf("unable to decode chatInviteLinkInfo#829e9f23: field member_user_ids: %w", err) + return fmt.Errorf("unable to decode chatInviteLinkInfo#95bf0ec4: field member_user_ids: %w", err) + } + case "subscription_info": + if err := c.SubscriptionInfo.DecodeTDLibJSON(b); err != nil { + return fmt.Errorf("unable to decode chatInviteLinkInfo#95bf0ec4: field subscription_info: %w", err) } case "creates_join_request": value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode chatInviteLinkInfo#829e9f23: field creates_join_request: %w", err) + return fmt.Errorf("unable to decode chatInviteLinkInfo#95bf0ec4: field creates_join_request: %w", err) } c.CreatesJoinRequest = value case "is_public": value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode chatInviteLinkInfo#829e9f23: field is_public: %w", err) + return fmt.Errorf("unable to decode chatInviteLinkInfo#95bf0ec4: field is_public: %w", err) } c.IsPublic = value case "is_verified": value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode chatInviteLinkInfo#829e9f23: field is_verified: %w", err) + return fmt.Errorf("unable to decode chatInviteLinkInfo#95bf0ec4: field is_verified: %w", err) } c.IsVerified = value case "is_scam": value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode chatInviteLinkInfo#829e9f23: field is_scam: %w", err) + return fmt.Errorf("unable to decode chatInviteLinkInfo#95bf0ec4: field is_scam: %w", err) } c.IsScam = value case "is_fake": value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode chatInviteLinkInfo#829e9f23: field is_fake: %w", err) + return fmt.Errorf("unable to decode chatInviteLinkInfo#95bf0ec4: field is_fake: %w", err) } c.IsFake = value default: @@ -631,6 +658,14 @@ func (c *ChatInviteLinkInfo) GetMemberUserIDs() (value []int64) { return c.MemberUserIDs } +// GetSubscriptionInfo returns value of SubscriptionInfo field. +func (c *ChatInviteLinkInfo) GetSubscriptionInfo() (value ChatInviteLinkSubscriptionInfo) { + if c == nil { + return + } + return c.SubscriptionInfo +} + // GetCreatesJoinRequest returns value of CreatesJoinRequest field. func (c *ChatInviteLinkInfo) GetCreatesJoinRequest() (value bool) { if c == nil { diff --git a/tdapi/tl_chat_invite_link_subscription_info_gen.go b/tdapi/tl_chat_invite_link_subscription_info_gen.go new file mode 100644 index 0000000000..2e9d928cc7 --- /dev/null +++ b/tdapi/tl_chat_invite_link_subscription_info_gen.go @@ -0,0 +1,263 @@ +// Code generated by gotdgen, DO NOT EDIT. + +package tdapi + +import ( + "context" + "errors" + "fmt" + "sort" + "strings" + + "go.uber.org/multierr" + + "github.com/gotd/td/bin" + "github.com/gotd/td/tdjson" + "github.com/gotd/td/tdp" + "github.com/gotd/td/tgerr" +) + +// No-op definition for keeping imports. +var ( + _ = bin.Buffer{} + _ = context.Background() + _ = fmt.Stringer(nil) + _ = strings.Builder{} + _ = errors.Is + _ = multierr.AppendInto + _ = sort.Ints + _ = tdp.Format + _ = tgerr.Error{} + _ = tdjson.Encoder{} +) + +// ChatInviteLinkSubscriptionInfo represents TL type `chatInviteLinkSubscriptionInfo#38cf7368`. +type ChatInviteLinkSubscriptionInfo struct { + // Information about subscription plan that must be paid by the user to use the link + Pricing StarSubscriptionPricing + // True, if the user has already paid for the subscription and can use + // joinChatByInviteLink to join the subscribed chat again + CanReuse bool + // Identifier of the payment form to use for subscription payment; 0 if the subscription + // can't be paid + FormID int64 +} + +// ChatInviteLinkSubscriptionInfoTypeID is TL type id of ChatInviteLinkSubscriptionInfo. +const ChatInviteLinkSubscriptionInfoTypeID = 0x38cf7368 + +// Ensuring interfaces in compile-time for ChatInviteLinkSubscriptionInfo. +var ( + _ bin.Encoder = &ChatInviteLinkSubscriptionInfo{} + _ bin.Decoder = &ChatInviteLinkSubscriptionInfo{} + _ bin.BareEncoder = &ChatInviteLinkSubscriptionInfo{} + _ bin.BareDecoder = &ChatInviteLinkSubscriptionInfo{} +) + +func (c *ChatInviteLinkSubscriptionInfo) Zero() bool { + if c == nil { + return true + } + if !(c.Pricing.Zero()) { + return false + } + if !(c.CanReuse == false) { + return false + } + if !(c.FormID == 0) { + return false + } + + return true +} + +// String implements fmt.Stringer. +func (c *ChatInviteLinkSubscriptionInfo) String() string { + if c == nil { + return "ChatInviteLinkSubscriptionInfo(nil)" + } + type Alias ChatInviteLinkSubscriptionInfo + return fmt.Sprintf("ChatInviteLinkSubscriptionInfo%+v", Alias(*c)) +} + +// TypeID returns type id in TL schema. +// +// See https://core.telegram.org/mtproto/TL-tl#remarks. +func (*ChatInviteLinkSubscriptionInfo) TypeID() uint32 { + return ChatInviteLinkSubscriptionInfoTypeID +} + +// TypeName returns name of type in TL schema. +func (*ChatInviteLinkSubscriptionInfo) TypeName() string { + return "chatInviteLinkSubscriptionInfo" +} + +// TypeInfo returns info about TL type. +func (c *ChatInviteLinkSubscriptionInfo) TypeInfo() tdp.Type { + typ := tdp.Type{ + Name: "chatInviteLinkSubscriptionInfo", + ID: ChatInviteLinkSubscriptionInfoTypeID, + } + if c == nil { + typ.Null = true + return typ + } + typ.Fields = []tdp.Field{ + { + Name: "Pricing", + SchemaName: "pricing", + }, + { + Name: "CanReuse", + SchemaName: "can_reuse", + }, + { + Name: "FormID", + SchemaName: "form_id", + }, + } + return typ +} + +// Encode implements bin.Encoder. +func (c *ChatInviteLinkSubscriptionInfo) Encode(b *bin.Buffer) error { + if c == nil { + return fmt.Errorf("can't encode chatInviteLinkSubscriptionInfo#38cf7368 as nil") + } + b.PutID(ChatInviteLinkSubscriptionInfoTypeID) + return c.EncodeBare(b) +} + +// EncodeBare implements bin.BareEncoder. +func (c *ChatInviteLinkSubscriptionInfo) EncodeBare(b *bin.Buffer) error { + if c == nil { + return fmt.Errorf("can't encode chatInviteLinkSubscriptionInfo#38cf7368 as nil") + } + if err := c.Pricing.Encode(b); err != nil { + return fmt.Errorf("unable to encode chatInviteLinkSubscriptionInfo#38cf7368: field pricing: %w", err) + } + b.PutBool(c.CanReuse) + b.PutLong(c.FormID) + return nil +} + +// Decode implements bin.Decoder. +func (c *ChatInviteLinkSubscriptionInfo) Decode(b *bin.Buffer) error { + if c == nil { + return fmt.Errorf("can't decode chatInviteLinkSubscriptionInfo#38cf7368 to nil") + } + if err := b.ConsumeID(ChatInviteLinkSubscriptionInfoTypeID); err != nil { + return fmt.Errorf("unable to decode chatInviteLinkSubscriptionInfo#38cf7368: %w", err) + } + return c.DecodeBare(b) +} + +// DecodeBare implements bin.BareDecoder. +func (c *ChatInviteLinkSubscriptionInfo) DecodeBare(b *bin.Buffer) error { + if c == nil { + return fmt.Errorf("can't decode chatInviteLinkSubscriptionInfo#38cf7368 to nil") + } + { + if err := c.Pricing.Decode(b); err != nil { + return fmt.Errorf("unable to decode chatInviteLinkSubscriptionInfo#38cf7368: field pricing: %w", err) + } + } + { + value, err := b.Bool() + if err != nil { + return fmt.Errorf("unable to decode chatInviteLinkSubscriptionInfo#38cf7368: field can_reuse: %w", err) + } + c.CanReuse = value + } + { + value, err := b.Long() + if err != nil { + return fmt.Errorf("unable to decode chatInviteLinkSubscriptionInfo#38cf7368: field form_id: %w", err) + } + c.FormID = value + } + return nil +} + +// EncodeTDLibJSON implements tdjson.TDLibEncoder. +func (c *ChatInviteLinkSubscriptionInfo) EncodeTDLibJSON(b tdjson.Encoder) error { + if c == nil { + return fmt.Errorf("can't encode chatInviteLinkSubscriptionInfo#38cf7368 as nil") + } + b.ObjStart() + b.PutID("chatInviteLinkSubscriptionInfo") + b.Comma() + b.FieldStart("pricing") + if err := c.Pricing.EncodeTDLibJSON(b); err != nil { + return fmt.Errorf("unable to encode chatInviteLinkSubscriptionInfo#38cf7368: field pricing: %w", err) + } + b.Comma() + b.FieldStart("can_reuse") + b.PutBool(c.CanReuse) + b.Comma() + b.FieldStart("form_id") + b.PutLong(c.FormID) + b.Comma() + b.StripComma() + b.ObjEnd() + return nil +} + +// DecodeTDLibJSON implements tdjson.TDLibDecoder. +func (c *ChatInviteLinkSubscriptionInfo) DecodeTDLibJSON(b tdjson.Decoder) error { + if c == nil { + return fmt.Errorf("can't decode chatInviteLinkSubscriptionInfo#38cf7368 to nil") + } + + return b.Obj(func(b tdjson.Decoder, key []byte) error { + switch string(key) { + case tdjson.TypeField: + if err := b.ConsumeID("chatInviteLinkSubscriptionInfo"); err != nil { + return fmt.Errorf("unable to decode chatInviteLinkSubscriptionInfo#38cf7368: %w", err) + } + case "pricing": + if err := c.Pricing.DecodeTDLibJSON(b); err != nil { + return fmt.Errorf("unable to decode chatInviteLinkSubscriptionInfo#38cf7368: field pricing: %w", err) + } + case "can_reuse": + value, err := b.Bool() + if err != nil { + return fmt.Errorf("unable to decode chatInviteLinkSubscriptionInfo#38cf7368: field can_reuse: %w", err) + } + c.CanReuse = value + case "form_id": + value, err := b.Long() + if err != nil { + return fmt.Errorf("unable to decode chatInviteLinkSubscriptionInfo#38cf7368: field form_id: %w", err) + } + c.FormID = value + default: + return b.Skip() + } + return nil + }) +} + +// GetPricing returns value of Pricing field. +func (c *ChatInviteLinkSubscriptionInfo) GetPricing() (value StarSubscriptionPricing) { + if c == nil { + return + } + return c.Pricing +} + +// GetCanReuse returns value of CanReuse field. +func (c *ChatInviteLinkSubscriptionInfo) GetCanReuse() (value bool) { + if c == nil { + return + } + return c.CanReuse +} + +// GetFormID returns value of FormID field. +func (c *ChatInviteLinkSubscriptionInfo) GetFormID() (value int64) { + if c == nil { + return + } + return c.FormID +} diff --git a/tdapi/tl_chat_member_status_gen.go b/tdapi/tl_chat_member_status_gen.go index 7e145d11d4..e084b92658 100644 --- a/tdapi/tl_chat_member_status_gen.go +++ b/tdapi/tl_chat_member_status_gen.go @@ -502,12 +502,15 @@ func (c *ChatMemberStatusAdministrator) GetRights() (value ChatAdministratorRigh return c.Rights } -// ChatMemberStatusMember represents TL type `chatMemberStatusMember#32597455`. +// ChatMemberStatusMember represents TL type `chatMemberStatusMember#fe0cec16`. type ChatMemberStatusMember struct { + // Point in time (Unix timestamp) when the user will be removed from the chat because of + // the expired subscription; 0 if never. Ignored in setChatMemberStatus + MemberUntilDate int32 } // ChatMemberStatusMemberTypeID is TL type id of ChatMemberStatusMember. -const ChatMemberStatusMemberTypeID = 0x32597455 +const ChatMemberStatusMemberTypeID = 0xfe0cec16 // construct implements constructor of ChatMemberStatusClass. func (c ChatMemberStatusMember) construct() ChatMemberStatusClass { return &c } @@ -526,6 +529,9 @@ func (c *ChatMemberStatusMember) Zero() bool { if c == nil { return true } + if !(c.MemberUntilDate == 0) { + return false + } return true } @@ -561,14 +567,19 @@ func (c *ChatMemberStatusMember) TypeInfo() tdp.Type { typ.Null = true return typ } - typ.Fields = []tdp.Field{} + typ.Fields = []tdp.Field{ + { + Name: "MemberUntilDate", + SchemaName: "member_until_date", + }, + } return typ } // Encode implements bin.Encoder. func (c *ChatMemberStatusMember) Encode(b *bin.Buffer) error { if c == nil { - return fmt.Errorf("can't encode chatMemberStatusMember#32597455 as nil") + return fmt.Errorf("can't encode chatMemberStatusMember#fe0cec16 as nil") } b.PutID(ChatMemberStatusMemberTypeID) return c.EncodeBare(b) @@ -577,18 +588,19 @@ func (c *ChatMemberStatusMember) Encode(b *bin.Buffer) error { // EncodeBare implements bin.BareEncoder. func (c *ChatMemberStatusMember) EncodeBare(b *bin.Buffer) error { if c == nil { - return fmt.Errorf("can't encode chatMemberStatusMember#32597455 as nil") + return fmt.Errorf("can't encode chatMemberStatusMember#fe0cec16 as nil") } + b.PutInt32(c.MemberUntilDate) return nil } // Decode implements bin.Decoder. func (c *ChatMemberStatusMember) Decode(b *bin.Buffer) error { if c == nil { - return fmt.Errorf("can't decode chatMemberStatusMember#32597455 to nil") + return fmt.Errorf("can't decode chatMemberStatusMember#fe0cec16 to nil") } if err := b.ConsumeID(ChatMemberStatusMemberTypeID); err != nil { - return fmt.Errorf("unable to decode chatMemberStatusMember#32597455: %w", err) + return fmt.Errorf("unable to decode chatMemberStatusMember#fe0cec16: %w", err) } return c.DecodeBare(b) } @@ -596,7 +608,14 @@ func (c *ChatMemberStatusMember) Decode(b *bin.Buffer) error { // DecodeBare implements bin.BareDecoder. func (c *ChatMemberStatusMember) DecodeBare(b *bin.Buffer) error { if c == nil { - return fmt.Errorf("can't decode chatMemberStatusMember#32597455 to nil") + return fmt.Errorf("can't decode chatMemberStatusMember#fe0cec16 to nil") + } + { + value, err := b.Int32() + if err != nil { + return fmt.Errorf("unable to decode chatMemberStatusMember#fe0cec16: field member_until_date: %w", err) + } + c.MemberUntilDate = value } return nil } @@ -604,11 +623,14 @@ func (c *ChatMemberStatusMember) DecodeBare(b *bin.Buffer) error { // EncodeTDLibJSON implements tdjson.TDLibEncoder. func (c *ChatMemberStatusMember) EncodeTDLibJSON(b tdjson.Encoder) error { if c == nil { - return fmt.Errorf("can't encode chatMemberStatusMember#32597455 as nil") + return fmt.Errorf("can't encode chatMemberStatusMember#fe0cec16 as nil") } b.ObjStart() b.PutID("chatMemberStatusMember") b.Comma() + b.FieldStart("member_until_date") + b.PutInt32(c.MemberUntilDate) + b.Comma() b.StripComma() b.ObjEnd() return nil @@ -617,15 +639,21 @@ func (c *ChatMemberStatusMember) EncodeTDLibJSON(b tdjson.Encoder) error { // DecodeTDLibJSON implements tdjson.TDLibDecoder. func (c *ChatMemberStatusMember) DecodeTDLibJSON(b tdjson.Decoder) error { if c == nil { - return fmt.Errorf("can't decode chatMemberStatusMember#32597455 to nil") + return fmt.Errorf("can't decode chatMemberStatusMember#fe0cec16 to nil") } return b.Obj(func(b tdjson.Decoder, key []byte) error { switch string(key) { case tdjson.TypeField: if err := b.ConsumeID("chatMemberStatusMember"); err != nil { - return fmt.Errorf("unable to decode chatMemberStatusMember#32597455: %w", err) + return fmt.Errorf("unable to decode chatMemberStatusMember#fe0cec16: %w", err) + } + case "member_until_date": + value, err := b.Int32() + if err != nil { + return fmt.Errorf("unable to decode chatMemberStatusMember#fe0cec16: field member_until_date: %w", err) } + c.MemberUntilDate = value default: return b.Skip() } @@ -633,6 +661,14 @@ func (c *ChatMemberStatusMember) DecodeTDLibJSON(b tdjson.Decoder) error { }) } +// GetMemberUntilDate returns value of MemberUntilDate field. +func (c *ChatMemberStatusMember) GetMemberUntilDate() (value int32) { + if c == nil { + return + } + return c.MemberUntilDate +} + // ChatMemberStatusRestricted represents TL type `chatMemberStatusRestricted#630774a6`. type ChatMemberStatusRestricted struct { // True, if the user is a member of the chat @@ -1182,7 +1218,7 @@ const ChatMemberStatusClassName = "ChatMemberStatus" // switch v := g.(type) { // case *tdapi.ChatMemberStatusCreator: // chatMemberStatusCreator#f6764afe // case *tdapi.ChatMemberStatusAdministrator: // chatMemberStatusAdministrator#fbd3841d -// case *tdapi.ChatMemberStatusMember: // chatMemberStatusMember#32597455 +// case *tdapi.ChatMemberStatusMember: // chatMemberStatusMember#fe0cec16 // case *tdapi.ChatMemberStatusRestricted: // chatMemberStatusRestricted#630774a6 // case *tdapi.ChatMemberStatusLeft: // chatMemberStatusLeft#ffa74425 // case *tdapi.ChatMemberStatusBanned: // chatMemberStatusBanned#9d714eb6 @@ -1232,7 +1268,7 @@ func DecodeChatMemberStatus(buf *bin.Buffer) (ChatMemberStatusClass, error) { } return &v, nil case ChatMemberStatusMemberTypeID: - // Decoding chatMemberStatusMember#32597455. + // Decoding chatMemberStatusMember#fe0cec16. v := ChatMemberStatusMember{} if err := v.Decode(buf); err != nil { return nil, fmt.Errorf("unable to decode ChatMemberStatusClass: %w", err) @@ -1286,7 +1322,7 @@ func DecodeTDLibJSONChatMemberStatus(buf tdjson.Decoder) (ChatMemberStatusClass, } return &v, nil case "chatMemberStatusMember": - // Decoding chatMemberStatusMember#32597455. + // Decoding chatMemberStatusMember#fe0cec16. v := ChatMemberStatusMember{} if err := v.DecodeTDLibJSON(buf); err != nil { return nil, fmt.Errorf("unable to decode ChatMemberStatusClass: %w", err) diff --git a/tdapi/tl_create_chat_subscription_invite_link_gen.go b/tdapi/tl_create_chat_subscription_invite_link_gen.go new file mode 100644 index 0000000000..0ef2081a5b --- /dev/null +++ b/tdapi/tl_create_chat_subscription_invite_link_gen.go @@ -0,0 +1,272 @@ +// Code generated by gotdgen, DO NOT EDIT. + +package tdapi + +import ( + "context" + "errors" + "fmt" + "sort" + "strings" + + "go.uber.org/multierr" + + "github.com/gotd/td/bin" + "github.com/gotd/td/tdjson" + "github.com/gotd/td/tdp" + "github.com/gotd/td/tgerr" +) + +// No-op definition for keeping imports. +var ( + _ = bin.Buffer{} + _ = context.Background() + _ = fmt.Stringer(nil) + _ = strings.Builder{} + _ = errors.Is + _ = multierr.AppendInto + _ = sort.Ints + _ = tdp.Format + _ = tgerr.Error{} + _ = tdjson.Encoder{} +) + +// CreateChatSubscriptionInviteLinkRequest represents TL type `createChatSubscriptionInviteLink#226b65`. +type CreateChatSubscriptionInviteLinkRequest struct { + // Chat identifier + ChatID int64 + // Invite link name; 0-32 characters + Name string + // Information about subscription plan that will be applied to the users joining the chat + // via the link. + SubscriptionPricing StarSubscriptionPricing +} + +// CreateChatSubscriptionInviteLinkRequestTypeID is TL type id of CreateChatSubscriptionInviteLinkRequest. +const CreateChatSubscriptionInviteLinkRequestTypeID = 0x226b65 + +// Ensuring interfaces in compile-time for CreateChatSubscriptionInviteLinkRequest. +var ( + _ bin.Encoder = &CreateChatSubscriptionInviteLinkRequest{} + _ bin.Decoder = &CreateChatSubscriptionInviteLinkRequest{} + _ bin.BareEncoder = &CreateChatSubscriptionInviteLinkRequest{} + _ bin.BareDecoder = &CreateChatSubscriptionInviteLinkRequest{} +) + +func (c *CreateChatSubscriptionInviteLinkRequest) Zero() bool { + if c == nil { + return true + } + if !(c.ChatID == 0) { + return false + } + if !(c.Name == "") { + return false + } + if !(c.SubscriptionPricing.Zero()) { + return false + } + + return true +} + +// String implements fmt.Stringer. +func (c *CreateChatSubscriptionInviteLinkRequest) String() string { + if c == nil { + return "CreateChatSubscriptionInviteLinkRequest(nil)" + } + type Alias CreateChatSubscriptionInviteLinkRequest + return fmt.Sprintf("CreateChatSubscriptionInviteLinkRequest%+v", Alias(*c)) +} + +// TypeID returns type id in TL schema. +// +// See https://core.telegram.org/mtproto/TL-tl#remarks. +func (*CreateChatSubscriptionInviteLinkRequest) TypeID() uint32 { + return CreateChatSubscriptionInviteLinkRequestTypeID +} + +// TypeName returns name of type in TL schema. +func (*CreateChatSubscriptionInviteLinkRequest) TypeName() string { + return "createChatSubscriptionInviteLink" +} + +// TypeInfo returns info about TL type. +func (c *CreateChatSubscriptionInviteLinkRequest) TypeInfo() tdp.Type { + typ := tdp.Type{ + Name: "createChatSubscriptionInviteLink", + ID: CreateChatSubscriptionInviteLinkRequestTypeID, + } + if c == nil { + typ.Null = true + return typ + } + typ.Fields = []tdp.Field{ + { + Name: "ChatID", + SchemaName: "chat_id", + }, + { + Name: "Name", + SchemaName: "name", + }, + { + Name: "SubscriptionPricing", + SchemaName: "subscription_pricing", + }, + } + return typ +} + +// Encode implements bin.Encoder. +func (c *CreateChatSubscriptionInviteLinkRequest) Encode(b *bin.Buffer) error { + if c == nil { + return fmt.Errorf("can't encode createChatSubscriptionInviteLink#226b65 as nil") + } + b.PutID(CreateChatSubscriptionInviteLinkRequestTypeID) + return c.EncodeBare(b) +} + +// EncodeBare implements bin.BareEncoder. +func (c *CreateChatSubscriptionInviteLinkRequest) EncodeBare(b *bin.Buffer) error { + if c == nil { + return fmt.Errorf("can't encode createChatSubscriptionInviteLink#226b65 as nil") + } + b.PutInt53(c.ChatID) + b.PutString(c.Name) + if err := c.SubscriptionPricing.Encode(b); err != nil { + return fmt.Errorf("unable to encode createChatSubscriptionInviteLink#226b65: field subscription_pricing: %w", err) + } + return nil +} + +// Decode implements bin.Decoder. +func (c *CreateChatSubscriptionInviteLinkRequest) Decode(b *bin.Buffer) error { + if c == nil { + return fmt.Errorf("can't decode createChatSubscriptionInviteLink#226b65 to nil") + } + if err := b.ConsumeID(CreateChatSubscriptionInviteLinkRequestTypeID); err != nil { + return fmt.Errorf("unable to decode createChatSubscriptionInviteLink#226b65: %w", err) + } + return c.DecodeBare(b) +} + +// DecodeBare implements bin.BareDecoder. +func (c *CreateChatSubscriptionInviteLinkRequest) DecodeBare(b *bin.Buffer) error { + if c == nil { + return fmt.Errorf("can't decode createChatSubscriptionInviteLink#226b65 to nil") + } + { + value, err := b.Int53() + if err != nil { + return fmt.Errorf("unable to decode createChatSubscriptionInviteLink#226b65: field chat_id: %w", err) + } + c.ChatID = value + } + { + value, err := b.String() + if err != nil { + return fmt.Errorf("unable to decode createChatSubscriptionInviteLink#226b65: field name: %w", err) + } + c.Name = value + } + { + if err := c.SubscriptionPricing.Decode(b); err != nil { + return fmt.Errorf("unable to decode createChatSubscriptionInviteLink#226b65: field subscription_pricing: %w", err) + } + } + return nil +} + +// EncodeTDLibJSON implements tdjson.TDLibEncoder. +func (c *CreateChatSubscriptionInviteLinkRequest) EncodeTDLibJSON(b tdjson.Encoder) error { + if c == nil { + return fmt.Errorf("can't encode createChatSubscriptionInviteLink#226b65 as nil") + } + b.ObjStart() + b.PutID("createChatSubscriptionInviteLink") + b.Comma() + b.FieldStart("chat_id") + b.PutInt53(c.ChatID) + b.Comma() + b.FieldStart("name") + b.PutString(c.Name) + b.Comma() + b.FieldStart("subscription_pricing") + if err := c.SubscriptionPricing.EncodeTDLibJSON(b); err != nil { + return fmt.Errorf("unable to encode createChatSubscriptionInviteLink#226b65: field subscription_pricing: %w", err) + } + b.Comma() + b.StripComma() + b.ObjEnd() + return nil +} + +// DecodeTDLibJSON implements tdjson.TDLibDecoder. +func (c *CreateChatSubscriptionInviteLinkRequest) DecodeTDLibJSON(b tdjson.Decoder) error { + if c == nil { + return fmt.Errorf("can't decode createChatSubscriptionInviteLink#226b65 to nil") + } + + return b.Obj(func(b tdjson.Decoder, key []byte) error { + switch string(key) { + case tdjson.TypeField: + if err := b.ConsumeID("createChatSubscriptionInviteLink"); err != nil { + return fmt.Errorf("unable to decode createChatSubscriptionInviteLink#226b65: %w", err) + } + case "chat_id": + value, err := b.Int53() + if err != nil { + return fmt.Errorf("unable to decode createChatSubscriptionInviteLink#226b65: field chat_id: %w", err) + } + c.ChatID = value + case "name": + value, err := b.String() + if err != nil { + return fmt.Errorf("unable to decode createChatSubscriptionInviteLink#226b65: field name: %w", err) + } + c.Name = value + case "subscription_pricing": + if err := c.SubscriptionPricing.DecodeTDLibJSON(b); err != nil { + return fmt.Errorf("unable to decode createChatSubscriptionInviteLink#226b65: field subscription_pricing: %w", err) + } + default: + return b.Skip() + } + return nil + }) +} + +// GetChatID returns value of ChatID field. +func (c *CreateChatSubscriptionInviteLinkRequest) GetChatID() (value int64) { + if c == nil { + return + } + return c.ChatID +} + +// GetName returns value of Name field. +func (c *CreateChatSubscriptionInviteLinkRequest) GetName() (value string) { + if c == nil { + return + } + return c.Name +} + +// GetSubscriptionPricing returns value of SubscriptionPricing field. +func (c *CreateChatSubscriptionInviteLinkRequest) GetSubscriptionPricing() (value StarSubscriptionPricing) { + if c == nil { + return + } + return c.SubscriptionPricing +} + +// CreateChatSubscriptionInviteLink invokes method createChatSubscriptionInviteLink#226b65 returning error if any. +func (c *Client) CreateChatSubscriptionInviteLink(ctx context.Context, request *CreateChatSubscriptionInviteLinkRequest) (*ChatInviteLink, error) { + var result ChatInviteLink + + if err := c.rpc.Invoke(ctx, request, &result); err != nil { + return nil, err + } + return &result, nil +} diff --git a/tdapi/tl_edit_chat_subscription_invite_link_gen.go b/tdapi/tl_edit_chat_subscription_invite_link_gen.go new file mode 100644 index 0000000000..8fd15aee49 --- /dev/null +++ b/tdapi/tl_edit_chat_subscription_invite_link_gen.go @@ -0,0 +1,271 @@ +// Code generated by gotdgen, DO NOT EDIT. + +package tdapi + +import ( + "context" + "errors" + "fmt" + "sort" + "strings" + + "go.uber.org/multierr" + + "github.com/gotd/td/bin" + "github.com/gotd/td/tdjson" + "github.com/gotd/td/tdp" + "github.com/gotd/td/tgerr" +) + +// No-op definition for keeping imports. +var ( + _ = bin.Buffer{} + _ = context.Background() + _ = fmt.Stringer(nil) + _ = strings.Builder{} + _ = errors.Is + _ = multierr.AppendInto + _ = sort.Ints + _ = tdp.Format + _ = tgerr.Error{} + _ = tdjson.Encoder{} +) + +// EditChatSubscriptionInviteLinkRequest represents TL type `editChatSubscriptionInviteLink#c74445d3`. +type EditChatSubscriptionInviteLinkRequest struct { + // Chat identifier + ChatID int64 + // Invite link to be edited + InviteLink string + // Invite link name; 0-32 characters + Name string +} + +// EditChatSubscriptionInviteLinkRequestTypeID is TL type id of EditChatSubscriptionInviteLinkRequest. +const EditChatSubscriptionInviteLinkRequestTypeID = 0xc74445d3 + +// Ensuring interfaces in compile-time for EditChatSubscriptionInviteLinkRequest. +var ( + _ bin.Encoder = &EditChatSubscriptionInviteLinkRequest{} + _ bin.Decoder = &EditChatSubscriptionInviteLinkRequest{} + _ bin.BareEncoder = &EditChatSubscriptionInviteLinkRequest{} + _ bin.BareDecoder = &EditChatSubscriptionInviteLinkRequest{} +) + +func (e *EditChatSubscriptionInviteLinkRequest) Zero() bool { + if e == nil { + return true + } + if !(e.ChatID == 0) { + return false + } + if !(e.InviteLink == "") { + return false + } + if !(e.Name == "") { + return false + } + + return true +} + +// String implements fmt.Stringer. +func (e *EditChatSubscriptionInviteLinkRequest) String() string { + if e == nil { + return "EditChatSubscriptionInviteLinkRequest(nil)" + } + type Alias EditChatSubscriptionInviteLinkRequest + return fmt.Sprintf("EditChatSubscriptionInviteLinkRequest%+v", Alias(*e)) +} + +// TypeID returns type id in TL schema. +// +// See https://core.telegram.org/mtproto/TL-tl#remarks. +func (*EditChatSubscriptionInviteLinkRequest) TypeID() uint32 { + return EditChatSubscriptionInviteLinkRequestTypeID +} + +// TypeName returns name of type in TL schema. +func (*EditChatSubscriptionInviteLinkRequest) TypeName() string { + return "editChatSubscriptionInviteLink" +} + +// TypeInfo returns info about TL type. +func (e *EditChatSubscriptionInviteLinkRequest) TypeInfo() tdp.Type { + typ := tdp.Type{ + Name: "editChatSubscriptionInviteLink", + ID: EditChatSubscriptionInviteLinkRequestTypeID, + } + if e == nil { + typ.Null = true + return typ + } + typ.Fields = []tdp.Field{ + { + Name: "ChatID", + SchemaName: "chat_id", + }, + { + Name: "InviteLink", + SchemaName: "invite_link", + }, + { + Name: "Name", + SchemaName: "name", + }, + } + return typ +} + +// Encode implements bin.Encoder. +func (e *EditChatSubscriptionInviteLinkRequest) Encode(b *bin.Buffer) error { + if e == nil { + return fmt.Errorf("can't encode editChatSubscriptionInviteLink#c74445d3 as nil") + } + b.PutID(EditChatSubscriptionInviteLinkRequestTypeID) + return e.EncodeBare(b) +} + +// EncodeBare implements bin.BareEncoder. +func (e *EditChatSubscriptionInviteLinkRequest) EncodeBare(b *bin.Buffer) error { + if e == nil { + return fmt.Errorf("can't encode editChatSubscriptionInviteLink#c74445d3 as nil") + } + b.PutInt53(e.ChatID) + b.PutString(e.InviteLink) + b.PutString(e.Name) + return nil +} + +// Decode implements bin.Decoder. +func (e *EditChatSubscriptionInviteLinkRequest) Decode(b *bin.Buffer) error { + if e == nil { + return fmt.Errorf("can't decode editChatSubscriptionInviteLink#c74445d3 to nil") + } + if err := b.ConsumeID(EditChatSubscriptionInviteLinkRequestTypeID); err != nil { + return fmt.Errorf("unable to decode editChatSubscriptionInviteLink#c74445d3: %w", err) + } + return e.DecodeBare(b) +} + +// DecodeBare implements bin.BareDecoder. +func (e *EditChatSubscriptionInviteLinkRequest) DecodeBare(b *bin.Buffer) error { + if e == nil { + return fmt.Errorf("can't decode editChatSubscriptionInviteLink#c74445d3 to nil") + } + { + value, err := b.Int53() + if err != nil { + return fmt.Errorf("unable to decode editChatSubscriptionInviteLink#c74445d3: field chat_id: %w", err) + } + e.ChatID = value + } + { + value, err := b.String() + if err != nil { + return fmt.Errorf("unable to decode editChatSubscriptionInviteLink#c74445d3: field invite_link: %w", err) + } + e.InviteLink = value + } + { + value, err := b.String() + if err != nil { + return fmt.Errorf("unable to decode editChatSubscriptionInviteLink#c74445d3: field name: %w", err) + } + e.Name = value + } + return nil +} + +// EncodeTDLibJSON implements tdjson.TDLibEncoder. +func (e *EditChatSubscriptionInviteLinkRequest) EncodeTDLibJSON(b tdjson.Encoder) error { + if e == nil { + return fmt.Errorf("can't encode editChatSubscriptionInviteLink#c74445d3 as nil") + } + b.ObjStart() + b.PutID("editChatSubscriptionInviteLink") + b.Comma() + b.FieldStart("chat_id") + b.PutInt53(e.ChatID) + b.Comma() + b.FieldStart("invite_link") + b.PutString(e.InviteLink) + b.Comma() + b.FieldStart("name") + b.PutString(e.Name) + b.Comma() + b.StripComma() + b.ObjEnd() + return nil +} + +// DecodeTDLibJSON implements tdjson.TDLibDecoder. +func (e *EditChatSubscriptionInviteLinkRequest) DecodeTDLibJSON(b tdjson.Decoder) error { + if e == nil { + return fmt.Errorf("can't decode editChatSubscriptionInviteLink#c74445d3 to nil") + } + + return b.Obj(func(b tdjson.Decoder, key []byte) error { + switch string(key) { + case tdjson.TypeField: + if err := b.ConsumeID("editChatSubscriptionInviteLink"); err != nil { + return fmt.Errorf("unable to decode editChatSubscriptionInviteLink#c74445d3: %w", err) + } + case "chat_id": + value, err := b.Int53() + if err != nil { + return fmt.Errorf("unable to decode editChatSubscriptionInviteLink#c74445d3: field chat_id: %w", err) + } + e.ChatID = value + case "invite_link": + value, err := b.String() + if err != nil { + return fmt.Errorf("unable to decode editChatSubscriptionInviteLink#c74445d3: field invite_link: %w", err) + } + e.InviteLink = value + case "name": + value, err := b.String() + if err != nil { + return fmt.Errorf("unable to decode editChatSubscriptionInviteLink#c74445d3: field name: %w", err) + } + e.Name = value + default: + return b.Skip() + } + return nil + }) +} + +// GetChatID returns value of ChatID field. +func (e *EditChatSubscriptionInviteLinkRequest) GetChatID() (value int64) { + if e == nil { + return + } + return e.ChatID +} + +// GetInviteLink returns value of InviteLink field. +func (e *EditChatSubscriptionInviteLinkRequest) GetInviteLink() (value string) { + if e == nil { + return + } + return e.InviteLink +} + +// GetName returns value of Name field. +func (e *EditChatSubscriptionInviteLinkRequest) GetName() (value string) { + if e == nil { + return + } + return e.Name +} + +// EditChatSubscriptionInviteLink invokes method editChatSubscriptionInviteLink#c74445d3 returning error if any. +func (c *Client) EditChatSubscriptionInviteLink(ctx context.Context, request *EditChatSubscriptionInviteLinkRequest) (*ChatInviteLink, error) { + var result ChatInviteLink + + if err := c.rpc.Invoke(ctx, request, &result); err != nil { + return nil, err + } + return &result, nil +} diff --git a/tdapi/tl_edit_star_subscription_gen.go b/tdapi/tl_edit_star_subscription_gen.go new file mode 100644 index 0000000000..00ba8dee01 --- /dev/null +++ b/tdapi/tl_edit_star_subscription_gen.go @@ -0,0 +1,237 @@ +// Code generated by gotdgen, DO NOT EDIT. + +package tdapi + +import ( + "context" + "errors" + "fmt" + "sort" + "strings" + + "go.uber.org/multierr" + + "github.com/gotd/td/bin" + "github.com/gotd/td/tdjson" + "github.com/gotd/td/tdp" + "github.com/gotd/td/tgerr" +) + +// No-op definition for keeping imports. +var ( + _ = bin.Buffer{} + _ = context.Background() + _ = fmt.Stringer(nil) + _ = strings.Builder{} + _ = errors.Is + _ = multierr.AppendInto + _ = sort.Ints + _ = tdp.Format + _ = tgerr.Error{} + _ = tdjson.Encoder{} +) + +// EditStarSubscriptionRequest represents TL type `editStarSubscription#7a1a3918`. +type EditStarSubscriptionRequest struct { + // Identifier of the subscription to change + SubscriptionID string + // New value of is_canceled + IsCanceled bool +} + +// EditStarSubscriptionRequestTypeID is TL type id of EditStarSubscriptionRequest. +const EditStarSubscriptionRequestTypeID = 0x7a1a3918 + +// Ensuring interfaces in compile-time for EditStarSubscriptionRequest. +var ( + _ bin.Encoder = &EditStarSubscriptionRequest{} + _ bin.Decoder = &EditStarSubscriptionRequest{} + _ bin.BareEncoder = &EditStarSubscriptionRequest{} + _ bin.BareDecoder = &EditStarSubscriptionRequest{} +) + +func (e *EditStarSubscriptionRequest) Zero() bool { + if e == nil { + return true + } + if !(e.SubscriptionID == "") { + return false + } + if !(e.IsCanceled == false) { + return false + } + + return true +} + +// String implements fmt.Stringer. +func (e *EditStarSubscriptionRequest) String() string { + if e == nil { + return "EditStarSubscriptionRequest(nil)" + } + type Alias EditStarSubscriptionRequest + return fmt.Sprintf("EditStarSubscriptionRequest%+v", Alias(*e)) +} + +// TypeID returns type id in TL schema. +// +// See https://core.telegram.org/mtproto/TL-tl#remarks. +func (*EditStarSubscriptionRequest) TypeID() uint32 { + return EditStarSubscriptionRequestTypeID +} + +// TypeName returns name of type in TL schema. +func (*EditStarSubscriptionRequest) TypeName() string { + return "editStarSubscription" +} + +// TypeInfo returns info about TL type. +func (e *EditStarSubscriptionRequest) TypeInfo() tdp.Type { + typ := tdp.Type{ + Name: "editStarSubscription", + ID: EditStarSubscriptionRequestTypeID, + } + if e == nil { + typ.Null = true + return typ + } + typ.Fields = []tdp.Field{ + { + Name: "SubscriptionID", + SchemaName: "subscription_id", + }, + { + Name: "IsCanceled", + SchemaName: "is_canceled", + }, + } + return typ +} + +// Encode implements bin.Encoder. +func (e *EditStarSubscriptionRequest) Encode(b *bin.Buffer) error { + if e == nil { + return fmt.Errorf("can't encode editStarSubscription#7a1a3918 as nil") + } + b.PutID(EditStarSubscriptionRequestTypeID) + return e.EncodeBare(b) +} + +// EncodeBare implements bin.BareEncoder. +func (e *EditStarSubscriptionRequest) EncodeBare(b *bin.Buffer) error { + if e == nil { + return fmt.Errorf("can't encode editStarSubscription#7a1a3918 as nil") + } + b.PutString(e.SubscriptionID) + b.PutBool(e.IsCanceled) + return nil +} + +// Decode implements bin.Decoder. +func (e *EditStarSubscriptionRequest) Decode(b *bin.Buffer) error { + if e == nil { + return fmt.Errorf("can't decode editStarSubscription#7a1a3918 to nil") + } + if err := b.ConsumeID(EditStarSubscriptionRequestTypeID); err != nil { + return fmt.Errorf("unable to decode editStarSubscription#7a1a3918: %w", err) + } + return e.DecodeBare(b) +} + +// DecodeBare implements bin.BareDecoder. +func (e *EditStarSubscriptionRequest) DecodeBare(b *bin.Buffer) error { + if e == nil { + return fmt.Errorf("can't decode editStarSubscription#7a1a3918 to nil") + } + { + value, err := b.String() + if err != nil { + return fmt.Errorf("unable to decode editStarSubscription#7a1a3918: field subscription_id: %w", err) + } + e.SubscriptionID = value + } + { + value, err := b.Bool() + if err != nil { + return fmt.Errorf("unable to decode editStarSubscription#7a1a3918: field is_canceled: %w", err) + } + e.IsCanceled = value + } + return nil +} + +// EncodeTDLibJSON implements tdjson.TDLibEncoder. +func (e *EditStarSubscriptionRequest) EncodeTDLibJSON(b tdjson.Encoder) error { + if e == nil { + return fmt.Errorf("can't encode editStarSubscription#7a1a3918 as nil") + } + b.ObjStart() + b.PutID("editStarSubscription") + b.Comma() + b.FieldStart("subscription_id") + b.PutString(e.SubscriptionID) + b.Comma() + b.FieldStart("is_canceled") + b.PutBool(e.IsCanceled) + b.Comma() + b.StripComma() + b.ObjEnd() + return nil +} + +// DecodeTDLibJSON implements tdjson.TDLibDecoder. +func (e *EditStarSubscriptionRequest) DecodeTDLibJSON(b tdjson.Decoder) error { + if e == nil { + return fmt.Errorf("can't decode editStarSubscription#7a1a3918 to nil") + } + + return b.Obj(func(b tdjson.Decoder, key []byte) error { + switch string(key) { + case tdjson.TypeField: + if err := b.ConsumeID("editStarSubscription"); err != nil { + return fmt.Errorf("unable to decode editStarSubscription#7a1a3918: %w", err) + } + case "subscription_id": + value, err := b.String() + if err != nil { + return fmt.Errorf("unable to decode editStarSubscription#7a1a3918: field subscription_id: %w", err) + } + e.SubscriptionID = value + case "is_canceled": + value, err := b.Bool() + if err != nil { + return fmt.Errorf("unable to decode editStarSubscription#7a1a3918: field is_canceled: %w", err) + } + e.IsCanceled = value + default: + return b.Skip() + } + return nil + }) +} + +// GetSubscriptionID returns value of SubscriptionID field. +func (e *EditStarSubscriptionRequest) GetSubscriptionID() (value string) { + if e == nil { + return + } + return e.SubscriptionID +} + +// GetIsCanceled returns value of IsCanceled field. +func (e *EditStarSubscriptionRequest) GetIsCanceled() (value bool) { + if e == nil { + return + } + return e.IsCanceled +} + +// EditStarSubscription invokes method editStarSubscription#7a1a3918 returning error if any. +func (c *Client) EditStarSubscription(ctx context.Context, request *EditStarSubscriptionRequest) error { + var ok Ok + + if err := c.rpc.Invoke(ctx, request, &ok); err != nil { + return err + } + return nil +} diff --git a/tdapi/tl_get_active_live_location_messages_gen.go b/tdapi/tl_get_active_live_location_messages_gen.go deleted file mode 100644 index fb861d4d9d..0000000000 --- a/tdapi/tl_get_active_live_location_messages_gen.go +++ /dev/null @@ -1,169 +0,0 @@ -// Code generated by gotdgen, DO NOT EDIT. - -package tdapi - -import ( - "context" - "errors" - "fmt" - "sort" - "strings" - - "go.uber.org/multierr" - - "github.com/gotd/td/bin" - "github.com/gotd/td/tdjson" - "github.com/gotd/td/tdp" - "github.com/gotd/td/tgerr" -) - -// No-op definition for keeping imports. -var ( - _ = bin.Buffer{} - _ = context.Background() - _ = fmt.Stringer(nil) - _ = strings.Builder{} - _ = errors.Is - _ = multierr.AppendInto - _ = sort.Ints - _ = tdp.Format - _ = tgerr.Error{} - _ = tdjson.Encoder{} -) - -// GetActiveLiveLocationMessagesRequest represents TL type `getActiveLiveLocationMessages#ab093691`. -type GetActiveLiveLocationMessagesRequest struct { -} - -// GetActiveLiveLocationMessagesRequestTypeID is TL type id of GetActiveLiveLocationMessagesRequest. -const GetActiveLiveLocationMessagesRequestTypeID = 0xab093691 - -// Ensuring interfaces in compile-time for GetActiveLiveLocationMessagesRequest. -var ( - _ bin.Encoder = &GetActiveLiveLocationMessagesRequest{} - _ bin.Decoder = &GetActiveLiveLocationMessagesRequest{} - _ bin.BareEncoder = &GetActiveLiveLocationMessagesRequest{} - _ bin.BareDecoder = &GetActiveLiveLocationMessagesRequest{} -) - -func (g *GetActiveLiveLocationMessagesRequest) Zero() bool { - if g == nil { - return true - } - - return true -} - -// String implements fmt.Stringer. -func (g *GetActiveLiveLocationMessagesRequest) String() string { - if g == nil { - return "GetActiveLiveLocationMessagesRequest(nil)" - } - type Alias GetActiveLiveLocationMessagesRequest - return fmt.Sprintf("GetActiveLiveLocationMessagesRequest%+v", Alias(*g)) -} - -// TypeID returns type id in TL schema. -// -// See https://core.telegram.org/mtproto/TL-tl#remarks. -func (*GetActiveLiveLocationMessagesRequest) TypeID() uint32 { - return GetActiveLiveLocationMessagesRequestTypeID -} - -// TypeName returns name of type in TL schema. -func (*GetActiveLiveLocationMessagesRequest) TypeName() string { - return "getActiveLiveLocationMessages" -} - -// TypeInfo returns info about TL type. -func (g *GetActiveLiveLocationMessagesRequest) TypeInfo() tdp.Type { - typ := tdp.Type{ - Name: "getActiveLiveLocationMessages", - ID: GetActiveLiveLocationMessagesRequestTypeID, - } - if g == nil { - typ.Null = true - return typ - } - typ.Fields = []tdp.Field{} - return typ -} - -// Encode implements bin.Encoder. -func (g *GetActiveLiveLocationMessagesRequest) Encode(b *bin.Buffer) error { - if g == nil { - return fmt.Errorf("can't encode getActiveLiveLocationMessages#ab093691 as nil") - } - b.PutID(GetActiveLiveLocationMessagesRequestTypeID) - return g.EncodeBare(b) -} - -// EncodeBare implements bin.BareEncoder. -func (g *GetActiveLiveLocationMessagesRequest) EncodeBare(b *bin.Buffer) error { - if g == nil { - return fmt.Errorf("can't encode getActiveLiveLocationMessages#ab093691 as nil") - } - return nil -} - -// Decode implements bin.Decoder. -func (g *GetActiveLiveLocationMessagesRequest) Decode(b *bin.Buffer) error { - if g == nil { - return fmt.Errorf("can't decode getActiveLiveLocationMessages#ab093691 to nil") - } - if err := b.ConsumeID(GetActiveLiveLocationMessagesRequestTypeID); err != nil { - return fmt.Errorf("unable to decode getActiveLiveLocationMessages#ab093691: %w", err) - } - return g.DecodeBare(b) -} - -// DecodeBare implements bin.BareDecoder. -func (g *GetActiveLiveLocationMessagesRequest) DecodeBare(b *bin.Buffer) error { - if g == nil { - return fmt.Errorf("can't decode getActiveLiveLocationMessages#ab093691 to nil") - } - return nil -} - -// EncodeTDLibJSON implements tdjson.TDLibEncoder. -func (g *GetActiveLiveLocationMessagesRequest) EncodeTDLibJSON(b tdjson.Encoder) error { - if g == nil { - return fmt.Errorf("can't encode getActiveLiveLocationMessages#ab093691 as nil") - } - b.ObjStart() - b.PutID("getActiveLiveLocationMessages") - b.Comma() - b.StripComma() - b.ObjEnd() - return nil -} - -// DecodeTDLibJSON implements tdjson.TDLibDecoder. -func (g *GetActiveLiveLocationMessagesRequest) DecodeTDLibJSON(b tdjson.Decoder) error { - if g == nil { - return fmt.Errorf("can't decode getActiveLiveLocationMessages#ab093691 to nil") - } - - return b.Obj(func(b tdjson.Decoder, key []byte) error { - switch string(key) { - case tdjson.TypeField: - if err := b.ConsumeID("getActiveLiveLocationMessages"); err != nil { - return fmt.Errorf("unable to decode getActiveLiveLocationMessages#ab093691: %w", err) - } - default: - return b.Skip() - } - return nil - }) -} - -// GetActiveLiveLocationMessages invokes method getActiveLiveLocationMessages#ab093691 returning error if any. -func (c *Client) GetActiveLiveLocationMessages(ctx context.Context) (*Messages, error) { - var result Messages - - request := &GetActiveLiveLocationMessagesRequest{} - if err := c.rpc.Invoke(ctx, request, &result); err != nil { - return nil, err - } - return &result, nil -} diff --git a/tdapi/tl_get_chat_invite_link_members_gen.go b/tdapi/tl_get_chat_invite_link_members_gen.go index 323439cd2d..4ee2ac6c4b 100644 --- a/tdapi/tl_get_chat_invite_link_members_gen.go +++ b/tdapi/tl_get_chat_invite_link_members_gen.go @@ -31,12 +31,15 @@ var ( _ = tdjson.Encoder{} ) -// GetChatInviteLinkMembersRequest represents TL type `getChatInviteLinkMembers#c5b6199a`. +// GetChatInviteLinkMembersRequest represents TL type `getChatInviteLinkMembers#6704ed3c`. type GetChatInviteLinkMembersRequest struct { // Chat identifier ChatID int64 // Invite link for which to return chat members InviteLink string + // Pass true if the link is a subscription link and only members with expired + // subscription must be returned + OnlyWithExpiredSubscription bool // A chat member from which to return next chat members; pass null to get results from // the beginning OffsetMember ChatInviteLinkMember @@ -45,7 +48,7 @@ type GetChatInviteLinkMembersRequest struct { } // GetChatInviteLinkMembersRequestTypeID is TL type id of GetChatInviteLinkMembersRequest. -const GetChatInviteLinkMembersRequestTypeID = 0xc5b6199a +const GetChatInviteLinkMembersRequestTypeID = 0x6704ed3c // Ensuring interfaces in compile-time for GetChatInviteLinkMembersRequest. var ( @@ -65,6 +68,9 @@ func (g *GetChatInviteLinkMembersRequest) Zero() bool { if !(g.InviteLink == "") { return false } + if !(g.OnlyWithExpiredSubscription == false) { + return false + } if !(g.OffsetMember.Zero()) { return false } @@ -115,6 +121,10 @@ func (g *GetChatInviteLinkMembersRequest) TypeInfo() tdp.Type { Name: "InviteLink", SchemaName: "invite_link", }, + { + Name: "OnlyWithExpiredSubscription", + SchemaName: "only_with_expired_subscription", + }, { Name: "OffsetMember", SchemaName: "offset_member", @@ -130,7 +140,7 @@ func (g *GetChatInviteLinkMembersRequest) TypeInfo() tdp.Type { // Encode implements bin.Encoder. func (g *GetChatInviteLinkMembersRequest) Encode(b *bin.Buffer) error { if g == nil { - return fmt.Errorf("can't encode getChatInviteLinkMembers#c5b6199a as nil") + return fmt.Errorf("can't encode getChatInviteLinkMembers#6704ed3c as nil") } b.PutID(GetChatInviteLinkMembersRequestTypeID) return g.EncodeBare(b) @@ -139,12 +149,13 @@ func (g *GetChatInviteLinkMembersRequest) Encode(b *bin.Buffer) error { // EncodeBare implements bin.BareEncoder. func (g *GetChatInviteLinkMembersRequest) EncodeBare(b *bin.Buffer) error { if g == nil { - return fmt.Errorf("can't encode getChatInviteLinkMembers#c5b6199a as nil") + return fmt.Errorf("can't encode getChatInviteLinkMembers#6704ed3c as nil") } b.PutInt53(g.ChatID) b.PutString(g.InviteLink) + b.PutBool(g.OnlyWithExpiredSubscription) if err := g.OffsetMember.Encode(b); err != nil { - return fmt.Errorf("unable to encode getChatInviteLinkMembers#c5b6199a: field offset_member: %w", err) + return fmt.Errorf("unable to encode getChatInviteLinkMembers#6704ed3c: field offset_member: %w", err) } b.PutInt32(g.Limit) return nil @@ -153,10 +164,10 @@ func (g *GetChatInviteLinkMembersRequest) EncodeBare(b *bin.Buffer) error { // Decode implements bin.Decoder. func (g *GetChatInviteLinkMembersRequest) Decode(b *bin.Buffer) error { if g == nil { - return fmt.Errorf("can't decode getChatInviteLinkMembers#c5b6199a to nil") + return fmt.Errorf("can't decode getChatInviteLinkMembers#6704ed3c to nil") } if err := b.ConsumeID(GetChatInviteLinkMembersRequestTypeID); err != nil { - return fmt.Errorf("unable to decode getChatInviteLinkMembers#c5b6199a: %w", err) + return fmt.Errorf("unable to decode getChatInviteLinkMembers#6704ed3c: %w", err) } return g.DecodeBare(b) } @@ -164,31 +175,38 @@ func (g *GetChatInviteLinkMembersRequest) Decode(b *bin.Buffer) error { // DecodeBare implements bin.BareDecoder. func (g *GetChatInviteLinkMembersRequest) DecodeBare(b *bin.Buffer) error { if g == nil { - return fmt.Errorf("can't decode getChatInviteLinkMembers#c5b6199a to nil") + return fmt.Errorf("can't decode getChatInviteLinkMembers#6704ed3c to nil") } { value, err := b.Int53() if err != nil { - return fmt.Errorf("unable to decode getChatInviteLinkMembers#c5b6199a: field chat_id: %w", err) + return fmt.Errorf("unable to decode getChatInviteLinkMembers#6704ed3c: field chat_id: %w", err) } g.ChatID = value } { value, err := b.String() if err != nil { - return fmt.Errorf("unable to decode getChatInviteLinkMembers#c5b6199a: field invite_link: %w", err) + return fmt.Errorf("unable to decode getChatInviteLinkMembers#6704ed3c: field invite_link: %w", err) } g.InviteLink = value } + { + value, err := b.Bool() + if err != nil { + return fmt.Errorf("unable to decode getChatInviteLinkMembers#6704ed3c: field only_with_expired_subscription: %w", err) + } + g.OnlyWithExpiredSubscription = value + } { if err := g.OffsetMember.Decode(b); err != nil { - return fmt.Errorf("unable to decode getChatInviteLinkMembers#c5b6199a: field offset_member: %w", err) + return fmt.Errorf("unable to decode getChatInviteLinkMembers#6704ed3c: field offset_member: %w", err) } } { value, err := b.Int32() if err != nil { - return fmt.Errorf("unable to decode getChatInviteLinkMembers#c5b6199a: field limit: %w", err) + return fmt.Errorf("unable to decode getChatInviteLinkMembers#6704ed3c: field limit: %w", err) } g.Limit = value } @@ -198,7 +216,7 @@ func (g *GetChatInviteLinkMembersRequest) DecodeBare(b *bin.Buffer) error { // EncodeTDLibJSON implements tdjson.TDLibEncoder. func (g *GetChatInviteLinkMembersRequest) EncodeTDLibJSON(b tdjson.Encoder) error { if g == nil { - return fmt.Errorf("can't encode getChatInviteLinkMembers#c5b6199a as nil") + return fmt.Errorf("can't encode getChatInviteLinkMembers#6704ed3c as nil") } b.ObjStart() b.PutID("getChatInviteLinkMembers") @@ -209,9 +227,12 @@ func (g *GetChatInviteLinkMembersRequest) EncodeTDLibJSON(b tdjson.Encoder) erro b.FieldStart("invite_link") b.PutString(g.InviteLink) b.Comma() + b.FieldStart("only_with_expired_subscription") + b.PutBool(g.OnlyWithExpiredSubscription) + b.Comma() b.FieldStart("offset_member") if err := g.OffsetMember.EncodeTDLibJSON(b); err != nil { - return fmt.Errorf("unable to encode getChatInviteLinkMembers#c5b6199a: field offset_member: %w", err) + return fmt.Errorf("unable to encode getChatInviteLinkMembers#6704ed3c: field offset_member: %w", err) } b.Comma() b.FieldStart("limit") @@ -225,35 +246,41 @@ func (g *GetChatInviteLinkMembersRequest) EncodeTDLibJSON(b tdjson.Encoder) erro // DecodeTDLibJSON implements tdjson.TDLibDecoder. func (g *GetChatInviteLinkMembersRequest) DecodeTDLibJSON(b tdjson.Decoder) error { if g == nil { - return fmt.Errorf("can't decode getChatInviteLinkMembers#c5b6199a to nil") + return fmt.Errorf("can't decode getChatInviteLinkMembers#6704ed3c to nil") } return b.Obj(func(b tdjson.Decoder, key []byte) error { switch string(key) { case tdjson.TypeField: if err := b.ConsumeID("getChatInviteLinkMembers"); err != nil { - return fmt.Errorf("unable to decode getChatInviteLinkMembers#c5b6199a: %w", err) + return fmt.Errorf("unable to decode getChatInviteLinkMembers#6704ed3c: %w", err) } case "chat_id": value, err := b.Int53() if err != nil { - return fmt.Errorf("unable to decode getChatInviteLinkMembers#c5b6199a: field chat_id: %w", err) + return fmt.Errorf("unable to decode getChatInviteLinkMembers#6704ed3c: field chat_id: %w", err) } g.ChatID = value case "invite_link": value, err := b.String() if err != nil { - return fmt.Errorf("unable to decode getChatInviteLinkMembers#c5b6199a: field invite_link: %w", err) + return fmt.Errorf("unable to decode getChatInviteLinkMembers#6704ed3c: field invite_link: %w", err) } g.InviteLink = value + case "only_with_expired_subscription": + value, err := b.Bool() + if err != nil { + return fmt.Errorf("unable to decode getChatInviteLinkMembers#6704ed3c: field only_with_expired_subscription: %w", err) + } + g.OnlyWithExpiredSubscription = value case "offset_member": if err := g.OffsetMember.DecodeTDLibJSON(b); err != nil { - return fmt.Errorf("unable to decode getChatInviteLinkMembers#c5b6199a: field offset_member: %w", err) + return fmt.Errorf("unable to decode getChatInviteLinkMembers#6704ed3c: field offset_member: %w", err) } case "limit": value, err := b.Int32() if err != nil { - return fmt.Errorf("unable to decode getChatInviteLinkMembers#c5b6199a: field limit: %w", err) + return fmt.Errorf("unable to decode getChatInviteLinkMembers#6704ed3c: field limit: %w", err) } g.Limit = value default: @@ -279,6 +306,14 @@ func (g *GetChatInviteLinkMembersRequest) GetInviteLink() (value string) { return g.InviteLink } +// GetOnlyWithExpiredSubscription returns value of OnlyWithExpiredSubscription field. +func (g *GetChatInviteLinkMembersRequest) GetOnlyWithExpiredSubscription() (value bool) { + if g == nil { + return + } + return g.OnlyWithExpiredSubscription +} + // GetOffsetMember returns value of OffsetMember field. func (g *GetChatInviteLinkMembersRequest) GetOffsetMember() (value ChatInviteLinkMember) { if g == nil { @@ -295,7 +330,7 @@ func (g *GetChatInviteLinkMembersRequest) GetLimit() (value int32) { return g.Limit } -// GetChatInviteLinkMembers invokes method getChatInviteLinkMembers#c5b6199a returning error if any. +// GetChatInviteLinkMembers invokes method getChatInviteLinkMembers#6704ed3c returning error if any. func (c *Client) GetChatInviteLinkMembers(ctx context.Context, request *GetChatInviteLinkMembersRequest) (*ChatInviteLinkMembers, error) { var result ChatInviteLinkMembers diff --git a/tdapi/tl_get_chat_story_interactions_gen.go b/tdapi/tl_get_chat_story_interactions_gen.go index 590b0ee82d..060c0efed7 100644 --- a/tdapi/tl_get_chat_story_interactions_gen.go +++ b/tdapi/tl_get_chat_story_interactions_gen.go @@ -38,7 +38,8 @@ type GetChatStoryInteractionsRequest struct { // Story identifier StoryID int32 // Pass the default heart reaction or a suggested reaction type to receive only - // interactions with the specified reaction type; pass null to receive all interactions + // interactions with the specified reaction type; pass null to receive all interactions; + // reactionTypePaid isn't supported ReactionType ReactionTypeClass // Pass true to get forwards and reposts first, then reactions, then other views; pass // false to get interactions sorted just by interaction date diff --git a/tdapi/tl_get_message_added_reactions_gen.go b/tdapi/tl_get_message_added_reactions_gen.go index cfefa0f997..649f6970c5 100644 --- a/tdapi/tl_get_message_added_reactions_gen.go +++ b/tdapi/tl_get_message_added_reactions_gen.go @@ -35,10 +35,12 @@ var ( type GetMessageAddedReactionsRequest struct { // Identifier of the chat to which the message belongs ChatID int64 - // Identifier of the message. Use messageProperties.can_get_added_reactions to check - // whether added reactions can be received for the message + // Identifier of the message. Use message.interaction_info.reactions + // can_get_added_reactions to check whether added reactions can be received for the + // message MessageID int64 - // Type of the reactions to return; pass null to return all added reactions + // Type of the reactions to return; pass null to return all added reactions; + // reactionTypePaid isn't supported ReactionType ReactionTypeClass // Offset of the first entry to return as received from the previous request; use empty // string to get the first chunk of results diff --git a/tdapi/tl_get_star_subscriptions_gen.go b/tdapi/tl_get_star_subscriptions_gen.go new file mode 100644 index 0000000000..b693f7bd71 --- /dev/null +++ b/tdapi/tl_get_star_subscriptions_gen.go @@ -0,0 +1,239 @@ +// Code generated by gotdgen, DO NOT EDIT. + +package tdapi + +import ( + "context" + "errors" + "fmt" + "sort" + "strings" + + "go.uber.org/multierr" + + "github.com/gotd/td/bin" + "github.com/gotd/td/tdjson" + "github.com/gotd/td/tdp" + "github.com/gotd/td/tgerr" +) + +// No-op definition for keeping imports. +var ( + _ = bin.Buffer{} + _ = context.Background() + _ = fmt.Stringer(nil) + _ = strings.Builder{} + _ = errors.Is + _ = multierr.AppendInto + _ = sort.Ints + _ = tdp.Format + _ = tgerr.Error{} + _ = tdjson.Encoder{} +) + +// GetStarSubscriptionsRequest represents TL type `getStarSubscriptions#d9c7b2ec`. +type GetStarSubscriptionsRequest struct { + // Pass true to receive only expiring subscriptions for which there are no enough + // Telegram Stars to extend + OnlyExpiring bool + // Offset of the first subscription to return as received from the previous request; use + // empty string to get the first chunk of results + Offset string +} + +// GetStarSubscriptionsRequestTypeID is TL type id of GetStarSubscriptionsRequest. +const GetStarSubscriptionsRequestTypeID = 0xd9c7b2ec + +// Ensuring interfaces in compile-time for GetStarSubscriptionsRequest. +var ( + _ bin.Encoder = &GetStarSubscriptionsRequest{} + _ bin.Decoder = &GetStarSubscriptionsRequest{} + _ bin.BareEncoder = &GetStarSubscriptionsRequest{} + _ bin.BareDecoder = &GetStarSubscriptionsRequest{} +) + +func (g *GetStarSubscriptionsRequest) Zero() bool { + if g == nil { + return true + } + if !(g.OnlyExpiring == false) { + return false + } + if !(g.Offset == "") { + return false + } + + return true +} + +// String implements fmt.Stringer. +func (g *GetStarSubscriptionsRequest) String() string { + if g == nil { + return "GetStarSubscriptionsRequest(nil)" + } + type Alias GetStarSubscriptionsRequest + return fmt.Sprintf("GetStarSubscriptionsRequest%+v", Alias(*g)) +} + +// TypeID returns type id in TL schema. +// +// See https://core.telegram.org/mtproto/TL-tl#remarks. +func (*GetStarSubscriptionsRequest) TypeID() uint32 { + return GetStarSubscriptionsRequestTypeID +} + +// TypeName returns name of type in TL schema. +func (*GetStarSubscriptionsRequest) TypeName() string { + return "getStarSubscriptions" +} + +// TypeInfo returns info about TL type. +func (g *GetStarSubscriptionsRequest) TypeInfo() tdp.Type { + typ := tdp.Type{ + Name: "getStarSubscriptions", + ID: GetStarSubscriptionsRequestTypeID, + } + if g == nil { + typ.Null = true + return typ + } + typ.Fields = []tdp.Field{ + { + Name: "OnlyExpiring", + SchemaName: "only_expiring", + }, + { + Name: "Offset", + SchemaName: "offset", + }, + } + return typ +} + +// Encode implements bin.Encoder. +func (g *GetStarSubscriptionsRequest) Encode(b *bin.Buffer) error { + if g == nil { + return fmt.Errorf("can't encode getStarSubscriptions#d9c7b2ec as nil") + } + b.PutID(GetStarSubscriptionsRequestTypeID) + return g.EncodeBare(b) +} + +// EncodeBare implements bin.BareEncoder. +func (g *GetStarSubscriptionsRequest) EncodeBare(b *bin.Buffer) error { + if g == nil { + return fmt.Errorf("can't encode getStarSubscriptions#d9c7b2ec as nil") + } + b.PutBool(g.OnlyExpiring) + b.PutString(g.Offset) + return nil +} + +// Decode implements bin.Decoder. +func (g *GetStarSubscriptionsRequest) Decode(b *bin.Buffer) error { + if g == nil { + return fmt.Errorf("can't decode getStarSubscriptions#d9c7b2ec to nil") + } + if err := b.ConsumeID(GetStarSubscriptionsRequestTypeID); err != nil { + return fmt.Errorf("unable to decode getStarSubscriptions#d9c7b2ec: %w", err) + } + return g.DecodeBare(b) +} + +// DecodeBare implements bin.BareDecoder. +func (g *GetStarSubscriptionsRequest) DecodeBare(b *bin.Buffer) error { + if g == nil { + return fmt.Errorf("can't decode getStarSubscriptions#d9c7b2ec to nil") + } + { + value, err := b.Bool() + if err != nil { + return fmt.Errorf("unable to decode getStarSubscriptions#d9c7b2ec: field only_expiring: %w", err) + } + g.OnlyExpiring = value + } + { + value, err := b.String() + if err != nil { + return fmt.Errorf("unable to decode getStarSubscriptions#d9c7b2ec: field offset: %w", err) + } + g.Offset = value + } + return nil +} + +// EncodeTDLibJSON implements tdjson.TDLibEncoder. +func (g *GetStarSubscriptionsRequest) EncodeTDLibJSON(b tdjson.Encoder) error { + if g == nil { + return fmt.Errorf("can't encode getStarSubscriptions#d9c7b2ec as nil") + } + b.ObjStart() + b.PutID("getStarSubscriptions") + b.Comma() + b.FieldStart("only_expiring") + b.PutBool(g.OnlyExpiring) + b.Comma() + b.FieldStart("offset") + b.PutString(g.Offset) + b.Comma() + b.StripComma() + b.ObjEnd() + return nil +} + +// DecodeTDLibJSON implements tdjson.TDLibDecoder. +func (g *GetStarSubscriptionsRequest) DecodeTDLibJSON(b tdjson.Decoder) error { + if g == nil { + return fmt.Errorf("can't decode getStarSubscriptions#d9c7b2ec to nil") + } + + return b.Obj(func(b tdjson.Decoder, key []byte) error { + switch string(key) { + case tdjson.TypeField: + if err := b.ConsumeID("getStarSubscriptions"); err != nil { + return fmt.Errorf("unable to decode getStarSubscriptions#d9c7b2ec: %w", err) + } + case "only_expiring": + value, err := b.Bool() + if err != nil { + return fmt.Errorf("unable to decode getStarSubscriptions#d9c7b2ec: field only_expiring: %w", err) + } + g.OnlyExpiring = value + case "offset": + value, err := b.String() + if err != nil { + return fmt.Errorf("unable to decode getStarSubscriptions#d9c7b2ec: field offset: %w", err) + } + g.Offset = value + default: + return b.Skip() + } + return nil + }) +} + +// GetOnlyExpiring returns value of OnlyExpiring field. +func (g *GetStarSubscriptionsRequest) GetOnlyExpiring() (value bool) { + if g == nil { + return + } + return g.OnlyExpiring +} + +// GetOffset returns value of Offset field. +func (g *GetStarSubscriptionsRequest) GetOffset() (value string) { + if g == nil { + return + } + return g.Offset +} + +// GetStarSubscriptions invokes method getStarSubscriptions#d9c7b2ec returning error if any. +func (c *Client) GetStarSubscriptions(ctx context.Context, request *GetStarSubscriptionsRequest) (*StarSubscriptions, error) { + var result StarSubscriptions + + if err := c.rpc.Invoke(ctx, request, &result); err != nil { + return nil, err + } + return &result, nil +} diff --git a/tdapi/tl_get_star_transactions_gen.go b/tdapi/tl_get_star_transactions_gen.go index b204ec27c5..fde7b47ee3 100644 --- a/tdapi/tl_get_star_transactions_gen.go +++ b/tdapi/tl_get_star_transactions_gen.go @@ -31,11 +31,13 @@ var ( _ = tdjson.Encoder{} ) -// GetStarTransactionsRequest represents TL type `getStarTransactions#eb1e109d`. +// GetStarTransactionsRequest represents TL type `getStarTransactions#f096f8f1`. type GetStarTransactionsRequest struct { // Identifier of the owner of the Telegram Stars; can be the identifier of the current // user, identifier of an owned bot, OwnerID MessageSenderClass + // If non-empty, only transactions related to the Star Subscription will be returned + SubscriptionID string // Direction of the transactions to receive; pass null to get all transactions Direction StarTransactionDirectionClass // Offset of the first transaction to return as received from the previous request; use @@ -46,7 +48,7 @@ type GetStarTransactionsRequest struct { } // GetStarTransactionsRequestTypeID is TL type id of GetStarTransactionsRequest. -const GetStarTransactionsRequestTypeID = 0xeb1e109d +const GetStarTransactionsRequestTypeID = 0xf096f8f1 // Ensuring interfaces in compile-time for GetStarTransactionsRequest. var ( @@ -63,6 +65,9 @@ func (g *GetStarTransactionsRequest) Zero() bool { if !(g.OwnerID == nil) { return false } + if !(g.SubscriptionID == "") { + return false + } if !(g.Direction == nil) { return false } @@ -112,6 +117,10 @@ func (g *GetStarTransactionsRequest) TypeInfo() tdp.Type { Name: "OwnerID", SchemaName: "owner_id", }, + { + Name: "SubscriptionID", + SchemaName: "subscription_id", + }, { Name: "Direction", SchemaName: "direction", @@ -131,7 +140,7 @@ func (g *GetStarTransactionsRequest) TypeInfo() tdp.Type { // Encode implements bin.Encoder. func (g *GetStarTransactionsRequest) Encode(b *bin.Buffer) error { if g == nil { - return fmt.Errorf("can't encode getStarTransactions#eb1e109d as nil") + return fmt.Errorf("can't encode getStarTransactions#f096f8f1 as nil") } b.PutID(GetStarTransactionsRequestTypeID) return g.EncodeBare(b) @@ -140,19 +149,20 @@ func (g *GetStarTransactionsRequest) Encode(b *bin.Buffer) error { // EncodeBare implements bin.BareEncoder. func (g *GetStarTransactionsRequest) EncodeBare(b *bin.Buffer) error { if g == nil { - return fmt.Errorf("can't encode getStarTransactions#eb1e109d as nil") + return fmt.Errorf("can't encode getStarTransactions#f096f8f1 as nil") } if g.OwnerID == nil { - return fmt.Errorf("unable to encode getStarTransactions#eb1e109d: field owner_id is nil") + return fmt.Errorf("unable to encode getStarTransactions#f096f8f1: field owner_id is nil") } if err := g.OwnerID.Encode(b); err != nil { - return fmt.Errorf("unable to encode getStarTransactions#eb1e109d: field owner_id: %w", err) + return fmt.Errorf("unable to encode getStarTransactions#f096f8f1: field owner_id: %w", err) } + b.PutString(g.SubscriptionID) if g.Direction == nil { - return fmt.Errorf("unable to encode getStarTransactions#eb1e109d: field direction is nil") + return fmt.Errorf("unable to encode getStarTransactions#f096f8f1: field direction is nil") } if err := g.Direction.Encode(b); err != nil { - return fmt.Errorf("unable to encode getStarTransactions#eb1e109d: field direction: %w", err) + return fmt.Errorf("unable to encode getStarTransactions#f096f8f1: field direction: %w", err) } b.PutString(g.Offset) b.PutInt32(g.Limit) @@ -162,10 +172,10 @@ func (g *GetStarTransactionsRequest) EncodeBare(b *bin.Buffer) error { // Decode implements bin.Decoder. func (g *GetStarTransactionsRequest) Decode(b *bin.Buffer) error { if g == nil { - return fmt.Errorf("can't decode getStarTransactions#eb1e109d to nil") + return fmt.Errorf("can't decode getStarTransactions#f096f8f1 to nil") } if err := b.ConsumeID(GetStarTransactionsRequestTypeID); err != nil { - return fmt.Errorf("unable to decode getStarTransactions#eb1e109d: %w", err) + return fmt.Errorf("unable to decode getStarTransactions#f096f8f1: %w", err) } return g.DecodeBare(b) } @@ -173,33 +183,40 @@ func (g *GetStarTransactionsRequest) Decode(b *bin.Buffer) error { // DecodeBare implements bin.BareDecoder. func (g *GetStarTransactionsRequest) DecodeBare(b *bin.Buffer) error { if g == nil { - return fmt.Errorf("can't decode getStarTransactions#eb1e109d to nil") + return fmt.Errorf("can't decode getStarTransactions#f096f8f1 to nil") } { value, err := DecodeMessageSender(b) if err != nil { - return fmt.Errorf("unable to decode getStarTransactions#eb1e109d: field owner_id: %w", err) + return fmt.Errorf("unable to decode getStarTransactions#f096f8f1: field owner_id: %w", err) } g.OwnerID = value } + { + value, err := b.String() + if err != nil { + return fmt.Errorf("unable to decode getStarTransactions#f096f8f1: field subscription_id: %w", err) + } + g.SubscriptionID = value + } { value, err := DecodeStarTransactionDirection(b) if err != nil { - return fmt.Errorf("unable to decode getStarTransactions#eb1e109d: field direction: %w", err) + return fmt.Errorf("unable to decode getStarTransactions#f096f8f1: field direction: %w", err) } g.Direction = value } { value, err := b.String() if err != nil { - return fmt.Errorf("unable to decode getStarTransactions#eb1e109d: field offset: %w", err) + return fmt.Errorf("unable to decode getStarTransactions#f096f8f1: field offset: %w", err) } g.Offset = value } { value, err := b.Int32() if err != nil { - return fmt.Errorf("unable to decode getStarTransactions#eb1e109d: field limit: %w", err) + return fmt.Errorf("unable to decode getStarTransactions#f096f8f1: field limit: %w", err) } g.Limit = value } @@ -209,25 +226,28 @@ func (g *GetStarTransactionsRequest) DecodeBare(b *bin.Buffer) error { // EncodeTDLibJSON implements tdjson.TDLibEncoder. func (g *GetStarTransactionsRequest) EncodeTDLibJSON(b tdjson.Encoder) error { if g == nil { - return fmt.Errorf("can't encode getStarTransactions#eb1e109d as nil") + return fmt.Errorf("can't encode getStarTransactions#f096f8f1 as nil") } b.ObjStart() b.PutID("getStarTransactions") b.Comma() b.FieldStart("owner_id") if g.OwnerID == nil { - return fmt.Errorf("unable to encode getStarTransactions#eb1e109d: field owner_id is nil") + return fmt.Errorf("unable to encode getStarTransactions#f096f8f1: field owner_id is nil") } if err := g.OwnerID.EncodeTDLibJSON(b); err != nil { - return fmt.Errorf("unable to encode getStarTransactions#eb1e109d: field owner_id: %w", err) + return fmt.Errorf("unable to encode getStarTransactions#f096f8f1: field owner_id: %w", err) } b.Comma() + b.FieldStart("subscription_id") + b.PutString(g.SubscriptionID) + b.Comma() b.FieldStart("direction") if g.Direction == nil { - return fmt.Errorf("unable to encode getStarTransactions#eb1e109d: field direction is nil") + return fmt.Errorf("unable to encode getStarTransactions#f096f8f1: field direction is nil") } if err := g.Direction.EncodeTDLibJSON(b); err != nil { - return fmt.Errorf("unable to encode getStarTransactions#eb1e109d: field direction: %w", err) + return fmt.Errorf("unable to encode getStarTransactions#f096f8f1: field direction: %w", err) } b.Comma() b.FieldStart("offset") @@ -244,37 +264,43 @@ func (g *GetStarTransactionsRequest) EncodeTDLibJSON(b tdjson.Encoder) error { // DecodeTDLibJSON implements tdjson.TDLibDecoder. func (g *GetStarTransactionsRequest) DecodeTDLibJSON(b tdjson.Decoder) error { if g == nil { - return fmt.Errorf("can't decode getStarTransactions#eb1e109d to nil") + return fmt.Errorf("can't decode getStarTransactions#f096f8f1 to nil") } return b.Obj(func(b tdjson.Decoder, key []byte) error { switch string(key) { case tdjson.TypeField: if err := b.ConsumeID("getStarTransactions"); err != nil { - return fmt.Errorf("unable to decode getStarTransactions#eb1e109d: %w", err) + return fmt.Errorf("unable to decode getStarTransactions#f096f8f1: %w", err) } case "owner_id": value, err := DecodeTDLibJSONMessageSender(b) if err != nil { - return fmt.Errorf("unable to decode getStarTransactions#eb1e109d: field owner_id: %w", err) + return fmt.Errorf("unable to decode getStarTransactions#f096f8f1: field owner_id: %w", err) } g.OwnerID = value + case "subscription_id": + value, err := b.String() + if err != nil { + return fmt.Errorf("unable to decode getStarTransactions#f096f8f1: field subscription_id: %w", err) + } + g.SubscriptionID = value case "direction": value, err := DecodeTDLibJSONStarTransactionDirection(b) if err != nil { - return fmt.Errorf("unable to decode getStarTransactions#eb1e109d: field direction: %w", err) + return fmt.Errorf("unable to decode getStarTransactions#f096f8f1: field direction: %w", err) } g.Direction = value case "offset": value, err := b.String() if err != nil { - return fmt.Errorf("unable to decode getStarTransactions#eb1e109d: field offset: %w", err) + return fmt.Errorf("unable to decode getStarTransactions#f096f8f1: field offset: %w", err) } g.Offset = value case "limit": value, err := b.Int32() if err != nil { - return fmt.Errorf("unable to decode getStarTransactions#eb1e109d: field limit: %w", err) + return fmt.Errorf("unable to decode getStarTransactions#f096f8f1: field limit: %w", err) } g.Limit = value default: @@ -292,6 +318,14 @@ func (g *GetStarTransactionsRequest) GetOwnerID() (value MessageSenderClass) { return g.OwnerID } +// GetSubscriptionID returns value of SubscriptionID field. +func (g *GetStarTransactionsRequest) GetSubscriptionID() (value string) { + if g == nil { + return + } + return g.SubscriptionID +} + // GetDirection returns value of Direction field. func (g *GetStarTransactionsRequest) GetDirection() (value StarTransactionDirectionClass) { if g == nil { @@ -316,7 +350,7 @@ func (g *GetStarTransactionsRequest) GetLimit() (value int32) { return g.Limit } -// GetStarTransactions invokes method getStarTransactions#eb1e109d returning error if any. +// GetStarTransactions invokes method getStarTransactions#f096f8f1 returning error if any. func (c *Client) GetStarTransactions(ctx context.Context, request *GetStarTransactionsRequest) (*StarTransactions, error) { var result StarTransactions diff --git a/tdapi/tl_internal_link_type_gen.go b/tdapi/tl_internal_link_type_gen.go index 685d1c06e0..d0671e91bb 100644 --- a/tdapi/tl_internal_link_type_gen.go +++ b/tdapi/tl_internal_link_type_gen.go @@ -1573,6 +1573,207 @@ func (i *InternalLinkTypeBusinessChat) GetLinkName() (value string) { return i.LinkName } +// InternalLinkTypeBuyStars represents TL type `internalLinkTypeBuyStars#a94cc347`. +type InternalLinkTypeBuyStars struct { + // The number of Telegram Stars that must be owned by the user + StarCount int64 + // Purpose of Telegram Star purchase. Arbitrary string specified by the server, for + // example, "subs" if the Telegram Stars are required to extend channel subscriptions + Purpose string +} + +// InternalLinkTypeBuyStarsTypeID is TL type id of InternalLinkTypeBuyStars. +const InternalLinkTypeBuyStarsTypeID = 0xa94cc347 + +// construct implements constructor of InternalLinkTypeClass. +func (i InternalLinkTypeBuyStars) construct() InternalLinkTypeClass { return &i } + +// Ensuring interfaces in compile-time for InternalLinkTypeBuyStars. +var ( + _ bin.Encoder = &InternalLinkTypeBuyStars{} + _ bin.Decoder = &InternalLinkTypeBuyStars{} + _ bin.BareEncoder = &InternalLinkTypeBuyStars{} + _ bin.BareDecoder = &InternalLinkTypeBuyStars{} + + _ InternalLinkTypeClass = &InternalLinkTypeBuyStars{} +) + +func (i *InternalLinkTypeBuyStars) Zero() bool { + if i == nil { + return true + } + if !(i.StarCount == 0) { + return false + } + if !(i.Purpose == "") { + return false + } + + return true +} + +// String implements fmt.Stringer. +func (i *InternalLinkTypeBuyStars) String() string { + if i == nil { + return "InternalLinkTypeBuyStars(nil)" + } + type Alias InternalLinkTypeBuyStars + return fmt.Sprintf("InternalLinkTypeBuyStars%+v", Alias(*i)) +} + +// TypeID returns type id in TL schema. +// +// See https://core.telegram.org/mtproto/TL-tl#remarks. +func (*InternalLinkTypeBuyStars) TypeID() uint32 { + return InternalLinkTypeBuyStarsTypeID +} + +// TypeName returns name of type in TL schema. +func (*InternalLinkTypeBuyStars) TypeName() string { + return "internalLinkTypeBuyStars" +} + +// TypeInfo returns info about TL type. +func (i *InternalLinkTypeBuyStars) TypeInfo() tdp.Type { + typ := tdp.Type{ + Name: "internalLinkTypeBuyStars", + ID: InternalLinkTypeBuyStarsTypeID, + } + if i == nil { + typ.Null = true + return typ + } + typ.Fields = []tdp.Field{ + { + Name: "StarCount", + SchemaName: "star_count", + }, + { + Name: "Purpose", + SchemaName: "purpose", + }, + } + return typ +} + +// Encode implements bin.Encoder. +func (i *InternalLinkTypeBuyStars) Encode(b *bin.Buffer) error { + if i == nil { + return fmt.Errorf("can't encode internalLinkTypeBuyStars#a94cc347 as nil") + } + b.PutID(InternalLinkTypeBuyStarsTypeID) + return i.EncodeBare(b) +} + +// EncodeBare implements bin.BareEncoder. +func (i *InternalLinkTypeBuyStars) EncodeBare(b *bin.Buffer) error { + if i == nil { + return fmt.Errorf("can't encode internalLinkTypeBuyStars#a94cc347 as nil") + } + b.PutInt53(i.StarCount) + b.PutString(i.Purpose) + return nil +} + +// Decode implements bin.Decoder. +func (i *InternalLinkTypeBuyStars) Decode(b *bin.Buffer) error { + if i == nil { + return fmt.Errorf("can't decode internalLinkTypeBuyStars#a94cc347 to nil") + } + if err := b.ConsumeID(InternalLinkTypeBuyStarsTypeID); err != nil { + return fmt.Errorf("unable to decode internalLinkTypeBuyStars#a94cc347: %w", err) + } + return i.DecodeBare(b) +} + +// DecodeBare implements bin.BareDecoder. +func (i *InternalLinkTypeBuyStars) DecodeBare(b *bin.Buffer) error { + if i == nil { + return fmt.Errorf("can't decode internalLinkTypeBuyStars#a94cc347 to nil") + } + { + value, err := b.Int53() + if err != nil { + return fmt.Errorf("unable to decode internalLinkTypeBuyStars#a94cc347: field star_count: %w", err) + } + i.StarCount = value + } + { + value, err := b.String() + if err != nil { + return fmt.Errorf("unable to decode internalLinkTypeBuyStars#a94cc347: field purpose: %w", err) + } + i.Purpose = value + } + return nil +} + +// EncodeTDLibJSON implements tdjson.TDLibEncoder. +func (i *InternalLinkTypeBuyStars) EncodeTDLibJSON(b tdjson.Encoder) error { + if i == nil { + return fmt.Errorf("can't encode internalLinkTypeBuyStars#a94cc347 as nil") + } + b.ObjStart() + b.PutID("internalLinkTypeBuyStars") + b.Comma() + b.FieldStart("star_count") + b.PutInt53(i.StarCount) + b.Comma() + b.FieldStart("purpose") + b.PutString(i.Purpose) + b.Comma() + b.StripComma() + b.ObjEnd() + return nil +} + +// DecodeTDLibJSON implements tdjson.TDLibDecoder. +func (i *InternalLinkTypeBuyStars) DecodeTDLibJSON(b tdjson.Decoder) error { + if i == nil { + return fmt.Errorf("can't decode internalLinkTypeBuyStars#a94cc347 to nil") + } + + return b.Obj(func(b tdjson.Decoder, key []byte) error { + switch string(key) { + case tdjson.TypeField: + if err := b.ConsumeID("internalLinkTypeBuyStars"); err != nil { + return fmt.Errorf("unable to decode internalLinkTypeBuyStars#a94cc347: %w", err) + } + case "star_count": + value, err := b.Int53() + if err != nil { + return fmt.Errorf("unable to decode internalLinkTypeBuyStars#a94cc347: field star_count: %w", err) + } + i.StarCount = value + case "purpose": + value, err := b.String() + if err != nil { + return fmt.Errorf("unable to decode internalLinkTypeBuyStars#a94cc347: field purpose: %w", err) + } + i.Purpose = value + default: + return b.Skip() + } + return nil + }) +} + +// GetStarCount returns value of StarCount field. +func (i *InternalLinkTypeBuyStars) GetStarCount() (value int64) { + if i == nil { + return + } + return i.StarCount +} + +// GetPurpose returns value of Purpose field. +func (i *InternalLinkTypeBuyStars) GetPurpose() (value string) { + if i == nil { + return + } + return i.Purpose +} + // InternalLinkTypeChangePhoneNumber represents TL type `internalLinkTypeChangePhoneNumber#f0275b01`. type InternalLinkTypeChangePhoneNumber struct { } @@ -7985,6 +8186,7 @@ const InternalLinkTypeClassName = "InternalLinkType" // case *tdapi.InternalLinkTypeBotStart: // internalLinkTypeBotStart#3f985fed // case *tdapi.InternalLinkTypeBotStartInGroup: // internalLinkTypeBotStartInGroup#ca0d8cce // case *tdapi.InternalLinkTypeBusinessChat: // internalLinkTypeBusinessChat#a03ae9d7 +// case *tdapi.InternalLinkTypeBuyStars: // internalLinkTypeBuyStars#a94cc347 // case *tdapi.InternalLinkTypeChangePhoneNumber: // internalLinkTypeChangePhoneNumber#f0275b01 // case *tdapi.InternalLinkTypeChatBoost: // internalLinkTypeChatBoost#d549fd40 // case *tdapi.InternalLinkTypeChatFolderInvite: // internalLinkTypeChatFolderInvite#89b2493e @@ -8108,6 +8310,13 @@ func DecodeInternalLinkType(buf *bin.Buffer) (InternalLinkTypeClass, error) { return nil, fmt.Errorf("unable to decode InternalLinkTypeClass: %w", err) } return &v, nil + case InternalLinkTypeBuyStarsTypeID: + // Decoding internalLinkTypeBuyStars#a94cc347. + v := InternalLinkTypeBuyStars{} + if err := v.Decode(buf); err != nil { + return nil, fmt.Errorf("unable to decode InternalLinkTypeClass: %w", err) + } + return &v, nil case InternalLinkTypeChangePhoneNumberTypeID: // Decoding internalLinkTypeChangePhoneNumber#f0275b01. v := InternalLinkTypeChangePhoneNumber{} @@ -8428,6 +8637,13 @@ func DecodeTDLibJSONInternalLinkType(buf tdjson.Decoder) (InternalLinkTypeClass, return nil, fmt.Errorf("unable to decode InternalLinkTypeClass: %w", err) } return &v, nil + case "internalLinkTypeBuyStars": + // Decoding internalLinkTypeBuyStars#a94cc347. + v := InternalLinkTypeBuyStars{} + if err := v.DecodeTDLibJSON(buf); err != nil { + return nil, fmt.Errorf("unable to decode InternalLinkTypeClass: %w", err) + } + return &v, nil case "internalLinkTypeChangePhoneNumber": // Decoding internalLinkTypeChangePhoneNumber#f0275b01. v := InternalLinkTypeChangePhoneNumber{} diff --git a/tdapi/tl_link_preview_type_gen.go b/tdapi/tl_link_preview_type_gen.go index d697fb29bf..39236c29a6 100644 --- a/tdapi/tl_link_preview_type_gen.go +++ b/tdapi/tl_link_preview_type_gen.go @@ -1167,14 +1167,16 @@ func (l *LinkPreviewTypeAudio) GetAuthor() (value string) { return l.Author } -// LinkPreviewTypeBackground represents TL type `linkPreviewTypeBackground#6dc50386`. +// LinkPreviewTypeBackground represents TL type `linkPreviewTypeBackground#3a48a1e0`. type LinkPreviewTypeBackground struct { // Document with the background; may be null for filled backgrounds Document Document + // Type of the background; may be null if unknown + BackgroundType BackgroundTypeClass } // LinkPreviewTypeBackgroundTypeID is TL type id of LinkPreviewTypeBackground. -const LinkPreviewTypeBackgroundTypeID = 0x6dc50386 +const LinkPreviewTypeBackgroundTypeID = 0x3a48a1e0 // construct implements constructor of LinkPreviewTypeClass. func (l LinkPreviewTypeBackground) construct() LinkPreviewTypeClass { return &l } @@ -1196,6 +1198,9 @@ func (l *LinkPreviewTypeBackground) Zero() bool { if !(l.Document.Zero()) { return false } + if !(l.BackgroundType == nil) { + return false + } return true } @@ -1236,6 +1241,10 @@ func (l *LinkPreviewTypeBackground) TypeInfo() tdp.Type { Name: "Document", SchemaName: "document", }, + { + Name: "BackgroundType", + SchemaName: "background_type", + }, } return typ } @@ -1243,7 +1252,7 @@ func (l *LinkPreviewTypeBackground) TypeInfo() tdp.Type { // Encode implements bin.Encoder. func (l *LinkPreviewTypeBackground) Encode(b *bin.Buffer) error { if l == nil { - return fmt.Errorf("can't encode linkPreviewTypeBackground#6dc50386 as nil") + return fmt.Errorf("can't encode linkPreviewTypeBackground#3a48a1e0 as nil") } b.PutID(LinkPreviewTypeBackgroundTypeID) return l.EncodeBare(b) @@ -1252,10 +1261,16 @@ func (l *LinkPreviewTypeBackground) Encode(b *bin.Buffer) error { // EncodeBare implements bin.BareEncoder. func (l *LinkPreviewTypeBackground) EncodeBare(b *bin.Buffer) error { if l == nil { - return fmt.Errorf("can't encode linkPreviewTypeBackground#6dc50386 as nil") + return fmt.Errorf("can't encode linkPreviewTypeBackground#3a48a1e0 as nil") } if err := l.Document.Encode(b); err != nil { - return fmt.Errorf("unable to encode linkPreviewTypeBackground#6dc50386: field document: %w", err) + return fmt.Errorf("unable to encode linkPreviewTypeBackground#3a48a1e0: field document: %w", err) + } + if l.BackgroundType == nil { + return fmt.Errorf("unable to encode linkPreviewTypeBackground#3a48a1e0: field background_type is nil") + } + if err := l.BackgroundType.Encode(b); err != nil { + return fmt.Errorf("unable to encode linkPreviewTypeBackground#3a48a1e0: field background_type: %w", err) } return nil } @@ -1263,10 +1278,10 @@ func (l *LinkPreviewTypeBackground) EncodeBare(b *bin.Buffer) error { // Decode implements bin.Decoder. func (l *LinkPreviewTypeBackground) Decode(b *bin.Buffer) error { if l == nil { - return fmt.Errorf("can't decode linkPreviewTypeBackground#6dc50386 to nil") + return fmt.Errorf("can't decode linkPreviewTypeBackground#3a48a1e0 to nil") } if err := b.ConsumeID(LinkPreviewTypeBackgroundTypeID); err != nil { - return fmt.Errorf("unable to decode linkPreviewTypeBackground#6dc50386: %w", err) + return fmt.Errorf("unable to decode linkPreviewTypeBackground#3a48a1e0: %w", err) } return l.DecodeBare(b) } @@ -1274,12 +1289,19 @@ func (l *LinkPreviewTypeBackground) Decode(b *bin.Buffer) error { // DecodeBare implements bin.BareDecoder. func (l *LinkPreviewTypeBackground) DecodeBare(b *bin.Buffer) error { if l == nil { - return fmt.Errorf("can't decode linkPreviewTypeBackground#6dc50386 to nil") + return fmt.Errorf("can't decode linkPreviewTypeBackground#3a48a1e0 to nil") } { if err := l.Document.Decode(b); err != nil { - return fmt.Errorf("unable to decode linkPreviewTypeBackground#6dc50386: field document: %w", err) + return fmt.Errorf("unable to decode linkPreviewTypeBackground#3a48a1e0: field document: %w", err) + } + } + { + value, err := DecodeBackgroundType(b) + if err != nil { + return fmt.Errorf("unable to decode linkPreviewTypeBackground#3a48a1e0: field background_type: %w", err) } + l.BackgroundType = value } return nil } @@ -1287,14 +1309,22 @@ func (l *LinkPreviewTypeBackground) DecodeBare(b *bin.Buffer) error { // EncodeTDLibJSON implements tdjson.TDLibEncoder. func (l *LinkPreviewTypeBackground) EncodeTDLibJSON(b tdjson.Encoder) error { if l == nil { - return fmt.Errorf("can't encode linkPreviewTypeBackground#6dc50386 as nil") + return fmt.Errorf("can't encode linkPreviewTypeBackground#3a48a1e0 as nil") } b.ObjStart() b.PutID("linkPreviewTypeBackground") b.Comma() b.FieldStart("document") if err := l.Document.EncodeTDLibJSON(b); err != nil { - return fmt.Errorf("unable to encode linkPreviewTypeBackground#6dc50386: field document: %w", err) + return fmt.Errorf("unable to encode linkPreviewTypeBackground#3a48a1e0: field document: %w", err) + } + b.Comma() + b.FieldStart("background_type") + if l.BackgroundType == nil { + return fmt.Errorf("unable to encode linkPreviewTypeBackground#3a48a1e0: field background_type is nil") + } + if err := l.BackgroundType.EncodeTDLibJSON(b); err != nil { + return fmt.Errorf("unable to encode linkPreviewTypeBackground#3a48a1e0: field background_type: %w", err) } b.Comma() b.StripComma() @@ -1305,19 +1335,25 @@ func (l *LinkPreviewTypeBackground) EncodeTDLibJSON(b tdjson.Encoder) error { // DecodeTDLibJSON implements tdjson.TDLibDecoder. func (l *LinkPreviewTypeBackground) DecodeTDLibJSON(b tdjson.Decoder) error { if l == nil { - return fmt.Errorf("can't decode linkPreviewTypeBackground#6dc50386 to nil") + return fmt.Errorf("can't decode linkPreviewTypeBackground#3a48a1e0 to nil") } return b.Obj(func(b tdjson.Decoder, key []byte) error { switch string(key) { case tdjson.TypeField: if err := b.ConsumeID("linkPreviewTypeBackground"); err != nil { - return fmt.Errorf("unable to decode linkPreviewTypeBackground#6dc50386: %w", err) + return fmt.Errorf("unable to decode linkPreviewTypeBackground#3a48a1e0: %w", err) } case "document": if err := l.Document.DecodeTDLibJSON(b); err != nil { - return fmt.Errorf("unable to decode linkPreviewTypeBackground#6dc50386: field document: %w", err) + return fmt.Errorf("unable to decode linkPreviewTypeBackground#3a48a1e0: field document: %w", err) + } + case "background_type": + value, err := DecodeTDLibJSONBackgroundType(b) + if err != nil { + return fmt.Errorf("unable to decode linkPreviewTypeBackground#3a48a1e0: field background_type: %w", err) } + l.BackgroundType = value default: return b.Skip() } @@ -1333,6 +1369,14 @@ func (l *LinkPreviewTypeBackground) GetDocument() (value Document) { return l.Document } +// GetBackgroundType returns value of BackgroundType field. +func (l *LinkPreviewTypeBackground) GetBackgroundType() (value BackgroundTypeClass) { + if l == nil { + return + } + return l.BackgroundType +} + // LinkPreviewTypeChannelBoost represents TL type `linkPreviewTypeChannelBoost#c6f40456`. type LinkPreviewTypeChannelBoost struct { // Photo of the chat; may be null @@ -3677,7 +3721,7 @@ func (l *LinkPreviewTypeShareableChatFolder) DecodeTDLibJSON(b tdjson.Decoder) e // LinkPreviewTypeSticker represents TL type `linkPreviewTypeSticker#245f4d25`. type LinkPreviewTypeSticker struct { - // The sticker + // The sticker. It can be an arbitrary WEBP image and can have dimensions bigger than 512 Sticker Sticker } @@ -6046,7 +6090,7 @@ const LinkPreviewTypeClassName = "LinkPreviewType" // case *tdapi.LinkPreviewTypeApp: // linkPreviewTypeApp#b5192746 // case *tdapi.LinkPreviewTypeArticle: // linkPreviewTypeArticle#965e4e27 // case *tdapi.LinkPreviewTypeAudio: // linkPreviewTypeAudio#572c6b78 -// case *tdapi.LinkPreviewTypeBackground: // linkPreviewTypeBackground#6dc50386 +// case *tdapi.LinkPreviewTypeBackground: // linkPreviewTypeBackground#3a48a1e0 // case *tdapi.LinkPreviewTypeChannelBoost: // linkPreviewTypeChannelBoost#c6f40456 // case *tdapi.LinkPreviewTypeChat: // linkPreviewTypeChat#ae2fa122 // case *tdapi.LinkPreviewTypeDocument: // linkPreviewTypeDocument#53b02747 @@ -6137,7 +6181,7 @@ func DecodeLinkPreviewType(buf *bin.Buffer) (LinkPreviewTypeClass, error) { } return &v, nil case LinkPreviewTypeBackgroundTypeID: - // Decoding linkPreviewTypeBackground#6dc50386. + // Decoding linkPreviewTypeBackground#3a48a1e0. v := LinkPreviewTypeBackground{} if err := v.Decode(buf); err != nil { return nil, fmt.Errorf("unable to decode LinkPreviewTypeClass: %w", err) @@ -6352,7 +6396,7 @@ func DecodeTDLibJSONLinkPreviewType(buf tdjson.Decoder) (LinkPreviewTypeClass, e } return &v, nil case "linkPreviewTypeBackground": - // Decoding linkPreviewTypeBackground#6dc50386. + // Decoding linkPreviewTypeBackground#3a48a1e0. v := LinkPreviewTypeBackground{} if err := v.DecodeTDLibJSON(buf); err != nil { return nil, fmt.Errorf("unable to decode LinkPreviewTypeClass: %w", err) diff --git a/tdapi/tl_message_gen.go b/tdapi/tl_message_gen.go index f603e8ddb0..949d1b0152 100644 --- a/tdapi/tl_message_gen.go +++ b/tdapi/tl_message_gen.go @@ -31,7 +31,7 @@ var ( _ = tdjson.Encoder{} ) -// Message represents TL type `message#dc764ddc`. +// Message represents TL type `message#a9c04bbc`. type Message struct { // Message identifier; unique for the chat to which the message belongs ID int64 @@ -110,6 +110,8 @@ type Message struct { MediaAlbumID int64 // Unique identifier of the effect added to the message; 0 if none EffectID int64 + // True, if media content of the message must be hidden with 18+ spoiler + HasSensitiveContent bool // If non-empty, contains a human-readable description of the reason why access to this // message must be restricted RestrictionReason string @@ -120,7 +122,7 @@ type Message struct { } // MessageTypeID is TL type id of Message. -const MessageTypeID = 0xdc764ddc +const MessageTypeID = 0xa9c04bbc // Ensuring interfaces in compile-time for Message. var ( @@ -230,6 +232,9 @@ func (m *Message) Zero() bool { if !(m.EffectID == 0) { return false } + if !(m.HasSensitiveContent == false) { + return false + } if !(m.RestrictionReason == "") { return false } @@ -403,6 +408,10 @@ func (m *Message) TypeInfo() tdp.Type { Name: "EffectID", SchemaName: "effect_id", }, + { + Name: "HasSensitiveContent", + SchemaName: "has_sensitive_content", + }, { Name: "RestrictionReason", SchemaName: "restriction_reason", @@ -422,7 +431,7 @@ func (m *Message) TypeInfo() tdp.Type { // Encode implements bin.Encoder. func (m *Message) Encode(b *bin.Buffer) error { if m == nil { - return fmt.Errorf("can't encode message#dc764ddc as nil") + return fmt.Errorf("can't encode message#a9c04bbc as nil") } b.PutID(MessageTypeID) return m.EncodeBare(b) @@ -431,27 +440,27 @@ func (m *Message) Encode(b *bin.Buffer) error { // EncodeBare implements bin.BareEncoder. func (m *Message) EncodeBare(b *bin.Buffer) error { if m == nil { - return fmt.Errorf("can't encode message#dc764ddc as nil") + return fmt.Errorf("can't encode message#a9c04bbc as nil") } b.PutInt53(m.ID) if m.SenderID == nil { - return fmt.Errorf("unable to encode message#dc764ddc: field sender_id is nil") + return fmt.Errorf("unable to encode message#a9c04bbc: field sender_id is nil") } if err := m.SenderID.Encode(b); err != nil { - return fmt.Errorf("unable to encode message#dc764ddc: field sender_id: %w", err) + return fmt.Errorf("unable to encode message#a9c04bbc: field sender_id: %w", err) } b.PutInt53(m.ChatID) if m.SendingState == nil { - return fmt.Errorf("unable to encode message#dc764ddc: field sending_state is nil") + return fmt.Errorf("unable to encode message#a9c04bbc: field sending_state is nil") } if err := m.SendingState.Encode(b); err != nil { - return fmt.Errorf("unable to encode message#dc764ddc: field sending_state: %w", err) + return fmt.Errorf("unable to encode message#a9c04bbc: field sending_state: %w", err) } if m.SchedulingState == nil { - return fmt.Errorf("unable to encode message#dc764ddc: field scheduling_state is nil") + return fmt.Errorf("unable to encode message#a9c04bbc: field scheduling_state is nil") } if err := m.SchedulingState.Encode(b); err != nil { - return fmt.Errorf("unable to encode message#dc764ddc: field scheduling_state: %w", err) + return fmt.Errorf("unable to encode message#a9c04bbc: field scheduling_state: %w", err) } b.PutBool(m.IsOutgoing) b.PutBool(m.IsPinned) @@ -464,36 +473,36 @@ func (m *Message) EncodeBare(b *bin.Buffer) error { b.PutInt32(m.Date) b.PutInt32(m.EditDate) if err := m.ForwardInfo.Encode(b); err != nil { - return fmt.Errorf("unable to encode message#dc764ddc: field forward_info: %w", err) + return fmt.Errorf("unable to encode message#a9c04bbc: field forward_info: %w", err) } if err := m.ImportInfo.Encode(b); err != nil { - return fmt.Errorf("unable to encode message#dc764ddc: field import_info: %w", err) + return fmt.Errorf("unable to encode message#a9c04bbc: field import_info: %w", err) } if err := m.InteractionInfo.Encode(b); err != nil { - return fmt.Errorf("unable to encode message#dc764ddc: field interaction_info: %w", err) + return fmt.Errorf("unable to encode message#a9c04bbc: field interaction_info: %w", err) } b.PutInt(len(m.UnreadReactions)) for idx, v := range m.UnreadReactions { if err := v.EncodeBare(b); err != nil { - return fmt.Errorf("unable to encode bare message#dc764ddc: field unread_reactions element with index %d: %w", idx, err) + return fmt.Errorf("unable to encode bare message#a9c04bbc: field unread_reactions element with index %d: %w", idx, err) } } if err := m.FactCheck.Encode(b); err != nil { - return fmt.Errorf("unable to encode message#dc764ddc: field fact_check: %w", err) + return fmt.Errorf("unable to encode message#a9c04bbc: field fact_check: %w", err) } if m.ReplyTo == nil { - return fmt.Errorf("unable to encode message#dc764ddc: field reply_to is nil") + return fmt.Errorf("unable to encode message#a9c04bbc: field reply_to is nil") } if err := m.ReplyTo.Encode(b); err != nil { - return fmt.Errorf("unable to encode message#dc764ddc: field reply_to: %w", err) + return fmt.Errorf("unable to encode message#a9c04bbc: field reply_to: %w", err) } b.PutInt53(m.MessageThreadID) b.PutInt53(m.SavedMessagesTopicID) if m.SelfDestructType == nil { - return fmt.Errorf("unable to encode message#dc764ddc: field self_destruct_type is nil") + return fmt.Errorf("unable to encode message#a9c04bbc: field self_destruct_type is nil") } if err := m.SelfDestructType.Encode(b); err != nil { - return fmt.Errorf("unable to encode message#dc764ddc: field self_destruct_type: %w", err) + return fmt.Errorf("unable to encode message#a9c04bbc: field self_destruct_type: %w", err) } b.PutDouble(m.SelfDestructIn) b.PutDouble(m.AutoDeleteIn) @@ -503,18 +512,19 @@ func (m *Message) EncodeBare(b *bin.Buffer) error { b.PutString(m.AuthorSignature) b.PutLong(m.MediaAlbumID) b.PutLong(m.EffectID) + b.PutBool(m.HasSensitiveContent) b.PutString(m.RestrictionReason) if m.Content == nil { - return fmt.Errorf("unable to encode message#dc764ddc: field content is nil") + return fmt.Errorf("unable to encode message#a9c04bbc: field content is nil") } if err := m.Content.Encode(b); err != nil { - return fmt.Errorf("unable to encode message#dc764ddc: field content: %w", err) + return fmt.Errorf("unable to encode message#a9c04bbc: field content: %w", err) } if m.ReplyMarkup == nil { - return fmt.Errorf("unable to encode message#dc764ddc: field reply_markup is nil") + return fmt.Errorf("unable to encode message#a9c04bbc: field reply_markup is nil") } if err := m.ReplyMarkup.Encode(b); err != nil { - return fmt.Errorf("unable to encode message#dc764ddc: field reply_markup: %w", err) + return fmt.Errorf("unable to encode message#a9c04bbc: field reply_markup: %w", err) } return nil } @@ -522,10 +532,10 @@ func (m *Message) EncodeBare(b *bin.Buffer) error { // Decode implements bin.Decoder. func (m *Message) Decode(b *bin.Buffer) error { if m == nil { - return fmt.Errorf("can't decode message#dc764ddc to nil") + return fmt.Errorf("can't decode message#a9c04bbc to nil") } if err := b.ConsumeID(MessageTypeID); err != nil { - return fmt.Errorf("unable to decode message#dc764ddc: %w", err) + return fmt.Errorf("unable to decode message#a9c04bbc: %w", err) } return m.DecodeBare(b) } @@ -533,132 +543,132 @@ func (m *Message) Decode(b *bin.Buffer) error { // DecodeBare implements bin.BareDecoder. func (m *Message) DecodeBare(b *bin.Buffer) error { if m == nil { - return fmt.Errorf("can't decode message#dc764ddc to nil") + return fmt.Errorf("can't decode message#a9c04bbc to nil") } { value, err := b.Int53() if err != nil { - return fmt.Errorf("unable to decode message#dc764ddc: field id: %w", err) + return fmt.Errorf("unable to decode message#a9c04bbc: field id: %w", err) } m.ID = value } { value, err := DecodeMessageSender(b) if err != nil { - return fmt.Errorf("unable to decode message#dc764ddc: field sender_id: %w", err) + return fmt.Errorf("unable to decode message#a9c04bbc: field sender_id: %w", err) } m.SenderID = value } { value, err := b.Int53() if err != nil { - return fmt.Errorf("unable to decode message#dc764ddc: field chat_id: %w", err) + return fmt.Errorf("unable to decode message#a9c04bbc: field chat_id: %w", err) } m.ChatID = value } { value, err := DecodeMessageSendingState(b) if err != nil { - return fmt.Errorf("unable to decode message#dc764ddc: field sending_state: %w", err) + return fmt.Errorf("unable to decode message#a9c04bbc: field sending_state: %w", err) } m.SendingState = value } { value, err := DecodeMessageSchedulingState(b) if err != nil { - return fmt.Errorf("unable to decode message#dc764ddc: field scheduling_state: %w", err) + return fmt.Errorf("unable to decode message#a9c04bbc: field scheduling_state: %w", err) } m.SchedulingState = value } { value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode message#dc764ddc: field is_outgoing: %w", err) + return fmt.Errorf("unable to decode message#a9c04bbc: field is_outgoing: %w", err) } m.IsOutgoing = value } { value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode message#dc764ddc: field is_pinned: %w", err) + return fmt.Errorf("unable to decode message#a9c04bbc: field is_pinned: %w", err) } m.IsPinned = value } { value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode message#dc764ddc: field is_from_offline: %w", err) + return fmt.Errorf("unable to decode message#a9c04bbc: field is_from_offline: %w", err) } m.IsFromOffline = value } { value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode message#dc764ddc: field can_be_saved: %w", err) + return fmt.Errorf("unable to decode message#a9c04bbc: field can_be_saved: %w", err) } m.CanBeSaved = value } { value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode message#dc764ddc: field has_timestamped_media: %w", err) + return fmt.Errorf("unable to decode message#a9c04bbc: field has_timestamped_media: %w", err) } m.HasTimestampedMedia = value } { value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode message#dc764ddc: field is_channel_post: %w", err) + return fmt.Errorf("unable to decode message#a9c04bbc: field is_channel_post: %w", err) } m.IsChannelPost = value } { value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode message#dc764ddc: field is_topic_message: %w", err) + return fmt.Errorf("unable to decode message#a9c04bbc: field is_topic_message: %w", err) } m.IsTopicMessage = value } { value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode message#dc764ddc: field contains_unread_mention: %w", err) + return fmt.Errorf("unable to decode message#a9c04bbc: field contains_unread_mention: %w", err) } m.ContainsUnreadMention = value } { value, err := b.Int32() if err != nil { - return fmt.Errorf("unable to decode message#dc764ddc: field date: %w", err) + return fmt.Errorf("unable to decode message#a9c04bbc: field date: %w", err) } m.Date = value } { value, err := b.Int32() if err != nil { - return fmt.Errorf("unable to decode message#dc764ddc: field edit_date: %w", err) + return fmt.Errorf("unable to decode message#a9c04bbc: field edit_date: %w", err) } m.EditDate = value } { if err := m.ForwardInfo.Decode(b); err != nil { - return fmt.Errorf("unable to decode message#dc764ddc: field forward_info: %w", err) + return fmt.Errorf("unable to decode message#a9c04bbc: field forward_info: %w", err) } } { if err := m.ImportInfo.Decode(b); err != nil { - return fmt.Errorf("unable to decode message#dc764ddc: field import_info: %w", err) + return fmt.Errorf("unable to decode message#a9c04bbc: field import_info: %w", err) } } { if err := m.InteractionInfo.Decode(b); err != nil { - return fmt.Errorf("unable to decode message#dc764ddc: field interaction_info: %w", err) + return fmt.Errorf("unable to decode message#a9c04bbc: field interaction_info: %w", err) } } { headerLen, err := b.Int() if err != nil { - return fmt.Errorf("unable to decode message#dc764ddc: field unread_reactions: %w", err) + return fmt.Errorf("unable to decode message#a9c04bbc: field unread_reactions: %w", err) } if headerLen > 0 { @@ -667,118 +677,125 @@ func (m *Message) DecodeBare(b *bin.Buffer) error { for idx := 0; idx < headerLen; idx++ { var value UnreadReaction if err := value.DecodeBare(b); err != nil { - return fmt.Errorf("unable to decode bare message#dc764ddc: field unread_reactions: %w", err) + return fmt.Errorf("unable to decode bare message#a9c04bbc: field unread_reactions: %w", err) } m.UnreadReactions = append(m.UnreadReactions, value) } } { if err := m.FactCheck.Decode(b); err != nil { - return fmt.Errorf("unable to decode message#dc764ddc: field fact_check: %w", err) + return fmt.Errorf("unable to decode message#a9c04bbc: field fact_check: %w", err) } } { value, err := DecodeMessageReplyTo(b) if err != nil { - return fmt.Errorf("unable to decode message#dc764ddc: field reply_to: %w", err) + return fmt.Errorf("unable to decode message#a9c04bbc: field reply_to: %w", err) } m.ReplyTo = value } { value, err := b.Int53() if err != nil { - return fmt.Errorf("unable to decode message#dc764ddc: field message_thread_id: %w", err) + return fmt.Errorf("unable to decode message#a9c04bbc: field message_thread_id: %w", err) } m.MessageThreadID = value } { value, err := b.Int53() if err != nil { - return fmt.Errorf("unable to decode message#dc764ddc: field saved_messages_topic_id: %w", err) + return fmt.Errorf("unable to decode message#a9c04bbc: field saved_messages_topic_id: %w", err) } m.SavedMessagesTopicID = value } { value, err := DecodeMessageSelfDestructType(b) if err != nil { - return fmt.Errorf("unable to decode message#dc764ddc: field self_destruct_type: %w", err) + return fmt.Errorf("unable to decode message#a9c04bbc: field self_destruct_type: %w", err) } m.SelfDestructType = value } { value, err := b.Double() if err != nil { - return fmt.Errorf("unable to decode message#dc764ddc: field self_destruct_in: %w", err) + return fmt.Errorf("unable to decode message#a9c04bbc: field self_destruct_in: %w", err) } m.SelfDestructIn = value } { value, err := b.Double() if err != nil { - return fmt.Errorf("unable to decode message#dc764ddc: field auto_delete_in: %w", err) + return fmt.Errorf("unable to decode message#a9c04bbc: field auto_delete_in: %w", err) } m.AutoDeleteIn = value } { value, err := b.Int53() if err != nil { - return fmt.Errorf("unable to decode message#dc764ddc: field via_bot_user_id: %w", err) + return fmt.Errorf("unable to decode message#a9c04bbc: field via_bot_user_id: %w", err) } m.ViaBotUserID = value } { value, err := b.Int53() if err != nil { - return fmt.Errorf("unable to decode message#dc764ddc: field sender_business_bot_user_id: %w", err) + return fmt.Errorf("unable to decode message#a9c04bbc: field sender_business_bot_user_id: %w", err) } m.SenderBusinessBotUserID = value } { value, err := b.Int32() if err != nil { - return fmt.Errorf("unable to decode message#dc764ddc: field sender_boost_count: %w", err) + return fmt.Errorf("unable to decode message#a9c04bbc: field sender_boost_count: %w", err) } m.SenderBoostCount = value } { value, err := b.String() if err != nil { - return fmt.Errorf("unable to decode message#dc764ddc: field author_signature: %w", err) + return fmt.Errorf("unable to decode message#a9c04bbc: field author_signature: %w", err) } m.AuthorSignature = value } { value, err := b.Long() if err != nil { - return fmt.Errorf("unable to decode message#dc764ddc: field media_album_id: %w", err) + return fmt.Errorf("unable to decode message#a9c04bbc: field media_album_id: %w", err) } m.MediaAlbumID = value } { value, err := b.Long() if err != nil { - return fmt.Errorf("unable to decode message#dc764ddc: field effect_id: %w", err) + return fmt.Errorf("unable to decode message#a9c04bbc: field effect_id: %w", err) } m.EffectID = value } + { + value, err := b.Bool() + if err != nil { + return fmt.Errorf("unable to decode message#a9c04bbc: field has_sensitive_content: %w", err) + } + m.HasSensitiveContent = value + } { value, err := b.String() if err != nil { - return fmt.Errorf("unable to decode message#dc764ddc: field restriction_reason: %w", err) + return fmt.Errorf("unable to decode message#a9c04bbc: field restriction_reason: %w", err) } m.RestrictionReason = value } { value, err := DecodeMessageContent(b) if err != nil { - return fmt.Errorf("unable to decode message#dc764ddc: field content: %w", err) + return fmt.Errorf("unable to decode message#a9c04bbc: field content: %w", err) } m.Content = value } { value, err := DecodeReplyMarkup(b) if err != nil { - return fmt.Errorf("unable to decode message#dc764ddc: field reply_markup: %w", err) + return fmt.Errorf("unable to decode message#a9c04bbc: field reply_markup: %w", err) } m.ReplyMarkup = value } @@ -788,7 +805,7 @@ func (m *Message) DecodeBare(b *bin.Buffer) error { // EncodeTDLibJSON implements tdjson.TDLibEncoder. func (m *Message) EncodeTDLibJSON(b tdjson.Encoder) error { if m == nil { - return fmt.Errorf("can't encode message#dc764ddc as nil") + return fmt.Errorf("can't encode message#a9c04bbc as nil") } b.ObjStart() b.PutID("message") @@ -798,10 +815,10 @@ func (m *Message) EncodeTDLibJSON(b tdjson.Encoder) error { b.Comma() b.FieldStart("sender_id") if m.SenderID == nil { - return fmt.Errorf("unable to encode message#dc764ddc: field sender_id is nil") + return fmt.Errorf("unable to encode message#a9c04bbc: field sender_id is nil") } if err := m.SenderID.EncodeTDLibJSON(b); err != nil { - return fmt.Errorf("unable to encode message#dc764ddc: field sender_id: %w", err) + return fmt.Errorf("unable to encode message#a9c04bbc: field sender_id: %w", err) } b.Comma() b.FieldStart("chat_id") @@ -809,18 +826,18 @@ func (m *Message) EncodeTDLibJSON(b tdjson.Encoder) error { b.Comma() b.FieldStart("sending_state") if m.SendingState == nil { - return fmt.Errorf("unable to encode message#dc764ddc: field sending_state is nil") + return fmt.Errorf("unable to encode message#a9c04bbc: field sending_state is nil") } if err := m.SendingState.EncodeTDLibJSON(b); err != nil { - return fmt.Errorf("unable to encode message#dc764ddc: field sending_state: %w", err) + return fmt.Errorf("unable to encode message#a9c04bbc: field sending_state: %w", err) } b.Comma() b.FieldStart("scheduling_state") if m.SchedulingState == nil { - return fmt.Errorf("unable to encode message#dc764ddc: field scheduling_state is nil") + return fmt.Errorf("unable to encode message#a9c04bbc: field scheduling_state is nil") } if err := m.SchedulingState.EncodeTDLibJSON(b); err != nil { - return fmt.Errorf("unable to encode message#dc764ddc: field scheduling_state: %w", err) + return fmt.Errorf("unable to encode message#a9c04bbc: field scheduling_state: %w", err) } b.Comma() b.FieldStart("is_outgoing") @@ -855,24 +872,24 @@ func (m *Message) EncodeTDLibJSON(b tdjson.Encoder) error { b.Comma() b.FieldStart("forward_info") if err := m.ForwardInfo.EncodeTDLibJSON(b); err != nil { - return fmt.Errorf("unable to encode message#dc764ddc: field forward_info: %w", err) + return fmt.Errorf("unable to encode message#a9c04bbc: field forward_info: %w", err) } b.Comma() b.FieldStart("import_info") if err := m.ImportInfo.EncodeTDLibJSON(b); err != nil { - return fmt.Errorf("unable to encode message#dc764ddc: field import_info: %w", err) + return fmt.Errorf("unable to encode message#a9c04bbc: field import_info: %w", err) } b.Comma() b.FieldStart("interaction_info") if err := m.InteractionInfo.EncodeTDLibJSON(b); err != nil { - return fmt.Errorf("unable to encode message#dc764ddc: field interaction_info: %w", err) + return fmt.Errorf("unable to encode message#a9c04bbc: field interaction_info: %w", err) } b.Comma() b.FieldStart("unread_reactions") b.ArrStart() for idx, v := range m.UnreadReactions { if err := v.EncodeTDLibJSON(b); err != nil { - return fmt.Errorf("unable to encode message#dc764ddc: field unread_reactions element with index %d: %w", idx, err) + return fmt.Errorf("unable to encode message#a9c04bbc: field unread_reactions element with index %d: %w", idx, err) } b.Comma() } @@ -881,15 +898,15 @@ func (m *Message) EncodeTDLibJSON(b tdjson.Encoder) error { b.Comma() b.FieldStart("fact_check") if err := m.FactCheck.EncodeTDLibJSON(b); err != nil { - return fmt.Errorf("unable to encode message#dc764ddc: field fact_check: %w", err) + return fmt.Errorf("unable to encode message#a9c04bbc: field fact_check: %w", err) } b.Comma() b.FieldStart("reply_to") if m.ReplyTo == nil { - return fmt.Errorf("unable to encode message#dc764ddc: field reply_to is nil") + return fmt.Errorf("unable to encode message#a9c04bbc: field reply_to is nil") } if err := m.ReplyTo.EncodeTDLibJSON(b); err != nil { - return fmt.Errorf("unable to encode message#dc764ddc: field reply_to: %w", err) + return fmt.Errorf("unable to encode message#a9c04bbc: field reply_to: %w", err) } b.Comma() b.FieldStart("message_thread_id") @@ -900,10 +917,10 @@ func (m *Message) EncodeTDLibJSON(b tdjson.Encoder) error { b.Comma() b.FieldStart("self_destruct_type") if m.SelfDestructType == nil { - return fmt.Errorf("unable to encode message#dc764ddc: field self_destruct_type is nil") + return fmt.Errorf("unable to encode message#a9c04bbc: field self_destruct_type is nil") } if err := m.SelfDestructType.EncodeTDLibJSON(b); err != nil { - return fmt.Errorf("unable to encode message#dc764ddc: field self_destruct_type: %w", err) + return fmt.Errorf("unable to encode message#a9c04bbc: field self_destruct_type: %w", err) } b.Comma() b.FieldStart("self_destruct_in") @@ -930,23 +947,26 @@ func (m *Message) EncodeTDLibJSON(b tdjson.Encoder) error { b.FieldStart("effect_id") b.PutLong(m.EffectID) b.Comma() + b.FieldStart("has_sensitive_content") + b.PutBool(m.HasSensitiveContent) + b.Comma() b.FieldStart("restriction_reason") b.PutString(m.RestrictionReason) b.Comma() b.FieldStart("content") if m.Content == nil { - return fmt.Errorf("unable to encode message#dc764ddc: field content is nil") + return fmt.Errorf("unable to encode message#a9c04bbc: field content is nil") } if err := m.Content.EncodeTDLibJSON(b); err != nil { - return fmt.Errorf("unable to encode message#dc764ddc: field content: %w", err) + return fmt.Errorf("unable to encode message#a9c04bbc: field content: %w", err) } b.Comma() b.FieldStart("reply_markup") if m.ReplyMarkup == nil { - return fmt.Errorf("unable to encode message#dc764ddc: field reply_markup is nil") + return fmt.Errorf("unable to encode message#a9c04bbc: field reply_markup is nil") } if err := m.ReplyMarkup.EncodeTDLibJSON(b); err != nil { - return fmt.Errorf("unable to encode message#dc764ddc: field reply_markup: %w", err) + return fmt.Errorf("unable to encode message#a9c04bbc: field reply_markup: %w", err) } b.Comma() b.StripComma() @@ -957,220 +977,226 @@ func (m *Message) EncodeTDLibJSON(b tdjson.Encoder) error { // DecodeTDLibJSON implements tdjson.TDLibDecoder. func (m *Message) DecodeTDLibJSON(b tdjson.Decoder) error { if m == nil { - return fmt.Errorf("can't decode message#dc764ddc to nil") + return fmt.Errorf("can't decode message#a9c04bbc to nil") } return b.Obj(func(b tdjson.Decoder, key []byte) error { switch string(key) { case tdjson.TypeField: if err := b.ConsumeID("message"); err != nil { - return fmt.Errorf("unable to decode message#dc764ddc: %w", err) + return fmt.Errorf("unable to decode message#a9c04bbc: %w", err) } case "id": value, err := b.Int53() if err != nil { - return fmt.Errorf("unable to decode message#dc764ddc: field id: %w", err) + return fmt.Errorf("unable to decode message#a9c04bbc: field id: %w", err) } m.ID = value case "sender_id": value, err := DecodeTDLibJSONMessageSender(b) if err != nil { - return fmt.Errorf("unable to decode message#dc764ddc: field sender_id: %w", err) + return fmt.Errorf("unable to decode message#a9c04bbc: field sender_id: %w", err) } m.SenderID = value case "chat_id": value, err := b.Int53() if err != nil { - return fmt.Errorf("unable to decode message#dc764ddc: field chat_id: %w", err) + return fmt.Errorf("unable to decode message#a9c04bbc: field chat_id: %w", err) } m.ChatID = value case "sending_state": value, err := DecodeTDLibJSONMessageSendingState(b) if err != nil { - return fmt.Errorf("unable to decode message#dc764ddc: field sending_state: %w", err) + return fmt.Errorf("unable to decode message#a9c04bbc: field sending_state: %w", err) } m.SendingState = value case "scheduling_state": value, err := DecodeTDLibJSONMessageSchedulingState(b) if err != nil { - return fmt.Errorf("unable to decode message#dc764ddc: field scheduling_state: %w", err) + return fmt.Errorf("unable to decode message#a9c04bbc: field scheduling_state: %w", err) } m.SchedulingState = value case "is_outgoing": value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode message#dc764ddc: field is_outgoing: %w", err) + return fmt.Errorf("unable to decode message#a9c04bbc: field is_outgoing: %w", err) } m.IsOutgoing = value case "is_pinned": value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode message#dc764ddc: field is_pinned: %w", err) + return fmt.Errorf("unable to decode message#a9c04bbc: field is_pinned: %w", err) } m.IsPinned = value case "is_from_offline": value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode message#dc764ddc: field is_from_offline: %w", err) + return fmt.Errorf("unable to decode message#a9c04bbc: field is_from_offline: %w", err) } m.IsFromOffline = value case "can_be_saved": value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode message#dc764ddc: field can_be_saved: %w", err) + return fmt.Errorf("unable to decode message#a9c04bbc: field can_be_saved: %w", err) } m.CanBeSaved = value case "has_timestamped_media": value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode message#dc764ddc: field has_timestamped_media: %w", err) + return fmt.Errorf("unable to decode message#a9c04bbc: field has_timestamped_media: %w", err) } m.HasTimestampedMedia = value case "is_channel_post": value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode message#dc764ddc: field is_channel_post: %w", err) + return fmt.Errorf("unable to decode message#a9c04bbc: field is_channel_post: %w", err) } m.IsChannelPost = value case "is_topic_message": value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode message#dc764ddc: field is_topic_message: %w", err) + return fmt.Errorf("unable to decode message#a9c04bbc: field is_topic_message: %w", err) } m.IsTopicMessage = value case "contains_unread_mention": value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode message#dc764ddc: field contains_unread_mention: %w", err) + return fmt.Errorf("unable to decode message#a9c04bbc: field contains_unread_mention: %w", err) } m.ContainsUnreadMention = value case "date": value, err := b.Int32() if err != nil { - return fmt.Errorf("unable to decode message#dc764ddc: field date: %w", err) + return fmt.Errorf("unable to decode message#a9c04bbc: field date: %w", err) } m.Date = value case "edit_date": value, err := b.Int32() if err != nil { - return fmt.Errorf("unable to decode message#dc764ddc: field edit_date: %w", err) + return fmt.Errorf("unable to decode message#a9c04bbc: field edit_date: %w", err) } m.EditDate = value case "forward_info": if err := m.ForwardInfo.DecodeTDLibJSON(b); err != nil { - return fmt.Errorf("unable to decode message#dc764ddc: field forward_info: %w", err) + return fmt.Errorf("unable to decode message#a9c04bbc: field forward_info: %w", err) } case "import_info": if err := m.ImportInfo.DecodeTDLibJSON(b); err != nil { - return fmt.Errorf("unable to decode message#dc764ddc: field import_info: %w", err) + return fmt.Errorf("unable to decode message#a9c04bbc: field import_info: %w", err) } case "interaction_info": if err := m.InteractionInfo.DecodeTDLibJSON(b); err != nil { - return fmt.Errorf("unable to decode message#dc764ddc: field interaction_info: %w", err) + return fmt.Errorf("unable to decode message#a9c04bbc: field interaction_info: %w", err) } case "unread_reactions": if err := b.Arr(func(b tdjson.Decoder) error { var value UnreadReaction if err := value.DecodeTDLibJSON(b); err != nil { - return fmt.Errorf("unable to decode message#dc764ddc: field unread_reactions: %w", err) + return fmt.Errorf("unable to decode message#a9c04bbc: field unread_reactions: %w", err) } m.UnreadReactions = append(m.UnreadReactions, value) return nil }); err != nil { - return fmt.Errorf("unable to decode message#dc764ddc: field unread_reactions: %w", err) + return fmt.Errorf("unable to decode message#a9c04bbc: field unread_reactions: %w", err) } case "fact_check": if err := m.FactCheck.DecodeTDLibJSON(b); err != nil { - return fmt.Errorf("unable to decode message#dc764ddc: field fact_check: %w", err) + return fmt.Errorf("unable to decode message#a9c04bbc: field fact_check: %w", err) } case "reply_to": value, err := DecodeTDLibJSONMessageReplyTo(b) if err != nil { - return fmt.Errorf("unable to decode message#dc764ddc: field reply_to: %w", err) + return fmt.Errorf("unable to decode message#a9c04bbc: field reply_to: %w", err) } m.ReplyTo = value case "message_thread_id": value, err := b.Int53() if err != nil { - return fmt.Errorf("unable to decode message#dc764ddc: field message_thread_id: %w", err) + return fmt.Errorf("unable to decode message#a9c04bbc: field message_thread_id: %w", err) } m.MessageThreadID = value case "saved_messages_topic_id": value, err := b.Int53() if err != nil { - return fmt.Errorf("unable to decode message#dc764ddc: field saved_messages_topic_id: %w", err) + return fmt.Errorf("unable to decode message#a9c04bbc: field saved_messages_topic_id: %w", err) } m.SavedMessagesTopicID = value case "self_destruct_type": value, err := DecodeTDLibJSONMessageSelfDestructType(b) if err != nil { - return fmt.Errorf("unable to decode message#dc764ddc: field self_destruct_type: %w", err) + return fmt.Errorf("unable to decode message#a9c04bbc: field self_destruct_type: %w", err) } m.SelfDestructType = value case "self_destruct_in": value, err := b.Double() if err != nil { - return fmt.Errorf("unable to decode message#dc764ddc: field self_destruct_in: %w", err) + return fmt.Errorf("unable to decode message#a9c04bbc: field self_destruct_in: %w", err) } m.SelfDestructIn = value case "auto_delete_in": value, err := b.Double() if err != nil { - return fmt.Errorf("unable to decode message#dc764ddc: field auto_delete_in: %w", err) + return fmt.Errorf("unable to decode message#a9c04bbc: field auto_delete_in: %w", err) } m.AutoDeleteIn = value case "via_bot_user_id": value, err := b.Int53() if err != nil { - return fmt.Errorf("unable to decode message#dc764ddc: field via_bot_user_id: %w", err) + return fmt.Errorf("unable to decode message#a9c04bbc: field via_bot_user_id: %w", err) } m.ViaBotUserID = value case "sender_business_bot_user_id": value, err := b.Int53() if err != nil { - return fmt.Errorf("unable to decode message#dc764ddc: field sender_business_bot_user_id: %w", err) + return fmt.Errorf("unable to decode message#a9c04bbc: field sender_business_bot_user_id: %w", err) } m.SenderBusinessBotUserID = value case "sender_boost_count": value, err := b.Int32() if err != nil { - return fmt.Errorf("unable to decode message#dc764ddc: field sender_boost_count: %w", err) + return fmt.Errorf("unable to decode message#a9c04bbc: field sender_boost_count: %w", err) } m.SenderBoostCount = value case "author_signature": value, err := b.String() if err != nil { - return fmt.Errorf("unable to decode message#dc764ddc: field author_signature: %w", err) + return fmt.Errorf("unable to decode message#a9c04bbc: field author_signature: %w", err) } m.AuthorSignature = value case "media_album_id": value, err := b.Long() if err != nil { - return fmt.Errorf("unable to decode message#dc764ddc: field media_album_id: %w", err) + return fmt.Errorf("unable to decode message#a9c04bbc: field media_album_id: %w", err) } m.MediaAlbumID = value case "effect_id": value, err := b.Long() if err != nil { - return fmt.Errorf("unable to decode message#dc764ddc: field effect_id: %w", err) + return fmt.Errorf("unable to decode message#a9c04bbc: field effect_id: %w", err) } m.EffectID = value + case "has_sensitive_content": + value, err := b.Bool() + if err != nil { + return fmt.Errorf("unable to decode message#a9c04bbc: field has_sensitive_content: %w", err) + } + m.HasSensitiveContent = value case "restriction_reason": value, err := b.String() if err != nil { - return fmt.Errorf("unable to decode message#dc764ddc: field restriction_reason: %w", err) + return fmt.Errorf("unable to decode message#a9c04bbc: field restriction_reason: %w", err) } m.RestrictionReason = value case "content": value, err := DecodeTDLibJSONMessageContent(b) if err != nil { - return fmt.Errorf("unable to decode message#dc764ddc: field content: %w", err) + return fmt.Errorf("unable to decode message#a9c04bbc: field content: %w", err) } m.Content = value case "reply_markup": value, err := DecodeTDLibJSONReplyMarkup(b) if err != nil { - return fmt.Errorf("unable to decode message#dc764ddc: field reply_markup: %w", err) + return fmt.Errorf("unable to decode message#a9c04bbc: field reply_markup: %w", err) } m.ReplyMarkup = value default: @@ -1436,6 +1462,14 @@ func (m *Message) GetEffectID() (value int64) { return m.EffectID } +// GetHasSensitiveContent returns value of HasSensitiveContent field. +func (m *Message) GetHasSensitiveContent() (value bool) { + if m == nil { + return + } + return m.HasSensitiveContent +} + // GetRestrictionReason returns value of RestrictionReason field. func (m *Message) GetRestrictionReason() (value string) { if m == nil { diff --git a/tdapi/tl_message_properties_gen.go b/tdapi/tl_message_properties_gen.go index 4837e6b4b7..09b5685619 100644 --- a/tdapi/tl_message_properties_gen.go +++ b/tdapi/tl_message_properties_gen.go @@ -31,7 +31,7 @@ var ( _ = tdjson.Encoder{} ) -// MessageProperties represents TL type `messageProperties#5ae4cb28`. +// MessageProperties represents TL type `messageProperties#11deeec2`. type MessageProperties struct { // True, if the message can be deleted only for the current user while other users will // continue to see it using the method deleteMessages with revoke == false @@ -62,8 +62,6 @@ type MessageProperties struct { CanBeSharedInStory bool // True, if scheduling state of the message can be edited CanEditSchedulingState bool - // True, if the list of added reactions is available using getMessageAddedReactions - CanGetAddedReactions bool // True, if code for message embedding can be received using getMessageEmbeddingCode CanGetEmbeddingCode bool // True, if a link can be generated for the message using getMessageLink @@ -97,7 +95,7 @@ type MessageProperties struct { } // MessagePropertiesTypeID is TL type id of MessageProperties. -const MessagePropertiesTypeID = 0x5ae4cb28 +const MessagePropertiesTypeID = 0x11deeec2 // Ensuring interfaces in compile-time for MessageProperties. var ( @@ -144,9 +142,6 @@ func (m *MessageProperties) Zero() bool { if !(m.CanEditSchedulingState == false) { return false } - if !(m.CanGetAddedReactions == false) { - return false - } if !(m.CanGetEmbeddingCode == false) { return false } @@ -266,10 +261,6 @@ func (m *MessageProperties) TypeInfo() tdp.Type { Name: "CanEditSchedulingState", SchemaName: "can_edit_scheduling_state", }, - { - Name: "CanGetAddedReactions", - SchemaName: "can_get_added_reactions", - }, { Name: "CanGetEmbeddingCode", SchemaName: "can_get_embedding_code", @@ -329,7 +320,7 @@ func (m *MessageProperties) TypeInfo() tdp.Type { // Encode implements bin.Encoder. func (m *MessageProperties) Encode(b *bin.Buffer) error { if m == nil { - return fmt.Errorf("can't encode messageProperties#5ae4cb28 as nil") + return fmt.Errorf("can't encode messageProperties#11deeec2 as nil") } b.PutID(MessagePropertiesTypeID) return m.EncodeBare(b) @@ -338,7 +329,7 @@ func (m *MessageProperties) Encode(b *bin.Buffer) error { // EncodeBare implements bin.BareEncoder. func (m *MessageProperties) EncodeBare(b *bin.Buffer) error { if m == nil { - return fmt.Errorf("can't encode messageProperties#5ae4cb28 as nil") + return fmt.Errorf("can't encode messageProperties#11deeec2 as nil") } b.PutBool(m.CanBeDeletedOnlyForSelf) b.PutBool(m.CanBeDeletedForAllUsers) @@ -351,7 +342,6 @@ func (m *MessageProperties) EncodeBare(b *bin.Buffer) error { b.PutBool(m.CanBeSaved) b.PutBool(m.CanBeSharedInStory) b.PutBool(m.CanEditSchedulingState) - b.PutBool(m.CanGetAddedReactions) b.PutBool(m.CanGetEmbeddingCode) b.PutBool(m.CanGetLink) b.PutBool(m.CanGetMediaTimestampLinks) @@ -371,10 +361,10 @@ func (m *MessageProperties) EncodeBare(b *bin.Buffer) error { // Decode implements bin.Decoder. func (m *MessageProperties) Decode(b *bin.Buffer) error { if m == nil { - return fmt.Errorf("can't decode messageProperties#5ae4cb28 to nil") + return fmt.Errorf("can't decode messageProperties#11deeec2 to nil") } if err := b.ConsumeID(MessagePropertiesTypeID); err != nil { - return fmt.Errorf("unable to decode messageProperties#5ae4cb28: %w", err) + return fmt.Errorf("unable to decode messageProperties#11deeec2: %w", err) } return m.DecodeBare(b) } @@ -382,180 +372,173 @@ func (m *MessageProperties) Decode(b *bin.Buffer) error { // DecodeBare implements bin.BareDecoder. func (m *MessageProperties) DecodeBare(b *bin.Buffer) error { if m == nil { - return fmt.Errorf("can't decode messageProperties#5ae4cb28 to nil") + return fmt.Errorf("can't decode messageProperties#11deeec2 to nil") } { value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode messageProperties#5ae4cb28: field can_be_deleted_only_for_self: %w", err) + return fmt.Errorf("unable to decode messageProperties#11deeec2: field can_be_deleted_only_for_self: %w", err) } m.CanBeDeletedOnlyForSelf = value } { value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode messageProperties#5ae4cb28: field can_be_deleted_for_all_users: %w", err) + return fmt.Errorf("unable to decode messageProperties#11deeec2: field can_be_deleted_for_all_users: %w", err) } m.CanBeDeletedForAllUsers = value } { value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode messageProperties#5ae4cb28: field can_be_edited: %w", err) + return fmt.Errorf("unable to decode messageProperties#11deeec2: field can_be_edited: %w", err) } m.CanBeEdited = value } { value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode messageProperties#5ae4cb28: field can_be_forwarded: %w", err) + return fmt.Errorf("unable to decode messageProperties#11deeec2: field can_be_forwarded: %w", err) } m.CanBeForwarded = value } { value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode messageProperties#5ae4cb28: field can_be_paid: %w", err) + return fmt.Errorf("unable to decode messageProperties#11deeec2: field can_be_paid: %w", err) } m.CanBePaid = value } { value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode messageProperties#5ae4cb28: field can_be_pinned: %w", err) + return fmt.Errorf("unable to decode messageProperties#11deeec2: field can_be_pinned: %w", err) } m.CanBePinned = value } { value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode messageProperties#5ae4cb28: field can_be_replied: %w", err) + return fmt.Errorf("unable to decode messageProperties#11deeec2: field can_be_replied: %w", err) } m.CanBeReplied = value } { value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode messageProperties#5ae4cb28: field can_be_replied_in_another_chat: %w", err) + return fmt.Errorf("unable to decode messageProperties#11deeec2: field can_be_replied_in_another_chat: %w", err) } m.CanBeRepliedInAnotherChat = value } { value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode messageProperties#5ae4cb28: field can_be_saved: %w", err) + return fmt.Errorf("unable to decode messageProperties#11deeec2: field can_be_saved: %w", err) } m.CanBeSaved = value } { value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode messageProperties#5ae4cb28: field can_be_shared_in_story: %w", err) + return fmt.Errorf("unable to decode messageProperties#11deeec2: field can_be_shared_in_story: %w", err) } m.CanBeSharedInStory = value } { value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode messageProperties#5ae4cb28: field can_edit_scheduling_state: %w", err) + return fmt.Errorf("unable to decode messageProperties#11deeec2: field can_edit_scheduling_state: %w", err) } m.CanEditSchedulingState = value } { value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode messageProperties#5ae4cb28: field can_get_added_reactions: %w", err) - } - m.CanGetAddedReactions = value - } - { - value, err := b.Bool() - if err != nil { - return fmt.Errorf("unable to decode messageProperties#5ae4cb28: field can_get_embedding_code: %w", err) + return fmt.Errorf("unable to decode messageProperties#11deeec2: field can_get_embedding_code: %w", err) } m.CanGetEmbeddingCode = value } { value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode messageProperties#5ae4cb28: field can_get_link: %w", err) + return fmt.Errorf("unable to decode messageProperties#11deeec2: field can_get_link: %w", err) } m.CanGetLink = value } { value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode messageProperties#5ae4cb28: field can_get_media_timestamp_links: %w", err) + return fmt.Errorf("unable to decode messageProperties#11deeec2: field can_get_media_timestamp_links: %w", err) } m.CanGetMediaTimestampLinks = value } { value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode messageProperties#5ae4cb28: field can_get_message_thread: %w", err) + return fmt.Errorf("unable to decode messageProperties#11deeec2: field can_get_message_thread: %w", err) } m.CanGetMessageThread = value } { value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode messageProperties#5ae4cb28: field can_get_read_date: %w", err) + return fmt.Errorf("unable to decode messageProperties#11deeec2: field can_get_read_date: %w", err) } m.CanGetReadDate = value } { value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode messageProperties#5ae4cb28: field can_get_statistics: %w", err) + return fmt.Errorf("unable to decode messageProperties#11deeec2: field can_get_statistics: %w", err) } m.CanGetStatistics = value } { value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode messageProperties#5ae4cb28: field can_get_viewers: %w", err) + return fmt.Errorf("unable to decode messageProperties#11deeec2: field can_get_viewers: %w", err) } m.CanGetViewers = value } { value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode messageProperties#5ae4cb28: field can_recognize_speech: %w", err) + return fmt.Errorf("unable to decode messageProperties#11deeec2: field can_recognize_speech: %w", err) } m.CanRecognizeSpeech = value } { value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode messageProperties#5ae4cb28: field can_report_chat: %w", err) + return fmt.Errorf("unable to decode messageProperties#11deeec2: field can_report_chat: %w", err) } m.CanReportChat = value } { value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode messageProperties#5ae4cb28: field can_report_reactions: %w", err) + return fmt.Errorf("unable to decode messageProperties#11deeec2: field can_report_reactions: %w", err) } m.CanReportReactions = value } { value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode messageProperties#5ae4cb28: field can_report_supergroup_spam: %w", err) + return fmt.Errorf("unable to decode messageProperties#11deeec2: field can_report_supergroup_spam: %w", err) } m.CanReportSupergroupSpam = value } { value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode messageProperties#5ae4cb28: field can_set_fact_check: %w", err) + return fmt.Errorf("unable to decode messageProperties#11deeec2: field can_set_fact_check: %w", err) } m.CanSetFactCheck = value } { value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode messageProperties#5ae4cb28: field need_show_statistics: %w", err) + return fmt.Errorf("unable to decode messageProperties#11deeec2: field need_show_statistics: %w", err) } m.NeedShowStatistics = value } @@ -565,7 +548,7 @@ func (m *MessageProperties) DecodeBare(b *bin.Buffer) error { // EncodeTDLibJSON implements tdjson.TDLibEncoder. func (m *MessageProperties) EncodeTDLibJSON(b tdjson.Encoder) error { if m == nil { - return fmt.Errorf("can't encode messageProperties#5ae4cb28 as nil") + return fmt.Errorf("can't encode messageProperties#11deeec2 as nil") } b.ObjStart() b.PutID("messageProperties") @@ -603,9 +586,6 @@ func (m *MessageProperties) EncodeTDLibJSON(b tdjson.Encoder) error { b.FieldStart("can_edit_scheduling_state") b.PutBool(m.CanEditSchedulingState) b.Comma() - b.FieldStart("can_get_added_reactions") - b.PutBool(m.CanGetAddedReactions) - b.Comma() b.FieldStart("can_get_embedding_code") b.PutBool(m.CanGetEmbeddingCode) b.Comma() @@ -653,163 +633,157 @@ func (m *MessageProperties) EncodeTDLibJSON(b tdjson.Encoder) error { // DecodeTDLibJSON implements tdjson.TDLibDecoder. func (m *MessageProperties) DecodeTDLibJSON(b tdjson.Decoder) error { if m == nil { - return fmt.Errorf("can't decode messageProperties#5ae4cb28 to nil") + return fmt.Errorf("can't decode messageProperties#11deeec2 to nil") } return b.Obj(func(b tdjson.Decoder, key []byte) error { switch string(key) { case tdjson.TypeField: if err := b.ConsumeID("messageProperties"); err != nil { - return fmt.Errorf("unable to decode messageProperties#5ae4cb28: %w", err) + return fmt.Errorf("unable to decode messageProperties#11deeec2: %w", err) } case "can_be_deleted_only_for_self": value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode messageProperties#5ae4cb28: field can_be_deleted_only_for_self: %w", err) + return fmt.Errorf("unable to decode messageProperties#11deeec2: field can_be_deleted_only_for_self: %w", err) } m.CanBeDeletedOnlyForSelf = value case "can_be_deleted_for_all_users": value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode messageProperties#5ae4cb28: field can_be_deleted_for_all_users: %w", err) + return fmt.Errorf("unable to decode messageProperties#11deeec2: field can_be_deleted_for_all_users: %w", err) } m.CanBeDeletedForAllUsers = value case "can_be_edited": value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode messageProperties#5ae4cb28: field can_be_edited: %w", err) + return fmt.Errorf("unable to decode messageProperties#11deeec2: field can_be_edited: %w", err) } m.CanBeEdited = value case "can_be_forwarded": value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode messageProperties#5ae4cb28: field can_be_forwarded: %w", err) + return fmt.Errorf("unable to decode messageProperties#11deeec2: field can_be_forwarded: %w", err) } m.CanBeForwarded = value case "can_be_paid": value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode messageProperties#5ae4cb28: field can_be_paid: %w", err) + return fmt.Errorf("unable to decode messageProperties#11deeec2: field can_be_paid: %w", err) } m.CanBePaid = value case "can_be_pinned": value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode messageProperties#5ae4cb28: field can_be_pinned: %w", err) + return fmt.Errorf("unable to decode messageProperties#11deeec2: field can_be_pinned: %w", err) } m.CanBePinned = value case "can_be_replied": value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode messageProperties#5ae4cb28: field can_be_replied: %w", err) + return fmt.Errorf("unable to decode messageProperties#11deeec2: field can_be_replied: %w", err) } m.CanBeReplied = value case "can_be_replied_in_another_chat": value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode messageProperties#5ae4cb28: field can_be_replied_in_another_chat: %w", err) + return fmt.Errorf("unable to decode messageProperties#11deeec2: field can_be_replied_in_another_chat: %w", err) } m.CanBeRepliedInAnotherChat = value case "can_be_saved": value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode messageProperties#5ae4cb28: field can_be_saved: %w", err) + return fmt.Errorf("unable to decode messageProperties#11deeec2: field can_be_saved: %w", err) } m.CanBeSaved = value case "can_be_shared_in_story": value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode messageProperties#5ae4cb28: field can_be_shared_in_story: %w", err) + return fmt.Errorf("unable to decode messageProperties#11deeec2: field can_be_shared_in_story: %w", err) } m.CanBeSharedInStory = value case "can_edit_scheduling_state": value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode messageProperties#5ae4cb28: field can_edit_scheduling_state: %w", err) + return fmt.Errorf("unable to decode messageProperties#11deeec2: field can_edit_scheduling_state: %w", err) } m.CanEditSchedulingState = value - case "can_get_added_reactions": - value, err := b.Bool() - if err != nil { - return fmt.Errorf("unable to decode messageProperties#5ae4cb28: field can_get_added_reactions: %w", err) - } - m.CanGetAddedReactions = value case "can_get_embedding_code": value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode messageProperties#5ae4cb28: field can_get_embedding_code: %w", err) + return fmt.Errorf("unable to decode messageProperties#11deeec2: field can_get_embedding_code: %w", err) } m.CanGetEmbeddingCode = value case "can_get_link": value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode messageProperties#5ae4cb28: field can_get_link: %w", err) + return fmt.Errorf("unable to decode messageProperties#11deeec2: field can_get_link: %w", err) } m.CanGetLink = value case "can_get_media_timestamp_links": value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode messageProperties#5ae4cb28: field can_get_media_timestamp_links: %w", err) + return fmt.Errorf("unable to decode messageProperties#11deeec2: field can_get_media_timestamp_links: %w", err) } m.CanGetMediaTimestampLinks = value case "can_get_message_thread": value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode messageProperties#5ae4cb28: field can_get_message_thread: %w", err) + return fmt.Errorf("unable to decode messageProperties#11deeec2: field can_get_message_thread: %w", err) } m.CanGetMessageThread = value case "can_get_read_date": value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode messageProperties#5ae4cb28: field can_get_read_date: %w", err) + return fmt.Errorf("unable to decode messageProperties#11deeec2: field can_get_read_date: %w", err) } m.CanGetReadDate = value case "can_get_statistics": value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode messageProperties#5ae4cb28: field can_get_statistics: %w", err) + return fmt.Errorf("unable to decode messageProperties#11deeec2: field can_get_statistics: %w", err) } m.CanGetStatistics = value case "can_get_viewers": value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode messageProperties#5ae4cb28: field can_get_viewers: %w", err) + return fmt.Errorf("unable to decode messageProperties#11deeec2: field can_get_viewers: %w", err) } m.CanGetViewers = value case "can_recognize_speech": value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode messageProperties#5ae4cb28: field can_recognize_speech: %w", err) + return fmt.Errorf("unable to decode messageProperties#11deeec2: field can_recognize_speech: %w", err) } m.CanRecognizeSpeech = value case "can_report_chat": value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode messageProperties#5ae4cb28: field can_report_chat: %w", err) + return fmt.Errorf("unable to decode messageProperties#11deeec2: field can_report_chat: %w", err) } m.CanReportChat = value case "can_report_reactions": value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode messageProperties#5ae4cb28: field can_report_reactions: %w", err) + return fmt.Errorf("unable to decode messageProperties#11deeec2: field can_report_reactions: %w", err) } m.CanReportReactions = value case "can_report_supergroup_spam": value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode messageProperties#5ae4cb28: field can_report_supergroup_spam: %w", err) + return fmt.Errorf("unable to decode messageProperties#11deeec2: field can_report_supergroup_spam: %w", err) } m.CanReportSupergroupSpam = value case "can_set_fact_check": value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode messageProperties#5ae4cb28: field can_set_fact_check: %w", err) + return fmt.Errorf("unable to decode messageProperties#11deeec2: field can_set_fact_check: %w", err) } m.CanSetFactCheck = value case "need_show_statistics": value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode messageProperties#5ae4cb28: field need_show_statistics: %w", err) + return fmt.Errorf("unable to decode messageProperties#11deeec2: field need_show_statistics: %w", err) } m.NeedShowStatistics = value default: @@ -907,14 +881,6 @@ func (m *MessageProperties) GetCanEditSchedulingState() (value bool) { return m.CanEditSchedulingState } -// GetCanGetAddedReactions returns value of CanGetAddedReactions field. -func (m *MessageProperties) GetCanGetAddedReactions() (value bool) { - if m == nil { - return - } - return m.CanGetAddedReactions -} - // GetCanGetEmbeddingCode returns value of CanGetEmbeddingCode field. func (m *MessageProperties) GetCanGetEmbeddingCode() (value bool) { if m == nil { diff --git a/tdapi/tl_message_reactions_gen.go b/tdapi/tl_message_reactions_gen.go index b329b5abfd..810cd2cd72 100644 --- a/tdapi/tl_message_reactions_gen.go +++ b/tdapi/tl_message_reactions_gen.go @@ -31,16 +31,20 @@ var ( _ = tdjson.Encoder{} ) -// MessageReactions represents TL type `messageReactions#91986cd8`. +// MessageReactions represents TL type `messageReactions#9d558cb`. type MessageReactions struct { // List of added reactions Reactions []MessageReaction // True, if the reactions are tags and Telegram Premium users can filter messages by them AreTags bool + // Information about top users that added the paid reaction + PaidReactors []PaidReactor + // True, if the list of added reactions is available using getMessageAddedReactions + CanGetAddedReactions bool } // MessageReactionsTypeID is TL type id of MessageReactions. -const MessageReactionsTypeID = 0x91986cd8 +const MessageReactionsTypeID = 0x9d558cb // Ensuring interfaces in compile-time for MessageReactions. var ( @@ -60,6 +64,12 @@ func (m *MessageReactions) Zero() bool { if !(m.AreTags == false) { return false } + if !(m.PaidReactors == nil) { + return false + } + if !(m.CanGetAddedReactions == false) { + return false + } return true } @@ -104,6 +114,14 @@ func (m *MessageReactions) TypeInfo() tdp.Type { Name: "AreTags", SchemaName: "are_tags", }, + { + Name: "PaidReactors", + SchemaName: "paid_reactors", + }, + { + Name: "CanGetAddedReactions", + SchemaName: "can_get_added_reactions", + }, } return typ } @@ -111,7 +129,7 @@ func (m *MessageReactions) TypeInfo() tdp.Type { // Encode implements bin.Encoder. func (m *MessageReactions) Encode(b *bin.Buffer) error { if m == nil { - return fmt.Errorf("can't encode messageReactions#91986cd8 as nil") + return fmt.Errorf("can't encode messageReactions#9d558cb as nil") } b.PutID(MessageReactionsTypeID) return m.EncodeBare(b) @@ -120,25 +138,32 @@ func (m *MessageReactions) Encode(b *bin.Buffer) error { // EncodeBare implements bin.BareEncoder. func (m *MessageReactions) EncodeBare(b *bin.Buffer) error { if m == nil { - return fmt.Errorf("can't encode messageReactions#91986cd8 as nil") + return fmt.Errorf("can't encode messageReactions#9d558cb as nil") } b.PutInt(len(m.Reactions)) for idx, v := range m.Reactions { if err := v.EncodeBare(b); err != nil { - return fmt.Errorf("unable to encode bare messageReactions#91986cd8: field reactions element with index %d: %w", idx, err) + return fmt.Errorf("unable to encode bare messageReactions#9d558cb: field reactions element with index %d: %w", idx, err) } } b.PutBool(m.AreTags) + b.PutInt(len(m.PaidReactors)) + for idx, v := range m.PaidReactors { + if err := v.EncodeBare(b); err != nil { + return fmt.Errorf("unable to encode bare messageReactions#9d558cb: field paid_reactors element with index %d: %w", idx, err) + } + } + b.PutBool(m.CanGetAddedReactions) return nil } // Decode implements bin.Decoder. func (m *MessageReactions) Decode(b *bin.Buffer) error { if m == nil { - return fmt.Errorf("can't decode messageReactions#91986cd8 to nil") + return fmt.Errorf("can't decode messageReactions#9d558cb to nil") } if err := b.ConsumeID(MessageReactionsTypeID); err != nil { - return fmt.Errorf("unable to decode messageReactions#91986cd8: %w", err) + return fmt.Errorf("unable to decode messageReactions#9d558cb: %w", err) } return m.DecodeBare(b) } @@ -146,12 +171,12 @@ func (m *MessageReactions) Decode(b *bin.Buffer) error { // DecodeBare implements bin.BareDecoder. func (m *MessageReactions) DecodeBare(b *bin.Buffer) error { if m == nil { - return fmt.Errorf("can't decode messageReactions#91986cd8 to nil") + return fmt.Errorf("can't decode messageReactions#9d558cb to nil") } { headerLen, err := b.Int() if err != nil { - return fmt.Errorf("unable to decode messageReactions#91986cd8: field reactions: %w", err) + return fmt.Errorf("unable to decode messageReactions#9d558cb: field reactions: %w", err) } if headerLen > 0 { @@ -160,7 +185,7 @@ func (m *MessageReactions) DecodeBare(b *bin.Buffer) error { for idx := 0; idx < headerLen; idx++ { var value MessageReaction if err := value.DecodeBare(b); err != nil { - return fmt.Errorf("unable to decode bare messageReactions#91986cd8: field reactions: %w", err) + return fmt.Errorf("unable to decode bare messageReactions#9d558cb: field reactions: %w", err) } m.Reactions = append(m.Reactions, value) } @@ -168,17 +193,41 @@ func (m *MessageReactions) DecodeBare(b *bin.Buffer) error { { value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode messageReactions#91986cd8: field are_tags: %w", err) + return fmt.Errorf("unable to decode messageReactions#9d558cb: field are_tags: %w", err) } m.AreTags = value } + { + headerLen, err := b.Int() + if err != nil { + return fmt.Errorf("unable to decode messageReactions#9d558cb: field paid_reactors: %w", err) + } + + if headerLen > 0 { + m.PaidReactors = make([]PaidReactor, 0, headerLen%bin.PreallocateLimit) + } + for idx := 0; idx < headerLen; idx++ { + var value PaidReactor + if err := value.DecodeBare(b); err != nil { + return fmt.Errorf("unable to decode bare messageReactions#9d558cb: field paid_reactors: %w", err) + } + m.PaidReactors = append(m.PaidReactors, value) + } + } + { + value, err := b.Bool() + if err != nil { + return fmt.Errorf("unable to decode messageReactions#9d558cb: field can_get_added_reactions: %w", err) + } + m.CanGetAddedReactions = value + } return nil } // EncodeTDLibJSON implements tdjson.TDLibEncoder. func (m *MessageReactions) EncodeTDLibJSON(b tdjson.Encoder) error { if m == nil { - return fmt.Errorf("can't encode messageReactions#91986cd8 as nil") + return fmt.Errorf("can't encode messageReactions#9d558cb as nil") } b.ObjStart() b.PutID("messageReactions") @@ -187,7 +236,7 @@ func (m *MessageReactions) EncodeTDLibJSON(b tdjson.Encoder) error { b.ArrStart() for idx, v := range m.Reactions { if err := v.EncodeTDLibJSON(b); err != nil { - return fmt.Errorf("unable to encode messageReactions#91986cd8: field reactions element with index %d: %w", idx, err) + return fmt.Errorf("unable to encode messageReactions#9d558cb: field reactions element with index %d: %w", idx, err) } b.Comma() } @@ -197,6 +246,20 @@ func (m *MessageReactions) EncodeTDLibJSON(b tdjson.Encoder) error { b.FieldStart("are_tags") b.PutBool(m.AreTags) b.Comma() + b.FieldStart("paid_reactors") + b.ArrStart() + for idx, v := range m.PaidReactors { + if err := v.EncodeTDLibJSON(b); err != nil { + return fmt.Errorf("unable to encode messageReactions#9d558cb: field paid_reactors element with index %d: %w", idx, err) + } + b.Comma() + } + b.StripComma() + b.ArrEnd() + b.Comma() + b.FieldStart("can_get_added_reactions") + b.PutBool(m.CanGetAddedReactions) + b.Comma() b.StripComma() b.ObjEnd() return nil @@ -205,32 +268,49 @@ func (m *MessageReactions) EncodeTDLibJSON(b tdjson.Encoder) error { // DecodeTDLibJSON implements tdjson.TDLibDecoder. func (m *MessageReactions) DecodeTDLibJSON(b tdjson.Decoder) error { if m == nil { - return fmt.Errorf("can't decode messageReactions#91986cd8 to nil") + return fmt.Errorf("can't decode messageReactions#9d558cb to nil") } return b.Obj(func(b tdjson.Decoder, key []byte) error { switch string(key) { case tdjson.TypeField: if err := b.ConsumeID("messageReactions"); err != nil { - return fmt.Errorf("unable to decode messageReactions#91986cd8: %w", err) + return fmt.Errorf("unable to decode messageReactions#9d558cb: %w", err) } case "reactions": if err := b.Arr(func(b tdjson.Decoder) error { var value MessageReaction if err := value.DecodeTDLibJSON(b); err != nil { - return fmt.Errorf("unable to decode messageReactions#91986cd8: field reactions: %w", err) + return fmt.Errorf("unable to decode messageReactions#9d558cb: field reactions: %w", err) } m.Reactions = append(m.Reactions, value) return nil }); err != nil { - return fmt.Errorf("unable to decode messageReactions#91986cd8: field reactions: %w", err) + return fmt.Errorf("unable to decode messageReactions#9d558cb: field reactions: %w", err) } case "are_tags": value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode messageReactions#91986cd8: field are_tags: %w", err) + return fmt.Errorf("unable to decode messageReactions#9d558cb: field are_tags: %w", err) } m.AreTags = value + case "paid_reactors": + if err := b.Arr(func(b tdjson.Decoder) error { + var value PaidReactor + if err := value.DecodeTDLibJSON(b); err != nil { + return fmt.Errorf("unable to decode messageReactions#9d558cb: field paid_reactors: %w", err) + } + m.PaidReactors = append(m.PaidReactors, value) + return nil + }); err != nil { + return fmt.Errorf("unable to decode messageReactions#9d558cb: field paid_reactors: %w", err) + } + case "can_get_added_reactions": + value, err := b.Bool() + if err != nil { + return fmt.Errorf("unable to decode messageReactions#9d558cb: field can_get_added_reactions: %w", err) + } + m.CanGetAddedReactions = value default: return b.Skip() } @@ -253,3 +333,19 @@ func (m *MessageReactions) GetAreTags() (value bool) { } return m.AreTags } + +// GetPaidReactors returns value of PaidReactors field. +func (m *MessageReactions) GetPaidReactors() (value []PaidReactor) { + if m == nil { + return + } + return m.PaidReactors +} + +// GetCanGetAddedReactions returns value of CanGetAddedReactions field. +func (m *MessageReactions) GetCanGetAddedReactions() (value bool) { + if m == nil { + return + } + return m.CanGetAddedReactions +} diff --git a/tdapi/tl_paid_reactor_gen.go b/tdapi/tl_paid_reactor_gen.go new file mode 100644 index 0000000000..899ceac36b --- /dev/null +++ b/tdapi/tl_paid_reactor_gen.go @@ -0,0 +1,341 @@ +// Code generated by gotdgen, DO NOT EDIT. + +package tdapi + +import ( + "context" + "errors" + "fmt" + "sort" + "strings" + + "go.uber.org/multierr" + + "github.com/gotd/td/bin" + "github.com/gotd/td/tdjson" + "github.com/gotd/td/tdp" + "github.com/gotd/td/tgerr" +) + +// No-op definition for keeping imports. +var ( + _ = bin.Buffer{} + _ = context.Background() + _ = fmt.Stringer(nil) + _ = strings.Builder{} + _ = errors.Is + _ = multierr.AppendInto + _ = sort.Ints + _ = tdp.Format + _ = tgerr.Error{} + _ = tdjson.Encoder{} +) + +// PaidReactor represents TL type `paidReactor#9d379008`. +type PaidReactor struct { + // Identifier of the user or chat that added the reactions; may be null for anonymous + // reactors that aren't the current user + SenderID MessageSenderClass + // Number of Telegram Stars added + StarCount int32 + // True, if the reactor is one of the most active reactors; can be false if the reactor + // is the current user + IsTop bool + // True, if the paid reaction was added by the current user + IsMe bool + // True, if the reactor is anonymous + IsAnonymous bool +} + +// PaidReactorTypeID is TL type id of PaidReactor. +const PaidReactorTypeID = 0x9d379008 + +// Ensuring interfaces in compile-time for PaidReactor. +var ( + _ bin.Encoder = &PaidReactor{} + _ bin.Decoder = &PaidReactor{} + _ bin.BareEncoder = &PaidReactor{} + _ bin.BareDecoder = &PaidReactor{} +) + +func (p *PaidReactor) Zero() bool { + if p == nil { + return true + } + if !(p.SenderID == nil) { + return false + } + if !(p.StarCount == 0) { + return false + } + if !(p.IsTop == false) { + return false + } + if !(p.IsMe == false) { + return false + } + if !(p.IsAnonymous == false) { + return false + } + + return true +} + +// String implements fmt.Stringer. +func (p *PaidReactor) String() string { + if p == nil { + return "PaidReactor(nil)" + } + type Alias PaidReactor + return fmt.Sprintf("PaidReactor%+v", Alias(*p)) +} + +// TypeID returns type id in TL schema. +// +// See https://core.telegram.org/mtproto/TL-tl#remarks. +func (*PaidReactor) TypeID() uint32 { + return PaidReactorTypeID +} + +// TypeName returns name of type in TL schema. +func (*PaidReactor) TypeName() string { + return "paidReactor" +} + +// TypeInfo returns info about TL type. +func (p *PaidReactor) TypeInfo() tdp.Type { + typ := tdp.Type{ + Name: "paidReactor", + ID: PaidReactorTypeID, + } + if p == nil { + typ.Null = true + return typ + } + typ.Fields = []tdp.Field{ + { + Name: "SenderID", + SchemaName: "sender_id", + }, + { + Name: "StarCount", + SchemaName: "star_count", + }, + { + Name: "IsTop", + SchemaName: "is_top", + }, + { + Name: "IsMe", + SchemaName: "is_me", + }, + { + Name: "IsAnonymous", + SchemaName: "is_anonymous", + }, + } + return typ +} + +// Encode implements bin.Encoder. +func (p *PaidReactor) Encode(b *bin.Buffer) error { + if p == nil { + return fmt.Errorf("can't encode paidReactor#9d379008 as nil") + } + b.PutID(PaidReactorTypeID) + return p.EncodeBare(b) +} + +// EncodeBare implements bin.BareEncoder. +func (p *PaidReactor) EncodeBare(b *bin.Buffer) error { + if p == nil { + return fmt.Errorf("can't encode paidReactor#9d379008 as nil") + } + if p.SenderID == nil { + return fmt.Errorf("unable to encode paidReactor#9d379008: field sender_id is nil") + } + if err := p.SenderID.Encode(b); err != nil { + return fmt.Errorf("unable to encode paidReactor#9d379008: field sender_id: %w", err) + } + b.PutInt32(p.StarCount) + b.PutBool(p.IsTop) + b.PutBool(p.IsMe) + b.PutBool(p.IsAnonymous) + return nil +} + +// Decode implements bin.Decoder. +func (p *PaidReactor) Decode(b *bin.Buffer) error { + if p == nil { + return fmt.Errorf("can't decode paidReactor#9d379008 to nil") + } + if err := b.ConsumeID(PaidReactorTypeID); err != nil { + return fmt.Errorf("unable to decode paidReactor#9d379008: %w", err) + } + return p.DecodeBare(b) +} + +// DecodeBare implements bin.BareDecoder. +func (p *PaidReactor) DecodeBare(b *bin.Buffer) error { + if p == nil { + return fmt.Errorf("can't decode paidReactor#9d379008 to nil") + } + { + value, err := DecodeMessageSender(b) + if err != nil { + return fmt.Errorf("unable to decode paidReactor#9d379008: field sender_id: %w", err) + } + p.SenderID = value + } + { + value, err := b.Int32() + if err != nil { + return fmt.Errorf("unable to decode paidReactor#9d379008: field star_count: %w", err) + } + p.StarCount = value + } + { + value, err := b.Bool() + if err != nil { + return fmt.Errorf("unable to decode paidReactor#9d379008: field is_top: %w", err) + } + p.IsTop = value + } + { + value, err := b.Bool() + if err != nil { + return fmt.Errorf("unable to decode paidReactor#9d379008: field is_me: %w", err) + } + p.IsMe = value + } + { + value, err := b.Bool() + if err != nil { + return fmt.Errorf("unable to decode paidReactor#9d379008: field is_anonymous: %w", err) + } + p.IsAnonymous = value + } + return nil +} + +// EncodeTDLibJSON implements tdjson.TDLibEncoder. +func (p *PaidReactor) EncodeTDLibJSON(b tdjson.Encoder) error { + if p == nil { + return fmt.Errorf("can't encode paidReactor#9d379008 as nil") + } + b.ObjStart() + b.PutID("paidReactor") + b.Comma() + b.FieldStart("sender_id") + if p.SenderID == nil { + return fmt.Errorf("unable to encode paidReactor#9d379008: field sender_id is nil") + } + if err := p.SenderID.EncodeTDLibJSON(b); err != nil { + return fmt.Errorf("unable to encode paidReactor#9d379008: field sender_id: %w", err) + } + b.Comma() + b.FieldStart("star_count") + b.PutInt32(p.StarCount) + b.Comma() + b.FieldStart("is_top") + b.PutBool(p.IsTop) + b.Comma() + b.FieldStart("is_me") + b.PutBool(p.IsMe) + b.Comma() + b.FieldStart("is_anonymous") + b.PutBool(p.IsAnonymous) + b.Comma() + b.StripComma() + b.ObjEnd() + return nil +} + +// DecodeTDLibJSON implements tdjson.TDLibDecoder. +func (p *PaidReactor) DecodeTDLibJSON(b tdjson.Decoder) error { + if p == nil { + return fmt.Errorf("can't decode paidReactor#9d379008 to nil") + } + + return b.Obj(func(b tdjson.Decoder, key []byte) error { + switch string(key) { + case tdjson.TypeField: + if err := b.ConsumeID("paidReactor"); err != nil { + return fmt.Errorf("unable to decode paidReactor#9d379008: %w", err) + } + case "sender_id": + value, err := DecodeTDLibJSONMessageSender(b) + if err != nil { + return fmt.Errorf("unable to decode paidReactor#9d379008: field sender_id: %w", err) + } + p.SenderID = value + case "star_count": + value, err := b.Int32() + if err != nil { + return fmt.Errorf("unable to decode paidReactor#9d379008: field star_count: %w", err) + } + p.StarCount = value + case "is_top": + value, err := b.Bool() + if err != nil { + return fmt.Errorf("unable to decode paidReactor#9d379008: field is_top: %w", err) + } + p.IsTop = value + case "is_me": + value, err := b.Bool() + if err != nil { + return fmt.Errorf("unable to decode paidReactor#9d379008: field is_me: %w", err) + } + p.IsMe = value + case "is_anonymous": + value, err := b.Bool() + if err != nil { + return fmt.Errorf("unable to decode paidReactor#9d379008: field is_anonymous: %w", err) + } + p.IsAnonymous = value + default: + return b.Skip() + } + return nil + }) +} + +// GetSenderID returns value of SenderID field. +func (p *PaidReactor) GetSenderID() (value MessageSenderClass) { + if p == nil { + return + } + return p.SenderID +} + +// GetStarCount returns value of StarCount field. +func (p *PaidReactor) GetStarCount() (value int32) { + if p == nil { + return + } + return p.StarCount +} + +// GetIsTop returns value of IsTop field. +func (p *PaidReactor) GetIsTop() (value bool) { + if p == nil { + return + } + return p.IsTop +} + +// GetIsMe returns value of IsMe field. +func (p *PaidReactor) GetIsMe() (value bool) { + if p == nil { + return + } + return p.IsMe +} + +// GetIsAnonymous returns value of IsAnonymous field. +func (p *PaidReactor) GetIsAnonymous() (value bool) { + if p == nil { + return + } + return p.IsAnonymous +} diff --git a/tdapi/tl_reaction_type_gen.go b/tdapi/tl_reaction_type_gen.go index 43969daf79..8367bb26fe 100644 --- a/tdapi/tl_reaction_type_gen.go +++ b/tdapi/tl_reaction_type_gen.go @@ -363,6 +363,137 @@ func (r *ReactionTypeCustomEmoji) GetCustomEmojiID() (value int64) { return r.CustomEmojiID } +// ReactionTypePaid represents TL type `reactionTypePaid#1a0152ed`. +type ReactionTypePaid struct { +} + +// ReactionTypePaidTypeID is TL type id of ReactionTypePaid. +const ReactionTypePaidTypeID = 0x1a0152ed + +// construct implements constructor of ReactionTypeClass. +func (r ReactionTypePaid) construct() ReactionTypeClass { return &r } + +// Ensuring interfaces in compile-time for ReactionTypePaid. +var ( + _ bin.Encoder = &ReactionTypePaid{} + _ bin.Decoder = &ReactionTypePaid{} + _ bin.BareEncoder = &ReactionTypePaid{} + _ bin.BareDecoder = &ReactionTypePaid{} + + _ ReactionTypeClass = &ReactionTypePaid{} +) + +func (r *ReactionTypePaid) Zero() bool { + if r == nil { + return true + } + + return true +} + +// String implements fmt.Stringer. +func (r *ReactionTypePaid) String() string { + if r == nil { + return "ReactionTypePaid(nil)" + } + type Alias ReactionTypePaid + return fmt.Sprintf("ReactionTypePaid%+v", Alias(*r)) +} + +// TypeID returns type id in TL schema. +// +// See https://core.telegram.org/mtproto/TL-tl#remarks. +func (*ReactionTypePaid) TypeID() uint32 { + return ReactionTypePaidTypeID +} + +// TypeName returns name of type in TL schema. +func (*ReactionTypePaid) TypeName() string { + return "reactionTypePaid" +} + +// TypeInfo returns info about TL type. +func (r *ReactionTypePaid) TypeInfo() tdp.Type { + typ := tdp.Type{ + Name: "reactionTypePaid", + ID: ReactionTypePaidTypeID, + } + if r == nil { + typ.Null = true + return typ + } + typ.Fields = []tdp.Field{} + return typ +} + +// Encode implements bin.Encoder. +func (r *ReactionTypePaid) Encode(b *bin.Buffer) error { + if r == nil { + return fmt.Errorf("can't encode reactionTypePaid#1a0152ed as nil") + } + b.PutID(ReactionTypePaidTypeID) + return r.EncodeBare(b) +} + +// EncodeBare implements bin.BareEncoder. +func (r *ReactionTypePaid) EncodeBare(b *bin.Buffer) error { + if r == nil { + return fmt.Errorf("can't encode reactionTypePaid#1a0152ed as nil") + } + return nil +} + +// Decode implements bin.Decoder. +func (r *ReactionTypePaid) Decode(b *bin.Buffer) error { + if r == nil { + return fmt.Errorf("can't decode reactionTypePaid#1a0152ed to nil") + } + if err := b.ConsumeID(ReactionTypePaidTypeID); err != nil { + return fmt.Errorf("unable to decode reactionTypePaid#1a0152ed: %w", err) + } + return r.DecodeBare(b) +} + +// DecodeBare implements bin.BareDecoder. +func (r *ReactionTypePaid) DecodeBare(b *bin.Buffer) error { + if r == nil { + return fmt.Errorf("can't decode reactionTypePaid#1a0152ed to nil") + } + return nil +} + +// EncodeTDLibJSON implements tdjson.TDLibEncoder. +func (r *ReactionTypePaid) EncodeTDLibJSON(b tdjson.Encoder) error { + if r == nil { + return fmt.Errorf("can't encode reactionTypePaid#1a0152ed as nil") + } + b.ObjStart() + b.PutID("reactionTypePaid") + b.Comma() + b.StripComma() + b.ObjEnd() + return nil +} + +// DecodeTDLibJSON implements tdjson.TDLibDecoder. +func (r *ReactionTypePaid) DecodeTDLibJSON(b tdjson.Decoder) error { + if r == nil { + return fmt.Errorf("can't decode reactionTypePaid#1a0152ed to nil") + } + + return b.Obj(func(b tdjson.Decoder, key []byte) error { + switch string(key) { + case tdjson.TypeField: + if err := b.ConsumeID("reactionTypePaid"); err != nil { + return fmt.Errorf("unable to decode reactionTypePaid#1a0152ed: %w", err) + } + default: + return b.Skip() + } + return nil + }) +} + // ReactionTypeClassName is schema name of ReactionTypeClass. const ReactionTypeClassName = "ReactionType" @@ -377,6 +508,7 @@ const ReactionTypeClassName = "ReactionType" // switch v := g.(type) { // case *tdapi.ReactionTypeEmoji: // reactionTypeEmoji#8c3e22c8 // case *tdapi.ReactionTypeCustomEmoji: // reactionTypeCustomEmoji#c50b42f3 +// case *tdapi.ReactionTypePaid: // reactionTypePaid#1a0152ed // default: panic(v) // } type ReactionTypeClass interface { @@ -422,6 +554,13 @@ func DecodeReactionType(buf *bin.Buffer) (ReactionTypeClass, error) { return nil, fmt.Errorf("unable to decode ReactionTypeClass: %w", err) } return &v, nil + case ReactionTypePaidTypeID: + // Decoding reactionTypePaid#1a0152ed. + v := ReactionTypePaid{} + if err := v.Decode(buf); err != nil { + return nil, fmt.Errorf("unable to decode ReactionTypeClass: %w", err) + } + return &v, nil default: return nil, fmt.Errorf("unable to decode ReactionTypeClass: %w", bin.NewUnexpectedID(id)) } @@ -448,6 +587,13 @@ func DecodeTDLibJSONReactionType(buf tdjson.Decoder) (ReactionTypeClass, error) return nil, fmt.Errorf("unable to decode ReactionTypeClass: %w", err) } return &v, nil + case "reactionTypePaid": + // Decoding reactionTypePaid#1a0152ed. + v := ReactionTypePaid{} + if err := v.DecodeTDLibJSON(buf); err != nil { + return nil, fmt.Errorf("unable to decode ReactionTypeClass: %w", err) + } + return &v, nil default: return nil, fmt.Errorf("unable to decode ReactionTypeClass: %w", tdjson.NewUnexpectedID(id)) } diff --git a/tdapi/tl_registry_gen.go b/tdapi/tl_registry_gen.go index fb120458b8..6c9e828208 100644 --- a/tdapi/tl_registry_gen.go +++ b/tdapi/tl_registry_gen.go @@ -176,6 +176,9 @@ func TypesMap() map[uint32]string { InputChatPhotoStickerTypeID: "inputChatPhotoSticker#4e6e735d", ChatPermissionsTypeID: "chatPermissions#f8f25a79", ChatAdministratorRightsTypeID: "chatAdministratorRights#5f4f9044", + StarSubscriptionPricingTypeID: "starSubscriptionPricing#96a28856", + StarSubscriptionTypeID: "starSubscription#6caf0ade", + StarSubscriptionsTypeID: "starSubscriptions#f7a7ae44", ProductInfoTypeID: "productInfo#87e47ca4", PremiumPaymentOptionTypeID: "premiumPaymentOption#8c0c5fb2", PremiumStatePaymentOptionTypeID: "premiumStatePaymentOption#7d06b579", @@ -186,13 +189,19 @@ func TypesMap() map[uint32]string { StarPaymentOptionsTypeID: "starPaymentOptions#77c3bbad", StarTransactionDirectionIncomingTypeID: "starTransactionDirectionIncoming#b2cabe46", StarTransactionDirectionOutgoingTypeID: "starTransactionDirectionOutgoing#6e83b5a0", + BotTransactionPurposePaidMediaTypeID: "botTransactionPurposePaidMedia#9593b72f", + BotTransactionPurposeInvoicePaymentTypeID: "botTransactionPurposeInvoicePayment#699860ac", + ChannelTransactionPurposePaidMediaTypeID: "channelTransactionPurposePaidMedia#b00b2258", + ChannelTransactionPurposeJoinTypeID: "channelTransactionPurposeJoin#ed83dd90", + ChannelTransactionPurposeReactionTypeID: "channelTransactionPurposeReaction#2ca05bee", StarTransactionPartnerTelegramTypeID: "starTransactionPartnerTelegram#7a899cc0", StarTransactionPartnerAppStoreTypeID: "starTransactionPartnerAppStore#e34026dc", StarTransactionPartnerGooglePlayTypeID: "starTransactionPartnerGooglePlay#f229f2a0", StarTransactionPartnerFragmentTypeID: "starTransactionPartnerFragment#da1849b5", StarTransactionPartnerTelegramAdsTypeID: "starTransactionPartnerTelegramAds#91f9c6b", - StarTransactionPartnerBotTypeID: "starTransactionPartnerBot#298ce3d9", - StarTransactionPartnerChannelTypeID: "starTransactionPartnerChannel#44b29c29", + StarTransactionPartnerBotTypeID: "starTransactionPartnerBot#4ece3a40", + StarTransactionPartnerBusinessTypeID: "starTransactionPartnerBusiness#7af9fb52", + StarTransactionPartnerChannelTypeID: "starTransactionPartnerChannel#7c04767e", StarTransactionPartnerUserTypeID: "starTransactionPartnerUser#2cf89d66", StarTransactionPartnerUnsupportedTypeID: "starTransactionPartnerUnsupported#c4b20d73", StarTransactionTypeID: "starTransaction#ce1084a8", @@ -211,7 +220,7 @@ func TypesMap() map[uint32]string { EmojiStatusesTypeID: "emojiStatuses#eaeb9bdc", UsernamesTypeID: "usernames#bf343063", UserTypeID: "user#18552c62", - BotInfoTypeID: "botInfo#32ab8617", + BotInfoTypeID: "botInfo#9902b940", UserFullInfoTypeID: "userFullInfo#b61c9c5", UsersTypeID: "users#9d955a12", FoundUsersTypeID: "foundUsers#c531e854", @@ -219,7 +228,7 @@ func TypesMap() map[uint32]string { ChatAdministratorsTypeID: "chatAdministrators#5141ca21", ChatMemberStatusCreatorTypeID: "chatMemberStatusCreator#f6764afe", ChatMemberStatusAdministratorTypeID: "chatMemberStatusAdministrator#fbd3841d", - ChatMemberStatusMemberTypeID: "chatMemberStatusMember#32597455", + ChatMemberStatusMemberTypeID: "chatMemberStatusMember#fe0cec16", ChatMemberStatusRestrictedTypeID: "chatMemberStatusRestricted#630774a6", ChatMemberStatusLeftTypeID: "chatMemberStatusLeft#ffa74425", ChatMemberStatusBannedTypeID: "chatMemberStatusBanned#9d714eb6", @@ -240,7 +249,7 @@ func TypesMap() map[uint32]string { SupergroupMembersFilterBannedTypeID: "supergroupMembersFilterBanned#b7d7610d", SupergroupMembersFilterMentionTypeID: "supergroupMembersFilterMention#3880091c", SupergroupMembersFilterBotsTypeID: "supergroupMembersFilterBots#1d5571a6", - ChatInviteLinkTypeID: "chatInviteLink#f3bb8d04", + ChatInviteLinkTypeID: "chatInviteLink#c6eb6530", ChatInviteLinksTypeID: "chatInviteLinks#9b1eddfa", ChatInviteLinkCountTypeID: "chatInviteLinkCount#c3158796", ChatInviteLinkCountsTypeID: "chatInviteLinkCounts#c953d7f8", @@ -249,14 +258,15 @@ func TypesMap() map[uint32]string { InviteLinkChatTypeBasicGroupTypeID: "inviteLinkChatTypeBasicGroup#4d43c5ee", InviteLinkChatTypeSupergroupTypeID: "inviteLinkChatTypeSupergroup#3de86758", InviteLinkChatTypeChannelTypeID: "inviteLinkChatTypeChannel#3012ef0b", - ChatInviteLinkInfoTypeID: "chatInviteLinkInfo#829e9f23", + ChatInviteLinkSubscriptionInfoTypeID: "chatInviteLinkSubscriptionInfo#38cf7368", + ChatInviteLinkInfoTypeID: "chatInviteLinkInfo#95bf0ec4", ChatJoinRequestTypeID: "chatJoinRequest#3897a68", ChatJoinRequestsTypeID: "chatJoinRequests#b2c5fd31", ChatJoinRequestsInfoTypeID: "chatJoinRequestsInfo#6aff5df5", BasicGroupTypeID: "basicGroup#f464168f", BasicGroupFullInfoTypeID: "basicGroupFullInfo#d62e521e", - SupergroupTypeID: "supergroup#39a14289", - SupergroupFullInfoTypeID: "supergroupFullInfo#32925d5a", + SupergroupTypeID: "supergroup#ca7c2ce", + SupergroupFullInfoTypeID: "supergroupFullInfo#1ea45bb", SecretChatStatePendingTypeID: "secretChatStatePending#9e6c967c", SecretChatStateReadyTypeID: "secretChatStateReady#9ff4b7e9", SecretChatStateClosedTypeID: "secretChatStateClosed#8c1006ed", @@ -280,11 +290,13 @@ func TypesMap() map[uint32]string { ForwardSourceTypeID: "forwardSource#6b02aec9", ReactionTypeEmojiTypeID: "reactionTypeEmoji#8c3e22c8", ReactionTypeCustomEmojiTypeID: "reactionTypeCustomEmoji#c50b42f3", + ReactionTypePaidTypeID: "reactionTypePaid#1a0152ed", + PaidReactorTypeID: "paidReactor#9d379008", MessageForwardInfoTypeID: "messageForwardInfo#cb877b7d", MessageImportInfoTypeID: "messageImportInfo#e6dfabcf", MessageReplyInfoTypeID: "messageReplyInfo#69240cb9", MessageReactionTypeID: "messageReaction#7d9e9864", - MessageReactionsTypeID: "messageReactions#91986cd8", + MessageReactionsTypeID: "messageReactions#9d558cb", MessageInteractionInfoTypeID: "messageInteractionInfo#2bbcde05", UnreadReactionTypeID: "unreadReaction#8c5b3b82", MessageEffectTypeEmojiReactionTypeID: "messageEffectTypeEmojiReaction#68aba63e", @@ -300,7 +312,7 @@ func TypesMap() map[uint32]string { InputMessageReplyToExternalMessageTypeID: "inputMessageReplyToExternalMessage#892d232a", InputMessageReplyToStoryTypeID: "inputMessageReplyToStory#51aece78", FactCheckTypeID: "factCheck#c185f918", - MessageTypeID: "message#dc764ddc", + MessageTypeID: "message#a9c04bbc", MessagesTypeID: "messages#b34c8c60", FoundMessagesTypeID: "foundMessages#2515f708", FoundChatMessagesTypeID: "foundChatMessages#4a25270c", @@ -488,7 +500,7 @@ func TypesMap() map[uint32]string { LinkPreviewTypeAppTypeID: "linkPreviewTypeApp#b5192746", LinkPreviewTypeArticleTypeID: "linkPreviewTypeArticle#965e4e27", LinkPreviewTypeAudioTypeID: "linkPreviewTypeAudio#572c6b78", - LinkPreviewTypeBackgroundTypeID: "linkPreviewTypeBackground#6dc50386", + LinkPreviewTypeBackgroundTypeID: "linkPreviewTypeBackground#3a48a1e0", LinkPreviewTypeChannelBoostTypeID: "linkPreviewTypeChannelBoost#c6f40456", LinkPreviewTypeChatTypeID: "linkPreviewTypeChat#ae2fa122", LinkPreviewTypeDocumentTypeID: "linkPreviewTypeDocument#53b02747", @@ -749,7 +761,7 @@ func TypesMap() map[uint32]string { InputMessagePollTypeID: "inputMessagePoll#9046c716", InputMessageStoryTypeID: "inputMessageStory#21099d63", InputMessageForwardedTypeID: "inputMessageForwarded#651a73f8", - MessagePropertiesTypeID: "messageProperties#5ae4cb28", + MessagePropertiesTypeID: "messageProperties#11deeec2", SearchMessagesFilterEmptyTypeID: "searchMessagesFilterEmpty#cc2e1337", SearchMessagesFilterAnimationTypeID: "searchMessagesFilterAnimation#f6b800c5", SearchMessagesFilterAudioTypeID: "searchMessagesFilterAudio#33b5147b", @@ -1001,6 +1013,7 @@ func TypesMap() map[uint32]string { ChatEventIsAllHistoryAvailableToggledTypeID: "chatEventIsAllHistoryAvailableToggled#a0b03c15", ChatEventHasAggressiveAntiSpamEnabledToggledTypeID: "chatEventHasAggressiveAntiSpamEnabledToggled#f8875702", ChatEventSignMessagesToggledTypeID: "chatEventSignMessagesToggled#b1b9281e", + ChatEventShowMessageSenderToggledTypeID: "chatEventShowMessageSenderToggled#d0a747e3", ChatEventInviteLinkEditedTypeID: "chatEventInviteLinkEdited#e4920d62", ChatEventInviteLinkRevokedTypeID: "chatEventInviteLinkRevoked#a1dbffe3", ChatEventInviteLinkDeletedTypeID: "chatEventInviteLinkDeleted#acda6167", @@ -1109,6 +1122,7 @@ func TypesMap() map[uint32]string { TelegramPaymentPurposePremiumGiveawayTypeID: "telegramPaymentPurposePremiumGiveaway#bfd4a227", TelegramPaymentPurposeStarsTypeID: "telegramPaymentPurposeStars#e273ee52", TelegramPaymentPurposeGiftedStarsTypeID: "telegramPaymentPurposeGiftedStars#91b68a36", + TelegramPaymentPurposeJoinChatTypeID: "telegramPaymentPurposeJoinChat#8ddd6788", DeviceTokenFirebaseCloudMessagingTypeID: "deviceTokenFirebaseCloudMessaging#d0714a07", DeviceTokenApplePushTypeID: "deviceTokenApplePush#17196bc3", DeviceTokenApplePushVoIPTypeID: "deviceTokenApplePushVoIP#2ff045e9", @@ -1294,6 +1308,7 @@ func TypesMap() map[uint32]string { InternalLinkTypeBotStartTypeID: "internalLinkTypeBotStart#3f985fed", InternalLinkTypeBotStartInGroupTypeID: "internalLinkTypeBotStartInGroup#ca0d8cce", InternalLinkTypeBusinessChatTypeID: "internalLinkTypeBusinessChat#a03ae9d7", + InternalLinkTypeBuyStarsTypeID: "internalLinkTypeBuyStars#a94cc347", InternalLinkTypeChangePhoneNumberTypeID: "internalLinkTypeChangePhoneNumber#f0275b01", InternalLinkTypeChatBoostTypeID: "internalLinkTypeChatBoost#d549fd40", InternalLinkTypeChatFolderInviteTypeID: "internalLinkTypeChatFolderInvite#89b2493e", @@ -1411,998 +1426,1007 @@ func TypesMap() map[uint32]string { SuggestedActionGiftPremiumForChristmasTypeID: "suggestedActionGiftPremiumForChristmas#93b3ee6f", SuggestedActionSetBirthdateTypeID: "suggestedActionSetBirthdate#eabd9b02", SuggestedActionExtendPremiumTypeID: "suggestedActionExtendPremium#de405cca", - CountTypeID: "count#4d38f104", - TextTypeID: "text#22765898", - SecondsTypeID: "seconds#3936e58e", - FileDownloadedPrefixSizeTypeID: "fileDownloadedPrefixSize#87e267fb", - DeepLinkInfoTypeID: "deepLinkInfo#6f1ba0fe", - TextParseModeMarkdownTypeID: "textParseModeMarkdown#157648bf", - TextParseModeHTMLTypeID: "textParseModeHTML#62f4c5f3", - ProxyTypeSocks5TypeID: "proxyTypeSocks5#caf342b3", - ProxyTypeHTTPTypeID: "proxyTypeHttp#a3c7c777", - ProxyTypeMtprotoTypeID: "proxyTypeMtproto#8ae31ffd", - ProxyTypeID: "proxy#baf7b73", - ProxiesTypeID: "proxies#5ee27a86", - InputStickerTypeID: "inputSticker#1f1d0998", - DateRangeTypeID: "dateRange#51150c66", - StatisticalValueTypeID: "statisticalValue#626d6a76", - StatisticalGraphDataTypeID: "statisticalGraphData#89732e2c", - StatisticalGraphAsyncTypeID: "statisticalGraphAsync#19fb2b9f", - StatisticalGraphErrorTypeID: "statisticalGraphError#c3fda052", - ChatStatisticsObjectTypeMessageTypeID: "chatStatisticsObjectTypeMessage#6f9f24f6", - ChatStatisticsObjectTypeStoryTypeID: "chatStatisticsObjectTypeStory#15baf9b0", - ChatStatisticsInteractionInfoTypeID: "chatStatisticsInteractionInfo#694a9a8d", - ChatStatisticsMessageSenderInfoTypeID: "chatStatisticsMessageSenderInfo#690a7e4b", - ChatStatisticsAdministratorActionsInfoTypeID: "chatStatisticsAdministratorActionsInfo#e7c5cd7e", - ChatStatisticsInviterInfoTypeID: "chatStatisticsInviterInfo#2583d48b", - ChatStatisticsSupergroupTypeID: "chatStatisticsSupergroup#c67549ef", - ChatStatisticsChannelTypeID: "chatStatisticsChannel#b8e95b4", - ChatRevenueAmountTypeID: "chatRevenueAmount#4f3bb29f", - ChatRevenueStatisticsTypeID: "chatRevenueStatistics#636318bb", - MessageStatisticsTypeID: "messageStatistics#a2ce4f07", - StoryStatisticsTypeID: "storyStatistics#46448b6b", - RevenueWithdrawalStatePendingTypeID: "revenueWithdrawalStatePending#5d314fa5", - RevenueWithdrawalStateSucceededTypeID: "revenueWithdrawalStateSucceeded#fd14e0a", - RevenueWithdrawalStateFailedTypeID: "revenueWithdrawalStateFailed#ff413089", - ChatRevenueTransactionTypeEarningsTypeID: "chatRevenueTransactionTypeEarnings#e81ca488", - ChatRevenueTransactionTypeWithdrawalTypeID: "chatRevenueTransactionTypeWithdrawal#f138deb", - ChatRevenueTransactionTypeRefundTypeID: "chatRevenueTransactionTypeRefund#1206b847", - ChatRevenueTransactionTypeID: "chatRevenueTransaction#4c7a4ff", - ChatRevenueTransactionsTypeID: "chatRevenueTransactions#95e61144", - StarRevenueStatusTypeID: "starRevenueStatus#e85bd5fb", - StarRevenueStatisticsTypeID: "starRevenueStatistics#bd2d9257", - PointTypeID: "point#1a13f5b9", - VectorPathCommandLineTypeID: "vectorPathCommandLine#db663c8a", - VectorPathCommandCubicBezierCurveTypeID: "vectorPathCommandCubicBezierCurve#494c3e3a", - BotCommandScopeDefaultTypeID: "botCommandScopeDefault#2f6cb2ab", - BotCommandScopeAllPrivateChatsTypeID: "botCommandScopeAllPrivateChats#eb716739", - BotCommandScopeAllGroupChatsTypeID: "botCommandScopeAllGroupChats#c585c85e", - BotCommandScopeAllChatAdministratorsTypeID: "botCommandScopeAllChatAdministrators#771c1551", - BotCommandScopeChatTypeID: "botCommandScopeChat#e65b22a5", - BotCommandScopeChatAdministratorsTypeID: "botCommandScopeChatAdministrators#42bcfe4e", - BotCommandScopeChatMemberTypeID: "botCommandScopeChatMember#f36696f2", - PhoneNumberCodeTypeChangeTypeID: "phoneNumberCodeTypeChange#531ba1a", - PhoneNumberCodeTypeVerifyTypeID: "phoneNumberCodeTypeVerify#c2a48fdb", - PhoneNumberCodeTypeConfirmOwnershipTypeID: "phoneNumberCodeTypeConfirmOwnership#e3114fe8", - UpdateAuthorizationStateTypeID: "updateAuthorizationState#60b30ee2", - UpdateNewMessageTypeID: "updateNewMessage#de6fb20e", - UpdateMessageSendAcknowledgedTypeID: "updateMessageSendAcknowledged#4da7d239", - UpdateMessageSendSucceededTypeID: "updateMessageSendSucceeded#6c399d7d", - UpdateMessageSendFailedTypeID: "updateMessageSendFailed#da1bf8e7", - UpdateMessageContentTypeID: "updateMessageContent#1e36bb24", - UpdateMessageEditedTypeID: "updateMessageEdited#dea602e6", - UpdateMessageIsPinnedTypeID: "updateMessageIsPinned#41bc233d", - UpdateMessageInteractionInfoTypeID: "updateMessageInteractionInfo#ab803bfe", - UpdateMessageContentOpenedTypeID: "updateMessageContentOpened#a55ea885", - UpdateMessageMentionReadTypeID: "updateMessageMentionRead#f0f74d46", - UpdateMessageUnreadReactionsTypeID: "updateMessageUnreadReactions#12a7220a", - UpdateMessageFactCheckTypeID: "updateMessageFactCheck#3c78fb02", - UpdateMessageLiveLocationViewedTypeID: "updateMessageLiveLocationViewed#b2058595", - UpdateNewChatTypeID: "updateNewChat#7bb98ccd", - UpdateChatTitleTypeID: "updateChatTitle#f58b85a4", - UpdateChatPhotoTypeID: "updateChatPhoto#eca5423f", - UpdateChatAccentColorsTypeID: "updateChatAccentColors#b7b8f8f9", - UpdateChatPermissionsTypeID: "updateChatPermissions#9f52176d", - UpdateChatLastMessageTypeID: "updateChatLastMessage#f10cab1d", - UpdateChatPositionTypeID: "updateChatPosition#ff76fa77", - UpdateChatAddedToListTypeID: "updateChatAddedToList#ab7004ec", - UpdateChatRemovedFromListTypeID: "updateChatRemovedFromList#4d2ac21c", - UpdateChatReadInboxTypeID: "updateChatReadInbox#d07036e7", - UpdateChatReadOutboxTypeID: "updateChatReadOutbox#2a385285", - UpdateChatActionBarTypeID: "updateChatActionBar#d9a258c2", - UpdateChatBusinessBotManageBarTypeID: "updateChatBusinessBotManageBar#be30e7f7", - UpdateChatAvailableReactionsTypeID: "updateChatAvailableReactions#8ab413f9", - UpdateChatDraftMessageTypeID: "updateChatDraftMessage#2bf257d4", - UpdateChatEmojiStatusTypeID: "updateChatEmojiStatus#77796510", - UpdateChatMessageSenderTypeID: "updateChatMessageSender#77705241", - UpdateChatMessageAutoDeleteTimeTypeID: "updateChatMessageAutoDeleteTime#71425de5", - UpdateChatNotificationSettingsTypeID: "updateChatNotificationSettings#d020b456", - UpdateChatPendingJoinRequestsTypeID: "updateChatPendingJoinRequests#14c6e3e1", - UpdateChatReplyMarkupTypeID: "updateChatReplyMarkup#4e0ba5a0", - UpdateChatBackgroundTypeID: "updateChatBackground#ff9d38b3", - UpdateChatThemeTypeID: "updateChatTheme#31f3d465", - UpdateChatUnreadMentionCountTypeID: "updateChatUnreadMentionCount#80f47b1c", - UpdateChatUnreadReactionCountTypeID: "updateChatUnreadReactionCount#81603cdd", - UpdateChatVideoChatTypeID: "updateChatVideoChat#25fb4ca6", - UpdateChatDefaultDisableNotificationTypeID: "updateChatDefaultDisableNotification#1ba96a9b", - UpdateChatHasProtectedContentTypeID: "updateChatHasProtectedContent#6b50071b", - UpdateChatIsTranslatableTypeID: "updateChatIsTranslatable#7b031617", - UpdateChatIsMarkedAsUnreadTypeID: "updateChatIsMarkedAsUnread#57853334", - UpdateChatViewAsTopicsTypeID: "updateChatViewAsTopics#5bff163d", - UpdateChatBlockListTypeID: "updateChatBlockList#872af48e", - UpdateChatHasScheduledMessagesTypeID: "updateChatHasScheduledMessages#7b14c2d7", - UpdateChatFoldersTypeID: "updateChatFolders#e110242a", - UpdateChatOnlineMemberCountTypeID: "updateChatOnlineMemberCount#1d0caa9d", - UpdateSavedMessagesTopicTypeID: "updateSavedMessagesTopic#9f823b30", - UpdateSavedMessagesTopicCountTypeID: "updateSavedMessagesTopicCount#fbd279d1", - UpdateQuickReplyShortcutTypeID: "updateQuickReplyShortcut#c69338cf", - UpdateQuickReplyShortcutDeletedTypeID: "updateQuickReplyShortcutDeleted#e8b9bc3a", - UpdateQuickReplyShortcutsTypeID: "updateQuickReplyShortcuts#77d31a6a", - UpdateQuickReplyShortcutMessagesTypeID: "updateQuickReplyShortcutMessages#8bb36b72", - UpdateForumTopicInfoTypeID: "updateForumTopicInfo#6b6f2cc9", - UpdateScopeNotificationSettingsTypeID: "updateScopeNotificationSettings#b83ccb73", - UpdateReactionNotificationSettingsTypeID: "updateReactionNotificationSettings#e54d17ec", - UpdateNotificationTypeID: "updateNotification#8ee67ed4", - UpdateNotificationGroupTypeID: "updateNotificationGroup#96cd9e06", - UpdateActiveNotificationsTypeID: "updateActiveNotifications#317d80f2", - UpdateHavePendingNotificationsTypeID: "updateHavePendingNotifications#aaee1db", - UpdateDeleteMessagesTypeID: "updateDeleteMessages#6a05bf9", - UpdateChatActionTypeID: "updateChatAction#9abfd628", - UpdateUserStatusTypeID: "updateUserStatus#39211211", - UpdateUserTypeID: "updateUser#468928f9", - UpdateBasicGroupTypeID: "updateBasicGroup#c433c763", - UpdateSupergroupTypeID: "updateSupergroup#fb6c6524", - UpdateSecretChatTypeID: "updateSecretChat#9ca5132b", - UpdateUserFullInfoTypeID: "updateUserFullInfo#fcf2cb17", - UpdateBasicGroupFullInfoTypeID: "updateBasicGroupFullInfo#52f66bbf", - UpdateSupergroupFullInfoTypeID: "updateSupergroupFullInfo#19f5cd0e", - UpdateServiceNotificationTypeID: "updateServiceNotification#4e9895ad", - UpdateFileTypeID: "updateFile#6cd875f", - UpdateFileGenerationStartTypeID: "updateFileGenerationStart#cec5eec", - UpdateFileGenerationStopTypeID: "updateFileGenerationStop#8f14fdeb", - UpdateFileDownloadsTypeID: "updateFileDownloads#e8cd12c7", - UpdateFileAddedToDownloadsTypeID: "updateFileAddedToDownloads#5ff5921a", - UpdateFileDownloadTypeID: "updateFileDownload#342f83ca", - UpdateFileRemovedFromDownloadsTypeID: "updateFileRemovedFromDownloads#6e7c14e8", - UpdateApplicationVerificationRequiredTypeID: "updateApplicationVerificationRequired#c59c61d7", - UpdateCallTypeID: "updateCall#4fb3d0dd", - UpdateGroupCallTypeID: "updateGroupCall#30324e00", - UpdateGroupCallParticipantTypeID: "updateGroupCallParticipant#d0213cf9", - UpdateNewCallSignalingDataTypeID: "updateNewCallSignalingData#22c98d8d", - UpdateUserPrivacySettingRulesTypeID: "updateUserPrivacySettingRules#c99552f6", - UpdateUnreadMessageCountTypeID: "updateUnreadMessageCount#4b541c9", - UpdateUnreadChatCountTypeID: "updateUnreadChatCount#76e19242", - UpdateStoryTypeID: "updateStory#1906572f", - UpdateStoryDeletedTypeID: "updateStoryDeleted#7007eb9d", - UpdateStorySendSucceededTypeID: "updateStorySendSucceeded#b9269e57", - UpdateStorySendFailedTypeID: "updateStorySendFailed#e046f199", - UpdateChatActiveStoriesTypeID: "updateChatActiveStories#79786c2c", - UpdateStoryListChatCountTypeID: "updateStoryListChatCount#8833cd3f", - UpdateStoryStealthModeTypeID: "updateStoryStealthMode#6ff7bd1a", - UpdateOptionTypeID: "updateOption#35b17404", - UpdateStickerSetTypeID: "updateStickerSet#70035dcc", - UpdateInstalledStickerSetsTypeID: "updateInstalledStickerSets#82cd5388", - UpdateTrendingStickerSetsTypeID: "updateTrendingStickerSets#4b7a50a7", - UpdateRecentStickersTypeID: "updateRecentStickers#aefdf8dc", - UpdateFavoriteStickersTypeID: "updateFavoriteStickers#113f2b6a", - UpdateSavedAnimationsTypeID: "updateSavedAnimations#1084a1c8", - UpdateSavedNotificationSoundsTypeID: "updateSavedNotificationSounds#5a6653b4", - UpdateDefaultBackgroundTypeID: "updateDefaultBackground#d550952f", - UpdateChatThemesTypeID: "updateChatThemes#98dc58d5", - UpdateAccentColorsTypeID: "updateAccentColors#1316555e", - UpdateProfileAccentColorsTypeID: "updateProfileAccentColors#bf8e7430", - UpdateLanguagePackStringsTypeID: "updateLanguagePackStrings#af87919f", - UpdateConnectionStateTypeID: "updateConnectionState#57939e2e", - UpdateTermsOfServiceTypeID: "updateTermsOfService#b23cc55e", - UpdateUsersNearbyTypeID: "updateUsersNearby#97c8ab5", - UpdateUnconfirmedSessionTypeID: "updateUnconfirmedSession#fea6088c", - UpdateAttachmentMenuBotsTypeID: "updateAttachmentMenuBots#b6b910c", - UpdateWebAppMessageSentTypeID: "updateWebAppMessageSent#58431229", - UpdateActiveEmojiReactionsTypeID: "updateActiveEmojiReactions#691ffcb7", - UpdateAvailableMessageEffectsTypeID: "updateAvailableMessageEffects#a1cb72b9", - UpdateDefaultReactionTypeTypeID: "updateDefaultReactionType#4b615105", - UpdateSavedMessagesTagsTypeID: "updateSavedMessagesTags#7386424a", - UpdateOwnedStarCountTypeID: "updateOwnedStarCount#de995b79", - UpdateChatRevenueAmountTypeID: "updateChatRevenueAmount#c6c9bcc4", - UpdateStarRevenueStatusTypeID: "updateStarRevenueStatus#ef4bfccb", - UpdateSpeechRecognitionTrialTypeID: "updateSpeechRecognitionTrial#ff4efcc1", - UpdateDiceEmojisTypeID: "updateDiceEmojis#9d0f91df", - UpdateAnimatedEmojiMessageClickedTypeID: "updateAnimatedEmojiMessageClicked#a3167405", - UpdateAnimationSearchParametersTypeID: "updateAnimationSearchParameters#6016ef01", - UpdateSuggestedActionsTypeID: "updateSuggestedActions#c2e5cccb", - UpdateSpeedLimitNotificationTypeID: "updateSpeedLimitNotification#c683d868", - UpdateContactCloseBirthdaysTypeID: "updateContactCloseBirthdays#c88b98ce", - UpdateAutosaveSettingsTypeID: "updateAutosaveSettings#da274f0b", - UpdateBusinessConnectionTypeID: "updateBusinessConnection#8632f476", - UpdateNewBusinessMessageTypeID: "updateNewBusinessMessage#86be4644", - UpdateBusinessMessageEditedTypeID: "updateBusinessMessageEdited#81a66d89", - UpdateBusinessMessagesDeletedTypeID: "updateBusinessMessagesDeleted#e036d3ed", - UpdateNewInlineQueryTypeID: "updateNewInlineQuery#7171bf34", - UpdateNewChosenInlineResultTypeID: "updateNewChosenInlineResult#cb4c4f5d", - UpdateNewCallbackQueryTypeID: "updateNewCallbackQuery#8964d05e", - UpdateNewInlineCallbackQueryTypeID: "updateNewInlineCallbackQuery#ecf934ba", - UpdateNewBusinessCallbackQueryTypeID: "updateNewBusinessCallbackQuery#14125364", - UpdateNewShippingQueryTypeID: "updateNewShippingQuery#29584672", - UpdateNewPreCheckoutQueryTypeID: "updateNewPreCheckoutQuery#2a3871c9", - UpdateNewCustomEventTypeID: "updateNewCustomEvent#76dd6a0c", - UpdateNewCustomQueryTypeID: "updateNewCustomQuery#d702f9a6", - UpdatePollTypeID: "updatePoll#966b73ca", - UpdatePollAnswerTypeID: "updatePollAnswer#b67ac547", - UpdateChatMemberTypeID: "updateChatMember#98865bc7", - UpdateNewChatJoinRequestTypeID: "updateNewChatJoinRequest#7e48b843", - UpdateChatBoostTypeID: "updateChatBoost#50727e24", - UpdateMessageReactionTypeID: "updateMessageReaction#f46c854a", - UpdateMessageReactionsTypeID: "updateMessageReactions#bd5618e9", - UpdatesTypeID: "updates#b9829222", - LogStreamDefaultTypeID: "logStreamDefault#52e296bc", - LogStreamFileTypeID: "logStreamFile#5b528de5", - LogStreamEmptyTypeID: "logStreamEmpty#e233f1cc", - LogVerbosityLevelTypeID: "logVerbosityLevel#676443ea", - LogTagsTypeID: "logTags#dc09ced4", - UserSupportInfoTypeID: "userSupportInfo#b50e1c29", - TestIntTypeID: "testInt#ddbd2c09", - TestStringTypeID: "testString#fe56688c", - TestBytesTypeID: "testBytes#a422c4de", - TestVectorIntTypeID: "testVectorInt#df9eb113", - TestVectorIntObjectTypeID: "testVectorIntObject#f152999b", - TestVectorStringTypeID: "testVectorString#5d6f85bc", - TestVectorStringObjectTypeID: "testVectorStringObject#e5ecc0d", - GetAuthorizationStateRequestTypeID: "getAuthorizationState#742dbe3d", - SetTdlibParametersRequestTypeID: "setTdlibParameters#d1c0f62e", - SetAuthenticationPhoneNumberRequestTypeID: "setAuthenticationPhoneNumber#33c0d823", - SetAuthenticationEmailAddressRequestTypeID: "setAuthenticationEmailAddress#69b2c502", - ResendAuthenticationCodeRequestTypeID: "resendAuthenticationCode#a630bbb8", - CheckAuthenticationEmailCodeRequestTypeID: "checkAuthenticationEmailCode#dd42c29f", - CheckAuthenticationCodeRequestTypeID: "checkAuthenticationCode#edfe44aa", - RequestQrCodeAuthenticationRequestTypeID: "requestQrCodeAuthentication#56fe3c4e", - RegisterUserRequestTypeID: "registerUser#c3aa52ec", - ResetAuthenticationEmailAddressRequestTypeID: "resetAuthenticationEmailAddress#e742722c", - CheckAuthenticationPasswordRequestTypeID: "checkAuthenticationPassword#87424ba0", - RequestAuthenticationPasswordRecoveryRequestTypeID: "requestAuthenticationPasswordRecovery#53152ab6", - CheckAuthenticationPasswordRecoveryCodeRequestTypeID: "checkAuthenticationPasswordRecoveryCode#dc0a3be5", - RecoverAuthenticationPasswordRequestTypeID: "recoverAuthenticationPassword#f8311523", - SendAuthenticationFirebaseSMSRequestTypeID: "sendAuthenticationFirebaseSms#15c15e3f", - ReportAuthenticationCodeMissingRequestTypeID: "reportAuthenticationCodeMissing#91efce48", - CheckAuthenticationBotTokenRequestTypeID: "checkAuthenticationBotToken#261b4476", - LogOutRequestTypeID: "logOut#a1b5c41b", - CloseRequestTypeID: "close#b933e17f", - DestroyRequestTypeID: "destroy#28d9534a", - ConfirmQrCodeAuthenticationRequestTypeID: "confirmQrCodeAuthentication#e993a72d", - GetCurrentStateRequestTypeID: "getCurrentState#b8fc6889", - SetDatabaseEncryptionKeyRequestTypeID: "setDatabaseEncryptionKey#b83345b5", - GetPasswordStateRequestTypeID: "getPasswordState#f5957b78", - SetPasswordRequestTypeID: "setPassword#b8db46dd", - SetLoginEmailAddressRequestTypeID: "setLoginEmailAddress#37bb43d4", - ResendLoginEmailAddressCodeRequestTypeID: "resendLoginEmailAddressCode#11765215", - CheckLoginEmailAddressCodeRequestTypeID: "checkLoginEmailAddressCode#a951fc62", - GetRecoveryEmailAddressRequestTypeID: "getRecoveryEmailAddress#a0f1b9fd", - SetRecoveryEmailAddressRequestTypeID: "setRecoveryEmailAddress#89df939f", - CheckRecoveryEmailAddressCodeRequestTypeID: "checkRecoveryEmailAddressCode#88f7981b", - ResendRecoveryEmailAddressCodeRequestTypeID: "resendRecoveryEmailAddressCode#19d66f1c", - CancelRecoveryEmailAddressVerificationRequestTypeID: "cancelRecoveryEmailAddressVerification#a5988e8d", - RequestPasswordRecoveryRequestTypeID: "requestPasswordRecovery#ff2dc552", - CheckPasswordRecoveryCodeRequestTypeID: "checkPasswordRecoveryCode#f4081e18", - RecoverPasswordRequestTypeID: "recoverPassword#a5259973", - ResetPasswordRequestTypeID: "resetPassword#dc9e8c9d", - CancelPasswordResetRequestTypeID: "cancelPasswordReset#38127462", - CreateTemporaryPasswordRequestTypeID: "createTemporaryPassword#9f0d6f86", - GetTemporaryPasswordStateRequestTypeID: "getTemporaryPasswordState#ff3ea892", - GetMeRequestTypeID: "getMe#f495b27f", - GetUserRequestTypeID: "getUser#42999c0b", - GetUserFullInfoRequestTypeID: "getUserFullInfo#d1b29c58", - GetBasicGroupRequestTypeID: "getBasicGroup#9e893654", - GetBasicGroupFullInfoRequestTypeID: "getBasicGroupFullInfo#9365e32b", - GetSupergroupRequestTypeID: "getSupergroup#3afd10e2", - GetSupergroupFullInfoRequestTypeID: "getSupergroupFullInfo#418d4038", - GetSecretChatRequestTypeID: "getSecretChat#26b7e81", - GetChatRequestTypeID: "getChat#6f421440", - GetMessageRequestTypeID: "getMessage#9372c080", - GetMessageLocallyRequestTypeID: "getMessageLocally#dc062b6c", - GetRepliedMessageRequestTypeID: "getRepliedMessage#d9bd19bd", - GetChatPinnedMessageRequestTypeID: "getChatPinnedMessage#15731ab0", - GetCallbackQueryMessageRequestTypeID: "getCallbackQueryMessage#bd209172", - GetMessagesRequestTypeID: "getMessages#d5dd28bf", - GetMessagePropertiesRequestTypeID: "getMessageProperties#2e18e1ab", - GetMessageThreadRequestTypeID: "getMessageThread#7af23e3e", - GetMessageReadDateRequestTypeID: "getMessageReadDate#a7850343", - GetMessageViewersRequestTypeID: "getMessageViewers#a18f1ace", - GetFileRequestTypeID: "getFile#5c9efd4e", - GetRemoteFileRequestTypeID: "getRemoteFile#7f632732", - LoadChatsRequestTypeID: "loadChats#8f9b7d7b", - GetChatsRequestTypeID: "getChats#c604bac2", - SearchPublicChatRequestTypeID: "searchPublicChat#3316d9ad", - SearchPublicChatsRequestTypeID: "searchPublicChats#39d6e7b9", - SearchChatsRequestTypeID: "searchChats#8ff4b9cc", - SearchChatsOnServerRequestTypeID: "searchChatsOnServer#baf42f74", - SearchChatsNearbyRequestTypeID: "searchChatsNearby#f445c81f", - GetRecommendedChatsRequestTypeID: "getRecommendedChats#d9438d71", - GetChatSimilarChatsRequestTypeID: "getChatSimilarChats#bb508f83", - GetChatSimilarChatCountRequestTypeID: "getChatSimilarChatCount#463e968e", - OpenChatSimilarChatRequestTypeID: "openChatSimilarChat#8fa6f413", - GetTopChatsRequestTypeID: "getTopChats#e8d95221", - RemoveTopChatRequestTypeID: "removeTopChat#8e481e55", - SearchRecentlyFoundChatsRequestTypeID: "searchRecentlyFoundChats#62320591", - AddRecentlyFoundChatRequestTypeID: "addRecentlyFoundChat#97e8198d", - RemoveRecentlyFoundChatRequestTypeID: "removeRecentlyFoundChat#2ac1bf1c", - ClearRecentlyFoundChatsRequestTypeID: "clearRecentlyFoundChats#eefa5b32", - GetRecentlyOpenedChatsRequestTypeID: "getRecentlyOpenedChats#8d4fb223", - CheckChatUsernameRequestTypeID: "checkChatUsername#f8e66210", - GetCreatedPublicChatsRequestTypeID: "getCreatedPublicChats#2a5725ef", - CheckCreatedPublicChatsLimitRequestTypeID: "checkCreatedPublicChatsLimit#e5717fa1", - GetSuitableDiscussionChatsRequestTypeID: "getSuitableDiscussionChats#2ec5df6", - GetInactiveSupergroupChatsRequestTypeID: "getInactiveSupergroupChats#d8cbf9b5", - GetSuitablePersonalChatsRequestTypeID: "getSuitablePersonalChats#90849bf5", - LoadSavedMessagesTopicsRequestTypeID: "loadSavedMessagesTopics#1146d6b8", - GetSavedMessagesTopicHistoryRequestTypeID: "getSavedMessagesTopicHistory#77e5da68", - GetSavedMessagesTopicMessageByDateRequestTypeID: "getSavedMessagesTopicMessageByDate#c15e4680", - DeleteSavedMessagesTopicHistoryRequestTypeID: "deleteSavedMessagesTopicHistory#69df3d6a", - DeleteSavedMessagesTopicMessagesByDateRequestTypeID: "deleteSavedMessagesTopicMessagesByDate#160a25", - ToggleSavedMessagesTopicIsPinnedRequestTypeID: "toggleSavedMessagesTopicIsPinned#a15345cc", - SetPinnedSavedMessagesTopicsRequestTypeID: "setPinnedSavedMessagesTopics#475a1110", - GetGroupsInCommonRequestTypeID: "getGroupsInCommon#16bdd36a", - GetChatHistoryRequestTypeID: "getChatHistory#d051927d", - GetMessageThreadHistoryRequestTypeID: "getMessageThreadHistory#9435d428", - DeleteChatHistoryRequestTypeID: "deleteChatHistory#a841d09f", - DeleteChatRequestTypeID: "deleteChat#f5cae05e", - SearchChatMessagesRequestTypeID: "searchChatMessages#dfdeb5c6", - SearchMessagesRequestTypeID: "searchMessages#31f9c3c9", - SearchSecretMessagesRequestTypeID: "searchSecretMessages#cd2a4c9c", - SearchSavedMessagesRequestTypeID: "searchSavedMessages#8a9b9f96", - SearchCallMessagesRequestTypeID: "searchCallMessages#8c3bef1b", - SearchOutgoingDocumentMessagesRequestTypeID: "searchOutgoingDocumentMessages#c023c47e", - SearchPublicMessagesByTagRequestTypeID: "searchPublicMessagesByTag#25976caa", - SearchPublicStoriesByTagRequestTypeID: "searchPublicStoriesByTag#aa501062", - SearchPublicStoriesByLocationRequestTypeID: "searchPublicStoriesByLocation#5f2bd988", - SearchPublicStoriesByVenueRequestTypeID: "searchPublicStoriesByVenue#d71a622a", - GetSearchedForTagsRequestTypeID: "getSearchedForTags#9b1b30cd", - RemoveSearchedForTagRequestTypeID: "removeSearchedForTag#35216bca", - ClearSearchedForTagsRequestTypeID: "clearSearchedForTags#1e84c356", - DeleteAllCallMessagesRequestTypeID: "deleteAllCallMessages#a897d1f3", - SearchChatRecentLocationMessagesRequestTypeID: "searchChatRecentLocationMessages#38a37ee6", - GetActiveLiveLocationMessagesRequestTypeID: "getActiveLiveLocationMessages#ab093691", - GetChatMessageByDateRequestTypeID: "getChatMessageByDate#3f557136", - GetChatSparseMessagePositionsRequestTypeID: "getChatSparseMessagePositions#3b452efd", - GetChatMessageCalendarRequestTypeID: "getChatMessageCalendar#81af2db7", - GetChatMessageCountRequestTypeID: "getChatMessageCount#38f78909", - GetChatMessagePositionRequestTypeID: "getChatMessagePosition#81bfcc7", - GetChatScheduledMessagesRequestTypeID: "getChatScheduledMessages#df3d2ffb", - GetChatSponsoredMessagesRequestTypeID: "getChatSponsoredMessages#50a84098", - ClickChatSponsoredMessageRequestTypeID: "clickChatSponsoredMessage#d9c09feb", - ReportChatSponsoredMessageRequestTypeID: "reportChatSponsoredMessage#cc3e53be", - RemoveNotificationRequestTypeID: "removeNotification#336ab34e", - RemoveNotificationGroupRequestTypeID: "removeNotificationGroup#661a638e", - GetMessageLinkRequestTypeID: "getMessageLink#c556ef7a", - GetMessageEmbeddingCodeRequestTypeID: "getMessageEmbeddingCode#62a4cd09", - GetMessageLinkInfoRequestTypeID: "getMessageLinkInfo#d63eb458", - TranslateTextRequestTypeID: "translateText#252264f2", - TranslateMessageTextRequestTypeID: "translateMessageText#53c51ed2", - RecognizeSpeechRequestTypeID: "recognizeSpeech#67d402b9", - RateSpeechRecognitionRequestTypeID: "rateSpeechRecognition#eedcc3b5", - GetChatAvailableMessageSendersRequestTypeID: "getChatAvailableMessageSenders#450fe92b", - SetChatMessageSenderRequestTypeID: "setChatMessageSender#ab456b7e", - SendMessageRequestTypeID: "sendMessage#e02d01e9", - SendMessageAlbumRequestTypeID: "sendMessageAlbum#74bcdacf", - SendBotStartMessageRequestTypeID: "sendBotStartMessage#aa6a3eee", - SendInlineQueryResultMessageRequestTypeID: "sendInlineQueryResultMessage#467c5478", - ForwardMessagesRequestTypeID: "forwardMessages#34de5b20", - SendQuickReplyShortcutMessagesRequestTypeID: "sendQuickReplyShortcutMessages#dd5169d", - ResendMessagesRequestTypeID: "resendMessages#90e36776", - AddLocalMessageRequestTypeID: "addLocalMessage#f617b7a1", - DeleteMessagesRequestTypeID: "deleteMessages#c3ed9de2", - DeleteChatMessagesBySenderRequestTypeID: "deleteChatMessagesBySender#ba9b2e67", - DeleteChatMessagesByDateRequestTypeID: "deleteChatMessagesByDate#9e44e0bf", - EditMessageTextRequestTypeID: "editMessageText#bb2e1b7", - EditMessageLiveLocationRequestTypeID: "editMessageLiveLocation#8f511394", - EditMessageMediaRequestTypeID: "editMessageMedia#bb4b8713", - EditMessageCaptionRequestTypeID: "editMessageCaption#87977241", - EditMessageReplyMarkupRequestTypeID: "editMessageReplyMarkup#13cbde89", - EditInlineMessageTextRequestTypeID: "editInlineMessageText#cd02c1e5", - EditInlineMessageLiveLocationRequestTypeID: "editInlineMessageLiveLocation#7f37a0ac", - EditInlineMessageMediaRequestTypeID: "editInlineMessageMedia#1676781", - EditInlineMessageCaptionRequestTypeID: "editInlineMessageCaption#540744f8", - EditInlineMessageReplyMarkupRequestTypeID: "editInlineMessageReplyMarkup#fbf906de", - EditMessageSchedulingStateRequestTypeID: "editMessageSchedulingState#ae2a0bc0", - SetMessageFactCheckRequestTypeID: "setMessageFactCheck#ffbe3d08", - SendBusinessMessageRequestTypeID: "sendBusinessMessage#987b403", - SendBusinessMessageAlbumRequestTypeID: "sendBusinessMessageAlbum#70bd4e6f", - EditBusinessMessageTextRequestTypeID: "editBusinessMessageText#bb81119c", - EditBusinessMessageLiveLocationRequestTypeID: "editBusinessMessageLiveLocation#1d80ae1f", - EditBusinessMessageMediaRequestTypeID: "editBusinessMessageMedia#fc614778", - EditBusinessMessageCaptionRequestTypeID: "editBusinessMessageCaption#c02142c3", - EditBusinessMessageReplyMarkupRequestTypeID: "editBusinessMessageReplyMarkup#29d46c17", - StopBusinessPollRequestTypeID: "stopBusinessPoll#bbeb2160", - SetBusinessMessageIsPinnedRequestTypeID: "setBusinessMessageIsPinned#ff14f5f0", - CheckQuickReplyShortcutNameRequestTypeID: "checkQuickReplyShortcutName#7d3dd129", - LoadQuickReplyShortcutsRequestTypeID: "loadQuickReplyShortcuts#c367b29d", - SetQuickReplyShortcutNameRequestTypeID: "setQuickReplyShortcutName#b20f471", - DeleteQuickReplyShortcutRequestTypeID: "deleteQuickReplyShortcut#f1486c16", - ReorderQuickReplyShortcutsRequestTypeID: "reorderQuickReplyShortcuts#b04981c4", - LoadQuickReplyShortcutMessagesRequestTypeID: "loadQuickReplyShortcutMessages#fd40aed4", - DeleteQuickReplyShortcutMessagesRequestTypeID: "deleteQuickReplyShortcutMessages#e859fcbb", - AddQuickReplyShortcutMessageRequestTypeID: "addQuickReplyShortcutMessage#3f188b2a", - AddQuickReplyShortcutInlineQueryResultMessageRequestTypeID: "addQuickReplyShortcutInlineQueryResultMessage#87c02a04", - AddQuickReplyShortcutMessageAlbumRequestTypeID: "addQuickReplyShortcutMessageAlbum#9647a3fd", - ReaddQuickReplyShortcutMessagesRequestTypeID: "readdQuickReplyShortcutMessages#652518f7", - EditQuickReplyMessageRequestTypeID: "editQuickReplyMessage#4cc978e", - GetForumTopicDefaultIconsRequestTypeID: "getForumTopicDefaultIcons#583574dc", - CreateForumTopicRequestTypeID: "createForumTopic#c1fa28e4", - EditForumTopicRequestTypeID: "editForumTopic#a7769060", - GetForumTopicRequestTypeID: "getForumTopic#e59bfe41", - GetForumTopicLinkRequestTypeID: "getForumTopicLink#c97b88cb", - GetForumTopicsRequestTypeID: "getForumTopics#fbab7d5a", - SetForumTopicNotificationSettingsRequestTypeID: "setForumTopicNotificationSettings#1f433467", - ToggleForumTopicIsClosedRequestTypeID: "toggleForumTopicIsClosed#c7648af3", - ToggleGeneralForumTopicIsHiddenRequestTypeID: "toggleGeneralForumTopicIsHidden#5f1d1448", - ToggleForumTopicIsPinnedRequestTypeID: "toggleForumTopicIsPinned#466ceab4", - SetPinnedForumTopicsRequestTypeID: "setPinnedForumTopics#ddf26f21", - DeleteForumTopicRequestTypeID: "deleteForumTopic#6f285cb8", - GetEmojiReactionRequestTypeID: "getEmojiReaction#e53411dc", - GetCustomEmojiReactionAnimationsRequestTypeID: "getCustomEmojiReactionAnimations#49748dd2", - GetMessageAvailableReactionsRequestTypeID: "getMessageAvailableReactions#76db86b2", - ClearRecentReactionsRequestTypeID: "clearRecentReactions#4d61c752", - AddMessageReactionRequestTypeID: "addMessageReaction#549855ed", - RemoveMessageReactionRequestTypeID: "removeMessageReaction#97474d7b", - SetMessageReactionsRequestTypeID: "setMessageReactions#71fa9e8f", - GetMessageAddedReactionsRequestTypeID: "getMessageAddedReactions#7dc6ae52", - SetDefaultReactionTypeRequestTypeID: "setDefaultReactionType#65038a3d", - GetSavedMessagesTagsRequestTypeID: "getSavedMessagesTags#8cd667a9", - SetSavedMessagesTagLabelRequestTypeID: "setSavedMessagesTagLabel#b03acd10", - GetMessageEffectRequestTypeID: "getMessageEffect#9e513d14", - SearchQuoteRequestTypeID: "searchQuote#6864011f", - GetTextEntitiesRequestTypeID: "getTextEntities#eba543fb", - ParseTextEntitiesRequestTypeID: "parseTextEntities#9a1fc29f", - ParseMarkdownRequestTypeID: "parseMarkdown#2d153aef", - GetMarkdownTextRequestTypeID: "getMarkdownText#9ce7228", - GetCountryFlagEmojiRequestTypeID: "getCountryFlagEmoji#3a8629fa", - GetFileMimeTypeRequestTypeID: "getFileMimeType#84631b89", - GetFileExtensionRequestTypeID: "getFileExtension#f9adb934", - CleanFileNameRequestTypeID: "cleanFileName#39b1f7fb", - GetLanguagePackStringRequestTypeID: "getLanguagePackString#8fcde73", - GetJSONValueRequestTypeID: "getJsonValue#92fa5a05", - GetJSONStringRequestTypeID: "getJsonString#278b9421", - GetThemeParametersJSONStringRequestTypeID: "getThemeParametersJsonString#91b905f8", - SetPollAnswerRequestTypeID: "setPollAnswer#5303b916", - GetPollVotersRequestTypeID: "getPollVoters#c45ba9ac", - StopPollRequestTypeID: "stopPoll#62e80aad", - HideSuggestedActionRequestTypeID: "hideSuggestedAction#a2ef2b7f", - HideContactCloseBirthdaysRequestTypeID: "hideContactCloseBirthdays#baad087b", - GetBusinessConnectionRequestTypeID: "getBusinessConnection#81f42420", - GetLoginURLInfoRequestTypeID: "getLoginUrlInfo#ccc99db3", - GetLoginURLRequestTypeID: "getLoginUrl#2f3295d1", - ShareUsersWithBotRequestTypeID: "shareUsersWithBot#58448550", - ShareChatWithBotRequestTypeID: "shareChatWithBot#a6530ae2", - GetInlineQueryResultsRequestTypeID: "getInlineQueryResults#79dcf86c", - AnswerInlineQueryRequestTypeID: "answerInlineQuery#ac7cc5e6", - GetPopularWebAppBotsRequestTypeID: "getPopularWebAppBots#e8d04cb", - SearchWebAppRequestTypeID: "searchWebApp#b5fc8a35", - GetWebAppLinkURLRequestTypeID: "getWebAppLinkUrl#4f0ef3cc", - GetMainWebAppRequestTypeID: "getMainWebApp#be84329a", - GetWebAppURLRequestTypeID: "getWebAppUrl#64c42cbe", - SendWebAppDataRequestTypeID: "sendWebAppData#ab1fce0c", - OpenWebAppRequestTypeID: "openWebApp#b02666b0", - CloseWebAppRequestTypeID: "closeWebApp#68a124c6", - AnswerWebAppQueryRequestTypeID: "answerWebAppQuery#a0b49cf1", - GetCallbackQueryAnswerRequestTypeID: "getCallbackQueryAnswer#6ef7a5f", - AnswerCallbackQueryRequestTypeID: "answerCallbackQuery#bb462e76", - AnswerShippingQueryRequestTypeID: "answerShippingQuery#7a3c2432", - AnswerPreCheckoutQueryRequestTypeID: "answerPreCheckoutQuery#a76163eb", - SetGameScoreRequestTypeID: "setGameScore#7eccedc6", - SetInlineGameScoreRequestTypeID: "setInlineGameScore#c7715d8b", - GetGameHighScoresRequestTypeID: "getGameHighScores#f0459b", - GetInlineGameHighScoresRequestTypeID: "getInlineGameHighScores#e0396baa", - DeleteChatReplyMarkupRequestTypeID: "deleteChatReplyMarkup#5ff9b5b", - SendChatActionRequestTypeID: "sendChatAction#8823f29e", - OpenChatRequestTypeID: "openChat#ecb9be0b", - CloseChatRequestTypeID: "closeChat#25e86e9", - ViewMessagesRequestTypeID: "viewMessages#aa2f0438", - OpenMessageContentRequestTypeID: "openMessageContent#d3f2697b", - ClickAnimatedEmojiMessageRequestTypeID: "clickAnimatedEmojiMessage#bb17662", - GetInternalLinkRequestTypeID: "getInternalLink#3960f1b0", - GetInternalLinkTypeRequestTypeID: "getInternalLinkType#8bdd5709", - GetExternalLinkInfoRequestTypeID: "getExternalLinkInfo#460d7a3f", - GetExternalLinkRequestTypeID: "getExternalLink#5e92f0eb", - ReadAllChatMentionsRequestTypeID: "readAllChatMentions#50eab2b5", - ReadAllMessageThreadMentionsRequestTypeID: "readAllMessageThreadMentions#4edd7555", - ReadAllChatReactionsRequestTypeID: "readAllChatReactions#54c1976d", - ReadAllMessageThreadReactionsRequestTypeID: "readAllMessageThreadReactions#d0bc273e", - CreatePrivateChatRequestTypeID: "createPrivateChat#c7825b09", - CreateBasicGroupChatRequestTypeID: "createBasicGroupChat#758ab4e4", - CreateSupergroupChatRequestTypeID: "createSupergroupChat#46c770eb", - CreateSecretChatRequestTypeID: "createSecretChat#730dd22f", - CreateNewBasicGroupChatRequestTypeID: "createNewBasicGroupChat#8b9517af", - CreateNewSupergroupChatRequestTypeID: "createNewSupergroupChat#2fecf6c6", - CreateNewSecretChatRequestTypeID: "createNewSecretChat#db012265", - UpgradeBasicGroupChatToSupergroupChatRequestTypeID: "upgradeBasicGroupChatToSupergroupChat#11e915ba", - GetChatListsToAddChatRequestTypeID: "getChatListsToAddChat#2709d6a1", - AddChatToListRequestTypeID: "addChatToList#fb334eb5", - GetChatFolderRequestTypeID: "getChatFolder#5882a98", - CreateChatFolderRequestTypeID: "createChatFolder#3c85c500", - EditChatFolderRequestTypeID: "editChatFolder#332fb32", - DeleteChatFolderRequestTypeID: "deleteChatFolder#74260b87", - GetChatFolderChatsToLeaveRequestTypeID: "getChatFolderChatsToLeave#8dc1e6af", - GetChatFolderChatCountRequestTypeID: "getChatFolderChatCount#7dd4cbbe", - ReorderChatFoldersRequestTypeID: "reorderChatFolders#59544c32", - ToggleChatFolderTagsRequestTypeID: "toggleChatFolderTags#834b6c44", - GetRecommendedChatFoldersRequestTypeID: "getRecommendedChatFolders#f7533b87", - GetChatFolderDefaultIconNameRequestTypeID: "getChatFolderDefaultIconName#2cf7a067", - GetChatsForChatFolderInviteLinkRequestTypeID: "getChatsForChatFolderInviteLink#6fac4949", - CreateChatFolderInviteLinkRequestTypeID: "createChatFolderInviteLink#fba5e198", - GetChatFolderInviteLinksRequestTypeID: "getChatFolderInviteLinks#139d5be0", - EditChatFolderInviteLinkRequestTypeID: "editChatFolderInviteLink#5cc415a8", - DeleteChatFolderInviteLinkRequestTypeID: "deleteChatFolderInviteLink#c890717e", - CheckChatFolderInviteLinkRequestTypeID: "checkChatFolderInviteLink#1f25999b", - AddChatFolderByInviteLinkRequestTypeID: "addChatFolderByInviteLink#1ed19dae", - GetChatFolderNewChatsRequestTypeID: "getChatFolderNewChats#7e8d2ccc", - ProcessChatFolderNewChatsRequestTypeID: "processChatFolderNewChats#109f8a8b", - GetArchiveChatListSettingsRequestTypeID: "getArchiveChatListSettings#838d8e60", - SetArchiveChatListSettingsRequestTypeID: "setArchiveChatListSettings#cb454c0a", - SetChatTitleRequestTypeID: "setChatTitle#9cabebf", - SetChatPhotoRequestTypeID: "setChatPhoto#e97b8d03", - SetChatAccentColorRequestTypeID: "setChatAccentColor#349f57ca", - SetChatProfileAccentColorRequestTypeID: "setChatProfileAccentColor#4227ae7a", - SetChatMessageAutoDeleteTimeRequestTypeID: "setChatMessageAutoDeleteTime#a641b4ff", - SetChatEmojiStatusRequestTypeID: "setChatEmojiStatus#55881912", - SetChatPermissionsRequestTypeID: "setChatPermissions#7f7706fe", - SetChatBackgroundRequestTypeID: "setChatBackground#eb4c3fe", - DeleteChatBackgroundRequestTypeID: "deleteChatBackground#1316e678", - SetChatThemeRequestTypeID: "setChatTheme#8f090293", - SetChatDraftMessageRequestTypeID: "setChatDraftMessage#645e1f1a", - SetChatNotificationSettingsRequestTypeID: "setChatNotificationSettings#2e531ffe", - ToggleChatHasProtectedContentRequestTypeID: "toggleChatHasProtectedContent#3a20d94d", - ToggleChatViewAsTopicsRequestTypeID: "toggleChatViewAsTopics#2b2783dc", - ToggleChatIsTranslatableRequestTypeID: "toggleChatIsTranslatable#93f9cbdf", - ToggleChatIsMarkedAsUnreadRequestTypeID: "toggleChatIsMarkedAsUnread#c538dadf", - ToggleChatDefaultDisableNotificationRequestTypeID: "toggleChatDefaultDisableNotification#12c36012", - SetChatAvailableReactionsRequestTypeID: "setChatAvailableReactions#feb3e06", - SetChatClientDataRequestTypeID: "setChatClientData#ceb3273d", - SetChatDescriptionRequestTypeID: "setChatDescription#74a8b45d", - SetChatDiscussionGroupRequestTypeID: "setChatDiscussionGroup#c93c32b8", - SetChatLocationRequestTypeID: "setChatLocation#d2471daa", - SetChatSlowModeDelayRequestTypeID: "setChatSlowModeDelay#dfcae63e", - PinChatMessageRequestTypeID: "pinChatMessage#79475baf", - UnpinChatMessageRequestTypeID: "unpinChatMessage#7b1c3ede", - UnpinAllChatMessagesRequestTypeID: "unpinAllChatMessages#aa4cd4b7", - UnpinAllMessageThreadMessagesRequestTypeID: "unpinAllMessageThreadMessages#b7c69f00", - JoinChatRequestTypeID: "joinChat#137a1aa1", - LeaveChatRequestTypeID: "leaveChat#93377a61", - AddChatMemberRequestTypeID: "addChatMember#66875217", - AddChatMembersRequestTypeID: "addChatMembers#1a3232f", - SetChatMemberStatusRequestTypeID: "setChatMemberStatus#4e0171f", - BanChatMemberRequestTypeID: "banChatMember#cb107d7c", - CanTransferOwnershipRequestTypeID: "canTransferOwnership#25d3440c", - TransferChatOwnershipRequestTypeID: "transferChatOwnership#77a00a13", - GetChatMemberRequestTypeID: "getChatMember#d0c15272", - SearchChatMembersRequestTypeID: "searchChatMembers#e56d46c5", - GetChatAdministratorsRequestTypeID: "getChatAdministrators#5c0eb6bb", - ClearAllDraftMessagesRequestTypeID: "clearAllDraftMessages#fd3c74db", - GetSavedNotificationSoundRequestTypeID: "getSavedNotificationSound#1b647917", - GetSavedNotificationSoundsRequestTypeID: "getSavedNotificationSounds#c0346fa8", - AddSavedNotificationSoundRequestTypeID: "addSavedNotificationSound#3e3984ef", - RemoveSavedNotificationSoundRequestTypeID: "removeSavedNotificationSound#e363474e", - GetChatNotificationSettingsExceptionsRequestTypeID: "getChatNotificationSettingsExceptions#bfe0e11", - GetScopeNotificationSettingsRequestTypeID: "getScopeNotificationSettings#c4a8254f", - SetScopeNotificationSettingsRequestTypeID: "setScopeNotificationSettings#85cfb63a", - SetReactionNotificationSettingsRequestTypeID: "setReactionNotificationSettings#46b2d495", - ResetAllNotificationSettingsRequestTypeID: "resetAllNotificationSettings#f5a0a8f9", - ToggleChatIsPinnedRequestTypeID: "toggleChatIsPinned#a776263e", - SetPinnedChatsRequestTypeID: "setPinnedChats#c6c6edf1", - ReadChatListRequestTypeID: "readChatList#bd6498aa", - GetCurrentWeatherRequestTypeID: "getCurrentWeather#8ada9bc9", - GetStoryRequestTypeID: "getStory#717b1c78", - GetChatsToSendStoriesRequestTypeID: "getChatsToSendStories#22f9e3a4", - CanSendStoryRequestTypeID: "canSendStory#b6e0216b", - SendStoryRequestTypeID: "sendStory#e6ab3302", - EditStoryRequestTypeID: "editStory#5e6a21b1", - EditStoryCoverRequestTypeID: "editStoryCover#ab2a0c4b", - SetStoryPrivacySettingsRequestTypeID: "setStoryPrivacySettings#d8e94332", - ToggleStoryIsPostedToChatPageRequestTypeID: "toggleStoryIsPostedToChatPage#ee0f4aff", - DeleteStoryRequestTypeID: "deleteStory#9f35af16", - GetStoryNotificationSettingsExceptionsRequestTypeID: "getStoryNotificationSettingsExceptions#256a2eb0", - LoadActiveStoriesRequestTypeID: "loadActiveStories#7d8cf738", - SetChatActiveStoriesListRequestTypeID: "setChatActiveStoriesList#e0e35d11", - GetChatActiveStoriesRequestTypeID: "getChatActiveStories#2e4ffbf5", - GetChatPostedToChatPageStoriesRequestTypeID: "getChatPostedToChatPageStories#fd3bc72b", - GetChatArchivedStoriesRequestTypeID: "getChatArchivedStories#af1e9488", - SetChatPinnedStoriesRequestTypeID: "setChatPinnedStories#f5cb679f", - OpenStoryRequestTypeID: "openStory#ceda7c7d", - CloseStoryRequestTypeID: "closeStory#443d0f55", - GetStoryAvailableReactionsRequestTypeID: "getStoryAvailableReactions#23854d3b", - SetStoryReactionRequestTypeID: "setStoryReaction#ac8b4fa7", - GetStoryInteractionsRequestTypeID: "getStoryInteractions#1cd1400d", - GetChatStoryInteractionsRequestTypeID: "getChatStoryInteractions#c5ec7376", - ReportStoryRequestTypeID: "reportStory#9b5f709b", - ActivateStoryStealthModeRequestTypeID: "activateStoryStealthMode#c3db8491", - GetStoryPublicForwardsRequestTypeID: "getStoryPublicForwards#68f7dcbb", - GetChatBoostLevelFeaturesRequestTypeID: "getChatBoostLevelFeatures#45e63e8b", - GetChatBoostFeaturesRequestTypeID: "getChatBoostFeatures#e8c128a0", - GetAvailableChatBoostSlotsRequestTypeID: "getAvailableChatBoostSlots#7307ebd5", - GetChatBoostStatusRequestTypeID: "getChatBoostStatus#cfac8acf", - BoostChatRequestTypeID: "boostChat#890ccd68", - GetChatBoostLinkRequestTypeID: "getChatBoostLink#56f16c85", - GetChatBoostLinkInfoRequestTypeID: "getChatBoostLinkInfo#26fc4b5c", - GetChatBoostsRequestTypeID: "getChatBoosts#ab5eaa38", - GetUserChatBoostsRequestTypeID: "getUserChatBoosts#b90ee799", - GetAttachmentMenuBotRequestTypeID: "getAttachmentMenuBot#3da561fb", - ToggleBotIsAddedToAttachmentMenuRequestTypeID: "toggleBotIsAddedToAttachmentMenu#8e59de9a", - GetThemedEmojiStatusesRequestTypeID: "getThemedEmojiStatuses#6ac5c8c2", - GetRecentEmojiStatusesRequestTypeID: "getRecentEmojiStatuses#ae3a3d29", - GetDefaultEmojiStatusesRequestTypeID: "getDefaultEmojiStatuses#24e45ec3", - ClearRecentEmojiStatusesRequestTypeID: "clearRecentEmojiStatuses#e671cb5e", - GetThemedChatEmojiStatusesRequestTypeID: "getThemedChatEmojiStatuses#fb735cb5", - GetDefaultChatEmojiStatusesRequestTypeID: "getDefaultChatEmojiStatuses#a7aa86e6", - GetDisallowedChatEmojiStatusesRequestTypeID: "getDisallowedChatEmojiStatuses#d2144da0", - DownloadFileRequestTypeID: "downloadFile#3f253234", - GetFileDownloadedPrefixSizeRequestTypeID: "getFileDownloadedPrefixSize#3304bd2d", - CancelDownloadFileRequestTypeID: "cancelDownloadFile#8b8052de", - GetSuggestedFileNameRequestTypeID: "getSuggestedFileName#85d8a486", - PreliminaryUploadFileRequestTypeID: "preliminaryUploadFile#70e7cb99", - CancelPreliminaryUploadFileRequestTypeID: "cancelPreliminaryUploadFile#311446be", - WriteGeneratedFilePartRequestTypeID: "writeGeneratedFilePart#cc89e95", - SetFileGenerationProgressRequestTypeID: "setFileGenerationProgress#6d754b3e", - FinishFileGenerationRequestTypeID: "finishFileGeneration#c11d0c9d", - ReadFilePartRequestTypeID: "readFilePart#360ca70d", - DeleteFileRequestTypeID: "deleteFile#6bbe9b2c", - AddFileToDownloadsRequestTypeID: "addFileToDownloads#33b583b7", - ToggleDownloadIsPausedRequestTypeID: "toggleDownloadIsPaused#c7866715", - ToggleAllDownloadsArePausedRequestTypeID: "toggleAllDownloadsArePaused#4a989002", - RemoveFileFromDownloadsRequestTypeID: "removeFileFromDownloads#5706bfee", - RemoveAllFilesFromDownloadsRequestTypeID: "removeAllFilesFromDownloads#b9487686", - SearchFileDownloadsRequestTypeID: "searchFileDownloads#2a1e0856", - SetApplicationVerificationTokenRequestTypeID: "setApplicationVerificationToken#3744af85", - GetMessageFileTypeRequestTypeID: "getMessageFileType#e2c70fd4", - GetMessageImportConfirmationTextRequestTypeID: "getMessageImportConfirmationText#174881a8", - ImportMessagesRequestTypeID: "importMessages#7e98592b", - ReplacePrimaryChatInviteLinkRequestTypeID: "replacePrimaryChatInviteLink#3f9e7b9d", - CreateChatInviteLinkRequestTypeID: "createChatInviteLink#1126a341", - EditChatInviteLinkRequestTypeID: "editChatInviteLink#4eb23d7c", - GetChatInviteLinkRequestTypeID: "getChatInviteLink#e36a41fd", - GetChatInviteLinkCountsRequestTypeID: "getChatInviteLinkCounts#3510e291", - GetChatInviteLinksRequestTypeID: "getChatInviteLinks#34a55cac", - GetChatInviteLinkMembersRequestTypeID: "getChatInviteLinkMembers#c5b6199a", - RevokeChatInviteLinkRequestTypeID: "revokeChatInviteLink#d1b755a9", - DeleteRevokedChatInviteLinkRequestTypeID: "deleteRevokedChatInviteLink#91270c7f", - DeleteAllRevokedChatInviteLinksRequestTypeID: "deleteAllRevokedChatInviteLinks#424816da", - CheckChatInviteLinkRequestTypeID: "checkChatInviteLink#e261483b", - JoinChatByInviteLinkRequestTypeID: "joinChatByInviteLink#c16aab86", - GetChatJoinRequestsRequestTypeID: "getChatJoinRequests#e8d90ea2", - ProcessChatJoinRequestRequestTypeID: "processChatJoinRequest#3be534a3", - ProcessChatJoinRequestsRequestTypeID: "processChatJoinRequests#3e823dce", - CreateCallRequestTypeID: "createCall#be282e10", - AcceptCallRequestTypeID: "acceptCall#d97562d0", - SendCallSignalingDataRequestTypeID: "sendCallSignalingData#542db19c", - DiscardCallRequestTypeID: "discardCall#95a9a57e", - SendCallRatingRequestTypeID: "sendCallRating#d89b576c", - SendCallDebugInformationRequestTypeID: "sendCallDebugInformation#785b373f", - SendCallLogRequestTypeID: "sendCallLog#3f0a47d1", - GetVideoChatAvailableParticipantsRequestTypeID: "getVideoChatAvailableParticipants#c45da305", - SetVideoChatDefaultParticipantRequestTypeID: "setVideoChatDefaultParticipant#f1a672b3", - CreateVideoChatRequestTypeID: "createVideoChat#7ea4958d", - GetVideoChatRtmpURLRequestTypeID: "getVideoChatRtmpUrl#482b1b1f", - ReplaceVideoChatRtmpURLRequestTypeID: "replaceVideoChatRtmpUrl#214f8fe0", - GetGroupCallRequestTypeID: "getGroupCall#5787668e", - StartScheduledGroupCallRequestTypeID: "startScheduledGroupCall#5a986d16", - ToggleGroupCallEnabledStartNotificationRequestTypeID: "toggleGroupCallEnabledStartNotification#2a30c752", - JoinGroupCallRequestTypeID: "joinGroupCall#c1c947e5", - StartGroupCallScreenSharingRequestTypeID: "startGroupCallScreenSharing#cb4e312d", - ToggleGroupCallScreenSharingIsPausedRequestTypeID: "toggleGroupCallScreenSharingIsPaused#a07b5360", - EndGroupCallScreenSharingRequestTypeID: "endGroupCallScreenSharing#85f41c4c", - SetGroupCallTitleRequestTypeID: "setGroupCallTitle#b6c19dcd", - ToggleGroupCallMuteNewParticipantsRequestTypeID: "toggleGroupCallMuteNewParticipants#10eec1c2", - InviteGroupCallParticipantsRequestTypeID: "inviteGroupCallParticipants#56c030a6", - GetGroupCallInviteLinkRequestTypeID: "getGroupCallInviteLink#2ae14924", - RevokeGroupCallInviteLinkRequestTypeID: "revokeGroupCallInviteLink#1de5a494", - StartGroupCallRecordingRequestTypeID: "startGroupCallRecording#68c5847b", - EndGroupCallRecordingRequestTypeID: "endGroupCallRecording#fb7b6289", - ToggleGroupCallIsMyVideoPausedRequestTypeID: "toggleGroupCallIsMyVideoPaused#e374f199", - ToggleGroupCallIsMyVideoEnabledRequestTypeID: "toggleGroupCallIsMyVideoEnabled#9f2f50fa", - SetGroupCallParticipantIsSpeakingRequestTypeID: "setGroupCallParticipantIsSpeaking#3748a1e5", - ToggleGroupCallParticipantIsMutedRequestTypeID: "toggleGroupCallParticipantIsMuted#b2081407", - SetGroupCallParticipantVolumeLevelRequestTypeID: "setGroupCallParticipantVolumeLevel#97779828", - ToggleGroupCallParticipantIsHandRaisedRequestTypeID: "toggleGroupCallParticipantIsHandRaised#8efb63e1", - LoadGroupCallParticipantsRequestTypeID: "loadGroupCallParticipants#37f3bece", - LeaveGroupCallRequestTypeID: "leaveGroupCall#3a6befa9", - EndGroupCallRequestTypeID: "endGroupCall#22294cb7", - GetGroupCallStreamsRequestTypeID: "getGroupCallStreams#9f7c9164", - GetGroupCallStreamSegmentRequestTypeID: "getGroupCallStreamSegment#8424daa5", - SetMessageSenderBlockListRequestTypeID: "setMessageSenderBlockList#898b5c91", - BlockMessageSenderFromRepliesRequestTypeID: "blockMessageSenderFromReplies#b79df58b", - GetBlockedMessageSendersRequestTypeID: "getBlockedMessageSenders#8ce52f16", - AddContactRequestTypeID: "addContact#6f707140", - ImportContactsRequestTypeID: "importContacts#77bdb718", - GetContactsRequestTypeID: "getContacts#ab7f4470", - SearchContactsRequestTypeID: "searchContacts#95073165", - RemoveContactsRequestTypeID: "removeContacts#b464dfff", - GetImportedContactCountRequestTypeID: "getImportedContactCount#d8e11a26", - ChangeImportedContactsRequestTypeID: "changeImportedContacts#24885905", - ClearImportedContactsRequestTypeID: "clearImportedContacts#33d39142", - SetCloseFriendsRequestTypeID: "setCloseFriends#7ff8f69f", - GetCloseFriendsRequestTypeID: "getCloseFriends#a9d574ce", - SetUserPersonalProfilePhotoRequestTypeID: "setUserPersonalProfilePhoto#1baa28f6", - SuggestUserProfilePhotoRequestTypeID: "suggestUserProfilePhoto#9561f463", - SearchUserByPhoneNumberRequestTypeID: "searchUserByPhoneNumber#eb82adc8", - SharePhoneNumberRequestTypeID: "sharePhoneNumber#4164e055", - GetUserProfilePhotosRequestTypeID: "getUserProfilePhotos#c9defe42", - GetStickersRequestTypeID: "getStickers#45069343", - GetAllStickerEmojisRequestTypeID: "getAllStickerEmojis#11ad2e30", - SearchStickersRequestTypeID: "searchStickers#9a19e90b", - GetGreetingStickersRequestTypeID: "getGreetingStickers#16581d1c", - GetPremiumStickersRequestTypeID: "getPremiumStickers#ef410a50", - GetInstalledStickerSetsRequestTypeID: "getInstalledStickerSets#612ef6f6", - GetArchivedStickerSetsRequestTypeID: "getArchivedStickerSets#3bb8424d", - GetTrendingStickerSetsRequestTypeID: "getTrendingStickerSets#e058455e", - GetAttachedStickerSetsRequestTypeID: "getAttachedStickerSets#4d9d930d", - GetStickerSetRequestTypeID: "getStickerSet#3eb91bc3", - SearchStickerSetRequestTypeID: "searchStickerSet#45049cee", - SearchInstalledStickerSetsRequestTypeID: "searchInstalledStickerSets#7e5e7fa4", - SearchStickerSetsRequestTypeID: "searchStickerSets#faa066c", - ChangeStickerSetRequestTypeID: "changeStickerSet#1ac8a5ed", - ViewTrendingStickerSetsRequestTypeID: "viewTrendingStickerSets#36d6469", - ReorderInstalledStickerSetsRequestTypeID: "reorderInstalledStickerSets#4a830a78", - GetRecentStickersRequestTypeID: "getRecentStickers#dd73aa9f", - AddRecentStickerRequestTypeID: "addRecentSticker#a7e5d89e", - RemoveRecentStickerRequestTypeID: "removeRecentSticker#4a4d440d", - ClearRecentStickersRequestTypeID: "clearRecentStickers#ecda39c4", - GetFavoriteStickersRequestTypeID: "getFavoriteStickers#ebcbcf40", - AddFavoriteStickerRequestTypeID: "addFavoriteSticker#13578cdf", - RemoveFavoriteStickerRequestTypeID: "removeFavoriteSticker#44b88c70", - GetStickerEmojisRequestTypeID: "getStickerEmojis#8f04d547", - SearchEmojisRequestTypeID: "searchEmojis#d513cd61", - GetKeywordEmojisRequestTypeID: "getKeywordEmojis#7af81263", - GetEmojiCategoriesRequestTypeID: "getEmojiCategories#7f86c16e", - GetAnimatedEmojiRequestTypeID: "getAnimatedEmoji#3f844f76", - GetEmojiSuggestionsURLRequestTypeID: "getEmojiSuggestionsUrl#ac4f1b2f", - GetCustomEmojiStickersRequestTypeID: "getCustomEmojiStickers#a5156885", - GetDefaultChatPhotoCustomEmojiStickersRequestTypeID: "getDefaultChatPhotoCustomEmojiStickers#e9917765", - GetDefaultProfilePhotoCustomEmojiStickersRequestTypeID: "getDefaultProfilePhotoCustomEmojiStickers#4c4be2b7", - GetDefaultBackgroundCustomEmojiStickersRequestTypeID: "getDefaultBackgroundCustomEmojiStickers#1cf6680e", - GetSavedAnimationsRequestTypeID: "getSavedAnimations#6b9718", - AddSavedAnimationRequestTypeID: "addSavedAnimation#a44bf860", - RemoveSavedAnimationRequestTypeID: "removeSavedAnimation#e275a919", - GetRecentInlineBotsRequestTypeID: "getRecentInlineBots#55b3723c", - SearchHashtagsRequestTypeID: "searchHashtags#3e34a571", - RemoveRecentHashtagRequestTypeID: "removeRecentHashtag#c393a0a4", - GetLinkPreviewRequestTypeID: "getLinkPreview#c2096321", - GetWebPageInstantViewRequestTypeID: "getWebPageInstantView#8b045689", - SetProfilePhotoRequestTypeID: "setProfilePhoto#85ea05ed", - DeleteProfilePhotoRequestTypeID: "deleteProfilePhoto#4eaa77c1", - SetAccentColorRequestTypeID: "setAccentColor#6389cb39", - SetProfileAccentColorRequestTypeID: "setProfileAccentColor#899bc168", - SetNameRequestTypeID: "setName#66065f10", - SetBioRequestTypeID: "setBio#9f772354", - SetUsernameRequestTypeID: "setUsername#1a385c1e", - ToggleUsernameIsActiveRequestTypeID: "toggleUsernameIsActive#4a276de3", - ReorderActiveUsernamesRequestTypeID: "reorderActiveUsernames#c659414f", - SetBirthdateRequestTypeID: "setBirthdate#4ea9dd98", - SetPersonalChatRequestTypeID: "setPersonalChat#c04babb4", - SetEmojiStatusRequestTypeID: "setEmojiStatus#92f83e5d", - SetLocationRequestTypeID: "setLocation#5993371", - ToggleHasSponsoredMessagesEnabledRequestTypeID: "toggleHasSponsoredMessagesEnabled#75055cec", - SetBusinessLocationRequestTypeID: "setBusinessLocation#eb740715", - SetBusinessOpeningHoursRequestTypeID: "setBusinessOpeningHours#e470a472", - SetBusinessGreetingMessageSettingsRequestTypeID: "setBusinessGreetingMessageSettings#cbf53c3d", - SetBusinessAwayMessageSettingsRequestTypeID: "setBusinessAwayMessageSettings#4974486c", - SetBusinessStartPageRequestTypeID: "setBusinessStartPage#9eed499e", - SendPhoneNumberCodeRequestTypeID: "sendPhoneNumberCode#409e3d10", - SendPhoneNumberFirebaseSMSRequestTypeID: "sendPhoneNumberFirebaseSms#f9c7084", - ReportPhoneNumberCodeMissingRequestTypeID: "reportPhoneNumberCodeMissing#caa4b553", - ResendPhoneNumberCodeRequestTypeID: "resendPhoneNumberCode#6bcea427", - CheckPhoneNumberCodeRequestTypeID: "checkPhoneNumberCode#dc0565a1", - GetBusinessConnectedBotRequestTypeID: "getBusinessConnectedBot#364da7c3", - SetBusinessConnectedBotRequestTypeID: "setBusinessConnectedBot#acf17ef0", - DeleteBusinessConnectedBotRequestTypeID: "deleteBusinessConnectedBot#9e9b7e55", - ToggleBusinessConnectedBotChatIsPausedRequestTypeID: "toggleBusinessConnectedBotChatIsPaused#4f364845", - RemoveBusinessConnectedBotFromChatRequestTypeID: "removeBusinessConnectedBotFromChat#787273f3", - GetBusinessChatLinksRequestTypeID: "getBusinessChatLinks#2a562157", - CreateBusinessChatLinkRequestTypeID: "createBusinessChatLink#91131d40", - EditBusinessChatLinkRequestTypeID: "editBusinessChatLink#5f10f626", - DeleteBusinessChatLinkRequestTypeID: "deleteBusinessChatLink#be526747", - GetBusinessChatLinkInfoRequestTypeID: "getBusinessChatLinkInfo#2f8b7e4a", - GetUserLinkRequestTypeID: "getUserLink#492014e6", - SearchUserByTokenRequestTypeID: "searchUserByToken#d841f436", - SetCommandsRequestTypeID: "setCommands#b0e0217a", - DeleteCommandsRequestTypeID: "deleteCommands#3bc47c2a", - GetCommandsRequestTypeID: "getCommands#58ba8ff7", - SetMenuButtonRequestTypeID: "setMenuButton#b44fc141", - GetMenuButtonRequestTypeID: "getMenuButton#e5eef440", - SetDefaultGroupAdministratorRightsRequestTypeID: "setDefaultGroupAdministratorRights#65577768", - SetDefaultChannelAdministratorRightsRequestTypeID: "setDefaultChannelAdministratorRights#f20d5e19", - CanBotSendMessagesRequestTypeID: "canBotSendMessages#206d948c", - AllowBotToSendMessagesRequestTypeID: "allowBotToSendMessages#69e9c58e", - SendWebAppCustomRequestRequestTypeID: "sendWebAppCustomRequest#36ff5dc8", - GetBotMediaPreviewsRequestTypeID: "getBotMediaPreviews#22665458", - GetBotMediaPreviewInfoRequestTypeID: "getBotMediaPreviewInfo#50f60136", - AddBotMediaPreviewRequestTypeID: "addBotMediaPreview#504b852b", - EditBotMediaPreviewRequestTypeID: "editBotMediaPreview#86955d62", - ReorderBotMediaPreviewsRequestTypeID: "reorderBotMediaPreviews#89ea0cc6", - DeleteBotMediaPreviewsRequestTypeID: "deleteBotMediaPreviews#f7d259db", - SetBotNameRequestTypeID: "setBotName#d295fa71", - GetBotNameRequestTypeID: "getBotName#9a3f722c", - SetBotProfilePhotoRequestTypeID: "setBotProfilePhoto#bd864b66", - ToggleBotUsernameIsActiveRequestTypeID: "toggleBotUsernameIsActive#79639409", - ReorderBotActiveUsernamesRequestTypeID: "reorderBotActiveUsernames#acadc444", - SetBotInfoDescriptionRequestTypeID: "setBotInfoDescription#29571d48", - GetBotInfoDescriptionRequestTypeID: "getBotInfoDescription#d287f835", - SetBotInfoShortDescriptionRequestTypeID: "setBotInfoShortDescription#3a96bae3", - GetBotInfoShortDescriptionRequestTypeID: "getBotInfoShortDescription#4a1c2614", - GetActiveSessionsRequestTypeID: "getActiveSessions#42bd6d3e", - TerminateSessionRequestTypeID: "terminateSession#e7b7c92c", - TerminateAllOtherSessionsRequestTypeID: "terminateAllOtherSessions#6fba6113", - ConfirmSessionRequestTypeID: "confirmSession#d7c9b41f", - ToggleSessionCanAcceptCallsRequestTypeID: "toggleSessionCanAcceptCalls#6c6c2708", - ToggleSessionCanAcceptSecretChatsRequestTypeID: "toggleSessionCanAcceptSecretChats#3ba7a87e", - SetInactiveSessionTTLRequestTypeID: "setInactiveSessionTtl#5d9ca950", - GetConnectedWebsitesRequestTypeID: "getConnectedWebsites#f5d5d352", - DisconnectWebsiteRequestTypeID: "disconnectWebsite#d194f3dd", - DisconnectAllWebsitesRequestTypeID: "disconnectAllWebsites#bf72f203", - SetSupergroupUsernameRequestTypeID: "setSupergroupUsername#503f4b04", - ToggleSupergroupUsernameIsActiveRequestTypeID: "toggleSupergroupUsernameIsActive#a68b6dff", - DisableAllSupergroupUsernamesRequestTypeID: "disableAllSupergroupUsernames#3246f5b0", - ReorderSupergroupActiveUsernamesRequestTypeID: "reorderSupergroupActiveUsernames#663c7f3b", - SetSupergroupStickerSetRequestTypeID: "setSupergroupStickerSet#856ead69", - SetSupergroupCustomEmojiStickerSetRequestTypeID: "setSupergroupCustomEmojiStickerSet#4f3552af", - SetSupergroupUnrestrictBoostCountRequestTypeID: "setSupergroupUnrestrictBoostCount#39ce30a3", - ToggleSupergroupSignMessagesRequestTypeID: "toggleSupergroupSignMessages#44efd524", - ToggleSupergroupJoinToSendMessagesRequestTypeID: "toggleSupergroupJoinToSendMessages#f5268e0e", - ToggleSupergroupJoinByRequestRequestTypeID: "toggleSupergroupJoinByRequest#7ddf9fde", - ToggleSupergroupIsAllHistoryAvailableRequestTypeID: "toggleSupergroupIsAllHistoryAvailable#44d9964e", - ToggleSupergroupCanHaveSponsoredMessagesRequestTypeID: "toggleSupergroupCanHaveSponsoredMessages#be8abb72", - ToggleSupergroupHasHiddenMembersRequestTypeID: "toggleSupergroupHasHiddenMembers#a4559dca", - ToggleSupergroupHasAggressiveAntiSpamEnabledRequestTypeID: "toggleSupergroupHasAggressiveAntiSpamEnabled#683ef70f", - ToggleSupergroupIsForumRequestTypeID: "toggleSupergroupIsForum#966f960a", - ToggleSupergroupIsBroadcastGroupRequestTypeID: "toggleSupergroupIsBroadcastGroup#34b22215", - ReportSupergroupSpamRequestTypeID: "reportSupergroupSpam#383e26f2", - ReportSupergroupAntiSpamFalsePositiveRequestTypeID: "reportSupergroupAntiSpamFalsePositive#e13db048", - GetSupergroupMembersRequestTypeID: "getSupergroupMembers#ddf821c8", - CloseSecretChatRequestTypeID: "closeSecretChat#e3ed044b", - GetChatEventLogRequestTypeID: "getChatEventLog#f47b0a9b", - GetTimeZonesRequestTypeID: "getTimeZones#4fe2e058", - GetPaymentFormRequestTypeID: "getPaymentForm#8d4f76d4", - ValidateOrderInfoRequestTypeID: "validateOrderInfo#b5985fcf", - SendPaymentFormRequestTypeID: "sendPaymentForm#c66e388a", - GetPaymentReceiptRequestTypeID: "getPaymentReceipt#3c6cb956", - GetSavedOrderInfoRequestTypeID: "getSavedOrderInfo#bb559edd", - DeleteSavedOrderInfoRequestTypeID: "deleteSavedOrderInfo#61197474", - DeleteSavedCredentialsRequestTypeID: "deleteSavedCredentials#314056d2", - CreateInvoiceLinkRequestTypeID: "createInvoiceLink#cebe921", - RefundStarPaymentRequestTypeID: "refundStarPayment#9476a055", - GetSupportUserRequestTypeID: "getSupportUser#98acec9c", - GetBackgroundURLRequestTypeID: "getBackgroundUrl#2bbc6fd2", - SearchBackgroundRequestTypeID: "searchBackground#80fb9121", - SetDefaultBackgroundRequestTypeID: "setDefaultBackground#89d1a8a1", - DeleteDefaultBackgroundRequestTypeID: "deleteDefaultBackground#b2a4ed3e", - GetInstalledBackgroundsRequestTypeID: "getInstalledBackgrounds#c154d05f", - RemoveInstalledBackgroundRequestTypeID: "removeInstalledBackground#5041253c", - ResetInstalledBackgroundsRequestTypeID: "resetInstalledBackgrounds#70540157", - GetLocalizationTargetInfoRequestTypeID: "getLocalizationTargetInfo#6e3d1f86", - GetLanguagePackInfoRequestTypeID: "getLanguagePackInfo#7bd8daa8", - GetLanguagePackStringsRequestTypeID: "getLanguagePackStrings#b0b867bb", - SynchronizeLanguagePackRequestTypeID: "synchronizeLanguagePack#84e5e72e", - AddCustomServerLanguagePackRequestTypeID: "addCustomServerLanguagePack#448de3", - SetCustomLanguagePackRequestTypeID: "setCustomLanguagePack#234b0607", - EditCustomLanguagePackInfoRequestTypeID: "editCustomLanguagePackInfo#4eb91099", - SetCustomLanguagePackStringRequestTypeID: "setCustomLanguagePackString#4e762518", - DeleteLanguagePackRequestTypeID: "deleteLanguagePack#824edc3e", - RegisterDeviceRequestTypeID: "registerDevice#ff140196", - ProcessPushNotificationRequestTypeID: "processPushNotification#2ee3c890", - GetPushReceiverIDRequestTypeID: "getPushReceiverId#eeec46b2", - GetRecentlyVisitedTMeURLsRequestTypeID: "getRecentlyVisitedTMeUrls#30161a91", - SetUserPrivacySettingRulesRequestTypeID: "setUserPrivacySettingRules#e3c230fb", - GetUserPrivacySettingRulesRequestTypeID: "getUserPrivacySettingRules#84301671", - SetReadDatePrivacySettingsRequestTypeID: "setReadDatePrivacySettings#1d7086b6", - GetReadDatePrivacySettingsRequestTypeID: "getReadDatePrivacySettings#1ae85bbb", - SetNewChatPrivacySettingsRequestTypeID: "setNewChatPrivacySettings#69bf374f", - GetNewChatPrivacySettingsRequestTypeID: "getNewChatPrivacySettings#b2cb4bb7", - CanSendMessageToUserRequestTypeID: "canSendMessageToUser#5b2a2836", - GetOptionRequestTypeID: "getOption#a2459e7e", - SetOptionRequestTypeID: "setOption#7e0b4ef2", - SetAccountTTLRequestTypeID: "setAccountTtl#29ce58e8", - GetAccountTTLRequestTypeID: "getAccountTtl#e58a8b77", - DeleteAccountRequestTypeID: "deleteAccount#533276c6", - SetDefaultMessageAutoDeleteTimeRequestTypeID: "setDefaultMessageAutoDeleteTime#965cd36c", - GetDefaultMessageAutoDeleteTimeRequestTypeID: "getDefaultMessageAutoDeleteTime#e520759a", - RemoveChatActionBarRequestTypeID: "removeChatActionBar#9d9839fa", - ReportChatRequestTypeID: "reportChat#d92c3a8a", - ReportChatPhotoRequestTypeID: "reportChatPhoto#d9701288", - ReportMessageReactionsRequestTypeID: "reportMessageReactions#36c88827", - GetChatRevenueStatisticsRequestTypeID: "getChatRevenueStatistics#29d79b3c", - GetChatRevenueWithdrawalURLRequestTypeID: "getChatRevenueWithdrawalUrl#1e320720", - GetChatRevenueTransactionsRequestTypeID: "getChatRevenueTransactions#472f0715", - GetStarRevenueStatisticsRequestTypeID: "getStarRevenueStatistics#f07b4517", - GetStarWithdrawalURLRequestTypeID: "getStarWithdrawalUrl#a9d23712", - GetStarAdAccountURLRequestTypeID: "getStarAdAccountUrl#73a9455d", - GetChatStatisticsRequestTypeID: "getChatStatistics#137e8198", - GetMessageStatisticsRequestTypeID: "getMessageStatistics#4bb5a1d8", - GetMessagePublicForwardsRequestTypeID: "getMessagePublicForwards#519da4b4", - GetStoryStatisticsRequestTypeID: "getStoryStatistics#3a964342", - GetStatisticalGraphRequestTypeID: "getStatisticalGraph#419f8d9b", - GetStorageStatisticsRequestTypeID: "getStorageStatistics#cd254b37", - GetStorageStatisticsFastRequestTypeID: "getStorageStatisticsFast#3a86702", - GetDatabaseStatisticsRequestTypeID: "getDatabaseStatistics#8c33d4b9", - OptimizeStorageRequestTypeID: "optimizeStorage#ef73c8c5", - SetNetworkTypeRequestTypeID: "setNetworkType#d62de55e", - GetNetworkStatisticsRequestTypeID: "getNetworkStatistics#c537581e", - AddNetworkStatisticsRequestTypeID: "addNetworkStatistics#4b63b3d9", - ResetNetworkStatisticsRequestTypeID: "resetNetworkStatistics#6222dd86", - GetAutoDownloadSettingsPresetsRequestTypeID: "getAutoDownloadSettingsPresets#996a4737", - SetAutoDownloadSettingsRequestTypeID: "setAutoDownloadSettings#eaeb64f4", - GetAutosaveSettingsRequestTypeID: "getAutosaveSettings#7f53f22a", - SetAutosaveSettingsRequestTypeID: "setAutosaveSettings#6878c0", - ClearAutosaveSettingsExceptionsRequestTypeID: "clearAutosaveSettingsExceptions#57ec63f2", - GetBankCardInfoRequestTypeID: "getBankCardInfo#b1e31db0", - GetPassportElementRequestTypeID: "getPassportElement#8fcce17a", - GetAllPassportElementsRequestTypeID: "getAllPassportElements#86782aeb", - SetPassportElementRequestTypeID: "setPassportElement#7b45d19c", - DeletePassportElementRequestTypeID: "deletePassportElement#9981aa74", - SetPassportElementErrorsRequestTypeID: "setPassportElementErrors#80fa80bf", - GetPreferredCountryLanguageRequestTypeID: "getPreferredCountryLanguage#c862cbd6", - SendEmailAddressVerificationCodeRequestTypeID: "sendEmailAddressVerificationCode#f2ca537d", - ResendEmailAddressVerificationCodeRequestTypeID: "resendEmailAddressVerificationCode#90653024", - CheckEmailAddressVerificationCodeRequestTypeID: "checkEmailAddressVerificationCode#e695db03", - GetPassportAuthorizationFormRequestTypeID: "getPassportAuthorizationForm#61850486", - GetPassportAuthorizationFormAvailableElementsRequestTypeID: "getPassportAuthorizationFormAvailableElements#3fb314fc", - SendPassportAuthorizationFormRequestTypeID: "sendPassportAuthorizationForm#d9c77579", - SetBotUpdatesStatusRequestTypeID: "setBotUpdatesStatus#bb293991", - UploadStickerFileRequestTypeID: "uploadStickerFile#269650c3", - GetSuggestedStickerSetNameRequestTypeID: "getSuggestedStickerSetName#b0120840", - CheckStickerSetNameRequestTypeID: "checkStickerSetName#955808fe", - CreateNewStickerSetRequestTypeID: "createNewStickerSet#87fd8611", - AddStickerToSetRequestTypeID: "addStickerToSet#56dc1e3b", - ReplaceStickerInSetRequestTypeID: "replaceStickerInSet#e7c82e19", - SetStickerSetThumbnailRequestTypeID: "setStickerSetThumbnail#63fe6932", - SetCustomEmojiStickerSetThumbnailRequestTypeID: "setCustomEmojiStickerSetThumbnail#bd12e0ea", - SetStickerSetTitleRequestTypeID: "setStickerSetTitle#64e933a2", - DeleteStickerSetRequestTypeID: "deleteStickerSet#5e0a7bad", - SetStickerPositionInSetRequestTypeID: "setStickerPositionInSet#7bb24721", - RemoveStickerFromSetRequestTypeID: "removeStickerFromSet#61e1eea4", - SetStickerEmojisRequestTypeID: "setStickerEmojis#d9ec0431", - SetStickerKeywordsRequestTypeID: "setStickerKeywords#462481d", - SetStickerMaskPositionRequestTypeID: "setStickerMaskPosition#47a959d0", - GetOwnedStickerSetsRequestTypeID: "getOwnedStickerSets#58fe8120", - GetMapThumbnailFileRequestTypeID: "getMapThumbnailFile#f6e6979a", - GetPremiumLimitRequestTypeID: "getPremiumLimit#4017fcea", - GetPremiumFeaturesRequestTypeID: "getPremiumFeatures#b4dc2649", - GetPremiumStickerExamplesRequestTypeID: "getPremiumStickerExamples#5369cb98", - ViewPremiumFeatureRequestTypeID: "viewPremiumFeature#b8031b2", - ClickPremiumSubscriptionButtonRequestTypeID: "clickPremiumSubscriptionButton#e9fca306", - GetPremiumStateRequestTypeID: "getPremiumState#278e3ae2", - GetPremiumGiftCodePaymentOptionsRequestTypeID: "getPremiumGiftCodePaymentOptions#89523a2c", - CheckPremiumGiftCodeRequestTypeID: "checkPremiumGiftCode#958ad664", - ApplyPremiumGiftCodeRequestTypeID: "applyPremiumGiftCode#afb44c1e", - LaunchPrepaidPremiumGiveawayRequestTypeID: "launchPrepaidPremiumGiveaway#5328fea1", - GetPremiumGiveawayInfoRequestTypeID: "getPremiumGiveawayInfo#6adb7b97", - GetStarPaymentOptionsRequestTypeID: "getStarPaymentOptions#6d930644", - GetStarGiftPaymentOptionsRequestTypeID: "getStarGiftPaymentOptions#e22760e3", - GetStarTransactionsRequestTypeID: "getStarTransactions#eb1e109d", - CanPurchaseFromStoreRequestTypeID: "canPurchaseFromStore#3caa9368", - AssignAppStoreTransactionRequestTypeID: "assignAppStoreTransaction#86f30bb0", - AssignGooglePlayTransactionRequestTypeID: "assignGooglePlayTransaction#8939bca4", - GetBusinessFeaturesRequestTypeID: "getBusinessFeatures#c4906001", - AcceptTermsOfServiceRequestTypeID: "acceptTermsOfService#7efe03e4", - SearchStringsByPrefixRequestTypeID: "searchStringsByPrefix#a8145813", - SendCustomRequestRequestTypeID: "sendCustomRequest#10fd71a1", - AnswerCustomQueryRequestTypeID: "answerCustomQuery#b2e52d3f", - SetAlarmRequestTypeID: "setAlarm#cbef7e15", - GetCountriesRequestTypeID: "getCountries#fce8099e", - GetCountryCodeRequestTypeID: "getCountryCode#5bd398f2", - GetPhoneNumberInfoRequestTypeID: "getPhoneNumberInfo#a0229bf9", - GetPhoneNumberInfoSyncRequestTypeID: "getPhoneNumberInfoSync#209b7d38", - GetCollectibleItemInfoRequestTypeID: "getCollectibleItemInfo#f304ad8a", - GetDeepLinkInfoRequestTypeID: "getDeepLinkInfo#28923f7e", - GetApplicationConfigRequestTypeID: "getApplicationConfig#93550682", - SaveApplicationLogEventRequestTypeID: "saveApplicationLogEvent#cfa6c20e", - GetApplicationDownloadLinkRequestTypeID: "getApplicationDownloadLink#6ad2fc4", - AddProxyRequestTypeID: "addProxy#13c2bcd8", - EditProxyRequestTypeID: "editProxy#a0482853", - EnableProxyRequestTypeID: "enableProxy#59138296", - DisableProxyRequestTypeID: "disableProxy#82d31782", - RemoveProxyRequestTypeID: "removeProxy#519ca307", - GetProxiesRequestTypeID: "getProxies#fa560333", - GetProxyLinkRequestTypeID: "getProxyLink#c125ae78", - PingProxyRequestTypeID: "pingProxy#c59b40b1", - SetLogStreamRequestTypeID: "setLogStream#aeaff791", - GetLogStreamRequestTypeID: "getLogStream#45984b5b", - SetLogVerbosityLevelRequestTypeID: "setLogVerbosityLevel#edea07d2", - GetLogVerbosityLevelRequestTypeID: "getLogVerbosityLevel#23689ae4", - GetLogTagsRequestTypeID: "getLogTags#f0d569da", - SetLogTagVerbosityLevelRequestTypeID: "setLogTagVerbosityLevel#8317d696", - GetLogTagVerbosityLevelRequestTypeID: "getLogTagVerbosityLevel#38af2d83", - AddLogMessageRequestTypeID: "addLogMessage#5f36cfec", - GetUserSupportInfoRequestTypeID: "getUserSupportInfo#74a59305", - SetUserSupportInfoRequestTypeID: "setUserSupportInfo#837c9803", - GetSupportNameRequestTypeID: "getSupportName#4d9e1562", - TestCallEmptyRequestTypeID: "testCallEmpty#da9c4a16", - TestCallStringRequestTypeID: "testCallString#98b74a2f", - TestCallBytesRequestTypeID: "testCallBytes#d4215aa9", - TestCallVectorIntRequestTypeID: "testCallVectorInt#65ed7e72", - TestCallVectorIntObjectRequestTypeID: "testCallVectorIntObject#ca57f472", - TestCallVectorStringRequestTypeID: "testCallVectorString#8e5a6ed8", - TestCallVectorStringObjectRequestTypeID: "testCallVectorStringObject#96cd6de", - TestSquareIntRequestTypeID: "testSquareInt#fc6a6990", - TestNetworkRequestTypeID: "testNetwork#afe4344b", - TestProxyRequestTypeID: "testProxy#b8a1a29e", - TestGetDifferenceRequestTypeID: "testGetDifference#68226325", - TestUseUpdateRequestTypeID: "testUseUpdate#2abdff1e", - TestReturnErrorRequestTypeID: "testReturnError#1b217cf2", + SuggestedActionExtendStarSubscriptionsTypeID: "suggestedActionExtendStarSubscriptions#fd32d556", + CountTypeID: "count#4d38f104", + TextTypeID: "text#22765898", + SecondsTypeID: "seconds#3936e58e", + FileDownloadedPrefixSizeTypeID: "fileDownloadedPrefixSize#87e267fb", + DeepLinkInfoTypeID: "deepLinkInfo#6f1ba0fe", + TextParseModeMarkdownTypeID: "textParseModeMarkdown#157648bf", + TextParseModeHTMLTypeID: "textParseModeHTML#62f4c5f3", + ProxyTypeSocks5TypeID: "proxyTypeSocks5#caf342b3", + ProxyTypeHTTPTypeID: "proxyTypeHttp#a3c7c777", + ProxyTypeMtprotoTypeID: "proxyTypeMtproto#8ae31ffd", + ProxyTypeID: "proxy#baf7b73", + ProxiesTypeID: "proxies#5ee27a86", + InputStickerTypeID: "inputSticker#1f1d0998", + DateRangeTypeID: "dateRange#51150c66", + StatisticalValueTypeID: "statisticalValue#626d6a76", + StatisticalGraphDataTypeID: "statisticalGraphData#89732e2c", + StatisticalGraphAsyncTypeID: "statisticalGraphAsync#19fb2b9f", + StatisticalGraphErrorTypeID: "statisticalGraphError#c3fda052", + ChatStatisticsObjectTypeMessageTypeID: "chatStatisticsObjectTypeMessage#6f9f24f6", + ChatStatisticsObjectTypeStoryTypeID: "chatStatisticsObjectTypeStory#15baf9b0", + ChatStatisticsInteractionInfoTypeID: "chatStatisticsInteractionInfo#694a9a8d", + ChatStatisticsMessageSenderInfoTypeID: "chatStatisticsMessageSenderInfo#690a7e4b", + ChatStatisticsAdministratorActionsInfoTypeID: "chatStatisticsAdministratorActionsInfo#e7c5cd7e", + ChatStatisticsInviterInfoTypeID: "chatStatisticsInviterInfo#2583d48b", + ChatStatisticsSupergroupTypeID: "chatStatisticsSupergroup#c67549ef", + ChatStatisticsChannelTypeID: "chatStatisticsChannel#b8e95b4", + ChatRevenueAmountTypeID: "chatRevenueAmount#4f3bb29f", + ChatRevenueStatisticsTypeID: "chatRevenueStatistics#636318bb", + MessageStatisticsTypeID: "messageStatistics#a2ce4f07", + StoryStatisticsTypeID: "storyStatistics#46448b6b", + RevenueWithdrawalStatePendingTypeID: "revenueWithdrawalStatePending#5d314fa5", + RevenueWithdrawalStateSucceededTypeID: "revenueWithdrawalStateSucceeded#fd14e0a", + RevenueWithdrawalStateFailedTypeID: "revenueWithdrawalStateFailed#ff413089", + ChatRevenueTransactionTypeEarningsTypeID: "chatRevenueTransactionTypeEarnings#e81ca488", + ChatRevenueTransactionTypeWithdrawalTypeID: "chatRevenueTransactionTypeWithdrawal#f138deb", + ChatRevenueTransactionTypeRefundTypeID: "chatRevenueTransactionTypeRefund#1206b847", + ChatRevenueTransactionTypeID: "chatRevenueTransaction#4c7a4ff", + ChatRevenueTransactionsTypeID: "chatRevenueTransactions#95e61144", + StarRevenueStatusTypeID: "starRevenueStatus#e85bd5fb", + StarRevenueStatisticsTypeID: "starRevenueStatistics#bd2d9257", + PointTypeID: "point#1a13f5b9", + VectorPathCommandLineTypeID: "vectorPathCommandLine#db663c8a", + VectorPathCommandCubicBezierCurveTypeID: "vectorPathCommandCubicBezierCurve#494c3e3a", + BotCommandScopeDefaultTypeID: "botCommandScopeDefault#2f6cb2ab", + BotCommandScopeAllPrivateChatsTypeID: "botCommandScopeAllPrivateChats#eb716739", + BotCommandScopeAllGroupChatsTypeID: "botCommandScopeAllGroupChats#c585c85e", + BotCommandScopeAllChatAdministratorsTypeID: "botCommandScopeAllChatAdministrators#771c1551", + BotCommandScopeChatTypeID: "botCommandScopeChat#e65b22a5", + BotCommandScopeChatAdministratorsTypeID: "botCommandScopeChatAdministrators#42bcfe4e", + BotCommandScopeChatMemberTypeID: "botCommandScopeChatMember#f36696f2", + PhoneNumberCodeTypeChangeTypeID: "phoneNumberCodeTypeChange#531ba1a", + PhoneNumberCodeTypeVerifyTypeID: "phoneNumberCodeTypeVerify#c2a48fdb", + PhoneNumberCodeTypeConfirmOwnershipTypeID: "phoneNumberCodeTypeConfirmOwnership#e3114fe8", + UpdateAuthorizationStateTypeID: "updateAuthorizationState#60b30ee2", + UpdateNewMessageTypeID: "updateNewMessage#de6fb20e", + UpdateMessageSendAcknowledgedTypeID: "updateMessageSendAcknowledged#4da7d239", + UpdateMessageSendSucceededTypeID: "updateMessageSendSucceeded#6c399d7d", + UpdateMessageSendFailedTypeID: "updateMessageSendFailed#da1bf8e7", + UpdateMessageContentTypeID: "updateMessageContent#1e36bb24", + UpdateMessageEditedTypeID: "updateMessageEdited#dea602e6", + UpdateMessageIsPinnedTypeID: "updateMessageIsPinned#41bc233d", + UpdateMessageInteractionInfoTypeID: "updateMessageInteractionInfo#ab803bfe", + UpdateMessageContentOpenedTypeID: "updateMessageContentOpened#a55ea885", + UpdateMessageMentionReadTypeID: "updateMessageMentionRead#f0f74d46", + UpdateMessageUnreadReactionsTypeID: "updateMessageUnreadReactions#12a7220a", + UpdateMessageFactCheckTypeID: "updateMessageFactCheck#3c78fb02", + UpdateMessageLiveLocationViewedTypeID: "updateMessageLiveLocationViewed#b2058595", + UpdateNewChatTypeID: "updateNewChat#7bb98ccd", + UpdateChatTitleTypeID: "updateChatTitle#f58b85a4", + UpdateChatPhotoTypeID: "updateChatPhoto#eca5423f", + UpdateChatAccentColorsTypeID: "updateChatAccentColors#b7b8f8f9", + UpdateChatPermissionsTypeID: "updateChatPermissions#9f52176d", + UpdateChatLastMessageTypeID: "updateChatLastMessage#f10cab1d", + UpdateChatPositionTypeID: "updateChatPosition#ff76fa77", + UpdateChatAddedToListTypeID: "updateChatAddedToList#ab7004ec", + UpdateChatRemovedFromListTypeID: "updateChatRemovedFromList#4d2ac21c", + UpdateChatReadInboxTypeID: "updateChatReadInbox#d07036e7", + UpdateChatReadOutboxTypeID: "updateChatReadOutbox#2a385285", + UpdateChatActionBarTypeID: "updateChatActionBar#d9a258c2", + UpdateChatBusinessBotManageBarTypeID: "updateChatBusinessBotManageBar#be30e7f7", + UpdateChatAvailableReactionsTypeID: "updateChatAvailableReactions#8ab413f9", + UpdateChatDraftMessageTypeID: "updateChatDraftMessage#2bf257d4", + UpdateChatEmojiStatusTypeID: "updateChatEmojiStatus#77796510", + UpdateChatMessageSenderTypeID: "updateChatMessageSender#77705241", + UpdateChatMessageAutoDeleteTimeTypeID: "updateChatMessageAutoDeleteTime#71425de5", + UpdateChatNotificationSettingsTypeID: "updateChatNotificationSettings#d020b456", + UpdateChatPendingJoinRequestsTypeID: "updateChatPendingJoinRequests#14c6e3e1", + UpdateChatReplyMarkupTypeID: "updateChatReplyMarkup#4e0ba5a0", + UpdateChatBackgroundTypeID: "updateChatBackground#ff9d38b3", + UpdateChatThemeTypeID: "updateChatTheme#31f3d465", + UpdateChatUnreadMentionCountTypeID: "updateChatUnreadMentionCount#80f47b1c", + UpdateChatUnreadReactionCountTypeID: "updateChatUnreadReactionCount#81603cdd", + UpdateChatVideoChatTypeID: "updateChatVideoChat#25fb4ca6", + UpdateChatDefaultDisableNotificationTypeID: "updateChatDefaultDisableNotification#1ba96a9b", + UpdateChatHasProtectedContentTypeID: "updateChatHasProtectedContent#6b50071b", + UpdateChatIsTranslatableTypeID: "updateChatIsTranslatable#7b031617", + UpdateChatIsMarkedAsUnreadTypeID: "updateChatIsMarkedAsUnread#57853334", + UpdateChatViewAsTopicsTypeID: "updateChatViewAsTopics#5bff163d", + UpdateChatBlockListTypeID: "updateChatBlockList#872af48e", + UpdateChatHasScheduledMessagesTypeID: "updateChatHasScheduledMessages#7b14c2d7", + UpdateChatFoldersTypeID: "updateChatFolders#e110242a", + UpdateChatOnlineMemberCountTypeID: "updateChatOnlineMemberCount#1d0caa9d", + UpdateSavedMessagesTopicTypeID: "updateSavedMessagesTopic#9f823b30", + UpdateSavedMessagesTopicCountTypeID: "updateSavedMessagesTopicCount#fbd279d1", + UpdateQuickReplyShortcutTypeID: "updateQuickReplyShortcut#c69338cf", + UpdateQuickReplyShortcutDeletedTypeID: "updateQuickReplyShortcutDeleted#e8b9bc3a", + UpdateQuickReplyShortcutsTypeID: "updateQuickReplyShortcuts#77d31a6a", + UpdateQuickReplyShortcutMessagesTypeID: "updateQuickReplyShortcutMessages#8bb36b72", + UpdateForumTopicInfoTypeID: "updateForumTopicInfo#6b6f2cc9", + UpdateScopeNotificationSettingsTypeID: "updateScopeNotificationSettings#b83ccb73", + UpdateReactionNotificationSettingsTypeID: "updateReactionNotificationSettings#e54d17ec", + UpdateNotificationTypeID: "updateNotification#8ee67ed4", + UpdateNotificationGroupTypeID: "updateNotificationGroup#96cd9e06", + UpdateActiveNotificationsTypeID: "updateActiveNotifications#317d80f2", + UpdateHavePendingNotificationsTypeID: "updateHavePendingNotifications#aaee1db", + UpdateDeleteMessagesTypeID: "updateDeleteMessages#6a05bf9", + UpdateChatActionTypeID: "updateChatAction#9abfd628", + UpdateUserStatusTypeID: "updateUserStatus#39211211", + UpdateUserTypeID: "updateUser#468928f9", + UpdateBasicGroupTypeID: "updateBasicGroup#c433c763", + UpdateSupergroupTypeID: "updateSupergroup#fb6c6524", + UpdateSecretChatTypeID: "updateSecretChat#9ca5132b", + UpdateUserFullInfoTypeID: "updateUserFullInfo#fcf2cb17", + UpdateBasicGroupFullInfoTypeID: "updateBasicGroupFullInfo#52f66bbf", + UpdateSupergroupFullInfoTypeID: "updateSupergroupFullInfo#19f5cd0e", + UpdateServiceNotificationTypeID: "updateServiceNotification#4e9895ad", + UpdateFileTypeID: "updateFile#6cd875f", + UpdateFileGenerationStartTypeID: "updateFileGenerationStart#cec5eec", + UpdateFileGenerationStopTypeID: "updateFileGenerationStop#8f14fdeb", + UpdateFileDownloadsTypeID: "updateFileDownloads#e8cd12c7", + UpdateFileAddedToDownloadsTypeID: "updateFileAddedToDownloads#5ff5921a", + UpdateFileDownloadTypeID: "updateFileDownload#342f83ca", + UpdateFileRemovedFromDownloadsTypeID: "updateFileRemovedFromDownloads#6e7c14e8", + UpdateApplicationVerificationRequiredTypeID: "updateApplicationVerificationRequired#c59c61d7", + UpdateCallTypeID: "updateCall#4fb3d0dd", + UpdateGroupCallTypeID: "updateGroupCall#30324e00", + UpdateGroupCallParticipantTypeID: "updateGroupCallParticipant#d0213cf9", + UpdateNewCallSignalingDataTypeID: "updateNewCallSignalingData#22c98d8d", + UpdateUserPrivacySettingRulesTypeID: "updateUserPrivacySettingRules#c99552f6", + UpdateUnreadMessageCountTypeID: "updateUnreadMessageCount#4b541c9", + UpdateUnreadChatCountTypeID: "updateUnreadChatCount#76e19242", + UpdateStoryTypeID: "updateStory#1906572f", + UpdateStoryDeletedTypeID: "updateStoryDeleted#7007eb9d", + UpdateStorySendSucceededTypeID: "updateStorySendSucceeded#b9269e57", + UpdateStorySendFailedTypeID: "updateStorySendFailed#e046f199", + UpdateChatActiveStoriesTypeID: "updateChatActiveStories#79786c2c", + UpdateStoryListChatCountTypeID: "updateStoryListChatCount#8833cd3f", + UpdateStoryStealthModeTypeID: "updateStoryStealthMode#6ff7bd1a", + UpdateOptionTypeID: "updateOption#35b17404", + UpdateStickerSetTypeID: "updateStickerSet#70035dcc", + UpdateInstalledStickerSetsTypeID: "updateInstalledStickerSets#82cd5388", + UpdateTrendingStickerSetsTypeID: "updateTrendingStickerSets#4b7a50a7", + UpdateRecentStickersTypeID: "updateRecentStickers#aefdf8dc", + UpdateFavoriteStickersTypeID: "updateFavoriteStickers#113f2b6a", + UpdateSavedAnimationsTypeID: "updateSavedAnimations#1084a1c8", + UpdateSavedNotificationSoundsTypeID: "updateSavedNotificationSounds#5a6653b4", + UpdateDefaultBackgroundTypeID: "updateDefaultBackground#d550952f", + UpdateChatThemesTypeID: "updateChatThemes#98dc58d5", + UpdateAccentColorsTypeID: "updateAccentColors#1316555e", + UpdateProfileAccentColorsTypeID: "updateProfileAccentColors#bf8e7430", + UpdateLanguagePackStringsTypeID: "updateLanguagePackStrings#af87919f", + UpdateConnectionStateTypeID: "updateConnectionState#57939e2e", + UpdateTermsOfServiceTypeID: "updateTermsOfService#b23cc55e", + UpdateUsersNearbyTypeID: "updateUsersNearby#97c8ab5", + UpdateUnconfirmedSessionTypeID: "updateUnconfirmedSession#fea6088c", + UpdateAttachmentMenuBotsTypeID: "updateAttachmentMenuBots#b6b910c", + UpdateWebAppMessageSentTypeID: "updateWebAppMessageSent#58431229", + UpdateActiveEmojiReactionsTypeID: "updateActiveEmojiReactions#691ffcb7", + UpdateAvailableMessageEffectsTypeID: "updateAvailableMessageEffects#a1cb72b9", + UpdateDefaultReactionTypeTypeID: "updateDefaultReactionType#4b615105", + UpdateSavedMessagesTagsTypeID: "updateSavedMessagesTags#7386424a", + UpdateActiveLiveLocationMessagesTypeID: "updateActiveLiveLocationMessages#a20b9b1f", + UpdateOwnedStarCountTypeID: "updateOwnedStarCount#de995b79", + UpdateChatRevenueAmountTypeID: "updateChatRevenueAmount#c6c9bcc4", + UpdateStarRevenueStatusTypeID: "updateStarRevenueStatus#ef4bfccb", + UpdateSpeechRecognitionTrialTypeID: "updateSpeechRecognitionTrial#ff4efcc1", + UpdateDiceEmojisTypeID: "updateDiceEmojis#9d0f91df", + UpdateAnimatedEmojiMessageClickedTypeID: "updateAnimatedEmojiMessageClicked#a3167405", + UpdateAnimationSearchParametersTypeID: "updateAnimationSearchParameters#6016ef01", + UpdateSuggestedActionsTypeID: "updateSuggestedActions#c2e5cccb", + UpdateSpeedLimitNotificationTypeID: "updateSpeedLimitNotification#c683d868", + UpdateContactCloseBirthdaysTypeID: "updateContactCloseBirthdays#c88b98ce", + UpdateAutosaveSettingsTypeID: "updateAutosaveSettings#da274f0b", + UpdateBusinessConnectionTypeID: "updateBusinessConnection#8632f476", + UpdateNewBusinessMessageTypeID: "updateNewBusinessMessage#86be4644", + UpdateBusinessMessageEditedTypeID: "updateBusinessMessageEdited#81a66d89", + UpdateBusinessMessagesDeletedTypeID: "updateBusinessMessagesDeleted#e036d3ed", + UpdateNewInlineQueryTypeID: "updateNewInlineQuery#7171bf34", + UpdateNewChosenInlineResultTypeID: "updateNewChosenInlineResult#cb4c4f5d", + UpdateNewCallbackQueryTypeID: "updateNewCallbackQuery#8964d05e", + UpdateNewInlineCallbackQueryTypeID: "updateNewInlineCallbackQuery#ecf934ba", + UpdateNewBusinessCallbackQueryTypeID: "updateNewBusinessCallbackQuery#14125364", + UpdateNewShippingQueryTypeID: "updateNewShippingQuery#29584672", + UpdateNewPreCheckoutQueryTypeID: "updateNewPreCheckoutQuery#2a3871c9", + UpdateNewCustomEventTypeID: "updateNewCustomEvent#76dd6a0c", + UpdateNewCustomQueryTypeID: "updateNewCustomQuery#d702f9a6", + UpdatePollTypeID: "updatePoll#966b73ca", + UpdatePollAnswerTypeID: "updatePollAnswer#b67ac547", + UpdateChatMemberTypeID: "updateChatMember#98865bc7", + UpdateNewChatJoinRequestTypeID: "updateNewChatJoinRequest#7e48b843", + UpdateChatBoostTypeID: "updateChatBoost#50727e24", + UpdateMessageReactionTypeID: "updateMessageReaction#f46c854a", + UpdateMessageReactionsTypeID: "updateMessageReactions#bd5618e9", + UpdatesTypeID: "updates#b9829222", + LogStreamDefaultTypeID: "logStreamDefault#52e296bc", + LogStreamFileTypeID: "logStreamFile#5b528de5", + LogStreamEmptyTypeID: "logStreamEmpty#e233f1cc", + LogVerbosityLevelTypeID: "logVerbosityLevel#676443ea", + LogTagsTypeID: "logTags#dc09ced4", + UserSupportInfoTypeID: "userSupportInfo#b50e1c29", + TestIntTypeID: "testInt#ddbd2c09", + TestStringTypeID: "testString#fe56688c", + TestBytesTypeID: "testBytes#a422c4de", + TestVectorIntTypeID: "testVectorInt#df9eb113", + TestVectorIntObjectTypeID: "testVectorIntObject#f152999b", + TestVectorStringTypeID: "testVectorString#5d6f85bc", + TestVectorStringObjectTypeID: "testVectorStringObject#e5ecc0d", + GetAuthorizationStateRequestTypeID: "getAuthorizationState#742dbe3d", + SetTdlibParametersRequestTypeID: "setTdlibParameters#d1c0f62e", + SetAuthenticationPhoneNumberRequestTypeID: "setAuthenticationPhoneNumber#33c0d823", + SetAuthenticationEmailAddressRequestTypeID: "setAuthenticationEmailAddress#69b2c502", + ResendAuthenticationCodeRequestTypeID: "resendAuthenticationCode#a630bbb8", + CheckAuthenticationEmailCodeRequestTypeID: "checkAuthenticationEmailCode#dd42c29f", + CheckAuthenticationCodeRequestTypeID: "checkAuthenticationCode#edfe44aa", + RequestQrCodeAuthenticationRequestTypeID: "requestQrCodeAuthentication#56fe3c4e", + RegisterUserRequestTypeID: "registerUser#c3aa52ec", + ResetAuthenticationEmailAddressRequestTypeID: "resetAuthenticationEmailAddress#e742722c", + CheckAuthenticationPasswordRequestTypeID: "checkAuthenticationPassword#87424ba0", + RequestAuthenticationPasswordRecoveryRequestTypeID: "requestAuthenticationPasswordRecovery#53152ab6", + CheckAuthenticationPasswordRecoveryCodeRequestTypeID: "checkAuthenticationPasswordRecoveryCode#dc0a3be5", + RecoverAuthenticationPasswordRequestTypeID: "recoverAuthenticationPassword#f8311523", + SendAuthenticationFirebaseSMSRequestTypeID: "sendAuthenticationFirebaseSms#15c15e3f", + ReportAuthenticationCodeMissingRequestTypeID: "reportAuthenticationCodeMissing#91efce48", + CheckAuthenticationBotTokenRequestTypeID: "checkAuthenticationBotToken#261b4476", + LogOutRequestTypeID: "logOut#a1b5c41b", + CloseRequestTypeID: "close#b933e17f", + DestroyRequestTypeID: "destroy#28d9534a", + ConfirmQrCodeAuthenticationRequestTypeID: "confirmQrCodeAuthentication#e993a72d", + GetCurrentStateRequestTypeID: "getCurrentState#b8fc6889", + SetDatabaseEncryptionKeyRequestTypeID: "setDatabaseEncryptionKey#b83345b5", + GetPasswordStateRequestTypeID: "getPasswordState#f5957b78", + SetPasswordRequestTypeID: "setPassword#b8db46dd", + SetLoginEmailAddressRequestTypeID: "setLoginEmailAddress#37bb43d4", + ResendLoginEmailAddressCodeRequestTypeID: "resendLoginEmailAddressCode#11765215", + CheckLoginEmailAddressCodeRequestTypeID: "checkLoginEmailAddressCode#a951fc62", + GetRecoveryEmailAddressRequestTypeID: "getRecoveryEmailAddress#a0f1b9fd", + SetRecoveryEmailAddressRequestTypeID: "setRecoveryEmailAddress#89df939f", + CheckRecoveryEmailAddressCodeRequestTypeID: "checkRecoveryEmailAddressCode#88f7981b", + ResendRecoveryEmailAddressCodeRequestTypeID: "resendRecoveryEmailAddressCode#19d66f1c", + CancelRecoveryEmailAddressVerificationRequestTypeID: "cancelRecoveryEmailAddressVerification#a5988e8d", + RequestPasswordRecoveryRequestTypeID: "requestPasswordRecovery#ff2dc552", + CheckPasswordRecoveryCodeRequestTypeID: "checkPasswordRecoveryCode#f4081e18", + RecoverPasswordRequestTypeID: "recoverPassword#a5259973", + ResetPasswordRequestTypeID: "resetPassword#dc9e8c9d", + CancelPasswordResetRequestTypeID: "cancelPasswordReset#38127462", + CreateTemporaryPasswordRequestTypeID: "createTemporaryPassword#9f0d6f86", + GetTemporaryPasswordStateRequestTypeID: "getTemporaryPasswordState#ff3ea892", + GetMeRequestTypeID: "getMe#f495b27f", + GetUserRequestTypeID: "getUser#42999c0b", + GetUserFullInfoRequestTypeID: "getUserFullInfo#d1b29c58", + GetBasicGroupRequestTypeID: "getBasicGroup#9e893654", + GetBasicGroupFullInfoRequestTypeID: "getBasicGroupFullInfo#9365e32b", + GetSupergroupRequestTypeID: "getSupergroup#3afd10e2", + GetSupergroupFullInfoRequestTypeID: "getSupergroupFullInfo#418d4038", + GetSecretChatRequestTypeID: "getSecretChat#26b7e81", + GetChatRequestTypeID: "getChat#6f421440", + GetMessageRequestTypeID: "getMessage#9372c080", + GetMessageLocallyRequestTypeID: "getMessageLocally#dc062b6c", + GetRepliedMessageRequestTypeID: "getRepliedMessage#d9bd19bd", + GetChatPinnedMessageRequestTypeID: "getChatPinnedMessage#15731ab0", + GetCallbackQueryMessageRequestTypeID: "getCallbackQueryMessage#bd209172", + GetMessagesRequestTypeID: "getMessages#d5dd28bf", + GetMessagePropertiesRequestTypeID: "getMessageProperties#2e18e1ab", + GetMessageThreadRequestTypeID: "getMessageThread#7af23e3e", + GetMessageReadDateRequestTypeID: "getMessageReadDate#a7850343", + GetMessageViewersRequestTypeID: "getMessageViewers#a18f1ace", + GetFileRequestTypeID: "getFile#5c9efd4e", + GetRemoteFileRequestTypeID: "getRemoteFile#7f632732", + LoadChatsRequestTypeID: "loadChats#8f9b7d7b", + GetChatsRequestTypeID: "getChats#c604bac2", + SearchPublicChatRequestTypeID: "searchPublicChat#3316d9ad", + SearchPublicChatsRequestTypeID: "searchPublicChats#39d6e7b9", + SearchChatsRequestTypeID: "searchChats#8ff4b9cc", + SearchChatsOnServerRequestTypeID: "searchChatsOnServer#baf42f74", + SearchChatsNearbyRequestTypeID: "searchChatsNearby#f445c81f", + GetRecommendedChatsRequestTypeID: "getRecommendedChats#d9438d71", + GetChatSimilarChatsRequestTypeID: "getChatSimilarChats#bb508f83", + GetChatSimilarChatCountRequestTypeID: "getChatSimilarChatCount#463e968e", + OpenChatSimilarChatRequestTypeID: "openChatSimilarChat#8fa6f413", + GetTopChatsRequestTypeID: "getTopChats#e8d95221", + RemoveTopChatRequestTypeID: "removeTopChat#8e481e55", + SearchRecentlyFoundChatsRequestTypeID: "searchRecentlyFoundChats#62320591", + AddRecentlyFoundChatRequestTypeID: "addRecentlyFoundChat#97e8198d", + RemoveRecentlyFoundChatRequestTypeID: "removeRecentlyFoundChat#2ac1bf1c", + ClearRecentlyFoundChatsRequestTypeID: "clearRecentlyFoundChats#eefa5b32", + GetRecentlyOpenedChatsRequestTypeID: "getRecentlyOpenedChats#8d4fb223", + CheckChatUsernameRequestTypeID: "checkChatUsername#f8e66210", + GetCreatedPublicChatsRequestTypeID: "getCreatedPublicChats#2a5725ef", + CheckCreatedPublicChatsLimitRequestTypeID: "checkCreatedPublicChatsLimit#e5717fa1", + GetSuitableDiscussionChatsRequestTypeID: "getSuitableDiscussionChats#2ec5df6", + GetInactiveSupergroupChatsRequestTypeID: "getInactiveSupergroupChats#d8cbf9b5", + GetSuitablePersonalChatsRequestTypeID: "getSuitablePersonalChats#90849bf5", + LoadSavedMessagesTopicsRequestTypeID: "loadSavedMessagesTopics#1146d6b8", + GetSavedMessagesTopicHistoryRequestTypeID: "getSavedMessagesTopicHistory#77e5da68", + GetSavedMessagesTopicMessageByDateRequestTypeID: "getSavedMessagesTopicMessageByDate#c15e4680", + DeleteSavedMessagesTopicHistoryRequestTypeID: "deleteSavedMessagesTopicHistory#69df3d6a", + DeleteSavedMessagesTopicMessagesByDateRequestTypeID: "deleteSavedMessagesTopicMessagesByDate#160a25", + ToggleSavedMessagesTopicIsPinnedRequestTypeID: "toggleSavedMessagesTopicIsPinned#a15345cc", + SetPinnedSavedMessagesTopicsRequestTypeID: "setPinnedSavedMessagesTopics#475a1110", + GetGroupsInCommonRequestTypeID: "getGroupsInCommon#16bdd36a", + GetChatHistoryRequestTypeID: "getChatHistory#d051927d", + GetMessageThreadHistoryRequestTypeID: "getMessageThreadHistory#9435d428", + DeleteChatHistoryRequestTypeID: "deleteChatHistory#a841d09f", + DeleteChatRequestTypeID: "deleteChat#f5cae05e", + SearchChatMessagesRequestTypeID: "searchChatMessages#dfdeb5c6", + SearchMessagesRequestTypeID: "searchMessages#31f9c3c9", + SearchSecretMessagesRequestTypeID: "searchSecretMessages#cd2a4c9c", + SearchSavedMessagesRequestTypeID: "searchSavedMessages#8a9b9f96", + SearchCallMessagesRequestTypeID: "searchCallMessages#8c3bef1b", + SearchOutgoingDocumentMessagesRequestTypeID: "searchOutgoingDocumentMessages#c023c47e", + SearchPublicMessagesByTagRequestTypeID: "searchPublicMessagesByTag#25976caa", + SearchPublicStoriesByTagRequestTypeID: "searchPublicStoriesByTag#aa501062", + SearchPublicStoriesByLocationRequestTypeID: "searchPublicStoriesByLocation#5f2bd988", + SearchPublicStoriesByVenueRequestTypeID: "searchPublicStoriesByVenue#d71a622a", + GetSearchedForTagsRequestTypeID: "getSearchedForTags#9b1b30cd", + RemoveSearchedForTagRequestTypeID: "removeSearchedForTag#35216bca", + ClearSearchedForTagsRequestTypeID: "clearSearchedForTags#1e84c356", + DeleteAllCallMessagesRequestTypeID: "deleteAllCallMessages#a897d1f3", + SearchChatRecentLocationMessagesRequestTypeID: "searchChatRecentLocationMessages#38a37ee6", + GetChatMessageByDateRequestTypeID: "getChatMessageByDate#3f557136", + GetChatSparseMessagePositionsRequestTypeID: "getChatSparseMessagePositions#3b452efd", + GetChatMessageCalendarRequestTypeID: "getChatMessageCalendar#81af2db7", + GetChatMessageCountRequestTypeID: "getChatMessageCount#38f78909", + GetChatMessagePositionRequestTypeID: "getChatMessagePosition#81bfcc7", + GetChatScheduledMessagesRequestTypeID: "getChatScheduledMessages#df3d2ffb", + GetChatSponsoredMessagesRequestTypeID: "getChatSponsoredMessages#50a84098", + ClickChatSponsoredMessageRequestTypeID: "clickChatSponsoredMessage#d9c09feb", + ReportChatSponsoredMessageRequestTypeID: "reportChatSponsoredMessage#cc3e53be", + RemoveNotificationRequestTypeID: "removeNotification#336ab34e", + RemoveNotificationGroupRequestTypeID: "removeNotificationGroup#661a638e", + GetMessageLinkRequestTypeID: "getMessageLink#c556ef7a", + GetMessageEmbeddingCodeRequestTypeID: "getMessageEmbeddingCode#62a4cd09", + GetMessageLinkInfoRequestTypeID: "getMessageLinkInfo#d63eb458", + TranslateTextRequestTypeID: "translateText#252264f2", + TranslateMessageTextRequestTypeID: "translateMessageText#53c51ed2", + RecognizeSpeechRequestTypeID: "recognizeSpeech#67d402b9", + RateSpeechRecognitionRequestTypeID: "rateSpeechRecognition#eedcc3b5", + GetChatAvailableMessageSendersRequestTypeID: "getChatAvailableMessageSenders#450fe92b", + SetChatMessageSenderRequestTypeID: "setChatMessageSender#ab456b7e", + SendMessageRequestTypeID: "sendMessage#e02d01e9", + SendMessageAlbumRequestTypeID: "sendMessageAlbum#74bcdacf", + SendBotStartMessageRequestTypeID: "sendBotStartMessage#aa6a3eee", + SendInlineQueryResultMessageRequestTypeID: "sendInlineQueryResultMessage#467c5478", + ForwardMessagesRequestTypeID: "forwardMessages#34de5b20", + SendQuickReplyShortcutMessagesRequestTypeID: "sendQuickReplyShortcutMessages#dd5169d", + ResendMessagesRequestTypeID: "resendMessages#90e36776", + AddLocalMessageRequestTypeID: "addLocalMessage#f617b7a1", + DeleteMessagesRequestTypeID: "deleteMessages#c3ed9de2", + DeleteChatMessagesBySenderRequestTypeID: "deleteChatMessagesBySender#ba9b2e67", + DeleteChatMessagesByDateRequestTypeID: "deleteChatMessagesByDate#9e44e0bf", + EditMessageTextRequestTypeID: "editMessageText#bb2e1b7", + EditMessageLiveLocationRequestTypeID: "editMessageLiveLocation#8f511394", + EditMessageMediaRequestTypeID: "editMessageMedia#bb4b8713", + EditMessageCaptionRequestTypeID: "editMessageCaption#87977241", + EditMessageReplyMarkupRequestTypeID: "editMessageReplyMarkup#13cbde89", + EditInlineMessageTextRequestTypeID: "editInlineMessageText#cd02c1e5", + EditInlineMessageLiveLocationRequestTypeID: "editInlineMessageLiveLocation#7f37a0ac", + EditInlineMessageMediaRequestTypeID: "editInlineMessageMedia#1676781", + EditInlineMessageCaptionRequestTypeID: "editInlineMessageCaption#540744f8", + EditInlineMessageReplyMarkupRequestTypeID: "editInlineMessageReplyMarkup#fbf906de", + EditMessageSchedulingStateRequestTypeID: "editMessageSchedulingState#ae2a0bc0", + SetMessageFactCheckRequestTypeID: "setMessageFactCheck#ffbe3d08", + SendBusinessMessageRequestTypeID: "sendBusinessMessage#987b403", + SendBusinessMessageAlbumRequestTypeID: "sendBusinessMessageAlbum#70bd4e6f", + EditBusinessMessageTextRequestTypeID: "editBusinessMessageText#bb81119c", + EditBusinessMessageLiveLocationRequestTypeID: "editBusinessMessageLiveLocation#1d80ae1f", + EditBusinessMessageMediaRequestTypeID: "editBusinessMessageMedia#fc614778", + EditBusinessMessageCaptionRequestTypeID: "editBusinessMessageCaption#c02142c3", + EditBusinessMessageReplyMarkupRequestTypeID: "editBusinessMessageReplyMarkup#29d46c17", + StopBusinessPollRequestTypeID: "stopBusinessPoll#bbeb2160", + SetBusinessMessageIsPinnedRequestTypeID: "setBusinessMessageIsPinned#ff14f5f0", + CheckQuickReplyShortcutNameRequestTypeID: "checkQuickReplyShortcutName#7d3dd129", + LoadQuickReplyShortcutsRequestTypeID: "loadQuickReplyShortcuts#c367b29d", + SetQuickReplyShortcutNameRequestTypeID: "setQuickReplyShortcutName#b20f471", + DeleteQuickReplyShortcutRequestTypeID: "deleteQuickReplyShortcut#f1486c16", + ReorderQuickReplyShortcutsRequestTypeID: "reorderQuickReplyShortcuts#b04981c4", + LoadQuickReplyShortcutMessagesRequestTypeID: "loadQuickReplyShortcutMessages#fd40aed4", + DeleteQuickReplyShortcutMessagesRequestTypeID: "deleteQuickReplyShortcutMessages#e859fcbb", + AddQuickReplyShortcutMessageRequestTypeID: "addQuickReplyShortcutMessage#3f188b2a", + AddQuickReplyShortcutInlineQueryResultMessageRequestTypeID: "addQuickReplyShortcutInlineQueryResultMessage#87c02a04", + AddQuickReplyShortcutMessageAlbumRequestTypeID: "addQuickReplyShortcutMessageAlbum#9647a3fd", + ReaddQuickReplyShortcutMessagesRequestTypeID: "readdQuickReplyShortcutMessages#652518f7", + EditQuickReplyMessageRequestTypeID: "editQuickReplyMessage#4cc978e", + GetForumTopicDefaultIconsRequestTypeID: "getForumTopicDefaultIcons#583574dc", + CreateForumTopicRequestTypeID: "createForumTopic#c1fa28e4", + EditForumTopicRequestTypeID: "editForumTopic#a7769060", + GetForumTopicRequestTypeID: "getForumTopic#e59bfe41", + GetForumTopicLinkRequestTypeID: "getForumTopicLink#c97b88cb", + GetForumTopicsRequestTypeID: "getForumTopics#fbab7d5a", + SetForumTopicNotificationSettingsRequestTypeID: "setForumTopicNotificationSettings#1f433467", + ToggleForumTopicIsClosedRequestTypeID: "toggleForumTopicIsClosed#c7648af3", + ToggleGeneralForumTopicIsHiddenRequestTypeID: "toggleGeneralForumTopicIsHidden#5f1d1448", + ToggleForumTopicIsPinnedRequestTypeID: "toggleForumTopicIsPinned#466ceab4", + SetPinnedForumTopicsRequestTypeID: "setPinnedForumTopics#ddf26f21", + DeleteForumTopicRequestTypeID: "deleteForumTopic#6f285cb8", + GetEmojiReactionRequestTypeID: "getEmojiReaction#e53411dc", + GetCustomEmojiReactionAnimationsRequestTypeID: "getCustomEmojiReactionAnimations#49748dd2", + GetMessageAvailableReactionsRequestTypeID: "getMessageAvailableReactions#76db86b2", + ClearRecentReactionsRequestTypeID: "clearRecentReactions#4d61c752", + AddMessageReactionRequestTypeID: "addMessageReaction#549855ed", + RemoveMessageReactionRequestTypeID: "removeMessageReaction#97474d7b", + AddPaidMessageReactionRequestTypeID: "addPaidMessageReaction#542fae53", + RemovePendingPaidMessageReactionsRequestTypeID: "removePendingPaidMessageReactions#41949cfb", + TogglePaidMessageReactionIsAnonymousRequestTypeID: "togglePaidMessageReactionIsAnonymous#9774db11", + SetMessageReactionsRequestTypeID: "setMessageReactions#71fa9e8f", + GetMessageAddedReactionsRequestTypeID: "getMessageAddedReactions#7dc6ae52", + SetDefaultReactionTypeRequestTypeID: "setDefaultReactionType#65038a3d", + GetSavedMessagesTagsRequestTypeID: "getSavedMessagesTags#8cd667a9", + SetSavedMessagesTagLabelRequestTypeID: "setSavedMessagesTagLabel#b03acd10", + GetMessageEffectRequestTypeID: "getMessageEffect#9e513d14", + SearchQuoteRequestTypeID: "searchQuote#6864011f", + GetTextEntitiesRequestTypeID: "getTextEntities#eba543fb", + ParseTextEntitiesRequestTypeID: "parseTextEntities#9a1fc29f", + ParseMarkdownRequestTypeID: "parseMarkdown#2d153aef", + GetMarkdownTextRequestTypeID: "getMarkdownText#9ce7228", + GetCountryFlagEmojiRequestTypeID: "getCountryFlagEmoji#3a8629fa", + GetFileMimeTypeRequestTypeID: "getFileMimeType#84631b89", + GetFileExtensionRequestTypeID: "getFileExtension#f9adb934", + CleanFileNameRequestTypeID: "cleanFileName#39b1f7fb", + GetLanguagePackStringRequestTypeID: "getLanguagePackString#8fcde73", + GetJSONValueRequestTypeID: "getJsonValue#92fa5a05", + GetJSONStringRequestTypeID: "getJsonString#278b9421", + GetThemeParametersJSONStringRequestTypeID: "getThemeParametersJsonString#91b905f8", + SetPollAnswerRequestTypeID: "setPollAnswer#5303b916", + GetPollVotersRequestTypeID: "getPollVoters#c45ba9ac", + StopPollRequestTypeID: "stopPoll#62e80aad", + HideSuggestedActionRequestTypeID: "hideSuggestedAction#a2ef2b7f", + HideContactCloseBirthdaysRequestTypeID: "hideContactCloseBirthdays#baad087b", + GetBusinessConnectionRequestTypeID: "getBusinessConnection#81f42420", + GetLoginURLInfoRequestTypeID: "getLoginUrlInfo#ccc99db3", + GetLoginURLRequestTypeID: "getLoginUrl#2f3295d1", + ShareUsersWithBotRequestTypeID: "shareUsersWithBot#58448550", + ShareChatWithBotRequestTypeID: "shareChatWithBot#a6530ae2", + GetInlineQueryResultsRequestTypeID: "getInlineQueryResults#79dcf86c", + AnswerInlineQueryRequestTypeID: "answerInlineQuery#ac7cc5e6", + GetPopularWebAppBotsRequestTypeID: "getPopularWebAppBots#e8d04cb", + SearchWebAppRequestTypeID: "searchWebApp#b5fc8a35", + GetWebAppLinkURLRequestTypeID: "getWebAppLinkUrl#4f0ef3cc", + GetMainWebAppRequestTypeID: "getMainWebApp#be84329a", + GetWebAppURLRequestTypeID: "getWebAppUrl#64c42cbe", + SendWebAppDataRequestTypeID: "sendWebAppData#ab1fce0c", + OpenWebAppRequestTypeID: "openWebApp#b02666b0", + CloseWebAppRequestTypeID: "closeWebApp#68a124c6", + AnswerWebAppQueryRequestTypeID: "answerWebAppQuery#a0b49cf1", + GetCallbackQueryAnswerRequestTypeID: "getCallbackQueryAnswer#6ef7a5f", + AnswerCallbackQueryRequestTypeID: "answerCallbackQuery#bb462e76", + AnswerShippingQueryRequestTypeID: "answerShippingQuery#7a3c2432", + AnswerPreCheckoutQueryRequestTypeID: "answerPreCheckoutQuery#a76163eb", + SetGameScoreRequestTypeID: "setGameScore#7eccedc6", + SetInlineGameScoreRequestTypeID: "setInlineGameScore#c7715d8b", + GetGameHighScoresRequestTypeID: "getGameHighScores#f0459b", + GetInlineGameHighScoresRequestTypeID: "getInlineGameHighScores#e0396baa", + DeleteChatReplyMarkupRequestTypeID: "deleteChatReplyMarkup#5ff9b5b", + SendChatActionRequestTypeID: "sendChatAction#8823f29e", + OpenChatRequestTypeID: "openChat#ecb9be0b", + CloseChatRequestTypeID: "closeChat#25e86e9", + ViewMessagesRequestTypeID: "viewMessages#aa2f0438", + OpenMessageContentRequestTypeID: "openMessageContent#d3f2697b", + ClickAnimatedEmojiMessageRequestTypeID: "clickAnimatedEmojiMessage#bb17662", + GetInternalLinkRequestTypeID: "getInternalLink#3960f1b0", + GetInternalLinkTypeRequestTypeID: "getInternalLinkType#8bdd5709", + GetExternalLinkInfoRequestTypeID: "getExternalLinkInfo#460d7a3f", + GetExternalLinkRequestTypeID: "getExternalLink#5e92f0eb", + ReadAllChatMentionsRequestTypeID: "readAllChatMentions#50eab2b5", + ReadAllMessageThreadMentionsRequestTypeID: "readAllMessageThreadMentions#4edd7555", + ReadAllChatReactionsRequestTypeID: "readAllChatReactions#54c1976d", + ReadAllMessageThreadReactionsRequestTypeID: "readAllMessageThreadReactions#d0bc273e", + CreatePrivateChatRequestTypeID: "createPrivateChat#c7825b09", + CreateBasicGroupChatRequestTypeID: "createBasicGroupChat#758ab4e4", + CreateSupergroupChatRequestTypeID: "createSupergroupChat#46c770eb", + CreateSecretChatRequestTypeID: "createSecretChat#730dd22f", + CreateNewBasicGroupChatRequestTypeID: "createNewBasicGroupChat#8b9517af", + CreateNewSupergroupChatRequestTypeID: "createNewSupergroupChat#2fecf6c6", + CreateNewSecretChatRequestTypeID: "createNewSecretChat#db012265", + UpgradeBasicGroupChatToSupergroupChatRequestTypeID: "upgradeBasicGroupChatToSupergroupChat#11e915ba", + GetChatListsToAddChatRequestTypeID: "getChatListsToAddChat#2709d6a1", + AddChatToListRequestTypeID: "addChatToList#fb334eb5", + GetChatFolderRequestTypeID: "getChatFolder#5882a98", + CreateChatFolderRequestTypeID: "createChatFolder#3c85c500", + EditChatFolderRequestTypeID: "editChatFolder#332fb32", + DeleteChatFolderRequestTypeID: "deleteChatFolder#74260b87", + GetChatFolderChatsToLeaveRequestTypeID: "getChatFolderChatsToLeave#8dc1e6af", + GetChatFolderChatCountRequestTypeID: "getChatFolderChatCount#7dd4cbbe", + ReorderChatFoldersRequestTypeID: "reorderChatFolders#59544c32", + ToggleChatFolderTagsRequestTypeID: "toggleChatFolderTags#834b6c44", + GetRecommendedChatFoldersRequestTypeID: "getRecommendedChatFolders#f7533b87", + GetChatFolderDefaultIconNameRequestTypeID: "getChatFolderDefaultIconName#2cf7a067", + GetChatsForChatFolderInviteLinkRequestTypeID: "getChatsForChatFolderInviteLink#6fac4949", + CreateChatFolderInviteLinkRequestTypeID: "createChatFolderInviteLink#fba5e198", + GetChatFolderInviteLinksRequestTypeID: "getChatFolderInviteLinks#139d5be0", + EditChatFolderInviteLinkRequestTypeID: "editChatFolderInviteLink#5cc415a8", + DeleteChatFolderInviteLinkRequestTypeID: "deleteChatFolderInviteLink#c890717e", + CheckChatFolderInviteLinkRequestTypeID: "checkChatFolderInviteLink#1f25999b", + AddChatFolderByInviteLinkRequestTypeID: "addChatFolderByInviteLink#1ed19dae", + GetChatFolderNewChatsRequestTypeID: "getChatFolderNewChats#7e8d2ccc", + ProcessChatFolderNewChatsRequestTypeID: "processChatFolderNewChats#109f8a8b", + GetArchiveChatListSettingsRequestTypeID: "getArchiveChatListSettings#838d8e60", + SetArchiveChatListSettingsRequestTypeID: "setArchiveChatListSettings#cb454c0a", + SetChatTitleRequestTypeID: "setChatTitle#9cabebf", + SetChatPhotoRequestTypeID: "setChatPhoto#e97b8d03", + SetChatAccentColorRequestTypeID: "setChatAccentColor#349f57ca", + SetChatProfileAccentColorRequestTypeID: "setChatProfileAccentColor#4227ae7a", + SetChatMessageAutoDeleteTimeRequestTypeID: "setChatMessageAutoDeleteTime#a641b4ff", + SetChatEmojiStatusRequestTypeID: "setChatEmojiStatus#55881912", + SetChatPermissionsRequestTypeID: "setChatPermissions#7f7706fe", + SetChatBackgroundRequestTypeID: "setChatBackground#eb4c3fe", + DeleteChatBackgroundRequestTypeID: "deleteChatBackground#1316e678", + SetChatThemeRequestTypeID: "setChatTheme#8f090293", + SetChatDraftMessageRequestTypeID: "setChatDraftMessage#645e1f1a", + SetChatNotificationSettingsRequestTypeID: "setChatNotificationSettings#2e531ffe", + ToggleChatHasProtectedContentRequestTypeID: "toggleChatHasProtectedContent#3a20d94d", + ToggleChatViewAsTopicsRequestTypeID: "toggleChatViewAsTopics#2b2783dc", + ToggleChatIsTranslatableRequestTypeID: "toggleChatIsTranslatable#93f9cbdf", + ToggleChatIsMarkedAsUnreadRequestTypeID: "toggleChatIsMarkedAsUnread#c538dadf", + ToggleChatDefaultDisableNotificationRequestTypeID: "toggleChatDefaultDisableNotification#12c36012", + SetChatAvailableReactionsRequestTypeID: "setChatAvailableReactions#feb3e06", + SetChatClientDataRequestTypeID: "setChatClientData#ceb3273d", + SetChatDescriptionRequestTypeID: "setChatDescription#74a8b45d", + SetChatDiscussionGroupRequestTypeID: "setChatDiscussionGroup#c93c32b8", + SetChatLocationRequestTypeID: "setChatLocation#d2471daa", + SetChatSlowModeDelayRequestTypeID: "setChatSlowModeDelay#dfcae63e", + PinChatMessageRequestTypeID: "pinChatMessage#79475baf", + UnpinChatMessageRequestTypeID: "unpinChatMessage#7b1c3ede", + UnpinAllChatMessagesRequestTypeID: "unpinAllChatMessages#aa4cd4b7", + UnpinAllMessageThreadMessagesRequestTypeID: "unpinAllMessageThreadMessages#b7c69f00", + JoinChatRequestTypeID: "joinChat#137a1aa1", + LeaveChatRequestTypeID: "leaveChat#93377a61", + AddChatMemberRequestTypeID: "addChatMember#66875217", + AddChatMembersRequestTypeID: "addChatMembers#1a3232f", + SetChatMemberStatusRequestTypeID: "setChatMemberStatus#4e0171f", + BanChatMemberRequestTypeID: "banChatMember#cb107d7c", + CanTransferOwnershipRequestTypeID: "canTransferOwnership#25d3440c", + TransferChatOwnershipRequestTypeID: "transferChatOwnership#77a00a13", + GetChatMemberRequestTypeID: "getChatMember#d0c15272", + SearchChatMembersRequestTypeID: "searchChatMembers#e56d46c5", + GetChatAdministratorsRequestTypeID: "getChatAdministrators#5c0eb6bb", + ClearAllDraftMessagesRequestTypeID: "clearAllDraftMessages#fd3c74db", + GetSavedNotificationSoundRequestTypeID: "getSavedNotificationSound#1b647917", + GetSavedNotificationSoundsRequestTypeID: "getSavedNotificationSounds#c0346fa8", + AddSavedNotificationSoundRequestTypeID: "addSavedNotificationSound#3e3984ef", + RemoveSavedNotificationSoundRequestTypeID: "removeSavedNotificationSound#e363474e", + GetChatNotificationSettingsExceptionsRequestTypeID: "getChatNotificationSettingsExceptions#bfe0e11", + GetScopeNotificationSettingsRequestTypeID: "getScopeNotificationSettings#c4a8254f", + SetScopeNotificationSettingsRequestTypeID: "setScopeNotificationSettings#85cfb63a", + SetReactionNotificationSettingsRequestTypeID: "setReactionNotificationSettings#46b2d495", + ResetAllNotificationSettingsRequestTypeID: "resetAllNotificationSettings#f5a0a8f9", + ToggleChatIsPinnedRequestTypeID: "toggleChatIsPinned#a776263e", + SetPinnedChatsRequestTypeID: "setPinnedChats#c6c6edf1", + ReadChatListRequestTypeID: "readChatList#bd6498aa", + GetCurrentWeatherRequestTypeID: "getCurrentWeather#8ada9bc9", + GetStoryRequestTypeID: "getStory#717b1c78", + GetChatsToSendStoriesRequestTypeID: "getChatsToSendStories#22f9e3a4", + CanSendStoryRequestTypeID: "canSendStory#b6e0216b", + SendStoryRequestTypeID: "sendStory#e6ab3302", + EditStoryRequestTypeID: "editStory#5e6a21b1", + EditStoryCoverRequestTypeID: "editStoryCover#ab2a0c4b", + SetStoryPrivacySettingsRequestTypeID: "setStoryPrivacySettings#d8e94332", + ToggleStoryIsPostedToChatPageRequestTypeID: "toggleStoryIsPostedToChatPage#ee0f4aff", + DeleteStoryRequestTypeID: "deleteStory#9f35af16", + GetStoryNotificationSettingsExceptionsRequestTypeID: "getStoryNotificationSettingsExceptions#256a2eb0", + LoadActiveStoriesRequestTypeID: "loadActiveStories#7d8cf738", + SetChatActiveStoriesListRequestTypeID: "setChatActiveStoriesList#e0e35d11", + GetChatActiveStoriesRequestTypeID: "getChatActiveStories#2e4ffbf5", + GetChatPostedToChatPageStoriesRequestTypeID: "getChatPostedToChatPageStories#fd3bc72b", + GetChatArchivedStoriesRequestTypeID: "getChatArchivedStories#af1e9488", + SetChatPinnedStoriesRequestTypeID: "setChatPinnedStories#f5cb679f", + OpenStoryRequestTypeID: "openStory#ceda7c7d", + CloseStoryRequestTypeID: "closeStory#443d0f55", + GetStoryAvailableReactionsRequestTypeID: "getStoryAvailableReactions#23854d3b", + SetStoryReactionRequestTypeID: "setStoryReaction#ac8b4fa7", + GetStoryInteractionsRequestTypeID: "getStoryInteractions#1cd1400d", + GetChatStoryInteractionsRequestTypeID: "getChatStoryInteractions#c5ec7376", + ReportStoryRequestTypeID: "reportStory#9b5f709b", + ActivateStoryStealthModeRequestTypeID: "activateStoryStealthMode#c3db8491", + GetStoryPublicForwardsRequestTypeID: "getStoryPublicForwards#68f7dcbb", + GetChatBoostLevelFeaturesRequestTypeID: "getChatBoostLevelFeatures#45e63e8b", + GetChatBoostFeaturesRequestTypeID: "getChatBoostFeatures#e8c128a0", + GetAvailableChatBoostSlotsRequestTypeID: "getAvailableChatBoostSlots#7307ebd5", + GetChatBoostStatusRequestTypeID: "getChatBoostStatus#cfac8acf", + BoostChatRequestTypeID: "boostChat#890ccd68", + GetChatBoostLinkRequestTypeID: "getChatBoostLink#56f16c85", + GetChatBoostLinkInfoRequestTypeID: "getChatBoostLinkInfo#26fc4b5c", + GetChatBoostsRequestTypeID: "getChatBoosts#ab5eaa38", + GetUserChatBoostsRequestTypeID: "getUserChatBoosts#b90ee799", + GetAttachmentMenuBotRequestTypeID: "getAttachmentMenuBot#3da561fb", + ToggleBotIsAddedToAttachmentMenuRequestTypeID: "toggleBotIsAddedToAttachmentMenu#8e59de9a", + GetThemedEmojiStatusesRequestTypeID: "getThemedEmojiStatuses#6ac5c8c2", + GetRecentEmojiStatusesRequestTypeID: "getRecentEmojiStatuses#ae3a3d29", + GetDefaultEmojiStatusesRequestTypeID: "getDefaultEmojiStatuses#24e45ec3", + ClearRecentEmojiStatusesRequestTypeID: "clearRecentEmojiStatuses#e671cb5e", + GetThemedChatEmojiStatusesRequestTypeID: "getThemedChatEmojiStatuses#fb735cb5", + GetDefaultChatEmojiStatusesRequestTypeID: "getDefaultChatEmojiStatuses#a7aa86e6", + GetDisallowedChatEmojiStatusesRequestTypeID: "getDisallowedChatEmojiStatuses#d2144da0", + DownloadFileRequestTypeID: "downloadFile#3f253234", + GetFileDownloadedPrefixSizeRequestTypeID: "getFileDownloadedPrefixSize#3304bd2d", + CancelDownloadFileRequestTypeID: "cancelDownloadFile#8b8052de", + GetSuggestedFileNameRequestTypeID: "getSuggestedFileName#85d8a486", + PreliminaryUploadFileRequestTypeID: "preliminaryUploadFile#70e7cb99", + CancelPreliminaryUploadFileRequestTypeID: "cancelPreliminaryUploadFile#311446be", + WriteGeneratedFilePartRequestTypeID: "writeGeneratedFilePart#cc89e95", + SetFileGenerationProgressRequestTypeID: "setFileGenerationProgress#6d754b3e", + FinishFileGenerationRequestTypeID: "finishFileGeneration#c11d0c9d", + ReadFilePartRequestTypeID: "readFilePart#360ca70d", + DeleteFileRequestTypeID: "deleteFile#6bbe9b2c", + AddFileToDownloadsRequestTypeID: "addFileToDownloads#33b583b7", + ToggleDownloadIsPausedRequestTypeID: "toggleDownloadIsPaused#c7866715", + ToggleAllDownloadsArePausedRequestTypeID: "toggleAllDownloadsArePaused#4a989002", + RemoveFileFromDownloadsRequestTypeID: "removeFileFromDownloads#5706bfee", + RemoveAllFilesFromDownloadsRequestTypeID: "removeAllFilesFromDownloads#b9487686", + SearchFileDownloadsRequestTypeID: "searchFileDownloads#2a1e0856", + SetApplicationVerificationTokenRequestTypeID: "setApplicationVerificationToken#3744af85", + GetMessageFileTypeRequestTypeID: "getMessageFileType#e2c70fd4", + GetMessageImportConfirmationTextRequestTypeID: "getMessageImportConfirmationText#174881a8", + ImportMessagesRequestTypeID: "importMessages#7e98592b", + ReplacePrimaryChatInviteLinkRequestTypeID: "replacePrimaryChatInviteLink#3f9e7b9d", + CreateChatInviteLinkRequestTypeID: "createChatInviteLink#1126a341", + CreateChatSubscriptionInviteLinkRequestTypeID: "createChatSubscriptionInviteLink#226b65", + EditChatInviteLinkRequestTypeID: "editChatInviteLink#4eb23d7c", + EditChatSubscriptionInviteLinkRequestTypeID: "editChatSubscriptionInviteLink#c74445d3", + GetChatInviteLinkRequestTypeID: "getChatInviteLink#e36a41fd", + GetChatInviteLinkCountsRequestTypeID: "getChatInviteLinkCounts#3510e291", + GetChatInviteLinksRequestTypeID: "getChatInviteLinks#34a55cac", + GetChatInviteLinkMembersRequestTypeID: "getChatInviteLinkMembers#6704ed3c", + RevokeChatInviteLinkRequestTypeID: "revokeChatInviteLink#d1b755a9", + DeleteRevokedChatInviteLinkRequestTypeID: "deleteRevokedChatInviteLink#91270c7f", + DeleteAllRevokedChatInviteLinksRequestTypeID: "deleteAllRevokedChatInviteLinks#424816da", + CheckChatInviteLinkRequestTypeID: "checkChatInviteLink#e261483b", + JoinChatByInviteLinkRequestTypeID: "joinChatByInviteLink#c16aab86", + GetChatJoinRequestsRequestTypeID: "getChatJoinRequests#e8d90ea2", + ProcessChatJoinRequestRequestTypeID: "processChatJoinRequest#3be534a3", + ProcessChatJoinRequestsRequestTypeID: "processChatJoinRequests#3e823dce", + CreateCallRequestTypeID: "createCall#be282e10", + AcceptCallRequestTypeID: "acceptCall#d97562d0", + SendCallSignalingDataRequestTypeID: "sendCallSignalingData#542db19c", + DiscardCallRequestTypeID: "discardCall#95a9a57e", + SendCallRatingRequestTypeID: "sendCallRating#d89b576c", + SendCallDebugInformationRequestTypeID: "sendCallDebugInformation#785b373f", + SendCallLogRequestTypeID: "sendCallLog#3f0a47d1", + GetVideoChatAvailableParticipantsRequestTypeID: "getVideoChatAvailableParticipants#c45da305", + SetVideoChatDefaultParticipantRequestTypeID: "setVideoChatDefaultParticipant#f1a672b3", + CreateVideoChatRequestTypeID: "createVideoChat#7ea4958d", + GetVideoChatRtmpURLRequestTypeID: "getVideoChatRtmpUrl#482b1b1f", + ReplaceVideoChatRtmpURLRequestTypeID: "replaceVideoChatRtmpUrl#214f8fe0", + GetGroupCallRequestTypeID: "getGroupCall#5787668e", + StartScheduledGroupCallRequestTypeID: "startScheduledGroupCall#5a986d16", + ToggleGroupCallEnabledStartNotificationRequestTypeID: "toggleGroupCallEnabledStartNotification#2a30c752", + JoinGroupCallRequestTypeID: "joinGroupCall#c1c947e5", + StartGroupCallScreenSharingRequestTypeID: "startGroupCallScreenSharing#cb4e312d", + ToggleGroupCallScreenSharingIsPausedRequestTypeID: "toggleGroupCallScreenSharingIsPaused#a07b5360", + EndGroupCallScreenSharingRequestTypeID: "endGroupCallScreenSharing#85f41c4c", + SetGroupCallTitleRequestTypeID: "setGroupCallTitle#b6c19dcd", + ToggleGroupCallMuteNewParticipantsRequestTypeID: "toggleGroupCallMuteNewParticipants#10eec1c2", + InviteGroupCallParticipantsRequestTypeID: "inviteGroupCallParticipants#56c030a6", + GetGroupCallInviteLinkRequestTypeID: "getGroupCallInviteLink#2ae14924", + RevokeGroupCallInviteLinkRequestTypeID: "revokeGroupCallInviteLink#1de5a494", + StartGroupCallRecordingRequestTypeID: "startGroupCallRecording#68c5847b", + EndGroupCallRecordingRequestTypeID: "endGroupCallRecording#fb7b6289", + ToggleGroupCallIsMyVideoPausedRequestTypeID: "toggleGroupCallIsMyVideoPaused#e374f199", + ToggleGroupCallIsMyVideoEnabledRequestTypeID: "toggleGroupCallIsMyVideoEnabled#9f2f50fa", + SetGroupCallParticipantIsSpeakingRequestTypeID: "setGroupCallParticipantIsSpeaking#3748a1e5", + ToggleGroupCallParticipantIsMutedRequestTypeID: "toggleGroupCallParticipantIsMuted#b2081407", + SetGroupCallParticipantVolumeLevelRequestTypeID: "setGroupCallParticipantVolumeLevel#97779828", + ToggleGroupCallParticipantIsHandRaisedRequestTypeID: "toggleGroupCallParticipantIsHandRaised#8efb63e1", + LoadGroupCallParticipantsRequestTypeID: "loadGroupCallParticipants#37f3bece", + LeaveGroupCallRequestTypeID: "leaveGroupCall#3a6befa9", + EndGroupCallRequestTypeID: "endGroupCall#22294cb7", + GetGroupCallStreamsRequestTypeID: "getGroupCallStreams#9f7c9164", + GetGroupCallStreamSegmentRequestTypeID: "getGroupCallStreamSegment#8424daa5", + SetMessageSenderBlockListRequestTypeID: "setMessageSenderBlockList#898b5c91", + BlockMessageSenderFromRepliesRequestTypeID: "blockMessageSenderFromReplies#b79df58b", + GetBlockedMessageSendersRequestTypeID: "getBlockedMessageSenders#8ce52f16", + AddContactRequestTypeID: "addContact#6f707140", + ImportContactsRequestTypeID: "importContacts#77bdb718", + GetContactsRequestTypeID: "getContacts#ab7f4470", + SearchContactsRequestTypeID: "searchContacts#95073165", + RemoveContactsRequestTypeID: "removeContacts#b464dfff", + GetImportedContactCountRequestTypeID: "getImportedContactCount#d8e11a26", + ChangeImportedContactsRequestTypeID: "changeImportedContacts#24885905", + ClearImportedContactsRequestTypeID: "clearImportedContacts#33d39142", + SetCloseFriendsRequestTypeID: "setCloseFriends#7ff8f69f", + GetCloseFriendsRequestTypeID: "getCloseFriends#a9d574ce", + SetUserPersonalProfilePhotoRequestTypeID: "setUserPersonalProfilePhoto#1baa28f6", + SuggestUserProfilePhotoRequestTypeID: "suggestUserProfilePhoto#9561f463", + SearchUserByPhoneNumberRequestTypeID: "searchUserByPhoneNumber#eb82adc8", + SharePhoneNumberRequestTypeID: "sharePhoneNumber#4164e055", + GetUserProfilePhotosRequestTypeID: "getUserProfilePhotos#c9defe42", + GetStickersRequestTypeID: "getStickers#45069343", + GetAllStickerEmojisRequestTypeID: "getAllStickerEmojis#11ad2e30", + SearchStickersRequestTypeID: "searchStickers#9a19e90b", + GetGreetingStickersRequestTypeID: "getGreetingStickers#16581d1c", + GetPremiumStickersRequestTypeID: "getPremiumStickers#ef410a50", + GetInstalledStickerSetsRequestTypeID: "getInstalledStickerSets#612ef6f6", + GetArchivedStickerSetsRequestTypeID: "getArchivedStickerSets#3bb8424d", + GetTrendingStickerSetsRequestTypeID: "getTrendingStickerSets#e058455e", + GetAttachedStickerSetsRequestTypeID: "getAttachedStickerSets#4d9d930d", + GetStickerSetRequestTypeID: "getStickerSet#3eb91bc3", + SearchStickerSetRequestTypeID: "searchStickerSet#45049cee", + SearchInstalledStickerSetsRequestTypeID: "searchInstalledStickerSets#7e5e7fa4", + SearchStickerSetsRequestTypeID: "searchStickerSets#faa066c", + ChangeStickerSetRequestTypeID: "changeStickerSet#1ac8a5ed", + ViewTrendingStickerSetsRequestTypeID: "viewTrendingStickerSets#36d6469", + ReorderInstalledStickerSetsRequestTypeID: "reorderInstalledStickerSets#4a830a78", + GetRecentStickersRequestTypeID: "getRecentStickers#dd73aa9f", + AddRecentStickerRequestTypeID: "addRecentSticker#a7e5d89e", + RemoveRecentStickerRequestTypeID: "removeRecentSticker#4a4d440d", + ClearRecentStickersRequestTypeID: "clearRecentStickers#ecda39c4", + GetFavoriteStickersRequestTypeID: "getFavoriteStickers#ebcbcf40", + AddFavoriteStickerRequestTypeID: "addFavoriteSticker#13578cdf", + RemoveFavoriteStickerRequestTypeID: "removeFavoriteSticker#44b88c70", + GetStickerEmojisRequestTypeID: "getStickerEmojis#8f04d547", + SearchEmojisRequestTypeID: "searchEmojis#d513cd61", + GetKeywordEmojisRequestTypeID: "getKeywordEmojis#7af81263", + GetEmojiCategoriesRequestTypeID: "getEmojiCategories#7f86c16e", + GetAnimatedEmojiRequestTypeID: "getAnimatedEmoji#3f844f76", + GetEmojiSuggestionsURLRequestTypeID: "getEmojiSuggestionsUrl#ac4f1b2f", + GetCustomEmojiStickersRequestTypeID: "getCustomEmojiStickers#a5156885", + GetDefaultChatPhotoCustomEmojiStickersRequestTypeID: "getDefaultChatPhotoCustomEmojiStickers#e9917765", + GetDefaultProfilePhotoCustomEmojiStickersRequestTypeID: "getDefaultProfilePhotoCustomEmojiStickers#4c4be2b7", + GetDefaultBackgroundCustomEmojiStickersRequestTypeID: "getDefaultBackgroundCustomEmojiStickers#1cf6680e", + GetSavedAnimationsRequestTypeID: "getSavedAnimations#6b9718", + AddSavedAnimationRequestTypeID: "addSavedAnimation#a44bf860", + RemoveSavedAnimationRequestTypeID: "removeSavedAnimation#e275a919", + GetRecentInlineBotsRequestTypeID: "getRecentInlineBots#55b3723c", + SearchHashtagsRequestTypeID: "searchHashtags#3e34a571", + RemoveRecentHashtagRequestTypeID: "removeRecentHashtag#c393a0a4", + GetLinkPreviewRequestTypeID: "getLinkPreview#c2096321", + GetWebPageInstantViewRequestTypeID: "getWebPageInstantView#8b045689", + SetProfilePhotoRequestTypeID: "setProfilePhoto#85ea05ed", + DeleteProfilePhotoRequestTypeID: "deleteProfilePhoto#4eaa77c1", + SetAccentColorRequestTypeID: "setAccentColor#6389cb39", + SetProfileAccentColorRequestTypeID: "setProfileAccentColor#899bc168", + SetNameRequestTypeID: "setName#66065f10", + SetBioRequestTypeID: "setBio#9f772354", + SetUsernameRequestTypeID: "setUsername#1a385c1e", + ToggleUsernameIsActiveRequestTypeID: "toggleUsernameIsActive#4a276de3", + ReorderActiveUsernamesRequestTypeID: "reorderActiveUsernames#c659414f", + SetBirthdateRequestTypeID: "setBirthdate#4ea9dd98", + SetPersonalChatRequestTypeID: "setPersonalChat#c04babb4", + SetEmojiStatusRequestTypeID: "setEmojiStatus#92f83e5d", + SetLocationRequestTypeID: "setLocation#5993371", + ToggleHasSponsoredMessagesEnabledRequestTypeID: "toggleHasSponsoredMessagesEnabled#75055cec", + SetBusinessLocationRequestTypeID: "setBusinessLocation#eb740715", + SetBusinessOpeningHoursRequestTypeID: "setBusinessOpeningHours#e470a472", + SetBusinessGreetingMessageSettingsRequestTypeID: "setBusinessGreetingMessageSettings#cbf53c3d", + SetBusinessAwayMessageSettingsRequestTypeID: "setBusinessAwayMessageSettings#4974486c", + SetBusinessStartPageRequestTypeID: "setBusinessStartPage#9eed499e", + SendPhoneNumberCodeRequestTypeID: "sendPhoneNumberCode#409e3d10", + SendPhoneNumberFirebaseSMSRequestTypeID: "sendPhoneNumberFirebaseSms#f9c7084", + ReportPhoneNumberCodeMissingRequestTypeID: "reportPhoneNumberCodeMissing#caa4b553", + ResendPhoneNumberCodeRequestTypeID: "resendPhoneNumberCode#6bcea427", + CheckPhoneNumberCodeRequestTypeID: "checkPhoneNumberCode#dc0565a1", + GetBusinessConnectedBotRequestTypeID: "getBusinessConnectedBot#364da7c3", + SetBusinessConnectedBotRequestTypeID: "setBusinessConnectedBot#acf17ef0", + DeleteBusinessConnectedBotRequestTypeID: "deleteBusinessConnectedBot#9e9b7e55", + ToggleBusinessConnectedBotChatIsPausedRequestTypeID: "toggleBusinessConnectedBotChatIsPaused#4f364845", + RemoveBusinessConnectedBotFromChatRequestTypeID: "removeBusinessConnectedBotFromChat#787273f3", + GetBusinessChatLinksRequestTypeID: "getBusinessChatLinks#2a562157", + CreateBusinessChatLinkRequestTypeID: "createBusinessChatLink#91131d40", + EditBusinessChatLinkRequestTypeID: "editBusinessChatLink#5f10f626", + DeleteBusinessChatLinkRequestTypeID: "deleteBusinessChatLink#be526747", + GetBusinessChatLinkInfoRequestTypeID: "getBusinessChatLinkInfo#2f8b7e4a", + GetUserLinkRequestTypeID: "getUserLink#492014e6", + SearchUserByTokenRequestTypeID: "searchUserByToken#d841f436", + SetCommandsRequestTypeID: "setCommands#b0e0217a", + DeleteCommandsRequestTypeID: "deleteCommands#3bc47c2a", + GetCommandsRequestTypeID: "getCommands#58ba8ff7", + SetMenuButtonRequestTypeID: "setMenuButton#b44fc141", + GetMenuButtonRequestTypeID: "getMenuButton#e5eef440", + SetDefaultGroupAdministratorRightsRequestTypeID: "setDefaultGroupAdministratorRights#65577768", + SetDefaultChannelAdministratorRightsRequestTypeID: "setDefaultChannelAdministratorRights#f20d5e19", + CanBotSendMessagesRequestTypeID: "canBotSendMessages#206d948c", + AllowBotToSendMessagesRequestTypeID: "allowBotToSendMessages#69e9c58e", + SendWebAppCustomRequestRequestTypeID: "sendWebAppCustomRequest#36ff5dc8", + GetBotMediaPreviewsRequestTypeID: "getBotMediaPreviews#22665458", + GetBotMediaPreviewInfoRequestTypeID: "getBotMediaPreviewInfo#50f60136", + AddBotMediaPreviewRequestTypeID: "addBotMediaPreview#504b852b", + EditBotMediaPreviewRequestTypeID: "editBotMediaPreview#86955d62", + ReorderBotMediaPreviewsRequestTypeID: "reorderBotMediaPreviews#89ea0cc6", + DeleteBotMediaPreviewsRequestTypeID: "deleteBotMediaPreviews#f7d259db", + SetBotNameRequestTypeID: "setBotName#d295fa71", + GetBotNameRequestTypeID: "getBotName#9a3f722c", + SetBotProfilePhotoRequestTypeID: "setBotProfilePhoto#bd864b66", + ToggleBotUsernameIsActiveRequestTypeID: "toggleBotUsernameIsActive#79639409", + ReorderBotActiveUsernamesRequestTypeID: "reorderBotActiveUsernames#acadc444", + SetBotInfoDescriptionRequestTypeID: "setBotInfoDescription#29571d48", + GetBotInfoDescriptionRequestTypeID: "getBotInfoDescription#d287f835", + SetBotInfoShortDescriptionRequestTypeID: "setBotInfoShortDescription#3a96bae3", + GetBotInfoShortDescriptionRequestTypeID: "getBotInfoShortDescription#4a1c2614", + GetActiveSessionsRequestTypeID: "getActiveSessions#42bd6d3e", + TerminateSessionRequestTypeID: "terminateSession#e7b7c92c", + TerminateAllOtherSessionsRequestTypeID: "terminateAllOtherSessions#6fba6113", + ConfirmSessionRequestTypeID: "confirmSession#d7c9b41f", + ToggleSessionCanAcceptCallsRequestTypeID: "toggleSessionCanAcceptCalls#6c6c2708", + ToggleSessionCanAcceptSecretChatsRequestTypeID: "toggleSessionCanAcceptSecretChats#3ba7a87e", + SetInactiveSessionTTLRequestTypeID: "setInactiveSessionTtl#5d9ca950", + GetConnectedWebsitesRequestTypeID: "getConnectedWebsites#f5d5d352", + DisconnectWebsiteRequestTypeID: "disconnectWebsite#d194f3dd", + DisconnectAllWebsitesRequestTypeID: "disconnectAllWebsites#bf72f203", + SetSupergroupUsernameRequestTypeID: "setSupergroupUsername#503f4b04", + ToggleSupergroupUsernameIsActiveRequestTypeID: "toggleSupergroupUsernameIsActive#a68b6dff", + DisableAllSupergroupUsernamesRequestTypeID: "disableAllSupergroupUsernames#3246f5b0", + ReorderSupergroupActiveUsernamesRequestTypeID: "reorderSupergroupActiveUsernames#663c7f3b", + SetSupergroupStickerSetRequestTypeID: "setSupergroupStickerSet#856ead69", + SetSupergroupCustomEmojiStickerSetRequestTypeID: "setSupergroupCustomEmojiStickerSet#4f3552af", + SetSupergroupUnrestrictBoostCountRequestTypeID: "setSupergroupUnrestrictBoostCount#39ce30a3", + ToggleSupergroupSignMessagesRequestTypeID: "toggleSupergroupSignMessages#221c1fcb", + ToggleSupergroupJoinToSendMessagesRequestTypeID: "toggleSupergroupJoinToSendMessages#f5268e0e", + ToggleSupergroupJoinByRequestRequestTypeID: "toggleSupergroupJoinByRequest#7ddf9fde", + ToggleSupergroupIsAllHistoryAvailableRequestTypeID: "toggleSupergroupIsAllHistoryAvailable#44d9964e", + ToggleSupergroupCanHaveSponsoredMessagesRequestTypeID: "toggleSupergroupCanHaveSponsoredMessages#be8abb72", + ToggleSupergroupHasHiddenMembersRequestTypeID: "toggleSupergroupHasHiddenMembers#a4559dca", + ToggleSupergroupHasAggressiveAntiSpamEnabledRequestTypeID: "toggleSupergroupHasAggressiveAntiSpamEnabled#683ef70f", + ToggleSupergroupIsForumRequestTypeID: "toggleSupergroupIsForum#966f960a", + ToggleSupergroupIsBroadcastGroupRequestTypeID: "toggleSupergroupIsBroadcastGroup#34b22215", + ReportSupergroupSpamRequestTypeID: "reportSupergroupSpam#383e26f2", + ReportSupergroupAntiSpamFalsePositiveRequestTypeID: "reportSupergroupAntiSpamFalsePositive#e13db048", + GetSupergroupMembersRequestTypeID: "getSupergroupMembers#ddf821c8", + CloseSecretChatRequestTypeID: "closeSecretChat#e3ed044b", + GetChatEventLogRequestTypeID: "getChatEventLog#f47b0a9b", + GetTimeZonesRequestTypeID: "getTimeZones#4fe2e058", + GetPaymentFormRequestTypeID: "getPaymentForm#8d4f76d4", + ValidateOrderInfoRequestTypeID: "validateOrderInfo#b5985fcf", + SendPaymentFormRequestTypeID: "sendPaymentForm#c66e388a", + GetPaymentReceiptRequestTypeID: "getPaymentReceipt#3c6cb956", + GetSavedOrderInfoRequestTypeID: "getSavedOrderInfo#bb559edd", + DeleteSavedOrderInfoRequestTypeID: "deleteSavedOrderInfo#61197474", + DeleteSavedCredentialsRequestTypeID: "deleteSavedCredentials#314056d2", + CreateInvoiceLinkRequestTypeID: "createInvoiceLink#cebe921", + RefundStarPaymentRequestTypeID: "refundStarPayment#9476a055", + GetSupportUserRequestTypeID: "getSupportUser#98acec9c", + GetBackgroundURLRequestTypeID: "getBackgroundUrl#2bbc6fd2", + SearchBackgroundRequestTypeID: "searchBackground#80fb9121", + SetDefaultBackgroundRequestTypeID: "setDefaultBackground#89d1a8a1", + DeleteDefaultBackgroundRequestTypeID: "deleteDefaultBackground#b2a4ed3e", + GetInstalledBackgroundsRequestTypeID: "getInstalledBackgrounds#c154d05f", + RemoveInstalledBackgroundRequestTypeID: "removeInstalledBackground#5041253c", + ResetInstalledBackgroundsRequestTypeID: "resetInstalledBackgrounds#70540157", + GetLocalizationTargetInfoRequestTypeID: "getLocalizationTargetInfo#6e3d1f86", + GetLanguagePackInfoRequestTypeID: "getLanguagePackInfo#7bd8daa8", + GetLanguagePackStringsRequestTypeID: "getLanguagePackStrings#b0b867bb", + SynchronizeLanguagePackRequestTypeID: "synchronizeLanguagePack#84e5e72e", + AddCustomServerLanguagePackRequestTypeID: "addCustomServerLanguagePack#448de3", + SetCustomLanguagePackRequestTypeID: "setCustomLanguagePack#234b0607", + EditCustomLanguagePackInfoRequestTypeID: "editCustomLanguagePackInfo#4eb91099", + SetCustomLanguagePackStringRequestTypeID: "setCustomLanguagePackString#4e762518", + DeleteLanguagePackRequestTypeID: "deleteLanguagePack#824edc3e", + RegisterDeviceRequestTypeID: "registerDevice#ff140196", + ProcessPushNotificationRequestTypeID: "processPushNotification#2ee3c890", + GetPushReceiverIDRequestTypeID: "getPushReceiverId#eeec46b2", + GetRecentlyVisitedTMeURLsRequestTypeID: "getRecentlyVisitedTMeUrls#30161a91", + SetUserPrivacySettingRulesRequestTypeID: "setUserPrivacySettingRules#e3c230fb", + GetUserPrivacySettingRulesRequestTypeID: "getUserPrivacySettingRules#84301671", + SetReadDatePrivacySettingsRequestTypeID: "setReadDatePrivacySettings#1d7086b6", + GetReadDatePrivacySettingsRequestTypeID: "getReadDatePrivacySettings#1ae85bbb", + SetNewChatPrivacySettingsRequestTypeID: "setNewChatPrivacySettings#69bf374f", + GetNewChatPrivacySettingsRequestTypeID: "getNewChatPrivacySettings#b2cb4bb7", + CanSendMessageToUserRequestTypeID: "canSendMessageToUser#5b2a2836", + GetOptionRequestTypeID: "getOption#a2459e7e", + SetOptionRequestTypeID: "setOption#7e0b4ef2", + SetAccountTTLRequestTypeID: "setAccountTtl#29ce58e8", + GetAccountTTLRequestTypeID: "getAccountTtl#e58a8b77", + DeleteAccountRequestTypeID: "deleteAccount#533276c6", + SetDefaultMessageAutoDeleteTimeRequestTypeID: "setDefaultMessageAutoDeleteTime#965cd36c", + GetDefaultMessageAutoDeleteTimeRequestTypeID: "getDefaultMessageAutoDeleteTime#e520759a", + RemoveChatActionBarRequestTypeID: "removeChatActionBar#9d9839fa", + ReportChatRequestTypeID: "reportChat#d92c3a8a", + ReportChatPhotoRequestTypeID: "reportChatPhoto#d9701288", + ReportMessageReactionsRequestTypeID: "reportMessageReactions#36c88827", + GetChatRevenueStatisticsRequestTypeID: "getChatRevenueStatistics#29d79b3c", + GetChatRevenueWithdrawalURLRequestTypeID: "getChatRevenueWithdrawalUrl#1e320720", + GetChatRevenueTransactionsRequestTypeID: "getChatRevenueTransactions#472f0715", + GetStarRevenueStatisticsRequestTypeID: "getStarRevenueStatistics#f07b4517", + GetStarWithdrawalURLRequestTypeID: "getStarWithdrawalUrl#a9d23712", + GetStarAdAccountURLRequestTypeID: "getStarAdAccountUrl#73a9455d", + GetChatStatisticsRequestTypeID: "getChatStatistics#137e8198", + GetMessageStatisticsRequestTypeID: "getMessageStatistics#4bb5a1d8", + GetMessagePublicForwardsRequestTypeID: "getMessagePublicForwards#519da4b4", + GetStoryStatisticsRequestTypeID: "getStoryStatistics#3a964342", + GetStatisticalGraphRequestTypeID: "getStatisticalGraph#419f8d9b", + GetStorageStatisticsRequestTypeID: "getStorageStatistics#cd254b37", + GetStorageStatisticsFastRequestTypeID: "getStorageStatisticsFast#3a86702", + GetDatabaseStatisticsRequestTypeID: "getDatabaseStatistics#8c33d4b9", + OptimizeStorageRequestTypeID: "optimizeStorage#ef73c8c5", + SetNetworkTypeRequestTypeID: "setNetworkType#d62de55e", + GetNetworkStatisticsRequestTypeID: "getNetworkStatistics#c537581e", + AddNetworkStatisticsRequestTypeID: "addNetworkStatistics#4b63b3d9", + ResetNetworkStatisticsRequestTypeID: "resetNetworkStatistics#6222dd86", + GetAutoDownloadSettingsPresetsRequestTypeID: "getAutoDownloadSettingsPresets#996a4737", + SetAutoDownloadSettingsRequestTypeID: "setAutoDownloadSettings#eaeb64f4", + GetAutosaveSettingsRequestTypeID: "getAutosaveSettings#7f53f22a", + SetAutosaveSettingsRequestTypeID: "setAutosaveSettings#6878c0", + ClearAutosaveSettingsExceptionsRequestTypeID: "clearAutosaveSettingsExceptions#57ec63f2", + GetBankCardInfoRequestTypeID: "getBankCardInfo#b1e31db0", + GetPassportElementRequestTypeID: "getPassportElement#8fcce17a", + GetAllPassportElementsRequestTypeID: "getAllPassportElements#86782aeb", + SetPassportElementRequestTypeID: "setPassportElement#7b45d19c", + DeletePassportElementRequestTypeID: "deletePassportElement#9981aa74", + SetPassportElementErrorsRequestTypeID: "setPassportElementErrors#80fa80bf", + GetPreferredCountryLanguageRequestTypeID: "getPreferredCountryLanguage#c862cbd6", + SendEmailAddressVerificationCodeRequestTypeID: "sendEmailAddressVerificationCode#f2ca537d", + ResendEmailAddressVerificationCodeRequestTypeID: "resendEmailAddressVerificationCode#90653024", + CheckEmailAddressVerificationCodeRequestTypeID: "checkEmailAddressVerificationCode#e695db03", + GetPassportAuthorizationFormRequestTypeID: "getPassportAuthorizationForm#61850486", + GetPassportAuthorizationFormAvailableElementsRequestTypeID: "getPassportAuthorizationFormAvailableElements#3fb314fc", + SendPassportAuthorizationFormRequestTypeID: "sendPassportAuthorizationForm#d9c77579", + SetBotUpdatesStatusRequestTypeID: "setBotUpdatesStatus#bb293991", + UploadStickerFileRequestTypeID: "uploadStickerFile#269650c3", + GetSuggestedStickerSetNameRequestTypeID: "getSuggestedStickerSetName#b0120840", + CheckStickerSetNameRequestTypeID: "checkStickerSetName#955808fe", + CreateNewStickerSetRequestTypeID: "createNewStickerSet#87fd8611", + AddStickerToSetRequestTypeID: "addStickerToSet#56dc1e3b", + ReplaceStickerInSetRequestTypeID: "replaceStickerInSet#e7c82e19", + SetStickerSetThumbnailRequestTypeID: "setStickerSetThumbnail#63fe6932", + SetCustomEmojiStickerSetThumbnailRequestTypeID: "setCustomEmojiStickerSetThumbnail#bd12e0ea", + SetStickerSetTitleRequestTypeID: "setStickerSetTitle#64e933a2", + DeleteStickerSetRequestTypeID: "deleteStickerSet#5e0a7bad", + SetStickerPositionInSetRequestTypeID: "setStickerPositionInSet#7bb24721", + RemoveStickerFromSetRequestTypeID: "removeStickerFromSet#61e1eea4", + SetStickerEmojisRequestTypeID: "setStickerEmojis#d9ec0431", + SetStickerKeywordsRequestTypeID: "setStickerKeywords#462481d", + SetStickerMaskPositionRequestTypeID: "setStickerMaskPosition#47a959d0", + GetOwnedStickerSetsRequestTypeID: "getOwnedStickerSets#58fe8120", + GetMapThumbnailFileRequestTypeID: "getMapThumbnailFile#f6e6979a", + GetPremiumLimitRequestTypeID: "getPremiumLimit#4017fcea", + GetPremiumFeaturesRequestTypeID: "getPremiumFeatures#b4dc2649", + GetPremiumStickerExamplesRequestTypeID: "getPremiumStickerExamples#5369cb98", + ViewPremiumFeatureRequestTypeID: "viewPremiumFeature#b8031b2", + ClickPremiumSubscriptionButtonRequestTypeID: "clickPremiumSubscriptionButton#e9fca306", + GetPremiumStateRequestTypeID: "getPremiumState#278e3ae2", + GetPremiumGiftCodePaymentOptionsRequestTypeID: "getPremiumGiftCodePaymentOptions#89523a2c", + CheckPremiumGiftCodeRequestTypeID: "checkPremiumGiftCode#958ad664", + ApplyPremiumGiftCodeRequestTypeID: "applyPremiumGiftCode#afb44c1e", + LaunchPrepaidPremiumGiveawayRequestTypeID: "launchPrepaidPremiumGiveaway#5328fea1", + GetPremiumGiveawayInfoRequestTypeID: "getPremiumGiveawayInfo#6adb7b97", + GetStarPaymentOptionsRequestTypeID: "getStarPaymentOptions#6d930644", + GetStarGiftPaymentOptionsRequestTypeID: "getStarGiftPaymentOptions#e22760e3", + GetStarTransactionsRequestTypeID: "getStarTransactions#f096f8f1", + GetStarSubscriptionsRequestTypeID: "getStarSubscriptions#d9c7b2ec", + CanPurchaseFromStoreRequestTypeID: "canPurchaseFromStore#3caa9368", + AssignAppStoreTransactionRequestTypeID: "assignAppStoreTransaction#86f30bb0", + AssignGooglePlayTransactionRequestTypeID: "assignGooglePlayTransaction#8939bca4", + EditStarSubscriptionRequestTypeID: "editStarSubscription#7a1a3918", + ReuseStarSubscriptionRequestTypeID: "reuseStarSubscription#2e677441", + GetBusinessFeaturesRequestTypeID: "getBusinessFeatures#c4906001", + AcceptTermsOfServiceRequestTypeID: "acceptTermsOfService#7efe03e4", + SearchStringsByPrefixRequestTypeID: "searchStringsByPrefix#a8145813", + SendCustomRequestRequestTypeID: "sendCustomRequest#10fd71a1", + AnswerCustomQueryRequestTypeID: "answerCustomQuery#b2e52d3f", + SetAlarmRequestTypeID: "setAlarm#cbef7e15", + GetCountriesRequestTypeID: "getCountries#fce8099e", + GetCountryCodeRequestTypeID: "getCountryCode#5bd398f2", + GetPhoneNumberInfoRequestTypeID: "getPhoneNumberInfo#a0229bf9", + GetPhoneNumberInfoSyncRequestTypeID: "getPhoneNumberInfoSync#209b7d38", + GetCollectibleItemInfoRequestTypeID: "getCollectibleItemInfo#f304ad8a", + GetDeepLinkInfoRequestTypeID: "getDeepLinkInfo#28923f7e", + GetApplicationConfigRequestTypeID: "getApplicationConfig#93550682", + SaveApplicationLogEventRequestTypeID: "saveApplicationLogEvent#cfa6c20e", + GetApplicationDownloadLinkRequestTypeID: "getApplicationDownloadLink#6ad2fc4", + AddProxyRequestTypeID: "addProxy#13c2bcd8", + EditProxyRequestTypeID: "editProxy#a0482853", + EnableProxyRequestTypeID: "enableProxy#59138296", + DisableProxyRequestTypeID: "disableProxy#82d31782", + RemoveProxyRequestTypeID: "removeProxy#519ca307", + GetProxiesRequestTypeID: "getProxies#fa560333", + GetProxyLinkRequestTypeID: "getProxyLink#c125ae78", + PingProxyRequestTypeID: "pingProxy#c59b40b1", + SetLogStreamRequestTypeID: "setLogStream#aeaff791", + GetLogStreamRequestTypeID: "getLogStream#45984b5b", + SetLogVerbosityLevelRequestTypeID: "setLogVerbosityLevel#edea07d2", + GetLogVerbosityLevelRequestTypeID: "getLogVerbosityLevel#23689ae4", + GetLogTagsRequestTypeID: "getLogTags#f0d569da", + SetLogTagVerbosityLevelRequestTypeID: "setLogTagVerbosityLevel#8317d696", + GetLogTagVerbosityLevelRequestTypeID: "getLogTagVerbosityLevel#38af2d83", + AddLogMessageRequestTypeID: "addLogMessage#5f36cfec", + GetUserSupportInfoRequestTypeID: "getUserSupportInfo#74a59305", + SetUserSupportInfoRequestTypeID: "setUserSupportInfo#837c9803", + GetSupportNameRequestTypeID: "getSupportName#4d9e1562", + TestCallEmptyRequestTypeID: "testCallEmpty#da9c4a16", + TestCallStringRequestTypeID: "testCallString#98b74a2f", + TestCallBytesRequestTypeID: "testCallBytes#d4215aa9", + TestCallVectorIntRequestTypeID: "testCallVectorInt#65ed7e72", + TestCallVectorIntObjectRequestTypeID: "testCallVectorIntObject#ca57f472", + TestCallVectorStringRequestTypeID: "testCallVectorString#8e5a6ed8", + TestCallVectorStringObjectRequestTypeID: "testCallVectorStringObject#96cd6de", + TestSquareIntRequestTypeID: "testSquareInt#fc6a6990", + TestNetworkRequestTypeID: "testNetwork#afe4344b", + TestProxyRequestTypeID: "testProxy#b8a1a29e", + TestGetDifferenceRequestTypeID: "testGetDifference#68226325", + TestUseUpdateRequestTypeID: "testUseUpdate#2abdff1e", + TestReturnErrorRequestTypeID: "testReturnError#1b217cf2", } } @@ -2551,6 +2575,9 @@ func NamesMap() map[string]uint32 { "inputChatPhotoSticker": InputChatPhotoStickerTypeID, "chatPermissions": ChatPermissionsTypeID, "chatAdministratorRights": ChatAdministratorRightsTypeID, + "starSubscriptionPricing": StarSubscriptionPricingTypeID, + "starSubscription": StarSubscriptionTypeID, + "starSubscriptions": StarSubscriptionsTypeID, "productInfo": ProductInfoTypeID, "premiumPaymentOption": PremiumPaymentOptionTypeID, "premiumStatePaymentOption": PremiumStatePaymentOptionTypeID, @@ -2561,12 +2588,18 @@ func NamesMap() map[string]uint32 { "starPaymentOptions": StarPaymentOptionsTypeID, "starTransactionDirectionIncoming": StarTransactionDirectionIncomingTypeID, "starTransactionDirectionOutgoing": StarTransactionDirectionOutgoingTypeID, + "botTransactionPurposePaidMedia": BotTransactionPurposePaidMediaTypeID, + "botTransactionPurposeInvoicePayment": BotTransactionPurposeInvoicePaymentTypeID, + "channelTransactionPurposePaidMedia": ChannelTransactionPurposePaidMediaTypeID, + "channelTransactionPurposeJoin": ChannelTransactionPurposeJoinTypeID, + "channelTransactionPurposeReaction": ChannelTransactionPurposeReactionTypeID, "starTransactionPartnerTelegram": StarTransactionPartnerTelegramTypeID, "starTransactionPartnerAppStore": StarTransactionPartnerAppStoreTypeID, "starTransactionPartnerGooglePlay": StarTransactionPartnerGooglePlayTypeID, "starTransactionPartnerFragment": StarTransactionPartnerFragmentTypeID, "starTransactionPartnerTelegramAds": StarTransactionPartnerTelegramAdsTypeID, "starTransactionPartnerBot": StarTransactionPartnerBotTypeID, + "starTransactionPartnerBusiness": StarTransactionPartnerBusinessTypeID, "starTransactionPartnerChannel": StarTransactionPartnerChannelTypeID, "starTransactionPartnerUser": StarTransactionPartnerUserTypeID, "starTransactionPartnerUnsupported": StarTransactionPartnerUnsupportedTypeID, @@ -2624,6 +2657,7 @@ func NamesMap() map[string]uint32 { "inviteLinkChatTypeBasicGroup": InviteLinkChatTypeBasicGroupTypeID, "inviteLinkChatTypeSupergroup": InviteLinkChatTypeSupergroupTypeID, "inviteLinkChatTypeChannel": InviteLinkChatTypeChannelTypeID, + "chatInviteLinkSubscriptionInfo": ChatInviteLinkSubscriptionInfoTypeID, "chatInviteLinkInfo": ChatInviteLinkInfoTypeID, "chatJoinRequest": ChatJoinRequestTypeID, "chatJoinRequests": ChatJoinRequestsTypeID, @@ -2655,6 +2689,8 @@ func NamesMap() map[string]uint32 { "forwardSource": ForwardSourceTypeID, "reactionTypeEmoji": ReactionTypeEmojiTypeID, "reactionTypeCustomEmoji": ReactionTypeCustomEmojiTypeID, + "reactionTypePaid": ReactionTypePaidTypeID, + "paidReactor": PaidReactorTypeID, "messageForwardInfo": MessageForwardInfoTypeID, "messageImportInfo": MessageImportInfoTypeID, "messageReplyInfo": MessageReplyInfoTypeID, @@ -3376,6 +3412,7 @@ func NamesMap() map[string]uint32 { "chatEventIsAllHistoryAvailableToggled": ChatEventIsAllHistoryAvailableToggledTypeID, "chatEventHasAggressiveAntiSpamEnabledToggled": ChatEventHasAggressiveAntiSpamEnabledToggledTypeID, "chatEventSignMessagesToggled": ChatEventSignMessagesToggledTypeID, + "chatEventShowMessageSenderToggled": ChatEventShowMessageSenderToggledTypeID, "chatEventInviteLinkEdited": ChatEventInviteLinkEditedTypeID, "chatEventInviteLinkRevoked": ChatEventInviteLinkRevokedTypeID, "chatEventInviteLinkDeleted": ChatEventInviteLinkDeletedTypeID, @@ -3484,6 +3521,7 @@ func NamesMap() map[string]uint32 { "telegramPaymentPurposePremiumGiveaway": TelegramPaymentPurposePremiumGiveawayTypeID, "telegramPaymentPurposeStars": TelegramPaymentPurposeStarsTypeID, "telegramPaymentPurposeGiftedStars": TelegramPaymentPurposeGiftedStarsTypeID, + "telegramPaymentPurposeJoinChat": TelegramPaymentPurposeJoinChatTypeID, "deviceTokenFirebaseCloudMessaging": DeviceTokenFirebaseCloudMessagingTypeID, "deviceTokenApplePush": DeviceTokenApplePushTypeID, "deviceTokenApplePushVoIP": DeviceTokenApplePushVoIPTypeID, @@ -3669,6 +3707,7 @@ func NamesMap() map[string]uint32 { "internalLinkTypeBotStart": InternalLinkTypeBotStartTypeID, "internalLinkTypeBotStartInGroup": InternalLinkTypeBotStartInGroupTypeID, "internalLinkTypeBusinessChat": InternalLinkTypeBusinessChatTypeID, + "internalLinkTypeBuyStars": InternalLinkTypeBuyStarsTypeID, "internalLinkTypeChangePhoneNumber": InternalLinkTypeChangePhoneNumberTypeID, "internalLinkTypeChatBoost": InternalLinkTypeChatBoostTypeID, "internalLinkTypeChatFolderInvite": InternalLinkTypeChatFolderInviteTypeID, @@ -3786,6 +3825,7 @@ func NamesMap() map[string]uint32 { "suggestedActionGiftPremiumForChristmas": SuggestedActionGiftPremiumForChristmasTypeID, "suggestedActionSetBirthdate": SuggestedActionSetBirthdateTypeID, "suggestedActionExtendPremium": SuggestedActionExtendPremiumTypeID, + "suggestedActionExtendStarSubscriptions": SuggestedActionExtendStarSubscriptionsTypeID, "count": CountTypeID, "text": TextTypeID, "seconds": SecondsTypeID, @@ -3957,6 +3997,7 @@ func NamesMap() map[string]uint32 { "updateAvailableMessageEffects": UpdateAvailableMessageEffectsTypeID, "updateDefaultReactionType": UpdateDefaultReactionTypeTypeID, "updateSavedMessagesTags": UpdateSavedMessagesTagsTypeID, + "updateActiveLiveLocationMessages": UpdateActiveLiveLocationMessagesTypeID, "updateOwnedStarCount": UpdateOwnedStarCountTypeID, "updateChatRevenueAmount": UpdateChatRevenueAmountTypeID, "updateStarRevenueStatus": UpdateStarRevenueStatusTypeID, @@ -4114,7 +4155,6 @@ func NamesMap() map[string]uint32 { "clearSearchedForTags": ClearSearchedForTagsRequestTypeID, "deleteAllCallMessages": DeleteAllCallMessagesRequestTypeID, "searchChatRecentLocationMessages": SearchChatRecentLocationMessagesRequestTypeID, - "getActiveLiveLocationMessages": GetActiveLiveLocationMessagesRequestTypeID, "getChatMessageByDate": GetChatMessageByDateRequestTypeID, "getChatSparseMessagePositions": GetChatSparseMessagePositionsRequestTypeID, "getChatMessageCalendar": GetChatMessageCalendarRequestTypeID, @@ -4197,6 +4237,9 @@ func NamesMap() map[string]uint32 { "clearRecentReactions": ClearRecentReactionsRequestTypeID, "addMessageReaction": AddMessageReactionRequestTypeID, "removeMessageReaction": RemoveMessageReactionRequestTypeID, + "addPaidMessageReaction": AddPaidMessageReactionRequestTypeID, + "removePendingPaidMessageReactions": RemovePendingPaidMessageReactionsRequestTypeID, + "togglePaidMessageReactionIsAnonymous": TogglePaidMessageReactionIsAnonymousRequestTypeID, "setMessageReactions": SetMessageReactionsRequestTypeID, "getMessageAddedReactions": GetMessageAddedReactionsRequestTypeID, "setDefaultReactionType": SetDefaultReactionTypeRequestTypeID, @@ -4409,7 +4452,9 @@ func NamesMap() map[string]uint32 { "importMessages": ImportMessagesRequestTypeID, "replacePrimaryChatInviteLink": ReplacePrimaryChatInviteLinkRequestTypeID, "createChatInviteLink": CreateChatInviteLinkRequestTypeID, + "createChatSubscriptionInviteLink": CreateChatSubscriptionInviteLinkRequestTypeID, "editChatInviteLink": EditChatInviteLinkRequestTypeID, + "editChatSubscriptionInviteLink": EditChatSubscriptionInviteLinkRequestTypeID, "getChatInviteLink": GetChatInviteLinkRequestTypeID, "getChatInviteLinkCounts": GetChatInviteLinkCountsRequestTypeID, "getChatInviteLinks": GetChatInviteLinksRequestTypeID, @@ -4728,9 +4773,12 @@ func NamesMap() map[string]uint32 { "getStarPaymentOptions": GetStarPaymentOptionsRequestTypeID, "getStarGiftPaymentOptions": GetStarGiftPaymentOptionsRequestTypeID, "getStarTransactions": GetStarTransactionsRequestTypeID, + "getStarSubscriptions": GetStarSubscriptionsRequestTypeID, "canPurchaseFromStore": CanPurchaseFromStoreRequestTypeID, "assignAppStoreTransaction": AssignAppStoreTransactionRequestTypeID, "assignGooglePlayTransaction": AssignGooglePlayTransactionRequestTypeID, + "editStarSubscription": EditStarSubscriptionRequestTypeID, + "reuseStarSubscription": ReuseStarSubscriptionRequestTypeID, "getBusinessFeatures": GetBusinessFeaturesRequestTypeID, "acceptTermsOfService": AcceptTermsOfServiceRequestTypeID, "searchStringsByPrefix": SearchStringsByPrefixRequestTypeID, @@ -4926,6 +4974,9 @@ func TypesConstructorMap() map[uint32]func() bin.Object { InputChatPhotoStickerTypeID: func() bin.Object { return &InputChatPhotoSticker{} }, ChatPermissionsTypeID: func() bin.Object { return &ChatPermissions{} }, ChatAdministratorRightsTypeID: func() bin.Object { return &ChatAdministratorRights{} }, + StarSubscriptionPricingTypeID: func() bin.Object { return &StarSubscriptionPricing{} }, + StarSubscriptionTypeID: func() bin.Object { return &StarSubscription{} }, + StarSubscriptionsTypeID: func() bin.Object { return &StarSubscriptions{} }, ProductInfoTypeID: func() bin.Object { return &ProductInfo{} }, PremiumPaymentOptionTypeID: func() bin.Object { return &PremiumPaymentOption{} }, PremiumStatePaymentOptionTypeID: func() bin.Object { return &PremiumStatePaymentOption{} }, @@ -4936,12 +4987,18 @@ func TypesConstructorMap() map[uint32]func() bin.Object { StarPaymentOptionsTypeID: func() bin.Object { return &StarPaymentOptions{} }, StarTransactionDirectionIncomingTypeID: func() bin.Object { return &StarTransactionDirectionIncoming{} }, StarTransactionDirectionOutgoingTypeID: func() bin.Object { return &StarTransactionDirectionOutgoing{} }, + BotTransactionPurposePaidMediaTypeID: func() bin.Object { return &BotTransactionPurposePaidMedia{} }, + BotTransactionPurposeInvoicePaymentTypeID: func() bin.Object { return &BotTransactionPurposeInvoicePayment{} }, + ChannelTransactionPurposePaidMediaTypeID: func() bin.Object { return &ChannelTransactionPurposePaidMedia{} }, + ChannelTransactionPurposeJoinTypeID: func() bin.Object { return &ChannelTransactionPurposeJoin{} }, + ChannelTransactionPurposeReactionTypeID: func() bin.Object { return &ChannelTransactionPurposeReaction{} }, StarTransactionPartnerTelegramTypeID: func() bin.Object { return &StarTransactionPartnerTelegram{} }, StarTransactionPartnerAppStoreTypeID: func() bin.Object { return &StarTransactionPartnerAppStore{} }, StarTransactionPartnerGooglePlayTypeID: func() bin.Object { return &StarTransactionPartnerGooglePlay{} }, StarTransactionPartnerFragmentTypeID: func() bin.Object { return &StarTransactionPartnerFragment{} }, StarTransactionPartnerTelegramAdsTypeID: func() bin.Object { return &StarTransactionPartnerTelegramAds{} }, StarTransactionPartnerBotTypeID: func() bin.Object { return &StarTransactionPartnerBot{} }, + StarTransactionPartnerBusinessTypeID: func() bin.Object { return &StarTransactionPartnerBusiness{} }, StarTransactionPartnerChannelTypeID: func() bin.Object { return &StarTransactionPartnerChannel{} }, StarTransactionPartnerUserTypeID: func() bin.Object { return &StarTransactionPartnerUser{} }, StarTransactionPartnerUnsupportedTypeID: func() bin.Object { return &StarTransactionPartnerUnsupported{} }, @@ -4999,6 +5056,7 @@ func TypesConstructorMap() map[uint32]func() bin.Object { InviteLinkChatTypeBasicGroupTypeID: func() bin.Object { return &InviteLinkChatTypeBasicGroup{} }, InviteLinkChatTypeSupergroupTypeID: func() bin.Object { return &InviteLinkChatTypeSupergroup{} }, InviteLinkChatTypeChannelTypeID: func() bin.Object { return &InviteLinkChatTypeChannel{} }, + ChatInviteLinkSubscriptionInfoTypeID: func() bin.Object { return &ChatInviteLinkSubscriptionInfo{} }, ChatInviteLinkInfoTypeID: func() bin.Object { return &ChatInviteLinkInfo{} }, ChatJoinRequestTypeID: func() bin.Object { return &ChatJoinRequest{} }, ChatJoinRequestsTypeID: func() bin.Object { return &ChatJoinRequests{} }, @@ -5030,6 +5088,8 @@ func TypesConstructorMap() map[uint32]func() bin.Object { ForwardSourceTypeID: func() bin.Object { return &ForwardSource{} }, ReactionTypeEmojiTypeID: func() bin.Object { return &ReactionTypeEmoji{} }, ReactionTypeCustomEmojiTypeID: func() bin.Object { return &ReactionTypeCustomEmoji{} }, + ReactionTypePaidTypeID: func() bin.Object { return &ReactionTypePaid{} }, + PaidReactorTypeID: func() bin.Object { return &PaidReactor{} }, MessageForwardInfoTypeID: func() bin.Object { return &MessageForwardInfo{} }, MessageImportInfoTypeID: func() bin.Object { return &MessageImportInfo{} }, MessageReplyInfoTypeID: func() bin.Object { return &MessageReplyInfo{} }, @@ -5751,6 +5811,7 @@ func TypesConstructorMap() map[uint32]func() bin.Object { ChatEventIsAllHistoryAvailableToggledTypeID: func() bin.Object { return &ChatEventIsAllHistoryAvailableToggled{} }, ChatEventHasAggressiveAntiSpamEnabledToggledTypeID: func() bin.Object { return &ChatEventHasAggressiveAntiSpamEnabledToggled{} }, ChatEventSignMessagesToggledTypeID: func() bin.Object { return &ChatEventSignMessagesToggled{} }, + ChatEventShowMessageSenderToggledTypeID: func() bin.Object { return &ChatEventShowMessageSenderToggled{} }, ChatEventInviteLinkEditedTypeID: func() bin.Object { return &ChatEventInviteLinkEdited{} }, ChatEventInviteLinkRevokedTypeID: func() bin.Object { return &ChatEventInviteLinkRevoked{} }, ChatEventInviteLinkDeletedTypeID: func() bin.Object { return &ChatEventInviteLinkDeleted{} }, @@ -5859,6 +5920,7 @@ func TypesConstructorMap() map[uint32]func() bin.Object { TelegramPaymentPurposePremiumGiveawayTypeID: func() bin.Object { return &TelegramPaymentPurposePremiumGiveaway{} }, TelegramPaymentPurposeStarsTypeID: func() bin.Object { return &TelegramPaymentPurposeStars{} }, TelegramPaymentPurposeGiftedStarsTypeID: func() bin.Object { return &TelegramPaymentPurposeGiftedStars{} }, + TelegramPaymentPurposeJoinChatTypeID: func() bin.Object { return &TelegramPaymentPurposeJoinChat{} }, DeviceTokenFirebaseCloudMessagingTypeID: func() bin.Object { return &DeviceTokenFirebaseCloudMessaging{} }, DeviceTokenApplePushTypeID: func() bin.Object { return &DeviceTokenApplePush{} }, DeviceTokenApplePushVoIPTypeID: func() bin.Object { return &DeviceTokenApplePushVoIP{} }, @@ -6044,6 +6106,7 @@ func TypesConstructorMap() map[uint32]func() bin.Object { InternalLinkTypeBotStartTypeID: func() bin.Object { return &InternalLinkTypeBotStart{} }, InternalLinkTypeBotStartInGroupTypeID: func() bin.Object { return &InternalLinkTypeBotStartInGroup{} }, InternalLinkTypeBusinessChatTypeID: func() bin.Object { return &InternalLinkTypeBusinessChat{} }, + InternalLinkTypeBuyStarsTypeID: func() bin.Object { return &InternalLinkTypeBuyStars{} }, InternalLinkTypeChangePhoneNumberTypeID: func() bin.Object { return &InternalLinkTypeChangePhoneNumber{} }, InternalLinkTypeChatBoostTypeID: func() bin.Object { return &InternalLinkTypeChatBoost{} }, InternalLinkTypeChatFolderInviteTypeID: func() bin.Object { return &InternalLinkTypeChatFolderInvite{} }, @@ -6161,998 +6224,1007 @@ func TypesConstructorMap() map[uint32]func() bin.Object { SuggestedActionGiftPremiumForChristmasTypeID: func() bin.Object { return &SuggestedActionGiftPremiumForChristmas{} }, SuggestedActionSetBirthdateTypeID: func() bin.Object { return &SuggestedActionSetBirthdate{} }, SuggestedActionExtendPremiumTypeID: func() bin.Object { return &SuggestedActionExtendPremium{} }, - CountTypeID: func() bin.Object { return &Count{} }, - TextTypeID: func() bin.Object { return &Text{} }, - SecondsTypeID: func() bin.Object { return &Seconds{} }, - FileDownloadedPrefixSizeTypeID: func() bin.Object { return &FileDownloadedPrefixSize{} }, - DeepLinkInfoTypeID: func() bin.Object { return &DeepLinkInfo{} }, - TextParseModeMarkdownTypeID: func() bin.Object { return &TextParseModeMarkdown{} }, - TextParseModeHTMLTypeID: func() bin.Object { return &TextParseModeHTML{} }, - ProxyTypeSocks5TypeID: func() bin.Object { return &ProxyTypeSocks5{} }, - ProxyTypeHTTPTypeID: func() bin.Object { return &ProxyTypeHTTP{} }, - ProxyTypeMtprotoTypeID: func() bin.Object { return &ProxyTypeMtproto{} }, - ProxyTypeID: func() bin.Object { return &Proxy{} }, - ProxiesTypeID: func() bin.Object { return &Proxies{} }, - InputStickerTypeID: func() bin.Object { return &InputSticker{} }, - DateRangeTypeID: func() bin.Object { return &DateRange{} }, - StatisticalValueTypeID: func() bin.Object { return &StatisticalValue{} }, - StatisticalGraphDataTypeID: func() bin.Object { return &StatisticalGraphData{} }, - StatisticalGraphAsyncTypeID: func() bin.Object { return &StatisticalGraphAsync{} }, - StatisticalGraphErrorTypeID: func() bin.Object { return &StatisticalGraphError{} }, - ChatStatisticsObjectTypeMessageTypeID: func() bin.Object { return &ChatStatisticsObjectTypeMessage{} }, - ChatStatisticsObjectTypeStoryTypeID: func() bin.Object { return &ChatStatisticsObjectTypeStory{} }, - ChatStatisticsInteractionInfoTypeID: func() bin.Object { return &ChatStatisticsInteractionInfo{} }, - ChatStatisticsMessageSenderInfoTypeID: func() bin.Object { return &ChatStatisticsMessageSenderInfo{} }, - ChatStatisticsAdministratorActionsInfoTypeID: func() bin.Object { return &ChatStatisticsAdministratorActionsInfo{} }, - ChatStatisticsInviterInfoTypeID: func() bin.Object { return &ChatStatisticsInviterInfo{} }, - ChatStatisticsSupergroupTypeID: func() bin.Object { return &ChatStatisticsSupergroup{} }, - ChatStatisticsChannelTypeID: func() bin.Object { return &ChatStatisticsChannel{} }, - ChatRevenueAmountTypeID: func() bin.Object { return &ChatRevenueAmount{} }, - ChatRevenueStatisticsTypeID: func() bin.Object { return &ChatRevenueStatistics{} }, - MessageStatisticsTypeID: func() bin.Object { return &MessageStatistics{} }, - StoryStatisticsTypeID: func() bin.Object { return &StoryStatistics{} }, - RevenueWithdrawalStatePendingTypeID: func() bin.Object { return &RevenueWithdrawalStatePending{} }, - RevenueWithdrawalStateSucceededTypeID: func() bin.Object { return &RevenueWithdrawalStateSucceeded{} }, - RevenueWithdrawalStateFailedTypeID: func() bin.Object { return &RevenueWithdrawalStateFailed{} }, - ChatRevenueTransactionTypeEarningsTypeID: func() bin.Object { return &ChatRevenueTransactionTypeEarnings{} }, - ChatRevenueTransactionTypeWithdrawalTypeID: func() bin.Object { return &ChatRevenueTransactionTypeWithdrawal{} }, - ChatRevenueTransactionTypeRefundTypeID: func() bin.Object { return &ChatRevenueTransactionTypeRefund{} }, - ChatRevenueTransactionTypeID: func() bin.Object { return &ChatRevenueTransaction{} }, - ChatRevenueTransactionsTypeID: func() bin.Object { return &ChatRevenueTransactions{} }, - StarRevenueStatusTypeID: func() bin.Object { return &StarRevenueStatus{} }, - StarRevenueStatisticsTypeID: func() bin.Object { return &StarRevenueStatistics{} }, - PointTypeID: func() bin.Object { return &Point{} }, - VectorPathCommandLineTypeID: func() bin.Object { return &VectorPathCommandLine{} }, - VectorPathCommandCubicBezierCurveTypeID: func() bin.Object { return &VectorPathCommandCubicBezierCurve{} }, - BotCommandScopeDefaultTypeID: func() bin.Object { return &BotCommandScopeDefault{} }, - BotCommandScopeAllPrivateChatsTypeID: func() bin.Object { return &BotCommandScopeAllPrivateChats{} }, - BotCommandScopeAllGroupChatsTypeID: func() bin.Object { return &BotCommandScopeAllGroupChats{} }, - BotCommandScopeAllChatAdministratorsTypeID: func() bin.Object { return &BotCommandScopeAllChatAdministrators{} }, - BotCommandScopeChatTypeID: func() bin.Object { return &BotCommandScopeChat{} }, - BotCommandScopeChatAdministratorsTypeID: func() bin.Object { return &BotCommandScopeChatAdministrators{} }, - BotCommandScopeChatMemberTypeID: func() bin.Object { return &BotCommandScopeChatMember{} }, - PhoneNumberCodeTypeChangeTypeID: func() bin.Object { return &PhoneNumberCodeTypeChange{} }, - PhoneNumberCodeTypeVerifyTypeID: func() bin.Object { return &PhoneNumberCodeTypeVerify{} }, - PhoneNumberCodeTypeConfirmOwnershipTypeID: func() bin.Object { return &PhoneNumberCodeTypeConfirmOwnership{} }, - UpdateAuthorizationStateTypeID: func() bin.Object { return &UpdateAuthorizationState{} }, - UpdateNewMessageTypeID: func() bin.Object { return &UpdateNewMessage{} }, - UpdateMessageSendAcknowledgedTypeID: func() bin.Object { return &UpdateMessageSendAcknowledged{} }, - UpdateMessageSendSucceededTypeID: func() bin.Object { return &UpdateMessageSendSucceeded{} }, - UpdateMessageSendFailedTypeID: func() bin.Object { return &UpdateMessageSendFailed{} }, - UpdateMessageContentTypeID: func() bin.Object { return &UpdateMessageContent{} }, - UpdateMessageEditedTypeID: func() bin.Object { return &UpdateMessageEdited{} }, - UpdateMessageIsPinnedTypeID: func() bin.Object { return &UpdateMessageIsPinned{} }, - UpdateMessageInteractionInfoTypeID: func() bin.Object { return &UpdateMessageInteractionInfo{} }, - UpdateMessageContentOpenedTypeID: func() bin.Object { return &UpdateMessageContentOpened{} }, - UpdateMessageMentionReadTypeID: func() bin.Object { return &UpdateMessageMentionRead{} }, - UpdateMessageUnreadReactionsTypeID: func() bin.Object { return &UpdateMessageUnreadReactions{} }, - UpdateMessageFactCheckTypeID: func() bin.Object { return &UpdateMessageFactCheck{} }, - UpdateMessageLiveLocationViewedTypeID: func() bin.Object { return &UpdateMessageLiveLocationViewed{} }, - UpdateNewChatTypeID: func() bin.Object { return &UpdateNewChat{} }, - UpdateChatTitleTypeID: func() bin.Object { return &UpdateChatTitle{} }, - UpdateChatPhotoTypeID: func() bin.Object { return &UpdateChatPhoto{} }, - UpdateChatAccentColorsTypeID: func() bin.Object { return &UpdateChatAccentColors{} }, - UpdateChatPermissionsTypeID: func() bin.Object { return &UpdateChatPermissions{} }, - UpdateChatLastMessageTypeID: func() bin.Object { return &UpdateChatLastMessage{} }, - UpdateChatPositionTypeID: func() bin.Object { return &UpdateChatPosition{} }, - UpdateChatAddedToListTypeID: func() bin.Object { return &UpdateChatAddedToList{} }, - UpdateChatRemovedFromListTypeID: func() bin.Object { return &UpdateChatRemovedFromList{} }, - UpdateChatReadInboxTypeID: func() bin.Object { return &UpdateChatReadInbox{} }, - UpdateChatReadOutboxTypeID: func() bin.Object { return &UpdateChatReadOutbox{} }, - UpdateChatActionBarTypeID: func() bin.Object { return &UpdateChatActionBar{} }, - UpdateChatBusinessBotManageBarTypeID: func() bin.Object { return &UpdateChatBusinessBotManageBar{} }, - UpdateChatAvailableReactionsTypeID: func() bin.Object { return &UpdateChatAvailableReactions{} }, - UpdateChatDraftMessageTypeID: func() bin.Object { return &UpdateChatDraftMessage{} }, - UpdateChatEmojiStatusTypeID: func() bin.Object { return &UpdateChatEmojiStatus{} }, - UpdateChatMessageSenderTypeID: func() bin.Object { return &UpdateChatMessageSender{} }, - UpdateChatMessageAutoDeleteTimeTypeID: func() bin.Object { return &UpdateChatMessageAutoDeleteTime{} }, - UpdateChatNotificationSettingsTypeID: func() bin.Object { return &UpdateChatNotificationSettings{} }, - UpdateChatPendingJoinRequestsTypeID: func() bin.Object { return &UpdateChatPendingJoinRequests{} }, - UpdateChatReplyMarkupTypeID: func() bin.Object { return &UpdateChatReplyMarkup{} }, - UpdateChatBackgroundTypeID: func() bin.Object { return &UpdateChatBackground{} }, - UpdateChatThemeTypeID: func() bin.Object { return &UpdateChatTheme{} }, - UpdateChatUnreadMentionCountTypeID: func() bin.Object { return &UpdateChatUnreadMentionCount{} }, - UpdateChatUnreadReactionCountTypeID: func() bin.Object { return &UpdateChatUnreadReactionCount{} }, - UpdateChatVideoChatTypeID: func() bin.Object { return &UpdateChatVideoChat{} }, - UpdateChatDefaultDisableNotificationTypeID: func() bin.Object { return &UpdateChatDefaultDisableNotification{} }, - UpdateChatHasProtectedContentTypeID: func() bin.Object { return &UpdateChatHasProtectedContent{} }, - UpdateChatIsTranslatableTypeID: func() bin.Object { return &UpdateChatIsTranslatable{} }, - UpdateChatIsMarkedAsUnreadTypeID: func() bin.Object { return &UpdateChatIsMarkedAsUnread{} }, - UpdateChatViewAsTopicsTypeID: func() bin.Object { return &UpdateChatViewAsTopics{} }, - UpdateChatBlockListTypeID: func() bin.Object { return &UpdateChatBlockList{} }, - UpdateChatHasScheduledMessagesTypeID: func() bin.Object { return &UpdateChatHasScheduledMessages{} }, - UpdateChatFoldersTypeID: func() bin.Object { return &UpdateChatFolders{} }, - UpdateChatOnlineMemberCountTypeID: func() bin.Object { return &UpdateChatOnlineMemberCount{} }, - UpdateSavedMessagesTopicTypeID: func() bin.Object { return &UpdateSavedMessagesTopic{} }, - UpdateSavedMessagesTopicCountTypeID: func() bin.Object { return &UpdateSavedMessagesTopicCount{} }, - UpdateQuickReplyShortcutTypeID: func() bin.Object { return &UpdateQuickReplyShortcut{} }, - UpdateQuickReplyShortcutDeletedTypeID: func() bin.Object { return &UpdateQuickReplyShortcutDeleted{} }, - UpdateQuickReplyShortcutsTypeID: func() bin.Object { return &UpdateQuickReplyShortcuts{} }, - UpdateQuickReplyShortcutMessagesTypeID: func() bin.Object { return &UpdateQuickReplyShortcutMessages{} }, - UpdateForumTopicInfoTypeID: func() bin.Object { return &UpdateForumTopicInfo{} }, - UpdateScopeNotificationSettingsTypeID: func() bin.Object { return &UpdateScopeNotificationSettings{} }, - UpdateReactionNotificationSettingsTypeID: func() bin.Object { return &UpdateReactionNotificationSettings{} }, - UpdateNotificationTypeID: func() bin.Object { return &UpdateNotification{} }, - UpdateNotificationGroupTypeID: func() bin.Object { return &UpdateNotificationGroup{} }, - UpdateActiveNotificationsTypeID: func() bin.Object { return &UpdateActiveNotifications{} }, - UpdateHavePendingNotificationsTypeID: func() bin.Object { return &UpdateHavePendingNotifications{} }, - UpdateDeleteMessagesTypeID: func() bin.Object { return &UpdateDeleteMessages{} }, - UpdateChatActionTypeID: func() bin.Object { return &UpdateChatAction{} }, - UpdateUserStatusTypeID: func() bin.Object { return &UpdateUserStatus{} }, - UpdateUserTypeID: func() bin.Object { return &UpdateUser{} }, - UpdateBasicGroupTypeID: func() bin.Object { return &UpdateBasicGroup{} }, - UpdateSupergroupTypeID: func() bin.Object { return &UpdateSupergroup{} }, - UpdateSecretChatTypeID: func() bin.Object { return &UpdateSecretChat{} }, - UpdateUserFullInfoTypeID: func() bin.Object { return &UpdateUserFullInfo{} }, - UpdateBasicGroupFullInfoTypeID: func() bin.Object { return &UpdateBasicGroupFullInfo{} }, - UpdateSupergroupFullInfoTypeID: func() bin.Object { return &UpdateSupergroupFullInfo{} }, - UpdateServiceNotificationTypeID: func() bin.Object { return &UpdateServiceNotification{} }, - UpdateFileTypeID: func() bin.Object { return &UpdateFile{} }, - UpdateFileGenerationStartTypeID: func() bin.Object { return &UpdateFileGenerationStart{} }, - UpdateFileGenerationStopTypeID: func() bin.Object { return &UpdateFileGenerationStop{} }, - UpdateFileDownloadsTypeID: func() bin.Object { return &UpdateFileDownloads{} }, - UpdateFileAddedToDownloadsTypeID: func() bin.Object { return &UpdateFileAddedToDownloads{} }, - UpdateFileDownloadTypeID: func() bin.Object { return &UpdateFileDownload{} }, - UpdateFileRemovedFromDownloadsTypeID: func() bin.Object { return &UpdateFileRemovedFromDownloads{} }, - UpdateApplicationVerificationRequiredTypeID: func() bin.Object { return &UpdateApplicationVerificationRequired{} }, - UpdateCallTypeID: func() bin.Object { return &UpdateCall{} }, - UpdateGroupCallTypeID: func() bin.Object { return &UpdateGroupCall{} }, - UpdateGroupCallParticipantTypeID: func() bin.Object { return &UpdateGroupCallParticipant{} }, - UpdateNewCallSignalingDataTypeID: func() bin.Object { return &UpdateNewCallSignalingData{} }, - UpdateUserPrivacySettingRulesTypeID: func() bin.Object { return &UpdateUserPrivacySettingRules{} }, - UpdateUnreadMessageCountTypeID: func() bin.Object { return &UpdateUnreadMessageCount{} }, - UpdateUnreadChatCountTypeID: func() bin.Object { return &UpdateUnreadChatCount{} }, - UpdateStoryTypeID: func() bin.Object { return &UpdateStory{} }, - UpdateStoryDeletedTypeID: func() bin.Object { return &UpdateStoryDeleted{} }, - UpdateStorySendSucceededTypeID: func() bin.Object { return &UpdateStorySendSucceeded{} }, - UpdateStorySendFailedTypeID: func() bin.Object { return &UpdateStorySendFailed{} }, - UpdateChatActiveStoriesTypeID: func() bin.Object { return &UpdateChatActiveStories{} }, - UpdateStoryListChatCountTypeID: func() bin.Object { return &UpdateStoryListChatCount{} }, - UpdateStoryStealthModeTypeID: func() bin.Object { return &UpdateStoryStealthMode{} }, - UpdateOptionTypeID: func() bin.Object { return &UpdateOption{} }, - UpdateStickerSetTypeID: func() bin.Object { return &UpdateStickerSet{} }, - UpdateInstalledStickerSetsTypeID: func() bin.Object { return &UpdateInstalledStickerSets{} }, - UpdateTrendingStickerSetsTypeID: func() bin.Object { return &UpdateTrendingStickerSets{} }, - UpdateRecentStickersTypeID: func() bin.Object { return &UpdateRecentStickers{} }, - UpdateFavoriteStickersTypeID: func() bin.Object { return &UpdateFavoriteStickers{} }, - UpdateSavedAnimationsTypeID: func() bin.Object { return &UpdateSavedAnimations{} }, - UpdateSavedNotificationSoundsTypeID: func() bin.Object { return &UpdateSavedNotificationSounds{} }, - UpdateDefaultBackgroundTypeID: func() bin.Object { return &UpdateDefaultBackground{} }, - UpdateChatThemesTypeID: func() bin.Object { return &UpdateChatThemes{} }, - UpdateAccentColorsTypeID: func() bin.Object { return &UpdateAccentColors{} }, - UpdateProfileAccentColorsTypeID: func() bin.Object { return &UpdateProfileAccentColors{} }, - UpdateLanguagePackStringsTypeID: func() bin.Object { return &UpdateLanguagePackStrings{} }, - UpdateConnectionStateTypeID: func() bin.Object { return &UpdateConnectionState{} }, - UpdateTermsOfServiceTypeID: func() bin.Object { return &UpdateTermsOfService{} }, - UpdateUsersNearbyTypeID: func() bin.Object { return &UpdateUsersNearby{} }, - UpdateUnconfirmedSessionTypeID: func() bin.Object { return &UpdateUnconfirmedSession{} }, - UpdateAttachmentMenuBotsTypeID: func() bin.Object { return &UpdateAttachmentMenuBots{} }, - UpdateWebAppMessageSentTypeID: func() bin.Object { return &UpdateWebAppMessageSent{} }, - UpdateActiveEmojiReactionsTypeID: func() bin.Object { return &UpdateActiveEmojiReactions{} }, - UpdateAvailableMessageEffectsTypeID: func() bin.Object { return &UpdateAvailableMessageEffects{} }, - UpdateDefaultReactionTypeTypeID: func() bin.Object { return &UpdateDefaultReactionType{} }, - UpdateSavedMessagesTagsTypeID: func() bin.Object { return &UpdateSavedMessagesTags{} }, - UpdateOwnedStarCountTypeID: func() bin.Object { return &UpdateOwnedStarCount{} }, - UpdateChatRevenueAmountTypeID: func() bin.Object { return &UpdateChatRevenueAmount{} }, - UpdateStarRevenueStatusTypeID: func() bin.Object { return &UpdateStarRevenueStatus{} }, - UpdateSpeechRecognitionTrialTypeID: func() bin.Object { return &UpdateSpeechRecognitionTrial{} }, - UpdateDiceEmojisTypeID: func() bin.Object { return &UpdateDiceEmojis{} }, - UpdateAnimatedEmojiMessageClickedTypeID: func() bin.Object { return &UpdateAnimatedEmojiMessageClicked{} }, - UpdateAnimationSearchParametersTypeID: func() bin.Object { return &UpdateAnimationSearchParameters{} }, - UpdateSuggestedActionsTypeID: func() bin.Object { return &UpdateSuggestedActions{} }, - UpdateSpeedLimitNotificationTypeID: func() bin.Object { return &UpdateSpeedLimitNotification{} }, - UpdateContactCloseBirthdaysTypeID: func() bin.Object { return &UpdateContactCloseBirthdays{} }, - UpdateAutosaveSettingsTypeID: func() bin.Object { return &UpdateAutosaveSettings{} }, - UpdateBusinessConnectionTypeID: func() bin.Object { return &UpdateBusinessConnection{} }, - UpdateNewBusinessMessageTypeID: func() bin.Object { return &UpdateNewBusinessMessage{} }, - UpdateBusinessMessageEditedTypeID: func() bin.Object { return &UpdateBusinessMessageEdited{} }, - UpdateBusinessMessagesDeletedTypeID: func() bin.Object { return &UpdateBusinessMessagesDeleted{} }, - UpdateNewInlineQueryTypeID: func() bin.Object { return &UpdateNewInlineQuery{} }, - UpdateNewChosenInlineResultTypeID: func() bin.Object { return &UpdateNewChosenInlineResult{} }, - UpdateNewCallbackQueryTypeID: func() bin.Object { return &UpdateNewCallbackQuery{} }, - UpdateNewInlineCallbackQueryTypeID: func() bin.Object { return &UpdateNewInlineCallbackQuery{} }, - UpdateNewBusinessCallbackQueryTypeID: func() bin.Object { return &UpdateNewBusinessCallbackQuery{} }, - UpdateNewShippingQueryTypeID: func() bin.Object { return &UpdateNewShippingQuery{} }, - UpdateNewPreCheckoutQueryTypeID: func() bin.Object { return &UpdateNewPreCheckoutQuery{} }, - UpdateNewCustomEventTypeID: func() bin.Object { return &UpdateNewCustomEvent{} }, - UpdateNewCustomQueryTypeID: func() bin.Object { return &UpdateNewCustomQuery{} }, - UpdatePollTypeID: func() bin.Object { return &UpdatePoll{} }, - UpdatePollAnswerTypeID: func() bin.Object { return &UpdatePollAnswer{} }, - UpdateChatMemberTypeID: func() bin.Object { return &UpdateChatMember{} }, - UpdateNewChatJoinRequestTypeID: func() bin.Object { return &UpdateNewChatJoinRequest{} }, - UpdateChatBoostTypeID: func() bin.Object { return &UpdateChatBoost{} }, - UpdateMessageReactionTypeID: func() bin.Object { return &UpdateMessageReaction{} }, - UpdateMessageReactionsTypeID: func() bin.Object { return &UpdateMessageReactions{} }, - UpdatesTypeID: func() bin.Object { return &Updates{} }, - LogStreamDefaultTypeID: func() bin.Object { return &LogStreamDefault{} }, - LogStreamFileTypeID: func() bin.Object { return &LogStreamFile{} }, - LogStreamEmptyTypeID: func() bin.Object { return &LogStreamEmpty{} }, - LogVerbosityLevelTypeID: func() bin.Object { return &LogVerbosityLevel{} }, - LogTagsTypeID: func() bin.Object { return &LogTags{} }, - UserSupportInfoTypeID: func() bin.Object { return &UserSupportInfo{} }, - TestIntTypeID: func() bin.Object { return &TestInt{} }, - TestStringTypeID: func() bin.Object { return &TestString{} }, - TestBytesTypeID: func() bin.Object { return &TestBytes{} }, - TestVectorIntTypeID: func() bin.Object { return &TestVectorInt{} }, - TestVectorIntObjectTypeID: func() bin.Object { return &TestVectorIntObject{} }, - TestVectorStringTypeID: func() bin.Object { return &TestVectorString{} }, - TestVectorStringObjectTypeID: func() bin.Object { return &TestVectorStringObject{} }, - GetAuthorizationStateRequestTypeID: func() bin.Object { return &GetAuthorizationStateRequest{} }, - SetTdlibParametersRequestTypeID: func() bin.Object { return &SetTdlibParametersRequest{} }, - SetAuthenticationPhoneNumberRequestTypeID: func() bin.Object { return &SetAuthenticationPhoneNumberRequest{} }, - SetAuthenticationEmailAddressRequestTypeID: func() bin.Object { return &SetAuthenticationEmailAddressRequest{} }, - ResendAuthenticationCodeRequestTypeID: func() bin.Object { return &ResendAuthenticationCodeRequest{} }, - CheckAuthenticationEmailCodeRequestTypeID: func() bin.Object { return &CheckAuthenticationEmailCodeRequest{} }, - CheckAuthenticationCodeRequestTypeID: func() bin.Object { return &CheckAuthenticationCodeRequest{} }, - RequestQrCodeAuthenticationRequestTypeID: func() bin.Object { return &RequestQrCodeAuthenticationRequest{} }, - RegisterUserRequestTypeID: func() bin.Object { return &RegisterUserRequest{} }, - ResetAuthenticationEmailAddressRequestTypeID: func() bin.Object { return &ResetAuthenticationEmailAddressRequest{} }, - CheckAuthenticationPasswordRequestTypeID: func() bin.Object { return &CheckAuthenticationPasswordRequest{} }, - RequestAuthenticationPasswordRecoveryRequestTypeID: func() bin.Object { return &RequestAuthenticationPasswordRecoveryRequest{} }, - CheckAuthenticationPasswordRecoveryCodeRequestTypeID: func() bin.Object { return &CheckAuthenticationPasswordRecoveryCodeRequest{} }, - RecoverAuthenticationPasswordRequestTypeID: func() bin.Object { return &RecoverAuthenticationPasswordRequest{} }, - SendAuthenticationFirebaseSMSRequestTypeID: func() bin.Object { return &SendAuthenticationFirebaseSMSRequest{} }, - ReportAuthenticationCodeMissingRequestTypeID: func() bin.Object { return &ReportAuthenticationCodeMissingRequest{} }, - CheckAuthenticationBotTokenRequestTypeID: func() bin.Object { return &CheckAuthenticationBotTokenRequest{} }, - LogOutRequestTypeID: func() bin.Object { return &LogOutRequest{} }, - CloseRequestTypeID: func() bin.Object { return &CloseRequest{} }, - DestroyRequestTypeID: func() bin.Object { return &DestroyRequest{} }, - ConfirmQrCodeAuthenticationRequestTypeID: func() bin.Object { return &ConfirmQrCodeAuthenticationRequest{} }, - GetCurrentStateRequestTypeID: func() bin.Object { return &GetCurrentStateRequest{} }, - SetDatabaseEncryptionKeyRequestTypeID: func() bin.Object { return &SetDatabaseEncryptionKeyRequest{} }, - GetPasswordStateRequestTypeID: func() bin.Object { return &GetPasswordStateRequest{} }, - SetPasswordRequestTypeID: func() bin.Object { return &SetPasswordRequest{} }, - SetLoginEmailAddressRequestTypeID: func() bin.Object { return &SetLoginEmailAddressRequest{} }, - ResendLoginEmailAddressCodeRequestTypeID: func() bin.Object { return &ResendLoginEmailAddressCodeRequest{} }, - CheckLoginEmailAddressCodeRequestTypeID: func() bin.Object { return &CheckLoginEmailAddressCodeRequest{} }, - GetRecoveryEmailAddressRequestTypeID: func() bin.Object { return &GetRecoveryEmailAddressRequest{} }, - SetRecoveryEmailAddressRequestTypeID: func() bin.Object { return &SetRecoveryEmailAddressRequest{} }, - CheckRecoveryEmailAddressCodeRequestTypeID: func() bin.Object { return &CheckRecoveryEmailAddressCodeRequest{} }, - ResendRecoveryEmailAddressCodeRequestTypeID: func() bin.Object { return &ResendRecoveryEmailAddressCodeRequest{} }, - CancelRecoveryEmailAddressVerificationRequestTypeID: func() bin.Object { return &CancelRecoveryEmailAddressVerificationRequest{} }, - RequestPasswordRecoveryRequestTypeID: func() bin.Object { return &RequestPasswordRecoveryRequest{} }, - CheckPasswordRecoveryCodeRequestTypeID: func() bin.Object { return &CheckPasswordRecoveryCodeRequest{} }, - RecoverPasswordRequestTypeID: func() bin.Object { return &RecoverPasswordRequest{} }, - ResetPasswordRequestTypeID: func() bin.Object { return &ResetPasswordRequest{} }, - CancelPasswordResetRequestTypeID: func() bin.Object { return &CancelPasswordResetRequest{} }, - CreateTemporaryPasswordRequestTypeID: func() bin.Object { return &CreateTemporaryPasswordRequest{} }, - GetTemporaryPasswordStateRequestTypeID: func() bin.Object { return &GetTemporaryPasswordStateRequest{} }, - GetMeRequestTypeID: func() bin.Object { return &GetMeRequest{} }, - GetUserRequestTypeID: func() bin.Object { return &GetUserRequest{} }, - GetUserFullInfoRequestTypeID: func() bin.Object { return &GetUserFullInfoRequest{} }, - GetBasicGroupRequestTypeID: func() bin.Object { return &GetBasicGroupRequest{} }, - GetBasicGroupFullInfoRequestTypeID: func() bin.Object { return &GetBasicGroupFullInfoRequest{} }, - GetSupergroupRequestTypeID: func() bin.Object { return &GetSupergroupRequest{} }, - GetSupergroupFullInfoRequestTypeID: func() bin.Object { return &GetSupergroupFullInfoRequest{} }, - GetSecretChatRequestTypeID: func() bin.Object { return &GetSecretChatRequest{} }, - GetChatRequestTypeID: func() bin.Object { return &GetChatRequest{} }, - GetMessageRequestTypeID: func() bin.Object { return &GetMessageRequest{} }, - GetMessageLocallyRequestTypeID: func() bin.Object { return &GetMessageLocallyRequest{} }, - GetRepliedMessageRequestTypeID: func() bin.Object { return &GetRepliedMessageRequest{} }, - GetChatPinnedMessageRequestTypeID: func() bin.Object { return &GetChatPinnedMessageRequest{} }, - GetCallbackQueryMessageRequestTypeID: func() bin.Object { return &GetCallbackQueryMessageRequest{} }, - GetMessagesRequestTypeID: func() bin.Object { return &GetMessagesRequest{} }, - GetMessagePropertiesRequestTypeID: func() bin.Object { return &GetMessagePropertiesRequest{} }, - GetMessageThreadRequestTypeID: func() bin.Object { return &GetMessageThreadRequest{} }, - GetMessageReadDateRequestTypeID: func() bin.Object { return &GetMessageReadDateRequest{} }, - GetMessageViewersRequestTypeID: func() bin.Object { return &GetMessageViewersRequest{} }, - GetFileRequestTypeID: func() bin.Object { return &GetFileRequest{} }, - GetRemoteFileRequestTypeID: func() bin.Object { return &GetRemoteFileRequest{} }, - LoadChatsRequestTypeID: func() bin.Object { return &LoadChatsRequest{} }, - GetChatsRequestTypeID: func() bin.Object { return &GetChatsRequest{} }, - SearchPublicChatRequestTypeID: func() bin.Object { return &SearchPublicChatRequest{} }, - SearchPublicChatsRequestTypeID: func() bin.Object { return &SearchPublicChatsRequest{} }, - SearchChatsRequestTypeID: func() bin.Object { return &SearchChatsRequest{} }, - SearchChatsOnServerRequestTypeID: func() bin.Object { return &SearchChatsOnServerRequest{} }, - SearchChatsNearbyRequestTypeID: func() bin.Object { return &SearchChatsNearbyRequest{} }, - GetRecommendedChatsRequestTypeID: func() bin.Object { return &GetRecommendedChatsRequest{} }, - GetChatSimilarChatsRequestTypeID: func() bin.Object { return &GetChatSimilarChatsRequest{} }, - GetChatSimilarChatCountRequestTypeID: func() bin.Object { return &GetChatSimilarChatCountRequest{} }, - OpenChatSimilarChatRequestTypeID: func() bin.Object { return &OpenChatSimilarChatRequest{} }, - GetTopChatsRequestTypeID: func() bin.Object { return &GetTopChatsRequest{} }, - RemoveTopChatRequestTypeID: func() bin.Object { return &RemoveTopChatRequest{} }, - SearchRecentlyFoundChatsRequestTypeID: func() bin.Object { return &SearchRecentlyFoundChatsRequest{} }, - AddRecentlyFoundChatRequestTypeID: func() bin.Object { return &AddRecentlyFoundChatRequest{} }, - RemoveRecentlyFoundChatRequestTypeID: func() bin.Object { return &RemoveRecentlyFoundChatRequest{} }, - ClearRecentlyFoundChatsRequestTypeID: func() bin.Object { return &ClearRecentlyFoundChatsRequest{} }, - GetRecentlyOpenedChatsRequestTypeID: func() bin.Object { return &GetRecentlyOpenedChatsRequest{} }, - CheckChatUsernameRequestTypeID: func() bin.Object { return &CheckChatUsernameRequest{} }, - GetCreatedPublicChatsRequestTypeID: func() bin.Object { return &GetCreatedPublicChatsRequest{} }, - CheckCreatedPublicChatsLimitRequestTypeID: func() bin.Object { return &CheckCreatedPublicChatsLimitRequest{} }, - GetSuitableDiscussionChatsRequestTypeID: func() bin.Object { return &GetSuitableDiscussionChatsRequest{} }, - GetInactiveSupergroupChatsRequestTypeID: func() bin.Object { return &GetInactiveSupergroupChatsRequest{} }, - GetSuitablePersonalChatsRequestTypeID: func() bin.Object { return &GetSuitablePersonalChatsRequest{} }, - LoadSavedMessagesTopicsRequestTypeID: func() bin.Object { return &LoadSavedMessagesTopicsRequest{} }, - GetSavedMessagesTopicHistoryRequestTypeID: func() bin.Object { return &GetSavedMessagesTopicHistoryRequest{} }, - GetSavedMessagesTopicMessageByDateRequestTypeID: func() bin.Object { return &GetSavedMessagesTopicMessageByDateRequest{} }, - DeleteSavedMessagesTopicHistoryRequestTypeID: func() bin.Object { return &DeleteSavedMessagesTopicHistoryRequest{} }, - DeleteSavedMessagesTopicMessagesByDateRequestTypeID: func() bin.Object { return &DeleteSavedMessagesTopicMessagesByDateRequest{} }, - ToggleSavedMessagesTopicIsPinnedRequestTypeID: func() bin.Object { return &ToggleSavedMessagesTopicIsPinnedRequest{} }, - SetPinnedSavedMessagesTopicsRequestTypeID: func() bin.Object { return &SetPinnedSavedMessagesTopicsRequest{} }, - GetGroupsInCommonRequestTypeID: func() bin.Object { return &GetGroupsInCommonRequest{} }, - GetChatHistoryRequestTypeID: func() bin.Object { return &GetChatHistoryRequest{} }, - GetMessageThreadHistoryRequestTypeID: func() bin.Object { return &GetMessageThreadHistoryRequest{} }, - DeleteChatHistoryRequestTypeID: func() bin.Object { return &DeleteChatHistoryRequest{} }, - DeleteChatRequestTypeID: func() bin.Object { return &DeleteChatRequest{} }, - SearchChatMessagesRequestTypeID: func() bin.Object { return &SearchChatMessagesRequest{} }, - SearchMessagesRequestTypeID: func() bin.Object { return &SearchMessagesRequest{} }, - SearchSecretMessagesRequestTypeID: func() bin.Object { return &SearchSecretMessagesRequest{} }, - SearchSavedMessagesRequestTypeID: func() bin.Object { return &SearchSavedMessagesRequest{} }, - SearchCallMessagesRequestTypeID: func() bin.Object { return &SearchCallMessagesRequest{} }, - SearchOutgoingDocumentMessagesRequestTypeID: func() bin.Object { return &SearchOutgoingDocumentMessagesRequest{} }, - SearchPublicMessagesByTagRequestTypeID: func() bin.Object { return &SearchPublicMessagesByTagRequest{} }, - SearchPublicStoriesByTagRequestTypeID: func() bin.Object { return &SearchPublicStoriesByTagRequest{} }, - SearchPublicStoriesByLocationRequestTypeID: func() bin.Object { return &SearchPublicStoriesByLocationRequest{} }, - SearchPublicStoriesByVenueRequestTypeID: func() bin.Object { return &SearchPublicStoriesByVenueRequest{} }, - GetSearchedForTagsRequestTypeID: func() bin.Object { return &GetSearchedForTagsRequest{} }, - RemoveSearchedForTagRequestTypeID: func() bin.Object { return &RemoveSearchedForTagRequest{} }, - ClearSearchedForTagsRequestTypeID: func() bin.Object { return &ClearSearchedForTagsRequest{} }, - DeleteAllCallMessagesRequestTypeID: func() bin.Object { return &DeleteAllCallMessagesRequest{} }, - SearchChatRecentLocationMessagesRequestTypeID: func() bin.Object { return &SearchChatRecentLocationMessagesRequest{} }, - GetActiveLiveLocationMessagesRequestTypeID: func() bin.Object { return &GetActiveLiveLocationMessagesRequest{} }, - GetChatMessageByDateRequestTypeID: func() bin.Object { return &GetChatMessageByDateRequest{} }, - GetChatSparseMessagePositionsRequestTypeID: func() bin.Object { return &GetChatSparseMessagePositionsRequest{} }, - GetChatMessageCalendarRequestTypeID: func() bin.Object { return &GetChatMessageCalendarRequest{} }, - GetChatMessageCountRequestTypeID: func() bin.Object { return &GetChatMessageCountRequest{} }, - GetChatMessagePositionRequestTypeID: func() bin.Object { return &GetChatMessagePositionRequest{} }, - GetChatScheduledMessagesRequestTypeID: func() bin.Object { return &GetChatScheduledMessagesRequest{} }, - GetChatSponsoredMessagesRequestTypeID: func() bin.Object { return &GetChatSponsoredMessagesRequest{} }, - ClickChatSponsoredMessageRequestTypeID: func() bin.Object { return &ClickChatSponsoredMessageRequest{} }, - ReportChatSponsoredMessageRequestTypeID: func() bin.Object { return &ReportChatSponsoredMessageRequest{} }, - RemoveNotificationRequestTypeID: func() bin.Object { return &RemoveNotificationRequest{} }, - RemoveNotificationGroupRequestTypeID: func() bin.Object { return &RemoveNotificationGroupRequest{} }, - GetMessageLinkRequestTypeID: func() bin.Object { return &GetMessageLinkRequest{} }, - GetMessageEmbeddingCodeRequestTypeID: func() bin.Object { return &GetMessageEmbeddingCodeRequest{} }, - GetMessageLinkInfoRequestTypeID: func() bin.Object { return &GetMessageLinkInfoRequest{} }, - TranslateTextRequestTypeID: func() bin.Object { return &TranslateTextRequest{} }, - TranslateMessageTextRequestTypeID: func() bin.Object { return &TranslateMessageTextRequest{} }, - RecognizeSpeechRequestTypeID: func() bin.Object { return &RecognizeSpeechRequest{} }, - RateSpeechRecognitionRequestTypeID: func() bin.Object { return &RateSpeechRecognitionRequest{} }, - GetChatAvailableMessageSendersRequestTypeID: func() bin.Object { return &GetChatAvailableMessageSendersRequest{} }, - SetChatMessageSenderRequestTypeID: func() bin.Object { return &SetChatMessageSenderRequest{} }, - SendMessageRequestTypeID: func() bin.Object { return &SendMessageRequest{} }, - SendMessageAlbumRequestTypeID: func() bin.Object { return &SendMessageAlbumRequest{} }, - SendBotStartMessageRequestTypeID: func() bin.Object { return &SendBotStartMessageRequest{} }, - SendInlineQueryResultMessageRequestTypeID: func() bin.Object { return &SendInlineQueryResultMessageRequest{} }, - ForwardMessagesRequestTypeID: func() bin.Object { return &ForwardMessagesRequest{} }, - SendQuickReplyShortcutMessagesRequestTypeID: func() bin.Object { return &SendQuickReplyShortcutMessagesRequest{} }, - ResendMessagesRequestTypeID: func() bin.Object { return &ResendMessagesRequest{} }, - AddLocalMessageRequestTypeID: func() bin.Object { return &AddLocalMessageRequest{} }, - DeleteMessagesRequestTypeID: func() bin.Object { return &DeleteMessagesRequest{} }, - DeleteChatMessagesBySenderRequestTypeID: func() bin.Object { return &DeleteChatMessagesBySenderRequest{} }, - DeleteChatMessagesByDateRequestTypeID: func() bin.Object { return &DeleteChatMessagesByDateRequest{} }, - EditMessageTextRequestTypeID: func() bin.Object { return &EditMessageTextRequest{} }, - EditMessageLiveLocationRequestTypeID: func() bin.Object { return &EditMessageLiveLocationRequest{} }, - EditMessageMediaRequestTypeID: func() bin.Object { return &EditMessageMediaRequest{} }, - EditMessageCaptionRequestTypeID: func() bin.Object { return &EditMessageCaptionRequest{} }, - EditMessageReplyMarkupRequestTypeID: func() bin.Object { return &EditMessageReplyMarkupRequest{} }, - EditInlineMessageTextRequestTypeID: func() bin.Object { return &EditInlineMessageTextRequest{} }, - EditInlineMessageLiveLocationRequestTypeID: func() bin.Object { return &EditInlineMessageLiveLocationRequest{} }, - EditInlineMessageMediaRequestTypeID: func() bin.Object { return &EditInlineMessageMediaRequest{} }, - EditInlineMessageCaptionRequestTypeID: func() bin.Object { return &EditInlineMessageCaptionRequest{} }, - EditInlineMessageReplyMarkupRequestTypeID: func() bin.Object { return &EditInlineMessageReplyMarkupRequest{} }, - EditMessageSchedulingStateRequestTypeID: func() bin.Object { return &EditMessageSchedulingStateRequest{} }, - SetMessageFactCheckRequestTypeID: func() bin.Object { return &SetMessageFactCheckRequest{} }, - SendBusinessMessageRequestTypeID: func() bin.Object { return &SendBusinessMessageRequest{} }, - SendBusinessMessageAlbumRequestTypeID: func() bin.Object { return &SendBusinessMessageAlbumRequest{} }, - EditBusinessMessageTextRequestTypeID: func() bin.Object { return &EditBusinessMessageTextRequest{} }, - EditBusinessMessageLiveLocationRequestTypeID: func() bin.Object { return &EditBusinessMessageLiveLocationRequest{} }, - EditBusinessMessageMediaRequestTypeID: func() bin.Object { return &EditBusinessMessageMediaRequest{} }, - EditBusinessMessageCaptionRequestTypeID: func() bin.Object { return &EditBusinessMessageCaptionRequest{} }, - EditBusinessMessageReplyMarkupRequestTypeID: func() bin.Object { return &EditBusinessMessageReplyMarkupRequest{} }, - StopBusinessPollRequestTypeID: func() bin.Object { return &StopBusinessPollRequest{} }, - SetBusinessMessageIsPinnedRequestTypeID: func() bin.Object { return &SetBusinessMessageIsPinnedRequest{} }, - CheckQuickReplyShortcutNameRequestTypeID: func() bin.Object { return &CheckQuickReplyShortcutNameRequest{} }, - LoadQuickReplyShortcutsRequestTypeID: func() bin.Object { return &LoadQuickReplyShortcutsRequest{} }, - SetQuickReplyShortcutNameRequestTypeID: func() bin.Object { return &SetQuickReplyShortcutNameRequest{} }, - DeleteQuickReplyShortcutRequestTypeID: func() bin.Object { return &DeleteQuickReplyShortcutRequest{} }, - ReorderQuickReplyShortcutsRequestTypeID: func() bin.Object { return &ReorderQuickReplyShortcutsRequest{} }, - LoadQuickReplyShortcutMessagesRequestTypeID: func() bin.Object { return &LoadQuickReplyShortcutMessagesRequest{} }, - DeleteQuickReplyShortcutMessagesRequestTypeID: func() bin.Object { return &DeleteQuickReplyShortcutMessagesRequest{} }, - AddQuickReplyShortcutMessageRequestTypeID: func() bin.Object { return &AddQuickReplyShortcutMessageRequest{} }, - AddQuickReplyShortcutInlineQueryResultMessageRequestTypeID: func() bin.Object { return &AddQuickReplyShortcutInlineQueryResultMessageRequest{} }, - AddQuickReplyShortcutMessageAlbumRequestTypeID: func() bin.Object { return &AddQuickReplyShortcutMessageAlbumRequest{} }, - ReaddQuickReplyShortcutMessagesRequestTypeID: func() bin.Object { return &ReaddQuickReplyShortcutMessagesRequest{} }, - EditQuickReplyMessageRequestTypeID: func() bin.Object { return &EditQuickReplyMessageRequest{} }, - GetForumTopicDefaultIconsRequestTypeID: func() bin.Object { return &GetForumTopicDefaultIconsRequest{} }, - CreateForumTopicRequestTypeID: func() bin.Object { return &CreateForumTopicRequest{} }, - EditForumTopicRequestTypeID: func() bin.Object { return &EditForumTopicRequest{} }, - GetForumTopicRequestTypeID: func() bin.Object { return &GetForumTopicRequest{} }, - GetForumTopicLinkRequestTypeID: func() bin.Object { return &GetForumTopicLinkRequest{} }, - GetForumTopicsRequestTypeID: func() bin.Object { return &GetForumTopicsRequest{} }, - SetForumTopicNotificationSettingsRequestTypeID: func() bin.Object { return &SetForumTopicNotificationSettingsRequest{} }, - ToggleForumTopicIsClosedRequestTypeID: func() bin.Object { return &ToggleForumTopicIsClosedRequest{} }, - ToggleGeneralForumTopicIsHiddenRequestTypeID: func() bin.Object { return &ToggleGeneralForumTopicIsHiddenRequest{} }, - ToggleForumTopicIsPinnedRequestTypeID: func() bin.Object { return &ToggleForumTopicIsPinnedRequest{} }, - SetPinnedForumTopicsRequestTypeID: func() bin.Object { return &SetPinnedForumTopicsRequest{} }, - DeleteForumTopicRequestTypeID: func() bin.Object { return &DeleteForumTopicRequest{} }, - GetEmojiReactionRequestTypeID: func() bin.Object { return &GetEmojiReactionRequest{} }, - GetCustomEmojiReactionAnimationsRequestTypeID: func() bin.Object { return &GetCustomEmojiReactionAnimationsRequest{} }, - GetMessageAvailableReactionsRequestTypeID: func() bin.Object { return &GetMessageAvailableReactionsRequest{} }, - ClearRecentReactionsRequestTypeID: func() bin.Object { return &ClearRecentReactionsRequest{} }, - AddMessageReactionRequestTypeID: func() bin.Object { return &AddMessageReactionRequest{} }, - RemoveMessageReactionRequestTypeID: func() bin.Object { return &RemoveMessageReactionRequest{} }, - SetMessageReactionsRequestTypeID: func() bin.Object { return &SetMessageReactionsRequest{} }, - GetMessageAddedReactionsRequestTypeID: func() bin.Object { return &GetMessageAddedReactionsRequest{} }, - SetDefaultReactionTypeRequestTypeID: func() bin.Object { return &SetDefaultReactionTypeRequest{} }, - GetSavedMessagesTagsRequestTypeID: func() bin.Object { return &GetSavedMessagesTagsRequest{} }, - SetSavedMessagesTagLabelRequestTypeID: func() bin.Object { return &SetSavedMessagesTagLabelRequest{} }, - GetMessageEffectRequestTypeID: func() bin.Object { return &GetMessageEffectRequest{} }, - SearchQuoteRequestTypeID: func() bin.Object { return &SearchQuoteRequest{} }, - GetTextEntitiesRequestTypeID: func() bin.Object { return &GetTextEntitiesRequest{} }, - ParseTextEntitiesRequestTypeID: func() bin.Object { return &ParseTextEntitiesRequest{} }, - ParseMarkdownRequestTypeID: func() bin.Object { return &ParseMarkdownRequest{} }, - GetMarkdownTextRequestTypeID: func() bin.Object { return &GetMarkdownTextRequest{} }, - GetCountryFlagEmojiRequestTypeID: func() bin.Object { return &GetCountryFlagEmojiRequest{} }, - GetFileMimeTypeRequestTypeID: func() bin.Object { return &GetFileMimeTypeRequest{} }, - GetFileExtensionRequestTypeID: func() bin.Object { return &GetFileExtensionRequest{} }, - CleanFileNameRequestTypeID: func() bin.Object { return &CleanFileNameRequest{} }, - GetLanguagePackStringRequestTypeID: func() bin.Object { return &GetLanguagePackStringRequest{} }, - GetJSONValueRequestTypeID: func() bin.Object { return &GetJSONValueRequest{} }, - GetJSONStringRequestTypeID: func() bin.Object { return &GetJSONStringRequest{} }, - GetThemeParametersJSONStringRequestTypeID: func() bin.Object { return &GetThemeParametersJSONStringRequest{} }, - SetPollAnswerRequestTypeID: func() bin.Object { return &SetPollAnswerRequest{} }, - GetPollVotersRequestTypeID: func() bin.Object { return &GetPollVotersRequest{} }, - StopPollRequestTypeID: func() bin.Object { return &StopPollRequest{} }, - HideSuggestedActionRequestTypeID: func() bin.Object { return &HideSuggestedActionRequest{} }, - HideContactCloseBirthdaysRequestTypeID: func() bin.Object { return &HideContactCloseBirthdaysRequest{} }, - GetBusinessConnectionRequestTypeID: func() bin.Object { return &GetBusinessConnectionRequest{} }, - GetLoginURLInfoRequestTypeID: func() bin.Object { return &GetLoginURLInfoRequest{} }, - GetLoginURLRequestTypeID: func() bin.Object { return &GetLoginURLRequest{} }, - ShareUsersWithBotRequestTypeID: func() bin.Object { return &ShareUsersWithBotRequest{} }, - ShareChatWithBotRequestTypeID: func() bin.Object { return &ShareChatWithBotRequest{} }, - GetInlineQueryResultsRequestTypeID: func() bin.Object { return &GetInlineQueryResultsRequest{} }, - AnswerInlineQueryRequestTypeID: func() bin.Object { return &AnswerInlineQueryRequest{} }, - GetPopularWebAppBotsRequestTypeID: func() bin.Object { return &GetPopularWebAppBotsRequest{} }, - SearchWebAppRequestTypeID: func() bin.Object { return &SearchWebAppRequest{} }, - GetWebAppLinkURLRequestTypeID: func() bin.Object { return &GetWebAppLinkURLRequest{} }, - GetMainWebAppRequestTypeID: func() bin.Object { return &GetMainWebAppRequest{} }, - GetWebAppURLRequestTypeID: func() bin.Object { return &GetWebAppURLRequest{} }, - SendWebAppDataRequestTypeID: func() bin.Object { return &SendWebAppDataRequest{} }, - OpenWebAppRequestTypeID: func() bin.Object { return &OpenWebAppRequest{} }, - CloseWebAppRequestTypeID: func() bin.Object { return &CloseWebAppRequest{} }, - AnswerWebAppQueryRequestTypeID: func() bin.Object { return &AnswerWebAppQueryRequest{} }, - GetCallbackQueryAnswerRequestTypeID: func() bin.Object { return &GetCallbackQueryAnswerRequest{} }, - AnswerCallbackQueryRequestTypeID: func() bin.Object { return &AnswerCallbackQueryRequest{} }, - AnswerShippingQueryRequestTypeID: func() bin.Object { return &AnswerShippingQueryRequest{} }, - AnswerPreCheckoutQueryRequestTypeID: func() bin.Object { return &AnswerPreCheckoutQueryRequest{} }, - SetGameScoreRequestTypeID: func() bin.Object { return &SetGameScoreRequest{} }, - SetInlineGameScoreRequestTypeID: func() bin.Object { return &SetInlineGameScoreRequest{} }, - GetGameHighScoresRequestTypeID: func() bin.Object { return &GetGameHighScoresRequest{} }, - GetInlineGameHighScoresRequestTypeID: func() bin.Object { return &GetInlineGameHighScoresRequest{} }, - DeleteChatReplyMarkupRequestTypeID: func() bin.Object { return &DeleteChatReplyMarkupRequest{} }, - SendChatActionRequestTypeID: func() bin.Object { return &SendChatActionRequest{} }, - OpenChatRequestTypeID: func() bin.Object { return &OpenChatRequest{} }, - CloseChatRequestTypeID: func() bin.Object { return &CloseChatRequest{} }, - ViewMessagesRequestTypeID: func() bin.Object { return &ViewMessagesRequest{} }, - OpenMessageContentRequestTypeID: func() bin.Object { return &OpenMessageContentRequest{} }, - ClickAnimatedEmojiMessageRequestTypeID: func() bin.Object { return &ClickAnimatedEmojiMessageRequest{} }, - GetInternalLinkRequestTypeID: func() bin.Object { return &GetInternalLinkRequest{} }, - GetInternalLinkTypeRequestTypeID: func() bin.Object { return &GetInternalLinkTypeRequest{} }, - GetExternalLinkInfoRequestTypeID: func() bin.Object { return &GetExternalLinkInfoRequest{} }, - GetExternalLinkRequestTypeID: func() bin.Object { return &GetExternalLinkRequest{} }, - ReadAllChatMentionsRequestTypeID: func() bin.Object { return &ReadAllChatMentionsRequest{} }, - ReadAllMessageThreadMentionsRequestTypeID: func() bin.Object { return &ReadAllMessageThreadMentionsRequest{} }, - ReadAllChatReactionsRequestTypeID: func() bin.Object { return &ReadAllChatReactionsRequest{} }, - ReadAllMessageThreadReactionsRequestTypeID: func() bin.Object { return &ReadAllMessageThreadReactionsRequest{} }, - CreatePrivateChatRequestTypeID: func() bin.Object { return &CreatePrivateChatRequest{} }, - CreateBasicGroupChatRequestTypeID: func() bin.Object { return &CreateBasicGroupChatRequest{} }, - CreateSupergroupChatRequestTypeID: func() bin.Object { return &CreateSupergroupChatRequest{} }, - CreateSecretChatRequestTypeID: func() bin.Object { return &CreateSecretChatRequest{} }, - CreateNewBasicGroupChatRequestTypeID: func() bin.Object { return &CreateNewBasicGroupChatRequest{} }, - CreateNewSupergroupChatRequestTypeID: func() bin.Object { return &CreateNewSupergroupChatRequest{} }, - CreateNewSecretChatRequestTypeID: func() bin.Object { return &CreateNewSecretChatRequest{} }, - UpgradeBasicGroupChatToSupergroupChatRequestTypeID: func() bin.Object { return &UpgradeBasicGroupChatToSupergroupChatRequest{} }, - GetChatListsToAddChatRequestTypeID: func() bin.Object { return &GetChatListsToAddChatRequest{} }, - AddChatToListRequestTypeID: func() bin.Object { return &AddChatToListRequest{} }, - GetChatFolderRequestTypeID: func() bin.Object { return &GetChatFolderRequest{} }, - CreateChatFolderRequestTypeID: func() bin.Object { return &CreateChatFolderRequest{} }, - EditChatFolderRequestTypeID: func() bin.Object { return &EditChatFolderRequest{} }, - DeleteChatFolderRequestTypeID: func() bin.Object { return &DeleteChatFolderRequest{} }, - GetChatFolderChatsToLeaveRequestTypeID: func() bin.Object { return &GetChatFolderChatsToLeaveRequest{} }, - GetChatFolderChatCountRequestTypeID: func() bin.Object { return &GetChatFolderChatCountRequest{} }, - ReorderChatFoldersRequestTypeID: func() bin.Object { return &ReorderChatFoldersRequest{} }, - ToggleChatFolderTagsRequestTypeID: func() bin.Object { return &ToggleChatFolderTagsRequest{} }, - GetRecommendedChatFoldersRequestTypeID: func() bin.Object { return &GetRecommendedChatFoldersRequest{} }, - GetChatFolderDefaultIconNameRequestTypeID: func() bin.Object { return &GetChatFolderDefaultIconNameRequest{} }, - GetChatsForChatFolderInviteLinkRequestTypeID: func() bin.Object { return &GetChatsForChatFolderInviteLinkRequest{} }, - CreateChatFolderInviteLinkRequestTypeID: func() bin.Object { return &CreateChatFolderInviteLinkRequest{} }, - GetChatFolderInviteLinksRequestTypeID: func() bin.Object { return &GetChatFolderInviteLinksRequest{} }, - EditChatFolderInviteLinkRequestTypeID: func() bin.Object { return &EditChatFolderInviteLinkRequest{} }, - DeleteChatFolderInviteLinkRequestTypeID: func() bin.Object { return &DeleteChatFolderInviteLinkRequest{} }, - CheckChatFolderInviteLinkRequestTypeID: func() bin.Object { return &CheckChatFolderInviteLinkRequest{} }, - AddChatFolderByInviteLinkRequestTypeID: func() bin.Object { return &AddChatFolderByInviteLinkRequest{} }, - GetChatFolderNewChatsRequestTypeID: func() bin.Object { return &GetChatFolderNewChatsRequest{} }, - ProcessChatFolderNewChatsRequestTypeID: func() bin.Object { return &ProcessChatFolderNewChatsRequest{} }, - GetArchiveChatListSettingsRequestTypeID: func() bin.Object { return &GetArchiveChatListSettingsRequest{} }, - SetArchiveChatListSettingsRequestTypeID: func() bin.Object { return &SetArchiveChatListSettingsRequest{} }, - SetChatTitleRequestTypeID: func() bin.Object { return &SetChatTitleRequest{} }, - SetChatPhotoRequestTypeID: func() bin.Object { return &SetChatPhotoRequest{} }, - SetChatAccentColorRequestTypeID: func() bin.Object { return &SetChatAccentColorRequest{} }, - SetChatProfileAccentColorRequestTypeID: func() bin.Object { return &SetChatProfileAccentColorRequest{} }, - SetChatMessageAutoDeleteTimeRequestTypeID: func() bin.Object { return &SetChatMessageAutoDeleteTimeRequest{} }, - SetChatEmojiStatusRequestTypeID: func() bin.Object { return &SetChatEmojiStatusRequest{} }, - SetChatPermissionsRequestTypeID: func() bin.Object { return &SetChatPermissionsRequest{} }, - SetChatBackgroundRequestTypeID: func() bin.Object { return &SetChatBackgroundRequest{} }, - DeleteChatBackgroundRequestTypeID: func() bin.Object { return &DeleteChatBackgroundRequest{} }, - SetChatThemeRequestTypeID: func() bin.Object { return &SetChatThemeRequest{} }, - SetChatDraftMessageRequestTypeID: func() bin.Object { return &SetChatDraftMessageRequest{} }, - SetChatNotificationSettingsRequestTypeID: func() bin.Object { return &SetChatNotificationSettingsRequest{} }, - ToggleChatHasProtectedContentRequestTypeID: func() bin.Object { return &ToggleChatHasProtectedContentRequest{} }, - ToggleChatViewAsTopicsRequestTypeID: func() bin.Object { return &ToggleChatViewAsTopicsRequest{} }, - ToggleChatIsTranslatableRequestTypeID: func() bin.Object { return &ToggleChatIsTranslatableRequest{} }, - ToggleChatIsMarkedAsUnreadRequestTypeID: func() bin.Object { return &ToggleChatIsMarkedAsUnreadRequest{} }, - ToggleChatDefaultDisableNotificationRequestTypeID: func() bin.Object { return &ToggleChatDefaultDisableNotificationRequest{} }, - SetChatAvailableReactionsRequestTypeID: func() bin.Object { return &SetChatAvailableReactionsRequest{} }, - SetChatClientDataRequestTypeID: func() bin.Object { return &SetChatClientDataRequest{} }, - SetChatDescriptionRequestTypeID: func() bin.Object { return &SetChatDescriptionRequest{} }, - SetChatDiscussionGroupRequestTypeID: func() bin.Object { return &SetChatDiscussionGroupRequest{} }, - SetChatLocationRequestTypeID: func() bin.Object { return &SetChatLocationRequest{} }, - SetChatSlowModeDelayRequestTypeID: func() bin.Object { return &SetChatSlowModeDelayRequest{} }, - PinChatMessageRequestTypeID: func() bin.Object { return &PinChatMessageRequest{} }, - UnpinChatMessageRequestTypeID: func() bin.Object { return &UnpinChatMessageRequest{} }, - UnpinAllChatMessagesRequestTypeID: func() bin.Object { return &UnpinAllChatMessagesRequest{} }, - UnpinAllMessageThreadMessagesRequestTypeID: func() bin.Object { return &UnpinAllMessageThreadMessagesRequest{} }, - JoinChatRequestTypeID: func() bin.Object { return &JoinChatRequest{} }, - LeaveChatRequestTypeID: func() bin.Object { return &LeaveChatRequest{} }, - AddChatMemberRequestTypeID: func() bin.Object { return &AddChatMemberRequest{} }, - AddChatMembersRequestTypeID: func() bin.Object { return &AddChatMembersRequest{} }, - SetChatMemberStatusRequestTypeID: func() bin.Object { return &SetChatMemberStatusRequest{} }, - BanChatMemberRequestTypeID: func() bin.Object { return &BanChatMemberRequest{} }, - CanTransferOwnershipRequestTypeID: func() bin.Object { return &CanTransferOwnershipRequest{} }, - TransferChatOwnershipRequestTypeID: func() bin.Object { return &TransferChatOwnershipRequest{} }, - GetChatMemberRequestTypeID: func() bin.Object { return &GetChatMemberRequest{} }, - SearchChatMembersRequestTypeID: func() bin.Object { return &SearchChatMembersRequest{} }, - GetChatAdministratorsRequestTypeID: func() bin.Object { return &GetChatAdministratorsRequest{} }, - ClearAllDraftMessagesRequestTypeID: func() bin.Object { return &ClearAllDraftMessagesRequest{} }, - GetSavedNotificationSoundRequestTypeID: func() bin.Object { return &GetSavedNotificationSoundRequest{} }, - GetSavedNotificationSoundsRequestTypeID: func() bin.Object { return &GetSavedNotificationSoundsRequest{} }, - AddSavedNotificationSoundRequestTypeID: func() bin.Object { return &AddSavedNotificationSoundRequest{} }, - RemoveSavedNotificationSoundRequestTypeID: func() bin.Object { return &RemoveSavedNotificationSoundRequest{} }, - GetChatNotificationSettingsExceptionsRequestTypeID: func() bin.Object { return &GetChatNotificationSettingsExceptionsRequest{} }, - GetScopeNotificationSettingsRequestTypeID: func() bin.Object { return &GetScopeNotificationSettingsRequest{} }, - SetScopeNotificationSettingsRequestTypeID: func() bin.Object { return &SetScopeNotificationSettingsRequest{} }, - SetReactionNotificationSettingsRequestTypeID: func() bin.Object { return &SetReactionNotificationSettingsRequest{} }, - ResetAllNotificationSettingsRequestTypeID: func() bin.Object { return &ResetAllNotificationSettingsRequest{} }, - ToggleChatIsPinnedRequestTypeID: func() bin.Object { return &ToggleChatIsPinnedRequest{} }, - SetPinnedChatsRequestTypeID: func() bin.Object { return &SetPinnedChatsRequest{} }, - ReadChatListRequestTypeID: func() bin.Object { return &ReadChatListRequest{} }, - GetCurrentWeatherRequestTypeID: func() bin.Object { return &GetCurrentWeatherRequest{} }, - GetStoryRequestTypeID: func() bin.Object { return &GetStoryRequest{} }, - GetChatsToSendStoriesRequestTypeID: func() bin.Object { return &GetChatsToSendStoriesRequest{} }, - CanSendStoryRequestTypeID: func() bin.Object { return &CanSendStoryRequest{} }, - SendStoryRequestTypeID: func() bin.Object { return &SendStoryRequest{} }, - EditStoryRequestTypeID: func() bin.Object { return &EditStoryRequest{} }, - EditStoryCoverRequestTypeID: func() bin.Object { return &EditStoryCoverRequest{} }, - SetStoryPrivacySettingsRequestTypeID: func() bin.Object { return &SetStoryPrivacySettingsRequest{} }, - ToggleStoryIsPostedToChatPageRequestTypeID: func() bin.Object { return &ToggleStoryIsPostedToChatPageRequest{} }, - DeleteStoryRequestTypeID: func() bin.Object { return &DeleteStoryRequest{} }, - GetStoryNotificationSettingsExceptionsRequestTypeID: func() bin.Object { return &GetStoryNotificationSettingsExceptionsRequest{} }, - LoadActiveStoriesRequestTypeID: func() bin.Object { return &LoadActiveStoriesRequest{} }, - SetChatActiveStoriesListRequestTypeID: func() bin.Object { return &SetChatActiveStoriesListRequest{} }, - GetChatActiveStoriesRequestTypeID: func() bin.Object { return &GetChatActiveStoriesRequest{} }, - GetChatPostedToChatPageStoriesRequestTypeID: func() bin.Object { return &GetChatPostedToChatPageStoriesRequest{} }, - GetChatArchivedStoriesRequestTypeID: func() bin.Object { return &GetChatArchivedStoriesRequest{} }, - SetChatPinnedStoriesRequestTypeID: func() bin.Object { return &SetChatPinnedStoriesRequest{} }, - OpenStoryRequestTypeID: func() bin.Object { return &OpenStoryRequest{} }, - CloseStoryRequestTypeID: func() bin.Object { return &CloseStoryRequest{} }, - GetStoryAvailableReactionsRequestTypeID: func() bin.Object { return &GetStoryAvailableReactionsRequest{} }, - SetStoryReactionRequestTypeID: func() bin.Object { return &SetStoryReactionRequest{} }, - GetStoryInteractionsRequestTypeID: func() bin.Object { return &GetStoryInteractionsRequest{} }, - GetChatStoryInteractionsRequestTypeID: func() bin.Object { return &GetChatStoryInteractionsRequest{} }, - ReportStoryRequestTypeID: func() bin.Object { return &ReportStoryRequest{} }, - ActivateStoryStealthModeRequestTypeID: func() bin.Object { return &ActivateStoryStealthModeRequest{} }, - GetStoryPublicForwardsRequestTypeID: func() bin.Object { return &GetStoryPublicForwardsRequest{} }, - GetChatBoostLevelFeaturesRequestTypeID: func() bin.Object { return &GetChatBoostLevelFeaturesRequest{} }, - GetChatBoostFeaturesRequestTypeID: func() bin.Object { return &GetChatBoostFeaturesRequest{} }, - GetAvailableChatBoostSlotsRequestTypeID: func() bin.Object { return &GetAvailableChatBoostSlotsRequest{} }, - GetChatBoostStatusRequestTypeID: func() bin.Object { return &GetChatBoostStatusRequest{} }, - BoostChatRequestTypeID: func() bin.Object { return &BoostChatRequest{} }, - GetChatBoostLinkRequestTypeID: func() bin.Object { return &GetChatBoostLinkRequest{} }, - GetChatBoostLinkInfoRequestTypeID: func() bin.Object { return &GetChatBoostLinkInfoRequest{} }, - GetChatBoostsRequestTypeID: func() bin.Object { return &GetChatBoostsRequest{} }, - GetUserChatBoostsRequestTypeID: func() bin.Object { return &GetUserChatBoostsRequest{} }, - GetAttachmentMenuBotRequestTypeID: func() bin.Object { return &GetAttachmentMenuBotRequest{} }, - ToggleBotIsAddedToAttachmentMenuRequestTypeID: func() bin.Object { return &ToggleBotIsAddedToAttachmentMenuRequest{} }, - GetThemedEmojiStatusesRequestTypeID: func() bin.Object { return &GetThemedEmojiStatusesRequest{} }, - GetRecentEmojiStatusesRequestTypeID: func() bin.Object { return &GetRecentEmojiStatusesRequest{} }, - GetDefaultEmojiStatusesRequestTypeID: func() bin.Object { return &GetDefaultEmojiStatusesRequest{} }, - ClearRecentEmojiStatusesRequestTypeID: func() bin.Object { return &ClearRecentEmojiStatusesRequest{} }, - GetThemedChatEmojiStatusesRequestTypeID: func() bin.Object { return &GetThemedChatEmojiStatusesRequest{} }, - GetDefaultChatEmojiStatusesRequestTypeID: func() bin.Object { return &GetDefaultChatEmojiStatusesRequest{} }, - GetDisallowedChatEmojiStatusesRequestTypeID: func() bin.Object { return &GetDisallowedChatEmojiStatusesRequest{} }, - DownloadFileRequestTypeID: func() bin.Object { return &DownloadFileRequest{} }, - GetFileDownloadedPrefixSizeRequestTypeID: func() bin.Object { return &GetFileDownloadedPrefixSizeRequest{} }, - CancelDownloadFileRequestTypeID: func() bin.Object { return &CancelDownloadFileRequest{} }, - GetSuggestedFileNameRequestTypeID: func() bin.Object { return &GetSuggestedFileNameRequest{} }, - PreliminaryUploadFileRequestTypeID: func() bin.Object { return &PreliminaryUploadFileRequest{} }, - CancelPreliminaryUploadFileRequestTypeID: func() bin.Object { return &CancelPreliminaryUploadFileRequest{} }, - WriteGeneratedFilePartRequestTypeID: func() bin.Object { return &WriteGeneratedFilePartRequest{} }, - SetFileGenerationProgressRequestTypeID: func() bin.Object { return &SetFileGenerationProgressRequest{} }, - FinishFileGenerationRequestTypeID: func() bin.Object { return &FinishFileGenerationRequest{} }, - ReadFilePartRequestTypeID: func() bin.Object { return &ReadFilePartRequest{} }, - DeleteFileRequestTypeID: func() bin.Object { return &DeleteFileRequest{} }, - AddFileToDownloadsRequestTypeID: func() bin.Object { return &AddFileToDownloadsRequest{} }, - ToggleDownloadIsPausedRequestTypeID: func() bin.Object { return &ToggleDownloadIsPausedRequest{} }, - ToggleAllDownloadsArePausedRequestTypeID: func() bin.Object { return &ToggleAllDownloadsArePausedRequest{} }, - RemoveFileFromDownloadsRequestTypeID: func() bin.Object { return &RemoveFileFromDownloadsRequest{} }, - RemoveAllFilesFromDownloadsRequestTypeID: func() bin.Object { return &RemoveAllFilesFromDownloadsRequest{} }, - SearchFileDownloadsRequestTypeID: func() bin.Object { return &SearchFileDownloadsRequest{} }, - SetApplicationVerificationTokenRequestTypeID: func() bin.Object { return &SetApplicationVerificationTokenRequest{} }, - GetMessageFileTypeRequestTypeID: func() bin.Object { return &GetMessageFileTypeRequest{} }, - GetMessageImportConfirmationTextRequestTypeID: func() bin.Object { return &GetMessageImportConfirmationTextRequest{} }, - ImportMessagesRequestTypeID: func() bin.Object { return &ImportMessagesRequest{} }, - ReplacePrimaryChatInviteLinkRequestTypeID: func() bin.Object { return &ReplacePrimaryChatInviteLinkRequest{} }, - CreateChatInviteLinkRequestTypeID: func() bin.Object { return &CreateChatInviteLinkRequest{} }, - EditChatInviteLinkRequestTypeID: func() bin.Object { return &EditChatInviteLinkRequest{} }, - GetChatInviteLinkRequestTypeID: func() bin.Object { return &GetChatInviteLinkRequest{} }, - GetChatInviteLinkCountsRequestTypeID: func() bin.Object { return &GetChatInviteLinkCountsRequest{} }, - GetChatInviteLinksRequestTypeID: func() bin.Object { return &GetChatInviteLinksRequest{} }, - GetChatInviteLinkMembersRequestTypeID: func() bin.Object { return &GetChatInviteLinkMembersRequest{} }, - RevokeChatInviteLinkRequestTypeID: func() bin.Object { return &RevokeChatInviteLinkRequest{} }, - DeleteRevokedChatInviteLinkRequestTypeID: func() bin.Object { return &DeleteRevokedChatInviteLinkRequest{} }, - DeleteAllRevokedChatInviteLinksRequestTypeID: func() bin.Object { return &DeleteAllRevokedChatInviteLinksRequest{} }, - CheckChatInviteLinkRequestTypeID: func() bin.Object { return &CheckChatInviteLinkRequest{} }, - JoinChatByInviteLinkRequestTypeID: func() bin.Object { return &JoinChatByInviteLinkRequest{} }, - GetChatJoinRequestsRequestTypeID: func() bin.Object { return &GetChatJoinRequestsRequest{} }, - ProcessChatJoinRequestRequestTypeID: func() bin.Object { return &ProcessChatJoinRequestRequest{} }, - ProcessChatJoinRequestsRequestTypeID: func() bin.Object { return &ProcessChatJoinRequestsRequest{} }, - CreateCallRequestTypeID: func() bin.Object { return &CreateCallRequest{} }, - AcceptCallRequestTypeID: func() bin.Object { return &AcceptCallRequest{} }, - SendCallSignalingDataRequestTypeID: func() bin.Object { return &SendCallSignalingDataRequest{} }, - DiscardCallRequestTypeID: func() bin.Object { return &DiscardCallRequest{} }, - SendCallRatingRequestTypeID: func() bin.Object { return &SendCallRatingRequest{} }, - SendCallDebugInformationRequestTypeID: func() bin.Object { return &SendCallDebugInformationRequest{} }, - SendCallLogRequestTypeID: func() bin.Object { return &SendCallLogRequest{} }, - GetVideoChatAvailableParticipantsRequestTypeID: func() bin.Object { return &GetVideoChatAvailableParticipantsRequest{} }, - SetVideoChatDefaultParticipantRequestTypeID: func() bin.Object { return &SetVideoChatDefaultParticipantRequest{} }, - CreateVideoChatRequestTypeID: func() bin.Object { return &CreateVideoChatRequest{} }, - GetVideoChatRtmpURLRequestTypeID: func() bin.Object { return &GetVideoChatRtmpURLRequest{} }, - ReplaceVideoChatRtmpURLRequestTypeID: func() bin.Object { return &ReplaceVideoChatRtmpURLRequest{} }, - GetGroupCallRequestTypeID: func() bin.Object { return &GetGroupCallRequest{} }, - StartScheduledGroupCallRequestTypeID: func() bin.Object { return &StartScheduledGroupCallRequest{} }, - ToggleGroupCallEnabledStartNotificationRequestTypeID: func() bin.Object { return &ToggleGroupCallEnabledStartNotificationRequest{} }, - JoinGroupCallRequestTypeID: func() bin.Object { return &JoinGroupCallRequest{} }, - StartGroupCallScreenSharingRequestTypeID: func() bin.Object { return &StartGroupCallScreenSharingRequest{} }, - ToggleGroupCallScreenSharingIsPausedRequestTypeID: func() bin.Object { return &ToggleGroupCallScreenSharingIsPausedRequest{} }, - EndGroupCallScreenSharingRequestTypeID: func() bin.Object { return &EndGroupCallScreenSharingRequest{} }, - SetGroupCallTitleRequestTypeID: func() bin.Object { return &SetGroupCallTitleRequest{} }, - ToggleGroupCallMuteNewParticipantsRequestTypeID: func() bin.Object { return &ToggleGroupCallMuteNewParticipantsRequest{} }, - InviteGroupCallParticipantsRequestTypeID: func() bin.Object { return &InviteGroupCallParticipantsRequest{} }, - GetGroupCallInviteLinkRequestTypeID: func() bin.Object { return &GetGroupCallInviteLinkRequest{} }, - RevokeGroupCallInviteLinkRequestTypeID: func() bin.Object { return &RevokeGroupCallInviteLinkRequest{} }, - StartGroupCallRecordingRequestTypeID: func() bin.Object { return &StartGroupCallRecordingRequest{} }, - EndGroupCallRecordingRequestTypeID: func() bin.Object { return &EndGroupCallRecordingRequest{} }, - ToggleGroupCallIsMyVideoPausedRequestTypeID: func() bin.Object { return &ToggleGroupCallIsMyVideoPausedRequest{} }, - ToggleGroupCallIsMyVideoEnabledRequestTypeID: func() bin.Object { return &ToggleGroupCallIsMyVideoEnabledRequest{} }, - SetGroupCallParticipantIsSpeakingRequestTypeID: func() bin.Object { return &SetGroupCallParticipantIsSpeakingRequest{} }, - ToggleGroupCallParticipantIsMutedRequestTypeID: func() bin.Object { return &ToggleGroupCallParticipantIsMutedRequest{} }, - SetGroupCallParticipantVolumeLevelRequestTypeID: func() bin.Object { return &SetGroupCallParticipantVolumeLevelRequest{} }, - ToggleGroupCallParticipantIsHandRaisedRequestTypeID: func() bin.Object { return &ToggleGroupCallParticipantIsHandRaisedRequest{} }, - LoadGroupCallParticipantsRequestTypeID: func() bin.Object { return &LoadGroupCallParticipantsRequest{} }, - LeaveGroupCallRequestTypeID: func() bin.Object { return &LeaveGroupCallRequest{} }, - EndGroupCallRequestTypeID: func() bin.Object { return &EndGroupCallRequest{} }, - GetGroupCallStreamsRequestTypeID: func() bin.Object { return &GetGroupCallStreamsRequest{} }, - GetGroupCallStreamSegmentRequestTypeID: func() bin.Object { return &GetGroupCallStreamSegmentRequest{} }, - SetMessageSenderBlockListRequestTypeID: func() bin.Object { return &SetMessageSenderBlockListRequest{} }, - BlockMessageSenderFromRepliesRequestTypeID: func() bin.Object { return &BlockMessageSenderFromRepliesRequest{} }, - GetBlockedMessageSendersRequestTypeID: func() bin.Object { return &GetBlockedMessageSendersRequest{} }, - AddContactRequestTypeID: func() bin.Object { return &AddContactRequest{} }, - ImportContactsRequestTypeID: func() bin.Object { return &ImportContactsRequest{} }, - GetContactsRequestTypeID: func() bin.Object { return &GetContactsRequest{} }, - SearchContactsRequestTypeID: func() bin.Object { return &SearchContactsRequest{} }, - RemoveContactsRequestTypeID: func() bin.Object { return &RemoveContactsRequest{} }, - GetImportedContactCountRequestTypeID: func() bin.Object { return &GetImportedContactCountRequest{} }, - ChangeImportedContactsRequestTypeID: func() bin.Object { return &ChangeImportedContactsRequest{} }, - ClearImportedContactsRequestTypeID: func() bin.Object { return &ClearImportedContactsRequest{} }, - SetCloseFriendsRequestTypeID: func() bin.Object { return &SetCloseFriendsRequest{} }, - GetCloseFriendsRequestTypeID: func() bin.Object { return &GetCloseFriendsRequest{} }, - SetUserPersonalProfilePhotoRequestTypeID: func() bin.Object { return &SetUserPersonalProfilePhotoRequest{} }, - SuggestUserProfilePhotoRequestTypeID: func() bin.Object { return &SuggestUserProfilePhotoRequest{} }, - SearchUserByPhoneNumberRequestTypeID: func() bin.Object { return &SearchUserByPhoneNumberRequest{} }, - SharePhoneNumberRequestTypeID: func() bin.Object { return &SharePhoneNumberRequest{} }, - GetUserProfilePhotosRequestTypeID: func() bin.Object { return &GetUserProfilePhotosRequest{} }, - GetStickersRequestTypeID: func() bin.Object { return &GetStickersRequest{} }, - GetAllStickerEmojisRequestTypeID: func() bin.Object { return &GetAllStickerEmojisRequest{} }, - SearchStickersRequestTypeID: func() bin.Object { return &SearchStickersRequest{} }, - GetGreetingStickersRequestTypeID: func() bin.Object { return &GetGreetingStickersRequest{} }, - GetPremiumStickersRequestTypeID: func() bin.Object { return &GetPremiumStickersRequest{} }, - GetInstalledStickerSetsRequestTypeID: func() bin.Object { return &GetInstalledStickerSetsRequest{} }, - GetArchivedStickerSetsRequestTypeID: func() bin.Object { return &GetArchivedStickerSetsRequest{} }, - GetTrendingStickerSetsRequestTypeID: func() bin.Object { return &GetTrendingStickerSetsRequest{} }, - GetAttachedStickerSetsRequestTypeID: func() bin.Object { return &GetAttachedStickerSetsRequest{} }, - GetStickerSetRequestTypeID: func() bin.Object { return &GetStickerSetRequest{} }, - SearchStickerSetRequestTypeID: func() bin.Object { return &SearchStickerSetRequest{} }, - SearchInstalledStickerSetsRequestTypeID: func() bin.Object { return &SearchInstalledStickerSetsRequest{} }, - SearchStickerSetsRequestTypeID: func() bin.Object { return &SearchStickerSetsRequest{} }, - ChangeStickerSetRequestTypeID: func() bin.Object { return &ChangeStickerSetRequest{} }, - ViewTrendingStickerSetsRequestTypeID: func() bin.Object { return &ViewTrendingStickerSetsRequest{} }, - ReorderInstalledStickerSetsRequestTypeID: func() bin.Object { return &ReorderInstalledStickerSetsRequest{} }, - GetRecentStickersRequestTypeID: func() bin.Object { return &GetRecentStickersRequest{} }, - AddRecentStickerRequestTypeID: func() bin.Object { return &AddRecentStickerRequest{} }, - RemoveRecentStickerRequestTypeID: func() bin.Object { return &RemoveRecentStickerRequest{} }, - ClearRecentStickersRequestTypeID: func() bin.Object { return &ClearRecentStickersRequest{} }, - GetFavoriteStickersRequestTypeID: func() bin.Object { return &GetFavoriteStickersRequest{} }, - AddFavoriteStickerRequestTypeID: func() bin.Object { return &AddFavoriteStickerRequest{} }, - RemoveFavoriteStickerRequestTypeID: func() bin.Object { return &RemoveFavoriteStickerRequest{} }, - GetStickerEmojisRequestTypeID: func() bin.Object { return &GetStickerEmojisRequest{} }, - SearchEmojisRequestTypeID: func() bin.Object { return &SearchEmojisRequest{} }, - GetKeywordEmojisRequestTypeID: func() bin.Object { return &GetKeywordEmojisRequest{} }, - GetEmojiCategoriesRequestTypeID: func() bin.Object { return &GetEmojiCategoriesRequest{} }, - GetAnimatedEmojiRequestTypeID: func() bin.Object { return &GetAnimatedEmojiRequest{} }, - GetEmojiSuggestionsURLRequestTypeID: func() bin.Object { return &GetEmojiSuggestionsURLRequest{} }, - GetCustomEmojiStickersRequestTypeID: func() bin.Object { return &GetCustomEmojiStickersRequest{} }, - GetDefaultChatPhotoCustomEmojiStickersRequestTypeID: func() bin.Object { return &GetDefaultChatPhotoCustomEmojiStickersRequest{} }, - GetDefaultProfilePhotoCustomEmojiStickersRequestTypeID: func() bin.Object { return &GetDefaultProfilePhotoCustomEmojiStickersRequest{} }, - GetDefaultBackgroundCustomEmojiStickersRequestTypeID: func() bin.Object { return &GetDefaultBackgroundCustomEmojiStickersRequest{} }, - GetSavedAnimationsRequestTypeID: func() bin.Object { return &GetSavedAnimationsRequest{} }, - AddSavedAnimationRequestTypeID: func() bin.Object { return &AddSavedAnimationRequest{} }, - RemoveSavedAnimationRequestTypeID: func() bin.Object { return &RemoveSavedAnimationRequest{} }, - GetRecentInlineBotsRequestTypeID: func() bin.Object { return &GetRecentInlineBotsRequest{} }, - SearchHashtagsRequestTypeID: func() bin.Object { return &SearchHashtagsRequest{} }, - RemoveRecentHashtagRequestTypeID: func() bin.Object { return &RemoveRecentHashtagRequest{} }, - GetLinkPreviewRequestTypeID: func() bin.Object { return &GetLinkPreviewRequest{} }, - GetWebPageInstantViewRequestTypeID: func() bin.Object { return &GetWebPageInstantViewRequest{} }, - SetProfilePhotoRequestTypeID: func() bin.Object { return &SetProfilePhotoRequest{} }, - DeleteProfilePhotoRequestTypeID: func() bin.Object { return &DeleteProfilePhotoRequest{} }, - SetAccentColorRequestTypeID: func() bin.Object { return &SetAccentColorRequest{} }, - SetProfileAccentColorRequestTypeID: func() bin.Object { return &SetProfileAccentColorRequest{} }, - SetNameRequestTypeID: func() bin.Object { return &SetNameRequest{} }, - SetBioRequestTypeID: func() bin.Object { return &SetBioRequest{} }, - SetUsernameRequestTypeID: func() bin.Object { return &SetUsernameRequest{} }, - ToggleUsernameIsActiveRequestTypeID: func() bin.Object { return &ToggleUsernameIsActiveRequest{} }, - ReorderActiveUsernamesRequestTypeID: func() bin.Object { return &ReorderActiveUsernamesRequest{} }, - SetBirthdateRequestTypeID: func() bin.Object { return &SetBirthdateRequest{} }, - SetPersonalChatRequestTypeID: func() bin.Object { return &SetPersonalChatRequest{} }, - SetEmojiStatusRequestTypeID: func() bin.Object { return &SetEmojiStatusRequest{} }, - SetLocationRequestTypeID: func() bin.Object { return &SetLocationRequest{} }, - ToggleHasSponsoredMessagesEnabledRequestTypeID: func() bin.Object { return &ToggleHasSponsoredMessagesEnabledRequest{} }, - SetBusinessLocationRequestTypeID: func() bin.Object { return &SetBusinessLocationRequest{} }, - SetBusinessOpeningHoursRequestTypeID: func() bin.Object { return &SetBusinessOpeningHoursRequest{} }, - SetBusinessGreetingMessageSettingsRequestTypeID: func() bin.Object { return &SetBusinessGreetingMessageSettingsRequest{} }, - SetBusinessAwayMessageSettingsRequestTypeID: func() bin.Object { return &SetBusinessAwayMessageSettingsRequest{} }, - SetBusinessStartPageRequestTypeID: func() bin.Object { return &SetBusinessStartPageRequest{} }, - SendPhoneNumberCodeRequestTypeID: func() bin.Object { return &SendPhoneNumberCodeRequest{} }, - SendPhoneNumberFirebaseSMSRequestTypeID: func() bin.Object { return &SendPhoneNumberFirebaseSMSRequest{} }, - ReportPhoneNumberCodeMissingRequestTypeID: func() bin.Object { return &ReportPhoneNumberCodeMissingRequest{} }, - ResendPhoneNumberCodeRequestTypeID: func() bin.Object { return &ResendPhoneNumberCodeRequest{} }, - CheckPhoneNumberCodeRequestTypeID: func() bin.Object { return &CheckPhoneNumberCodeRequest{} }, - GetBusinessConnectedBotRequestTypeID: func() bin.Object { return &GetBusinessConnectedBotRequest{} }, - SetBusinessConnectedBotRequestTypeID: func() bin.Object { return &SetBusinessConnectedBotRequest{} }, - DeleteBusinessConnectedBotRequestTypeID: func() bin.Object { return &DeleteBusinessConnectedBotRequest{} }, - ToggleBusinessConnectedBotChatIsPausedRequestTypeID: func() bin.Object { return &ToggleBusinessConnectedBotChatIsPausedRequest{} }, - RemoveBusinessConnectedBotFromChatRequestTypeID: func() bin.Object { return &RemoveBusinessConnectedBotFromChatRequest{} }, - GetBusinessChatLinksRequestTypeID: func() bin.Object { return &GetBusinessChatLinksRequest{} }, - CreateBusinessChatLinkRequestTypeID: func() bin.Object { return &CreateBusinessChatLinkRequest{} }, - EditBusinessChatLinkRequestTypeID: func() bin.Object { return &EditBusinessChatLinkRequest{} }, - DeleteBusinessChatLinkRequestTypeID: func() bin.Object { return &DeleteBusinessChatLinkRequest{} }, - GetBusinessChatLinkInfoRequestTypeID: func() bin.Object { return &GetBusinessChatLinkInfoRequest{} }, - GetUserLinkRequestTypeID: func() bin.Object { return &GetUserLinkRequest{} }, - SearchUserByTokenRequestTypeID: func() bin.Object { return &SearchUserByTokenRequest{} }, - SetCommandsRequestTypeID: func() bin.Object { return &SetCommandsRequest{} }, - DeleteCommandsRequestTypeID: func() bin.Object { return &DeleteCommandsRequest{} }, - GetCommandsRequestTypeID: func() bin.Object { return &GetCommandsRequest{} }, - SetMenuButtonRequestTypeID: func() bin.Object { return &SetMenuButtonRequest{} }, - GetMenuButtonRequestTypeID: func() bin.Object { return &GetMenuButtonRequest{} }, - SetDefaultGroupAdministratorRightsRequestTypeID: func() bin.Object { return &SetDefaultGroupAdministratorRightsRequest{} }, - SetDefaultChannelAdministratorRightsRequestTypeID: func() bin.Object { return &SetDefaultChannelAdministratorRightsRequest{} }, - CanBotSendMessagesRequestTypeID: func() bin.Object { return &CanBotSendMessagesRequest{} }, - AllowBotToSendMessagesRequestTypeID: func() bin.Object { return &AllowBotToSendMessagesRequest{} }, - SendWebAppCustomRequestRequestTypeID: func() bin.Object { return &SendWebAppCustomRequestRequest{} }, - GetBotMediaPreviewsRequestTypeID: func() bin.Object { return &GetBotMediaPreviewsRequest{} }, - GetBotMediaPreviewInfoRequestTypeID: func() bin.Object { return &GetBotMediaPreviewInfoRequest{} }, - AddBotMediaPreviewRequestTypeID: func() bin.Object { return &AddBotMediaPreviewRequest{} }, - EditBotMediaPreviewRequestTypeID: func() bin.Object { return &EditBotMediaPreviewRequest{} }, - ReorderBotMediaPreviewsRequestTypeID: func() bin.Object { return &ReorderBotMediaPreviewsRequest{} }, - DeleteBotMediaPreviewsRequestTypeID: func() bin.Object { return &DeleteBotMediaPreviewsRequest{} }, - SetBotNameRequestTypeID: func() bin.Object { return &SetBotNameRequest{} }, - GetBotNameRequestTypeID: func() bin.Object { return &GetBotNameRequest{} }, - SetBotProfilePhotoRequestTypeID: func() bin.Object { return &SetBotProfilePhotoRequest{} }, - ToggleBotUsernameIsActiveRequestTypeID: func() bin.Object { return &ToggleBotUsernameIsActiveRequest{} }, - ReorderBotActiveUsernamesRequestTypeID: func() bin.Object { return &ReorderBotActiveUsernamesRequest{} }, - SetBotInfoDescriptionRequestTypeID: func() bin.Object { return &SetBotInfoDescriptionRequest{} }, - GetBotInfoDescriptionRequestTypeID: func() bin.Object { return &GetBotInfoDescriptionRequest{} }, - SetBotInfoShortDescriptionRequestTypeID: func() bin.Object { return &SetBotInfoShortDescriptionRequest{} }, - GetBotInfoShortDescriptionRequestTypeID: func() bin.Object { return &GetBotInfoShortDescriptionRequest{} }, - GetActiveSessionsRequestTypeID: func() bin.Object { return &GetActiveSessionsRequest{} }, - TerminateSessionRequestTypeID: func() bin.Object { return &TerminateSessionRequest{} }, - TerminateAllOtherSessionsRequestTypeID: func() bin.Object { return &TerminateAllOtherSessionsRequest{} }, - ConfirmSessionRequestTypeID: func() bin.Object { return &ConfirmSessionRequest{} }, - ToggleSessionCanAcceptCallsRequestTypeID: func() bin.Object { return &ToggleSessionCanAcceptCallsRequest{} }, - ToggleSessionCanAcceptSecretChatsRequestTypeID: func() bin.Object { return &ToggleSessionCanAcceptSecretChatsRequest{} }, - SetInactiveSessionTTLRequestTypeID: func() bin.Object { return &SetInactiveSessionTTLRequest{} }, - GetConnectedWebsitesRequestTypeID: func() bin.Object { return &GetConnectedWebsitesRequest{} }, - DisconnectWebsiteRequestTypeID: func() bin.Object { return &DisconnectWebsiteRequest{} }, - DisconnectAllWebsitesRequestTypeID: func() bin.Object { return &DisconnectAllWebsitesRequest{} }, - SetSupergroupUsernameRequestTypeID: func() bin.Object { return &SetSupergroupUsernameRequest{} }, - ToggleSupergroupUsernameIsActiveRequestTypeID: func() bin.Object { return &ToggleSupergroupUsernameIsActiveRequest{} }, - DisableAllSupergroupUsernamesRequestTypeID: func() bin.Object { return &DisableAllSupergroupUsernamesRequest{} }, - ReorderSupergroupActiveUsernamesRequestTypeID: func() bin.Object { return &ReorderSupergroupActiveUsernamesRequest{} }, - SetSupergroupStickerSetRequestTypeID: func() bin.Object { return &SetSupergroupStickerSetRequest{} }, - SetSupergroupCustomEmojiStickerSetRequestTypeID: func() bin.Object { return &SetSupergroupCustomEmojiStickerSetRequest{} }, - SetSupergroupUnrestrictBoostCountRequestTypeID: func() bin.Object { return &SetSupergroupUnrestrictBoostCountRequest{} }, - ToggleSupergroupSignMessagesRequestTypeID: func() bin.Object { return &ToggleSupergroupSignMessagesRequest{} }, - ToggleSupergroupJoinToSendMessagesRequestTypeID: func() bin.Object { return &ToggleSupergroupJoinToSendMessagesRequest{} }, - ToggleSupergroupJoinByRequestRequestTypeID: func() bin.Object { return &ToggleSupergroupJoinByRequestRequest{} }, - ToggleSupergroupIsAllHistoryAvailableRequestTypeID: func() bin.Object { return &ToggleSupergroupIsAllHistoryAvailableRequest{} }, - ToggleSupergroupCanHaveSponsoredMessagesRequestTypeID: func() bin.Object { return &ToggleSupergroupCanHaveSponsoredMessagesRequest{} }, - ToggleSupergroupHasHiddenMembersRequestTypeID: func() bin.Object { return &ToggleSupergroupHasHiddenMembersRequest{} }, - ToggleSupergroupHasAggressiveAntiSpamEnabledRequestTypeID: func() bin.Object { return &ToggleSupergroupHasAggressiveAntiSpamEnabledRequest{} }, - ToggleSupergroupIsForumRequestTypeID: func() bin.Object { return &ToggleSupergroupIsForumRequest{} }, - ToggleSupergroupIsBroadcastGroupRequestTypeID: func() bin.Object { return &ToggleSupergroupIsBroadcastGroupRequest{} }, - ReportSupergroupSpamRequestTypeID: func() bin.Object { return &ReportSupergroupSpamRequest{} }, - ReportSupergroupAntiSpamFalsePositiveRequestTypeID: func() bin.Object { return &ReportSupergroupAntiSpamFalsePositiveRequest{} }, - GetSupergroupMembersRequestTypeID: func() bin.Object { return &GetSupergroupMembersRequest{} }, - CloseSecretChatRequestTypeID: func() bin.Object { return &CloseSecretChatRequest{} }, - GetChatEventLogRequestTypeID: func() bin.Object { return &GetChatEventLogRequest{} }, - GetTimeZonesRequestTypeID: func() bin.Object { return &GetTimeZonesRequest{} }, - GetPaymentFormRequestTypeID: func() bin.Object { return &GetPaymentFormRequest{} }, - ValidateOrderInfoRequestTypeID: func() bin.Object { return &ValidateOrderInfoRequest{} }, - SendPaymentFormRequestTypeID: func() bin.Object { return &SendPaymentFormRequest{} }, - GetPaymentReceiptRequestTypeID: func() bin.Object { return &GetPaymentReceiptRequest{} }, - GetSavedOrderInfoRequestTypeID: func() bin.Object { return &GetSavedOrderInfoRequest{} }, - DeleteSavedOrderInfoRequestTypeID: func() bin.Object { return &DeleteSavedOrderInfoRequest{} }, - DeleteSavedCredentialsRequestTypeID: func() bin.Object { return &DeleteSavedCredentialsRequest{} }, - CreateInvoiceLinkRequestTypeID: func() bin.Object { return &CreateInvoiceLinkRequest{} }, - RefundStarPaymentRequestTypeID: func() bin.Object { return &RefundStarPaymentRequest{} }, - GetSupportUserRequestTypeID: func() bin.Object { return &GetSupportUserRequest{} }, - GetBackgroundURLRequestTypeID: func() bin.Object { return &GetBackgroundURLRequest{} }, - SearchBackgroundRequestTypeID: func() bin.Object { return &SearchBackgroundRequest{} }, - SetDefaultBackgroundRequestTypeID: func() bin.Object { return &SetDefaultBackgroundRequest{} }, - DeleteDefaultBackgroundRequestTypeID: func() bin.Object { return &DeleteDefaultBackgroundRequest{} }, - GetInstalledBackgroundsRequestTypeID: func() bin.Object { return &GetInstalledBackgroundsRequest{} }, - RemoveInstalledBackgroundRequestTypeID: func() bin.Object { return &RemoveInstalledBackgroundRequest{} }, - ResetInstalledBackgroundsRequestTypeID: func() bin.Object { return &ResetInstalledBackgroundsRequest{} }, - GetLocalizationTargetInfoRequestTypeID: func() bin.Object { return &GetLocalizationTargetInfoRequest{} }, - GetLanguagePackInfoRequestTypeID: func() bin.Object { return &GetLanguagePackInfoRequest{} }, - GetLanguagePackStringsRequestTypeID: func() bin.Object { return &GetLanguagePackStringsRequest{} }, - SynchronizeLanguagePackRequestTypeID: func() bin.Object { return &SynchronizeLanguagePackRequest{} }, - AddCustomServerLanguagePackRequestTypeID: func() bin.Object { return &AddCustomServerLanguagePackRequest{} }, - SetCustomLanguagePackRequestTypeID: func() bin.Object { return &SetCustomLanguagePackRequest{} }, - EditCustomLanguagePackInfoRequestTypeID: func() bin.Object { return &EditCustomLanguagePackInfoRequest{} }, - SetCustomLanguagePackStringRequestTypeID: func() bin.Object { return &SetCustomLanguagePackStringRequest{} }, - DeleteLanguagePackRequestTypeID: func() bin.Object { return &DeleteLanguagePackRequest{} }, - RegisterDeviceRequestTypeID: func() bin.Object { return &RegisterDeviceRequest{} }, - ProcessPushNotificationRequestTypeID: func() bin.Object { return &ProcessPushNotificationRequest{} }, - GetPushReceiverIDRequestTypeID: func() bin.Object { return &GetPushReceiverIDRequest{} }, - GetRecentlyVisitedTMeURLsRequestTypeID: func() bin.Object { return &GetRecentlyVisitedTMeURLsRequest{} }, - SetUserPrivacySettingRulesRequestTypeID: func() bin.Object { return &SetUserPrivacySettingRulesRequest{} }, - GetUserPrivacySettingRulesRequestTypeID: func() bin.Object { return &GetUserPrivacySettingRulesRequest{} }, - SetReadDatePrivacySettingsRequestTypeID: func() bin.Object { return &SetReadDatePrivacySettingsRequest{} }, - GetReadDatePrivacySettingsRequestTypeID: func() bin.Object { return &GetReadDatePrivacySettingsRequest{} }, - SetNewChatPrivacySettingsRequestTypeID: func() bin.Object { return &SetNewChatPrivacySettingsRequest{} }, - GetNewChatPrivacySettingsRequestTypeID: func() bin.Object { return &GetNewChatPrivacySettingsRequest{} }, - CanSendMessageToUserRequestTypeID: func() bin.Object { return &CanSendMessageToUserRequest{} }, - GetOptionRequestTypeID: func() bin.Object { return &GetOptionRequest{} }, - SetOptionRequestTypeID: func() bin.Object { return &SetOptionRequest{} }, - SetAccountTTLRequestTypeID: func() bin.Object { return &SetAccountTTLRequest{} }, - GetAccountTTLRequestTypeID: func() bin.Object { return &GetAccountTTLRequest{} }, - DeleteAccountRequestTypeID: func() bin.Object { return &DeleteAccountRequest{} }, - SetDefaultMessageAutoDeleteTimeRequestTypeID: func() bin.Object { return &SetDefaultMessageAutoDeleteTimeRequest{} }, - GetDefaultMessageAutoDeleteTimeRequestTypeID: func() bin.Object { return &GetDefaultMessageAutoDeleteTimeRequest{} }, - RemoveChatActionBarRequestTypeID: func() bin.Object { return &RemoveChatActionBarRequest{} }, - ReportChatRequestTypeID: func() bin.Object { return &ReportChatRequest{} }, - ReportChatPhotoRequestTypeID: func() bin.Object { return &ReportChatPhotoRequest{} }, - ReportMessageReactionsRequestTypeID: func() bin.Object { return &ReportMessageReactionsRequest{} }, - GetChatRevenueStatisticsRequestTypeID: func() bin.Object { return &GetChatRevenueStatisticsRequest{} }, - GetChatRevenueWithdrawalURLRequestTypeID: func() bin.Object { return &GetChatRevenueWithdrawalURLRequest{} }, - GetChatRevenueTransactionsRequestTypeID: func() bin.Object { return &GetChatRevenueTransactionsRequest{} }, - GetStarRevenueStatisticsRequestTypeID: func() bin.Object { return &GetStarRevenueStatisticsRequest{} }, - GetStarWithdrawalURLRequestTypeID: func() bin.Object { return &GetStarWithdrawalURLRequest{} }, - GetStarAdAccountURLRequestTypeID: func() bin.Object { return &GetStarAdAccountURLRequest{} }, - GetChatStatisticsRequestTypeID: func() bin.Object { return &GetChatStatisticsRequest{} }, - GetMessageStatisticsRequestTypeID: func() bin.Object { return &GetMessageStatisticsRequest{} }, - GetMessagePublicForwardsRequestTypeID: func() bin.Object { return &GetMessagePublicForwardsRequest{} }, - GetStoryStatisticsRequestTypeID: func() bin.Object { return &GetStoryStatisticsRequest{} }, - GetStatisticalGraphRequestTypeID: func() bin.Object { return &GetStatisticalGraphRequest{} }, - GetStorageStatisticsRequestTypeID: func() bin.Object { return &GetStorageStatisticsRequest{} }, - GetStorageStatisticsFastRequestTypeID: func() bin.Object { return &GetStorageStatisticsFastRequest{} }, - GetDatabaseStatisticsRequestTypeID: func() bin.Object { return &GetDatabaseStatisticsRequest{} }, - OptimizeStorageRequestTypeID: func() bin.Object { return &OptimizeStorageRequest{} }, - SetNetworkTypeRequestTypeID: func() bin.Object { return &SetNetworkTypeRequest{} }, - GetNetworkStatisticsRequestTypeID: func() bin.Object { return &GetNetworkStatisticsRequest{} }, - AddNetworkStatisticsRequestTypeID: func() bin.Object { return &AddNetworkStatisticsRequest{} }, - ResetNetworkStatisticsRequestTypeID: func() bin.Object { return &ResetNetworkStatisticsRequest{} }, - GetAutoDownloadSettingsPresetsRequestTypeID: func() bin.Object { return &GetAutoDownloadSettingsPresetsRequest{} }, - SetAutoDownloadSettingsRequestTypeID: func() bin.Object { return &SetAutoDownloadSettingsRequest{} }, - GetAutosaveSettingsRequestTypeID: func() bin.Object { return &GetAutosaveSettingsRequest{} }, - SetAutosaveSettingsRequestTypeID: func() bin.Object { return &SetAutosaveSettingsRequest{} }, - ClearAutosaveSettingsExceptionsRequestTypeID: func() bin.Object { return &ClearAutosaveSettingsExceptionsRequest{} }, - GetBankCardInfoRequestTypeID: func() bin.Object { return &GetBankCardInfoRequest{} }, - GetPassportElementRequestTypeID: func() bin.Object { return &GetPassportElementRequest{} }, - GetAllPassportElementsRequestTypeID: func() bin.Object { return &GetAllPassportElementsRequest{} }, - SetPassportElementRequestTypeID: func() bin.Object { return &SetPassportElementRequest{} }, - DeletePassportElementRequestTypeID: func() bin.Object { return &DeletePassportElementRequest{} }, - SetPassportElementErrorsRequestTypeID: func() bin.Object { return &SetPassportElementErrorsRequest{} }, - GetPreferredCountryLanguageRequestTypeID: func() bin.Object { return &GetPreferredCountryLanguageRequest{} }, - SendEmailAddressVerificationCodeRequestTypeID: func() bin.Object { return &SendEmailAddressVerificationCodeRequest{} }, - ResendEmailAddressVerificationCodeRequestTypeID: func() bin.Object { return &ResendEmailAddressVerificationCodeRequest{} }, - CheckEmailAddressVerificationCodeRequestTypeID: func() bin.Object { return &CheckEmailAddressVerificationCodeRequest{} }, - GetPassportAuthorizationFormRequestTypeID: func() bin.Object { return &GetPassportAuthorizationFormRequest{} }, - GetPassportAuthorizationFormAvailableElementsRequestTypeID: func() bin.Object { return &GetPassportAuthorizationFormAvailableElementsRequest{} }, - SendPassportAuthorizationFormRequestTypeID: func() bin.Object { return &SendPassportAuthorizationFormRequest{} }, - SetBotUpdatesStatusRequestTypeID: func() bin.Object { return &SetBotUpdatesStatusRequest{} }, - UploadStickerFileRequestTypeID: func() bin.Object { return &UploadStickerFileRequest{} }, - GetSuggestedStickerSetNameRequestTypeID: func() bin.Object { return &GetSuggestedStickerSetNameRequest{} }, - CheckStickerSetNameRequestTypeID: func() bin.Object { return &CheckStickerSetNameRequest{} }, - CreateNewStickerSetRequestTypeID: func() bin.Object { return &CreateNewStickerSetRequest{} }, - AddStickerToSetRequestTypeID: func() bin.Object { return &AddStickerToSetRequest{} }, - ReplaceStickerInSetRequestTypeID: func() bin.Object { return &ReplaceStickerInSetRequest{} }, - SetStickerSetThumbnailRequestTypeID: func() bin.Object { return &SetStickerSetThumbnailRequest{} }, - SetCustomEmojiStickerSetThumbnailRequestTypeID: func() bin.Object { return &SetCustomEmojiStickerSetThumbnailRequest{} }, - SetStickerSetTitleRequestTypeID: func() bin.Object { return &SetStickerSetTitleRequest{} }, - DeleteStickerSetRequestTypeID: func() bin.Object { return &DeleteStickerSetRequest{} }, - SetStickerPositionInSetRequestTypeID: func() bin.Object { return &SetStickerPositionInSetRequest{} }, - RemoveStickerFromSetRequestTypeID: func() bin.Object { return &RemoveStickerFromSetRequest{} }, - SetStickerEmojisRequestTypeID: func() bin.Object { return &SetStickerEmojisRequest{} }, - SetStickerKeywordsRequestTypeID: func() bin.Object { return &SetStickerKeywordsRequest{} }, - SetStickerMaskPositionRequestTypeID: func() bin.Object { return &SetStickerMaskPositionRequest{} }, - GetOwnedStickerSetsRequestTypeID: func() bin.Object { return &GetOwnedStickerSetsRequest{} }, - GetMapThumbnailFileRequestTypeID: func() bin.Object { return &GetMapThumbnailFileRequest{} }, - GetPremiumLimitRequestTypeID: func() bin.Object { return &GetPremiumLimitRequest{} }, - GetPremiumFeaturesRequestTypeID: func() bin.Object { return &GetPremiumFeaturesRequest{} }, - GetPremiumStickerExamplesRequestTypeID: func() bin.Object { return &GetPremiumStickerExamplesRequest{} }, - ViewPremiumFeatureRequestTypeID: func() bin.Object { return &ViewPremiumFeatureRequest{} }, - ClickPremiumSubscriptionButtonRequestTypeID: func() bin.Object { return &ClickPremiumSubscriptionButtonRequest{} }, - GetPremiumStateRequestTypeID: func() bin.Object { return &GetPremiumStateRequest{} }, - GetPremiumGiftCodePaymentOptionsRequestTypeID: func() bin.Object { return &GetPremiumGiftCodePaymentOptionsRequest{} }, - CheckPremiumGiftCodeRequestTypeID: func() bin.Object { return &CheckPremiumGiftCodeRequest{} }, - ApplyPremiumGiftCodeRequestTypeID: func() bin.Object { return &ApplyPremiumGiftCodeRequest{} }, - LaunchPrepaidPremiumGiveawayRequestTypeID: func() bin.Object { return &LaunchPrepaidPremiumGiveawayRequest{} }, - GetPremiumGiveawayInfoRequestTypeID: func() bin.Object { return &GetPremiumGiveawayInfoRequest{} }, - GetStarPaymentOptionsRequestTypeID: func() bin.Object { return &GetStarPaymentOptionsRequest{} }, - GetStarGiftPaymentOptionsRequestTypeID: func() bin.Object { return &GetStarGiftPaymentOptionsRequest{} }, - GetStarTransactionsRequestTypeID: func() bin.Object { return &GetStarTransactionsRequest{} }, - CanPurchaseFromStoreRequestTypeID: func() bin.Object { return &CanPurchaseFromStoreRequest{} }, - AssignAppStoreTransactionRequestTypeID: func() bin.Object { return &AssignAppStoreTransactionRequest{} }, - AssignGooglePlayTransactionRequestTypeID: func() bin.Object { return &AssignGooglePlayTransactionRequest{} }, - GetBusinessFeaturesRequestTypeID: func() bin.Object { return &GetBusinessFeaturesRequest{} }, - AcceptTermsOfServiceRequestTypeID: func() bin.Object { return &AcceptTermsOfServiceRequest{} }, - SearchStringsByPrefixRequestTypeID: func() bin.Object { return &SearchStringsByPrefixRequest{} }, - SendCustomRequestRequestTypeID: func() bin.Object { return &SendCustomRequestRequest{} }, - AnswerCustomQueryRequestTypeID: func() bin.Object { return &AnswerCustomQueryRequest{} }, - SetAlarmRequestTypeID: func() bin.Object { return &SetAlarmRequest{} }, - GetCountriesRequestTypeID: func() bin.Object { return &GetCountriesRequest{} }, - GetCountryCodeRequestTypeID: func() bin.Object { return &GetCountryCodeRequest{} }, - GetPhoneNumberInfoRequestTypeID: func() bin.Object { return &GetPhoneNumberInfoRequest{} }, - GetPhoneNumberInfoSyncRequestTypeID: func() bin.Object { return &GetPhoneNumberInfoSyncRequest{} }, - GetCollectibleItemInfoRequestTypeID: func() bin.Object { return &GetCollectibleItemInfoRequest{} }, - GetDeepLinkInfoRequestTypeID: func() bin.Object { return &GetDeepLinkInfoRequest{} }, - GetApplicationConfigRequestTypeID: func() bin.Object { return &GetApplicationConfigRequest{} }, - SaveApplicationLogEventRequestTypeID: func() bin.Object { return &SaveApplicationLogEventRequest{} }, - GetApplicationDownloadLinkRequestTypeID: func() bin.Object { return &GetApplicationDownloadLinkRequest{} }, - AddProxyRequestTypeID: func() bin.Object { return &AddProxyRequest{} }, - EditProxyRequestTypeID: func() bin.Object { return &EditProxyRequest{} }, - EnableProxyRequestTypeID: func() bin.Object { return &EnableProxyRequest{} }, - DisableProxyRequestTypeID: func() bin.Object { return &DisableProxyRequest{} }, - RemoveProxyRequestTypeID: func() bin.Object { return &RemoveProxyRequest{} }, - GetProxiesRequestTypeID: func() bin.Object { return &GetProxiesRequest{} }, - GetProxyLinkRequestTypeID: func() bin.Object { return &GetProxyLinkRequest{} }, - PingProxyRequestTypeID: func() bin.Object { return &PingProxyRequest{} }, - SetLogStreamRequestTypeID: func() bin.Object { return &SetLogStreamRequest{} }, - GetLogStreamRequestTypeID: func() bin.Object { return &GetLogStreamRequest{} }, - SetLogVerbosityLevelRequestTypeID: func() bin.Object { return &SetLogVerbosityLevelRequest{} }, - GetLogVerbosityLevelRequestTypeID: func() bin.Object { return &GetLogVerbosityLevelRequest{} }, - GetLogTagsRequestTypeID: func() bin.Object { return &GetLogTagsRequest{} }, - SetLogTagVerbosityLevelRequestTypeID: func() bin.Object { return &SetLogTagVerbosityLevelRequest{} }, - GetLogTagVerbosityLevelRequestTypeID: func() bin.Object { return &GetLogTagVerbosityLevelRequest{} }, - AddLogMessageRequestTypeID: func() bin.Object { return &AddLogMessageRequest{} }, - GetUserSupportInfoRequestTypeID: func() bin.Object { return &GetUserSupportInfoRequest{} }, - SetUserSupportInfoRequestTypeID: func() bin.Object { return &SetUserSupportInfoRequest{} }, - GetSupportNameRequestTypeID: func() bin.Object { return &GetSupportNameRequest{} }, - TestCallEmptyRequestTypeID: func() bin.Object { return &TestCallEmptyRequest{} }, - TestCallStringRequestTypeID: func() bin.Object { return &TestCallStringRequest{} }, - TestCallBytesRequestTypeID: func() bin.Object { return &TestCallBytesRequest{} }, - TestCallVectorIntRequestTypeID: func() bin.Object { return &TestCallVectorIntRequest{} }, - TestCallVectorIntObjectRequestTypeID: func() bin.Object { return &TestCallVectorIntObjectRequest{} }, - TestCallVectorStringRequestTypeID: func() bin.Object { return &TestCallVectorStringRequest{} }, - TestCallVectorStringObjectRequestTypeID: func() bin.Object { return &TestCallVectorStringObjectRequest{} }, - TestSquareIntRequestTypeID: func() bin.Object { return &TestSquareIntRequest{} }, - TestNetworkRequestTypeID: func() bin.Object { return &TestNetworkRequest{} }, - TestProxyRequestTypeID: func() bin.Object { return &TestProxyRequest{} }, - TestGetDifferenceRequestTypeID: func() bin.Object { return &TestGetDifferenceRequest{} }, - TestUseUpdateRequestTypeID: func() bin.Object { return &TestUseUpdateRequest{} }, - TestReturnErrorRequestTypeID: func() bin.Object { return &TestReturnErrorRequest{} }, + SuggestedActionExtendStarSubscriptionsTypeID: func() bin.Object { return &SuggestedActionExtendStarSubscriptions{} }, + CountTypeID: func() bin.Object { return &Count{} }, + TextTypeID: func() bin.Object { return &Text{} }, + SecondsTypeID: func() bin.Object { return &Seconds{} }, + FileDownloadedPrefixSizeTypeID: func() bin.Object { return &FileDownloadedPrefixSize{} }, + DeepLinkInfoTypeID: func() bin.Object { return &DeepLinkInfo{} }, + TextParseModeMarkdownTypeID: func() bin.Object { return &TextParseModeMarkdown{} }, + TextParseModeHTMLTypeID: func() bin.Object { return &TextParseModeHTML{} }, + ProxyTypeSocks5TypeID: func() bin.Object { return &ProxyTypeSocks5{} }, + ProxyTypeHTTPTypeID: func() bin.Object { return &ProxyTypeHTTP{} }, + ProxyTypeMtprotoTypeID: func() bin.Object { return &ProxyTypeMtproto{} }, + ProxyTypeID: func() bin.Object { return &Proxy{} }, + ProxiesTypeID: func() bin.Object { return &Proxies{} }, + InputStickerTypeID: func() bin.Object { return &InputSticker{} }, + DateRangeTypeID: func() bin.Object { return &DateRange{} }, + StatisticalValueTypeID: func() bin.Object { return &StatisticalValue{} }, + StatisticalGraphDataTypeID: func() bin.Object { return &StatisticalGraphData{} }, + StatisticalGraphAsyncTypeID: func() bin.Object { return &StatisticalGraphAsync{} }, + StatisticalGraphErrorTypeID: func() bin.Object { return &StatisticalGraphError{} }, + ChatStatisticsObjectTypeMessageTypeID: func() bin.Object { return &ChatStatisticsObjectTypeMessage{} }, + ChatStatisticsObjectTypeStoryTypeID: func() bin.Object { return &ChatStatisticsObjectTypeStory{} }, + ChatStatisticsInteractionInfoTypeID: func() bin.Object { return &ChatStatisticsInteractionInfo{} }, + ChatStatisticsMessageSenderInfoTypeID: func() bin.Object { return &ChatStatisticsMessageSenderInfo{} }, + ChatStatisticsAdministratorActionsInfoTypeID: func() bin.Object { return &ChatStatisticsAdministratorActionsInfo{} }, + ChatStatisticsInviterInfoTypeID: func() bin.Object { return &ChatStatisticsInviterInfo{} }, + ChatStatisticsSupergroupTypeID: func() bin.Object { return &ChatStatisticsSupergroup{} }, + ChatStatisticsChannelTypeID: func() bin.Object { return &ChatStatisticsChannel{} }, + ChatRevenueAmountTypeID: func() bin.Object { return &ChatRevenueAmount{} }, + ChatRevenueStatisticsTypeID: func() bin.Object { return &ChatRevenueStatistics{} }, + MessageStatisticsTypeID: func() bin.Object { return &MessageStatistics{} }, + StoryStatisticsTypeID: func() bin.Object { return &StoryStatistics{} }, + RevenueWithdrawalStatePendingTypeID: func() bin.Object { return &RevenueWithdrawalStatePending{} }, + RevenueWithdrawalStateSucceededTypeID: func() bin.Object { return &RevenueWithdrawalStateSucceeded{} }, + RevenueWithdrawalStateFailedTypeID: func() bin.Object { return &RevenueWithdrawalStateFailed{} }, + ChatRevenueTransactionTypeEarningsTypeID: func() bin.Object { return &ChatRevenueTransactionTypeEarnings{} }, + ChatRevenueTransactionTypeWithdrawalTypeID: func() bin.Object { return &ChatRevenueTransactionTypeWithdrawal{} }, + ChatRevenueTransactionTypeRefundTypeID: func() bin.Object { return &ChatRevenueTransactionTypeRefund{} }, + ChatRevenueTransactionTypeID: func() bin.Object { return &ChatRevenueTransaction{} }, + ChatRevenueTransactionsTypeID: func() bin.Object { return &ChatRevenueTransactions{} }, + StarRevenueStatusTypeID: func() bin.Object { return &StarRevenueStatus{} }, + StarRevenueStatisticsTypeID: func() bin.Object { return &StarRevenueStatistics{} }, + PointTypeID: func() bin.Object { return &Point{} }, + VectorPathCommandLineTypeID: func() bin.Object { return &VectorPathCommandLine{} }, + VectorPathCommandCubicBezierCurveTypeID: func() bin.Object { return &VectorPathCommandCubicBezierCurve{} }, + BotCommandScopeDefaultTypeID: func() bin.Object { return &BotCommandScopeDefault{} }, + BotCommandScopeAllPrivateChatsTypeID: func() bin.Object { return &BotCommandScopeAllPrivateChats{} }, + BotCommandScopeAllGroupChatsTypeID: func() bin.Object { return &BotCommandScopeAllGroupChats{} }, + BotCommandScopeAllChatAdministratorsTypeID: func() bin.Object { return &BotCommandScopeAllChatAdministrators{} }, + BotCommandScopeChatTypeID: func() bin.Object { return &BotCommandScopeChat{} }, + BotCommandScopeChatAdministratorsTypeID: func() bin.Object { return &BotCommandScopeChatAdministrators{} }, + BotCommandScopeChatMemberTypeID: func() bin.Object { return &BotCommandScopeChatMember{} }, + PhoneNumberCodeTypeChangeTypeID: func() bin.Object { return &PhoneNumberCodeTypeChange{} }, + PhoneNumberCodeTypeVerifyTypeID: func() bin.Object { return &PhoneNumberCodeTypeVerify{} }, + PhoneNumberCodeTypeConfirmOwnershipTypeID: func() bin.Object { return &PhoneNumberCodeTypeConfirmOwnership{} }, + UpdateAuthorizationStateTypeID: func() bin.Object { return &UpdateAuthorizationState{} }, + UpdateNewMessageTypeID: func() bin.Object { return &UpdateNewMessage{} }, + UpdateMessageSendAcknowledgedTypeID: func() bin.Object { return &UpdateMessageSendAcknowledged{} }, + UpdateMessageSendSucceededTypeID: func() bin.Object { return &UpdateMessageSendSucceeded{} }, + UpdateMessageSendFailedTypeID: func() bin.Object { return &UpdateMessageSendFailed{} }, + UpdateMessageContentTypeID: func() bin.Object { return &UpdateMessageContent{} }, + UpdateMessageEditedTypeID: func() bin.Object { return &UpdateMessageEdited{} }, + UpdateMessageIsPinnedTypeID: func() bin.Object { return &UpdateMessageIsPinned{} }, + UpdateMessageInteractionInfoTypeID: func() bin.Object { return &UpdateMessageInteractionInfo{} }, + UpdateMessageContentOpenedTypeID: func() bin.Object { return &UpdateMessageContentOpened{} }, + UpdateMessageMentionReadTypeID: func() bin.Object { return &UpdateMessageMentionRead{} }, + UpdateMessageUnreadReactionsTypeID: func() bin.Object { return &UpdateMessageUnreadReactions{} }, + UpdateMessageFactCheckTypeID: func() bin.Object { return &UpdateMessageFactCheck{} }, + UpdateMessageLiveLocationViewedTypeID: func() bin.Object { return &UpdateMessageLiveLocationViewed{} }, + UpdateNewChatTypeID: func() bin.Object { return &UpdateNewChat{} }, + UpdateChatTitleTypeID: func() bin.Object { return &UpdateChatTitle{} }, + UpdateChatPhotoTypeID: func() bin.Object { return &UpdateChatPhoto{} }, + UpdateChatAccentColorsTypeID: func() bin.Object { return &UpdateChatAccentColors{} }, + UpdateChatPermissionsTypeID: func() bin.Object { return &UpdateChatPermissions{} }, + UpdateChatLastMessageTypeID: func() bin.Object { return &UpdateChatLastMessage{} }, + UpdateChatPositionTypeID: func() bin.Object { return &UpdateChatPosition{} }, + UpdateChatAddedToListTypeID: func() bin.Object { return &UpdateChatAddedToList{} }, + UpdateChatRemovedFromListTypeID: func() bin.Object { return &UpdateChatRemovedFromList{} }, + UpdateChatReadInboxTypeID: func() bin.Object { return &UpdateChatReadInbox{} }, + UpdateChatReadOutboxTypeID: func() bin.Object { return &UpdateChatReadOutbox{} }, + UpdateChatActionBarTypeID: func() bin.Object { return &UpdateChatActionBar{} }, + UpdateChatBusinessBotManageBarTypeID: func() bin.Object { return &UpdateChatBusinessBotManageBar{} }, + UpdateChatAvailableReactionsTypeID: func() bin.Object { return &UpdateChatAvailableReactions{} }, + UpdateChatDraftMessageTypeID: func() bin.Object { return &UpdateChatDraftMessage{} }, + UpdateChatEmojiStatusTypeID: func() bin.Object { return &UpdateChatEmojiStatus{} }, + UpdateChatMessageSenderTypeID: func() bin.Object { return &UpdateChatMessageSender{} }, + UpdateChatMessageAutoDeleteTimeTypeID: func() bin.Object { return &UpdateChatMessageAutoDeleteTime{} }, + UpdateChatNotificationSettingsTypeID: func() bin.Object { return &UpdateChatNotificationSettings{} }, + UpdateChatPendingJoinRequestsTypeID: func() bin.Object { return &UpdateChatPendingJoinRequests{} }, + UpdateChatReplyMarkupTypeID: func() bin.Object { return &UpdateChatReplyMarkup{} }, + UpdateChatBackgroundTypeID: func() bin.Object { return &UpdateChatBackground{} }, + UpdateChatThemeTypeID: func() bin.Object { return &UpdateChatTheme{} }, + UpdateChatUnreadMentionCountTypeID: func() bin.Object { return &UpdateChatUnreadMentionCount{} }, + UpdateChatUnreadReactionCountTypeID: func() bin.Object { return &UpdateChatUnreadReactionCount{} }, + UpdateChatVideoChatTypeID: func() bin.Object { return &UpdateChatVideoChat{} }, + UpdateChatDefaultDisableNotificationTypeID: func() bin.Object { return &UpdateChatDefaultDisableNotification{} }, + UpdateChatHasProtectedContentTypeID: func() bin.Object { return &UpdateChatHasProtectedContent{} }, + UpdateChatIsTranslatableTypeID: func() bin.Object { return &UpdateChatIsTranslatable{} }, + UpdateChatIsMarkedAsUnreadTypeID: func() bin.Object { return &UpdateChatIsMarkedAsUnread{} }, + UpdateChatViewAsTopicsTypeID: func() bin.Object { return &UpdateChatViewAsTopics{} }, + UpdateChatBlockListTypeID: func() bin.Object { return &UpdateChatBlockList{} }, + UpdateChatHasScheduledMessagesTypeID: func() bin.Object { return &UpdateChatHasScheduledMessages{} }, + UpdateChatFoldersTypeID: func() bin.Object { return &UpdateChatFolders{} }, + UpdateChatOnlineMemberCountTypeID: func() bin.Object { return &UpdateChatOnlineMemberCount{} }, + UpdateSavedMessagesTopicTypeID: func() bin.Object { return &UpdateSavedMessagesTopic{} }, + UpdateSavedMessagesTopicCountTypeID: func() bin.Object { return &UpdateSavedMessagesTopicCount{} }, + UpdateQuickReplyShortcutTypeID: func() bin.Object { return &UpdateQuickReplyShortcut{} }, + UpdateQuickReplyShortcutDeletedTypeID: func() bin.Object { return &UpdateQuickReplyShortcutDeleted{} }, + UpdateQuickReplyShortcutsTypeID: func() bin.Object { return &UpdateQuickReplyShortcuts{} }, + UpdateQuickReplyShortcutMessagesTypeID: func() bin.Object { return &UpdateQuickReplyShortcutMessages{} }, + UpdateForumTopicInfoTypeID: func() bin.Object { return &UpdateForumTopicInfo{} }, + UpdateScopeNotificationSettingsTypeID: func() bin.Object { return &UpdateScopeNotificationSettings{} }, + UpdateReactionNotificationSettingsTypeID: func() bin.Object { return &UpdateReactionNotificationSettings{} }, + UpdateNotificationTypeID: func() bin.Object { return &UpdateNotification{} }, + UpdateNotificationGroupTypeID: func() bin.Object { return &UpdateNotificationGroup{} }, + UpdateActiveNotificationsTypeID: func() bin.Object { return &UpdateActiveNotifications{} }, + UpdateHavePendingNotificationsTypeID: func() bin.Object { return &UpdateHavePendingNotifications{} }, + UpdateDeleteMessagesTypeID: func() bin.Object { return &UpdateDeleteMessages{} }, + UpdateChatActionTypeID: func() bin.Object { return &UpdateChatAction{} }, + UpdateUserStatusTypeID: func() bin.Object { return &UpdateUserStatus{} }, + UpdateUserTypeID: func() bin.Object { return &UpdateUser{} }, + UpdateBasicGroupTypeID: func() bin.Object { return &UpdateBasicGroup{} }, + UpdateSupergroupTypeID: func() bin.Object { return &UpdateSupergroup{} }, + UpdateSecretChatTypeID: func() bin.Object { return &UpdateSecretChat{} }, + UpdateUserFullInfoTypeID: func() bin.Object { return &UpdateUserFullInfo{} }, + UpdateBasicGroupFullInfoTypeID: func() bin.Object { return &UpdateBasicGroupFullInfo{} }, + UpdateSupergroupFullInfoTypeID: func() bin.Object { return &UpdateSupergroupFullInfo{} }, + UpdateServiceNotificationTypeID: func() bin.Object { return &UpdateServiceNotification{} }, + UpdateFileTypeID: func() bin.Object { return &UpdateFile{} }, + UpdateFileGenerationStartTypeID: func() bin.Object { return &UpdateFileGenerationStart{} }, + UpdateFileGenerationStopTypeID: func() bin.Object { return &UpdateFileGenerationStop{} }, + UpdateFileDownloadsTypeID: func() bin.Object { return &UpdateFileDownloads{} }, + UpdateFileAddedToDownloadsTypeID: func() bin.Object { return &UpdateFileAddedToDownloads{} }, + UpdateFileDownloadTypeID: func() bin.Object { return &UpdateFileDownload{} }, + UpdateFileRemovedFromDownloadsTypeID: func() bin.Object { return &UpdateFileRemovedFromDownloads{} }, + UpdateApplicationVerificationRequiredTypeID: func() bin.Object { return &UpdateApplicationVerificationRequired{} }, + UpdateCallTypeID: func() bin.Object { return &UpdateCall{} }, + UpdateGroupCallTypeID: func() bin.Object { return &UpdateGroupCall{} }, + UpdateGroupCallParticipantTypeID: func() bin.Object { return &UpdateGroupCallParticipant{} }, + UpdateNewCallSignalingDataTypeID: func() bin.Object { return &UpdateNewCallSignalingData{} }, + UpdateUserPrivacySettingRulesTypeID: func() bin.Object { return &UpdateUserPrivacySettingRules{} }, + UpdateUnreadMessageCountTypeID: func() bin.Object { return &UpdateUnreadMessageCount{} }, + UpdateUnreadChatCountTypeID: func() bin.Object { return &UpdateUnreadChatCount{} }, + UpdateStoryTypeID: func() bin.Object { return &UpdateStory{} }, + UpdateStoryDeletedTypeID: func() bin.Object { return &UpdateStoryDeleted{} }, + UpdateStorySendSucceededTypeID: func() bin.Object { return &UpdateStorySendSucceeded{} }, + UpdateStorySendFailedTypeID: func() bin.Object { return &UpdateStorySendFailed{} }, + UpdateChatActiveStoriesTypeID: func() bin.Object { return &UpdateChatActiveStories{} }, + UpdateStoryListChatCountTypeID: func() bin.Object { return &UpdateStoryListChatCount{} }, + UpdateStoryStealthModeTypeID: func() bin.Object { return &UpdateStoryStealthMode{} }, + UpdateOptionTypeID: func() bin.Object { return &UpdateOption{} }, + UpdateStickerSetTypeID: func() bin.Object { return &UpdateStickerSet{} }, + UpdateInstalledStickerSetsTypeID: func() bin.Object { return &UpdateInstalledStickerSets{} }, + UpdateTrendingStickerSetsTypeID: func() bin.Object { return &UpdateTrendingStickerSets{} }, + UpdateRecentStickersTypeID: func() bin.Object { return &UpdateRecentStickers{} }, + UpdateFavoriteStickersTypeID: func() bin.Object { return &UpdateFavoriteStickers{} }, + UpdateSavedAnimationsTypeID: func() bin.Object { return &UpdateSavedAnimations{} }, + UpdateSavedNotificationSoundsTypeID: func() bin.Object { return &UpdateSavedNotificationSounds{} }, + UpdateDefaultBackgroundTypeID: func() bin.Object { return &UpdateDefaultBackground{} }, + UpdateChatThemesTypeID: func() bin.Object { return &UpdateChatThemes{} }, + UpdateAccentColorsTypeID: func() bin.Object { return &UpdateAccentColors{} }, + UpdateProfileAccentColorsTypeID: func() bin.Object { return &UpdateProfileAccentColors{} }, + UpdateLanguagePackStringsTypeID: func() bin.Object { return &UpdateLanguagePackStrings{} }, + UpdateConnectionStateTypeID: func() bin.Object { return &UpdateConnectionState{} }, + UpdateTermsOfServiceTypeID: func() bin.Object { return &UpdateTermsOfService{} }, + UpdateUsersNearbyTypeID: func() bin.Object { return &UpdateUsersNearby{} }, + UpdateUnconfirmedSessionTypeID: func() bin.Object { return &UpdateUnconfirmedSession{} }, + UpdateAttachmentMenuBotsTypeID: func() bin.Object { return &UpdateAttachmentMenuBots{} }, + UpdateWebAppMessageSentTypeID: func() bin.Object { return &UpdateWebAppMessageSent{} }, + UpdateActiveEmojiReactionsTypeID: func() bin.Object { return &UpdateActiveEmojiReactions{} }, + UpdateAvailableMessageEffectsTypeID: func() bin.Object { return &UpdateAvailableMessageEffects{} }, + UpdateDefaultReactionTypeTypeID: func() bin.Object { return &UpdateDefaultReactionType{} }, + UpdateSavedMessagesTagsTypeID: func() bin.Object { return &UpdateSavedMessagesTags{} }, + UpdateActiveLiveLocationMessagesTypeID: func() bin.Object { return &UpdateActiveLiveLocationMessages{} }, + UpdateOwnedStarCountTypeID: func() bin.Object { return &UpdateOwnedStarCount{} }, + UpdateChatRevenueAmountTypeID: func() bin.Object { return &UpdateChatRevenueAmount{} }, + UpdateStarRevenueStatusTypeID: func() bin.Object { return &UpdateStarRevenueStatus{} }, + UpdateSpeechRecognitionTrialTypeID: func() bin.Object { return &UpdateSpeechRecognitionTrial{} }, + UpdateDiceEmojisTypeID: func() bin.Object { return &UpdateDiceEmojis{} }, + UpdateAnimatedEmojiMessageClickedTypeID: func() bin.Object { return &UpdateAnimatedEmojiMessageClicked{} }, + UpdateAnimationSearchParametersTypeID: func() bin.Object { return &UpdateAnimationSearchParameters{} }, + UpdateSuggestedActionsTypeID: func() bin.Object { return &UpdateSuggestedActions{} }, + UpdateSpeedLimitNotificationTypeID: func() bin.Object { return &UpdateSpeedLimitNotification{} }, + UpdateContactCloseBirthdaysTypeID: func() bin.Object { return &UpdateContactCloseBirthdays{} }, + UpdateAutosaveSettingsTypeID: func() bin.Object { return &UpdateAutosaveSettings{} }, + UpdateBusinessConnectionTypeID: func() bin.Object { return &UpdateBusinessConnection{} }, + UpdateNewBusinessMessageTypeID: func() bin.Object { return &UpdateNewBusinessMessage{} }, + UpdateBusinessMessageEditedTypeID: func() bin.Object { return &UpdateBusinessMessageEdited{} }, + UpdateBusinessMessagesDeletedTypeID: func() bin.Object { return &UpdateBusinessMessagesDeleted{} }, + UpdateNewInlineQueryTypeID: func() bin.Object { return &UpdateNewInlineQuery{} }, + UpdateNewChosenInlineResultTypeID: func() bin.Object { return &UpdateNewChosenInlineResult{} }, + UpdateNewCallbackQueryTypeID: func() bin.Object { return &UpdateNewCallbackQuery{} }, + UpdateNewInlineCallbackQueryTypeID: func() bin.Object { return &UpdateNewInlineCallbackQuery{} }, + UpdateNewBusinessCallbackQueryTypeID: func() bin.Object { return &UpdateNewBusinessCallbackQuery{} }, + UpdateNewShippingQueryTypeID: func() bin.Object { return &UpdateNewShippingQuery{} }, + UpdateNewPreCheckoutQueryTypeID: func() bin.Object { return &UpdateNewPreCheckoutQuery{} }, + UpdateNewCustomEventTypeID: func() bin.Object { return &UpdateNewCustomEvent{} }, + UpdateNewCustomQueryTypeID: func() bin.Object { return &UpdateNewCustomQuery{} }, + UpdatePollTypeID: func() bin.Object { return &UpdatePoll{} }, + UpdatePollAnswerTypeID: func() bin.Object { return &UpdatePollAnswer{} }, + UpdateChatMemberTypeID: func() bin.Object { return &UpdateChatMember{} }, + UpdateNewChatJoinRequestTypeID: func() bin.Object { return &UpdateNewChatJoinRequest{} }, + UpdateChatBoostTypeID: func() bin.Object { return &UpdateChatBoost{} }, + UpdateMessageReactionTypeID: func() bin.Object { return &UpdateMessageReaction{} }, + UpdateMessageReactionsTypeID: func() bin.Object { return &UpdateMessageReactions{} }, + UpdatesTypeID: func() bin.Object { return &Updates{} }, + LogStreamDefaultTypeID: func() bin.Object { return &LogStreamDefault{} }, + LogStreamFileTypeID: func() bin.Object { return &LogStreamFile{} }, + LogStreamEmptyTypeID: func() bin.Object { return &LogStreamEmpty{} }, + LogVerbosityLevelTypeID: func() bin.Object { return &LogVerbosityLevel{} }, + LogTagsTypeID: func() bin.Object { return &LogTags{} }, + UserSupportInfoTypeID: func() bin.Object { return &UserSupportInfo{} }, + TestIntTypeID: func() bin.Object { return &TestInt{} }, + TestStringTypeID: func() bin.Object { return &TestString{} }, + TestBytesTypeID: func() bin.Object { return &TestBytes{} }, + TestVectorIntTypeID: func() bin.Object { return &TestVectorInt{} }, + TestVectorIntObjectTypeID: func() bin.Object { return &TestVectorIntObject{} }, + TestVectorStringTypeID: func() bin.Object { return &TestVectorString{} }, + TestVectorStringObjectTypeID: func() bin.Object { return &TestVectorStringObject{} }, + GetAuthorizationStateRequestTypeID: func() bin.Object { return &GetAuthorizationStateRequest{} }, + SetTdlibParametersRequestTypeID: func() bin.Object { return &SetTdlibParametersRequest{} }, + SetAuthenticationPhoneNumberRequestTypeID: func() bin.Object { return &SetAuthenticationPhoneNumberRequest{} }, + SetAuthenticationEmailAddressRequestTypeID: func() bin.Object { return &SetAuthenticationEmailAddressRequest{} }, + ResendAuthenticationCodeRequestTypeID: func() bin.Object { return &ResendAuthenticationCodeRequest{} }, + CheckAuthenticationEmailCodeRequestTypeID: func() bin.Object { return &CheckAuthenticationEmailCodeRequest{} }, + CheckAuthenticationCodeRequestTypeID: func() bin.Object { return &CheckAuthenticationCodeRequest{} }, + RequestQrCodeAuthenticationRequestTypeID: func() bin.Object { return &RequestQrCodeAuthenticationRequest{} }, + RegisterUserRequestTypeID: func() bin.Object { return &RegisterUserRequest{} }, + ResetAuthenticationEmailAddressRequestTypeID: func() bin.Object { return &ResetAuthenticationEmailAddressRequest{} }, + CheckAuthenticationPasswordRequestTypeID: func() bin.Object { return &CheckAuthenticationPasswordRequest{} }, + RequestAuthenticationPasswordRecoveryRequestTypeID: func() bin.Object { return &RequestAuthenticationPasswordRecoveryRequest{} }, + CheckAuthenticationPasswordRecoveryCodeRequestTypeID: func() bin.Object { return &CheckAuthenticationPasswordRecoveryCodeRequest{} }, + RecoverAuthenticationPasswordRequestTypeID: func() bin.Object { return &RecoverAuthenticationPasswordRequest{} }, + SendAuthenticationFirebaseSMSRequestTypeID: func() bin.Object { return &SendAuthenticationFirebaseSMSRequest{} }, + ReportAuthenticationCodeMissingRequestTypeID: func() bin.Object { return &ReportAuthenticationCodeMissingRequest{} }, + CheckAuthenticationBotTokenRequestTypeID: func() bin.Object { return &CheckAuthenticationBotTokenRequest{} }, + LogOutRequestTypeID: func() bin.Object { return &LogOutRequest{} }, + CloseRequestTypeID: func() bin.Object { return &CloseRequest{} }, + DestroyRequestTypeID: func() bin.Object { return &DestroyRequest{} }, + ConfirmQrCodeAuthenticationRequestTypeID: func() bin.Object { return &ConfirmQrCodeAuthenticationRequest{} }, + GetCurrentStateRequestTypeID: func() bin.Object { return &GetCurrentStateRequest{} }, + SetDatabaseEncryptionKeyRequestTypeID: func() bin.Object { return &SetDatabaseEncryptionKeyRequest{} }, + GetPasswordStateRequestTypeID: func() bin.Object { return &GetPasswordStateRequest{} }, + SetPasswordRequestTypeID: func() bin.Object { return &SetPasswordRequest{} }, + SetLoginEmailAddressRequestTypeID: func() bin.Object { return &SetLoginEmailAddressRequest{} }, + ResendLoginEmailAddressCodeRequestTypeID: func() bin.Object { return &ResendLoginEmailAddressCodeRequest{} }, + CheckLoginEmailAddressCodeRequestTypeID: func() bin.Object { return &CheckLoginEmailAddressCodeRequest{} }, + GetRecoveryEmailAddressRequestTypeID: func() bin.Object { return &GetRecoveryEmailAddressRequest{} }, + SetRecoveryEmailAddressRequestTypeID: func() bin.Object { return &SetRecoveryEmailAddressRequest{} }, + CheckRecoveryEmailAddressCodeRequestTypeID: func() bin.Object { return &CheckRecoveryEmailAddressCodeRequest{} }, + ResendRecoveryEmailAddressCodeRequestTypeID: func() bin.Object { return &ResendRecoveryEmailAddressCodeRequest{} }, + CancelRecoveryEmailAddressVerificationRequestTypeID: func() bin.Object { return &CancelRecoveryEmailAddressVerificationRequest{} }, + RequestPasswordRecoveryRequestTypeID: func() bin.Object { return &RequestPasswordRecoveryRequest{} }, + CheckPasswordRecoveryCodeRequestTypeID: func() bin.Object { return &CheckPasswordRecoveryCodeRequest{} }, + RecoverPasswordRequestTypeID: func() bin.Object { return &RecoverPasswordRequest{} }, + ResetPasswordRequestTypeID: func() bin.Object { return &ResetPasswordRequest{} }, + CancelPasswordResetRequestTypeID: func() bin.Object { return &CancelPasswordResetRequest{} }, + CreateTemporaryPasswordRequestTypeID: func() bin.Object { return &CreateTemporaryPasswordRequest{} }, + GetTemporaryPasswordStateRequestTypeID: func() bin.Object { return &GetTemporaryPasswordStateRequest{} }, + GetMeRequestTypeID: func() bin.Object { return &GetMeRequest{} }, + GetUserRequestTypeID: func() bin.Object { return &GetUserRequest{} }, + GetUserFullInfoRequestTypeID: func() bin.Object { return &GetUserFullInfoRequest{} }, + GetBasicGroupRequestTypeID: func() bin.Object { return &GetBasicGroupRequest{} }, + GetBasicGroupFullInfoRequestTypeID: func() bin.Object { return &GetBasicGroupFullInfoRequest{} }, + GetSupergroupRequestTypeID: func() bin.Object { return &GetSupergroupRequest{} }, + GetSupergroupFullInfoRequestTypeID: func() bin.Object { return &GetSupergroupFullInfoRequest{} }, + GetSecretChatRequestTypeID: func() bin.Object { return &GetSecretChatRequest{} }, + GetChatRequestTypeID: func() bin.Object { return &GetChatRequest{} }, + GetMessageRequestTypeID: func() bin.Object { return &GetMessageRequest{} }, + GetMessageLocallyRequestTypeID: func() bin.Object { return &GetMessageLocallyRequest{} }, + GetRepliedMessageRequestTypeID: func() bin.Object { return &GetRepliedMessageRequest{} }, + GetChatPinnedMessageRequestTypeID: func() bin.Object { return &GetChatPinnedMessageRequest{} }, + GetCallbackQueryMessageRequestTypeID: func() bin.Object { return &GetCallbackQueryMessageRequest{} }, + GetMessagesRequestTypeID: func() bin.Object { return &GetMessagesRequest{} }, + GetMessagePropertiesRequestTypeID: func() bin.Object { return &GetMessagePropertiesRequest{} }, + GetMessageThreadRequestTypeID: func() bin.Object { return &GetMessageThreadRequest{} }, + GetMessageReadDateRequestTypeID: func() bin.Object { return &GetMessageReadDateRequest{} }, + GetMessageViewersRequestTypeID: func() bin.Object { return &GetMessageViewersRequest{} }, + GetFileRequestTypeID: func() bin.Object { return &GetFileRequest{} }, + GetRemoteFileRequestTypeID: func() bin.Object { return &GetRemoteFileRequest{} }, + LoadChatsRequestTypeID: func() bin.Object { return &LoadChatsRequest{} }, + GetChatsRequestTypeID: func() bin.Object { return &GetChatsRequest{} }, + SearchPublicChatRequestTypeID: func() bin.Object { return &SearchPublicChatRequest{} }, + SearchPublicChatsRequestTypeID: func() bin.Object { return &SearchPublicChatsRequest{} }, + SearchChatsRequestTypeID: func() bin.Object { return &SearchChatsRequest{} }, + SearchChatsOnServerRequestTypeID: func() bin.Object { return &SearchChatsOnServerRequest{} }, + SearchChatsNearbyRequestTypeID: func() bin.Object { return &SearchChatsNearbyRequest{} }, + GetRecommendedChatsRequestTypeID: func() bin.Object { return &GetRecommendedChatsRequest{} }, + GetChatSimilarChatsRequestTypeID: func() bin.Object { return &GetChatSimilarChatsRequest{} }, + GetChatSimilarChatCountRequestTypeID: func() bin.Object { return &GetChatSimilarChatCountRequest{} }, + OpenChatSimilarChatRequestTypeID: func() bin.Object { return &OpenChatSimilarChatRequest{} }, + GetTopChatsRequestTypeID: func() bin.Object { return &GetTopChatsRequest{} }, + RemoveTopChatRequestTypeID: func() bin.Object { return &RemoveTopChatRequest{} }, + SearchRecentlyFoundChatsRequestTypeID: func() bin.Object { return &SearchRecentlyFoundChatsRequest{} }, + AddRecentlyFoundChatRequestTypeID: func() bin.Object { return &AddRecentlyFoundChatRequest{} }, + RemoveRecentlyFoundChatRequestTypeID: func() bin.Object { return &RemoveRecentlyFoundChatRequest{} }, + ClearRecentlyFoundChatsRequestTypeID: func() bin.Object { return &ClearRecentlyFoundChatsRequest{} }, + GetRecentlyOpenedChatsRequestTypeID: func() bin.Object { return &GetRecentlyOpenedChatsRequest{} }, + CheckChatUsernameRequestTypeID: func() bin.Object { return &CheckChatUsernameRequest{} }, + GetCreatedPublicChatsRequestTypeID: func() bin.Object { return &GetCreatedPublicChatsRequest{} }, + CheckCreatedPublicChatsLimitRequestTypeID: func() bin.Object { return &CheckCreatedPublicChatsLimitRequest{} }, + GetSuitableDiscussionChatsRequestTypeID: func() bin.Object { return &GetSuitableDiscussionChatsRequest{} }, + GetInactiveSupergroupChatsRequestTypeID: func() bin.Object { return &GetInactiveSupergroupChatsRequest{} }, + GetSuitablePersonalChatsRequestTypeID: func() bin.Object { return &GetSuitablePersonalChatsRequest{} }, + LoadSavedMessagesTopicsRequestTypeID: func() bin.Object { return &LoadSavedMessagesTopicsRequest{} }, + GetSavedMessagesTopicHistoryRequestTypeID: func() bin.Object { return &GetSavedMessagesTopicHistoryRequest{} }, + GetSavedMessagesTopicMessageByDateRequestTypeID: func() bin.Object { return &GetSavedMessagesTopicMessageByDateRequest{} }, + DeleteSavedMessagesTopicHistoryRequestTypeID: func() bin.Object { return &DeleteSavedMessagesTopicHistoryRequest{} }, + DeleteSavedMessagesTopicMessagesByDateRequestTypeID: func() bin.Object { return &DeleteSavedMessagesTopicMessagesByDateRequest{} }, + ToggleSavedMessagesTopicIsPinnedRequestTypeID: func() bin.Object { return &ToggleSavedMessagesTopicIsPinnedRequest{} }, + SetPinnedSavedMessagesTopicsRequestTypeID: func() bin.Object { return &SetPinnedSavedMessagesTopicsRequest{} }, + GetGroupsInCommonRequestTypeID: func() bin.Object { return &GetGroupsInCommonRequest{} }, + GetChatHistoryRequestTypeID: func() bin.Object { return &GetChatHistoryRequest{} }, + GetMessageThreadHistoryRequestTypeID: func() bin.Object { return &GetMessageThreadHistoryRequest{} }, + DeleteChatHistoryRequestTypeID: func() bin.Object { return &DeleteChatHistoryRequest{} }, + DeleteChatRequestTypeID: func() bin.Object { return &DeleteChatRequest{} }, + SearchChatMessagesRequestTypeID: func() bin.Object { return &SearchChatMessagesRequest{} }, + SearchMessagesRequestTypeID: func() bin.Object { return &SearchMessagesRequest{} }, + SearchSecretMessagesRequestTypeID: func() bin.Object { return &SearchSecretMessagesRequest{} }, + SearchSavedMessagesRequestTypeID: func() bin.Object { return &SearchSavedMessagesRequest{} }, + SearchCallMessagesRequestTypeID: func() bin.Object { return &SearchCallMessagesRequest{} }, + SearchOutgoingDocumentMessagesRequestTypeID: func() bin.Object { return &SearchOutgoingDocumentMessagesRequest{} }, + SearchPublicMessagesByTagRequestTypeID: func() bin.Object { return &SearchPublicMessagesByTagRequest{} }, + SearchPublicStoriesByTagRequestTypeID: func() bin.Object { return &SearchPublicStoriesByTagRequest{} }, + SearchPublicStoriesByLocationRequestTypeID: func() bin.Object { return &SearchPublicStoriesByLocationRequest{} }, + SearchPublicStoriesByVenueRequestTypeID: func() bin.Object { return &SearchPublicStoriesByVenueRequest{} }, + GetSearchedForTagsRequestTypeID: func() bin.Object { return &GetSearchedForTagsRequest{} }, + RemoveSearchedForTagRequestTypeID: func() bin.Object { return &RemoveSearchedForTagRequest{} }, + ClearSearchedForTagsRequestTypeID: func() bin.Object { return &ClearSearchedForTagsRequest{} }, + DeleteAllCallMessagesRequestTypeID: func() bin.Object { return &DeleteAllCallMessagesRequest{} }, + SearchChatRecentLocationMessagesRequestTypeID: func() bin.Object { return &SearchChatRecentLocationMessagesRequest{} }, + GetChatMessageByDateRequestTypeID: func() bin.Object { return &GetChatMessageByDateRequest{} }, + GetChatSparseMessagePositionsRequestTypeID: func() bin.Object { return &GetChatSparseMessagePositionsRequest{} }, + GetChatMessageCalendarRequestTypeID: func() bin.Object { return &GetChatMessageCalendarRequest{} }, + GetChatMessageCountRequestTypeID: func() bin.Object { return &GetChatMessageCountRequest{} }, + GetChatMessagePositionRequestTypeID: func() bin.Object { return &GetChatMessagePositionRequest{} }, + GetChatScheduledMessagesRequestTypeID: func() bin.Object { return &GetChatScheduledMessagesRequest{} }, + GetChatSponsoredMessagesRequestTypeID: func() bin.Object { return &GetChatSponsoredMessagesRequest{} }, + ClickChatSponsoredMessageRequestTypeID: func() bin.Object { return &ClickChatSponsoredMessageRequest{} }, + ReportChatSponsoredMessageRequestTypeID: func() bin.Object { return &ReportChatSponsoredMessageRequest{} }, + RemoveNotificationRequestTypeID: func() bin.Object { return &RemoveNotificationRequest{} }, + RemoveNotificationGroupRequestTypeID: func() bin.Object { return &RemoveNotificationGroupRequest{} }, + GetMessageLinkRequestTypeID: func() bin.Object { return &GetMessageLinkRequest{} }, + GetMessageEmbeddingCodeRequestTypeID: func() bin.Object { return &GetMessageEmbeddingCodeRequest{} }, + GetMessageLinkInfoRequestTypeID: func() bin.Object { return &GetMessageLinkInfoRequest{} }, + TranslateTextRequestTypeID: func() bin.Object { return &TranslateTextRequest{} }, + TranslateMessageTextRequestTypeID: func() bin.Object { return &TranslateMessageTextRequest{} }, + RecognizeSpeechRequestTypeID: func() bin.Object { return &RecognizeSpeechRequest{} }, + RateSpeechRecognitionRequestTypeID: func() bin.Object { return &RateSpeechRecognitionRequest{} }, + GetChatAvailableMessageSendersRequestTypeID: func() bin.Object { return &GetChatAvailableMessageSendersRequest{} }, + SetChatMessageSenderRequestTypeID: func() bin.Object { return &SetChatMessageSenderRequest{} }, + SendMessageRequestTypeID: func() bin.Object { return &SendMessageRequest{} }, + SendMessageAlbumRequestTypeID: func() bin.Object { return &SendMessageAlbumRequest{} }, + SendBotStartMessageRequestTypeID: func() bin.Object { return &SendBotStartMessageRequest{} }, + SendInlineQueryResultMessageRequestTypeID: func() bin.Object { return &SendInlineQueryResultMessageRequest{} }, + ForwardMessagesRequestTypeID: func() bin.Object { return &ForwardMessagesRequest{} }, + SendQuickReplyShortcutMessagesRequestTypeID: func() bin.Object { return &SendQuickReplyShortcutMessagesRequest{} }, + ResendMessagesRequestTypeID: func() bin.Object { return &ResendMessagesRequest{} }, + AddLocalMessageRequestTypeID: func() bin.Object { return &AddLocalMessageRequest{} }, + DeleteMessagesRequestTypeID: func() bin.Object { return &DeleteMessagesRequest{} }, + DeleteChatMessagesBySenderRequestTypeID: func() bin.Object { return &DeleteChatMessagesBySenderRequest{} }, + DeleteChatMessagesByDateRequestTypeID: func() bin.Object { return &DeleteChatMessagesByDateRequest{} }, + EditMessageTextRequestTypeID: func() bin.Object { return &EditMessageTextRequest{} }, + EditMessageLiveLocationRequestTypeID: func() bin.Object { return &EditMessageLiveLocationRequest{} }, + EditMessageMediaRequestTypeID: func() bin.Object { return &EditMessageMediaRequest{} }, + EditMessageCaptionRequestTypeID: func() bin.Object { return &EditMessageCaptionRequest{} }, + EditMessageReplyMarkupRequestTypeID: func() bin.Object { return &EditMessageReplyMarkupRequest{} }, + EditInlineMessageTextRequestTypeID: func() bin.Object { return &EditInlineMessageTextRequest{} }, + EditInlineMessageLiveLocationRequestTypeID: func() bin.Object { return &EditInlineMessageLiveLocationRequest{} }, + EditInlineMessageMediaRequestTypeID: func() bin.Object { return &EditInlineMessageMediaRequest{} }, + EditInlineMessageCaptionRequestTypeID: func() bin.Object { return &EditInlineMessageCaptionRequest{} }, + EditInlineMessageReplyMarkupRequestTypeID: func() bin.Object { return &EditInlineMessageReplyMarkupRequest{} }, + EditMessageSchedulingStateRequestTypeID: func() bin.Object { return &EditMessageSchedulingStateRequest{} }, + SetMessageFactCheckRequestTypeID: func() bin.Object { return &SetMessageFactCheckRequest{} }, + SendBusinessMessageRequestTypeID: func() bin.Object { return &SendBusinessMessageRequest{} }, + SendBusinessMessageAlbumRequestTypeID: func() bin.Object { return &SendBusinessMessageAlbumRequest{} }, + EditBusinessMessageTextRequestTypeID: func() bin.Object { return &EditBusinessMessageTextRequest{} }, + EditBusinessMessageLiveLocationRequestTypeID: func() bin.Object { return &EditBusinessMessageLiveLocationRequest{} }, + EditBusinessMessageMediaRequestTypeID: func() bin.Object { return &EditBusinessMessageMediaRequest{} }, + EditBusinessMessageCaptionRequestTypeID: func() bin.Object { return &EditBusinessMessageCaptionRequest{} }, + EditBusinessMessageReplyMarkupRequestTypeID: func() bin.Object { return &EditBusinessMessageReplyMarkupRequest{} }, + StopBusinessPollRequestTypeID: func() bin.Object { return &StopBusinessPollRequest{} }, + SetBusinessMessageIsPinnedRequestTypeID: func() bin.Object { return &SetBusinessMessageIsPinnedRequest{} }, + CheckQuickReplyShortcutNameRequestTypeID: func() bin.Object { return &CheckQuickReplyShortcutNameRequest{} }, + LoadQuickReplyShortcutsRequestTypeID: func() bin.Object { return &LoadQuickReplyShortcutsRequest{} }, + SetQuickReplyShortcutNameRequestTypeID: func() bin.Object { return &SetQuickReplyShortcutNameRequest{} }, + DeleteQuickReplyShortcutRequestTypeID: func() bin.Object { return &DeleteQuickReplyShortcutRequest{} }, + ReorderQuickReplyShortcutsRequestTypeID: func() bin.Object { return &ReorderQuickReplyShortcutsRequest{} }, + LoadQuickReplyShortcutMessagesRequestTypeID: func() bin.Object { return &LoadQuickReplyShortcutMessagesRequest{} }, + DeleteQuickReplyShortcutMessagesRequestTypeID: func() bin.Object { return &DeleteQuickReplyShortcutMessagesRequest{} }, + AddQuickReplyShortcutMessageRequestTypeID: func() bin.Object { return &AddQuickReplyShortcutMessageRequest{} }, + AddQuickReplyShortcutInlineQueryResultMessageRequestTypeID: func() bin.Object { return &AddQuickReplyShortcutInlineQueryResultMessageRequest{} }, + AddQuickReplyShortcutMessageAlbumRequestTypeID: func() bin.Object { return &AddQuickReplyShortcutMessageAlbumRequest{} }, + ReaddQuickReplyShortcutMessagesRequestTypeID: func() bin.Object { return &ReaddQuickReplyShortcutMessagesRequest{} }, + EditQuickReplyMessageRequestTypeID: func() bin.Object { return &EditQuickReplyMessageRequest{} }, + GetForumTopicDefaultIconsRequestTypeID: func() bin.Object { return &GetForumTopicDefaultIconsRequest{} }, + CreateForumTopicRequestTypeID: func() bin.Object { return &CreateForumTopicRequest{} }, + EditForumTopicRequestTypeID: func() bin.Object { return &EditForumTopicRequest{} }, + GetForumTopicRequestTypeID: func() bin.Object { return &GetForumTopicRequest{} }, + GetForumTopicLinkRequestTypeID: func() bin.Object { return &GetForumTopicLinkRequest{} }, + GetForumTopicsRequestTypeID: func() bin.Object { return &GetForumTopicsRequest{} }, + SetForumTopicNotificationSettingsRequestTypeID: func() bin.Object { return &SetForumTopicNotificationSettingsRequest{} }, + ToggleForumTopicIsClosedRequestTypeID: func() bin.Object { return &ToggleForumTopicIsClosedRequest{} }, + ToggleGeneralForumTopicIsHiddenRequestTypeID: func() bin.Object { return &ToggleGeneralForumTopicIsHiddenRequest{} }, + ToggleForumTopicIsPinnedRequestTypeID: func() bin.Object { return &ToggleForumTopicIsPinnedRequest{} }, + SetPinnedForumTopicsRequestTypeID: func() bin.Object { return &SetPinnedForumTopicsRequest{} }, + DeleteForumTopicRequestTypeID: func() bin.Object { return &DeleteForumTopicRequest{} }, + GetEmojiReactionRequestTypeID: func() bin.Object { return &GetEmojiReactionRequest{} }, + GetCustomEmojiReactionAnimationsRequestTypeID: func() bin.Object { return &GetCustomEmojiReactionAnimationsRequest{} }, + GetMessageAvailableReactionsRequestTypeID: func() bin.Object { return &GetMessageAvailableReactionsRequest{} }, + ClearRecentReactionsRequestTypeID: func() bin.Object { return &ClearRecentReactionsRequest{} }, + AddMessageReactionRequestTypeID: func() bin.Object { return &AddMessageReactionRequest{} }, + RemoveMessageReactionRequestTypeID: func() bin.Object { return &RemoveMessageReactionRequest{} }, + AddPaidMessageReactionRequestTypeID: func() bin.Object { return &AddPaidMessageReactionRequest{} }, + RemovePendingPaidMessageReactionsRequestTypeID: func() bin.Object { return &RemovePendingPaidMessageReactionsRequest{} }, + TogglePaidMessageReactionIsAnonymousRequestTypeID: func() bin.Object { return &TogglePaidMessageReactionIsAnonymousRequest{} }, + SetMessageReactionsRequestTypeID: func() bin.Object { return &SetMessageReactionsRequest{} }, + GetMessageAddedReactionsRequestTypeID: func() bin.Object { return &GetMessageAddedReactionsRequest{} }, + SetDefaultReactionTypeRequestTypeID: func() bin.Object { return &SetDefaultReactionTypeRequest{} }, + GetSavedMessagesTagsRequestTypeID: func() bin.Object { return &GetSavedMessagesTagsRequest{} }, + SetSavedMessagesTagLabelRequestTypeID: func() bin.Object { return &SetSavedMessagesTagLabelRequest{} }, + GetMessageEffectRequestTypeID: func() bin.Object { return &GetMessageEffectRequest{} }, + SearchQuoteRequestTypeID: func() bin.Object { return &SearchQuoteRequest{} }, + GetTextEntitiesRequestTypeID: func() bin.Object { return &GetTextEntitiesRequest{} }, + ParseTextEntitiesRequestTypeID: func() bin.Object { return &ParseTextEntitiesRequest{} }, + ParseMarkdownRequestTypeID: func() bin.Object { return &ParseMarkdownRequest{} }, + GetMarkdownTextRequestTypeID: func() bin.Object { return &GetMarkdownTextRequest{} }, + GetCountryFlagEmojiRequestTypeID: func() bin.Object { return &GetCountryFlagEmojiRequest{} }, + GetFileMimeTypeRequestTypeID: func() bin.Object { return &GetFileMimeTypeRequest{} }, + GetFileExtensionRequestTypeID: func() bin.Object { return &GetFileExtensionRequest{} }, + CleanFileNameRequestTypeID: func() bin.Object { return &CleanFileNameRequest{} }, + GetLanguagePackStringRequestTypeID: func() bin.Object { return &GetLanguagePackStringRequest{} }, + GetJSONValueRequestTypeID: func() bin.Object { return &GetJSONValueRequest{} }, + GetJSONStringRequestTypeID: func() bin.Object { return &GetJSONStringRequest{} }, + GetThemeParametersJSONStringRequestTypeID: func() bin.Object { return &GetThemeParametersJSONStringRequest{} }, + SetPollAnswerRequestTypeID: func() bin.Object { return &SetPollAnswerRequest{} }, + GetPollVotersRequestTypeID: func() bin.Object { return &GetPollVotersRequest{} }, + StopPollRequestTypeID: func() bin.Object { return &StopPollRequest{} }, + HideSuggestedActionRequestTypeID: func() bin.Object { return &HideSuggestedActionRequest{} }, + HideContactCloseBirthdaysRequestTypeID: func() bin.Object { return &HideContactCloseBirthdaysRequest{} }, + GetBusinessConnectionRequestTypeID: func() bin.Object { return &GetBusinessConnectionRequest{} }, + GetLoginURLInfoRequestTypeID: func() bin.Object { return &GetLoginURLInfoRequest{} }, + GetLoginURLRequestTypeID: func() bin.Object { return &GetLoginURLRequest{} }, + ShareUsersWithBotRequestTypeID: func() bin.Object { return &ShareUsersWithBotRequest{} }, + ShareChatWithBotRequestTypeID: func() bin.Object { return &ShareChatWithBotRequest{} }, + GetInlineQueryResultsRequestTypeID: func() bin.Object { return &GetInlineQueryResultsRequest{} }, + AnswerInlineQueryRequestTypeID: func() bin.Object { return &AnswerInlineQueryRequest{} }, + GetPopularWebAppBotsRequestTypeID: func() bin.Object { return &GetPopularWebAppBotsRequest{} }, + SearchWebAppRequestTypeID: func() bin.Object { return &SearchWebAppRequest{} }, + GetWebAppLinkURLRequestTypeID: func() bin.Object { return &GetWebAppLinkURLRequest{} }, + GetMainWebAppRequestTypeID: func() bin.Object { return &GetMainWebAppRequest{} }, + GetWebAppURLRequestTypeID: func() bin.Object { return &GetWebAppURLRequest{} }, + SendWebAppDataRequestTypeID: func() bin.Object { return &SendWebAppDataRequest{} }, + OpenWebAppRequestTypeID: func() bin.Object { return &OpenWebAppRequest{} }, + CloseWebAppRequestTypeID: func() bin.Object { return &CloseWebAppRequest{} }, + AnswerWebAppQueryRequestTypeID: func() bin.Object { return &AnswerWebAppQueryRequest{} }, + GetCallbackQueryAnswerRequestTypeID: func() bin.Object { return &GetCallbackQueryAnswerRequest{} }, + AnswerCallbackQueryRequestTypeID: func() bin.Object { return &AnswerCallbackQueryRequest{} }, + AnswerShippingQueryRequestTypeID: func() bin.Object { return &AnswerShippingQueryRequest{} }, + AnswerPreCheckoutQueryRequestTypeID: func() bin.Object { return &AnswerPreCheckoutQueryRequest{} }, + SetGameScoreRequestTypeID: func() bin.Object { return &SetGameScoreRequest{} }, + SetInlineGameScoreRequestTypeID: func() bin.Object { return &SetInlineGameScoreRequest{} }, + GetGameHighScoresRequestTypeID: func() bin.Object { return &GetGameHighScoresRequest{} }, + GetInlineGameHighScoresRequestTypeID: func() bin.Object { return &GetInlineGameHighScoresRequest{} }, + DeleteChatReplyMarkupRequestTypeID: func() bin.Object { return &DeleteChatReplyMarkupRequest{} }, + SendChatActionRequestTypeID: func() bin.Object { return &SendChatActionRequest{} }, + OpenChatRequestTypeID: func() bin.Object { return &OpenChatRequest{} }, + CloseChatRequestTypeID: func() bin.Object { return &CloseChatRequest{} }, + ViewMessagesRequestTypeID: func() bin.Object { return &ViewMessagesRequest{} }, + OpenMessageContentRequestTypeID: func() bin.Object { return &OpenMessageContentRequest{} }, + ClickAnimatedEmojiMessageRequestTypeID: func() bin.Object { return &ClickAnimatedEmojiMessageRequest{} }, + GetInternalLinkRequestTypeID: func() bin.Object { return &GetInternalLinkRequest{} }, + GetInternalLinkTypeRequestTypeID: func() bin.Object { return &GetInternalLinkTypeRequest{} }, + GetExternalLinkInfoRequestTypeID: func() bin.Object { return &GetExternalLinkInfoRequest{} }, + GetExternalLinkRequestTypeID: func() bin.Object { return &GetExternalLinkRequest{} }, + ReadAllChatMentionsRequestTypeID: func() bin.Object { return &ReadAllChatMentionsRequest{} }, + ReadAllMessageThreadMentionsRequestTypeID: func() bin.Object { return &ReadAllMessageThreadMentionsRequest{} }, + ReadAllChatReactionsRequestTypeID: func() bin.Object { return &ReadAllChatReactionsRequest{} }, + ReadAllMessageThreadReactionsRequestTypeID: func() bin.Object { return &ReadAllMessageThreadReactionsRequest{} }, + CreatePrivateChatRequestTypeID: func() bin.Object { return &CreatePrivateChatRequest{} }, + CreateBasicGroupChatRequestTypeID: func() bin.Object { return &CreateBasicGroupChatRequest{} }, + CreateSupergroupChatRequestTypeID: func() bin.Object { return &CreateSupergroupChatRequest{} }, + CreateSecretChatRequestTypeID: func() bin.Object { return &CreateSecretChatRequest{} }, + CreateNewBasicGroupChatRequestTypeID: func() bin.Object { return &CreateNewBasicGroupChatRequest{} }, + CreateNewSupergroupChatRequestTypeID: func() bin.Object { return &CreateNewSupergroupChatRequest{} }, + CreateNewSecretChatRequestTypeID: func() bin.Object { return &CreateNewSecretChatRequest{} }, + UpgradeBasicGroupChatToSupergroupChatRequestTypeID: func() bin.Object { return &UpgradeBasicGroupChatToSupergroupChatRequest{} }, + GetChatListsToAddChatRequestTypeID: func() bin.Object { return &GetChatListsToAddChatRequest{} }, + AddChatToListRequestTypeID: func() bin.Object { return &AddChatToListRequest{} }, + GetChatFolderRequestTypeID: func() bin.Object { return &GetChatFolderRequest{} }, + CreateChatFolderRequestTypeID: func() bin.Object { return &CreateChatFolderRequest{} }, + EditChatFolderRequestTypeID: func() bin.Object { return &EditChatFolderRequest{} }, + DeleteChatFolderRequestTypeID: func() bin.Object { return &DeleteChatFolderRequest{} }, + GetChatFolderChatsToLeaveRequestTypeID: func() bin.Object { return &GetChatFolderChatsToLeaveRequest{} }, + GetChatFolderChatCountRequestTypeID: func() bin.Object { return &GetChatFolderChatCountRequest{} }, + ReorderChatFoldersRequestTypeID: func() bin.Object { return &ReorderChatFoldersRequest{} }, + ToggleChatFolderTagsRequestTypeID: func() bin.Object { return &ToggleChatFolderTagsRequest{} }, + GetRecommendedChatFoldersRequestTypeID: func() bin.Object { return &GetRecommendedChatFoldersRequest{} }, + GetChatFolderDefaultIconNameRequestTypeID: func() bin.Object { return &GetChatFolderDefaultIconNameRequest{} }, + GetChatsForChatFolderInviteLinkRequestTypeID: func() bin.Object { return &GetChatsForChatFolderInviteLinkRequest{} }, + CreateChatFolderInviteLinkRequestTypeID: func() bin.Object { return &CreateChatFolderInviteLinkRequest{} }, + GetChatFolderInviteLinksRequestTypeID: func() bin.Object { return &GetChatFolderInviteLinksRequest{} }, + EditChatFolderInviteLinkRequestTypeID: func() bin.Object { return &EditChatFolderInviteLinkRequest{} }, + DeleteChatFolderInviteLinkRequestTypeID: func() bin.Object { return &DeleteChatFolderInviteLinkRequest{} }, + CheckChatFolderInviteLinkRequestTypeID: func() bin.Object { return &CheckChatFolderInviteLinkRequest{} }, + AddChatFolderByInviteLinkRequestTypeID: func() bin.Object { return &AddChatFolderByInviteLinkRequest{} }, + GetChatFolderNewChatsRequestTypeID: func() bin.Object { return &GetChatFolderNewChatsRequest{} }, + ProcessChatFolderNewChatsRequestTypeID: func() bin.Object { return &ProcessChatFolderNewChatsRequest{} }, + GetArchiveChatListSettingsRequestTypeID: func() bin.Object { return &GetArchiveChatListSettingsRequest{} }, + SetArchiveChatListSettingsRequestTypeID: func() bin.Object { return &SetArchiveChatListSettingsRequest{} }, + SetChatTitleRequestTypeID: func() bin.Object { return &SetChatTitleRequest{} }, + SetChatPhotoRequestTypeID: func() bin.Object { return &SetChatPhotoRequest{} }, + SetChatAccentColorRequestTypeID: func() bin.Object { return &SetChatAccentColorRequest{} }, + SetChatProfileAccentColorRequestTypeID: func() bin.Object { return &SetChatProfileAccentColorRequest{} }, + SetChatMessageAutoDeleteTimeRequestTypeID: func() bin.Object { return &SetChatMessageAutoDeleteTimeRequest{} }, + SetChatEmojiStatusRequestTypeID: func() bin.Object { return &SetChatEmojiStatusRequest{} }, + SetChatPermissionsRequestTypeID: func() bin.Object { return &SetChatPermissionsRequest{} }, + SetChatBackgroundRequestTypeID: func() bin.Object { return &SetChatBackgroundRequest{} }, + DeleteChatBackgroundRequestTypeID: func() bin.Object { return &DeleteChatBackgroundRequest{} }, + SetChatThemeRequestTypeID: func() bin.Object { return &SetChatThemeRequest{} }, + SetChatDraftMessageRequestTypeID: func() bin.Object { return &SetChatDraftMessageRequest{} }, + SetChatNotificationSettingsRequestTypeID: func() bin.Object { return &SetChatNotificationSettingsRequest{} }, + ToggleChatHasProtectedContentRequestTypeID: func() bin.Object { return &ToggleChatHasProtectedContentRequest{} }, + ToggleChatViewAsTopicsRequestTypeID: func() bin.Object { return &ToggleChatViewAsTopicsRequest{} }, + ToggleChatIsTranslatableRequestTypeID: func() bin.Object { return &ToggleChatIsTranslatableRequest{} }, + ToggleChatIsMarkedAsUnreadRequestTypeID: func() bin.Object { return &ToggleChatIsMarkedAsUnreadRequest{} }, + ToggleChatDefaultDisableNotificationRequestTypeID: func() bin.Object { return &ToggleChatDefaultDisableNotificationRequest{} }, + SetChatAvailableReactionsRequestTypeID: func() bin.Object { return &SetChatAvailableReactionsRequest{} }, + SetChatClientDataRequestTypeID: func() bin.Object { return &SetChatClientDataRequest{} }, + SetChatDescriptionRequestTypeID: func() bin.Object { return &SetChatDescriptionRequest{} }, + SetChatDiscussionGroupRequestTypeID: func() bin.Object { return &SetChatDiscussionGroupRequest{} }, + SetChatLocationRequestTypeID: func() bin.Object { return &SetChatLocationRequest{} }, + SetChatSlowModeDelayRequestTypeID: func() bin.Object { return &SetChatSlowModeDelayRequest{} }, + PinChatMessageRequestTypeID: func() bin.Object { return &PinChatMessageRequest{} }, + UnpinChatMessageRequestTypeID: func() bin.Object { return &UnpinChatMessageRequest{} }, + UnpinAllChatMessagesRequestTypeID: func() bin.Object { return &UnpinAllChatMessagesRequest{} }, + UnpinAllMessageThreadMessagesRequestTypeID: func() bin.Object { return &UnpinAllMessageThreadMessagesRequest{} }, + JoinChatRequestTypeID: func() bin.Object { return &JoinChatRequest{} }, + LeaveChatRequestTypeID: func() bin.Object { return &LeaveChatRequest{} }, + AddChatMemberRequestTypeID: func() bin.Object { return &AddChatMemberRequest{} }, + AddChatMembersRequestTypeID: func() bin.Object { return &AddChatMembersRequest{} }, + SetChatMemberStatusRequestTypeID: func() bin.Object { return &SetChatMemberStatusRequest{} }, + BanChatMemberRequestTypeID: func() bin.Object { return &BanChatMemberRequest{} }, + CanTransferOwnershipRequestTypeID: func() bin.Object { return &CanTransferOwnershipRequest{} }, + TransferChatOwnershipRequestTypeID: func() bin.Object { return &TransferChatOwnershipRequest{} }, + GetChatMemberRequestTypeID: func() bin.Object { return &GetChatMemberRequest{} }, + SearchChatMembersRequestTypeID: func() bin.Object { return &SearchChatMembersRequest{} }, + GetChatAdministratorsRequestTypeID: func() bin.Object { return &GetChatAdministratorsRequest{} }, + ClearAllDraftMessagesRequestTypeID: func() bin.Object { return &ClearAllDraftMessagesRequest{} }, + GetSavedNotificationSoundRequestTypeID: func() bin.Object { return &GetSavedNotificationSoundRequest{} }, + GetSavedNotificationSoundsRequestTypeID: func() bin.Object { return &GetSavedNotificationSoundsRequest{} }, + AddSavedNotificationSoundRequestTypeID: func() bin.Object { return &AddSavedNotificationSoundRequest{} }, + RemoveSavedNotificationSoundRequestTypeID: func() bin.Object { return &RemoveSavedNotificationSoundRequest{} }, + GetChatNotificationSettingsExceptionsRequestTypeID: func() bin.Object { return &GetChatNotificationSettingsExceptionsRequest{} }, + GetScopeNotificationSettingsRequestTypeID: func() bin.Object { return &GetScopeNotificationSettingsRequest{} }, + SetScopeNotificationSettingsRequestTypeID: func() bin.Object { return &SetScopeNotificationSettingsRequest{} }, + SetReactionNotificationSettingsRequestTypeID: func() bin.Object { return &SetReactionNotificationSettingsRequest{} }, + ResetAllNotificationSettingsRequestTypeID: func() bin.Object { return &ResetAllNotificationSettingsRequest{} }, + ToggleChatIsPinnedRequestTypeID: func() bin.Object { return &ToggleChatIsPinnedRequest{} }, + SetPinnedChatsRequestTypeID: func() bin.Object { return &SetPinnedChatsRequest{} }, + ReadChatListRequestTypeID: func() bin.Object { return &ReadChatListRequest{} }, + GetCurrentWeatherRequestTypeID: func() bin.Object { return &GetCurrentWeatherRequest{} }, + GetStoryRequestTypeID: func() bin.Object { return &GetStoryRequest{} }, + GetChatsToSendStoriesRequestTypeID: func() bin.Object { return &GetChatsToSendStoriesRequest{} }, + CanSendStoryRequestTypeID: func() bin.Object { return &CanSendStoryRequest{} }, + SendStoryRequestTypeID: func() bin.Object { return &SendStoryRequest{} }, + EditStoryRequestTypeID: func() bin.Object { return &EditStoryRequest{} }, + EditStoryCoverRequestTypeID: func() bin.Object { return &EditStoryCoverRequest{} }, + SetStoryPrivacySettingsRequestTypeID: func() bin.Object { return &SetStoryPrivacySettingsRequest{} }, + ToggleStoryIsPostedToChatPageRequestTypeID: func() bin.Object { return &ToggleStoryIsPostedToChatPageRequest{} }, + DeleteStoryRequestTypeID: func() bin.Object { return &DeleteStoryRequest{} }, + GetStoryNotificationSettingsExceptionsRequestTypeID: func() bin.Object { return &GetStoryNotificationSettingsExceptionsRequest{} }, + LoadActiveStoriesRequestTypeID: func() bin.Object { return &LoadActiveStoriesRequest{} }, + SetChatActiveStoriesListRequestTypeID: func() bin.Object { return &SetChatActiveStoriesListRequest{} }, + GetChatActiveStoriesRequestTypeID: func() bin.Object { return &GetChatActiveStoriesRequest{} }, + GetChatPostedToChatPageStoriesRequestTypeID: func() bin.Object { return &GetChatPostedToChatPageStoriesRequest{} }, + GetChatArchivedStoriesRequestTypeID: func() bin.Object { return &GetChatArchivedStoriesRequest{} }, + SetChatPinnedStoriesRequestTypeID: func() bin.Object { return &SetChatPinnedStoriesRequest{} }, + OpenStoryRequestTypeID: func() bin.Object { return &OpenStoryRequest{} }, + CloseStoryRequestTypeID: func() bin.Object { return &CloseStoryRequest{} }, + GetStoryAvailableReactionsRequestTypeID: func() bin.Object { return &GetStoryAvailableReactionsRequest{} }, + SetStoryReactionRequestTypeID: func() bin.Object { return &SetStoryReactionRequest{} }, + GetStoryInteractionsRequestTypeID: func() bin.Object { return &GetStoryInteractionsRequest{} }, + GetChatStoryInteractionsRequestTypeID: func() bin.Object { return &GetChatStoryInteractionsRequest{} }, + ReportStoryRequestTypeID: func() bin.Object { return &ReportStoryRequest{} }, + ActivateStoryStealthModeRequestTypeID: func() bin.Object { return &ActivateStoryStealthModeRequest{} }, + GetStoryPublicForwardsRequestTypeID: func() bin.Object { return &GetStoryPublicForwardsRequest{} }, + GetChatBoostLevelFeaturesRequestTypeID: func() bin.Object { return &GetChatBoostLevelFeaturesRequest{} }, + GetChatBoostFeaturesRequestTypeID: func() bin.Object { return &GetChatBoostFeaturesRequest{} }, + GetAvailableChatBoostSlotsRequestTypeID: func() bin.Object { return &GetAvailableChatBoostSlotsRequest{} }, + GetChatBoostStatusRequestTypeID: func() bin.Object { return &GetChatBoostStatusRequest{} }, + BoostChatRequestTypeID: func() bin.Object { return &BoostChatRequest{} }, + GetChatBoostLinkRequestTypeID: func() bin.Object { return &GetChatBoostLinkRequest{} }, + GetChatBoostLinkInfoRequestTypeID: func() bin.Object { return &GetChatBoostLinkInfoRequest{} }, + GetChatBoostsRequestTypeID: func() bin.Object { return &GetChatBoostsRequest{} }, + GetUserChatBoostsRequestTypeID: func() bin.Object { return &GetUserChatBoostsRequest{} }, + GetAttachmentMenuBotRequestTypeID: func() bin.Object { return &GetAttachmentMenuBotRequest{} }, + ToggleBotIsAddedToAttachmentMenuRequestTypeID: func() bin.Object { return &ToggleBotIsAddedToAttachmentMenuRequest{} }, + GetThemedEmojiStatusesRequestTypeID: func() bin.Object { return &GetThemedEmojiStatusesRequest{} }, + GetRecentEmojiStatusesRequestTypeID: func() bin.Object { return &GetRecentEmojiStatusesRequest{} }, + GetDefaultEmojiStatusesRequestTypeID: func() bin.Object { return &GetDefaultEmojiStatusesRequest{} }, + ClearRecentEmojiStatusesRequestTypeID: func() bin.Object { return &ClearRecentEmojiStatusesRequest{} }, + GetThemedChatEmojiStatusesRequestTypeID: func() bin.Object { return &GetThemedChatEmojiStatusesRequest{} }, + GetDefaultChatEmojiStatusesRequestTypeID: func() bin.Object { return &GetDefaultChatEmojiStatusesRequest{} }, + GetDisallowedChatEmojiStatusesRequestTypeID: func() bin.Object { return &GetDisallowedChatEmojiStatusesRequest{} }, + DownloadFileRequestTypeID: func() bin.Object { return &DownloadFileRequest{} }, + GetFileDownloadedPrefixSizeRequestTypeID: func() bin.Object { return &GetFileDownloadedPrefixSizeRequest{} }, + CancelDownloadFileRequestTypeID: func() bin.Object { return &CancelDownloadFileRequest{} }, + GetSuggestedFileNameRequestTypeID: func() bin.Object { return &GetSuggestedFileNameRequest{} }, + PreliminaryUploadFileRequestTypeID: func() bin.Object { return &PreliminaryUploadFileRequest{} }, + CancelPreliminaryUploadFileRequestTypeID: func() bin.Object { return &CancelPreliminaryUploadFileRequest{} }, + WriteGeneratedFilePartRequestTypeID: func() bin.Object { return &WriteGeneratedFilePartRequest{} }, + SetFileGenerationProgressRequestTypeID: func() bin.Object { return &SetFileGenerationProgressRequest{} }, + FinishFileGenerationRequestTypeID: func() bin.Object { return &FinishFileGenerationRequest{} }, + ReadFilePartRequestTypeID: func() bin.Object { return &ReadFilePartRequest{} }, + DeleteFileRequestTypeID: func() bin.Object { return &DeleteFileRequest{} }, + AddFileToDownloadsRequestTypeID: func() bin.Object { return &AddFileToDownloadsRequest{} }, + ToggleDownloadIsPausedRequestTypeID: func() bin.Object { return &ToggleDownloadIsPausedRequest{} }, + ToggleAllDownloadsArePausedRequestTypeID: func() bin.Object { return &ToggleAllDownloadsArePausedRequest{} }, + RemoveFileFromDownloadsRequestTypeID: func() bin.Object { return &RemoveFileFromDownloadsRequest{} }, + RemoveAllFilesFromDownloadsRequestTypeID: func() bin.Object { return &RemoveAllFilesFromDownloadsRequest{} }, + SearchFileDownloadsRequestTypeID: func() bin.Object { return &SearchFileDownloadsRequest{} }, + SetApplicationVerificationTokenRequestTypeID: func() bin.Object { return &SetApplicationVerificationTokenRequest{} }, + GetMessageFileTypeRequestTypeID: func() bin.Object { return &GetMessageFileTypeRequest{} }, + GetMessageImportConfirmationTextRequestTypeID: func() bin.Object { return &GetMessageImportConfirmationTextRequest{} }, + ImportMessagesRequestTypeID: func() bin.Object { return &ImportMessagesRequest{} }, + ReplacePrimaryChatInviteLinkRequestTypeID: func() bin.Object { return &ReplacePrimaryChatInviteLinkRequest{} }, + CreateChatInviteLinkRequestTypeID: func() bin.Object { return &CreateChatInviteLinkRequest{} }, + CreateChatSubscriptionInviteLinkRequestTypeID: func() bin.Object { return &CreateChatSubscriptionInviteLinkRequest{} }, + EditChatInviteLinkRequestTypeID: func() bin.Object { return &EditChatInviteLinkRequest{} }, + EditChatSubscriptionInviteLinkRequestTypeID: func() bin.Object { return &EditChatSubscriptionInviteLinkRequest{} }, + GetChatInviteLinkRequestTypeID: func() bin.Object { return &GetChatInviteLinkRequest{} }, + GetChatInviteLinkCountsRequestTypeID: func() bin.Object { return &GetChatInviteLinkCountsRequest{} }, + GetChatInviteLinksRequestTypeID: func() bin.Object { return &GetChatInviteLinksRequest{} }, + GetChatInviteLinkMembersRequestTypeID: func() bin.Object { return &GetChatInviteLinkMembersRequest{} }, + RevokeChatInviteLinkRequestTypeID: func() bin.Object { return &RevokeChatInviteLinkRequest{} }, + DeleteRevokedChatInviteLinkRequestTypeID: func() bin.Object { return &DeleteRevokedChatInviteLinkRequest{} }, + DeleteAllRevokedChatInviteLinksRequestTypeID: func() bin.Object { return &DeleteAllRevokedChatInviteLinksRequest{} }, + CheckChatInviteLinkRequestTypeID: func() bin.Object { return &CheckChatInviteLinkRequest{} }, + JoinChatByInviteLinkRequestTypeID: func() bin.Object { return &JoinChatByInviteLinkRequest{} }, + GetChatJoinRequestsRequestTypeID: func() bin.Object { return &GetChatJoinRequestsRequest{} }, + ProcessChatJoinRequestRequestTypeID: func() bin.Object { return &ProcessChatJoinRequestRequest{} }, + ProcessChatJoinRequestsRequestTypeID: func() bin.Object { return &ProcessChatJoinRequestsRequest{} }, + CreateCallRequestTypeID: func() bin.Object { return &CreateCallRequest{} }, + AcceptCallRequestTypeID: func() bin.Object { return &AcceptCallRequest{} }, + SendCallSignalingDataRequestTypeID: func() bin.Object { return &SendCallSignalingDataRequest{} }, + DiscardCallRequestTypeID: func() bin.Object { return &DiscardCallRequest{} }, + SendCallRatingRequestTypeID: func() bin.Object { return &SendCallRatingRequest{} }, + SendCallDebugInformationRequestTypeID: func() bin.Object { return &SendCallDebugInformationRequest{} }, + SendCallLogRequestTypeID: func() bin.Object { return &SendCallLogRequest{} }, + GetVideoChatAvailableParticipantsRequestTypeID: func() bin.Object { return &GetVideoChatAvailableParticipantsRequest{} }, + SetVideoChatDefaultParticipantRequestTypeID: func() bin.Object { return &SetVideoChatDefaultParticipantRequest{} }, + CreateVideoChatRequestTypeID: func() bin.Object { return &CreateVideoChatRequest{} }, + GetVideoChatRtmpURLRequestTypeID: func() bin.Object { return &GetVideoChatRtmpURLRequest{} }, + ReplaceVideoChatRtmpURLRequestTypeID: func() bin.Object { return &ReplaceVideoChatRtmpURLRequest{} }, + GetGroupCallRequestTypeID: func() bin.Object { return &GetGroupCallRequest{} }, + StartScheduledGroupCallRequestTypeID: func() bin.Object { return &StartScheduledGroupCallRequest{} }, + ToggleGroupCallEnabledStartNotificationRequestTypeID: func() bin.Object { return &ToggleGroupCallEnabledStartNotificationRequest{} }, + JoinGroupCallRequestTypeID: func() bin.Object { return &JoinGroupCallRequest{} }, + StartGroupCallScreenSharingRequestTypeID: func() bin.Object { return &StartGroupCallScreenSharingRequest{} }, + ToggleGroupCallScreenSharingIsPausedRequestTypeID: func() bin.Object { return &ToggleGroupCallScreenSharingIsPausedRequest{} }, + EndGroupCallScreenSharingRequestTypeID: func() bin.Object { return &EndGroupCallScreenSharingRequest{} }, + SetGroupCallTitleRequestTypeID: func() bin.Object { return &SetGroupCallTitleRequest{} }, + ToggleGroupCallMuteNewParticipantsRequestTypeID: func() bin.Object { return &ToggleGroupCallMuteNewParticipantsRequest{} }, + InviteGroupCallParticipantsRequestTypeID: func() bin.Object { return &InviteGroupCallParticipantsRequest{} }, + GetGroupCallInviteLinkRequestTypeID: func() bin.Object { return &GetGroupCallInviteLinkRequest{} }, + RevokeGroupCallInviteLinkRequestTypeID: func() bin.Object { return &RevokeGroupCallInviteLinkRequest{} }, + StartGroupCallRecordingRequestTypeID: func() bin.Object { return &StartGroupCallRecordingRequest{} }, + EndGroupCallRecordingRequestTypeID: func() bin.Object { return &EndGroupCallRecordingRequest{} }, + ToggleGroupCallIsMyVideoPausedRequestTypeID: func() bin.Object { return &ToggleGroupCallIsMyVideoPausedRequest{} }, + ToggleGroupCallIsMyVideoEnabledRequestTypeID: func() bin.Object { return &ToggleGroupCallIsMyVideoEnabledRequest{} }, + SetGroupCallParticipantIsSpeakingRequestTypeID: func() bin.Object { return &SetGroupCallParticipantIsSpeakingRequest{} }, + ToggleGroupCallParticipantIsMutedRequestTypeID: func() bin.Object { return &ToggleGroupCallParticipantIsMutedRequest{} }, + SetGroupCallParticipantVolumeLevelRequestTypeID: func() bin.Object { return &SetGroupCallParticipantVolumeLevelRequest{} }, + ToggleGroupCallParticipantIsHandRaisedRequestTypeID: func() bin.Object { return &ToggleGroupCallParticipantIsHandRaisedRequest{} }, + LoadGroupCallParticipantsRequestTypeID: func() bin.Object { return &LoadGroupCallParticipantsRequest{} }, + LeaveGroupCallRequestTypeID: func() bin.Object { return &LeaveGroupCallRequest{} }, + EndGroupCallRequestTypeID: func() bin.Object { return &EndGroupCallRequest{} }, + GetGroupCallStreamsRequestTypeID: func() bin.Object { return &GetGroupCallStreamsRequest{} }, + GetGroupCallStreamSegmentRequestTypeID: func() bin.Object { return &GetGroupCallStreamSegmentRequest{} }, + SetMessageSenderBlockListRequestTypeID: func() bin.Object { return &SetMessageSenderBlockListRequest{} }, + BlockMessageSenderFromRepliesRequestTypeID: func() bin.Object { return &BlockMessageSenderFromRepliesRequest{} }, + GetBlockedMessageSendersRequestTypeID: func() bin.Object { return &GetBlockedMessageSendersRequest{} }, + AddContactRequestTypeID: func() bin.Object { return &AddContactRequest{} }, + ImportContactsRequestTypeID: func() bin.Object { return &ImportContactsRequest{} }, + GetContactsRequestTypeID: func() bin.Object { return &GetContactsRequest{} }, + SearchContactsRequestTypeID: func() bin.Object { return &SearchContactsRequest{} }, + RemoveContactsRequestTypeID: func() bin.Object { return &RemoveContactsRequest{} }, + GetImportedContactCountRequestTypeID: func() bin.Object { return &GetImportedContactCountRequest{} }, + ChangeImportedContactsRequestTypeID: func() bin.Object { return &ChangeImportedContactsRequest{} }, + ClearImportedContactsRequestTypeID: func() bin.Object { return &ClearImportedContactsRequest{} }, + SetCloseFriendsRequestTypeID: func() bin.Object { return &SetCloseFriendsRequest{} }, + GetCloseFriendsRequestTypeID: func() bin.Object { return &GetCloseFriendsRequest{} }, + SetUserPersonalProfilePhotoRequestTypeID: func() bin.Object { return &SetUserPersonalProfilePhotoRequest{} }, + SuggestUserProfilePhotoRequestTypeID: func() bin.Object { return &SuggestUserProfilePhotoRequest{} }, + SearchUserByPhoneNumberRequestTypeID: func() bin.Object { return &SearchUserByPhoneNumberRequest{} }, + SharePhoneNumberRequestTypeID: func() bin.Object { return &SharePhoneNumberRequest{} }, + GetUserProfilePhotosRequestTypeID: func() bin.Object { return &GetUserProfilePhotosRequest{} }, + GetStickersRequestTypeID: func() bin.Object { return &GetStickersRequest{} }, + GetAllStickerEmojisRequestTypeID: func() bin.Object { return &GetAllStickerEmojisRequest{} }, + SearchStickersRequestTypeID: func() bin.Object { return &SearchStickersRequest{} }, + GetGreetingStickersRequestTypeID: func() bin.Object { return &GetGreetingStickersRequest{} }, + GetPremiumStickersRequestTypeID: func() bin.Object { return &GetPremiumStickersRequest{} }, + GetInstalledStickerSetsRequestTypeID: func() bin.Object { return &GetInstalledStickerSetsRequest{} }, + GetArchivedStickerSetsRequestTypeID: func() bin.Object { return &GetArchivedStickerSetsRequest{} }, + GetTrendingStickerSetsRequestTypeID: func() bin.Object { return &GetTrendingStickerSetsRequest{} }, + GetAttachedStickerSetsRequestTypeID: func() bin.Object { return &GetAttachedStickerSetsRequest{} }, + GetStickerSetRequestTypeID: func() bin.Object { return &GetStickerSetRequest{} }, + SearchStickerSetRequestTypeID: func() bin.Object { return &SearchStickerSetRequest{} }, + SearchInstalledStickerSetsRequestTypeID: func() bin.Object { return &SearchInstalledStickerSetsRequest{} }, + SearchStickerSetsRequestTypeID: func() bin.Object { return &SearchStickerSetsRequest{} }, + ChangeStickerSetRequestTypeID: func() bin.Object { return &ChangeStickerSetRequest{} }, + ViewTrendingStickerSetsRequestTypeID: func() bin.Object { return &ViewTrendingStickerSetsRequest{} }, + ReorderInstalledStickerSetsRequestTypeID: func() bin.Object { return &ReorderInstalledStickerSetsRequest{} }, + GetRecentStickersRequestTypeID: func() bin.Object { return &GetRecentStickersRequest{} }, + AddRecentStickerRequestTypeID: func() bin.Object { return &AddRecentStickerRequest{} }, + RemoveRecentStickerRequestTypeID: func() bin.Object { return &RemoveRecentStickerRequest{} }, + ClearRecentStickersRequestTypeID: func() bin.Object { return &ClearRecentStickersRequest{} }, + GetFavoriteStickersRequestTypeID: func() bin.Object { return &GetFavoriteStickersRequest{} }, + AddFavoriteStickerRequestTypeID: func() bin.Object { return &AddFavoriteStickerRequest{} }, + RemoveFavoriteStickerRequestTypeID: func() bin.Object { return &RemoveFavoriteStickerRequest{} }, + GetStickerEmojisRequestTypeID: func() bin.Object { return &GetStickerEmojisRequest{} }, + SearchEmojisRequestTypeID: func() bin.Object { return &SearchEmojisRequest{} }, + GetKeywordEmojisRequestTypeID: func() bin.Object { return &GetKeywordEmojisRequest{} }, + GetEmojiCategoriesRequestTypeID: func() bin.Object { return &GetEmojiCategoriesRequest{} }, + GetAnimatedEmojiRequestTypeID: func() bin.Object { return &GetAnimatedEmojiRequest{} }, + GetEmojiSuggestionsURLRequestTypeID: func() bin.Object { return &GetEmojiSuggestionsURLRequest{} }, + GetCustomEmojiStickersRequestTypeID: func() bin.Object { return &GetCustomEmojiStickersRequest{} }, + GetDefaultChatPhotoCustomEmojiStickersRequestTypeID: func() bin.Object { return &GetDefaultChatPhotoCustomEmojiStickersRequest{} }, + GetDefaultProfilePhotoCustomEmojiStickersRequestTypeID: func() bin.Object { return &GetDefaultProfilePhotoCustomEmojiStickersRequest{} }, + GetDefaultBackgroundCustomEmojiStickersRequestTypeID: func() bin.Object { return &GetDefaultBackgroundCustomEmojiStickersRequest{} }, + GetSavedAnimationsRequestTypeID: func() bin.Object { return &GetSavedAnimationsRequest{} }, + AddSavedAnimationRequestTypeID: func() bin.Object { return &AddSavedAnimationRequest{} }, + RemoveSavedAnimationRequestTypeID: func() bin.Object { return &RemoveSavedAnimationRequest{} }, + GetRecentInlineBotsRequestTypeID: func() bin.Object { return &GetRecentInlineBotsRequest{} }, + SearchHashtagsRequestTypeID: func() bin.Object { return &SearchHashtagsRequest{} }, + RemoveRecentHashtagRequestTypeID: func() bin.Object { return &RemoveRecentHashtagRequest{} }, + GetLinkPreviewRequestTypeID: func() bin.Object { return &GetLinkPreviewRequest{} }, + GetWebPageInstantViewRequestTypeID: func() bin.Object { return &GetWebPageInstantViewRequest{} }, + SetProfilePhotoRequestTypeID: func() bin.Object { return &SetProfilePhotoRequest{} }, + DeleteProfilePhotoRequestTypeID: func() bin.Object { return &DeleteProfilePhotoRequest{} }, + SetAccentColorRequestTypeID: func() bin.Object { return &SetAccentColorRequest{} }, + SetProfileAccentColorRequestTypeID: func() bin.Object { return &SetProfileAccentColorRequest{} }, + SetNameRequestTypeID: func() bin.Object { return &SetNameRequest{} }, + SetBioRequestTypeID: func() bin.Object { return &SetBioRequest{} }, + SetUsernameRequestTypeID: func() bin.Object { return &SetUsernameRequest{} }, + ToggleUsernameIsActiveRequestTypeID: func() bin.Object { return &ToggleUsernameIsActiveRequest{} }, + ReorderActiveUsernamesRequestTypeID: func() bin.Object { return &ReorderActiveUsernamesRequest{} }, + SetBirthdateRequestTypeID: func() bin.Object { return &SetBirthdateRequest{} }, + SetPersonalChatRequestTypeID: func() bin.Object { return &SetPersonalChatRequest{} }, + SetEmojiStatusRequestTypeID: func() bin.Object { return &SetEmojiStatusRequest{} }, + SetLocationRequestTypeID: func() bin.Object { return &SetLocationRequest{} }, + ToggleHasSponsoredMessagesEnabledRequestTypeID: func() bin.Object { return &ToggleHasSponsoredMessagesEnabledRequest{} }, + SetBusinessLocationRequestTypeID: func() bin.Object { return &SetBusinessLocationRequest{} }, + SetBusinessOpeningHoursRequestTypeID: func() bin.Object { return &SetBusinessOpeningHoursRequest{} }, + SetBusinessGreetingMessageSettingsRequestTypeID: func() bin.Object { return &SetBusinessGreetingMessageSettingsRequest{} }, + SetBusinessAwayMessageSettingsRequestTypeID: func() bin.Object { return &SetBusinessAwayMessageSettingsRequest{} }, + SetBusinessStartPageRequestTypeID: func() bin.Object { return &SetBusinessStartPageRequest{} }, + SendPhoneNumberCodeRequestTypeID: func() bin.Object { return &SendPhoneNumberCodeRequest{} }, + SendPhoneNumberFirebaseSMSRequestTypeID: func() bin.Object { return &SendPhoneNumberFirebaseSMSRequest{} }, + ReportPhoneNumberCodeMissingRequestTypeID: func() bin.Object { return &ReportPhoneNumberCodeMissingRequest{} }, + ResendPhoneNumberCodeRequestTypeID: func() bin.Object { return &ResendPhoneNumberCodeRequest{} }, + CheckPhoneNumberCodeRequestTypeID: func() bin.Object { return &CheckPhoneNumberCodeRequest{} }, + GetBusinessConnectedBotRequestTypeID: func() bin.Object { return &GetBusinessConnectedBotRequest{} }, + SetBusinessConnectedBotRequestTypeID: func() bin.Object { return &SetBusinessConnectedBotRequest{} }, + DeleteBusinessConnectedBotRequestTypeID: func() bin.Object { return &DeleteBusinessConnectedBotRequest{} }, + ToggleBusinessConnectedBotChatIsPausedRequestTypeID: func() bin.Object { return &ToggleBusinessConnectedBotChatIsPausedRequest{} }, + RemoveBusinessConnectedBotFromChatRequestTypeID: func() bin.Object { return &RemoveBusinessConnectedBotFromChatRequest{} }, + GetBusinessChatLinksRequestTypeID: func() bin.Object { return &GetBusinessChatLinksRequest{} }, + CreateBusinessChatLinkRequestTypeID: func() bin.Object { return &CreateBusinessChatLinkRequest{} }, + EditBusinessChatLinkRequestTypeID: func() bin.Object { return &EditBusinessChatLinkRequest{} }, + DeleteBusinessChatLinkRequestTypeID: func() bin.Object { return &DeleteBusinessChatLinkRequest{} }, + GetBusinessChatLinkInfoRequestTypeID: func() bin.Object { return &GetBusinessChatLinkInfoRequest{} }, + GetUserLinkRequestTypeID: func() bin.Object { return &GetUserLinkRequest{} }, + SearchUserByTokenRequestTypeID: func() bin.Object { return &SearchUserByTokenRequest{} }, + SetCommandsRequestTypeID: func() bin.Object { return &SetCommandsRequest{} }, + DeleteCommandsRequestTypeID: func() bin.Object { return &DeleteCommandsRequest{} }, + GetCommandsRequestTypeID: func() bin.Object { return &GetCommandsRequest{} }, + SetMenuButtonRequestTypeID: func() bin.Object { return &SetMenuButtonRequest{} }, + GetMenuButtonRequestTypeID: func() bin.Object { return &GetMenuButtonRequest{} }, + SetDefaultGroupAdministratorRightsRequestTypeID: func() bin.Object { return &SetDefaultGroupAdministratorRightsRequest{} }, + SetDefaultChannelAdministratorRightsRequestTypeID: func() bin.Object { return &SetDefaultChannelAdministratorRightsRequest{} }, + CanBotSendMessagesRequestTypeID: func() bin.Object { return &CanBotSendMessagesRequest{} }, + AllowBotToSendMessagesRequestTypeID: func() bin.Object { return &AllowBotToSendMessagesRequest{} }, + SendWebAppCustomRequestRequestTypeID: func() bin.Object { return &SendWebAppCustomRequestRequest{} }, + GetBotMediaPreviewsRequestTypeID: func() bin.Object { return &GetBotMediaPreviewsRequest{} }, + GetBotMediaPreviewInfoRequestTypeID: func() bin.Object { return &GetBotMediaPreviewInfoRequest{} }, + AddBotMediaPreviewRequestTypeID: func() bin.Object { return &AddBotMediaPreviewRequest{} }, + EditBotMediaPreviewRequestTypeID: func() bin.Object { return &EditBotMediaPreviewRequest{} }, + ReorderBotMediaPreviewsRequestTypeID: func() bin.Object { return &ReorderBotMediaPreviewsRequest{} }, + DeleteBotMediaPreviewsRequestTypeID: func() bin.Object { return &DeleteBotMediaPreviewsRequest{} }, + SetBotNameRequestTypeID: func() bin.Object { return &SetBotNameRequest{} }, + GetBotNameRequestTypeID: func() bin.Object { return &GetBotNameRequest{} }, + SetBotProfilePhotoRequestTypeID: func() bin.Object { return &SetBotProfilePhotoRequest{} }, + ToggleBotUsernameIsActiveRequestTypeID: func() bin.Object { return &ToggleBotUsernameIsActiveRequest{} }, + ReorderBotActiveUsernamesRequestTypeID: func() bin.Object { return &ReorderBotActiveUsernamesRequest{} }, + SetBotInfoDescriptionRequestTypeID: func() bin.Object { return &SetBotInfoDescriptionRequest{} }, + GetBotInfoDescriptionRequestTypeID: func() bin.Object { return &GetBotInfoDescriptionRequest{} }, + SetBotInfoShortDescriptionRequestTypeID: func() bin.Object { return &SetBotInfoShortDescriptionRequest{} }, + GetBotInfoShortDescriptionRequestTypeID: func() bin.Object { return &GetBotInfoShortDescriptionRequest{} }, + GetActiveSessionsRequestTypeID: func() bin.Object { return &GetActiveSessionsRequest{} }, + TerminateSessionRequestTypeID: func() bin.Object { return &TerminateSessionRequest{} }, + TerminateAllOtherSessionsRequestTypeID: func() bin.Object { return &TerminateAllOtherSessionsRequest{} }, + ConfirmSessionRequestTypeID: func() bin.Object { return &ConfirmSessionRequest{} }, + ToggleSessionCanAcceptCallsRequestTypeID: func() bin.Object { return &ToggleSessionCanAcceptCallsRequest{} }, + ToggleSessionCanAcceptSecretChatsRequestTypeID: func() bin.Object { return &ToggleSessionCanAcceptSecretChatsRequest{} }, + SetInactiveSessionTTLRequestTypeID: func() bin.Object { return &SetInactiveSessionTTLRequest{} }, + GetConnectedWebsitesRequestTypeID: func() bin.Object { return &GetConnectedWebsitesRequest{} }, + DisconnectWebsiteRequestTypeID: func() bin.Object { return &DisconnectWebsiteRequest{} }, + DisconnectAllWebsitesRequestTypeID: func() bin.Object { return &DisconnectAllWebsitesRequest{} }, + SetSupergroupUsernameRequestTypeID: func() bin.Object { return &SetSupergroupUsernameRequest{} }, + ToggleSupergroupUsernameIsActiveRequestTypeID: func() bin.Object { return &ToggleSupergroupUsernameIsActiveRequest{} }, + DisableAllSupergroupUsernamesRequestTypeID: func() bin.Object { return &DisableAllSupergroupUsernamesRequest{} }, + ReorderSupergroupActiveUsernamesRequestTypeID: func() bin.Object { return &ReorderSupergroupActiveUsernamesRequest{} }, + SetSupergroupStickerSetRequestTypeID: func() bin.Object { return &SetSupergroupStickerSetRequest{} }, + SetSupergroupCustomEmojiStickerSetRequestTypeID: func() bin.Object { return &SetSupergroupCustomEmojiStickerSetRequest{} }, + SetSupergroupUnrestrictBoostCountRequestTypeID: func() bin.Object { return &SetSupergroupUnrestrictBoostCountRequest{} }, + ToggleSupergroupSignMessagesRequestTypeID: func() bin.Object { return &ToggleSupergroupSignMessagesRequest{} }, + ToggleSupergroupJoinToSendMessagesRequestTypeID: func() bin.Object { return &ToggleSupergroupJoinToSendMessagesRequest{} }, + ToggleSupergroupJoinByRequestRequestTypeID: func() bin.Object { return &ToggleSupergroupJoinByRequestRequest{} }, + ToggleSupergroupIsAllHistoryAvailableRequestTypeID: func() bin.Object { return &ToggleSupergroupIsAllHistoryAvailableRequest{} }, + ToggleSupergroupCanHaveSponsoredMessagesRequestTypeID: func() bin.Object { return &ToggleSupergroupCanHaveSponsoredMessagesRequest{} }, + ToggleSupergroupHasHiddenMembersRequestTypeID: func() bin.Object { return &ToggleSupergroupHasHiddenMembersRequest{} }, + ToggleSupergroupHasAggressiveAntiSpamEnabledRequestTypeID: func() bin.Object { return &ToggleSupergroupHasAggressiveAntiSpamEnabledRequest{} }, + ToggleSupergroupIsForumRequestTypeID: func() bin.Object { return &ToggleSupergroupIsForumRequest{} }, + ToggleSupergroupIsBroadcastGroupRequestTypeID: func() bin.Object { return &ToggleSupergroupIsBroadcastGroupRequest{} }, + ReportSupergroupSpamRequestTypeID: func() bin.Object { return &ReportSupergroupSpamRequest{} }, + ReportSupergroupAntiSpamFalsePositiveRequestTypeID: func() bin.Object { return &ReportSupergroupAntiSpamFalsePositiveRequest{} }, + GetSupergroupMembersRequestTypeID: func() bin.Object { return &GetSupergroupMembersRequest{} }, + CloseSecretChatRequestTypeID: func() bin.Object { return &CloseSecretChatRequest{} }, + GetChatEventLogRequestTypeID: func() bin.Object { return &GetChatEventLogRequest{} }, + GetTimeZonesRequestTypeID: func() bin.Object { return &GetTimeZonesRequest{} }, + GetPaymentFormRequestTypeID: func() bin.Object { return &GetPaymentFormRequest{} }, + ValidateOrderInfoRequestTypeID: func() bin.Object { return &ValidateOrderInfoRequest{} }, + SendPaymentFormRequestTypeID: func() bin.Object { return &SendPaymentFormRequest{} }, + GetPaymentReceiptRequestTypeID: func() bin.Object { return &GetPaymentReceiptRequest{} }, + GetSavedOrderInfoRequestTypeID: func() bin.Object { return &GetSavedOrderInfoRequest{} }, + DeleteSavedOrderInfoRequestTypeID: func() bin.Object { return &DeleteSavedOrderInfoRequest{} }, + DeleteSavedCredentialsRequestTypeID: func() bin.Object { return &DeleteSavedCredentialsRequest{} }, + CreateInvoiceLinkRequestTypeID: func() bin.Object { return &CreateInvoiceLinkRequest{} }, + RefundStarPaymentRequestTypeID: func() bin.Object { return &RefundStarPaymentRequest{} }, + GetSupportUserRequestTypeID: func() bin.Object { return &GetSupportUserRequest{} }, + GetBackgroundURLRequestTypeID: func() bin.Object { return &GetBackgroundURLRequest{} }, + SearchBackgroundRequestTypeID: func() bin.Object { return &SearchBackgroundRequest{} }, + SetDefaultBackgroundRequestTypeID: func() bin.Object { return &SetDefaultBackgroundRequest{} }, + DeleteDefaultBackgroundRequestTypeID: func() bin.Object { return &DeleteDefaultBackgroundRequest{} }, + GetInstalledBackgroundsRequestTypeID: func() bin.Object { return &GetInstalledBackgroundsRequest{} }, + RemoveInstalledBackgroundRequestTypeID: func() bin.Object { return &RemoveInstalledBackgroundRequest{} }, + ResetInstalledBackgroundsRequestTypeID: func() bin.Object { return &ResetInstalledBackgroundsRequest{} }, + GetLocalizationTargetInfoRequestTypeID: func() bin.Object { return &GetLocalizationTargetInfoRequest{} }, + GetLanguagePackInfoRequestTypeID: func() bin.Object { return &GetLanguagePackInfoRequest{} }, + GetLanguagePackStringsRequestTypeID: func() bin.Object { return &GetLanguagePackStringsRequest{} }, + SynchronizeLanguagePackRequestTypeID: func() bin.Object { return &SynchronizeLanguagePackRequest{} }, + AddCustomServerLanguagePackRequestTypeID: func() bin.Object { return &AddCustomServerLanguagePackRequest{} }, + SetCustomLanguagePackRequestTypeID: func() bin.Object { return &SetCustomLanguagePackRequest{} }, + EditCustomLanguagePackInfoRequestTypeID: func() bin.Object { return &EditCustomLanguagePackInfoRequest{} }, + SetCustomLanguagePackStringRequestTypeID: func() bin.Object { return &SetCustomLanguagePackStringRequest{} }, + DeleteLanguagePackRequestTypeID: func() bin.Object { return &DeleteLanguagePackRequest{} }, + RegisterDeviceRequestTypeID: func() bin.Object { return &RegisterDeviceRequest{} }, + ProcessPushNotificationRequestTypeID: func() bin.Object { return &ProcessPushNotificationRequest{} }, + GetPushReceiverIDRequestTypeID: func() bin.Object { return &GetPushReceiverIDRequest{} }, + GetRecentlyVisitedTMeURLsRequestTypeID: func() bin.Object { return &GetRecentlyVisitedTMeURLsRequest{} }, + SetUserPrivacySettingRulesRequestTypeID: func() bin.Object { return &SetUserPrivacySettingRulesRequest{} }, + GetUserPrivacySettingRulesRequestTypeID: func() bin.Object { return &GetUserPrivacySettingRulesRequest{} }, + SetReadDatePrivacySettingsRequestTypeID: func() bin.Object { return &SetReadDatePrivacySettingsRequest{} }, + GetReadDatePrivacySettingsRequestTypeID: func() bin.Object { return &GetReadDatePrivacySettingsRequest{} }, + SetNewChatPrivacySettingsRequestTypeID: func() bin.Object { return &SetNewChatPrivacySettingsRequest{} }, + GetNewChatPrivacySettingsRequestTypeID: func() bin.Object { return &GetNewChatPrivacySettingsRequest{} }, + CanSendMessageToUserRequestTypeID: func() bin.Object { return &CanSendMessageToUserRequest{} }, + GetOptionRequestTypeID: func() bin.Object { return &GetOptionRequest{} }, + SetOptionRequestTypeID: func() bin.Object { return &SetOptionRequest{} }, + SetAccountTTLRequestTypeID: func() bin.Object { return &SetAccountTTLRequest{} }, + GetAccountTTLRequestTypeID: func() bin.Object { return &GetAccountTTLRequest{} }, + DeleteAccountRequestTypeID: func() bin.Object { return &DeleteAccountRequest{} }, + SetDefaultMessageAutoDeleteTimeRequestTypeID: func() bin.Object { return &SetDefaultMessageAutoDeleteTimeRequest{} }, + GetDefaultMessageAutoDeleteTimeRequestTypeID: func() bin.Object { return &GetDefaultMessageAutoDeleteTimeRequest{} }, + RemoveChatActionBarRequestTypeID: func() bin.Object { return &RemoveChatActionBarRequest{} }, + ReportChatRequestTypeID: func() bin.Object { return &ReportChatRequest{} }, + ReportChatPhotoRequestTypeID: func() bin.Object { return &ReportChatPhotoRequest{} }, + ReportMessageReactionsRequestTypeID: func() bin.Object { return &ReportMessageReactionsRequest{} }, + GetChatRevenueStatisticsRequestTypeID: func() bin.Object { return &GetChatRevenueStatisticsRequest{} }, + GetChatRevenueWithdrawalURLRequestTypeID: func() bin.Object { return &GetChatRevenueWithdrawalURLRequest{} }, + GetChatRevenueTransactionsRequestTypeID: func() bin.Object { return &GetChatRevenueTransactionsRequest{} }, + GetStarRevenueStatisticsRequestTypeID: func() bin.Object { return &GetStarRevenueStatisticsRequest{} }, + GetStarWithdrawalURLRequestTypeID: func() bin.Object { return &GetStarWithdrawalURLRequest{} }, + GetStarAdAccountURLRequestTypeID: func() bin.Object { return &GetStarAdAccountURLRequest{} }, + GetChatStatisticsRequestTypeID: func() bin.Object { return &GetChatStatisticsRequest{} }, + GetMessageStatisticsRequestTypeID: func() bin.Object { return &GetMessageStatisticsRequest{} }, + GetMessagePublicForwardsRequestTypeID: func() bin.Object { return &GetMessagePublicForwardsRequest{} }, + GetStoryStatisticsRequestTypeID: func() bin.Object { return &GetStoryStatisticsRequest{} }, + GetStatisticalGraphRequestTypeID: func() bin.Object { return &GetStatisticalGraphRequest{} }, + GetStorageStatisticsRequestTypeID: func() bin.Object { return &GetStorageStatisticsRequest{} }, + GetStorageStatisticsFastRequestTypeID: func() bin.Object { return &GetStorageStatisticsFastRequest{} }, + GetDatabaseStatisticsRequestTypeID: func() bin.Object { return &GetDatabaseStatisticsRequest{} }, + OptimizeStorageRequestTypeID: func() bin.Object { return &OptimizeStorageRequest{} }, + SetNetworkTypeRequestTypeID: func() bin.Object { return &SetNetworkTypeRequest{} }, + GetNetworkStatisticsRequestTypeID: func() bin.Object { return &GetNetworkStatisticsRequest{} }, + AddNetworkStatisticsRequestTypeID: func() bin.Object { return &AddNetworkStatisticsRequest{} }, + ResetNetworkStatisticsRequestTypeID: func() bin.Object { return &ResetNetworkStatisticsRequest{} }, + GetAutoDownloadSettingsPresetsRequestTypeID: func() bin.Object { return &GetAutoDownloadSettingsPresetsRequest{} }, + SetAutoDownloadSettingsRequestTypeID: func() bin.Object { return &SetAutoDownloadSettingsRequest{} }, + GetAutosaveSettingsRequestTypeID: func() bin.Object { return &GetAutosaveSettingsRequest{} }, + SetAutosaveSettingsRequestTypeID: func() bin.Object { return &SetAutosaveSettingsRequest{} }, + ClearAutosaveSettingsExceptionsRequestTypeID: func() bin.Object { return &ClearAutosaveSettingsExceptionsRequest{} }, + GetBankCardInfoRequestTypeID: func() bin.Object { return &GetBankCardInfoRequest{} }, + GetPassportElementRequestTypeID: func() bin.Object { return &GetPassportElementRequest{} }, + GetAllPassportElementsRequestTypeID: func() bin.Object { return &GetAllPassportElementsRequest{} }, + SetPassportElementRequestTypeID: func() bin.Object { return &SetPassportElementRequest{} }, + DeletePassportElementRequestTypeID: func() bin.Object { return &DeletePassportElementRequest{} }, + SetPassportElementErrorsRequestTypeID: func() bin.Object { return &SetPassportElementErrorsRequest{} }, + GetPreferredCountryLanguageRequestTypeID: func() bin.Object { return &GetPreferredCountryLanguageRequest{} }, + SendEmailAddressVerificationCodeRequestTypeID: func() bin.Object { return &SendEmailAddressVerificationCodeRequest{} }, + ResendEmailAddressVerificationCodeRequestTypeID: func() bin.Object { return &ResendEmailAddressVerificationCodeRequest{} }, + CheckEmailAddressVerificationCodeRequestTypeID: func() bin.Object { return &CheckEmailAddressVerificationCodeRequest{} }, + GetPassportAuthorizationFormRequestTypeID: func() bin.Object { return &GetPassportAuthorizationFormRequest{} }, + GetPassportAuthorizationFormAvailableElementsRequestTypeID: func() bin.Object { return &GetPassportAuthorizationFormAvailableElementsRequest{} }, + SendPassportAuthorizationFormRequestTypeID: func() bin.Object { return &SendPassportAuthorizationFormRequest{} }, + SetBotUpdatesStatusRequestTypeID: func() bin.Object { return &SetBotUpdatesStatusRequest{} }, + UploadStickerFileRequestTypeID: func() bin.Object { return &UploadStickerFileRequest{} }, + GetSuggestedStickerSetNameRequestTypeID: func() bin.Object { return &GetSuggestedStickerSetNameRequest{} }, + CheckStickerSetNameRequestTypeID: func() bin.Object { return &CheckStickerSetNameRequest{} }, + CreateNewStickerSetRequestTypeID: func() bin.Object { return &CreateNewStickerSetRequest{} }, + AddStickerToSetRequestTypeID: func() bin.Object { return &AddStickerToSetRequest{} }, + ReplaceStickerInSetRequestTypeID: func() bin.Object { return &ReplaceStickerInSetRequest{} }, + SetStickerSetThumbnailRequestTypeID: func() bin.Object { return &SetStickerSetThumbnailRequest{} }, + SetCustomEmojiStickerSetThumbnailRequestTypeID: func() bin.Object { return &SetCustomEmojiStickerSetThumbnailRequest{} }, + SetStickerSetTitleRequestTypeID: func() bin.Object { return &SetStickerSetTitleRequest{} }, + DeleteStickerSetRequestTypeID: func() bin.Object { return &DeleteStickerSetRequest{} }, + SetStickerPositionInSetRequestTypeID: func() bin.Object { return &SetStickerPositionInSetRequest{} }, + RemoveStickerFromSetRequestTypeID: func() bin.Object { return &RemoveStickerFromSetRequest{} }, + SetStickerEmojisRequestTypeID: func() bin.Object { return &SetStickerEmojisRequest{} }, + SetStickerKeywordsRequestTypeID: func() bin.Object { return &SetStickerKeywordsRequest{} }, + SetStickerMaskPositionRequestTypeID: func() bin.Object { return &SetStickerMaskPositionRequest{} }, + GetOwnedStickerSetsRequestTypeID: func() bin.Object { return &GetOwnedStickerSetsRequest{} }, + GetMapThumbnailFileRequestTypeID: func() bin.Object { return &GetMapThumbnailFileRequest{} }, + GetPremiumLimitRequestTypeID: func() bin.Object { return &GetPremiumLimitRequest{} }, + GetPremiumFeaturesRequestTypeID: func() bin.Object { return &GetPremiumFeaturesRequest{} }, + GetPremiumStickerExamplesRequestTypeID: func() bin.Object { return &GetPremiumStickerExamplesRequest{} }, + ViewPremiumFeatureRequestTypeID: func() bin.Object { return &ViewPremiumFeatureRequest{} }, + ClickPremiumSubscriptionButtonRequestTypeID: func() bin.Object { return &ClickPremiumSubscriptionButtonRequest{} }, + GetPremiumStateRequestTypeID: func() bin.Object { return &GetPremiumStateRequest{} }, + GetPremiumGiftCodePaymentOptionsRequestTypeID: func() bin.Object { return &GetPremiumGiftCodePaymentOptionsRequest{} }, + CheckPremiumGiftCodeRequestTypeID: func() bin.Object { return &CheckPremiumGiftCodeRequest{} }, + ApplyPremiumGiftCodeRequestTypeID: func() bin.Object { return &ApplyPremiumGiftCodeRequest{} }, + LaunchPrepaidPremiumGiveawayRequestTypeID: func() bin.Object { return &LaunchPrepaidPremiumGiveawayRequest{} }, + GetPremiumGiveawayInfoRequestTypeID: func() bin.Object { return &GetPremiumGiveawayInfoRequest{} }, + GetStarPaymentOptionsRequestTypeID: func() bin.Object { return &GetStarPaymentOptionsRequest{} }, + GetStarGiftPaymentOptionsRequestTypeID: func() bin.Object { return &GetStarGiftPaymentOptionsRequest{} }, + GetStarTransactionsRequestTypeID: func() bin.Object { return &GetStarTransactionsRequest{} }, + GetStarSubscriptionsRequestTypeID: func() bin.Object { return &GetStarSubscriptionsRequest{} }, + CanPurchaseFromStoreRequestTypeID: func() bin.Object { return &CanPurchaseFromStoreRequest{} }, + AssignAppStoreTransactionRequestTypeID: func() bin.Object { return &AssignAppStoreTransactionRequest{} }, + AssignGooglePlayTransactionRequestTypeID: func() bin.Object { return &AssignGooglePlayTransactionRequest{} }, + EditStarSubscriptionRequestTypeID: func() bin.Object { return &EditStarSubscriptionRequest{} }, + ReuseStarSubscriptionRequestTypeID: func() bin.Object { return &ReuseStarSubscriptionRequest{} }, + GetBusinessFeaturesRequestTypeID: func() bin.Object { return &GetBusinessFeaturesRequest{} }, + AcceptTermsOfServiceRequestTypeID: func() bin.Object { return &AcceptTermsOfServiceRequest{} }, + SearchStringsByPrefixRequestTypeID: func() bin.Object { return &SearchStringsByPrefixRequest{} }, + SendCustomRequestRequestTypeID: func() bin.Object { return &SendCustomRequestRequest{} }, + AnswerCustomQueryRequestTypeID: func() bin.Object { return &AnswerCustomQueryRequest{} }, + SetAlarmRequestTypeID: func() bin.Object { return &SetAlarmRequest{} }, + GetCountriesRequestTypeID: func() bin.Object { return &GetCountriesRequest{} }, + GetCountryCodeRequestTypeID: func() bin.Object { return &GetCountryCodeRequest{} }, + GetPhoneNumberInfoRequestTypeID: func() bin.Object { return &GetPhoneNumberInfoRequest{} }, + GetPhoneNumberInfoSyncRequestTypeID: func() bin.Object { return &GetPhoneNumberInfoSyncRequest{} }, + GetCollectibleItemInfoRequestTypeID: func() bin.Object { return &GetCollectibleItemInfoRequest{} }, + GetDeepLinkInfoRequestTypeID: func() bin.Object { return &GetDeepLinkInfoRequest{} }, + GetApplicationConfigRequestTypeID: func() bin.Object { return &GetApplicationConfigRequest{} }, + SaveApplicationLogEventRequestTypeID: func() bin.Object { return &SaveApplicationLogEventRequest{} }, + GetApplicationDownloadLinkRequestTypeID: func() bin.Object { return &GetApplicationDownloadLinkRequest{} }, + AddProxyRequestTypeID: func() bin.Object { return &AddProxyRequest{} }, + EditProxyRequestTypeID: func() bin.Object { return &EditProxyRequest{} }, + EnableProxyRequestTypeID: func() bin.Object { return &EnableProxyRequest{} }, + DisableProxyRequestTypeID: func() bin.Object { return &DisableProxyRequest{} }, + RemoveProxyRequestTypeID: func() bin.Object { return &RemoveProxyRequest{} }, + GetProxiesRequestTypeID: func() bin.Object { return &GetProxiesRequest{} }, + GetProxyLinkRequestTypeID: func() bin.Object { return &GetProxyLinkRequest{} }, + PingProxyRequestTypeID: func() bin.Object { return &PingProxyRequest{} }, + SetLogStreamRequestTypeID: func() bin.Object { return &SetLogStreamRequest{} }, + GetLogStreamRequestTypeID: func() bin.Object { return &GetLogStreamRequest{} }, + SetLogVerbosityLevelRequestTypeID: func() bin.Object { return &SetLogVerbosityLevelRequest{} }, + GetLogVerbosityLevelRequestTypeID: func() bin.Object { return &GetLogVerbosityLevelRequest{} }, + GetLogTagsRequestTypeID: func() bin.Object { return &GetLogTagsRequest{} }, + SetLogTagVerbosityLevelRequestTypeID: func() bin.Object { return &SetLogTagVerbosityLevelRequest{} }, + GetLogTagVerbosityLevelRequestTypeID: func() bin.Object { return &GetLogTagVerbosityLevelRequest{} }, + AddLogMessageRequestTypeID: func() bin.Object { return &AddLogMessageRequest{} }, + GetUserSupportInfoRequestTypeID: func() bin.Object { return &GetUserSupportInfoRequest{} }, + SetUserSupportInfoRequestTypeID: func() bin.Object { return &SetUserSupportInfoRequest{} }, + GetSupportNameRequestTypeID: func() bin.Object { return &GetSupportNameRequest{} }, + TestCallEmptyRequestTypeID: func() bin.Object { return &TestCallEmptyRequest{} }, + TestCallStringRequestTypeID: func() bin.Object { return &TestCallStringRequest{} }, + TestCallBytesRequestTypeID: func() bin.Object { return &TestCallBytesRequest{} }, + TestCallVectorIntRequestTypeID: func() bin.Object { return &TestCallVectorIntRequest{} }, + TestCallVectorIntObjectRequestTypeID: func() bin.Object { return &TestCallVectorIntObjectRequest{} }, + TestCallVectorStringRequestTypeID: func() bin.Object { return &TestCallVectorStringRequest{} }, + TestCallVectorStringObjectRequestTypeID: func() bin.Object { return &TestCallVectorStringObjectRequest{} }, + TestSquareIntRequestTypeID: func() bin.Object { return &TestSquareIntRequest{} }, + TestNetworkRequestTypeID: func() bin.Object { return &TestNetworkRequest{} }, + TestProxyRequestTypeID: func() bin.Object { return &TestProxyRequest{} }, + TestGetDifferenceRequestTypeID: func() bin.Object { return &TestGetDifferenceRequest{} }, + TestUseUpdateRequestTypeID: func() bin.Object { return &TestUseUpdateRequest{} }, + TestReturnErrorRequestTypeID: func() bin.Object { return &TestReturnErrorRequest{} }, } } @@ -7219,6 +7291,10 @@ func ClassConstructorsMap() map[string][]uint32 { BotCommandScopeChatAdministratorsTypeID, BotCommandScopeChatMemberTypeID, }, + BotTransactionPurposeClassName: { + BotTransactionPurposePaidMediaTypeID, + BotTransactionPurposeInvoicePaymentTypeID, + }, BotWriteAccessAllowReasonClassName: { BotWriteAccessAllowReasonConnectedWebsiteTypeID, BotWriteAccessAllowReasonAddedToAttachmentMenuTypeID, @@ -7297,6 +7373,11 @@ func ClassConstructorsMap() map[string][]uint32 { CanTransferOwnershipResultPasswordTooFreshTypeID, CanTransferOwnershipResultSessionTooFreshTypeID, }, + ChannelTransactionPurposeClassName: { + ChannelTransactionPurposePaidMediaTypeID, + ChannelTransactionPurposeJoinTypeID, + ChannelTransactionPurposeReactionTypeID, + }, ChatActionBarClassName: { ChatActionBarReportSpamTypeID, ChatActionBarReportUnrelatedLocationTypeID, @@ -7367,6 +7448,7 @@ func ClassConstructorsMap() map[string][]uint32 { ChatEventIsAllHistoryAvailableToggledTypeID, ChatEventHasAggressiveAntiSpamEnabledToggledTypeID, ChatEventSignMessagesToggledTypeID, + ChatEventShowMessageSenderToggledTypeID, ChatEventInviteLinkEditedTypeID, ChatEventInviteLinkRevokedTypeID, ChatEventInviteLinkDeletedTypeID, @@ -7676,6 +7758,7 @@ func ClassConstructorsMap() map[string][]uint32 { InternalLinkTypeBotStartTypeID, InternalLinkTypeBotStartInGroupTypeID, InternalLinkTypeBusinessChatTypeID, + InternalLinkTypeBuyStarsTypeID, InternalLinkTypeChangePhoneNumberTypeID, InternalLinkTypeChatBoostTypeID, InternalLinkTypeChatFolderInviteTypeID, @@ -8195,6 +8278,7 @@ func ClassConstructorsMap() map[string][]uint32 { ReactionTypeClassName: { ReactionTypeEmojiTypeID, ReactionTypeCustomEmojiTypeID, + ReactionTypePaidTypeID, }, ReactionUnavailabilityReasonClassName: { ReactionUnavailabilityReasonAnonymousAdministratorTypeID, @@ -8322,6 +8406,7 @@ func ClassConstructorsMap() map[string][]uint32 { StarTransactionPartnerFragmentTypeID, StarTransactionPartnerTelegramAdsTypeID, StarTransactionPartnerBotTypeID, + StarTransactionPartnerBusinessTypeID, StarTransactionPartnerChannelTypeID, StarTransactionPartnerUserTypeID, StarTransactionPartnerUnsupportedTypeID, @@ -8399,6 +8484,7 @@ func ClassConstructorsMap() map[string][]uint32 { SuggestedActionGiftPremiumForChristmasTypeID, SuggestedActionSetBirthdateTypeID, SuggestedActionExtendPremiumTypeID, + SuggestedActionExtendStarSubscriptionsTypeID, }, SupergroupMembersFilterClassName: { SupergroupMembersFilterRecentTypeID, @@ -8426,6 +8512,7 @@ func ClassConstructorsMap() map[string][]uint32 { TelegramPaymentPurposePremiumGiveawayTypeID, TelegramPaymentPurposeStarsTypeID, TelegramPaymentPurposeGiftedStarsTypeID, + TelegramPaymentPurposeJoinChatTypeID, }, TextEntityTypeClassName: { TextEntityTypeMentionTypeID, @@ -8593,6 +8680,7 @@ func ClassConstructorsMap() map[string][]uint32 { UpdateAvailableMessageEffectsTypeID, UpdateDefaultReactionTypeTypeID, UpdateSavedMessagesTagsTypeID, + UpdateActiveLiveLocationMessagesTypeID, UpdateOwnedStarCountTypeID, UpdateChatRevenueAmountTypeID, UpdateStarRevenueStatusTypeID, diff --git a/tdapi/tl_remove_message_reaction_gen.go b/tdapi/tl_remove_message_reaction_gen.go index 6ff3152527..a60e4cfc49 100644 --- a/tdapi/tl_remove_message_reaction_gen.go +++ b/tdapi/tl_remove_message_reaction_gen.go @@ -37,7 +37,7 @@ type RemoveMessageReactionRequest struct { ChatID int64 // Identifier of the message MessageID int64 - // Type of the reaction to remove + // Type of the reaction to remove. The paid reaction can't be removed ReactionType ReactionTypeClass } diff --git a/tdapi/tl_remove_pending_paid_message_reactions_gen.go b/tdapi/tl_remove_pending_paid_message_reactions_gen.go new file mode 100644 index 0000000000..b6916b2fdd --- /dev/null +++ b/tdapi/tl_remove_pending_paid_message_reactions_gen.go @@ -0,0 +1,237 @@ +// Code generated by gotdgen, DO NOT EDIT. + +package tdapi + +import ( + "context" + "errors" + "fmt" + "sort" + "strings" + + "go.uber.org/multierr" + + "github.com/gotd/td/bin" + "github.com/gotd/td/tdjson" + "github.com/gotd/td/tdp" + "github.com/gotd/td/tgerr" +) + +// No-op definition for keeping imports. +var ( + _ = bin.Buffer{} + _ = context.Background() + _ = fmt.Stringer(nil) + _ = strings.Builder{} + _ = errors.Is + _ = multierr.AppendInto + _ = sort.Ints + _ = tdp.Format + _ = tgerr.Error{} + _ = tdjson.Encoder{} +) + +// RemovePendingPaidMessageReactionsRequest represents TL type `removePendingPaidMessageReactions#41949cfb`. +type RemovePendingPaidMessageReactionsRequest struct { + // Identifier of the chat to which the message belongs + ChatID int64 + // Identifier of the message + MessageID int64 +} + +// RemovePendingPaidMessageReactionsRequestTypeID is TL type id of RemovePendingPaidMessageReactionsRequest. +const RemovePendingPaidMessageReactionsRequestTypeID = 0x41949cfb + +// Ensuring interfaces in compile-time for RemovePendingPaidMessageReactionsRequest. +var ( + _ bin.Encoder = &RemovePendingPaidMessageReactionsRequest{} + _ bin.Decoder = &RemovePendingPaidMessageReactionsRequest{} + _ bin.BareEncoder = &RemovePendingPaidMessageReactionsRequest{} + _ bin.BareDecoder = &RemovePendingPaidMessageReactionsRequest{} +) + +func (r *RemovePendingPaidMessageReactionsRequest) Zero() bool { + if r == nil { + return true + } + if !(r.ChatID == 0) { + return false + } + if !(r.MessageID == 0) { + return false + } + + return true +} + +// String implements fmt.Stringer. +func (r *RemovePendingPaidMessageReactionsRequest) String() string { + if r == nil { + return "RemovePendingPaidMessageReactionsRequest(nil)" + } + type Alias RemovePendingPaidMessageReactionsRequest + return fmt.Sprintf("RemovePendingPaidMessageReactionsRequest%+v", Alias(*r)) +} + +// TypeID returns type id in TL schema. +// +// See https://core.telegram.org/mtproto/TL-tl#remarks. +func (*RemovePendingPaidMessageReactionsRequest) TypeID() uint32 { + return RemovePendingPaidMessageReactionsRequestTypeID +} + +// TypeName returns name of type in TL schema. +func (*RemovePendingPaidMessageReactionsRequest) TypeName() string { + return "removePendingPaidMessageReactions" +} + +// TypeInfo returns info about TL type. +func (r *RemovePendingPaidMessageReactionsRequest) TypeInfo() tdp.Type { + typ := tdp.Type{ + Name: "removePendingPaidMessageReactions", + ID: RemovePendingPaidMessageReactionsRequestTypeID, + } + if r == nil { + typ.Null = true + return typ + } + typ.Fields = []tdp.Field{ + { + Name: "ChatID", + SchemaName: "chat_id", + }, + { + Name: "MessageID", + SchemaName: "message_id", + }, + } + return typ +} + +// Encode implements bin.Encoder. +func (r *RemovePendingPaidMessageReactionsRequest) Encode(b *bin.Buffer) error { + if r == nil { + return fmt.Errorf("can't encode removePendingPaidMessageReactions#41949cfb as nil") + } + b.PutID(RemovePendingPaidMessageReactionsRequestTypeID) + return r.EncodeBare(b) +} + +// EncodeBare implements bin.BareEncoder. +func (r *RemovePendingPaidMessageReactionsRequest) EncodeBare(b *bin.Buffer) error { + if r == nil { + return fmt.Errorf("can't encode removePendingPaidMessageReactions#41949cfb as nil") + } + b.PutInt53(r.ChatID) + b.PutInt53(r.MessageID) + return nil +} + +// Decode implements bin.Decoder. +func (r *RemovePendingPaidMessageReactionsRequest) Decode(b *bin.Buffer) error { + if r == nil { + return fmt.Errorf("can't decode removePendingPaidMessageReactions#41949cfb to nil") + } + if err := b.ConsumeID(RemovePendingPaidMessageReactionsRequestTypeID); err != nil { + return fmt.Errorf("unable to decode removePendingPaidMessageReactions#41949cfb: %w", err) + } + return r.DecodeBare(b) +} + +// DecodeBare implements bin.BareDecoder. +func (r *RemovePendingPaidMessageReactionsRequest) DecodeBare(b *bin.Buffer) error { + if r == nil { + return fmt.Errorf("can't decode removePendingPaidMessageReactions#41949cfb to nil") + } + { + value, err := b.Int53() + if err != nil { + return fmt.Errorf("unable to decode removePendingPaidMessageReactions#41949cfb: field chat_id: %w", err) + } + r.ChatID = value + } + { + value, err := b.Int53() + if err != nil { + return fmt.Errorf("unable to decode removePendingPaidMessageReactions#41949cfb: field message_id: %w", err) + } + r.MessageID = value + } + return nil +} + +// EncodeTDLibJSON implements tdjson.TDLibEncoder. +func (r *RemovePendingPaidMessageReactionsRequest) EncodeTDLibJSON(b tdjson.Encoder) error { + if r == nil { + return fmt.Errorf("can't encode removePendingPaidMessageReactions#41949cfb as nil") + } + b.ObjStart() + b.PutID("removePendingPaidMessageReactions") + b.Comma() + b.FieldStart("chat_id") + b.PutInt53(r.ChatID) + b.Comma() + b.FieldStart("message_id") + b.PutInt53(r.MessageID) + b.Comma() + b.StripComma() + b.ObjEnd() + return nil +} + +// DecodeTDLibJSON implements tdjson.TDLibDecoder. +func (r *RemovePendingPaidMessageReactionsRequest) DecodeTDLibJSON(b tdjson.Decoder) error { + if r == nil { + return fmt.Errorf("can't decode removePendingPaidMessageReactions#41949cfb to nil") + } + + return b.Obj(func(b tdjson.Decoder, key []byte) error { + switch string(key) { + case tdjson.TypeField: + if err := b.ConsumeID("removePendingPaidMessageReactions"); err != nil { + return fmt.Errorf("unable to decode removePendingPaidMessageReactions#41949cfb: %w", err) + } + case "chat_id": + value, err := b.Int53() + if err != nil { + return fmt.Errorf("unable to decode removePendingPaidMessageReactions#41949cfb: field chat_id: %w", err) + } + r.ChatID = value + case "message_id": + value, err := b.Int53() + if err != nil { + return fmt.Errorf("unable to decode removePendingPaidMessageReactions#41949cfb: field message_id: %w", err) + } + r.MessageID = value + default: + return b.Skip() + } + return nil + }) +} + +// GetChatID returns value of ChatID field. +func (r *RemovePendingPaidMessageReactionsRequest) GetChatID() (value int64) { + if r == nil { + return + } + return r.ChatID +} + +// GetMessageID returns value of MessageID field. +func (r *RemovePendingPaidMessageReactionsRequest) GetMessageID() (value int64) { + if r == nil { + return + } + return r.MessageID +} + +// RemovePendingPaidMessageReactions invokes method removePendingPaidMessageReactions#41949cfb returning error if any. +func (c *Client) RemovePendingPaidMessageReactions(ctx context.Context, request *RemovePendingPaidMessageReactionsRequest) error { + var ok Ok + + if err := c.rpc.Invoke(ctx, request, &ok); err != nil { + return err + } + return nil +} diff --git a/tdapi/tl_reuse_star_subscription_gen.go b/tdapi/tl_reuse_star_subscription_gen.go new file mode 100644 index 0000000000..eabeb2bc1f --- /dev/null +++ b/tdapi/tl_reuse_star_subscription_gen.go @@ -0,0 +1,206 @@ +// Code generated by gotdgen, DO NOT EDIT. + +package tdapi + +import ( + "context" + "errors" + "fmt" + "sort" + "strings" + + "go.uber.org/multierr" + + "github.com/gotd/td/bin" + "github.com/gotd/td/tdjson" + "github.com/gotd/td/tdp" + "github.com/gotd/td/tgerr" +) + +// No-op definition for keeping imports. +var ( + _ = bin.Buffer{} + _ = context.Background() + _ = fmt.Stringer(nil) + _ = strings.Builder{} + _ = errors.Is + _ = multierr.AppendInto + _ = sort.Ints + _ = tdp.Format + _ = tgerr.Error{} + _ = tdjson.Encoder{} +) + +// ReuseStarSubscriptionRequest represents TL type `reuseStarSubscription#2e677441`. +type ReuseStarSubscriptionRequest struct { + // Identifier of the subscription + SubscriptionID string +} + +// ReuseStarSubscriptionRequestTypeID is TL type id of ReuseStarSubscriptionRequest. +const ReuseStarSubscriptionRequestTypeID = 0x2e677441 + +// Ensuring interfaces in compile-time for ReuseStarSubscriptionRequest. +var ( + _ bin.Encoder = &ReuseStarSubscriptionRequest{} + _ bin.Decoder = &ReuseStarSubscriptionRequest{} + _ bin.BareEncoder = &ReuseStarSubscriptionRequest{} + _ bin.BareDecoder = &ReuseStarSubscriptionRequest{} +) + +func (r *ReuseStarSubscriptionRequest) Zero() bool { + if r == nil { + return true + } + if !(r.SubscriptionID == "") { + return false + } + + return true +} + +// String implements fmt.Stringer. +func (r *ReuseStarSubscriptionRequest) String() string { + if r == nil { + return "ReuseStarSubscriptionRequest(nil)" + } + type Alias ReuseStarSubscriptionRequest + return fmt.Sprintf("ReuseStarSubscriptionRequest%+v", Alias(*r)) +} + +// TypeID returns type id in TL schema. +// +// See https://core.telegram.org/mtproto/TL-tl#remarks. +func (*ReuseStarSubscriptionRequest) TypeID() uint32 { + return ReuseStarSubscriptionRequestTypeID +} + +// TypeName returns name of type in TL schema. +func (*ReuseStarSubscriptionRequest) TypeName() string { + return "reuseStarSubscription" +} + +// TypeInfo returns info about TL type. +func (r *ReuseStarSubscriptionRequest) TypeInfo() tdp.Type { + typ := tdp.Type{ + Name: "reuseStarSubscription", + ID: ReuseStarSubscriptionRequestTypeID, + } + if r == nil { + typ.Null = true + return typ + } + typ.Fields = []tdp.Field{ + { + Name: "SubscriptionID", + SchemaName: "subscription_id", + }, + } + return typ +} + +// Encode implements bin.Encoder. +func (r *ReuseStarSubscriptionRequest) Encode(b *bin.Buffer) error { + if r == nil { + return fmt.Errorf("can't encode reuseStarSubscription#2e677441 as nil") + } + b.PutID(ReuseStarSubscriptionRequestTypeID) + return r.EncodeBare(b) +} + +// EncodeBare implements bin.BareEncoder. +func (r *ReuseStarSubscriptionRequest) EncodeBare(b *bin.Buffer) error { + if r == nil { + return fmt.Errorf("can't encode reuseStarSubscription#2e677441 as nil") + } + b.PutString(r.SubscriptionID) + return nil +} + +// Decode implements bin.Decoder. +func (r *ReuseStarSubscriptionRequest) Decode(b *bin.Buffer) error { + if r == nil { + return fmt.Errorf("can't decode reuseStarSubscription#2e677441 to nil") + } + if err := b.ConsumeID(ReuseStarSubscriptionRequestTypeID); err != nil { + return fmt.Errorf("unable to decode reuseStarSubscription#2e677441: %w", err) + } + return r.DecodeBare(b) +} + +// DecodeBare implements bin.BareDecoder. +func (r *ReuseStarSubscriptionRequest) DecodeBare(b *bin.Buffer) error { + if r == nil { + return fmt.Errorf("can't decode reuseStarSubscription#2e677441 to nil") + } + { + value, err := b.String() + if err != nil { + return fmt.Errorf("unable to decode reuseStarSubscription#2e677441: field subscription_id: %w", err) + } + r.SubscriptionID = value + } + return nil +} + +// EncodeTDLibJSON implements tdjson.TDLibEncoder. +func (r *ReuseStarSubscriptionRequest) EncodeTDLibJSON(b tdjson.Encoder) error { + if r == nil { + return fmt.Errorf("can't encode reuseStarSubscription#2e677441 as nil") + } + b.ObjStart() + b.PutID("reuseStarSubscription") + b.Comma() + b.FieldStart("subscription_id") + b.PutString(r.SubscriptionID) + b.Comma() + b.StripComma() + b.ObjEnd() + return nil +} + +// DecodeTDLibJSON implements tdjson.TDLibDecoder. +func (r *ReuseStarSubscriptionRequest) DecodeTDLibJSON(b tdjson.Decoder) error { + if r == nil { + return fmt.Errorf("can't decode reuseStarSubscription#2e677441 to nil") + } + + return b.Obj(func(b tdjson.Decoder, key []byte) error { + switch string(key) { + case tdjson.TypeField: + if err := b.ConsumeID("reuseStarSubscription"); err != nil { + return fmt.Errorf("unable to decode reuseStarSubscription#2e677441: %w", err) + } + case "subscription_id": + value, err := b.String() + if err != nil { + return fmt.Errorf("unable to decode reuseStarSubscription#2e677441: field subscription_id: %w", err) + } + r.SubscriptionID = value + default: + return b.Skip() + } + return nil + }) +} + +// GetSubscriptionID returns value of SubscriptionID field. +func (r *ReuseStarSubscriptionRequest) GetSubscriptionID() (value string) { + if r == nil { + return + } + return r.SubscriptionID +} + +// ReuseStarSubscription invokes method reuseStarSubscription#2e677441 returning error if any. +func (c *Client) ReuseStarSubscription(ctx context.Context, subscriptionid string) error { + var ok Ok + + request := &ReuseStarSubscriptionRequest{ + SubscriptionID: subscriptionid, + } + if err := c.rpc.Invoke(ctx, request, &ok); err != nil { + return err + } + return nil +} diff --git a/tdapi/tl_set_default_reaction_type_gen.go b/tdapi/tl_set_default_reaction_type_gen.go index d92e717e04..90e2e3019d 100644 --- a/tdapi/tl_set_default_reaction_type_gen.go +++ b/tdapi/tl_set_default_reaction_type_gen.go @@ -33,7 +33,7 @@ var ( // SetDefaultReactionTypeRequest represents TL type `setDefaultReactionType#65038a3d`. type SetDefaultReactionTypeRequest struct { - // New type of the default reaction + // New type of the default reaction. The paid reaction can't be set as default ReactionType ReactionTypeClass } diff --git a/tdapi/tl_set_story_reaction_gen.go b/tdapi/tl_set_story_reaction_gen.go index d5a191dda7..5f81b3070a 100644 --- a/tdapi/tl_set_story_reaction_gen.go +++ b/tdapi/tl_set_story_reaction_gen.go @@ -37,8 +37,8 @@ type SetStoryReactionRequest struct { StorySenderChatID int64 // The identifier of the story StoryID int32 - // Type of the reaction to set; pass null to remove the reaction. - // `reactionTypeCustomEmoji` reactions can be used only by Telegram Premium users + // Type of the reaction to set; pass null to remove the reaction. Custom emoji reactions + // can be used only by Telegram Premium users. Paid reactions can't be set ReactionType ReactionTypeClass // Pass true if the reaction needs to be added to recent reactions UpdateRecentReactions bool diff --git a/tdapi/tl_sponsored_message_gen.go b/tdapi/tl_sponsored_message_gen.go index e3c2a92aaf..0a931e5fcf 100644 --- a/tdapi/tl_sponsored_message_gen.go +++ b/tdapi/tl_sponsored_message_gen.go @@ -41,7 +41,8 @@ type SponsoredMessage struct { // True, if the message can be reported to Telegram moderators through // reportChatSponsoredMessage CanBeReported bool - // Content of the message. Currently, can be only of the type messageText + // Content of the message. Currently, can be only of the types messageText, + // messageAnimation, messagePhoto, or messageVideo Content MessageContentClass // Information about the sponsor of the message Sponsor MessageSponsor diff --git a/tdapi/tl_star_subscription_gen.go b/tdapi/tl_star_subscription_gen.go new file mode 100644 index 0000000000..615b460712 --- /dev/null +++ b/tdapi/tl_star_subscription_gen.go @@ -0,0 +1,434 @@ +// Code generated by gotdgen, DO NOT EDIT. + +package tdapi + +import ( + "context" + "errors" + "fmt" + "sort" + "strings" + + "go.uber.org/multierr" + + "github.com/gotd/td/bin" + "github.com/gotd/td/tdjson" + "github.com/gotd/td/tdp" + "github.com/gotd/td/tgerr" +) + +// No-op definition for keeping imports. +var ( + _ = bin.Buffer{} + _ = context.Background() + _ = fmt.Stringer(nil) + _ = strings.Builder{} + _ = errors.Is + _ = multierr.AppendInto + _ = sort.Ints + _ = tdp.Format + _ = tgerr.Error{} + _ = tdjson.Encoder{} +) + +// StarSubscription represents TL type `starSubscription#6caf0ade`. +type StarSubscription struct { + // Unique identifier of the subscription + ID string + // Identifier of the channel chat that is subscribed + ChatID int64 + // Point in time (Unix timestamp) when the subscription will expire or expired + ExpirationDate int32 + // True, if the subscription is active and the user can use the method + // reuseStarSubscription to join the subscribed chat again + CanReuse bool + // True, if the subscription was canceled + IsCanceled bool + // True, if the subscription expires soon and there are no enough Telegram Stars on the + // user's balance to extend it + IsExpiring bool + // The invite link that can be used to renew the subscription if it has been expired; may + // be empty, if the link isn't available anymore + InviteLink string + // The subscription plan + Pricing StarSubscriptionPricing +} + +// StarSubscriptionTypeID is TL type id of StarSubscription. +const StarSubscriptionTypeID = 0x6caf0ade + +// Ensuring interfaces in compile-time for StarSubscription. +var ( + _ bin.Encoder = &StarSubscription{} + _ bin.Decoder = &StarSubscription{} + _ bin.BareEncoder = &StarSubscription{} + _ bin.BareDecoder = &StarSubscription{} +) + +func (s *StarSubscription) Zero() bool { + if s == nil { + return true + } + if !(s.ID == "") { + return false + } + if !(s.ChatID == 0) { + return false + } + if !(s.ExpirationDate == 0) { + return false + } + if !(s.CanReuse == false) { + return false + } + if !(s.IsCanceled == false) { + return false + } + if !(s.IsExpiring == false) { + return false + } + if !(s.InviteLink == "") { + return false + } + if !(s.Pricing.Zero()) { + return false + } + + return true +} + +// String implements fmt.Stringer. +func (s *StarSubscription) String() string { + if s == nil { + return "StarSubscription(nil)" + } + type Alias StarSubscription + return fmt.Sprintf("StarSubscription%+v", Alias(*s)) +} + +// TypeID returns type id in TL schema. +// +// See https://core.telegram.org/mtproto/TL-tl#remarks. +func (*StarSubscription) TypeID() uint32 { + return StarSubscriptionTypeID +} + +// TypeName returns name of type in TL schema. +func (*StarSubscription) TypeName() string { + return "starSubscription" +} + +// TypeInfo returns info about TL type. +func (s *StarSubscription) TypeInfo() tdp.Type { + typ := tdp.Type{ + Name: "starSubscription", + ID: StarSubscriptionTypeID, + } + if s == nil { + typ.Null = true + return typ + } + typ.Fields = []tdp.Field{ + { + Name: "ID", + SchemaName: "id", + }, + { + Name: "ChatID", + SchemaName: "chat_id", + }, + { + Name: "ExpirationDate", + SchemaName: "expiration_date", + }, + { + Name: "CanReuse", + SchemaName: "can_reuse", + }, + { + Name: "IsCanceled", + SchemaName: "is_canceled", + }, + { + Name: "IsExpiring", + SchemaName: "is_expiring", + }, + { + Name: "InviteLink", + SchemaName: "invite_link", + }, + { + Name: "Pricing", + SchemaName: "pricing", + }, + } + return typ +} + +// Encode implements bin.Encoder. +func (s *StarSubscription) Encode(b *bin.Buffer) error { + if s == nil { + return fmt.Errorf("can't encode starSubscription#6caf0ade as nil") + } + b.PutID(StarSubscriptionTypeID) + return s.EncodeBare(b) +} + +// EncodeBare implements bin.BareEncoder. +func (s *StarSubscription) EncodeBare(b *bin.Buffer) error { + if s == nil { + return fmt.Errorf("can't encode starSubscription#6caf0ade as nil") + } + b.PutString(s.ID) + b.PutInt53(s.ChatID) + b.PutInt32(s.ExpirationDate) + b.PutBool(s.CanReuse) + b.PutBool(s.IsCanceled) + b.PutBool(s.IsExpiring) + b.PutString(s.InviteLink) + if err := s.Pricing.Encode(b); err != nil { + return fmt.Errorf("unable to encode starSubscription#6caf0ade: field pricing: %w", err) + } + return nil +} + +// Decode implements bin.Decoder. +func (s *StarSubscription) Decode(b *bin.Buffer) error { + if s == nil { + return fmt.Errorf("can't decode starSubscription#6caf0ade to nil") + } + if err := b.ConsumeID(StarSubscriptionTypeID); err != nil { + return fmt.Errorf("unable to decode starSubscription#6caf0ade: %w", err) + } + return s.DecodeBare(b) +} + +// DecodeBare implements bin.BareDecoder. +func (s *StarSubscription) DecodeBare(b *bin.Buffer) error { + if s == nil { + return fmt.Errorf("can't decode starSubscription#6caf0ade to nil") + } + { + value, err := b.String() + if err != nil { + return fmt.Errorf("unable to decode starSubscription#6caf0ade: field id: %w", err) + } + s.ID = value + } + { + value, err := b.Int53() + if err != nil { + return fmt.Errorf("unable to decode starSubscription#6caf0ade: field chat_id: %w", err) + } + s.ChatID = value + } + { + value, err := b.Int32() + if err != nil { + return fmt.Errorf("unable to decode starSubscription#6caf0ade: field expiration_date: %w", err) + } + s.ExpirationDate = value + } + { + value, err := b.Bool() + if err != nil { + return fmt.Errorf("unable to decode starSubscription#6caf0ade: field can_reuse: %w", err) + } + s.CanReuse = value + } + { + value, err := b.Bool() + if err != nil { + return fmt.Errorf("unable to decode starSubscription#6caf0ade: field is_canceled: %w", err) + } + s.IsCanceled = value + } + { + value, err := b.Bool() + if err != nil { + return fmt.Errorf("unable to decode starSubscription#6caf0ade: field is_expiring: %w", err) + } + s.IsExpiring = value + } + { + value, err := b.String() + if err != nil { + return fmt.Errorf("unable to decode starSubscription#6caf0ade: field invite_link: %w", err) + } + s.InviteLink = value + } + { + if err := s.Pricing.Decode(b); err != nil { + return fmt.Errorf("unable to decode starSubscription#6caf0ade: field pricing: %w", err) + } + } + return nil +} + +// EncodeTDLibJSON implements tdjson.TDLibEncoder. +func (s *StarSubscription) EncodeTDLibJSON(b tdjson.Encoder) error { + if s == nil { + return fmt.Errorf("can't encode starSubscription#6caf0ade as nil") + } + b.ObjStart() + b.PutID("starSubscription") + b.Comma() + b.FieldStart("id") + b.PutString(s.ID) + b.Comma() + b.FieldStart("chat_id") + b.PutInt53(s.ChatID) + b.Comma() + b.FieldStart("expiration_date") + b.PutInt32(s.ExpirationDate) + b.Comma() + b.FieldStart("can_reuse") + b.PutBool(s.CanReuse) + b.Comma() + b.FieldStart("is_canceled") + b.PutBool(s.IsCanceled) + b.Comma() + b.FieldStart("is_expiring") + b.PutBool(s.IsExpiring) + b.Comma() + b.FieldStart("invite_link") + b.PutString(s.InviteLink) + b.Comma() + b.FieldStart("pricing") + if err := s.Pricing.EncodeTDLibJSON(b); err != nil { + return fmt.Errorf("unable to encode starSubscription#6caf0ade: field pricing: %w", err) + } + b.Comma() + b.StripComma() + b.ObjEnd() + return nil +} + +// DecodeTDLibJSON implements tdjson.TDLibDecoder. +func (s *StarSubscription) DecodeTDLibJSON(b tdjson.Decoder) error { + if s == nil { + return fmt.Errorf("can't decode starSubscription#6caf0ade to nil") + } + + return b.Obj(func(b tdjson.Decoder, key []byte) error { + switch string(key) { + case tdjson.TypeField: + if err := b.ConsumeID("starSubscription"); err != nil { + return fmt.Errorf("unable to decode starSubscription#6caf0ade: %w", err) + } + case "id": + value, err := b.String() + if err != nil { + return fmt.Errorf("unable to decode starSubscription#6caf0ade: field id: %w", err) + } + s.ID = value + case "chat_id": + value, err := b.Int53() + if err != nil { + return fmt.Errorf("unable to decode starSubscription#6caf0ade: field chat_id: %w", err) + } + s.ChatID = value + case "expiration_date": + value, err := b.Int32() + if err != nil { + return fmt.Errorf("unable to decode starSubscription#6caf0ade: field expiration_date: %w", err) + } + s.ExpirationDate = value + case "can_reuse": + value, err := b.Bool() + if err != nil { + return fmt.Errorf("unable to decode starSubscription#6caf0ade: field can_reuse: %w", err) + } + s.CanReuse = value + case "is_canceled": + value, err := b.Bool() + if err != nil { + return fmt.Errorf("unable to decode starSubscription#6caf0ade: field is_canceled: %w", err) + } + s.IsCanceled = value + case "is_expiring": + value, err := b.Bool() + if err != nil { + return fmt.Errorf("unable to decode starSubscription#6caf0ade: field is_expiring: %w", err) + } + s.IsExpiring = value + case "invite_link": + value, err := b.String() + if err != nil { + return fmt.Errorf("unable to decode starSubscription#6caf0ade: field invite_link: %w", err) + } + s.InviteLink = value + case "pricing": + if err := s.Pricing.DecodeTDLibJSON(b); err != nil { + return fmt.Errorf("unable to decode starSubscription#6caf0ade: field pricing: %w", err) + } + default: + return b.Skip() + } + return nil + }) +} + +// GetID returns value of ID field. +func (s *StarSubscription) GetID() (value string) { + if s == nil { + return + } + return s.ID +} + +// GetChatID returns value of ChatID field. +func (s *StarSubscription) GetChatID() (value int64) { + if s == nil { + return + } + return s.ChatID +} + +// GetExpirationDate returns value of ExpirationDate field. +func (s *StarSubscription) GetExpirationDate() (value int32) { + if s == nil { + return + } + return s.ExpirationDate +} + +// GetCanReuse returns value of CanReuse field. +func (s *StarSubscription) GetCanReuse() (value bool) { + if s == nil { + return + } + return s.CanReuse +} + +// GetIsCanceled returns value of IsCanceled field. +func (s *StarSubscription) GetIsCanceled() (value bool) { + if s == nil { + return + } + return s.IsCanceled +} + +// GetIsExpiring returns value of IsExpiring field. +func (s *StarSubscription) GetIsExpiring() (value bool) { + if s == nil { + return + } + return s.IsExpiring +} + +// GetInviteLink returns value of InviteLink field. +func (s *StarSubscription) GetInviteLink() (value string) { + if s == nil { + return + } + return s.InviteLink +} + +// GetPricing returns value of Pricing field. +func (s *StarSubscription) GetPricing() (value StarSubscriptionPricing) { + if s == nil { + return + } + return s.Pricing +} diff --git a/tdapi/tl_star_subscription_pricing_gen.go b/tdapi/tl_star_subscription_pricing_gen.go new file mode 100644 index 0000000000..4e239a17be --- /dev/null +++ b/tdapi/tl_star_subscription_pricing_gen.go @@ -0,0 +1,227 @@ +// Code generated by gotdgen, DO NOT EDIT. + +package tdapi + +import ( + "context" + "errors" + "fmt" + "sort" + "strings" + + "go.uber.org/multierr" + + "github.com/gotd/td/bin" + "github.com/gotd/td/tdjson" + "github.com/gotd/td/tdp" + "github.com/gotd/td/tgerr" +) + +// No-op definition for keeping imports. +var ( + _ = bin.Buffer{} + _ = context.Background() + _ = fmt.Stringer(nil) + _ = strings.Builder{} + _ = errors.Is + _ = multierr.AppendInto + _ = sort.Ints + _ = tdp.Format + _ = tgerr.Error{} + _ = tdjson.Encoder{} +) + +// StarSubscriptionPricing represents TL type `starSubscriptionPricing#96a28856`. +type StarSubscriptionPricing struct { + // The number of seconds between consecutive Telegram Star debiting + Period int32 + // The amount of Telegram Stars that must be paid for each period + StarCount int64 +} + +// StarSubscriptionPricingTypeID is TL type id of StarSubscriptionPricing. +const StarSubscriptionPricingTypeID = 0x96a28856 + +// Ensuring interfaces in compile-time for StarSubscriptionPricing. +var ( + _ bin.Encoder = &StarSubscriptionPricing{} + _ bin.Decoder = &StarSubscriptionPricing{} + _ bin.BareEncoder = &StarSubscriptionPricing{} + _ bin.BareDecoder = &StarSubscriptionPricing{} +) + +func (s *StarSubscriptionPricing) Zero() bool { + if s == nil { + return true + } + if !(s.Period == 0) { + return false + } + if !(s.StarCount == 0) { + return false + } + + return true +} + +// String implements fmt.Stringer. +func (s *StarSubscriptionPricing) String() string { + if s == nil { + return "StarSubscriptionPricing(nil)" + } + type Alias StarSubscriptionPricing + return fmt.Sprintf("StarSubscriptionPricing%+v", Alias(*s)) +} + +// TypeID returns type id in TL schema. +// +// See https://core.telegram.org/mtproto/TL-tl#remarks. +func (*StarSubscriptionPricing) TypeID() uint32 { + return StarSubscriptionPricingTypeID +} + +// TypeName returns name of type in TL schema. +func (*StarSubscriptionPricing) TypeName() string { + return "starSubscriptionPricing" +} + +// TypeInfo returns info about TL type. +func (s *StarSubscriptionPricing) TypeInfo() tdp.Type { + typ := tdp.Type{ + Name: "starSubscriptionPricing", + ID: StarSubscriptionPricingTypeID, + } + if s == nil { + typ.Null = true + return typ + } + typ.Fields = []tdp.Field{ + { + Name: "Period", + SchemaName: "period", + }, + { + Name: "StarCount", + SchemaName: "star_count", + }, + } + return typ +} + +// Encode implements bin.Encoder. +func (s *StarSubscriptionPricing) Encode(b *bin.Buffer) error { + if s == nil { + return fmt.Errorf("can't encode starSubscriptionPricing#96a28856 as nil") + } + b.PutID(StarSubscriptionPricingTypeID) + return s.EncodeBare(b) +} + +// EncodeBare implements bin.BareEncoder. +func (s *StarSubscriptionPricing) EncodeBare(b *bin.Buffer) error { + if s == nil { + return fmt.Errorf("can't encode starSubscriptionPricing#96a28856 as nil") + } + b.PutInt32(s.Period) + b.PutInt53(s.StarCount) + return nil +} + +// Decode implements bin.Decoder. +func (s *StarSubscriptionPricing) Decode(b *bin.Buffer) error { + if s == nil { + return fmt.Errorf("can't decode starSubscriptionPricing#96a28856 to nil") + } + if err := b.ConsumeID(StarSubscriptionPricingTypeID); err != nil { + return fmt.Errorf("unable to decode starSubscriptionPricing#96a28856: %w", err) + } + return s.DecodeBare(b) +} + +// DecodeBare implements bin.BareDecoder. +func (s *StarSubscriptionPricing) DecodeBare(b *bin.Buffer) error { + if s == nil { + return fmt.Errorf("can't decode starSubscriptionPricing#96a28856 to nil") + } + { + value, err := b.Int32() + if err != nil { + return fmt.Errorf("unable to decode starSubscriptionPricing#96a28856: field period: %w", err) + } + s.Period = value + } + { + value, err := b.Int53() + if err != nil { + return fmt.Errorf("unable to decode starSubscriptionPricing#96a28856: field star_count: %w", err) + } + s.StarCount = value + } + return nil +} + +// EncodeTDLibJSON implements tdjson.TDLibEncoder. +func (s *StarSubscriptionPricing) EncodeTDLibJSON(b tdjson.Encoder) error { + if s == nil { + return fmt.Errorf("can't encode starSubscriptionPricing#96a28856 as nil") + } + b.ObjStart() + b.PutID("starSubscriptionPricing") + b.Comma() + b.FieldStart("period") + b.PutInt32(s.Period) + b.Comma() + b.FieldStart("star_count") + b.PutInt53(s.StarCount) + b.Comma() + b.StripComma() + b.ObjEnd() + return nil +} + +// DecodeTDLibJSON implements tdjson.TDLibDecoder. +func (s *StarSubscriptionPricing) DecodeTDLibJSON(b tdjson.Decoder) error { + if s == nil { + return fmt.Errorf("can't decode starSubscriptionPricing#96a28856 to nil") + } + + return b.Obj(func(b tdjson.Decoder, key []byte) error { + switch string(key) { + case tdjson.TypeField: + if err := b.ConsumeID("starSubscriptionPricing"); err != nil { + return fmt.Errorf("unable to decode starSubscriptionPricing#96a28856: %w", err) + } + case "period": + value, err := b.Int32() + if err != nil { + return fmt.Errorf("unable to decode starSubscriptionPricing#96a28856: field period: %w", err) + } + s.Period = value + case "star_count": + value, err := b.Int53() + if err != nil { + return fmt.Errorf("unable to decode starSubscriptionPricing#96a28856: field star_count: %w", err) + } + s.StarCount = value + default: + return b.Skip() + } + return nil + }) +} + +// GetPeriod returns value of Period field. +func (s *StarSubscriptionPricing) GetPeriod() (value int32) { + if s == nil { + return + } + return s.Period +} + +// GetStarCount returns value of StarCount field. +func (s *StarSubscriptionPricing) GetStarCount() (value int64) { + if s == nil { + return + } + return s.StarCount +} diff --git a/tdapi/tl_star_subscriptions_gen.go b/tdapi/tl_star_subscriptions_gen.go new file mode 100644 index 0000000000..b240721d3c --- /dev/null +++ b/tdapi/tl_star_subscriptions_gen.go @@ -0,0 +1,323 @@ +// Code generated by gotdgen, DO NOT EDIT. + +package tdapi + +import ( + "context" + "errors" + "fmt" + "sort" + "strings" + + "go.uber.org/multierr" + + "github.com/gotd/td/bin" + "github.com/gotd/td/tdjson" + "github.com/gotd/td/tdp" + "github.com/gotd/td/tgerr" +) + +// No-op definition for keeping imports. +var ( + _ = bin.Buffer{} + _ = context.Background() + _ = fmt.Stringer(nil) + _ = strings.Builder{} + _ = errors.Is + _ = multierr.AppendInto + _ = sort.Ints + _ = tdp.Format + _ = tgerr.Error{} + _ = tdjson.Encoder{} +) + +// StarSubscriptions represents TL type `starSubscriptions#f7a7ae44`. +type StarSubscriptions struct { + // The amount of owned Telegram Stars + StarCount int64 + // List of subbscriptions for Telegram Stars + Subscriptions []StarSubscription + // The number of Telegram Stars required to buy to extend subscriptions expiring soon + RequiredStarCount int64 + // The offset for the next request. If empty, then there are no more results + NextOffset string +} + +// StarSubscriptionsTypeID is TL type id of StarSubscriptions. +const StarSubscriptionsTypeID = 0xf7a7ae44 + +// Ensuring interfaces in compile-time for StarSubscriptions. +var ( + _ bin.Encoder = &StarSubscriptions{} + _ bin.Decoder = &StarSubscriptions{} + _ bin.BareEncoder = &StarSubscriptions{} + _ bin.BareDecoder = &StarSubscriptions{} +) + +func (s *StarSubscriptions) Zero() bool { + if s == nil { + return true + } + if !(s.StarCount == 0) { + return false + } + if !(s.Subscriptions == nil) { + return false + } + if !(s.RequiredStarCount == 0) { + return false + } + if !(s.NextOffset == "") { + return false + } + + return true +} + +// String implements fmt.Stringer. +func (s *StarSubscriptions) String() string { + if s == nil { + return "StarSubscriptions(nil)" + } + type Alias StarSubscriptions + return fmt.Sprintf("StarSubscriptions%+v", Alias(*s)) +} + +// TypeID returns type id in TL schema. +// +// See https://core.telegram.org/mtproto/TL-tl#remarks. +func (*StarSubscriptions) TypeID() uint32 { + return StarSubscriptionsTypeID +} + +// TypeName returns name of type in TL schema. +func (*StarSubscriptions) TypeName() string { + return "starSubscriptions" +} + +// TypeInfo returns info about TL type. +func (s *StarSubscriptions) TypeInfo() tdp.Type { + typ := tdp.Type{ + Name: "starSubscriptions", + ID: StarSubscriptionsTypeID, + } + if s == nil { + typ.Null = true + return typ + } + typ.Fields = []tdp.Field{ + { + Name: "StarCount", + SchemaName: "star_count", + }, + { + Name: "Subscriptions", + SchemaName: "subscriptions", + }, + { + Name: "RequiredStarCount", + SchemaName: "required_star_count", + }, + { + Name: "NextOffset", + SchemaName: "next_offset", + }, + } + return typ +} + +// Encode implements bin.Encoder. +func (s *StarSubscriptions) Encode(b *bin.Buffer) error { + if s == nil { + return fmt.Errorf("can't encode starSubscriptions#f7a7ae44 as nil") + } + b.PutID(StarSubscriptionsTypeID) + return s.EncodeBare(b) +} + +// EncodeBare implements bin.BareEncoder. +func (s *StarSubscriptions) EncodeBare(b *bin.Buffer) error { + if s == nil { + return fmt.Errorf("can't encode starSubscriptions#f7a7ae44 as nil") + } + b.PutInt53(s.StarCount) + b.PutInt(len(s.Subscriptions)) + for idx, v := range s.Subscriptions { + if err := v.EncodeBare(b); err != nil { + return fmt.Errorf("unable to encode bare starSubscriptions#f7a7ae44: field subscriptions element with index %d: %w", idx, err) + } + } + b.PutInt53(s.RequiredStarCount) + b.PutString(s.NextOffset) + return nil +} + +// Decode implements bin.Decoder. +func (s *StarSubscriptions) Decode(b *bin.Buffer) error { + if s == nil { + return fmt.Errorf("can't decode starSubscriptions#f7a7ae44 to nil") + } + if err := b.ConsumeID(StarSubscriptionsTypeID); err != nil { + return fmt.Errorf("unable to decode starSubscriptions#f7a7ae44: %w", err) + } + return s.DecodeBare(b) +} + +// DecodeBare implements bin.BareDecoder. +func (s *StarSubscriptions) DecodeBare(b *bin.Buffer) error { + if s == nil { + return fmt.Errorf("can't decode starSubscriptions#f7a7ae44 to nil") + } + { + value, err := b.Int53() + if err != nil { + return fmt.Errorf("unable to decode starSubscriptions#f7a7ae44: field star_count: %w", err) + } + s.StarCount = value + } + { + headerLen, err := b.Int() + if err != nil { + return fmt.Errorf("unable to decode starSubscriptions#f7a7ae44: field subscriptions: %w", err) + } + + if headerLen > 0 { + s.Subscriptions = make([]StarSubscription, 0, headerLen%bin.PreallocateLimit) + } + for idx := 0; idx < headerLen; idx++ { + var value StarSubscription + if err := value.DecodeBare(b); err != nil { + return fmt.Errorf("unable to decode bare starSubscriptions#f7a7ae44: field subscriptions: %w", err) + } + s.Subscriptions = append(s.Subscriptions, value) + } + } + { + value, err := b.Int53() + if err != nil { + return fmt.Errorf("unable to decode starSubscriptions#f7a7ae44: field required_star_count: %w", err) + } + s.RequiredStarCount = value + } + { + value, err := b.String() + if err != nil { + return fmt.Errorf("unable to decode starSubscriptions#f7a7ae44: field next_offset: %w", err) + } + s.NextOffset = value + } + return nil +} + +// EncodeTDLibJSON implements tdjson.TDLibEncoder. +func (s *StarSubscriptions) EncodeTDLibJSON(b tdjson.Encoder) error { + if s == nil { + return fmt.Errorf("can't encode starSubscriptions#f7a7ae44 as nil") + } + b.ObjStart() + b.PutID("starSubscriptions") + b.Comma() + b.FieldStart("star_count") + b.PutInt53(s.StarCount) + b.Comma() + b.FieldStart("subscriptions") + b.ArrStart() + for idx, v := range s.Subscriptions { + if err := v.EncodeTDLibJSON(b); err != nil { + return fmt.Errorf("unable to encode starSubscriptions#f7a7ae44: field subscriptions element with index %d: %w", idx, err) + } + b.Comma() + } + b.StripComma() + b.ArrEnd() + b.Comma() + b.FieldStart("required_star_count") + b.PutInt53(s.RequiredStarCount) + b.Comma() + b.FieldStart("next_offset") + b.PutString(s.NextOffset) + b.Comma() + b.StripComma() + b.ObjEnd() + return nil +} + +// DecodeTDLibJSON implements tdjson.TDLibDecoder. +func (s *StarSubscriptions) DecodeTDLibJSON(b tdjson.Decoder) error { + if s == nil { + return fmt.Errorf("can't decode starSubscriptions#f7a7ae44 to nil") + } + + return b.Obj(func(b tdjson.Decoder, key []byte) error { + switch string(key) { + case tdjson.TypeField: + if err := b.ConsumeID("starSubscriptions"); err != nil { + return fmt.Errorf("unable to decode starSubscriptions#f7a7ae44: %w", err) + } + case "star_count": + value, err := b.Int53() + if err != nil { + return fmt.Errorf("unable to decode starSubscriptions#f7a7ae44: field star_count: %w", err) + } + s.StarCount = value + case "subscriptions": + if err := b.Arr(func(b tdjson.Decoder) error { + var value StarSubscription + if err := value.DecodeTDLibJSON(b); err != nil { + return fmt.Errorf("unable to decode starSubscriptions#f7a7ae44: field subscriptions: %w", err) + } + s.Subscriptions = append(s.Subscriptions, value) + return nil + }); err != nil { + return fmt.Errorf("unable to decode starSubscriptions#f7a7ae44: field subscriptions: %w", err) + } + case "required_star_count": + value, err := b.Int53() + if err != nil { + return fmt.Errorf("unable to decode starSubscriptions#f7a7ae44: field required_star_count: %w", err) + } + s.RequiredStarCount = value + case "next_offset": + value, err := b.String() + if err != nil { + return fmt.Errorf("unable to decode starSubscriptions#f7a7ae44: field next_offset: %w", err) + } + s.NextOffset = value + default: + return b.Skip() + } + return nil + }) +} + +// GetStarCount returns value of StarCount field. +func (s *StarSubscriptions) GetStarCount() (value int64) { + if s == nil { + return + } + return s.StarCount +} + +// GetSubscriptions returns value of Subscriptions field. +func (s *StarSubscriptions) GetSubscriptions() (value []StarSubscription) { + if s == nil { + return + } + return s.Subscriptions +} + +// GetRequiredStarCount returns value of RequiredStarCount field. +func (s *StarSubscriptions) GetRequiredStarCount() (value int64) { + if s == nil { + return + } + return s.RequiredStarCount +} + +// GetNextOffset returns value of NextOffset field. +func (s *StarSubscriptions) GetNextOffset() (value string) { + if s == nil { + return + } + return s.NextOffset +} diff --git a/tdapi/tl_star_transaction_partner_gen.go b/tdapi/tl_star_transaction_partner_gen.go index bf4f18a3e3..aecccbce87 100644 --- a/tdapi/tl_star_transaction_partner_gen.go +++ b/tdapi/tl_star_transaction_partner_gen.go @@ -731,18 +731,16 @@ func (s *StarTransactionPartnerTelegramAds) DecodeTDLibJSON(b tdjson.Decoder) er }) } -// StarTransactionPartnerBot represents TL type `starTransactionPartnerBot#298ce3d9`. +// StarTransactionPartnerBot represents TL type `starTransactionPartnerBot#4ece3a40`. type StarTransactionPartnerBot struct { - // Identifier of the bot for the user, or the user for the bot + // Identifier of the bot UserID int64 - // Information about the bought product; may be null if not applicable - ProductInfo ProductInfo - // Invoice payload; for bots only - InvoicePayload []byte + // Purpose of the transaction + Purpose BotTransactionPurposeClass } // StarTransactionPartnerBotTypeID is TL type id of StarTransactionPartnerBot. -const StarTransactionPartnerBotTypeID = 0x298ce3d9 +const StarTransactionPartnerBotTypeID = 0x4ece3a40 // construct implements constructor of StarTransactionPartnerClass. func (s StarTransactionPartnerBot) construct() StarTransactionPartnerClass { return &s } @@ -764,10 +762,7 @@ func (s *StarTransactionPartnerBot) Zero() bool { if !(s.UserID == 0) { return false } - if !(s.ProductInfo.Zero()) { - return false - } - if !(s.InvoicePayload == nil) { + if !(s.Purpose == nil) { return false } @@ -811,12 +806,8 @@ func (s *StarTransactionPartnerBot) TypeInfo() tdp.Type { SchemaName: "user_id", }, { - Name: "ProductInfo", - SchemaName: "product_info", - }, - { - Name: "InvoicePayload", - SchemaName: "invoice_payload", + Name: "Purpose", + SchemaName: "purpose", }, } return typ @@ -825,7 +816,7 @@ func (s *StarTransactionPartnerBot) TypeInfo() tdp.Type { // Encode implements bin.Encoder. func (s *StarTransactionPartnerBot) Encode(b *bin.Buffer) error { if s == nil { - return fmt.Errorf("can't encode starTransactionPartnerBot#298ce3d9 as nil") + return fmt.Errorf("can't encode starTransactionPartnerBot#4ece3a40 as nil") } b.PutID(StarTransactionPartnerBotTypeID) return s.EncodeBare(b) @@ -834,23 +825,25 @@ func (s *StarTransactionPartnerBot) Encode(b *bin.Buffer) error { // EncodeBare implements bin.BareEncoder. func (s *StarTransactionPartnerBot) EncodeBare(b *bin.Buffer) error { if s == nil { - return fmt.Errorf("can't encode starTransactionPartnerBot#298ce3d9 as nil") + return fmt.Errorf("can't encode starTransactionPartnerBot#4ece3a40 as nil") } b.PutInt53(s.UserID) - if err := s.ProductInfo.Encode(b); err != nil { - return fmt.Errorf("unable to encode starTransactionPartnerBot#298ce3d9: field product_info: %w", err) + if s.Purpose == nil { + return fmt.Errorf("unable to encode starTransactionPartnerBot#4ece3a40: field purpose is nil") + } + if err := s.Purpose.Encode(b); err != nil { + return fmt.Errorf("unable to encode starTransactionPartnerBot#4ece3a40: field purpose: %w", err) } - b.PutBytes(s.InvoicePayload) return nil } // Decode implements bin.Decoder. func (s *StarTransactionPartnerBot) Decode(b *bin.Buffer) error { if s == nil { - return fmt.Errorf("can't decode starTransactionPartnerBot#298ce3d9 to nil") + return fmt.Errorf("can't decode starTransactionPartnerBot#4ece3a40 to nil") } if err := b.ConsumeID(StarTransactionPartnerBotTypeID); err != nil { - return fmt.Errorf("unable to decode starTransactionPartnerBot#298ce3d9: %w", err) + return fmt.Errorf("unable to decode starTransactionPartnerBot#4ece3a40: %w", err) } return s.DecodeBare(b) } @@ -858,26 +851,21 @@ func (s *StarTransactionPartnerBot) Decode(b *bin.Buffer) error { // DecodeBare implements bin.BareDecoder. func (s *StarTransactionPartnerBot) DecodeBare(b *bin.Buffer) error { if s == nil { - return fmt.Errorf("can't decode starTransactionPartnerBot#298ce3d9 to nil") + return fmt.Errorf("can't decode starTransactionPartnerBot#4ece3a40 to nil") } { value, err := b.Int53() if err != nil { - return fmt.Errorf("unable to decode starTransactionPartnerBot#298ce3d9: field user_id: %w", err) + return fmt.Errorf("unable to decode starTransactionPartnerBot#4ece3a40: field user_id: %w", err) } s.UserID = value } { - if err := s.ProductInfo.Decode(b); err != nil { - return fmt.Errorf("unable to decode starTransactionPartnerBot#298ce3d9: field product_info: %w", err) - } - } - { - value, err := b.Bytes() + value, err := DecodeBotTransactionPurpose(b) if err != nil { - return fmt.Errorf("unable to decode starTransactionPartnerBot#298ce3d9: field invoice_payload: %w", err) + return fmt.Errorf("unable to decode starTransactionPartnerBot#4ece3a40: field purpose: %w", err) } - s.InvoicePayload = value + s.Purpose = value } return nil } @@ -885,7 +873,7 @@ func (s *StarTransactionPartnerBot) DecodeBare(b *bin.Buffer) error { // EncodeTDLibJSON implements tdjson.TDLibEncoder. func (s *StarTransactionPartnerBot) EncodeTDLibJSON(b tdjson.Encoder) error { if s == nil { - return fmt.Errorf("can't encode starTransactionPartnerBot#298ce3d9 as nil") + return fmt.Errorf("can't encode starTransactionPartnerBot#4ece3a40 as nil") } b.ObjStart() b.PutID("starTransactionPartnerBot") @@ -893,13 +881,13 @@ func (s *StarTransactionPartnerBot) EncodeTDLibJSON(b tdjson.Encoder) error { b.FieldStart("user_id") b.PutInt53(s.UserID) b.Comma() - b.FieldStart("product_info") - if err := s.ProductInfo.EncodeTDLibJSON(b); err != nil { - return fmt.Errorf("unable to encode starTransactionPartnerBot#298ce3d9: field product_info: %w", err) + b.FieldStart("purpose") + if s.Purpose == nil { + return fmt.Errorf("unable to encode starTransactionPartnerBot#4ece3a40: field purpose is nil") + } + if err := s.Purpose.EncodeTDLibJSON(b); err != nil { + return fmt.Errorf("unable to encode starTransactionPartnerBot#4ece3a40: field purpose: %w", err) } - b.Comma() - b.FieldStart("invoice_payload") - b.PutBytes(s.InvoicePayload) b.Comma() b.StripComma() b.ObjEnd() @@ -909,31 +897,27 @@ func (s *StarTransactionPartnerBot) EncodeTDLibJSON(b tdjson.Encoder) error { // DecodeTDLibJSON implements tdjson.TDLibDecoder. func (s *StarTransactionPartnerBot) DecodeTDLibJSON(b tdjson.Decoder) error { if s == nil { - return fmt.Errorf("can't decode starTransactionPartnerBot#298ce3d9 to nil") + return fmt.Errorf("can't decode starTransactionPartnerBot#4ece3a40 to nil") } return b.Obj(func(b tdjson.Decoder, key []byte) error { switch string(key) { case tdjson.TypeField: if err := b.ConsumeID("starTransactionPartnerBot"); err != nil { - return fmt.Errorf("unable to decode starTransactionPartnerBot#298ce3d9: %w", err) + return fmt.Errorf("unable to decode starTransactionPartnerBot#4ece3a40: %w", err) } case "user_id": value, err := b.Int53() if err != nil { - return fmt.Errorf("unable to decode starTransactionPartnerBot#298ce3d9: field user_id: %w", err) + return fmt.Errorf("unable to decode starTransactionPartnerBot#4ece3a40: field user_id: %w", err) } s.UserID = value - case "product_info": - if err := s.ProductInfo.DecodeTDLibJSON(b); err != nil { - return fmt.Errorf("unable to decode starTransactionPartnerBot#298ce3d9: field product_info: %w", err) - } - case "invoice_payload": - value, err := b.Bytes() + case "purpose": + value, err := DecodeTDLibJSONBotTransactionPurpose(b) if err != nil { - return fmt.Errorf("unable to decode starTransactionPartnerBot#298ce3d9: field invoice_payload: %w", err) + return fmt.Errorf("unable to decode starTransactionPartnerBot#4ece3a40: field purpose: %w", err) } - s.InvoicePayload = value + s.Purpose = value default: return b.Skip() } @@ -949,35 +933,258 @@ func (s *StarTransactionPartnerBot) GetUserID() (value int64) { return s.UserID } -// GetProductInfo returns value of ProductInfo field. -func (s *StarTransactionPartnerBot) GetProductInfo() (value ProductInfo) { +// GetPurpose returns value of Purpose field. +func (s *StarTransactionPartnerBot) GetPurpose() (value BotTransactionPurposeClass) { if s == nil { return } - return s.ProductInfo + return s.Purpose +} + +// StarTransactionPartnerBusiness represents TL type `starTransactionPartnerBusiness#7af9fb52`. +type StarTransactionPartnerBusiness struct { + // Identifier of the business account user + UserID int64 + // The bought media if the trancastion wasn't refunded + Media []PaidMediaClass +} + +// StarTransactionPartnerBusinessTypeID is TL type id of StarTransactionPartnerBusiness. +const StarTransactionPartnerBusinessTypeID = 0x7af9fb52 + +// construct implements constructor of StarTransactionPartnerClass. +func (s StarTransactionPartnerBusiness) construct() StarTransactionPartnerClass { return &s } + +// Ensuring interfaces in compile-time for StarTransactionPartnerBusiness. +var ( + _ bin.Encoder = &StarTransactionPartnerBusiness{} + _ bin.Decoder = &StarTransactionPartnerBusiness{} + _ bin.BareEncoder = &StarTransactionPartnerBusiness{} + _ bin.BareDecoder = &StarTransactionPartnerBusiness{} + + _ StarTransactionPartnerClass = &StarTransactionPartnerBusiness{} +) + +func (s *StarTransactionPartnerBusiness) Zero() bool { + if s == nil { + return true + } + if !(s.UserID == 0) { + return false + } + if !(s.Media == nil) { + return false + } + + return true +} + +// String implements fmt.Stringer. +func (s *StarTransactionPartnerBusiness) String() string { + if s == nil { + return "StarTransactionPartnerBusiness(nil)" + } + type Alias StarTransactionPartnerBusiness + return fmt.Sprintf("StarTransactionPartnerBusiness%+v", Alias(*s)) +} + +// TypeID returns type id in TL schema. +// +// See https://core.telegram.org/mtproto/TL-tl#remarks. +func (*StarTransactionPartnerBusiness) TypeID() uint32 { + return StarTransactionPartnerBusinessTypeID +} + +// TypeName returns name of type in TL schema. +func (*StarTransactionPartnerBusiness) TypeName() string { + return "starTransactionPartnerBusiness" } -// GetInvoicePayload returns value of InvoicePayload field. -func (s *StarTransactionPartnerBot) GetInvoicePayload() (value []byte) { +// TypeInfo returns info about TL type. +func (s *StarTransactionPartnerBusiness) TypeInfo() tdp.Type { + typ := tdp.Type{ + Name: "starTransactionPartnerBusiness", + ID: StarTransactionPartnerBusinessTypeID, + } + if s == nil { + typ.Null = true + return typ + } + typ.Fields = []tdp.Field{ + { + Name: "UserID", + SchemaName: "user_id", + }, + { + Name: "Media", + SchemaName: "media", + }, + } + return typ +} + +// Encode implements bin.Encoder. +func (s *StarTransactionPartnerBusiness) Encode(b *bin.Buffer) error { + if s == nil { + return fmt.Errorf("can't encode starTransactionPartnerBusiness#7af9fb52 as nil") + } + b.PutID(StarTransactionPartnerBusinessTypeID) + return s.EncodeBare(b) +} + +// EncodeBare implements bin.BareEncoder. +func (s *StarTransactionPartnerBusiness) EncodeBare(b *bin.Buffer) error { + if s == nil { + return fmt.Errorf("can't encode starTransactionPartnerBusiness#7af9fb52 as nil") + } + b.PutInt53(s.UserID) + b.PutInt(len(s.Media)) + for idx, v := range s.Media { + if v == nil { + return fmt.Errorf("unable to encode starTransactionPartnerBusiness#7af9fb52: field media element with index %d is nil", idx) + } + if err := v.EncodeBare(b); err != nil { + return fmt.Errorf("unable to encode bare starTransactionPartnerBusiness#7af9fb52: field media element with index %d: %w", idx, err) + } + } + return nil +} + +// Decode implements bin.Decoder. +func (s *StarTransactionPartnerBusiness) Decode(b *bin.Buffer) error { + if s == nil { + return fmt.Errorf("can't decode starTransactionPartnerBusiness#7af9fb52 to nil") + } + if err := b.ConsumeID(StarTransactionPartnerBusinessTypeID); err != nil { + return fmt.Errorf("unable to decode starTransactionPartnerBusiness#7af9fb52: %w", err) + } + return s.DecodeBare(b) +} + +// DecodeBare implements bin.BareDecoder. +func (s *StarTransactionPartnerBusiness) DecodeBare(b *bin.Buffer) error { + if s == nil { + return fmt.Errorf("can't decode starTransactionPartnerBusiness#7af9fb52 to nil") + } + { + value, err := b.Int53() + if err != nil { + return fmt.Errorf("unable to decode starTransactionPartnerBusiness#7af9fb52: field user_id: %w", err) + } + s.UserID = value + } + { + headerLen, err := b.Int() + if err != nil { + return fmt.Errorf("unable to decode starTransactionPartnerBusiness#7af9fb52: field media: %w", err) + } + + if headerLen > 0 { + s.Media = make([]PaidMediaClass, 0, headerLen%bin.PreallocateLimit) + } + for idx := 0; idx < headerLen; idx++ { + value, err := DecodePaidMedia(b) + if err != nil { + return fmt.Errorf("unable to decode starTransactionPartnerBusiness#7af9fb52: field media: %w", err) + } + s.Media = append(s.Media, value) + } + } + return nil +} + +// EncodeTDLibJSON implements tdjson.TDLibEncoder. +func (s *StarTransactionPartnerBusiness) EncodeTDLibJSON(b tdjson.Encoder) error { + if s == nil { + return fmt.Errorf("can't encode starTransactionPartnerBusiness#7af9fb52 as nil") + } + b.ObjStart() + b.PutID("starTransactionPartnerBusiness") + b.Comma() + b.FieldStart("user_id") + b.PutInt53(s.UserID) + b.Comma() + b.FieldStart("media") + b.ArrStart() + for idx, v := range s.Media { + if v == nil { + return fmt.Errorf("unable to encode starTransactionPartnerBusiness#7af9fb52: field media element with index %d is nil", idx) + } + if err := v.EncodeTDLibJSON(b); err != nil { + return fmt.Errorf("unable to encode starTransactionPartnerBusiness#7af9fb52: field media element with index %d: %w", idx, err) + } + b.Comma() + } + b.StripComma() + b.ArrEnd() + b.Comma() + b.StripComma() + b.ObjEnd() + return nil +} + +// DecodeTDLibJSON implements tdjson.TDLibDecoder. +func (s *StarTransactionPartnerBusiness) DecodeTDLibJSON(b tdjson.Decoder) error { + if s == nil { + return fmt.Errorf("can't decode starTransactionPartnerBusiness#7af9fb52 to nil") + } + + return b.Obj(func(b tdjson.Decoder, key []byte) error { + switch string(key) { + case tdjson.TypeField: + if err := b.ConsumeID("starTransactionPartnerBusiness"); err != nil { + return fmt.Errorf("unable to decode starTransactionPartnerBusiness#7af9fb52: %w", err) + } + case "user_id": + value, err := b.Int53() + if err != nil { + return fmt.Errorf("unable to decode starTransactionPartnerBusiness#7af9fb52: field user_id: %w", err) + } + s.UserID = value + case "media": + if err := b.Arr(func(b tdjson.Decoder) error { + value, err := DecodeTDLibJSONPaidMedia(b) + if err != nil { + return fmt.Errorf("unable to decode starTransactionPartnerBusiness#7af9fb52: field media: %w", err) + } + s.Media = append(s.Media, value) + return nil + }); err != nil { + return fmt.Errorf("unable to decode starTransactionPartnerBusiness#7af9fb52: field media: %w", err) + } + default: + return b.Skip() + } + return nil + }) +} + +// GetUserID returns value of UserID field. +func (s *StarTransactionPartnerBusiness) GetUserID() (value int64) { if s == nil { return } - return s.InvoicePayload + return s.UserID } -// StarTransactionPartnerChannel represents TL type `starTransactionPartnerChannel#44b29c29`. +// GetMedia returns value of Media field. +func (s *StarTransactionPartnerBusiness) GetMedia() (value []PaidMediaClass) { + if s == nil { + return + } + return s.Media +} + +// StarTransactionPartnerChannel represents TL type `starTransactionPartnerChannel#7c04767e`. type StarTransactionPartnerChannel struct { // Identifier of the chat ChatID int64 - // Identifier of the corresponding message with paid media; can be an identifier of a - // deleted message - PaidMediaMessageID int64 - // Information about the bought media - Media []PaidMediaClass + // Purpose of the transaction + Purpose ChannelTransactionPurposeClass } // StarTransactionPartnerChannelTypeID is TL type id of StarTransactionPartnerChannel. -const StarTransactionPartnerChannelTypeID = 0x44b29c29 +const StarTransactionPartnerChannelTypeID = 0x7c04767e // construct implements constructor of StarTransactionPartnerClass. func (s StarTransactionPartnerChannel) construct() StarTransactionPartnerClass { return &s } @@ -999,10 +1206,7 @@ func (s *StarTransactionPartnerChannel) Zero() bool { if !(s.ChatID == 0) { return false } - if !(s.PaidMediaMessageID == 0) { - return false - } - if !(s.Media == nil) { + if !(s.Purpose == nil) { return false } @@ -1046,12 +1250,8 @@ func (s *StarTransactionPartnerChannel) TypeInfo() tdp.Type { SchemaName: "chat_id", }, { - Name: "PaidMediaMessageID", - SchemaName: "paid_media_message_id", - }, - { - Name: "Media", - SchemaName: "media", + Name: "Purpose", + SchemaName: "purpose", }, } return typ @@ -1060,7 +1260,7 @@ func (s *StarTransactionPartnerChannel) TypeInfo() tdp.Type { // Encode implements bin.Encoder. func (s *StarTransactionPartnerChannel) Encode(b *bin.Buffer) error { if s == nil { - return fmt.Errorf("can't encode starTransactionPartnerChannel#44b29c29 as nil") + return fmt.Errorf("can't encode starTransactionPartnerChannel#7c04767e as nil") } b.PutID(StarTransactionPartnerChannelTypeID) return s.EncodeBare(b) @@ -1069,18 +1269,14 @@ func (s *StarTransactionPartnerChannel) Encode(b *bin.Buffer) error { // EncodeBare implements bin.BareEncoder. func (s *StarTransactionPartnerChannel) EncodeBare(b *bin.Buffer) error { if s == nil { - return fmt.Errorf("can't encode starTransactionPartnerChannel#44b29c29 as nil") + return fmt.Errorf("can't encode starTransactionPartnerChannel#7c04767e as nil") } b.PutInt53(s.ChatID) - b.PutInt53(s.PaidMediaMessageID) - b.PutInt(len(s.Media)) - for idx, v := range s.Media { - if v == nil { - return fmt.Errorf("unable to encode starTransactionPartnerChannel#44b29c29: field media element with index %d is nil", idx) - } - if err := v.EncodeBare(b); err != nil { - return fmt.Errorf("unable to encode bare starTransactionPartnerChannel#44b29c29: field media element with index %d: %w", idx, err) - } + if s.Purpose == nil { + return fmt.Errorf("unable to encode starTransactionPartnerChannel#7c04767e: field purpose is nil") + } + if err := s.Purpose.Encode(b); err != nil { + return fmt.Errorf("unable to encode starTransactionPartnerChannel#7c04767e: field purpose: %w", err) } return nil } @@ -1088,10 +1284,10 @@ func (s *StarTransactionPartnerChannel) EncodeBare(b *bin.Buffer) error { // Decode implements bin.Decoder. func (s *StarTransactionPartnerChannel) Decode(b *bin.Buffer) error { if s == nil { - return fmt.Errorf("can't decode starTransactionPartnerChannel#44b29c29 to nil") + return fmt.Errorf("can't decode starTransactionPartnerChannel#7c04767e to nil") } if err := b.ConsumeID(StarTransactionPartnerChannelTypeID); err != nil { - return fmt.Errorf("unable to decode starTransactionPartnerChannel#44b29c29: %w", err) + return fmt.Errorf("unable to decode starTransactionPartnerChannel#7c04767e: %w", err) } return s.DecodeBare(b) } @@ -1099,38 +1295,21 @@ func (s *StarTransactionPartnerChannel) Decode(b *bin.Buffer) error { // DecodeBare implements bin.BareDecoder. func (s *StarTransactionPartnerChannel) DecodeBare(b *bin.Buffer) error { if s == nil { - return fmt.Errorf("can't decode starTransactionPartnerChannel#44b29c29 to nil") + return fmt.Errorf("can't decode starTransactionPartnerChannel#7c04767e to nil") } { value, err := b.Int53() if err != nil { - return fmt.Errorf("unable to decode starTransactionPartnerChannel#44b29c29: field chat_id: %w", err) + return fmt.Errorf("unable to decode starTransactionPartnerChannel#7c04767e: field chat_id: %w", err) } s.ChatID = value } { - value, err := b.Int53() - if err != nil { - return fmt.Errorf("unable to decode starTransactionPartnerChannel#44b29c29: field paid_media_message_id: %w", err) - } - s.PaidMediaMessageID = value - } - { - headerLen, err := b.Int() + value, err := DecodeChannelTransactionPurpose(b) if err != nil { - return fmt.Errorf("unable to decode starTransactionPartnerChannel#44b29c29: field media: %w", err) - } - - if headerLen > 0 { - s.Media = make([]PaidMediaClass, 0, headerLen%bin.PreallocateLimit) - } - for idx := 0; idx < headerLen; idx++ { - value, err := DecodePaidMedia(b) - if err != nil { - return fmt.Errorf("unable to decode starTransactionPartnerChannel#44b29c29: field media: %w", err) - } - s.Media = append(s.Media, value) + return fmt.Errorf("unable to decode starTransactionPartnerChannel#7c04767e: field purpose: %w", err) } + s.Purpose = value } return nil } @@ -1138,7 +1317,7 @@ func (s *StarTransactionPartnerChannel) DecodeBare(b *bin.Buffer) error { // EncodeTDLibJSON implements tdjson.TDLibEncoder. func (s *StarTransactionPartnerChannel) EncodeTDLibJSON(b tdjson.Encoder) error { if s == nil { - return fmt.Errorf("can't encode starTransactionPartnerChannel#44b29c29 as nil") + return fmt.Errorf("can't encode starTransactionPartnerChannel#7c04767e as nil") } b.ObjStart() b.PutID("starTransactionPartnerChannel") @@ -1146,22 +1325,13 @@ func (s *StarTransactionPartnerChannel) EncodeTDLibJSON(b tdjson.Encoder) error b.FieldStart("chat_id") b.PutInt53(s.ChatID) b.Comma() - b.FieldStart("paid_media_message_id") - b.PutInt53(s.PaidMediaMessageID) - b.Comma() - b.FieldStart("media") - b.ArrStart() - for idx, v := range s.Media { - if v == nil { - return fmt.Errorf("unable to encode starTransactionPartnerChannel#44b29c29: field media element with index %d is nil", idx) - } - if err := v.EncodeTDLibJSON(b); err != nil { - return fmt.Errorf("unable to encode starTransactionPartnerChannel#44b29c29: field media element with index %d: %w", idx, err) - } - b.Comma() + b.FieldStart("purpose") + if s.Purpose == nil { + return fmt.Errorf("unable to encode starTransactionPartnerChannel#7c04767e: field purpose is nil") + } + if err := s.Purpose.EncodeTDLibJSON(b); err != nil { + return fmt.Errorf("unable to encode starTransactionPartnerChannel#7c04767e: field purpose: %w", err) } - b.StripComma() - b.ArrEnd() b.Comma() b.StripComma() b.ObjEnd() @@ -1171,38 +1341,27 @@ func (s *StarTransactionPartnerChannel) EncodeTDLibJSON(b tdjson.Encoder) error // DecodeTDLibJSON implements tdjson.TDLibDecoder. func (s *StarTransactionPartnerChannel) DecodeTDLibJSON(b tdjson.Decoder) error { if s == nil { - return fmt.Errorf("can't decode starTransactionPartnerChannel#44b29c29 to nil") + return fmt.Errorf("can't decode starTransactionPartnerChannel#7c04767e to nil") } return b.Obj(func(b tdjson.Decoder, key []byte) error { switch string(key) { case tdjson.TypeField: if err := b.ConsumeID("starTransactionPartnerChannel"); err != nil { - return fmt.Errorf("unable to decode starTransactionPartnerChannel#44b29c29: %w", err) + return fmt.Errorf("unable to decode starTransactionPartnerChannel#7c04767e: %w", err) } case "chat_id": value, err := b.Int53() if err != nil { - return fmt.Errorf("unable to decode starTransactionPartnerChannel#44b29c29: field chat_id: %w", err) + return fmt.Errorf("unable to decode starTransactionPartnerChannel#7c04767e: field chat_id: %w", err) } s.ChatID = value - case "paid_media_message_id": - value, err := b.Int53() + case "purpose": + value, err := DecodeTDLibJSONChannelTransactionPurpose(b) if err != nil { - return fmt.Errorf("unable to decode starTransactionPartnerChannel#44b29c29: field paid_media_message_id: %w", err) - } - s.PaidMediaMessageID = value - case "media": - if err := b.Arr(func(b tdjson.Decoder) error { - value, err := DecodeTDLibJSONPaidMedia(b) - if err != nil { - return fmt.Errorf("unable to decode starTransactionPartnerChannel#44b29c29: field media: %w", err) - } - s.Media = append(s.Media, value) - return nil - }); err != nil { - return fmt.Errorf("unable to decode starTransactionPartnerChannel#44b29c29: field media: %w", err) + return fmt.Errorf("unable to decode starTransactionPartnerChannel#7c04767e: field purpose: %w", err) } + s.Purpose = value default: return b.Skip() } @@ -1218,20 +1377,12 @@ func (s *StarTransactionPartnerChannel) GetChatID() (value int64) { return s.ChatID } -// GetPaidMediaMessageID returns value of PaidMediaMessageID field. -func (s *StarTransactionPartnerChannel) GetPaidMediaMessageID() (value int64) { +// GetPurpose returns value of Purpose field. +func (s *StarTransactionPartnerChannel) GetPurpose() (value ChannelTransactionPurposeClass) { if s == nil { return } - return s.PaidMediaMessageID -} - -// GetMedia returns value of Media field. -func (s *StarTransactionPartnerChannel) GetMedia() (value []PaidMediaClass) { - if s == nil { - return - } - return s.Media + return s.Purpose } // StarTransactionPartnerUser represents TL type `starTransactionPartnerUser#2cf89d66`. @@ -1582,8 +1733,9 @@ const StarTransactionPartnerClassName = "StarTransactionPartner" // case *tdapi.StarTransactionPartnerGooglePlay: // starTransactionPartnerGooglePlay#f229f2a0 // case *tdapi.StarTransactionPartnerFragment: // starTransactionPartnerFragment#da1849b5 // case *tdapi.StarTransactionPartnerTelegramAds: // starTransactionPartnerTelegramAds#91f9c6b -// case *tdapi.StarTransactionPartnerBot: // starTransactionPartnerBot#298ce3d9 -// case *tdapi.StarTransactionPartnerChannel: // starTransactionPartnerChannel#44b29c29 +// case *tdapi.StarTransactionPartnerBot: // starTransactionPartnerBot#4ece3a40 +// case *tdapi.StarTransactionPartnerBusiness: // starTransactionPartnerBusiness#7af9fb52 +// case *tdapi.StarTransactionPartnerChannel: // starTransactionPartnerChannel#7c04767e // case *tdapi.StarTransactionPartnerUser: // starTransactionPartnerUser#2cf89d66 // case *tdapi.StarTransactionPartnerUnsupported: // starTransactionPartnerUnsupported#c4b20d73 // default: panic(v) @@ -1653,14 +1805,21 @@ func DecodeStarTransactionPartner(buf *bin.Buffer) (StarTransactionPartnerClass, } return &v, nil case StarTransactionPartnerBotTypeID: - // Decoding starTransactionPartnerBot#298ce3d9. + // Decoding starTransactionPartnerBot#4ece3a40. v := StarTransactionPartnerBot{} if err := v.Decode(buf); err != nil { return nil, fmt.Errorf("unable to decode StarTransactionPartnerClass: %w", err) } return &v, nil + case StarTransactionPartnerBusinessTypeID: + // Decoding starTransactionPartnerBusiness#7af9fb52. + v := StarTransactionPartnerBusiness{} + if err := v.Decode(buf); err != nil { + return nil, fmt.Errorf("unable to decode StarTransactionPartnerClass: %w", err) + } + return &v, nil case StarTransactionPartnerChannelTypeID: - // Decoding starTransactionPartnerChannel#44b29c29. + // Decoding starTransactionPartnerChannel#7c04767e. v := StarTransactionPartnerChannel{} if err := v.Decode(buf); err != nil { return nil, fmt.Errorf("unable to decode StarTransactionPartnerClass: %w", err) @@ -1728,14 +1887,21 @@ func DecodeTDLibJSONStarTransactionPartner(buf tdjson.Decoder) (StarTransactionP } return &v, nil case "starTransactionPartnerBot": - // Decoding starTransactionPartnerBot#298ce3d9. + // Decoding starTransactionPartnerBot#4ece3a40. v := StarTransactionPartnerBot{} if err := v.DecodeTDLibJSON(buf); err != nil { return nil, fmt.Errorf("unable to decode StarTransactionPartnerClass: %w", err) } return &v, nil + case "starTransactionPartnerBusiness": + // Decoding starTransactionPartnerBusiness#7af9fb52. + v := StarTransactionPartnerBusiness{} + if err := v.DecodeTDLibJSON(buf); err != nil { + return nil, fmt.Errorf("unable to decode StarTransactionPartnerClass: %w", err) + } + return &v, nil case "starTransactionPartnerChannel": - // Decoding starTransactionPartnerChannel#44b29c29. + // Decoding starTransactionPartnerChannel#7c04767e. v := StarTransactionPartnerChannel{} if err := v.DecodeTDLibJSON(buf); err != nil { return nil, fmt.Errorf("unable to decode StarTransactionPartnerClass: %w", err) diff --git a/tdapi/tl_suggested_action_gen.go b/tdapi/tl_suggested_action_gen.go index 9827308b66..121a14738e 100644 --- a/tdapi/tl_suggested_action_gen.go +++ b/tdapi/tl_suggested_action_gen.go @@ -1709,6 +1709,137 @@ func (s *SuggestedActionExtendPremium) GetManagePremiumSubscriptionURL() (value return s.ManagePremiumSubscriptionURL } +// SuggestedActionExtendStarSubscriptions represents TL type `suggestedActionExtendStarSubscriptions#fd32d556`. +type SuggestedActionExtendStarSubscriptions struct { +} + +// SuggestedActionExtendStarSubscriptionsTypeID is TL type id of SuggestedActionExtendStarSubscriptions. +const SuggestedActionExtendStarSubscriptionsTypeID = 0xfd32d556 + +// construct implements constructor of SuggestedActionClass. +func (s SuggestedActionExtendStarSubscriptions) construct() SuggestedActionClass { return &s } + +// Ensuring interfaces in compile-time for SuggestedActionExtendStarSubscriptions. +var ( + _ bin.Encoder = &SuggestedActionExtendStarSubscriptions{} + _ bin.Decoder = &SuggestedActionExtendStarSubscriptions{} + _ bin.BareEncoder = &SuggestedActionExtendStarSubscriptions{} + _ bin.BareDecoder = &SuggestedActionExtendStarSubscriptions{} + + _ SuggestedActionClass = &SuggestedActionExtendStarSubscriptions{} +) + +func (s *SuggestedActionExtendStarSubscriptions) Zero() bool { + if s == nil { + return true + } + + return true +} + +// String implements fmt.Stringer. +func (s *SuggestedActionExtendStarSubscriptions) String() string { + if s == nil { + return "SuggestedActionExtendStarSubscriptions(nil)" + } + type Alias SuggestedActionExtendStarSubscriptions + return fmt.Sprintf("SuggestedActionExtendStarSubscriptions%+v", Alias(*s)) +} + +// TypeID returns type id in TL schema. +// +// See https://core.telegram.org/mtproto/TL-tl#remarks. +func (*SuggestedActionExtendStarSubscriptions) TypeID() uint32 { + return SuggestedActionExtendStarSubscriptionsTypeID +} + +// TypeName returns name of type in TL schema. +func (*SuggestedActionExtendStarSubscriptions) TypeName() string { + return "suggestedActionExtendStarSubscriptions" +} + +// TypeInfo returns info about TL type. +func (s *SuggestedActionExtendStarSubscriptions) TypeInfo() tdp.Type { + typ := tdp.Type{ + Name: "suggestedActionExtendStarSubscriptions", + ID: SuggestedActionExtendStarSubscriptionsTypeID, + } + if s == nil { + typ.Null = true + return typ + } + typ.Fields = []tdp.Field{} + return typ +} + +// Encode implements bin.Encoder. +func (s *SuggestedActionExtendStarSubscriptions) Encode(b *bin.Buffer) error { + if s == nil { + return fmt.Errorf("can't encode suggestedActionExtendStarSubscriptions#fd32d556 as nil") + } + b.PutID(SuggestedActionExtendStarSubscriptionsTypeID) + return s.EncodeBare(b) +} + +// EncodeBare implements bin.BareEncoder. +func (s *SuggestedActionExtendStarSubscriptions) EncodeBare(b *bin.Buffer) error { + if s == nil { + return fmt.Errorf("can't encode suggestedActionExtendStarSubscriptions#fd32d556 as nil") + } + return nil +} + +// Decode implements bin.Decoder. +func (s *SuggestedActionExtendStarSubscriptions) Decode(b *bin.Buffer) error { + if s == nil { + return fmt.Errorf("can't decode suggestedActionExtendStarSubscriptions#fd32d556 to nil") + } + if err := b.ConsumeID(SuggestedActionExtendStarSubscriptionsTypeID); err != nil { + return fmt.Errorf("unable to decode suggestedActionExtendStarSubscriptions#fd32d556: %w", err) + } + return s.DecodeBare(b) +} + +// DecodeBare implements bin.BareDecoder. +func (s *SuggestedActionExtendStarSubscriptions) DecodeBare(b *bin.Buffer) error { + if s == nil { + return fmt.Errorf("can't decode suggestedActionExtendStarSubscriptions#fd32d556 to nil") + } + return nil +} + +// EncodeTDLibJSON implements tdjson.TDLibEncoder. +func (s *SuggestedActionExtendStarSubscriptions) EncodeTDLibJSON(b tdjson.Encoder) error { + if s == nil { + return fmt.Errorf("can't encode suggestedActionExtendStarSubscriptions#fd32d556 as nil") + } + b.ObjStart() + b.PutID("suggestedActionExtendStarSubscriptions") + b.Comma() + b.StripComma() + b.ObjEnd() + return nil +} + +// DecodeTDLibJSON implements tdjson.TDLibDecoder. +func (s *SuggestedActionExtendStarSubscriptions) DecodeTDLibJSON(b tdjson.Decoder) error { + if s == nil { + return fmt.Errorf("can't decode suggestedActionExtendStarSubscriptions#fd32d556 to nil") + } + + return b.Obj(func(b tdjson.Decoder, key []byte) error { + switch string(key) { + case tdjson.TypeField: + if err := b.ConsumeID("suggestedActionExtendStarSubscriptions"); err != nil { + return fmt.Errorf("unable to decode suggestedActionExtendStarSubscriptions#fd32d556: %w", err) + } + default: + return b.Skip() + } + return nil + }) +} + // SuggestedActionClassName is schema name of SuggestedActionClass. const SuggestedActionClassName = "SuggestedAction" @@ -1733,6 +1864,7 @@ const SuggestedActionClassName = "SuggestedAction" // case *tdapi.SuggestedActionGiftPremiumForChristmas: // suggestedActionGiftPremiumForChristmas#93b3ee6f // case *tdapi.SuggestedActionSetBirthdate: // suggestedActionSetBirthdate#eabd9b02 // case *tdapi.SuggestedActionExtendPremium: // suggestedActionExtendPremium#de405cca +// case *tdapi.SuggestedActionExtendStarSubscriptions: // suggestedActionExtendStarSubscriptions#fd32d556 // default: panic(v) // } type SuggestedActionClass interface { @@ -1848,6 +1980,13 @@ func DecodeSuggestedAction(buf *bin.Buffer) (SuggestedActionClass, error) { return nil, fmt.Errorf("unable to decode SuggestedActionClass: %w", err) } return &v, nil + case SuggestedActionExtendStarSubscriptionsTypeID: + // Decoding suggestedActionExtendStarSubscriptions#fd32d556. + v := SuggestedActionExtendStarSubscriptions{} + if err := v.Decode(buf); err != nil { + return nil, fmt.Errorf("unable to decode SuggestedActionClass: %w", err) + } + return &v, nil default: return nil, fmt.Errorf("unable to decode SuggestedActionClass: %w", bin.NewUnexpectedID(id)) } @@ -1944,6 +2083,13 @@ func DecodeTDLibJSONSuggestedAction(buf tdjson.Decoder) (SuggestedActionClass, e return nil, fmt.Errorf("unable to decode SuggestedActionClass: %w", err) } return &v, nil + case "suggestedActionExtendStarSubscriptions": + // Decoding suggestedActionExtendStarSubscriptions#fd32d556. + v := SuggestedActionExtendStarSubscriptions{} + if err := v.DecodeTDLibJSON(buf); err != nil { + return nil, fmt.Errorf("unable to decode SuggestedActionClass: %w", err) + } + return &v, nil default: return nil, fmt.Errorf("unable to decode SuggestedActionClass: %w", tdjson.NewUnexpectedID(id)) } diff --git a/tdapi/tl_supergroup_full_info_gen.go b/tdapi/tl_supergroup_full_info_gen.go index a6c0d22087..85b1c89e88 100644 --- a/tdapi/tl_supergroup_full_info_gen.go +++ b/tdapi/tl_supergroup_full_info_gen.go @@ -31,7 +31,7 @@ var ( _ = tdjson.Encoder{} ) -// SupergroupFullInfo represents TL type `supergroupFullInfo#32925d5a`. +// SupergroupFullInfo represents TL type `supergroupFullInfo#1ea45bb`. type SupergroupFullInfo struct { // Chat photo; may be null if empty or unknown. If non-null, then it is the same photo as // in chat.photo @@ -56,6 +56,8 @@ type SupergroupFullInfo struct { // updateSupergroupFullInfo update is not triggered when value of this field changes, but // both new and old values are non-zero SlowModeDelayExpiresIn float64 + // True, if paid reaction can be enabled in the channel chat; for channels only + CanEnablePaidReaction bool // True, if members of the chat can be retrieved via getSupergroupMembers or // searchChatMembers CanGetMembers bool @@ -116,7 +118,7 @@ type SupergroupFullInfo struct { } // SupergroupFullInfoTypeID is TL type id of SupergroupFullInfo. -const SupergroupFullInfoTypeID = 0x32925d5a +const SupergroupFullInfoTypeID = 0x1ea45bb // Ensuring interfaces in compile-time for SupergroupFullInfo. var ( @@ -157,6 +159,9 @@ func (s *SupergroupFullInfo) Zero() bool { if !(s.SlowModeDelayExpiresIn == 0) { return false } + if !(s.CanEnablePaidReaction == false) { + return false + } if !(s.CanGetMembers == false) { return false } @@ -298,6 +303,10 @@ func (s *SupergroupFullInfo) TypeInfo() tdp.Type { Name: "SlowModeDelayExpiresIn", SchemaName: "slow_mode_delay_expires_in", }, + { + Name: "CanEnablePaidReaction", + SchemaName: "can_enable_paid_reaction", + }, { Name: "CanGetMembers", SchemaName: "can_get_members", @@ -397,7 +406,7 @@ func (s *SupergroupFullInfo) TypeInfo() tdp.Type { // Encode implements bin.Encoder. func (s *SupergroupFullInfo) Encode(b *bin.Buffer) error { if s == nil { - return fmt.Errorf("can't encode supergroupFullInfo#32925d5a as nil") + return fmt.Errorf("can't encode supergroupFullInfo#1ea45bb as nil") } b.PutID(SupergroupFullInfoTypeID) return s.EncodeBare(b) @@ -406,10 +415,10 @@ func (s *SupergroupFullInfo) Encode(b *bin.Buffer) error { // EncodeBare implements bin.BareEncoder. func (s *SupergroupFullInfo) EncodeBare(b *bin.Buffer) error { if s == nil { - return fmt.Errorf("can't encode supergroupFullInfo#32925d5a as nil") + return fmt.Errorf("can't encode supergroupFullInfo#1ea45bb as nil") } if err := s.Photo.Encode(b); err != nil { - return fmt.Errorf("unable to encode supergroupFullInfo#32925d5a: field photo: %w", err) + return fmt.Errorf("unable to encode supergroupFullInfo#1ea45bb: field photo: %w", err) } b.PutString(s.Description) b.PutInt32(s.MemberCount) @@ -419,6 +428,7 @@ func (s *SupergroupFullInfo) EncodeBare(b *bin.Buffer) error { b.PutInt53(s.LinkedChatID) b.PutInt32(s.SlowModeDelay) b.PutDouble(s.SlowModeDelayExpiresIn) + b.PutBool(s.CanEnablePaidReaction) b.PutBool(s.CanGetMembers) b.PutBool(s.HasHiddenMembers) b.PutBool(s.CanHideMembers) @@ -438,15 +448,15 @@ func (s *SupergroupFullInfo) EncodeBare(b *bin.Buffer) error { b.PutLong(s.StickerSetID) b.PutLong(s.CustomEmojiStickerSetID) if err := s.Location.Encode(b); err != nil { - return fmt.Errorf("unable to encode supergroupFullInfo#32925d5a: field location: %w", err) + return fmt.Errorf("unable to encode supergroupFullInfo#1ea45bb: field location: %w", err) } if err := s.InviteLink.Encode(b); err != nil { - return fmt.Errorf("unable to encode supergroupFullInfo#32925d5a: field invite_link: %w", err) + return fmt.Errorf("unable to encode supergroupFullInfo#1ea45bb: field invite_link: %w", err) } b.PutInt(len(s.BotCommands)) for idx, v := range s.BotCommands { if err := v.EncodeBare(b); err != nil { - return fmt.Errorf("unable to encode bare supergroupFullInfo#32925d5a: field bot_commands element with index %d: %w", idx, err) + return fmt.Errorf("unable to encode bare supergroupFullInfo#1ea45bb: field bot_commands element with index %d: %w", idx, err) } } b.PutInt53(s.UpgradedFromBasicGroupID) @@ -457,10 +467,10 @@ func (s *SupergroupFullInfo) EncodeBare(b *bin.Buffer) error { // Decode implements bin.Decoder. func (s *SupergroupFullInfo) Decode(b *bin.Buffer) error { if s == nil { - return fmt.Errorf("can't decode supergroupFullInfo#32925d5a to nil") + return fmt.Errorf("can't decode supergroupFullInfo#1ea45bb to nil") } if err := b.ConsumeID(SupergroupFullInfoTypeID); err != nil { - return fmt.Errorf("unable to decode supergroupFullInfo#32925d5a: %w", err) + return fmt.Errorf("unable to decode supergroupFullInfo#1ea45bb: %w", err) } return s.DecodeBare(b) } @@ -468,209 +478,216 @@ func (s *SupergroupFullInfo) Decode(b *bin.Buffer) error { // DecodeBare implements bin.BareDecoder. func (s *SupergroupFullInfo) DecodeBare(b *bin.Buffer) error { if s == nil { - return fmt.Errorf("can't decode supergroupFullInfo#32925d5a to nil") + return fmt.Errorf("can't decode supergroupFullInfo#1ea45bb to nil") } { if err := s.Photo.Decode(b); err != nil { - return fmt.Errorf("unable to decode supergroupFullInfo#32925d5a: field photo: %w", err) + return fmt.Errorf("unable to decode supergroupFullInfo#1ea45bb: field photo: %w", err) } } { value, err := b.String() if err != nil { - return fmt.Errorf("unable to decode supergroupFullInfo#32925d5a: field description: %w", err) + return fmt.Errorf("unable to decode supergroupFullInfo#1ea45bb: field description: %w", err) } s.Description = value } { value, err := b.Int32() if err != nil { - return fmt.Errorf("unable to decode supergroupFullInfo#32925d5a: field member_count: %w", err) + return fmt.Errorf("unable to decode supergroupFullInfo#1ea45bb: field member_count: %w", err) } s.MemberCount = value } { value, err := b.Int32() if err != nil { - return fmt.Errorf("unable to decode supergroupFullInfo#32925d5a: field administrator_count: %w", err) + return fmt.Errorf("unable to decode supergroupFullInfo#1ea45bb: field administrator_count: %w", err) } s.AdministratorCount = value } { value, err := b.Int32() if err != nil { - return fmt.Errorf("unable to decode supergroupFullInfo#32925d5a: field restricted_count: %w", err) + return fmt.Errorf("unable to decode supergroupFullInfo#1ea45bb: field restricted_count: %w", err) } s.RestrictedCount = value } { value, err := b.Int32() if err != nil { - return fmt.Errorf("unable to decode supergroupFullInfo#32925d5a: field banned_count: %w", err) + return fmt.Errorf("unable to decode supergroupFullInfo#1ea45bb: field banned_count: %w", err) } s.BannedCount = value } { value, err := b.Int53() if err != nil { - return fmt.Errorf("unable to decode supergroupFullInfo#32925d5a: field linked_chat_id: %w", err) + return fmt.Errorf("unable to decode supergroupFullInfo#1ea45bb: field linked_chat_id: %w", err) } s.LinkedChatID = value } { value, err := b.Int32() if err != nil { - return fmt.Errorf("unable to decode supergroupFullInfo#32925d5a: field slow_mode_delay: %w", err) + return fmt.Errorf("unable to decode supergroupFullInfo#1ea45bb: field slow_mode_delay: %w", err) } s.SlowModeDelay = value } { value, err := b.Double() if err != nil { - return fmt.Errorf("unable to decode supergroupFullInfo#32925d5a: field slow_mode_delay_expires_in: %w", err) + return fmt.Errorf("unable to decode supergroupFullInfo#1ea45bb: field slow_mode_delay_expires_in: %w", err) } s.SlowModeDelayExpiresIn = value } { value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode supergroupFullInfo#32925d5a: field can_get_members: %w", err) + return fmt.Errorf("unable to decode supergroupFullInfo#1ea45bb: field can_enable_paid_reaction: %w", err) + } + s.CanEnablePaidReaction = value + } + { + value, err := b.Bool() + if err != nil { + return fmt.Errorf("unable to decode supergroupFullInfo#1ea45bb: field can_get_members: %w", err) } s.CanGetMembers = value } { value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode supergroupFullInfo#32925d5a: field has_hidden_members: %w", err) + return fmt.Errorf("unable to decode supergroupFullInfo#1ea45bb: field has_hidden_members: %w", err) } s.HasHiddenMembers = value } { value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode supergroupFullInfo#32925d5a: field can_hide_members: %w", err) + return fmt.Errorf("unable to decode supergroupFullInfo#1ea45bb: field can_hide_members: %w", err) } s.CanHideMembers = value } { value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode supergroupFullInfo#32925d5a: field can_set_sticker_set: %w", err) + return fmt.Errorf("unable to decode supergroupFullInfo#1ea45bb: field can_set_sticker_set: %w", err) } s.CanSetStickerSet = value } { value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode supergroupFullInfo#32925d5a: field can_set_location: %w", err) + return fmt.Errorf("unable to decode supergroupFullInfo#1ea45bb: field can_set_location: %w", err) } s.CanSetLocation = value } { value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode supergroupFullInfo#32925d5a: field can_get_statistics: %w", err) + return fmt.Errorf("unable to decode supergroupFullInfo#1ea45bb: field can_get_statistics: %w", err) } s.CanGetStatistics = value } { value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode supergroupFullInfo#32925d5a: field can_get_revenue_statistics: %w", err) + return fmt.Errorf("unable to decode supergroupFullInfo#1ea45bb: field can_get_revenue_statistics: %w", err) } s.CanGetRevenueStatistics = value } { value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode supergroupFullInfo#32925d5a: field can_get_star_revenue_statistics: %w", err) + return fmt.Errorf("unable to decode supergroupFullInfo#1ea45bb: field can_get_star_revenue_statistics: %w", err) } s.CanGetStarRevenueStatistics = value } { value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode supergroupFullInfo#32925d5a: field can_toggle_aggressive_anti_spam: %w", err) + return fmt.Errorf("unable to decode supergroupFullInfo#1ea45bb: field can_toggle_aggressive_anti_spam: %w", err) } s.CanToggleAggressiveAntiSpam = value } { value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode supergroupFullInfo#32925d5a: field is_all_history_available: %w", err) + return fmt.Errorf("unable to decode supergroupFullInfo#1ea45bb: field is_all_history_available: %w", err) } s.IsAllHistoryAvailable = value } { value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode supergroupFullInfo#32925d5a: field can_have_sponsored_messages: %w", err) + return fmt.Errorf("unable to decode supergroupFullInfo#1ea45bb: field can_have_sponsored_messages: %w", err) } s.CanHaveSponsoredMessages = value } { value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode supergroupFullInfo#32925d5a: field has_aggressive_anti_spam_enabled: %w", err) + return fmt.Errorf("unable to decode supergroupFullInfo#1ea45bb: field has_aggressive_anti_spam_enabled: %w", err) } s.HasAggressiveAntiSpamEnabled = value } { value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode supergroupFullInfo#32925d5a: field has_paid_media_allowed: %w", err) + return fmt.Errorf("unable to decode supergroupFullInfo#1ea45bb: field has_paid_media_allowed: %w", err) } s.HasPaidMediaAllowed = value } { value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode supergroupFullInfo#32925d5a: field has_pinned_stories: %w", err) + return fmt.Errorf("unable to decode supergroupFullInfo#1ea45bb: field has_pinned_stories: %w", err) } s.HasPinnedStories = value } { value, err := b.Int32() if err != nil { - return fmt.Errorf("unable to decode supergroupFullInfo#32925d5a: field my_boost_count: %w", err) + return fmt.Errorf("unable to decode supergroupFullInfo#1ea45bb: field my_boost_count: %w", err) } s.MyBoostCount = value } { value, err := b.Int32() if err != nil { - return fmt.Errorf("unable to decode supergroupFullInfo#32925d5a: field unrestrict_boost_count: %w", err) + return fmt.Errorf("unable to decode supergroupFullInfo#1ea45bb: field unrestrict_boost_count: %w", err) } s.UnrestrictBoostCount = value } { value, err := b.Long() if err != nil { - return fmt.Errorf("unable to decode supergroupFullInfo#32925d5a: field sticker_set_id: %w", err) + return fmt.Errorf("unable to decode supergroupFullInfo#1ea45bb: field sticker_set_id: %w", err) } s.StickerSetID = value } { value, err := b.Long() if err != nil { - return fmt.Errorf("unable to decode supergroupFullInfo#32925d5a: field custom_emoji_sticker_set_id: %w", err) + return fmt.Errorf("unable to decode supergroupFullInfo#1ea45bb: field custom_emoji_sticker_set_id: %w", err) } s.CustomEmojiStickerSetID = value } { if err := s.Location.Decode(b); err != nil { - return fmt.Errorf("unable to decode supergroupFullInfo#32925d5a: field location: %w", err) + return fmt.Errorf("unable to decode supergroupFullInfo#1ea45bb: field location: %w", err) } } { if err := s.InviteLink.Decode(b); err != nil { - return fmt.Errorf("unable to decode supergroupFullInfo#32925d5a: field invite_link: %w", err) + return fmt.Errorf("unable to decode supergroupFullInfo#1ea45bb: field invite_link: %w", err) } } { headerLen, err := b.Int() if err != nil { - return fmt.Errorf("unable to decode supergroupFullInfo#32925d5a: field bot_commands: %w", err) + return fmt.Errorf("unable to decode supergroupFullInfo#1ea45bb: field bot_commands: %w", err) } if headerLen > 0 { @@ -679,7 +696,7 @@ func (s *SupergroupFullInfo) DecodeBare(b *bin.Buffer) error { for idx := 0; idx < headerLen; idx++ { var value BotCommands if err := value.DecodeBare(b); err != nil { - return fmt.Errorf("unable to decode bare supergroupFullInfo#32925d5a: field bot_commands: %w", err) + return fmt.Errorf("unable to decode bare supergroupFullInfo#1ea45bb: field bot_commands: %w", err) } s.BotCommands = append(s.BotCommands, value) } @@ -687,14 +704,14 @@ func (s *SupergroupFullInfo) DecodeBare(b *bin.Buffer) error { { value, err := b.Int53() if err != nil { - return fmt.Errorf("unable to decode supergroupFullInfo#32925d5a: field upgraded_from_basic_group_id: %w", err) + return fmt.Errorf("unable to decode supergroupFullInfo#1ea45bb: field upgraded_from_basic_group_id: %w", err) } s.UpgradedFromBasicGroupID = value } { value, err := b.Int53() if err != nil { - return fmt.Errorf("unable to decode supergroupFullInfo#32925d5a: field upgraded_from_max_message_id: %w", err) + return fmt.Errorf("unable to decode supergroupFullInfo#1ea45bb: field upgraded_from_max_message_id: %w", err) } s.UpgradedFromMaxMessageID = value } @@ -704,14 +721,14 @@ func (s *SupergroupFullInfo) DecodeBare(b *bin.Buffer) error { // EncodeTDLibJSON implements tdjson.TDLibEncoder. func (s *SupergroupFullInfo) EncodeTDLibJSON(b tdjson.Encoder) error { if s == nil { - return fmt.Errorf("can't encode supergroupFullInfo#32925d5a as nil") + return fmt.Errorf("can't encode supergroupFullInfo#1ea45bb as nil") } b.ObjStart() b.PutID("supergroupFullInfo") b.Comma() b.FieldStart("photo") if err := s.Photo.EncodeTDLibJSON(b); err != nil { - return fmt.Errorf("unable to encode supergroupFullInfo#32925d5a: field photo: %w", err) + return fmt.Errorf("unable to encode supergroupFullInfo#1ea45bb: field photo: %w", err) } b.Comma() b.FieldStart("description") @@ -738,6 +755,9 @@ func (s *SupergroupFullInfo) EncodeTDLibJSON(b tdjson.Encoder) error { b.FieldStart("slow_mode_delay_expires_in") b.PutDouble(s.SlowModeDelayExpiresIn) b.Comma() + b.FieldStart("can_enable_paid_reaction") + b.PutBool(s.CanEnablePaidReaction) + b.Comma() b.FieldStart("can_get_members") b.PutBool(s.CanGetMembers) b.Comma() @@ -794,19 +814,19 @@ func (s *SupergroupFullInfo) EncodeTDLibJSON(b tdjson.Encoder) error { b.Comma() b.FieldStart("location") if err := s.Location.EncodeTDLibJSON(b); err != nil { - return fmt.Errorf("unable to encode supergroupFullInfo#32925d5a: field location: %w", err) + return fmt.Errorf("unable to encode supergroupFullInfo#1ea45bb: field location: %w", err) } b.Comma() b.FieldStart("invite_link") if err := s.InviteLink.EncodeTDLibJSON(b); err != nil { - return fmt.Errorf("unable to encode supergroupFullInfo#32925d5a: field invite_link: %w", err) + return fmt.Errorf("unable to encode supergroupFullInfo#1ea45bb: field invite_link: %w", err) } b.Comma() b.FieldStart("bot_commands") b.ArrStart() for idx, v := range s.BotCommands { if err := v.EncodeTDLibJSON(b); err != nil { - return fmt.Errorf("unable to encode supergroupFullInfo#32925d5a: field bot_commands element with index %d: %w", idx, err) + return fmt.Errorf("unable to encode supergroupFullInfo#1ea45bb: field bot_commands element with index %d: %w", idx, err) } b.Comma() } @@ -827,204 +847,210 @@ func (s *SupergroupFullInfo) EncodeTDLibJSON(b tdjson.Encoder) error { // DecodeTDLibJSON implements tdjson.TDLibDecoder. func (s *SupergroupFullInfo) DecodeTDLibJSON(b tdjson.Decoder) error { if s == nil { - return fmt.Errorf("can't decode supergroupFullInfo#32925d5a to nil") + return fmt.Errorf("can't decode supergroupFullInfo#1ea45bb to nil") } return b.Obj(func(b tdjson.Decoder, key []byte) error { switch string(key) { case tdjson.TypeField: if err := b.ConsumeID("supergroupFullInfo"); err != nil { - return fmt.Errorf("unable to decode supergroupFullInfo#32925d5a: %w", err) + return fmt.Errorf("unable to decode supergroupFullInfo#1ea45bb: %w", err) } case "photo": if err := s.Photo.DecodeTDLibJSON(b); err != nil { - return fmt.Errorf("unable to decode supergroupFullInfo#32925d5a: field photo: %w", err) + return fmt.Errorf("unable to decode supergroupFullInfo#1ea45bb: field photo: %w", err) } case "description": value, err := b.String() if err != nil { - return fmt.Errorf("unable to decode supergroupFullInfo#32925d5a: field description: %w", err) + return fmt.Errorf("unable to decode supergroupFullInfo#1ea45bb: field description: %w", err) } s.Description = value case "member_count": value, err := b.Int32() if err != nil { - return fmt.Errorf("unable to decode supergroupFullInfo#32925d5a: field member_count: %w", err) + return fmt.Errorf("unable to decode supergroupFullInfo#1ea45bb: field member_count: %w", err) } s.MemberCount = value case "administrator_count": value, err := b.Int32() if err != nil { - return fmt.Errorf("unable to decode supergroupFullInfo#32925d5a: field administrator_count: %w", err) + return fmt.Errorf("unable to decode supergroupFullInfo#1ea45bb: field administrator_count: %w", err) } s.AdministratorCount = value case "restricted_count": value, err := b.Int32() if err != nil { - return fmt.Errorf("unable to decode supergroupFullInfo#32925d5a: field restricted_count: %w", err) + return fmt.Errorf("unable to decode supergroupFullInfo#1ea45bb: field restricted_count: %w", err) } s.RestrictedCount = value case "banned_count": value, err := b.Int32() if err != nil { - return fmt.Errorf("unable to decode supergroupFullInfo#32925d5a: field banned_count: %w", err) + return fmt.Errorf("unable to decode supergroupFullInfo#1ea45bb: field banned_count: %w", err) } s.BannedCount = value case "linked_chat_id": value, err := b.Int53() if err != nil { - return fmt.Errorf("unable to decode supergroupFullInfo#32925d5a: field linked_chat_id: %w", err) + return fmt.Errorf("unable to decode supergroupFullInfo#1ea45bb: field linked_chat_id: %w", err) } s.LinkedChatID = value case "slow_mode_delay": value, err := b.Int32() if err != nil { - return fmt.Errorf("unable to decode supergroupFullInfo#32925d5a: field slow_mode_delay: %w", err) + return fmt.Errorf("unable to decode supergroupFullInfo#1ea45bb: field slow_mode_delay: %w", err) } s.SlowModeDelay = value case "slow_mode_delay_expires_in": value, err := b.Double() if err != nil { - return fmt.Errorf("unable to decode supergroupFullInfo#32925d5a: field slow_mode_delay_expires_in: %w", err) + return fmt.Errorf("unable to decode supergroupFullInfo#1ea45bb: field slow_mode_delay_expires_in: %w", err) } s.SlowModeDelayExpiresIn = value + case "can_enable_paid_reaction": + value, err := b.Bool() + if err != nil { + return fmt.Errorf("unable to decode supergroupFullInfo#1ea45bb: field can_enable_paid_reaction: %w", err) + } + s.CanEnablePaidReaction = value case "can_get_members": value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode supergroupFullInfo#32925d5a: field can_get_members: %w", err) + return fmt.Errorf("unable to decode supergroupFullInfo#1ea45bb: field can_get_members: %w", err) } s.CanGetMembers = value case "has_hidden_members": value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode supergroupFullInfo#32925d5a: field has_hidden_members: %w", err) + return fmt.Errorf("unable to decode supergroupFullInfo#1ea45bb: field has_hidden_members: %w", err) } s.HasHiddenMembers = value case "can_hide_members": value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode supergroupFullInfo#32925d5a: field can_hide_members: %w", err) + return fmt.Errorf("unable to decode supergroupFullInfo#1ea45bb: field can_hide_members: %w", err) } s.CanHideMembers = value case "can_set_sticker_set": value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode supergroupFullInfo#32925d5a: field can_set_sticker_set: %w", err) + return fmt.Errorf("unable to decode supergroupFullInfo#1ea45bb: field can_set_sticker_set: %w", err) } s.CanSetStickerSet = value case "can_set_location": value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode supergroupFullInfo#32925d5a: field can_set_location: %w", err) + return fmt.Errorf("unable to decode supergroupFullInfo#1ea45bb: field can_set_location: %w", err) } s.CanSetLocation = value case "can_get_statistics": value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode supergroupFullInfo#32925d5a: field can_get_statistics: %w", err) + return fmt.Errorf("unable to decode supergroupFullInfo#1ea45bb: field can_get_statistics: %w", err) } s.CanGetStatistics = value case "can_get_revenue_statistics": value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode supergroupFullInfo#32925d5a: field can_get_revenue_statistics: %w", err) + return fmt.Errorf("unable to decode supergroupFullInfo#1ea45bb: field can_get_revenue_statistics: %w", err) } s.CanGetRevenueStatistics = value case "can_get_star_revenue_statistics": value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode supergroupFullInfo#32925d5a: field can_get_star_revenue_statistics: %w", err) + return fmt.Errorf("unable to decode supergroupFullInfo#1ea45bb: field can_get_star_revenue_statistics: %w", err) } s.CanGetStarRevenueStatistics = value case "can_toggle_aggressive_anti_spam": value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode supergroupFullInfo#32925d5a: field can_toggle_aggressive_anti_spam: %w", err) + return fmt.Errorf("unable to decode supergroupFullInfo#1ea45bb: field can_toggle_aggressive_anti_spam: %w", err) } s.CanToggleAggressiveAntiSpam = value case "is_all_history_available": value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode supergroupFullInfo#32925d5a: field is_all_history_available: %w", err) + return fmt.Errorf("unable to decode supergroupFullInfo#1ea45bb: field is_all_history_available: %w", err) } s.IsAllHistoryAvailable = value case "can_have_sponsored_messages": value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode supergroupFullInfo#32925d5a: field can_have_sponsored_messages: %w", err) + return fmt.Errorf("unable to decode supergroupFullInfo#1ea45bb: field can_have_sponsored_messages: %w", err) } s.CanHaveSponsoredMessages = value case "has_aggressive_anti_spam_enabled": value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode supergroupFullInfo#32925d5a: field has_aggressive_anti_spam_enabled: %w", err) + return fmt.Errorf("unable to decode supergroupFullInfo#1ea45bb: field has_aggressive_anti_spam_enabled: %w", err) } s.HasAggressiveAntiSpamEnabled = value case "has_paid_media_allowed": value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode supergroupFullInfo#32925d5a: field has_paid_media_allowed: %w", err) + return fmt.Errorf("unable to decode supergroupFullInfo#1ea45bb: field has_paid_media_allowed: %w", err) } s.HasPaidMediaAllowed = value case "has_pinned_stories": value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode supergroupFullInfo#32925d5a: field has_pinned_stories: %w", err) + return fmt.Errorf("unable to decode supergroupFullInfo#1ea45bb: field has_pinned_stories: %w", err) } s.HasPinnedStories = value case "my_boost_count": value, err := b.Int32() if err != nil { - return fmt.Errorf("unable to decode supergroupFullInfo#32925d5a: field my_boost_count: %w", err) + return fmt.Errorf("unable to decode supergroupFullInfo#1ea45bb: field my_boost_count: %w", err) } s.MyBoostCount = value case "unrestrict_boost_count": value, err := b.Int32() if err != nil { - return fmt.Errorf("unable to decode supergroupFullInfo#32925d5a: field unrestrict_boost_count: %w", err) + return fmt.Errorf("unable to decode supergroupFullInfo#1ea45bb: field unrestrict_boost_count: %w", err) } s.UnrestrictBoostCount = value case "sticker_set_id": value, err := b.Long() if err != nil { - return fmt.Errorf("unable to decode supergroupFullInfo#32925d5a: field sticker_set_id: %w", err) + return fmt.Errorf("unable to decode supergroupFullInfo#1ea45bb: field sticker_set_id: %w", err) } s.StickerSetID = value case "custom_emoji_sticker_set_id": value, err := b.Long() if err != nil { - return fmt.Errorf("unable to decode supergroupFullInfo#32925d5a: field custom_emoji_sticker_set_id: %w", err) + return fmt.Errorf("unable to decode supergroupFullInfo#1ea45bb: field custom_emoji_sticker_set_id: %w", err) } s.CustomEmojiStickerSetID = value case "location": if err := s.Location.DecodeTDLibJSON(b); err != nil { - return fmt.Errorf("unable to decode supergroupFullInfo#32925d5a: field location: %w", err) + return fmt.Errorf("unable to decode supergroupFullInfo#1ea45bb: field location: %w", err) } case "invite_link": if err := s.InviteLink.DecodeTDLibJSON(b); err != nil { - return fmt.Errorf("unable to decode supergroupFullInfo#32925d5a: field invite_link: %w", err) + return fmt.Errorf("unable to decode supergroupFullInfo#1ea45bb: field invite_link: %w", err) } case "bot_commands": if err := b.Arr(func(b tdjson.Decoder) error { var value BotCommands if err := value.DecodeTDLibJSON(b); err != nil { - return fmt.Errorf("unable to decode supergroupFullInfo#32925d5a: field bot_commands: %w", err) + return fmt.Errorf("unable to decode supergroupFullInfo#1ea45bb: field bot_commands: %w", err) } s.BotCommands = append(s.BotCommands, value) return nil }); err != nil { - return fmt.Errorf("unable to decode supergroupFullInfo#32925d5a: field bot_commands: %w", err) + return fmt.Errorf("unable to decode supergroupFullInfo#1ea45bb: field bot_commands: %w", err) } case "upgraded_from_basic_group_id": value, err := b.Int53() if err != nil { - return fmt.Errorf("unable to decode supergroupFullInfo#32925d5a: field upgraded_from_basic_group_id: %w", err) + return fmt.Errorf("unable to decode supergroupFullInfo#1ea45bb: field upgraded_from_basic_group_id: %w", err) } s.UpgradedFromBasicGroupID = value case "upgraded_from_max_message_id": value, err := b.Int53() if err != nil { - return fmt.Errorf("unable to decode supergroupFullInfo#32925d5a: field upgraded_from_max_message_id: %w", err) + return fmt.Errorf("unable to decode supergroupFullInfo#1ea45bb: field upgraded_from_max_message_id: %w", err) } s.UpgradedFromMaxMessageID = value default: @@ -1106,6 +1132,14 @@ func (s *SupergroupFullInfo) GetSlowModeDelayExpiresIn() (value float64) { return s.SlowModeDelayExpiresIn } +// GetCanEnablePaidReaction returns value of CanEnablePaidReaction field. +func (s *SupergroupFullInfo) GetCanEnablePaidReaction() (value bool) { + if s == nil { + return + } + return s.CanEnablePaidReaction +} + // GetCanGetMembers returns value of CanGetMembers field. func (s *SupergroupFullInfo) GetCanGetMembers() (value bool) { if s == nil { diff --git a/tdapi/tl_supergroup_gen.go b/tdapi/tl_supergroup_gen.go index 3c623532c4..daae444437 100644 --- a/tdapi/tl_supergroup_gen.go +++ b/tdapi/tl_supergroup_gen.go @@ -31,7 +31,7 @@ var ( _ = tdjson.Encoder{} ) -// Supergroup represents TL type `supergroup#39a14289`. +// Supergroup represents TL type `supergroup#ca7c2ce`. type Supergroup struct { // Supergroup or channel identifier ID int64 @@ -54,9 +54,12 @@ type Supergroup struct { // True, if the supergroup is connected to a location, i.e. the supergroup is a // location-based supergroup HasLocation bool - // True, if messages sent to the channel need to contain information about the sender. - // This field is only applicable to channels + // True, if messages sent to the channel contains name of the sender. This field is only + // applicable to channels SignMessages bool + // True, if messages sent to the channel have information about the sender user. This + // field is only applicable to channels + ShowMessageSender bool // True, if users need to join the supergroup before they can send messages. Always true // for channels and non-discussion supergroups JoinToSendMessages bool @@ -75,6 +78,9 @@ type Supergroup struct { IsForum bool // True, if the supergroup or channel is verified IsVerified bool + // True, if content of media messages in the supergroup or channel chat must be hidden + // with 18+ spoiler + HasSensitiveContent bool // If non-empty, contains a human-readable description of the reason why access to this // supergroup or channel must be restricted RestrictionReason string @@ -91,7 +97,7 @@ type Supergroup struct { } // SupergroupTypeID is TL type id of Supergroup. -const SupergroupTypeID = 0x39a14289 +const SupergroupTypeID = 0xca7c2ce // Ensuring interfaces in compile-time for Supergroup. var ( @@ -132,6 +138,9 @@ func (s *Supergroup) Zero() bool { if !(s.SignMessages == false) { return false } + if !(s.ShowMessageSender == false) { + return false + } if !(s.JoinToSendMessages == false) { return false } @@ -153,6 +162,9 @@ func (s *Supergroup) Zero() bool { if !(s.IsVerified == false) { return false } + if !(s.HasSensitiveContent == false) { + return false + } if !(s.RestrictionReason == "") { return false } @@ -240,6 +252,10 @@ func (s *Supergroup) TypeInfo() tdp.Type { Name: "SignMessages", SchemaName: "sign_messages", }, + { + Name: "ShowMessageSender", + SchemaName: "show_message_sender", + }, { Name: "JoinToSendMessages", SchemaName: "join_to_send_messages", @@ -268,6 +284,10 @@ func (s *Supergroup) TypeInfo() tdp.Type { Name: "IsVerified", SchemaName: "is_verified", }, + { + Name: "HasSensitiveContent", + SchemaName: "has_sensitive_content", + }, { Name: "RestrictionReason", SchemaName: "restriction_reason", @@ -295,7 +315,7 @@ func (s *Supergroup) TypeInfo() tdp.Type { // Encode implements bin.Encoder. func (s *Supergroup) Encode(b *bin.Buffer) error { if s == nil { - return fmt.Errorf("can't encode supergroup#39a14289 as nil") + return fmt.Errorf("can't encode supergroup#ca7c2ce as nil") } b.PutID(SupergroupTypeID) return s.EncodeBare(b) @@ -304,24 +324,25 @@ func (s *Supergroup) Encode(b *bin.Buffer) error { // EncodeBare implements bin.BareEncoder. func (s *Supergroup) EncodeBare(b *bin.Buffer) error { if s == nil { - return fmt.Errorf("can't encode supergroup#39a14289 as nil") + return fmt.Errorf("can't encode supergroup#ca7c2ce as nil") } b.PutInt53(s.ID) if err := s.Usernames.Encode(b); err != nil { - return fmt.Errorf("unable to encode supergroup#39a14289: field usernames: %w", err) + return fmt.Errorf("unable to encode supergroup#ca7c2ce: field usernames: %w", err) } b.PutInt32(s.Date) if s.Status == nil { - return fmt.Errorf("unable to encode supergroup#39a14289: field status is nil") + return fmt.Errorf("unable to encode supergroup#ca7c2ce: field status is nil") } if err := s.Status.Encode(b); err != nil { - return fmt.Errorf("unable to encode supergroup#39a14289: field status: %w", err) + return fmt.Errorf("unable to encode supergroup#ca7c2ce: field status: %w", err) } b.PutInt32(s.MemberCount) b.PutInt32(s.BoostLevel) b.PutBool(s.HasLinkedChat) b.PutBool(s.HasLocation) b.PutBool(s.SignMessages) + b.PutBool(s.ShowMessageSender) b.PutBool(s.JoinToSendMessages) b.PutBool(s.JoinByRequest) b.PutBool(s.IsSlowModeEnabled) @@ -329,6 +350,7 @@ func (s *Supergroup) EncodeBare(b *bin.Buffer) error { b.PutBool(s.IsBroadcastGroup) b.PutBool(s.IsForum) b.PutBool(s.IsVerified) + b.PutBool(s.HasSensitiveContent) b.PutString(s.RestrictionReason) b.PutBool(s.IsScam) b.PutBool(s.IsFake) @@ -340,10 +362,10 @@ func (s *Supergroup) EncodeBare(b *bin.Buffer) error { // Decode implements bin.Decoder. func (s *Supergroup) Decode(b *bin.Buffer) error { if s == nil { - return fmt.Errorf("can't decode supergroup#39a14289 to nil") + return fmt.Errorf("can't decode supergroup#ca7c2ce to nil") } if err := b.ConsumeID(SupergroupTypeID); err != nil { - return fmt.Errorf("unable to decode supergroup#39a14289: %w", err) + return fmt.Errorf("unable to decode supergroup#ca7c2ce: %w", err) } return s.DecodeBare(b) } @@ -351,150 +373,164 @@ func (s *Supergroup) Decode(b *bin.Buffer) error { // DecodeBare implements bin.BareDecoder. func (s *Supergroup) DecodeBare(b *bin.Buffer) error { if s == nil { - return fmt.Errorf("can't decode supergroup#39a14289 to nil") + return fmt.Errorf("can't decode supergroup#ca7c2ce to nil") } { value, err := b.Int53() if err != nil { - return fmt.Errorf("unable to decode supergroup#39a14289: field id: %w", err) + return fmt.Errorf("unable to decode supergroup#ca7c2ce: field id: %w", err) } s.ID = value } { if err := s.Usernames.Decode(b); err != nil { - return fmt.Errorf("unable to decode supergroup#39a14289: field usernames: %w", err) + return fmt.Errorf("unable to decode supergroup#ca7c2ce: field usernames: %w", err) } } { value, err := b.Int32() if err != nil { - return fmt.Errorf("unable to decode supergroup#39a14289: field date: %w", err) + return fmt.Errorf("unable to decode supergroup#ca7c2ce: field date: %w", err) } s.Date = value } { value, err := DecodeChatMemberStatus(b) if err != nil { - return fmt.Errorf("unable to decode supergroup#39a14289: field status: %w", err) + return fmt.Errorf("unable to decode supergroup#ca7c2ce: field status: %w", err) } s.Status = value } { value, err := b.Int32() if err != nil { - return fmt.Errorf("unable to decode supergroup#39a14289: field member_count: %w", err) + return fmt.Errorf("unable to decode supergroup#ca7c2ce: field member_count: %w", err) } s.MemberCount = value } { value, err := b.Int32() if err != nil { - return fmt.Errorf("unable to decode supergroup#39a14289: field boost_level: %w", err) + return fmt.Errorf("unable to decode supergroup#ca7c2ce: field boost_level: %w", err) } s.BoostLevel = value } { value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode supergroup#39a14289: field has_linked_chat: %w", err) + return fmt.Errorf("unable to decode supergroup#ca7c2ce: field has_linked_chat: %w", err) } s.HasLinkedChat = value } { value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode supergroup#39a14289: field has_location: %w", err) + return fmt.Errorf("unable to decode supergroup#ca7c2ce: field has_location: %w", err) } s.HasLocation = value } { value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode supergroup#39a14289: field sign_messages: %w", err) + return fmt.Errorf("unable to decode supergroup#ca7c2ce: field sign_messages: %w", err) } s.SignMessages = value } { value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode supergroup#39a14289: field join_to_send_messages: %w", err) + return fmt.Errorf("unable to decode supergroup#ca7c2ce: field show_message_sender: %w", err) + } + s.ShowMessageSender = value + } + { + value, err := b.Bool() + if err != nil { + return fmt.Errorf("unable to decode supergroup#ca7c2ce: field join_to_send_messages: %w", err) } s.JoinToSendMessages = value } { value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode supergroup#39a14289: field join_by_request: %w", err) + return fmt.Errorf("unable to decode supergroup#ca7c2ce: field join_by_request: %w", err) } s.JoinByRequest = value } { value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode supergroup#39a14289: field is_slow_mode_enabled: %w", err) + return fmt.Errorf("unable to decode supergroup#ca7c2ce: field is_slow_mode_enabled: %w", err) } s.IsSlowModeEnabled = value } { value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode supergroup#39a14289: field is_channel: %w", err) + return fmt.Errorf("unable to decode supergroup#ca7c2ce: field is_channel: %w", err) } s.IsChannel = value } { value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode supergroup#39a14289: field is_broadcast_group: %w", err) + return fmt.Errorf("unable to decode supergroup#ca7c2ce: field is_broadcast_group: %w", err) } s.IsBroadcastGroup = value } { value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode supergroup#39a14289: field is_forum: %w", err) + return fmt.Errorf("unable to decode supergroup#ca7c2ce: field is_forum: %w", err) } s.IsForum = value } { value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode supergroup#39a14289: field is_verified: %w", err) + return fmt.Errorf("unable to decode supergroup#ca7c2ce: field is_verified: %w", err) } s.IsVerified = value } + { + value, err := b.Bool() + if err != nil { + return fmt.Errorf("unable to decode supergroup#ca7c2ce: field has_sensitive_content: %w", err) + } + s.HasSensitiveContent = value + } { value, err := b.String() if err != nil { - return fmt.Errorf("unable to decode supergroup#39a14289: field restriction_reason: %w", err) + return fmt.Errorf("unable to decode supergroup#ca7c2ce: field restriction_reason: %w", err) } s.RestrictionReason = value } { value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode supergroup#39a14289: field is_scam: %w", err) + return fmt.Errorf("unable to decode supergroup#ca7c2ce: field is_scam: %w", err) } s.IsScam = value } { value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode supergroup#39a14289: field is_fake: %w", err) + return fmt.Errorf("unable to decode supergroup#ca7c2ce: field is_fake: %w", err) } s.IsFake = value } { value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode supergroup#39a14289: field has_active_stories: %w", err) + return fmt.Errorf("unable to decode supergroup#ca7c2ce: field has_active_stories: %w", err) } s.HasActiveStories = value } { value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode supergroup#39a14289: field has_unread_active_stories: %w", err) + return fmt.Errorf("unable to decode supergroup#ca7c2ce: field has_unread_active_stories: %w", err) } s.HasUnreadActiveStories = value } @@ -504,7 +540,7 @@ func (s *Supergroup) DecodeBare(b *bin.Buffer) error { // EncodeTDLibJSON implements tdjson.TDLibEncoder. func (s *Supergroup) EncodeTDLibJSON(b tdjson.Encoder) error { if s == nil { - return fmt.Errorf("can't encode supergroup#39a14289 as nil") + return fmt.Errorf("can't encode supergroup#ca7c2ce as nil") } b.ObjStart() b.PutID("supergroup") @@ -514,7 +550,7 @@ func (s *Supergroup) EncodeTDLibJSON(b tdjson.Encoder) error { b.Comma() b.FieldStart("usernames") if err := s.Usernames.EncodeTDLibJSON(b); err != nil { - return fmt.Errorf("unable to encode supergroup#39a14289: field usernames: %w", err) + return fmt.Errorf("unable to encode supergroup#ca7c2ce: field usernames: %w", err) } b.Comma() b.FieldStart("date") @@ -522,10 +558,10 @@ func (s *Supergroup) EncodeTDLibJSON(b tdjson.Encoder) error { b.Comma() b.FieldStart("status") if s.Status == nil { - return fmt.Errorf("unable to encode supergroup#39a14289: field status is nil") + return fmt.Errorf("unable to encode supergroup#ca7c2ce: field status is nil") } if err := s.Status.EncodeTDLibJSON(b); err != nil { - return fmt.Errorf("unable to encode supergroup#39a14289: field status: %w", err) + return fmt.Errorf("unable to encode supergroup#ca7c2ce: field status: %w", err) } b.Comma() b.FieldStart("member_count") @@ -543,6 +579,9 @@ func (s *Supergroup) EncodeTDLibJSON(b tdjson.Encoder) error { b.FieldStart("sign_messages") b.PutBool(s.SignMessages) b.Comma() + b.FieldStart("show_message_sender") + b.PutBool(s.ShowMessageSender) + b.Comma() b.FieldStart("join_to_send_messages") b.PutBool(s.JoinToSendMessages) b.Comma() @@ -564,6 +603,9 @@ func (s *Supergroup) EncodeTDLibJSON(b tdjson.Encoder) error { b.FieldStart("is_verified") b.PutBool(s.IsVerified) b.Comma() + b.FieldStart("has_sensitive_content") + b.PutBool(s.HasSensitiveContent) + b.Comma() b.FieldStart("restriction_reason") b.PutString(s.RestrictionReason) b.Comma() @@ -587,137 +629,149 @@ func (s *Supergroup) EncodeTDLibJSON(b tdjson.Encoder) error { // DecodeTDLibJSON implements tdjson.TDLibDecoder. func (s *Supergroup) DecodeTDLibJSON(b tdjson.Decoder) error { if s == nil { - return fmt.Errorf("can't decode supergroup#39a14289 to nil") + return fmt.Errorf("can't decode supergroup#ca7c2ce to nil") } return b.Obj(func(b tdjson.Decoder, key []byte) error { switch string(key) { case tdjson.TypeField: if err := b.ConsumeID("supergroup"); err != nil { - return fmt.Errorf("unable to decode supergroup#39a14289: %w", err) + return fmt.Errorf("unable to decode supergroup#ca7c2ce: %w", err) } case "id": value, err := b.Int53() if err != nil { - return fmt.Errorf("unable to decode supergroup#39a14289: field id: %w", err) + return fmt.Errorf("unable to decode supergroup#ca7c2ce: field id: %w", err) } s.ID = value case "usernames": if err := s.Usernames.DecodeTDLibJSON(b); err != nil { - return fmt.Errorf("unable to decode supergroup#39a14289: field usernames: %w", err) + return fmt.Errorf("unable to decode supergroup#ca7c2ce: field usernames: %w", err) } case "date": value, err := b.Int32() if err != nil { - return fmt.Errorf("unable to decode supergroup#39a14289: field date: %w", err) + return fmt.Errorf("unable to decode supergroup#ca7c2ce: field date: %w", err) } s.Date = value case "status": value, err := DecodeTDLibJSONChatMemberStatus(b) if err != nil { - return fmt.Errorf("unable to decode supergroup#39a14289: field status: %w", err) + return fmt.Errorf("unable to decode supergroup#ca7c2ce: field status: %w", err) } s.Status = value case "member_count": value, err := b.Int32() if err != nil { - return fmt.Errorf("unable to decode supergroup#39a14289: field member_count: %w", err) + return fmt.Errorf("unable to decode supergroup#ca7c2ce: field member_count: %w", err) } s.MemberCount = value case "boost_level": value, err := b.Int32() if err != nil { - return fmt.Errorf("unable to decode supergroup#39a14289: field boost_level: %w", err) + return fmt.Errorf("unable to decode supergroup#ca7c2ce: field boost_level: %w", err) } s.BoostLevel = value case "has_linked_chat": value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode supergroup#39a14289: field has_linked_chat: %w", err) + return fmt.Errorf("unable to decode supergroup#ca7c2ce: field has_linked_chat: %w", err) } s.HasLinkedChat = value case "has_location": value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode supergroup#39a14289: field has_location: %w", err) + return fmt.Errorf("unable to decode supergroup#ca7c2ce: field has_location: %w", err) } s.HasLocation = value case "sign_messages": value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode supergroup#39a14289: field sign_messages: %w", err) + return fmt.Errorf("unable to decode supergroup#ca7c2ce: field sign_messages: %w", err) } s.SignMessages = value + case "show_message_sender": + value, err := b.Bool() + if err != nil { + return fmt.Errorf("unable to decode supergroup#ca7c2ce: field show_message_sender: %w", err) + } + s.ShowMessageSender = value case "join_to_send_messages": value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode supergroup#39a14289: field join_to_send_messages: %w", err) + return fmt.Errorf("unable to decode supergroup#ca7c2ce: field join_to_send_messages: %w", err) } s.JoinToSendMessages = value case "join_by_request": value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode supergroup#39a14289: field join_by_request: %w", err) + return fmt.Errorf("unable to decode supergroup#ca7c2ce: field join_by_request: %w", err) } s.JoinByRequest = value case "is_slow_mode_enabled": value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode supergroup#39a14289: field is_slow_mode_enabled: %w", err) + return fmt.Errorf("unable to decode supergroup#ca7c2ce: field is_slow_mode_enabled: %w", err) } s.IsSlowModeEnabled = value case "is_channel": value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode supergroup#39a14289: field is_channel: %w", err) + return fmt.Errorf("unable to decode supergroup#ca7c2ce: field is_channel: %w", err) } s.IsChannel = value case "is_broadcast_group": value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode supergroup#39a14289: field is_broadcast_group: %w", err) + return fmt.Errorf("unable to decode supergroup#ca7c2ce: field is_broadcast_group: %w", err) } s.IsBroadcastGroup = value case "is_forum": value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode supergroup#39a14289: field is_forum: %w", err) + return fmt.Errorf("unable to decode supergroup#ca7c2ce: field is_forum: %w", err) } s.IsForum = value case "is_verified": value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode supergroup#39a14289: field is_verified: %w", err) + return fmt.Errorf("unable to decode supergroup#ca7c2ce: field is_verified: %w", err) } s.IsVerified = value + case "has_sensitive_content": + value, err := b.Bool() + if err != nil { + return fmt.Errorf("unable to decode supergroup#ca7c2ce: field has_sensitive_content: %w", err) + } + s.HasSensitiveContent = value case "restriction_reason": value, err := b.String() if err != nil { - return fmt.Errorf("unable to decode supergroup#39a14289: field restriction_reason: %w", err) + return fmt.Errorf("unable to decode supergroup#ca7c2ce: field restriction_reason: %w", err) } s.RestrictionReason = value case "is_scam": value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode supergroup#39a14289: field is_scam: %w", err) + return fmt.Errorf("unable to decode supergroup#ca7c2ce: field is_scam: %w", err) } s.IsScam = value case "is_fake": value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode supergroup#39a14289: field is_fake: %w", err) + return fmt.Errorf("unable to decode supergroup#ca7c2ce: field is_fake: %w", err) } s.IsFake = value case "has_active_stories": value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode supergroup#39a14289: field has_active_stories: %w", err) + return fmt.Errorf("unable to decode supergroup#ca7c2ce: field has_active_stories: %w", err) } s.HasActiveStories = value case "has_unread_active_stories": value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode supergroup#39a14289: field has_unread_active_stories: %w", err) + return fmt.Errorf("unable to decode supergroup#ca7c2ce: field has_unread_active_stories: %w", err) } s.HasUnreadActiveStories = value default: @@ -799,6 +853,14 @@ func (s *Supergroup) GetSignMessages() (value bool) { return s.SignMessages } +// GetShowMessageSender returns value of ShowMessageSender field. +func (s *Supergroup) GetShowMessageSender() (value bool) { + if s == nil { + return + } + return s.ShowMessageSender +} + // GetJoinToSendMessages returns value of JoinToSendMessages field. func (s *Supergroup) GetJoinToSendMessages() (value bool) { if s == nil { @@ -855,6 +917,14 @@ func (s *Supergroup) GetIsVerified() (value bool) { return s.IsVerified } +// GetHasSensitiveContent returns value of HasSensitiveContent field. +func (s *Supergroup) GetHasSensitiveContent() (value bool) { + if s == nil { + return + } + return s.HasSensitiveContent +} + // GetRestrictionReason returns value of RestrictionReason field. func (s *Supergroup) GetRestrictionReason() (value string) { if s == nil { diff --git a/tdapi/tl_telegram_payment_purpose_gen.go b/tdapi/tl_telegram_payment_purpose_gen.go index 5ac4799145..23c5dc9cd9 100644 --- a/tdapi/tl_telegram_payment_purpose_gen.go +++ b/tdapi/tl_telegram_payment_purpose_gen.go @@ -1163,6 +1163,172 @@ func (t *TelegramPaymentPurposeGiftedStars) GetStarCount() (value int64) { return t.StarCount } +// TelegramPaymentPurposeJoinChat represents TL type `telegramPaymentPurposeJoinChat#8ddd6788`. +type TelegramPaymentPurposeJoinChat struct { + // Invite link to use + InviteLink string +} + +// TelegramPaymentPurposeJoinChatTypeID is TL type id of TelegramPaymentPurposeJoinChat. +const TelegramPaymentPurposeJoinChatTypeID = 0x8ddd6788 + +// construct implements constructor of TelegramPaymentPurposeClass. +func (t TelegramPaymentPurposeJoinChat) construct() TelegramPaymentPurposeClass { return &t } + +// Ensuring interfaces in compile-time for TelegramPaymentPurposeJoinChat. +var ( + _ bin.Encoder = &TelegramPaymentPurposeJoinChat{} + _ bin.Decoder = &TelegramPaymentPurposeJoinChat{} + _ bin.BareEncoder = &TelegramPaymentPurposeJoinChat{} + _ bin.BareDecoder = &TelegramPaymentPurposeJoinChat{} + + _ TelegramPaymentPurposeClass = &TelegramPaymentPurposeJoinChat{} +) + +func (t *TelegramPaymentPurposeJoinChat) Zero() bool { + if t == nil { + return true + } + if !(t.InviteLink == "") { + return false + } + + return true +} + +// String implements fmt.Stringer. +func (t *TelegramPaymentPurposeJoinChat) String() string { + if t == nil { + return "TelegramPaymentPurposeJoinChat(nil)" + } + type Alias TelegramPaymentPurposeJoinChat + return fmt.Sprintf("TelegramPaymentPurposeJoinChat%+v", Alias(*t)) +} + +// TypeID returns type id in TL schema. +// +// See https://core.telegram.org/mtproto/TL-tl#remarks. +func (*TelegramPaymentPurposeJoinChat) TypeID() uint32 { + return TelegramPaymentPurposeJoinChatTypeID +} + +// TypeName returns name of type in TL schema. +func (*TelegramPaymentPurposeJoinChat) TypeName() string { + return "telegramPaymentPurposeJoinChat" +} + +// TypeInfo returns info about TL type. +func (t *TelegramPaymentPurposeJoinChat) TypeInfo() tdp.Type { + typ := tdp.Type{ + Name: "telegramPaymentPurposeJoinChat", + ID: TelegramPaymentPurposeJoinChatTypeID, + } + if t == nil { + typ.Null = true + return typ + } + typ.Fields = []tdp.Field{ + { + Name: "InviteLink", + SchemaName: "invite_link", + }, + } + return typ +} + +// Encode implements bin.Encoder. +func (t *TelegramPaymentPurposeJoinChat) Encode(b *bin.Buffer) error { + if t == nil { + return fmt.Errorf("can't encode telegramPaymentPurposeJoinChat#8ddd6788 as nil") + } + b.PutID(TelegramPaymentPurposeJoinChatTypeID) + return t.EncodeBare(b) +} + +// EncodeBare implements bin.BareEncoder. +func (t *TelegramPaymentPurposeJoinChat) EncodeBare(b *bin.Buffer) error { + if t == nil { + return fmt.Errorf("can't encode telegramPaymentPurposeJoinChat#8ddd6788 as nil") + } + b.PutString(t.InviteLink) + return nil +} + +// Decode implements bin.Decoder. +func (t *TelegramPaymentPurposeJoinChat) Decode(b *bin.Buffer) error { + if t == nil { + return fmt.Errorf("can't decode telegramPaymentPurposeJoinChat#8ddd6788 to nil") + } + if err := b.ConsumeID(TelegramPaymentPurposeJoinChatTypeID); err != nil { + return fmt.Errorf("unable to decode telegramPaymentPurposeJoinChat#8ddd6788: %w", err) + } + return t.DecodeBare(b) +} + +// DecodeBare implements bin.BareDecoder. +func (t *TelegramPaymentPurposeJoinChat) DecodeBare(b *bin.Buffer) error { + if t == nil { + return fmt.Errorf("can't decode telegramPaymentPurposeJoinChat#8ddd6788 to nil") + } + { + value, err := b.String() + if err != nil { + return fmt.Errorf("unable to decode telegramPaymentPurposeJoinChat#8ddd6788: field invite_link: %w", err) + } + t.InviteLink = value + } + return nil +} + +// EncodeTDLibJSON implements tdjson.TDLibEncoder. +func (t *TelegramPaymentPurposeJoinChat) EncodeTDLibJSON(b tdjson.Encoder) error { + if t == nil { + return fmt.Errorf("can't encode telegramPaymentPurposeJoinChat#8ddd6788 as nil") + } + b.ObjStart() + b.PutID("telegramPaymentPurposeJoinChat") + b.Comma() + b.FieldStart("invite_link") + b.PutString(t.InviteLink) + b.Comma() + b.StripComma() + b.ObjEnd() + return nil +} + +// DecodeTDLibJSON implements tdjson.TDLibDecoder. +func (t *TelegramPaymentPurposeJoinChat) DecodeTDLibJSON(b tdjson.Decoder) error { + if t == nil { + return fmt.Errorf("can't decode telegramPaymentPurposeJoinChat#8ddd6788 to nil") + } + + return b.Obj(func(b tdjson.Decoder, key []byte) error { + switch string(key) { + case tdjson.TypeField: + if err := b.ConsumeID("telegramPaymentPurposeJoinChat"); err != nil { + return fmt.Errorf("unable to decode telegramPaymentPurposeJoinChat#8ddd6788: %w", err) + } + case "invite_link": + value, err := b.String() + if err != nil { + return fmt.Errorf("unable to decode telegramPaymentPurposeJoinChat#8ddd6788: field invite_link: %w", err) + } + t.InviteLink = value + default: + return b.Skip() + } + return nil + }) +} + +// GetInviteLink returns value of InviteLink field. +func (t *TelegramPaymentPurposeJoinChat) GetInviteLink() (value string) { + if t == nil { + return + } + return t.InviteLink +} + // TelegramPaymentPurposeClassName is schema name of TelegramPaymentPurposeClass. const TelegramPaymentPurposeClassName = "TelegramPaymentPurpose" @@ -1179,6 +1345,7 @@ const TelegramPaymentPurposeClassName = "TelegramPaymentPurpose" // case *tdapi.TelegramPaymentPurposePremiumGiveaway: // telegramPaymentPurposePremiumGiveaway#bfd4a227 // case *tdapi.TelegramPaymentPurposeStars: // telegramPaymentPurposeStars#e273ee52 // case *tdapi.TelegramPaymentPurposeGiftedStars: // telegramPaymentPurposeGiftedStars#91b68a36 +// case *tdapi.TelegramPaymentPurposeJoinChat: // telegramPaymentPurposeJoinChat#8ddd6788 // default: panic(v) // } type TelegramPaymentPurposeClass interface { @@ -1201,11 +1368,6 @@ type TelegramPaymentPurposeClass interface { EncodeTDLibJSON(b tdjson.Encoder) error DecodeTDLibJSON(b tdjson.Decoder) error - - // ISO 4217 currency code of the payment currency - GetCurrency() (value string) - // Paid amount, in the smallest units of the currency - GetAmount() (value int64) } // DecodeTelegramPaymentPurpose implements binary de-serialization for TelegramPaymentPurposeClass. @@ -1243,6 +1405,13 @@ func DecodeTelegramPaymentPurpose(buf *bin.Buffer) (TelegramPaymentPurposeClass, return nil, fmt.Errorf("unable to decode TelegramPaymentPurposeClass: %w", err) } return &v, nil + case TelegramPaymentPurposeJoinChatTypeID: + // Decoding telegramPaymentPurposeJoinChat#8ddd6788. + v := TelegramPaymentPurposeJoinChat{} + if err := v.Decode(buf); err != nil { + return nil, fmt.Errorf("unable to decode TelegramPaymentPurposeClass: %w", err) + } + return &v, nil default: return nil, fmt.Errorf("unable to decode TelegramPaymentPurposeClass: %w", bin.NewUnexpectedID(id)) } @@ -1283,6 +1452,13 @@ func DecodeTDLibJSONTelegramPaymentPurpose(buf tdjson.Decoder) (TelegramPaymentP return nil, fmt.Errorf("unable to decode TelegramPaymentPurposeClass: %w", err) } return &v, nil + case "telegramPaymentPurposeJoinChat": + // Decoding telegramPaymentPurposeJoinChat#8ddd6788. + v := TelegramPaymentPurposeJoinChat{} + if err := v.DecodeTDLibJSON(buf); err != nil { + return nil, fmt.Errorf("unable to decode TelegramPaymentPurposeClass: %w", err) + } + return &v, nil default: return nil, fmt.Errorf("unable to decode TelegramPaymentPurposeClass: %w", tdjson.NewUnexpectedID(id)) } diff --git a/tdapi/tl_toggle_paid_message_reaction_is_anonymous_gen.go b/tdapi/tl_toggle_paid_message_reaction_is_anonymous_gen.go new file mode 100644 index 0000000000..a67950ba36 --- /dev/null +++ b/tdapi/tl_toggle_paid_message_reaction_is_anonymous_gen.go @@ -0,0 +1,272 @@ +// Code generated by gotdgen, DO NOT EDIT. + +package tdapi + +import ( + "context" + "errors" + "fmt" + "sort" + "strings" + + "go.uber.org/multierr" + + "github.com/gotd/td/bin" + "github.com/gotd/td/tdjson" + "github.com/gotd/td/tdp" + "github.com/gotd/td/tgerr" +) + +// No-op definition for keeping imports. +var ( + _ = bin.Buffer{} + _ = context.Background() + _ = fmt.Stringer(nil) + _ = strings.Builder{} + _ = errors.Is + _ = multierr.AppendInto + _ = sort.Ints + _ = tdp.Format + _ = tgerr.Error{} + _ = tdjson.Encoder{} +) + +// TogglePaidMessageReactionIsAnonymousRequest represents TL type `togglePaidMessageReactionIsAnonymous#9774db11`. +type TogglePaidMessageReactionIsAnonymousRequest struct { + // Identifier of the chat to which the message belongs + ChatID int64 + // Identifier of the message + MessageID int64 + // Pass true to make paid reaction of the user on the message anonymous; pass false to + // make the user's profile visible among top reactors + IsAnonymous bool +} + +// TogglePaidMessageReactionIsAnonymousRequestTypeID is TL type id of TogglePaidMessageReactionIsAnonymousRequest. +const TogglePaidMessageReactionIsAnonymousRequestTypeID = 0x9774db11 + +// Ensuring interfaces in compile-time for TogglePaidMessageReactionIsAnonymousRequest. +var ( + _ bin.Encoder = &TogglePaidMessageReactionIsAnonymousRequest{} + _ bin.Decoder = &TogglePaidMessageReactionIsAnonymousRequest{} + _ bin.BareEncoder = &TogglePaidMessageReactionIsAnonymousRequest{} + _ bin.BareDecoder = &TogglePaidMessageReactionIsAnonymousRequest{} +) + +func (t *TogglePaidMessageReactionIsAnonymousRequest) Zero() bool { + if t == nil { + return true + } + if !(t.ChatID == 0) { + return false + } + if !(t.MessageID == 0) { + return false + } + if !(t.IsAnonymous == false) { + return false + } + + return true +} + +// String implements fmt.Stringer. +func (t *TogglePaidMessageReactionIsAnonymousRequest) String() string { + if t == nil { + return "TogglePaidMessageReactionIsAnonymousRequest(nil)" + } + type Alias TogglePaidMessageReactionIsAnonymousRequest + return fmt.Sprintf("TogglePaidMessageReactionIsAnonymousRequest%+v", Alias(*t)) +} + +// TypeID returns type id in TL schema. +// +// See https://core.telegram.org/mtproto/TL-tl#remarks. +func (*TogglePaidMessageReactionIsAnonymousRequest) TypeID() uint32 { + return TogglePaidMessageReactionIsAnonymousRequestTypeID +} + +// TypeName returns name of type in TL schema. +func (*TogglePaidMessageReactionIsAnonymousRequest) TypeName() string { + return "togglePaidMessageReactionIsAnonymous" +} + +// TypeInfo returns info about TL type. +func (t *TogglePaidMessageReactionIsAnonymousRequest) TypeInfo() tdp.Type { + typ := tdp.Type{ + Name: "togglePaidMessageReactionIsAnonymous", + ID: TogglePaidMessageReactionIsAnonymousRequestTypeID, + } + if t == nil { + typ.Null = true + return typ + } + typ.Fields = []tdp.Field{ + { + Name: "ChatID", + SchemaName: "chat_id", + }, + { + Name: "MessageID", + SchemaName: "message_id", + }, + { + Name: "IsAnonymous", + SchemaName: "is_anonymous", + }, + } + return typ +} + +// Encode implements bin.Encoder. +func (t *TogglePaidMessageReactionIsAnonymousRequest) Encode(b *bin.Buffer) error { + if t == nil { + return fmt.Errorf("can't encode togglePaidMessageReactionIsAnonymous#9774db11 as nil") + } + b.PutID(TogglePaidMessageReactionIsAnonymousRequestTypeID) + return t.EncodeBare(b) +} + +// EncodeBare implements bin.BareEncoder. +func (t *TogglePaidMessageReactionIsAnonymousRequest) EncodeBare(b *bin.Buffer) error { + if t == nil { + return fmt.Errorf("can't encode togglePaidMessageReactionIsAnonymous#9774db11 as nil") + } + b.PutInt53(t.ChatID) + b.PutInt53(t.MessageID) + b.PutBool(t.IsAnonymous) + return nil +} + +// Decode implements bin.Decoder. +func (t *TogglePaidMessageReactionIsAnonymousRequest) Decode(b *bin.Buffer) error { + if t == nil { + return fmt.Errorf("can't decode togglePaidMessageReactionIsAnonymous#9774db11 to nil") + } + if err := b.ConsumeID(TogglePaidMessageReactionIsAnonymousRequestTypeID); err != nil { + return fmt.Errorf("unable to decode togglePaidMessageReactionIsAnonymous#9774db11: %w", err) + } + return t.DecodeBare(b) +} + +// DecodeBare implements bin.BareDecoder. +func (t *TogglePaidMessageReactionIsAnonymousRequest) DecodeBare(b *bin.Buffer) error { + if t == nil { + return fmt.Errorf("can't decode togglePaidMessageReactionIsAnonymous#9774db11 to nil") + } + { + value, err := b.Int53() + if err != nil { + return fmt.Errorf("unable to decode togglePaidMessageReactionIsAnonymous#9774db11: field chat_id: %w", err) + } + t.ChatID = value + } + { + value, err := b.Int53() + if err != nil { + return fmt.Errorf("unable to decode togglePaidMessageReactionIsAnonymous#9774db11: field message_id: %w", err) + } + t.MessageID = value + } + { + value, err := b.Bool() + if err != nil { + return fmt.Errorf("unable to decode togglePaidMessageReactionIsAnonymous#9774db11: field is_anonymous: %w", err) + } + t.IsAnonymous = value + } + return nil +} + +// EncodeTDLibJSON implements tdjson.TDLibEncoder. +func (t *TogglePaidMessageReactionIsAnonymousRequest) EncodeTDLibJSON(b tdjson.Encoder) error { + if t == nil { + return fmt.Errorf("can't encode togglePaidMessageReactionIsAnonymous#9774db11 as nil") + } + b.ObjStart() + b.PutID("togglePaidMessageReactionIsAnonymous") + b.Comma() + b.FieldStart("chat_id") + b.PutInt53(t.ChatID) + b.Comma() + b.FieldStart("message_id") + b.PutInt53(t.MessageID) + b.Comma() + b.FieldStart("is_anonymous") + b.PutBool(t.IsAnonymous) + b.Comma() + b.StripComma() + b.ObjEnd() + return nil +} + +// DecodeTDLibJSON implements tdjson.TDLibDecoder. +func (t *TogglePaidMessageReactionIsAnonymousRequest) DecodeTDLibJSON(b tdjson.Decoder) error { + if t == nil { + return fmt.Errorf("can't decode togglePaidMessageReactionIsAnonymous#9774db11 to nil") + } + + return b.Obj(func(b tdjson.Decoder, key []byte) error { + switch string(key) { + case tdjson.TypeField: + if err := b.ConsumeID("togglePaidMessageReactionIsAnonymous"); err != nil { + return fmt.Errorf("unable to decode togglePaidMessageReactionIsAnonymous#9774db11: %w", err) + } + case "chat_id": + value, err := b.Int53() + if err != nil { + return fmt.Errorf("unable to decode togglePaidMessageReactionIsAnonymous#9774db11: field chat_id: %w", err) + } + t.ChatID = value + case "message_id": + value, err := b.Int53() + if err != nil { + return fmt.Errorf("unable to decode togglePaidMessageReactionIsAnonymous#9774db11: field message_id: %w", err) + } + t.MessageID = value + case "is_anonymous": + value, err := b.Bool() + if err != nil { + return fmt.Errorf("unable to decode togglePaidMessageReactionIsAnonymous#9774db11: field is_anonymous: %w", err) + } + t.IsAnonymous = value + default: + return b.Skip() + } + return nil + }) +} + +// GetChatID returns value of ChatID field. +func (t *TogglePaidMessageReactionIsAnonymousRequest) GetChatID() (value int64) { + if t == nil { + return + } + return t.ChatID +} + +// GetMessageID returns value of MessageID field. +func (t *TogglePaidMessageReactionIsAnonymousRequest) GetMessageID() (value int64) { + if t == nil { + return + } + return t.MessageID +} + +// GetIsAnonymous returns value of IsAnonymous field. +func (t *TogglePaidMessageReactionIsAnonymousRequest) GetIsAnonymous() (value bool) { + if t == nil { + return + } + return t.IsAnonymous +} + +// TogglePaidMessageReactionIsAnonymous invokes method togglePaidMessageReactionIsAnonymous#9774db11 returning error if any. +func (c *Client) TogglePaidMessageReactionIsAnonymous(ctx context.Context, request *TogglePaidMessageReactionIsAnonymousRequest) error { + var ok Ok + + if err := c.rpc.Invoke(ctx, request, &ok); err != nil { + return err + } + return nil +} diff --git a/tdapi/tl_toggle_supergroup_sign_messages_gen.go b/tdapi/tl_toggle_supergroup_sign_messages_gen.go index 36231bbff2..7da231f506 100644 --- a/tdapi/tl_toggle_supergroup_sign_messages_gen.go +++ b/tdapi/tl_toggle_supergroup_sign_messages_gen.go @@ -31,16 +31,18 @@ var ( _ = tdjson.Encoder{} ) -// ToggleSupergroupSignMessagesRequest represents TL type `toggleSupergroupSignMessages#44efd524`. +// ToggleSupergroupSignMessagesRequest represents TL type `toggleSupergroupSignMessages#221c1fcb`. type ToggleSupergroupSignMessagesRequest struct { // Identifier of the channel SupergroupID int64 // New value of sign_messages SignMessages bool + // New value of show_message_sender + ShowMessageSender bool } // ToggleSupergroupSignMessagesRequestTypeID is TL type id of ToggleSupergroupSignMessagesRequest. -const ToggleSupergroupSignMessagesRequestTypeID = 0x44efd524 +const ToggleSupergroupSignMessagesRequestTypeID = 0x221c1fcb // Ensuring interfaces in compile-time for ToggleSupergroupSignMessagesRequest. var ( @@ -60,6 +62,9 @@ func (t *ToggleSupergroupSignMessagesRequest) Zero() bool { if !(t.SignMessages == false) { return false } + if !(t.ShowMessageSender == false) { + return false + } return true } @@ -104,6 +109,10 @@ func (t *ToggleSupergroupSignMessagesRequest) TypeInfo() tdp.Type { Name: "SignMessages", SchemaName: "sign_messages", }, + { + Name: "ShowMessageSender", + SchemaName: "show_message_sender", + }, } return typ } @@ -111,7 +120,7 @@ func (t *ToggleSupergroupSignMessagesRequest) TypeInfo() tdp.Type { // Encode implements bin.Encoder. func (t *ToggleSupergroupSignMessagesRequest) Encode(b *bin.Buffer) error { if t == nil { - return fmt.Errorf("can't encode toggleSupergroupSignMessages#44efd524 as nil") + return fmt.Errorf("can't encode toggleSupergroupSignMessages#221c1fcb as nil") } b.PutID(ToggleSupergroupSignMessagesRequestTypeID) return t.EncodeBare(b) @@ -120,20 +129,21 @@ func (t *ToggleSupergroupSignMessagesRequest) Encode(b *bin.Buffer) error { // EncodeBare implements bin.BareEncoder. func (t *ToggleSupergroupSignMessagesRequest) EncodeBare(b *bin.Buffer) error { if t == nil { - return fmt.Errorf("can't encode toggleSupergroupSignMessages#44efd524 as nil") + return fmt.Errorf("can't encode toggleSupergroupSignMessages#221c1fcb as nil") } b.PutInt53(t.SupergroupID) b.PutBool(t.SignMessages) + b.PutBool(t.ShowMessageSender) return nil } // Decode implements bin.Decoder. func (t *ToggleSupergroupSignMessagesRequest) Decode(b *bin.Buffer) error { if t == nil { - return fmt.Errorf("can't decode toggleSupergroupSignMessages#44efd524 to nil") + return fmt.Errorf("can't decode toggleSupergroupSignMessages#221c1fcb to nil") } if err := b.ConsumeID(ToggleSupergroupSignMessagesRequestTypeID); err != nil { - return fmt.Errorf("unable to decode toggleSupergroupSignMessages#44efd524: %w", err) + return fmt.Errorf("unable to decode toggleSupergroupSignMessages#221c1fcb: %w", err) } return t.DecodeBare(b) } @@ -141,29 +151,36 @@ func (t *ToggleSupergroupSignMessagesRequest) Decode(b *bin.Buffer) error { // DecodeBare implements bin.BareDecoder. func (t *ToggleSupergroupSignMessagesRequest) DecodeBare(b *bin.Buffer) error { if t == nil { - return fmt.Errorf("can't decode toggleSupergroupSignMessages#44efd524 to nil") + return fmt.Errorf("can't decode toggleSupergroupSignMessages#221c1fcb to nil") } { value, err := b.Int53() if err != nil { - return fmt.Errorf("unable to decode toggleSupergroupSignMessages#44efd524: field supergroup_id: %w", err) + return fmt.Errorf("unable to decode toggleSupergroupSignMessages#221c1fcb: field supergroup_id: %w", err) } t.SupergroupID = value } { value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode toggleSupergroupSignMessages#44efd524: field sign_messages: %w", err) + return fmt.Errorf("unable to decode toggleSupergroupSignMessages#221c1fcb: field sign_messages: %w", err) } t.SignMessages = value } + { + value, err := b.Bool() + if err != nil { + return fmt.Errorf("unable to decode toggleSupergroupSignMessages#221c1fcb: field show_message_sender: %w", err) + } + t.ShowMessageSender = value + } return nil } // EncodeTDLibJSON implements tdjson.TDLibEncoder. func (t *ToggleSupergroupSignMessagesRequest) EncodeTDLibJSON(b tdjson.Encoder) error { if t == nil { - return fmt.Errorf("can't encode toggleSupergroupSignMessages#44efd524 as nil") + return fmt.Errorf("can't encode toggleSupergroupSignMessages#221c1fcb as nil") } b.ObjStart() b.PutID("toggleSupergroupSignMessages") @@ -174,6 +191,9 @@ func (t *ToggleSupergroupSignMessagesRequest) EncodeTDLibJSON(b tdjson.Encoder) b.FieldStart("sign_messages") b.PutBool(t.SignMessages) b.Comma() + b.FieldStart("show_message_sender") + b.PutBool(t.ShowMessageSender) + b.Comma() b.StripComma() b.ObjEnd() return nil @@ -182,27 +202,33 @@ func (t *ToggleSupergroupSignMessagesRequest) EncodeTDLibJSON(b tdjson.Encoder) // DecodeTDLibJSON implements tdjson.TDLibDecoder. func (t *ToggleSupergroupSignMessagesRequest) DecodeTDLibJSON(b tdjson.Decoder) error { if t == nil { - return fmt.Errorf("can't decode toggleSupergroupSignMessages#44efd524 to nil") + return fmt.Errorf("can't decode toggleSupergroupSignMessages#221c1fcb to nil") } return b.Obj(func(b tdjson.Decoder, key []byte) error { switch string(key) { case tdjson.TypeField: if err := b.ConsumeID("toggleSupergroupSignMessages"); err != nil { - return fmt.Errorf("unable to decode toggleSupergroupSignMessages#44efd524: %w", err) + return fmt.Errorf("unable to decode toggleSupergroupSignMessages#221c1fcb: %w", err) } case "supergroup_id": value, err := b.Int53() if err != nil { - return fmt.Errorf("unable to decode toggleSupergroupSignMessages#44efd524: field supergroup_id: %w", err) + return fmt.Errorf("unable to decode toggleSupergroupSignMessages#221c1fcb: field supergroup_id: %w", err) } t.SupergroupID = value case "sign_messages": value, err := b.Bool() if err != nil { - return fmt.Errorf("unable to decode toggleSupergroupSignMessages#44efd524: field sign_messages: %w", err) + return fmt.Errorf("unable to decode toggleSupergroupSignMessages#221c1fcb: field sign_messages: %w", err) } t.SignMessages = value + case "show_message_sender": + value, err := b.Bool() + if err != nil { + return fmt.Errorf("unable to decode toggleSupergroupSignMessages#221c1fcb: field show_message_sender: %w", err) + } + t.ShowMessageSender = value default: return b.Skip() } @@ -226,7 +252,15 @@ func (t *ToggleSupergroupSignMessagesRequest) GetSignMessages() (value bool) { return t.SignMessages } -// ToggleSupergroupSignMessages invokes method toggleSupergroupSignMessages#44efd524 returning error if any. +// GetShowMessageSender returns value of ShowMessageSender field. +func (t *ToggleSupergroupSignMessagesRequest) GetShowMessageSender() (value bool) { + if t == nil { + return + } + return t.ShowMessageSender +} + +// ToggleSupergroupSignMessages invokes method toggleSupergroupSignMessages#221c1fcb returning error if any. func (c *Client) ToggleSupergroupSignMessages(ctx context.Context, request *ToggleSupergroupSignMessagesRequest) error { var ok Ok diff --git a/tdapi/tl_update_gen.go b/tdapi/tl_update_gen.go index 028451d27f..097588078c 100644 --- a/tdapi/tl_update_gen.go +++ b/tdapi/tl_update_gen.go @@ -24852,6 +24852,200 @@ func (u *UpdateSavedMessagesTags) GetTags() (value SavedMessagesTags) { return u.Tags } +// UpdateActiveLiveLocationMessages represents TL type `updateActiveLiveLocationMessages#a20b9b1f`. +type UpdateActiveLiveLocationMessages struct { + // The list of messages with active live locations + Messages []Message +} + +// UpdateActiveLiveLocationMessagesTypeID is TL type id of UpdateActiveLiveLocationMessages. +const UpdateActiveLiveLocationMessagesTypeID = 0xa20b9b1f + +// construct implements constructor of UpdateClass. +func (u UpdateActiveLiveLocationMessages) construct() UpdateClass { return &u } + +// Ensuring interfaces in compile-time for UpdateActiveLiveLocationMessages. +var ( + _ bin.Encoder = &UpdateActiveLiveLocationMessages{} + _ bin.Decoder = &UpdateActiveLiveLocationMessages{} + _ bin.BareEncoder = &UpdateActiveLiveLocationMessages{} + _ bin.BareDecoder = &UpdateActiveLiveLocationMessages{} + + _ UpdateClass = &UpdateActiveLiveLocationMessages{} +) + +func (u *UpdateActiveLiveLocationMessages) Zero() bool { + if u == nil { + return true + } + if !(u.Messages == nil) { + return false + } + + return true +} + +// String implements fmt.Stringer. +func (u *UpdateActiveLiveLocationMessages) String() string { + if u == nil { + return "UpdateActiveLiveLocationMessages(nil)" + } + type Alias UpdateActiveLiveLocationMessages + return fmt.Sprintf("UpdateActiveLiveLocationMessages%+v", Alias(*u)) +} + +// TypeID returns type id in TL schema. +// +// See https://core.telegram.org/mtproto/TL-tl#remarks. +func (*UpdateActiveLiveLocationMessages) TypeID() uint32 { + return UpdateActiveLiveLocationMessagesTypeID +} + +// TypeName returns name of type in TL schema. +func (*UpdateActiveLiveLocationMessages) TypeName() string { + return "updateActiveLiveLocationMessages" +} + +// TypeInfo returns info about TL type. +func (u *UpdateActiveLiveLocationMessages) TypeInfo() tdp.Type { + typ := tdp.Type{ + Name: "updateActiveLiveLocationMessages", + ID: UpdateActiveLiveLocationMessagesTypeID, + } + if u == nil { + typ.Null = true + return typ + } + typ.Fields = []tdp.Field{ + { + Name: "Messages", + SchemaName: "messages", + }, + } + return typ +} + +// Encode implements bin.Encoder. +func (u *UpdateActiveLiveLocationMessages) Encode(b *bin.Buffer) error { + if u == nil { + return fmt.Errorf("can't encode updateActiveLiveLocationMessages#a20b9b1f as nil") + } + b.PutID(UpdateActiveLiveLocationMessagesTypeID) + return u.EncodeBare(b) +} + +// EncodeBare implements bin.BareEncoder. +func (u *UpdateActiveLiveLocationMessages) EncodeBare(b *bin.Buffer) error { + if u == nil { + return fmt.Errorf("can't encode updateActiveLiveLocationMessages#a20b9b1f as nil") + } + b.PutInt(len(u.Messages)) + for idx, v := range u.Messages { + if err := v.EncodeBare(b); err != nil { + return fmt.Errorf("unable to encode bare updateActiveLiveLocationMessages#a20b9b1f: field messages element with index %d: %w", idx, err) + } + } + return nil +} + +// Decode implements bin.Decoder. +func (u *UpdateActiveLiveLocationMessages) Decode(b *bin.Buffer) error { + if u == nil { + return fmt.Errorf("can't decode updateActiveLiveLocationMessages#a20b9b1f to nil") + } + if err := b.ConsumeID(UpdateActiveLiveLocationMessagesTypeID); err != nil { + return fmt.Errorf("unable to decode updateActiveLiveLocationMessages#a20b9b1f: %w", err) + } + return u.DecodeBare(b) +} + +// DecodeBare implements bin.BareDecoder. +func (u *UpdateActiveLiveLocationMessages) DecodeBare(b *bin.Buffer) error { + if u == nil { + return fmt.Errorf("can't decode updateActiveLiveLocationMessages#a20b9b1f to nil") + } + { + headerLen, err := b.Int() + if err != nil { + return fmt.Errorf("unable to decode updateActiveLiveLocationMessages#a20b9b1f: field messages: %w", err) + } + + if headerLen > 0 { + u.Messages = make([]Message, 0, headerLen%bin.PreallocateLimit) + } + for idx := 0; idx < headerLen; idx++ { + var value Message + if err := value.DecodeBare(b); err != nil { + return fmt.Errorf("unable to decode bare updateActiveLiveLocationMessages#a20b9b1f: field messages: %w", err) + } + u.Messages = append(u.Messages, value) + } + } + return nil +} + +// EncodeTDLibJSON implements tdjson.TDLibEncoder. +func (u *UpdateActiveLiveLocationMessages) EncodeTDLibJSON(b tdjson.Encoder) error { + if u == nil { + return fmt.Errorf("can't encode updateActiveLiveLocationMessages#a20b9b1f as nil") + } + b.ObjStart() + b.PutID("updateActiveLiveLocationMessages") + b.Comma() + b.FieldStart("messages") + b.ArrStart() + for idx, v := range u.Messages { + if err := v.EncodeTDLibJSON(b); err != nil { + return fmt.Errorf("unable to encode updateActiveLiveLocationMessages#a20b9b1f: field messages element with index %d: %w", idx, err) + } + b.Comma() + } + b.StripComma() + b.ArrEnd() + b.Comma() + b.StripComma() + b.ObjEnd() + return nil +} + +// DecodeTDLibJSON implements tdjson.TDLibDecoder. +func (u *UpdateActiveLiveLocationMessages) DecodeTDLibJSON(b tdjson.Decoder) error { + if u == nil { + return fmt.Errorf("can't decode updateActiveLiveLocationMessages#a20b9b1f to nil") + } + + return b.Obj(func(b tdjson.Decoder, key []byte) error { + switch string(key) { + case tdjson.TypeField: + if err := b.ConsumeID("updateActiveLiveLocationMessages"); err != nil { + return fmt.Errorf("unable to decode updateActiveLiveLocationMessages#a20b9b1f: %w", err) + } + case "messages": + if err := b.Arr(func(b tdjson.Decoder) error { + var value Message + if err := value.DecodeTDLibJSON(b); err != nil { + return fmt.Errorf("unable to decode updateActiveLiveLocationMessages#a20b9b1f: field messages: %w", err) + } + u.Messages = append(u.Messages, value) + return nil + }); err != nil { + return fmt.Errorf("unable to decode updateActiveLiveLocationMessages#a20b9b1f: field messages: %w", err) + } + default: + return b.Skip() + } + return nil + }) +} + +// GetMessages returns value of Messages field. +func (u *UpdateActiveLiveLocationMessages) GetMessages() (value []Message) { + if u == nil { + return + } + return u.Messages +} + // UpdateOwnedStarCount represents TL type `updateOwnedStarCount#de995b79`. type UpdateOwnedStarCount struct { // The new number of Telegram Stars owned @@ -32845,6 +33039,7 @@ const UpdateClassName = "Update" // case *tdapi.UpdateAvailableMessageEffects: // updateAvailableMessageEffects#a1cb72b9 // case *tdapi.UpdateDefaultReactionType: // updateDefaultReactionType#4b615105 // case *tdapi.UpdateSavedMessagesTags: // updateSavedMessagesTags#7386424a +// case *tdapi.UpdateActiveLiveLocationMessages: // updateActiveLiveLocationMessages#a20b9b1f // case *tdapi.UpdateOwnedStarCount: // updateOwnedStarCount#de995b79 // case *tdapi.UpdateChatRevenueAmount: // updateChatRevenueAmount#c6c9bcc4 // case *tdapi.UpdateStarRevenueStatus: // updateStarRevenueStatus#ef4bfccb @@ -33733,6 +33928,13 @@ func DecodeUpdate(buf *bin.Buffer) (UpdateClass, error) { return nil, fmt.Errorf("unable to decode UpdateClass: %w", err) } return &v, nil + case UpdateActiveLiveLocationMessagesTypeID: + // Decoding updateActiveLiveLocationMessages#a20b9b1f. + v := UpdateActiveLiveLocationMessages{} + if err := v.Decode(buf); err != nil { + return nil, fmt.Errorf("unable to decode UpdateClass: %w", err) + } + return &v, nil case UpdateOwnedStarCountTypeID: // Decoding updateOwnedStarCount#de995b79. v := UpdateOwnedStarCount{} @@ -34788,6 +34990,13 @@ func DecodeTDLibJSONUpdate(buf tdjson.Decoder) (UpdateClass, error) { return nil, fmt.Errorf("unable to decode UpdateClass: %w", err) } return &v, nil + case "updateActiveLiveLocationMessages": + // Decoding updateActiveLiveLocationMessages#a20b9b1f. + v := UpdateActiveLiveLocationMessages{} + if err := v.DecodeTDLibJSON(buf); err != nil { + return nil, fmt.Errorf("unable to decode UpdateClass: %w", err) + } + return &v, nil case "updateOwnedStarCount": // Decoding updateOwnedStarCount#de995b79. v := UpdateOwnedStarCount{}