This commit is contained in:
Wizou 2025-01-02 00:27:45 +01:00
parent d8f7304067
commit b5aea68f66
3 changed files with 196 additions and 90 deletions

View file

@ -1856,7 +1856,7 @@ namespace TL
has_effect = 0x4, has_effect = 0x4,
/// <summary>Field <see cref="factcheck"/> has a value</summary> /// <summary>Field <see cref="factcheck"/> has a value</summary>
has_factcheck = 0x8, has_factcheck = 0x8,
/// <summary>The video contained in the message is currently being processed by the server (i.e. to generate alternative qualities, that will be contained in the final <see cref="MessageMediaDocument"/>.<c>alt_document</c>), and will be sent once the video is processed, which will happen approximately at the specified <c>date</c> (i.e. messages with this flag set should be treated similarly to <a href="https://corefork.telegram.org/api/scheduled-messages">scheduled messages</a>, but instead of the scheduled date, <c>date</c> contains the estimated conversion date).</summary> /// <summary>The video contained in the message is currently being processed by the server (i.e. to generate alternative qualities, that will be contained in the final <see cref="MessageMediaDocument"/>.<c>alt_document</c>), and will be sent once the video is processed, which will happen approximately at the specified <c>date</c> (i.e. messages with this flag set should be treated similarly to <a href="https://corefork.telegram.org/api/scheduled-messages">scheduled messages</a>, but instead of the scheduled date, <c>date</c> contains the estimated conversion date). <br/>See <a href="https://corefork.telegram.org/api/files#video-qualities">here »</a> for more info.</summary>
video_processing_pending = 0x10, video_processing_pending = 0x10,
} }
@ -2352,6 +2352,7 @@ namespace TL
[IfFlag(1)] public string shipping_option_id; [IfFlag(1)] public string shipping_option_id;
/// <summary>Provider payment identifier</summary> /// <summary>Provider payment identifier</summary>
public PaymentCharge charge; public PaymentCharge charge;
/// <summary>Expiration date of the <a href="https://corefork.telegram.org/api/stars#star-subscriptions">Telegram Star subscription »</a>.</summary>
[IfFlag(4)] public DateTime subscription_until_date; [IfFlag(4)] public DateTime subscription_until_date;
[Flags] public enum Flags : uint [Flags] public enum Flags : uint
@ -2380,6 +2381,7 @@ namespace TL
public long total_amount; public long total_amount;
/// <summary>An invoice slug taken from an <a href="https://corefork.telegram.org/api/links#invoice-links">invoice deep link</a> or from the <a href="https://corefork.telegram.org/api/config#premium-invoice-slug"><c>premium_invoice_slug</c> app config parameter »</a></summary> /// <summary>An invoice slug taken from an <a href="https://corefork.telegram.org/api/links#invoice-links">invoice deep link</a> or from the <a href="https://corefork.telegram.org/api/config#premium-invoice-slug"><c>premium_invoice_slug</c> app config parameter »</a></summary>
[IfFlag(0)] public string invoice_slug; [IfFlag(0)] public string invoice_slug;
/// <summary>Expiration date of the <a href="https://corefork.telegram.org/api/stars#star-subscriptions">Telegram Star subscription »</a>.</summary>
[IfFlag(4)] public DateTime subscription_until_date; [IfFlag(4)] public DateTime subscription_until_date;
[Flags] public enum Flags : uint [Flags] public enum Flags : uint
@ -2814,6 +2816,7 @@ namespace TL
[Flags] public enum Flags : uint [Flags] public enum Flags : uint
{ {
/// <summary>If set, this indicates the reverse transaction that refunds the remaining stars to the creator of a giveaway if, when the giveaway ends, the number of members in the channel is smaller than the number of winners in the giveaway.</summary>
unclaimed = 0x1, unclaimed = 0x1,
} }
} }
@ -3511,6 +3514,7 @@ namespace TL
[IfFlag(38)] public int personal_channel_message; [IfFlag(38)] public int personal_channel_message;
/// <summary>Number of <a href="https://corefork.telegram.org/api/gifts">gifts</a> the user has chosen to display on their profile</summary> /// <summary>Number of <a href="https://corefork.telegram.org/api/gifts">gifts</a> the user has chosen to display on their profile</summary>
[IfFlag(40)] public int stargifts_count; [IfFlag(40)] public int stargifts_count;
/// <summary>This bot has an active <a href="https://corefork.telegram.org/api/bots/referrals">referral program »</a></summary>
[IfFlag(43)] public StarRefProgram starref_program; [IfFlag(43)] public StarRefProgram starref_program;
[Flags] public enum Flags : uint [Flags] public enum Flags : uint
@ -3595,6 +3599,7 @@ namespace TL
has_stargifts_count = 0x100, has_stargifts_count = 0x100,
/// <summary>If set, this user can view <a href="https://corefork.telegram.org/api/revenue#revenue-statistics">ad revenue statistics »</a> for this bot.</summary> /// <summary>If set, this user can view <a href="https://corefork.telegram.org/api/revenue#revenue-statistics">ad revenue statistics »</a> for this bot.</summary>
can_view_revenue = 0x200, can_view_revenue = 0x200,
/// <summary>If set, this is a bot that can <a href="https://corefork.telegram.org/api/emoji-status#setting-an-emoji-status-from-a-bot">change our emoji status »</a></summary>
bot_can_manage_emoji_status = 0x400, bot_can_manage_emoji_status = 0x400,
/// <summary>Field <see cref="starref_program"/> has a value</summary> /// <summary>Field <see cref="starref_program"/> has a value</summary>
has_starref_program = 0x800, has_starref_program = 0x800,
@ -4751,7 +4756,7 @@ namespace TL
/// <summary>Message</summary> /// <summary>Message</summary>
public MessageBase message; public MessageBase message;
} }
/// <summary>Some <a href="https://corefork.telegram.org/api/scheduled-messages">scheduled messages</a> were deleted from the schedule queue of a chat <para>See <a href="https://corefork.telegram.org/constructor/updateDeleteScheduledMessages"/></para></summary> /// <summary>Some <a href="https://corefork.telegram.org/api/scheduled-messages">scheduled messages</a> were deleted (or sent) from the schedule queue of a chat <para>See <a href="https://corefork.telegram.org/constructor/updateDeleteScheduledMessages"/></para></summary>
[TLDef(0xF2A71983)] [TLDef(0xF2A71983)]
public sealed partial class UpdateDeleteScheduledMessages : Update public sealed partial class UpdateDeleteScheduledMessages : Update
{ {
@ -4761,6 +4766,7 @@ namespace TL
public Peer peer; public Peer peer;
/// <summary>Deleted scheduled messages</summary> /// <summary>Deleted scheduled messages</summary>
public int[] messages; public int[] messages;
/// <summary>If set, this update indicates that some scheduled messages were sent (not simply deleted from the schedule queue). <br/>In this case, the <c>messages</c> field will contain the scheduled message IDs for the sent messages (initially returned in <see cref="UpdateNewScheduledMessage"/>), and <c>sent_messages</c> will contain the real message IDs for the sent messages.</summary>
[IfFlag(0)] public int[] sent_messages; [IfFlag(0)] public int[] sent_messages;
[Flags] public enum Flags : uint [Flags] public enum Flags : uint
@ -6799,7 +6805,7 @@ namespace TL
About = 0x3823CC40, About = 0x3823CC40,
///<summary>Whether the user can see our birthday.</summary> ///<summary>Whether the user can see our birthday.</summary>
Birthday = 0xD65A11CC, Birthday = 0xD65A11CC,
///<summary>See <a href="https://corefork.telegram.org/constructor/inputPrivacyKeyStarGiftsAutoSave"/></summary> ///<summary>Whether received <a href="https://corefork.telegram.org/api/gifts">gifts</a> will be automatically displayed on our profile</summary>
StarGiftsAutoSave = 0xE1732341, StarGiftsAutoSave = 0xE1732341,
} }
@ -6828,11 +6834,11 @@ namespace TL
About = 0xA486B761, About = 0xA486B761,
///<summary>Whether the user can see our birthday.</summary> ///<summary>Whether the user can see our birthday.</summary>
Birthday = 0x2000A518, Birthday = 0x2000A518,
///<summary>See <a href="https://corefork.telegram.org/constructor/privacyKeyStarGiftsAutoSave"/></summary> ///<summary>Whether received <a href="https://corefork.telegram.org/api/gifts">gifts</a> will be automatically displayed on our profile</summary>
StarGiftsAutoSave = 0x2CA4FDF8, StarGiftsAutoSave = 0x2CA4FDF8,
} }
/// <summary>Privacy <strong>rules</strong> indicate <em>who</em> can or can't do something and are specified by a <see cref="PrivacyRule"/>, and its input counterpart <see cref="InputPrivacyRule"/>. <para>See <a href="https://corefork.telegram.org/type/InputPrivacyRule"/></para> <para>Derived classes: <see cref="InputPrivacyValueAllowContacts"/>, <see cref="InputPrivacyValueAllowAll"/>, <see cref="InputPrivacyValueAllowUsers"/>, <see cref="InputPrivacyValueDisallowContacts"/>, <see cref="InputPrivacyValueDisallowAll"/>, <see cref="InputPrivacyValueDisallowUsers"/>, <see cref="InputPrivacyValueAllowChatParticipants"/>, <see cref="InputPrivacyValueDisallowChatParticipants"/>, <see cref="InputPrivacyValueAllowCloseFriends"/>, <see cref="InputPrivacyValueAllowPremium"/></para></summary> /// <summary>Privacy <strong>rules</strong> indicate <em>who</em> can or can't do something and are specified by a <see cref="PrivacyRule"/>, and its input counterpart <see cref="InputPrivacyRule"/>. <para>See <a href="https://corefork.telegram.org/type/InputPrivacyRule"/></para> <para>Derived classes: <see cref="InputPrivacyValueAllowContacts"/>, <see cref="InputPrivacyValueAllowAll"/>, <see cref="InputPrivacyValueAllowUsers"/>, <see cref="InputPrivacyValueDisallowContacts"/>, <see cref="InputPrivacyValueDisallowAll"/>, <see cref="InputPrivacyValueDisallowUsers"/>, <see cref="InputPrivacyValueAllowChatParticipants"/>, <see cref="InputPrivacyValueDisallowChatParticipants"/>, <see cref="InputPrivacyValueAllowCloseFriends"/>, <see cref="InputPrivacyValueAllowPremium"/>, <see cref="InputPrivacyValueAllowBots"/>, <see cref="InputPrivacyValueDisallowBots"/></para></summary>
public abstract partial class InputPrivacyRule : IObject { } public abstract partial class InputPrivacyRule : IObject { }
/// <summary>Allow only contacts <para>See <a href="https://corefork.telegram.org/constructor/inputPrivacyValueAllowContacts"/></para></summary> /// <summary>Allow only contacts <para>See <a href="https://corefork.telegram.org/constructor/inputPrivacyValueAllowContacts"/></para></summary>
[TLDef(0x0D09E07B)] [TLDef(0x0D09E07B)]
@ -6880,14 +6886,14 @@ namespace TL
/// <summary>Allow only users with a <a href="https://corefork.telegram.org/api/premium">Premium subscription »</a>, currently only usable for <see cref="InputPrivacyKey.ChatInvite"/>. <para>See <a href="https://corefork.telegram.org/constructor/inputPrivacyValueAllowPremium"/></para></summary> /// <summary>Allow only users with a <a href="https://corefork.telegram.org/api/premium">Premium subscription »</a>, currently only usable for <see cref="InputPrivacyKey.ChatInvite"/>. <para>See <a href="https://corefork.telegram.org/constructor/inputPrivacyValueAllowPremium"/></para></summary>
[TLDef(0x77CDC9F1)] [TLDef(0x77CDC9F1)]
public sealed partial class InputPrivacyValueAllowPremium : InputPrivacyRule { } public sealed partial class InputPrivacyValueAllowPremium : InputPrivacyRule { }
/// <summary><para>See <a href="https://corefork.telegram.org/constructor/inputPrivacyValueAllowBots"/></para></summary> /// <summary>Allow bots and mini apps <para>See <a href="https://corefork.telegram.org/constructor/inputPrivacyValueAllowBots"/></para></summary>
[TLDef(0x5A4FCCE5)] [TLDef(0x5A4FCCE5)]
public sealed partial class InputPrivacyValueAllowBots : InputPrivacyRule { } public sealed partial class InputPrivacyValueAllowBots : InputPrivacyRule { }
/// <summary><para>See <a href="https://corefork.telegram.org/constructor/inputPrivacyValueDisallowBots"/></para></summary> /// <summary>Disallow bots and mini apps <para>See <a href="https://corefork.telegram.org/constructor/inputPrivacyValueDisallowBots"/></para></summary>
[TLDef(0xC4E57915)] [TLDef(0xC4E57915)]
public sealed partial class InputPrivacyValueDisallowBots : InputPrivacyRule { } public sealed partial class InputPrivacyValueDisallowBots : InputPrivacyRule { }
/// <summary>Privacy <strong>rules</strong> together with <a href="https://corefork.telegram.org/api/privacy#privacy-keys">privacy keys</a> indicate <em>what</em> can or can't someone do and are specified by a <see cref="PrivacyRule"/> constructor, and its input counterpart <see cref="InputPrivacyRule"/>. <para>See <a href="https://corefork.telegram.org/type/PrivacyRule"/></para> <para>Derived classes: <see cref="PrivacyValueAllowContacts"/>, <see cref="PrivacyValueAllowAll"/>, <see cref="PrivacyValueAllowUsers"/>, <see cref="PrivacyValueDisallowContacts"/>, <see cref="PrivacyValueDisallowAll"/>, <see cref="PrivacyValueDisallowUsers"/>, <see cref="PrivacyValueAllowChatParticipants"/>, <see cref="PrivacyValueDisallowChatParticipants"/>, <see cref="PrivacyValueAllowCloseFriends"/>, <see cref="PrivacyValueAllowPremium"/></para></summary> /// <summary>Privacy <strong>rules</strong> together with <a href="https://corefork.telegram.org/api/privacy#privacy-keys">privacy keys</a> indicate <em>what</em> can or can't someone do and are specified by a <see cref="PrivacyRule"/> constructor, and its input counterpart <see cref="InputPrivacyRule"/>. <para>See <a href="https://corefork.telegram.org/type/PrivacyRule"/></para> <para>Derived classes: <see cref="PrivacyValueAllowContacts"/>, <see cref="PrivacyValueAllowAll"/>, <see cref="PrivacyValueAllowUsers"/>, <see cref="PrivacyValueDisallowContacts"/>, <see cref="PrivacyValueDisallowAll"/>, <see cref="PrivacyValueDisallowUsers"/>, <see cref="PrivacyValueAllowChatParticipants"/>, <see cref="PrivacyValueDisallowChatParticipants"/>, <see cref="PrivacyValueAllowCloseFriends"/>, <see cref="PrivacyValueAllowPremium"/>, <see cref="PrivacyValueAllowBots"/>, <see cref="PrivacyValueDisallowBots"/></para></summary>
public abstract partial class PrivacyRule : IObject { } public abstract partial class PrivacyRule : IObject { }
/// <summary>Allow all contacts <para>See <a href="https://corefork.telegram.org/constructor/privacyValueAllowContacts"/></para></summary> /// <summary>Allow all contacts <para>See <a href="https://corefork.telegram.org/constructor/privacyValueAllowContacts"/></para></summary>
[TLDef(0xFFFE1BAC)] [TLDef(0xFFFE1BAC)]
@ -6935,10 +6941,10 @@ namespace TL
/// <summary>Allow only users with a <a href="https://corefork.telegram.org/api/premium">Premium subscription »</a>, currently only usable for <see cref="InputPrivacyKey.ChatInvite"/>. <para>See <a href="https://corefork.telegram.org/constructor/privacyValueAllowPremium"/></para></summary> /// <summary>Allow only users with a <a href="https://corefork.telegram.org/api/premium">Premium subscription »</a>, currently only usable for <see cref="InputPrivacyKey.ChatInvite"/>. <para>See <a href="https://corefork.telegram.org/constructor/privacyValueAllowPremium"/></para></summary>
[TLDef(0xECE9814B)] [TLDef(0xECE9814B)]
public sealed partial class PrivacyValueAllowPremium : PrivacyRule { } public sealed partial class PrivacyValueAllowPremium : PrivacyRule { }
/// <summary><para>See <a href="https://corefork.telegram.org/constructor/privacyValueAllowBots"/></para></summary> /// <summary>Allow bots and mini apps <para>See <a href="https://corefork.telegram.org/constructor/privacyValueAllowBots"/></para></summary>
[TLDef(0x21461B5D)] [TLDef(0x21461B5D)]
public sealed partial class PrivacyValueAllowBots : PrivacyRule { } public sealed partial class PrivacyValueAllowBots : PrivacyRule { }
/// <summary><para>See <a href="https://corefork.telegram.org/constructor/privacyValueDisallowBots"/></para></summary> /// <summary>Disallow bots and mini apps <para>See <a href="https://corefork.telegram.org/constructor/privacyValueDisallowBots"/></para></summary>
[TLDef(0xF6A5F82F)] [TLDef(0xF6A5F82F)]
public sealed partial class PrivacyValueDisallowBots : PrivacyRule { } public sealed partial class PrivacyValueDisallowBots : PrivacyRule { }
@ -7201,7 +7207,7 @@ namespace TL
public string display_url; public string display_url;
/// <summary><a href="https://corefork.telegram.org/api/offsets#hash-generation">Hash used for caching, for more info click here</a></summary> /// <summary><a href="https://corefork.telegram.org/api/offsets#hash-generation">Hash used for caching, for more info click here</a></summary>
public int hash; public int hash;
/// <summary>Type of the web page. Can be: article, photo, audio, video, document, profile, app, or something else, see <a href="https://github.com/telegramdesktop/tdesktop/blob/4f7a124f3e85f3f61d862b94fb5a45236976f38f/Telegram/SourceFiles/data/data_web_page.cpp#L127">here »</a> for a full list.</summary> /// <summary>Type of the web page. One of the following: <!-- start type --><br/><br/>- <c>video</c><br/>- <c>gif</c><br/>- <c>photo</c><br/>- <c>document</c><br/>- <c>profile</c><br/>- <c>telegram_background</c><br/>- <c>telegram_theme</c><br/>- <c>telegram_story</c><br/>- <c>telegram_channel</c><br/>- <c>telegram_channel_request</c><br/>- <c>telegram_megagroup</c><br/>- <c>telegram_chat</c><br/>- <c>telegram_megagroup_request</c><br/>- <c>telegram_chat_request</c><br/>- <c>telegram_album</c><br/>- <c>telegram_message</c><br/>- <c>telegram_bot</c><br/>- <c>telegram_voicechat</c><br/>- <c>telegram_livestream</c><br/>- <c>telegram_user</c><br/>- <c>telegram_botapp</c><br/>- <c>telegram_channel_boost</c><br/>- <c>telegram_group_boost</c><br/>- <c>telegram_giftcode</c><br/>- <c>telegram_stickerset</c><br/><br/><!-- end type --></summary>
[IfFlag(0)] public string type; [IfFlag(0)] public string type;
/// <summary>Short name of the site (e.g., Google Docs, App Store)</summary> /// <summary>Short name of the site (e.g., Google Docs, App Store)</summary>
[IfFlag(1)] public string site_name; [IfFlag(1)] public string site_name;
@ -7731,6 +7737,7 @@ namespace TL
[IfFlag(3)] public BotMenuButtonBase menu_button; [IfFlag(3)] public BotMenuButtonBase menu_button;
/// <summary>The HTTP link to the privacy policy of the bot. If not set, then the <c>/privacy</c> command must be used, if supported by the bot (i.e. if it's present in the <c>commands</c> vector). If it isn't supported, then <a href="https://telegram.org/privacy-tpa">https://telegram.org/privacy-tpa</a> must be opened, instead.</summary> /// <summary>The HTTP link to the privacy policy of the bot. If not set, then the <c>/privacy</c> command must be used, if supported by the bot (i.e. if it's present in the <c>commands</c> vector). If it isn't supported, then <a href="https://telegram.org/privacy-tpa">https://telegram.org/privacy-tpa</a> must be opened, instead.</summary>
[IfFlag(7)] public string privacy_policy_url; [IfFlag(7)] public string privacy_policy_url;
/// <summary><a href="https://corefork.telegram.org/api/bots/webapps">Mini app »</a> settings<br/></summary>
[IfFlag(8)] public BotAppSettings app_settings; [IfFlag(8)] public BotAppSettings app_settings;
[Flags] public enum Flags : uint [Flags] public enum Flags : uint
@ -10391,6 +10398,7 @@ namespace TL
[IfFlag(8)] public long[] suggested_tip_amounts; [IfFlag(8)] public long[] suggested_tip_amounts;
/// <summary>Terms of service URL</summary> /// <summary>Terms of service URL</summary>
[IfFlag(10)] public string terms_url; [IfFlag(10)] public string terms_url;
/// <summary>The number of seconds between consecutive Telegram Star debiting for <a href="https://corefork.telegram.org/api/subscriptions#bot-subscriptions">bot subscription</a> invoices</summary>
[IfFlag(11)] public int subscription_period; [IfFlag(11)] public int subscription_period;
[Flags] public enum Flags : uint [Flags] public enum Flags : uint
@ -11924,7 +11932,9 @@ namespace TL
[TLDef(0x64642DB3)] [TLDef(0x64642DB3)]
public sealed partial class ChannelAdminLogEventActionParticipantSubExtend : ChannelAdminLogEventAction public sealed partial class ChannelAdminLogEventActionParticipantSubExtend : ChannelAdminLogEventAction
{ {
/// <summary>Same as <c>new_participant</c>.</summary>
public ChannelParticipantBase prev_participant; public ChannelParticipantBase prev_participant;
/// <summary>The subscriber that extended the subscription.</summary>
public ChannelParticipantBase new_participant; public ChannelParticipantBase new_participant;
} }
@ -13580,7 +13590,7 @@ namespace TL
{ {
/// <summary>Platform identifier (ios, android, wp, all, etc.), can be concatenated with a dash as separator (<c>android-ios</c>, <c>ios-wp</c>, etc)</summary> /// <summary>Platform identifier (ios, android, wp, all, etc.), can be concatenated with a dash as separator (<c>android-ios</c>, <c>ios-wp</c>, etc)</summary>
public string platform; public string platform;
/// <summary>Restriction reason (<c>porno</c>, <c>terms</c>, etc.)</summary> /// <summary>Restriction reason (<c>porno</c>, <c>terms</c>, etc.). Ignore this restriction reason if it is contained in the <a href="https://corefork.telegram.org/api/config#ignore-restriction-reasons">ignore_restriction_reasons »</a> client configuration parameter.</summary>
public string reason; public string reason;
/// <summary>Error message to be shown to the user</summary> /// <summary>Error message to be shown to the user</summary>
public string text; public string text;
@ -15533,6 +15543,7 @@ namespace TL
has_query_id = 0x1, has_query_id = 0x1,
/// <summary>If set, the app must be opened in fullsize mode instead of compact mode.</summary> /// <summary>If set, the app must be opened in fullsize mode instead of compact mode.</summary>
fullsize = 0x2, fullsize = 0x2,
/// <summary>If set, the app must be opened in fullscreen</summary>
fullscreen = 0x4, fullscreen = 0x4,
} }
} }
@ -15680,7 +15691,7 @@ namespace TL
public InputUserBase user_id; public InputUserBase user_id;
/// <summary>Identifier of the gift, from <see cref="StarGift"/>.<c>id</c></summary> /// <summary>Identifier of the gift, from <see cref="StarGift"/>.<c>id</c></summary>
public long gift_id; public long gift_id;
/// <summary>Optional message, attached with the gift</summary> /// <summary>Optional message, attached with the gift. <br/>The maximum length for this field is specified in the <a href="https://corefork.telegram.org/api/config#stargifts-message-length-max">stargifts_message_length_max client configuration value »</a>.</summary>
[IfFlag(1)] public TextWithEntities message; [IfFlag(1)] public TextWithEntities message;
[Flags] public enum Flags : uint [Flags] public enum Flags : uint
@ -17609,6 +17620,7 @@ namespace TL
[IfFlag(4)] public string used_gift_slug; [IfFlag(4)] public string used_gift_slug;
/// <summary>If set, this boost counts as <c>multiplier</c> boosts, otherwise it counts as a single boost.</summary> /// <summary>If set, this boost counts as <c>multiplier</c> boosts, otherwise it counts as a single boost.</summary>
[IfFlag(5)] public int multiplier; [IfFlag(5)] public int multiplier;
/// <summary>Number of Telegram Stars distributed among the winners of the giveaway.</summary>
[IfFlag(6)] public long stars; [IfFlag(6)] public long stars;
[Flags] public enum Flags : uint [Flags] public enum Flags : uint
@ -19157,8 +19169,11 @@ namespace TL
[IfFlag(14)] public StarGift stargift; [IfFlag(14)] public StarGift stargift;
/// <summary>This transaction is payment for <a href="https://corefork.telegram.org/bots/faq#how-can-i-message-all-of-my-bot-39s-subscribers-at-once">paid bot broadcasts</a>. <br/>Paid broadcasts are only allowed if the <c>allow_paid_floodskip</c> parameter of <see cref="SchemaExtensions.Messages_SendMessage">Messages_SendMessage</see> and other message sending methods is set while trying to broadcast more than 30 messages per second to bot users. <br/>The integer value returned by this flag indicates the number of billed API calls.</summary> /// <summary>This transaction is payment for <a href="https://corefork.telegram.org/bots/faq#how-can-i-message-all-of-my-bot-39s-subscribers-at-once">paid bot broadcasts</a>. <br/>Paid broadcasts are only allowed if the <c>allow_paid_floodskip</c> parameter of <see cref="SchemaExtensions.Messages_SendMessage">Messages_SendMessage</see> and other message sending methods is set while trying to broadcast more than 30 messages per second to bot users. <br/>The integer value returned by this flag indicates the number of billed API calls.</summary>
[IfFlag(15)] public int floodskip_number; [IfFlag(15)] public int floodskip_number;
/// <summary>This transaction is the receival (or refund) of an <a href="https://corefork.telegram.org/api/bots/referrals">affiliate commission</a> (i.e. this is the transaction received by the peer that created the <a href="https://corefork.telegram.org/api/links#referral-links">referral link</a>, flag 17 is for transactions made by users that imported the referral link).</summary>
[IfFlag(16)] public int starref_commission_permille; [IfFlag(16)] public int starref_commission_permille;
/// <summary>For transactions made by <a href="https://corefork.telegram.org/api/bots/referrals">referred users</a>, the peer that received the affiliate commission.</summary>
[IfFlag(17)] public Peer starref_peer; [IfFlag(17)] public Peer starref_peer;
/// <summary>For transactions made by <a href="https://corefork.telegram.org/api/bots/referrals">referred users</a>, the amount of Telegram Stars received by the affiliate, can be negative for refunds.</summary>
[IfFlag(17)] public StarsAmount starref_amount; [IfFlag(17)] public StarsAmount starref_amount;
[Flags] public enum Flags : uint [Flags] public enum Flags : uint
@ -19212,7 +19227,7 @@ namespace TL
public StarsAmount balance; public StarsAmount balance;
/// <summary>Info about current Telegram Star subscriptions, only returned when invoking <see cref="SchemaExtensions.Payments_GetStarsTransactions">Payments_GetStarsTransactions</see> and <see cref="SchemaExtensions.Payments_GetStarsSubscriptions">Payments_GetStarsSubscriptions</see>.</summary> /// <summary>Info about current Telegram Star subscriptions, only returned when invoking <see cref="SchemaExtensions.Payments_GetStarsTransactions">Payments_GetStarsTransactions</see> and <see cref="SchemaExtensions.Payments_GetStarsSubscriptions">Payments_GetStarsSubscriptions</see>.</summary>
[IfFlag(1)] public StarsSubscription[] subscriptions; [IfFlag(1)] public StarsSubscription[] subscriptions;
/// <summary>Offset for pagination of subscriptions: only usable with <see cref="SchemaExtensions.Payments_GetStarsSubscriptions">Payments_GetStarsSubscriptions</see>, returned when invoking <see cref="SchemaExtensions.Payments_GetStarsTransactions">Payments_GetStarsTransactions</see> and <see cref="SchemaExtensions.Payments_GetStarsSubscriptions">Payments_GetStarsSubscriptions</see>.</summary> /// <summary>Offset for pagination of subscriptions: only usable and returned when invoking <see cref="SchemaExtensions.Payments_GetStarsSubscriptions">Payments_GetStarsSubscriptions</see>.</summary>
[IfFlag(2)] public string subscriptions_next_offset; [IfFlag(2)] public string subscriptions_next_offset;
/// <summary>The number of Telegram Stars the user should buy to be able to extend expired subscriptions soon (i.e. the current balance is not enough to extend all expired subscriptions).</summary> /// <summary>The number of Telegram Stars the user should buy to be able to extend expired subscriptions soon (i.e. the current balance is not enough to extend all expired subscriptions).</summary>
[IfFlag(4)] public long subscriptions_missing_balance; [IfFlag(4)] public long subscriptions_missing_balance;
@ -19321,7 +19336,7 @@ namespace TL
[Flags] public enum Flags : uint [Flags] public enum Flags : uint
{ {
/// <summary>If set, the user may <a href="https://corefork.telegram.org/api/stars#withdrawing-revenue">withdraw</a> up to <c>available_balance</c> stars.</summary> /// <summary>If set, the user may <a href="https://corefork.telegram.org/api/stars#withdrawing-stars">withdraw</a> up to <c>available_balance</c> stars.</summary>
withdrawal_enabled = 0x1, withdrawal_enabled = 0x1,
/// <summary>Field <see cref="next_withdrawal_at"/> has a value</summary> /// <summary>Field <see cref="next_withdrawal_at"/> has a value</summary>
has_next_withdrawal_at = 0x2, has_next_withdrawal_at = 0x2,
@ -19340,11 +19355,11 @@ namespace TL
public double usd_rate; public double usd_rate;
} }
/// <summary>Contains the URL to use to <a href="https://corefork.telegram.org/api/stars#withdrawing-revenue">withdraw Telegram Star revenue</a>. <para>See <a href="https://corefork.telegram.org/constructor/payments.starsRevenueWithdrawalUrl"/></para></summary> /// <summary>Contains the URL to use to <a href="https://corefork.telegram.org/api/stars#withdrawing-stars">withdraw Telegram Star revenue</a>. <para>See <a href="https://corefork.telegram.org/constructor/payments.starsRevenueWithdrawalUrl"/></para></summary>
[TLDef(0x1DAB80B7)] [TLDef(0x1DAB80B7)]
public sealed partial class Payments_StarsRevenueWithdrawalUrl : IObject public sealed partial class Payments_StarsRevenueWithdrawalUrl : IObject
{ {
/// <summary>Contains the URL to use to <a href="https://corefork.telegram.org/api/stars#withdrawing-revenue">withdraw Telegram Star revenue</a>.</summary> /// <summary>Contains the URL to use to <a href="https://corefork.telegram.org/api/stars#withdrawing-stars">withdraw Telegram Star revenue</a>.</summary>
public string url; public string url;
} }
@ -19460,8 +19475,11 @@ namespace TL
public StarsSubscriptionPricing pricing; public StarsSubscriptionPricing pricing;
/// <summary>Invitation link, used to renew the subscription after cancellation or expiration.</summary> /// <summary>Invitation link, used to renew the subscription after cancellation or expiration.</summary>
[IfFlag(3)] public string chat_invite_hash; [IfFlag(3)] public string chat_invite_hash;
/// <summary>For bot subscriptions, the title of the subscription invoice</summary>
[IfFlag(4)] public string title; [IfFlag(4)] public string title;
/// <summary>For bot subscriptions, the photo from the subscription invoice</summary>
[IfFlag(5)] public WebDocumentBase photo; [IfFlag(5)] public WebDocumentBase photo;
/// <summary>For bot subscriptions, the <a href="https://corefork.telegram.org/api/links#invoice-links">identifier</a> of the subscription invoice</summary>
[IfFlag(6)] public string invoice_slug; [IfFlag(6)] public string invoice_slug;
[Flags] public enum Flags : uint [Flags] public enum Flags : uint
@ -19480,6 +19498,7 @@ namespace TL
has_photo = 0x20, has_photo = 0x20,
/// <summary>Field <see cref="invoice_slug"/> has a value</summary> /// <summary>Field <see cref="invoice_slug"/> has a value</summary>
has_invoice_slug = 0x40, has_invoice_slug = 0x40,
/// <summary>Set if this <a href="https://corefork.telegram.org/api/subscriptions#bot-subscriptions">bot subscription</a> was cancelled by the bot</summary>
bot_canceled = 0x80, bot_canceled = 0x80,
} }
} }
@ -19585,6 +19604,7 @@ namespace TL
limited = 0x1, limited = 0x1,
/// <summary>Whether this gift sold out and cannot be bought anymore.</summary> /// <summary>Whether this gift sold out and cannot be bought anymore.</summary>
sold_out = 0x2, sold_out = 0x2,
/// <summary>Whether this is a birthday-themed gift</summary>
birthday = 0x4, birthday = 0x4,
} }
} }
@ -19698,143 +19718,199 @@ namespace TL
[TLDef(0x8DB33C4B)] [TLDef(0x8DB33C4B)]
public sealed partial class ReportResultReported : ReportResult { } public sealed partial class ReportResultReported : ReportResult { }
/// <summary><para>See <a href="https://corefork.telegram.org/constructor/messages.botPreparedInlineMessage"/></para></summary> /// <summary>Represents a <a href="https://corefork.telegram.org/api/bots/inline#21-using-a-prepared-inline-message">prepared inline message saved by a bot, to be sent to the user via a web app »</a> <para>See <a href="https://corefork.telegram.org/constructor/messages.botPreparedInlineMessage"/></para></summary>
[TLDef(0x8ECF0511)] [TLDef(0x8ECF0511)]
public sealed partial class Messages_BotPreparedInlineMessage : IObject public sealed partial class Messages_BotPreparedInlineMessage : IObject
{ {
/// <summary>The ID of the saved message, to be passed to the <c>id</c> field of the <a href="https://corefork.telegram.org/api/web-events#web-app-send-prepared-message">web_app_send_prepared_message event »</a></summary>
public string id; public string id;
/// <summary>Expiration date of the message</summary>
public DateTime expire_date; public DateTime expire_date;
} }
/// <summary><para>See <a href="https://corefork.telegram.org/constructor/messages.preparedInlineMessage"/></para></summary> /// <summary>Represents a <a href="https://corefork.telegram.org/api/bots/inline#21-using-a-prepared-inline-message">prepared inline message received via a bot's mini app, that can be sent to some chats »</a> <para>See <a href="https://corefork.telegram.org/constructor/messages.preparedInlineMessage"/></para></summary>
[TLDef(0xFF57708D)] [TLDef(0xFF57708D)]
public sealed partial class Messages_PreparedInlineMessage : IObject public sealed partial class Messages_PreparedInlineMessage : IObject
{ {
/// <summary>The <c>query_id</c> to pass to <see cref="SchemaExtensions.Messages_SendInlineBotResult">Messages_SendInlineBotResult</see></summary>
public long query_id; public long query_id;
/// <summary>The contents of the message, to be shown in a preview</summary>
public BotInlineResultBase result; public BotInlineResultBase result;
/// <summary>Types of chats where this message can be sent</summary>
public InlineQueryPeerType[] peer_types; public InlineQueryPeerType[] peer_types;
/// <summary>Caching validity of the results</summary>
public int cache_time; public int cache_time;
/// <summary>Users mentioned in the results</summary>
public Dictionary<long, User> users; public Dictionary<long, User> users;
} }
/// <summary><para>See <a href="https://corefork.telegram.org/constructor/botAppSettings"/></para></summary> /// <summary><a href="https://corefork.telegram.org/api/bots/webapps">Mini app »</a> settings <para>See <a href="https://corefork.telegram.org/constructor/botAppSettings"/></para></summary>
[TLDef(0xC99B1950)] [TLDef(0xC99B1950)]
public sealed partial class BotAppSettings : IObject public sealed partial class BotAppSettings : IObject
{ {
/// <summary>Extra bits of information, use <c>flags.HasFlag(...)</c> to test for those</summary>
public Flags flags; public Flags flags;
/// <summary>SVG placeholder logo, compressed using the same format used for <a href="https://corefork.telegram.org/api/files#vector-thumbnails">vector thumbnails »</a>.</summary>
[IfFlag(0)] public byte[] placeholder_path; [IfFlag(0)] public byte[] placeholder_path;
/// <summary>Default light mode background color</summary>
[IfFlag(1)] public int background_color; [IfFlag(1)] public int background_color;
/// <summary>Default dark mode background color</summary>
[IfFlag(2)] public int background_dark_color; [IfFlag(2)] public int background_dark_color;
/// <summary>Default light mode header color</summary>
[IfFlag(3)] public int header_color; [IfFlag(3)] public int header_color;
/// <summary>Default dark mode header color</summary>
[IfFlag(4)] public int header_dark_color; [IfFlag(4)] public int header_dark_color;
[Flags] public enum Flags : uint [Flags] public enum Flags : uint
{ {
/// <summary>Field <see cref="placeholder_path"/> has a value</summary>
has_placeholder_path = 0x1, has_placeholder_path = 0x1,
/// <summary>Field <see cref="background_color"/> has a value</summary>
has_background_color = 0x2, has_background_color = 0x2,
/// <summary>Field <see cref="background_dark_color"/> has a value</summary>
has_background_dark_color = 0x4, has_background_dark_color = 0x4,
/// <summary>Field <see cref="header_color"/> has a value</summary>
has_header_color = 0x8, has_header_color = 0x8,
/// <summary>Field <see cref="header_dark_color"/> has a value</summary>
has_header_dark_color = 0x10, has_header_dark_color = 0x10,
} }
} }
/// <summary><para>See <a href="https://corefork.telegram.org/constructor/starRefProgram"/></para></summary> /// <summary>Indo about an <a href="https://corefork.telegram.org/api/bots/referrals">affiliate program offered by a bot</a> <para>See <a href="https://corefork.telegram.org/constructor/starRefProgram"/></para></summary>
[TLDef(0xDD0C66F2)] [TLDef(0xDD0C66F2)]
public sealed partial class StarRefProgram : IObject public sealed partial class StarRefProgram : IObject
{ {
/// <summary>Extra bits of information, use <c>flags.HasFlag(...)</c> to test for those</summary>
public Flags flags; public Flags flags;
/// <summary>ID of the bot that offers the program</summary>
public long bot_id; public long bot_id;
/// <summary>An affiliate gets a commission of <see cref="StarRefProgram"/>.<c>commission_permille</c>‰ <a href="https://corefork.telegram.org/api/stars">Telegram Stars</a> for every mini app transaction made by users they refer</summary>
public int commission_permille; public int commission_permille;
/// <summary>An affiliate gets a commission for every mini app transaction made by users they refer, for <c>duration_months</c> months after a referral link is imported, starting the bot for the first time</summary>
[IfFlag(0)] public int duration_months; [IfFlag(0)] public int duration_months;
/// <summary>Point in time (Unix timestamp) when the affiliate program will be closed (optional, if not set the affiliate program isn't scheduled to be closed)</summary>
[IfFlag(1)] public DateTime end_date; [IfFlag(1)] public DateTime end_date;
/// <summary>The amount of daily revenue per user in Telegram Stars of the bot that created the affiliate program</summary>
[IfFlag(2)] public StarsAmount daily_revenue_per_user; [IfFlag(2)] public StarsAmount daily_revenue_per_user;
[Flags] public enum Flags : uint [Flags] public enum Flags : uint
{ {
/// <summary>Field <see cref="duration_months"/> has a value</summary>
has_duration_months = 0x1, has_duration_months = 0x1,
/// <summary>Field <see cref="end_date"/> has a value</summary>
has_end_date = 0x2, has_end_date = 0x2,
/// <summary>Field <see cref="daily_revenue_per_user"/> has a value</summary>
has_daily_revenue_per_user = 0x4, has_daily_revenue_per_user = 0x4,
} }
} }
/// <summary><para>See <a href="https://corefork.telegram.org/constructor/connectedBotStarRef"/></para></summary> /// <summary>Info about an <a href="https://corefork.telegram.org/api/bots/referrals#becoming-an-affiliate">active affiliate program we have with a Mini App</a> <para>See <a href="https://corefork.telegram.org/constructor/connectedBotStarRef"/></para></summary>
[TLDef(0x19A13F71)] [TLDef(0x19A13F71)]
public sealed partial class ConnectedBotStarRef : IObject public sealed partial class ConnectedBotStarRef : IObject
{ {
/// <summary>Extra bits of information, use <c>flags.HasFlag(...)</c> to test for those</summary>
public Flags flags; public Flags flags;
/// <summary><a href="https://corefork.telegram.org/api/links#referral-links">Referral link</a> to be shared</summary>
public string url; public string url;
/// <summary>When did we affiliate with <c>bot_id</c></summary>
public DateTime date; public DateTime date;
/// <summary>ID of the mini app that created the affiliate program</summary>
public long bot_id; public long bot_id;
/// <summary>The number of Telegram Stars received by the affiliate for each 1000 Telegram Stars received by <c>bot_id</c></summary>
public int commission_permille; public int commission_permille;
/// <summary>Number of months the program will be active; if not set, there is no expiration date.</summary>
[IfFlag(0)] public int duration_months; [IfFlag(0)] public int duration_months;
/// <summary>The number of users that used the affiliate program</summary>
public long participants; public long participants;
/// <summary>The number of Telegram Stars that were earned by the affiliate program</summary>
public long revenue; public long revenue;
[Flags] public enum Flags : uint [Flags] public enum Flags : uint
{ {
/// <summary>Field <see cref="duration_months"/> has a value</summary>
has_duration_months = 0x1, has_duration_months = 0x1,
/// <summary>If set, this affiliation was revoked by the affiliate using <see cref="SchemaExtensions.Payments_EditConnectedStarRefBot">Payments_EditConnectedStarRefBot</see>, or by the affiliation program owner using <see cref="SchemaExtensions.Bots_UpdateStarRefProgram">Bots_UpdateStarRefProgram</see></summary>
revoked = 0x2, revoked = 0x2,
} }
} }
/// <summary><para>See <a href="https://corefork.telegram.org/constructor/payments.connectedStarRefBots"/></para></summary> /// <summary>Active <a href="https://corefork.telegram.org/api/bots/referrals#becoming-an-affiliate">affiliations</a> <para>See <a href="https://corefork.telegram.org/constructor/payments.connectedStarRefBots"/></para></summary>
[TLDef(0x98D5EA1D)] [TLDef(0x98D5EA1D)]
public sealed partial class Payments_ConnectedStarRefBots : IObject public sealed partial class Payments_ConnectedStarRefBots : IObject
{ {
/// <summary>Total number of active affiliations</summary>
public int count; public int count;
/// <summary>The affiliations</summary>
public ConnectedBotStarRef[] connected_bots; public ConnectedBotStarRef[] connected_bots;
/// <summary>Peers mentioned in <c>connected_bots</c></summary>
public Dictionary<long, User> users; public Dictionary<long, User> users;
} }
/// <summary><para>See <a href="https://corefork.telegram.org/constructor/payments.suggestedStarRefBots"/></para></summary> /// <summary>A list of suggested <a href="https://corefork.telegram.org/api/bots/webapps">mini apps</a> with available <a href="https://corefork.telegram.org/api/bots/referrals">affiliate programs</a> <para>See <a href="https://corefork.telegram.org/constructor/payments.suggestedStarRefBots"/></para></summary>
[TLDef(0xB4D5D859)] [TLDef(0xB4D5D859)]
public sealed partial class Payments_SuggestedStarRefBots : IObject public sealed partial class Payments_SuggestedStarRefBots : IObject
{ {
/// <summary>Extra bits of information, use <c>flags.HasFlag(...)</c> to test for those</summary>
public Flags flags; public Flags flags;
/// <summary>Total number of results (for pagination)</summary>
public int count; public int count;
/// <summary>Suggested affiliate programs (full or partial list to be fetched using pagination)</summary>
public StarRefProgram[] suggested_bots; public StarRefProgram[] suggested_bots;
/// <summary>Peers mentioned in <c>suggested_bots</c></summary>
public Dictionary<long, User> users; public Dictionary<long, User> users;
/// <summary>Next offset for <a href="https://corefork.telegram.org/api/offsets">pagination</a></summary>
[IfFlag(0)] public string next_offset; [IfFlag(0)] public string next_offset;
[Flags] public enum Flags : uint [Flags] public enum Flags : uint
{ {
/// <summary>Field <see cref="next_offset"/> has a value</summary>
has_next_offset = 0x1, has_next_offset = 0x1,
} }
} }
/// <summary><para>See <a href="https://corefork.telegram.org/constructor/starsAmount"/></para></summary> /// <summary>Describes a real (i.e. possibly decimal) amount of <a href="https://corefork.telegram.org/api/stars">Telegram Stars</a>. <para>See <a href="https://corefork.telegram.org/constructor/starsAmount"/></para></summary>
[TLDef(0xBBB6B4A3)] [TLDef(0xBBB6B4A3)]
public sealed partial class StarsAmount : IObject public sealed partial class StarsAmount : IObject
{ {
/// <summary>The integer amount of Telegram Stars.</summary>
public long amount; public long amount;
/// <summary>The decimal amount of Telegram Stars, expressed as nanostars (i.e. 1 nanostar is equal to <c>1/1'000'000'000</c>th of a Telegram Star). <br/>This field may also be negative (the allowed range is -999999999 to 999999999).</summary>
public int nanos; public int nanos;
} }
/// <summary><para>See <a href="https://corefork.telegram.org/type/messages.FoundStickers"/></para></summary> /// <summary>Found <a href="https://corefork.telegram.org/api/stickers">stickers</a> <para>See <a href="https://corefork.telegram.org/type/messages.FoundStickers"/></para> <para>Derived classes: <see cref="Messages_FoundStickersNotModified"/>, <see cref="Messages_FoundStickers"/></para></summary>
public abstract partial class Messages_FoundStickersBase : IObject { } public abstract partial class Messages_FoundStickersBase : IObject { }
/// <summary><para>See <a href="https://corefork.telegram.org/constructor/messages.foundStickersNotModified"/></para></summary> /// <summary>No new stickers were found for the specified query <para>See <a href="https://corefork.telegram.org/constructor/messages.foundStickersNotModified"/></para></summary>
[TLDef(0x6010C534)] [TLDef(0x6010C534)]
public sealed partial class Messages_FoundStickersNotModified : Messages_FoundStickersBase public sealed partial class Messages_FoundStickersNotModified : Messages_FoundStickersBase
{ {
/// <summary>Extra bits of information, use <c>flags.HasFlag(...)</c> to test for those</summary>
public Flags flags; public Flags flags;
/// <summary>Offset for <a href="https://corefork.telegram.org/api/offsets">pagination</a></summary>
[IfFlag(0)] public int next_offset; [IfFlag(0)] public int next_offset;
[Flags] public enum Flags : uint [Flags] public enum Flags : uint
{ {
/// <summary>Field <see cref="next_offset"/> has a value</summary>
has_next_offset = 0x1, has_next_offset = 0x1,
} }
} }
/// <summary><para>See <a href="https://corefork.telegram.org/constructor/messages.foundStickers"/></para></summary> /// <summary>Found stickers <para>See <a href="https://corefork.telegram.org/constructor/messages.foundStickers"/></para></summary>
[TLDef(0x82C9E290)] [TLDef(0x82C9E290)]
public sealed partial class Messages_FoundStickers : Messages_FoundStickersBase public sealed partial class Messages_FoundStickers : Messages_FoundStickersBase
{ {
/// <summary>Extra bits of information, use <c>flags.HasFlag(...)</c> to test for those</summary>
public Flags flags; public Flags flags;
/// <summary>Offset for <a href="https://corefork.telegram.org/api/offsets">pagination</a></summary>
[IfFlag(0)] public int next_offset; [IfFlag(0)] public int next_offset;
/// <summary><a href="https://corefork.telegram.org/api/offsets#hash-generation">Hash used for caching, for more info click here</a></summary>
public long hash; public long hash;
/// <summary>Found stickers</summary>
public DocumentBase[] stickers; public DocumentBase[] stickers;
[Flags] public enum Flags : uint [Flags] public enum Flags : uint
{ {
/// <summary>Field <see cref="next_offset"/> has a value</summary>
has_next_offset = 0x1, has_next_offset = 0x1,
} }
} }

View file

@ -232,7 +232,7 @@ namespace TL
bot_auth_token = bot_auth_token, bot_auth_token = bot_auth_token,
}); });
/// <summary>Try logging to an account protected by a <a href="https://corefork.telegram.org/api/srp">2FA password</a>. <para>See <a href="https://corefork.telegram.org/method/auth.checkPassword"/></para> <para>Possible <see cref="RpcException"/> codes: 400 (<a href="https://corefork.telegram.org/method/auth.checkPassword#possible-errors">details</a>)</para></summary> /// <summary>Try logging to an account protected by a <a href="https://corefork.telegram.org/api/srp">2FA password</a>. <para>See <a href="https://corefork.telegram.org/method/auth.checkPassword"/></para> <para>Possible <see cref="RpcException"/> codes: 400,500 (<a href="https://corefork.telegram.org/method/auth.checkPassword#possible-errors">details</a>)</para></summary>
/// <param name="password">The account's password (see <a href="https://corefork.telegram.org/api/srp">SRP</a>)</param> /// <param name="password">The account's password (see <a href="https://corefork.telegram.org/api/srp">SRP</a>)</param>
public static Task<Auth_AuthorizationBase> Auth_CheckPassword(this Client client, InputCheckPasswordSRP password) public static Task<Auth_AuthorizationBase> Auth_CheckPassword(this Client client, InputCheckPasswordSRP password)
=> client.Invoke(new Auth_CheckPassword => client.Invoke(new Auth_CheckPassword
@ -507,7 +507,7 @@ namespace TL
rules = rules, rules = rules,
}); });
/// <summary>Delete the user's account from the telegram servers. <para>See <a href="https://corefork.telegram.org/method/account.deleteAccount"/></para> <para>Possible <see cref="RpcException"/> codes: 420 (<a href="https://corefork.telegram.org/method/account.deleteAccount#possible-errors">details</a>)</para></summary> /// <summary>Delete the user's account from the telegram servers. <para>See <a href="https://corefork.telegram.org/method/account.deleteAccount"/></para> <para>Possible <see cref="RpcException"/> codes: 400,420 (<a href="https://corefork.telegram.org/method/account.deleteAccount#possible-errors">details</a>)</para></summary>
/// <param name="reason">Why is the account being deleted, can be empty</param> /// <param name="reason">Why is the account being deleted, can be empty</param>
/// <param name="password"><a href="https://corefork.telegram.org/api/srp">2FA password</a>: this field can be omitted even for accounts with 2FA enabled: in this case account account deletion will be delayed by 7 days <a href="https://corefork.telegram.org/api/account-deletion">as specified in the docs »</a></param> /// <param name="password"><a href="https://corefork.telegram.org/api/srp">2FA password</a>: this field can be omitted even for accounts with 2FA enabled: in this case account account deletion will be delayed by 7 days <a href="https://corefork.telegram.org/api/account-deletion">as specified in the docs »</a></param>
public static Task<bool> Account_DeleteAccount(this Client client, string reason, InputCheckPasswordSRP password = null) public static Task<bool> Account_DeleteAccount(this Client client, string reason, InputCheckPasswordSRP password = null)
@ -1482,7 +1482,7 @@ namespace TL
contacts = contacts, contacts = contacts,
}); });
/// <summary>Deletes several contacts from the list. <para>See <a href="https://corefork.telegram.org/method/contacts.deleteContacts"/></para></summary> /// <summary>Deletes several contacts from the list. <para>See <a href="https://corefork.telegram.org/method/contacts.deleteContacts"/></para> <para>Possible <see cref="RpcException"/> codes: 400 (<a href="https://corefork.telegram.org/method/contacts.deleteContacts#possible-errors">details</a>)</para></summary>
/// <param name="id">User ID list</param> /// <param name="id">User ID list</param>
public static Task<UpdatesBase> Contacts_DeleteContacts(this Client client, params InputUserBase[] id) public static Task<UpdatesBase> Contacts_DeleteContacts(this Client client, params InputUserBase[] id)
=> client.Invoke(new Contacts_DeleteContacts => client.Invoke(new Contacts_DeleteContacts
@ -1542,6 +1542,7 @@ namespace TL
/// <summary>Resolve a @username to get peer info <para>See <a href="https://corefork.telegram.org/method/contacts.resolveUsername"/> [bots: ✓]</para> <para>Possible <see cref="RpcException"/> codes: 400 (<a href="https://corefork.telegram.org/method/contacts.resolveUsername#possible-errors">details</a>)</para></summary> /// <summary>Resolve a @username to get peer info <para>See <a href="https://corefork.telegram.org/method/contacts.resolveUsername"/> [bots: ✓]</para> <para>Possible <see cref="RpcException"/> codes: 400 (<a href="https://corefork.telegram.org/method/contacts.resolveUsername#possible-errors">details</a>)</para></summary>
/// <param name="username">@username to resolve</param> /// <param name="username">@username to resolve</param>
/// <param name="referer"><a href="https://corefork.telegram.org/api/links#referral-links">Referrer ID from referral links »</a>.</param>
public static Task<Contacts_ResolvedPeer> Contacts_ResolveUsername(this Client client, string username, string referer = null) public static Task<Contacts_ResolvedPeer> Contacts_ResolveUsername(this Client client, string username, string referer = null)
=> client.Invoke(new Contacts_ResolveUsername => client.Invoke(new Contacts_ResolveUsername
{ {
@ -1761,7 +1762,7 @@ namespace TL
/// <param name="max_date">If a positive value was transferred, only messages with a sending date smaller than the transferred one will be returned</param> /// <param name="max_date">If a positive value was transferred, only messages with a sending date smaller than the transferred one will be returned</param>
/// <param name="offset_id">Only return messages starting from the specified message ID</param> /// <param name="offset_id">Only return messages starting from the specified message ID</param>
/// <param name="add_offset"><a href="https://corefork.telegram.org/api/offsets">Additional offset</a></param> /// <param name="add_offset"><a href="https://corefork.telegram.org/api/offsets">Additional offset</a></param>
/// <param name="limit"><a href="https://corefork.telegram.org/api/offsets">Number of results to return</a></param> /// <param name="limit"><a href="https://corefork.telegram.org/api/offsets">Number of results to return</a>, can be 0 to only return the message counter.</param>
/// <param name="max_id"><a href="https://corefork.telegram.org/api/offsets">Maximum message ID to return</a></param> /// <param name="max_id"><a href="https://corefork.telegram.org/api/offsets">Maximum message ID to return</a></param>
/// <param name="min_id"><a href="https://corefork.telegram.org/api/offsets">Minimum message ID to return</a></param> /// <param name="min_id"><a href="https://corefork.telegram.org/api/offsets">Minimum message ID to return</a></param>
/// <param name="hash"><a href="https://corefork.telegram.org/api/offsets">Hash</a></param> /// <param name="hash"><a href="https://corefork.telegram.org/api/offsets">Hash</a></param>
@ -1844,7 +1845,7 @@ namespace TL
action = action, action = action,
}); });
/// <summary>Sends a message to a chat <para>See <a href="https://corefork.telegram.org/method/messages.sendMessage"/> [bots: ✓]</para> <para>Possible <see cref="RpcException"/> codes: 400,403,406,420,500 (<a href="https://corefork.telegram.org/method/messages.sendMessage#possible-errors">details</a>)</para></summary> /// <summary>Sends a message to a chat <para>See <a href="https://corefork.telegram.org/method/messages.sendMessage"/> [bots: ✓]</para> <para>Possible <see cref="RpcException"/> codes: 400,403,404,406,420,500 (<a href="https://corefork.telegram.org/method/messages.sendMessage#possible-errors">details</a>)</para></summary>
/// <param name="no_webpage">Set this flag to disable generation of the webpage preview</param> /// <param name="no_webpage">Set this flag to disable generation of the webpage preview</param>
/// <param name="silent">Send this message silently (no notifications for the receivers)</param> /// <param name="silent">Send this message silently (no notifications for the receivers)</param>
/// <param name="background">Send this message as background message</param> /// <param name="background">Send this message as background message</param>
@ -3622,7 +3623,7 @@ namespace TL
reaction = reaction, reaction = reaction,
}); });
/// <summary>Translate a given text. <para>See <a href="https://corefork.telegram.org/method/messages.translateText"/></para> <para>Possible <see cref="RpcException"/> codes: 400 (<a href="https://corefork.telegram.org/method/messages.translateText#possible-errors">details</a>)</para></summary> /// <summary>Translate a given text. <para>See <a href="https://corefork.telegram.org/method/messages.translateText"/></para> <para>Possible <see cref="RpcException"/> codes: 400,500 (<a href="https://corefork.telegram.org/method/messages.translateText#possible-errors">details</a>)</para></summary>
/// <param name="peer">If the text is a chat message, the peer ID</param> /// <param name="peer">If the text is a chat message, the peer ID</param>
/// <param name="id">A list of message IDs to translate</param> /// <param name="id">A list of message IDs to translate</param>
/// <param name="text">A list of styled messages to translate</param> /// <param name="text">A list of styled messages to translate</param>
@ -3713,7 +3714,8 @@ namespace TL
/// <summary>Open a <a href="https://corefork.telegram.org/bots/webapps">bot mini app</a>, sending over user information after user confirmation. <para>See <a href="https://corefork.telegram.org/method/messages.requestWebView"/></para> <para>Possible <see cref="RpcException"/> codes: 400,403 (<a href="https://corefork.telegram.org/method/messages.requestWebView#possible-errors">details</a>)</para></summary> /// <summary>Open a <a href="https://corefork.telegram.org/bots/webapps">bot mini app</a>, sending over user information after user confirmation. <para>See <a href="https://corefork.telegram.org/method/messages.requestWebView"/></para> <para>Possible <see cref="RpcException"/> codes: 400,403 (<a href="https://corefork.telegram.org/method/messages.requestWebView#possible-errors">details</a>)</para></summary>
/// <param name="from_bot_menu">Whether the webview was opened by clicking on the bot's <a href="https://corefork.telegram.org/api/bots/menu">menu button »</a>.</param> /// <param name="from_bot_menu">Whether the webview was opened by clicking on the bot's <a href="https://corefork.telegram.org/api/bots/menu">menu button »</a>.</param>
/// <param name="silent">Whether the inline message that will be sent by the bot on behalf of the user once the web app interaction is <see cref="Messages_SendWebViewResultMessage">Messages_SendWebViewResultMessage</see> should be sent silently (no notifications for the receivers).</param> /// <param name="silent">Whether the inline message that will be sent by the bot on behalf of the user once the web app interaction is <see cref="Messages_SendWebViewResultMessage">Messages_SendWebViewResultMessage</see> should be sent silently (no notifications for the receivers).</param>
/// <param name="compact">If set, requests to open the mini app in compact mode (as opposed to fullview mode). Must be set if the <c>mode</c> parameter of the <a href="https://corefork.telegram.org/api/links#bot-attachment-or-side-menu-links">attachment menu deep link</a> is equal to <c>compact</c>.</param> /// <param name="compact">If set, requests to open the mini app in compact mode (as opposed to normal or fullscreen mode). Must be set if the <c>mode</c> parameter of the <a href="https://corefork.telegram.org/api/links#bot-attachment-or-side-menu-links">attachment menu deep link</a> is equal to <c>compact</c>.</param>
/// <param name="fullscreen">If set, requests to open the mini app in fullscreen mode (as opposed to normal or compact mode). Must be set if the <c>mode</c> parameter of the <a href="https://corefork.telegram.org/api/links#bot-attachment-or-side-menu-links">attachment menu deep link</a> is equal to <c>fullscreen</c>.</param>
/// <param name="peer">Dialog where the web app is being opened, and where the resulting message will be sent (see the <a href="https://corefork.telegram.org/api/bots/webapps">docs for more info »</a>).</param> /// <param name="peer">Dialog where the web app is being opened, and where the resulting message will be sent (see the <a href="https://corefork.telegram.org/api/bots/webapps">docs for more info »</a>).</param>
/// <param name="bot">Bot that owns the <a href="https://corefork.telegram.org/api/bots/webapps">web app</a></param> /// <param name="bot">Bot that owns the <a href="https://corefork.telegram.org/api/bots/webapps">web app</a></param>
/// <param name="url"><a href="https://corefork.telegram.org/api/bots/webapps">Web app URL</a></param> /// <param name="url"><a href="https://corefork.telegram.org/api/bots/webapps">Web app URL</a></param>
@ -3758,6 +3760,7 @@ namespace TL
/// <param name="from_switch_webview">Whether the webapp was opened by clicking on the <c>switch_webview</c> button shown on top of the inline results list returned by <see cref="Messages_GetInlineBotResults">Messages_GetInlineBotResults</see>.</param> /// <param name="from_switch_webview">Whether the webapp was opened by clicking on the <c>switch_webview</c> button shown on top of the inline results list returned by <see cref="Messages_GetInlineBotResults">Messages_GetInlineBotResults</see>.</param>
/// <param name="from_side_menu">Set this flag if opening the Mini App from the installed <a href="https://corefork.telegram.org/api/bots/attach">side menu entry »</a>.</param> /// <param name="from_side_menu">Set this flag if opening the Mini App from the installed <a href="https://corefork.telegram.org/api/bots/attach">side menu entry »</a>.</param>
/// <param name="compact">Deprecated.</param> /// <param name="compact">Deprecated.</param>
/// <param name="fullscreen">Requests to open the app in fullscreen mode.</param>
/// <param name="bot">Bot that owns the mini app</param> /// <param name="bot">Bot that owns the mini app</param>
/// <param name="url">Web app URL, if opening from a keyboard button or inline result</param> /// <param name="url">Web app URL, if opening from a keyboard button or inline result</param>
/// <param name="start_param">Deprecated.</param> /// <param name="start_param">Deprecated.</param>
@ -3898,7 +3901,7 @@ namespace TL
}); });
/// <summary>Changes the default value of the Time-To-Live setting, applied to all new chats. <para>See <a href="https://corefork.telegram.org/method/messages.setDefaultHistoryTTL"/></para> <para>Possible <see cref="RpcException"/> codes: 400 (<a href="https://corefork.telegram.org/method/messages.setDefaultHistoryTTL#possible-errors">details</a>)</para></summary> /// <summary>Changes the default value of the Time-To-Live setting, applied to all new chats. <para>See <a href="https://corefork.telegram.org/method/messages.setDefaultHistoryTTL"/></para> <para>Possible <see cref="RpcException"/> codes: 400 (<a href="https://corefork.telegram.org/method/messages.setDefaultHistoryTTL#possible-errors">details</a>)</para></summary>
/// <param name="period">The new default Time-To-Live of all messages sent in new chats.</param> /// <param name="period">The new default Time-To-Live of all messages sent in new chats, in seconds.</param>
public static Task<bool> Messages_SetDefaultHistoryTTL(this Client client, int period) public static Task<bool> Messages_SetDefaultHistoryTTL(this Client client, int period)
=> client.Invoke(new Messages_SetDefaultHistoryTTL => client.Invoke(new Messages_SetDefaultHistoryTTL
{ {
@ -3985,7 +3988,8 @@ namespace TL
/// <summary>Open a <a href="https://corefork.telegram.org/bots/webapps">bot mini app</a> from a <a href="https://corefork.telegram.org/api/links#direct-mini-app-links">direct Mini App deep link</a>, sending over user information after user confirmation. <para>See <a href="https://corefork.telegram.org/method/messages.requestAppWebView"/></para> <para>Possible <see cref="RpcException"/> codes: 400 (<a href="https://corefork.telegram.org/method/messages.requestAppWebView#possible-errors">details</a>)</para></summary> /// <summary>Open a <a href="https://corefork.telegram.org/bots/webapps">bot mini app</a> from a <a href="https://corefork.telegram.org/api/links#direct-mini-app-links">direct Mini App deep link</a>, sending over user information after user confirmation. <para>See <a href="https://corefork.telegram.org/method/messages.requestAppWebView"/></para> <para>Possible <see cref="RpcException"/> codes: 400 (<a href="https://corefork.telegram.org/method/messages.requestAppWebView#possible-errors">details</a>)</para></summary>
/// <param name="write_allowed">Set this flag if the bot is asking permission to send messages to the user as specified in the <a href="https://corefork.telegram.org/api/links#direct-mini-app-links">direct Mini App deep link</a> docs, and the user agreed.</param> /// <param name="write_allowed">Set this flag if the bot is asking permission to send messages to the user as specified in the <a href="https://corefork.telegram.org/api/links#direct-mini-app-links">direct Mini App deep link</a> docs, and the user agreed.</param>
/// <param name="compact">If set, requests to open the mini app in compact mode (as opposed to fullview mode). Must be set if the <c>mode</c> parameter of the <a href="https://corefork.telegram.org/api/links#direct-mini-app-links">direct Mini App deep link</a> is equal to <c>compact</c>.</param> /// <param name="compact">If set, requests to open the mini app in compact mode (as opposed to normal or fullscreen mode). Must be set if the <c>mode</c> parameter of the <a href="https://corefork.telegram.org/api/links#direct-mini-app-links">direct Mini App deep link</a> is equal to <c>compact</c>.</param>
/// <param name="fullscreen">If set, requests to open the mini app in fullscreen mode (as opposed to compact or normal mode). Must be set if the <c>mode</c> parameter of the <a href="https://corefork.telegram.org/api/links#direct-mini-app-links">direct Mini App deep link</a> is equal to <c>fullscreen</c>.</param>
/// <param name="peer">If the client has clicked on the link in a Telegram chat, pass the chat's peer information; otherwise pass the bot's peer information, instead.</param> /// <param name="peer">If the client has clicked on the link in a Telegram chat, pass the chat's peer information; otherwise pass the bot's peer information, instead.</param>
/// <param name="app">The app obtained by invoking <see cref="Messages_GetBotApp">Messages_GetBotApp</see> as specified in the <a href="https://corefork.telegram.org/api/links#direct-mini-app-links">direct Mini App deep link</a> docs.</param> /// <param name="app">The app obtained by invoking <see cref="Messages_GetBotApp">Messages_GetBotApp</see> as specified in the <a href="https://corefork.telegram.org/api/links#direct-mini-app-links">direct Mini App deep link</a> docs.</param>
/// <param name="start_param">If the <c>startapp</c> query string parameter is present in the <a href="https://corefork.telegram.org/api/links#direct-mini-app-links">direct Mini App deep link</a>, pass it to <c>start_param</c>.</param> /// <param name="start_param">If the <c>startapp</c> query string parameter is present in the <a href="https://corefork.telegram.org/api/links#direct-mini-app-links">direct Mini App deep link</a>, pass it to <c>start_param</c>.</param>
@ -4304,7 +4308,8 @@ namespace TL
}); });
/// <summary>Open a <a href="https://corefork.telegram.org/api/bots/webapps#main-mini-apps">Main Mini App</a>. <para>See <a href="https://corefork.telegram.org/method/messages.requestMainWebView"/></para> <para>Possible <see cref="RpcException"/> codes: 400 (<a href="https://corefork.telegram.org/method/messages.requestMainWebView#possible-errors">details</a>)</para></summary> /// <summary>Open a <a href="https://corefork.telegram.org/api/bots/webapps#main-mini-apps">Main Mini App</a>. <para>See <a href="https://corefork.telegram.org/method/messages.requestMainWebView"/></para> <para>Possible <see cref="RpcException"/> codes: 400 (<a href="https://corefork.telegram.org/method/messages.requestMainWebView#possible-errors">details</a>)</para></summary>
/// <param name="compact">If set, requests to open the mini app in compact mode (as opposed to fullview mode). Must be set if the <c>mode</c> parameter of the <a href="https://corefork.telegram.org/api/links#main-mini-app-links">Main Mini App link</a> is equal to <c>compact</c>.</param> /// <param name="compact">If set, requests to open the mini app in compact mode (as opposed to normal or fullscreen mode). Must be set if the <c>mode</c> parameter of the <a href="https://corefork.telegram.org/api/links#main-mini-app-links">Main Mini App link</a> is equal to <c>compact</c>.</param>
/// <param name="fullscreen">If set, requests to open the mini app in fullscreen mode (as opposed to compact or normal mode). Must be set if the <c>mode</c> parameter of the <a href="https://corefork.telegram.org/api/links#main-mini-app-links">Main Mini App link</a> is equal to <c>fullscreen</c>.</param>
/// <param name="peer">Currently open chat, may be <see langword="null"/> if no chat is currently open.</param> /// <param name="peer">Currently open chat, may be <see langword="null"/> if no chat is currently open.</param>
/// <param name="bot">Bot that owns the main mini app.</param> /// <param name="bot">Bot that owns the main mini app.</param>
/// <param name="start_param">Start parameter, if opening from a <a href="https://corefork.telegram.org/api/links#main-mini-app-links">Main Mini App link »</a>.</param> /// <param name="start_param">Start parameter, if opening from a <a href="https://corefork.telegram.org/api/links#main-mini-app-links">Main Mini App link »</a>.</param>
@ -4321,7 +4326,7 @@ namespace TL
platform = platform, platform = platform,
}); });
/// <summary>Sends one or more <a href="https://corefork.telegram.org/api/reactions#paid-reactions">paid Telegram Star reactions »</a>, transferring <a href="https://corefork.telegram.org/api/stars">Telegram Stars »</a> to a channel's balance. <para>See <a href="https://corefork.telegram.org/method/messages.sendPaidReaction"/> [bots: ✓]</para></summary> /// <summary>Sends one or more <a href="https://corefork.telegram.org/api/reactions#paid-reactions">paid Telegram Star reactions »</a>, transferring <a href="https://corefork.telegram.org/api/stars">Telegram Stars »</a> to a channel's balance. <para>See <a href="https://corefork.telegram.org/method/messages.sendPaidReaction"/></para> <para>Possible <see cref="RpcException"/> codes: 400 (<a href="https://corefork.telegram.org/method/messages.sendPaidReaction#possible-errors">details</a>)</para></summary>
/// <param name="peer">The channel</param> /// <param name="peer">The channel</param>
/// <param name="msg_id">The message to react to</param> /// <param name="msg_id">The message to react to</param>
/// <param name="count">The number of <a href="https://corefork.telegram.org/api/stars">stars</a> to send (each will increment the reaction counter by one).</param> /// <param name="count">The number of <a href="https://corefork.telegram.org/api/stars">stars</a> to send (each will increment the reaction counter by one).</param>
@ -4338,7 +4343,7 @@ namespace TL
private_ = private_ ?? default, private_ = private_ ?? default,
}); });
/// <summary>Changes the privacy of already sent <a href="https://corefork.telegram.org/api/reactions#paid-reactions">paid reactions</a> on a specific message. <para>See <a href="https://corefork.telegram.org/method/messages.togglePaidReactionPrivacy"/> [bots: ✓]</para></summary> /// <summary>Changes the privacy of already sent <a href="https://corefork.telegram.org/api/reactions#paid-reactions">paid reactions</a> on a specific message. <para>See <a href="https://corefork.telegram.org/method/messages.togglePaidReactionPrivacy"/></para> <para>Possible <see cref="RpcException"/> codes: 400 (<a href="https://corefork.telegram.org/method/messages.togglePaidReactionPrivacy#possible-errors">details</a>)</para></summary>
/// <param name="peer">The channel</param> /// <param name="peer">The channel</param>
/// <param name="msg_id">The ID of the message to which we sent the paid reactions</param> /// <param name="msg_id">The ID of the message to which we sent the paid reactions</param>
/// <param name="private_">If true, makes the current anonymous in the top sender leaderboard for this message; otherwise, does the opposite.</param> /// <param name="private_">If true, makes the current anonymous in the top sender leaderboard for this message; otherwise, does the opposite.</param>
@ -4350,13 +4355,13 @@ namespace TL
private_ = private_, private_ = private_,
}); });
/// <summary>Fetches an <see cref="UpdatePaidReactionPrivacy"/> update with the current <a href="https://corefork.telegram.org/api/reactions#paid-reactions">default paid reaction privacy, see here »</a> for more info. <para>See <a href="https://corefork.telegram.org/method/messages.getPaidReactionPrivacy"/> [bots: ✓]</para></summary> /// <summary>Fetches an <see cref="UpdatePaidReactionPrivacy"/> update with the current <a href="https://corefork.telegram.org/api/reactions#paid-reactions">default paid reaction privacy, see here »</a> for more info. <para>See <a href="https://corefork.telegram.org/method/messages.getPaidReactionPrivacy"/></para></summary>
public static Task<UpdatesBase> Messages_GetPaidReactionPrivacy(this Client client) public static Task<UpdatesBase> Messages_GetPaidReactionPrivacy(this Client client)
=> client.Invoke(new Messages_GetPaidReactionPrivacy => client.Invoke(new Messages_GetPaidReactionPrivacy
{ {
}); });
/// <summary>Mark a specific <a href="https://corefork.telegram.org/api/sponsored-messages">sponsored message »</a> as read <para>See <a href="https://corefork.telegram.org/method/messages.viewSponsoredMessage"/> [bots: ✓]</para></summary> /// <summary>Mark a specific <a href="https://corefork.telegram.org/api/sponsored-messages">sponsored message »</a> as read <para>See <a href="https://corefork.telegram.org/method/messages.viewSponsoredMessage"/></para></summary>
/// <param name="peer">The channel/bot where the ad is located</param> /// <param name="peer">The channel/bot where the ad is located</param>
/// <param name="random_id">The ad's unique ID.</param> /// <param name="random_id">The ad's unique ID.</param>
public static Task<bool> Messages_ViewSponsoredMessage(this Client client, InputPeer peer, byte[] random_id) public static Task<bool> Messages_ViewSponsoredMessage(this Client client, InputPeer peer, byte[] random_id)
@ -4366,7 +4371,7 @@ namespace TL
random_id = random_id, random_id = random_id,
}); });
/// <summary>Informs the server that the user has interacted with a sponsored message in <a href="https://corefork.telegram.org/api/sponsored-messages#clicking-on-sponsored-messages">one of the ways listed here »</a>. <para>See <a href="https://corefork.telegram.org/method/messages.clickSponsoredMessage"/> [bots: ✓]</para></summary> /// <summary>Informs the server that the user has interacted with a sponsored message in <a href="https://corefork.telegram.org/api/sponsored-messages#clicking-on-sponsored-messages">one of the ways listed here »</a>. <para>See <a href="https://corefork.telegram.org/method/messages.clickSponsoredMessage"/></para></summary>
/// <param name="media">The user clicked on the media</param> /// <param name="media">The user clicked on the media</param>
/// <param name="fullscreen">The user expanded the video to full screen, and then clicked on it.</param> /// <param name="fullscreen">The user expanded the video to full screen, and then clicked on it.</param>
/// <param name="peer">The channel/bot where the ad is located</param> /// <param name="peer">The channel/bot where the ad is located</param>
@ -4379,7 +4384,7 @@ namespace TL
random_id = random_id, random_id = random_id,
}); });
/// <summary>Report a <a href="https://corefork.telegram.org/api/sponsored-messages">sponsored message »</a>, see <a href="https://corefork.telegram.org/api/sponsored-messages#reporting-sponsored-messages">here »</a> for more info on the full flow. <para>See <a href="https://corefork.telegram.org/method/messages.reportSponsoredMessage"/> [bots: ✓]</para></summary> /// <summary>Report a <a href="https://corefork.telegram.org/api/sponsored-messages">sponsored message »</a>, see <a href="https://corefork.telegram.org/api/sponsored-messages#reporting-sponsored-messages">here »</a> for more info on the full flow. <para>See <a href="https://corefork.telegram.org/method/messages.reportSponsoredMessage"/></para></summary>
/// <param name="peer">The channel/bot where the ad is located</param> /// <param name="peer">The channel/bot where the ad is located</param>
/// <param name="random_id">The ad's unique ID.</param> /// <param name="random_id">The ad's unique ID.</param>
/// <param name="option">Chosen report option, initially an empty string, see <a href="https://corefork.telegram.org/api/sponsored-messages#reporting-sponsored-messages">here »</a> for more info on the full flow.</param> /// <param name="option">Chosen report option, initially an empty string, see <a href="https://corefork.telegram.org/api/sponsored-messages#reporting-sponsored-messages">here »</a> for more info on the full flow.</param>
@ -4391,7 +4396,7 @@ namespace TL
option = option, option = option,
}); });
/// <summary>Get a list of <a href="https://corefork.telegram.org/api/sponsored-messages">sponsored messages for a peer, see here »</a> for more info. <para>See <a href="https://corefork.telegram.org/method/messages.getSponsoredMessages"/> [bots: ✓]</para></summary> /// <summary>Get a list of <a href="https://corefork.telegram.org/api/sponsored-messages">sponsored messages for a peer, see here »</a> for more info. <para>See <a href="https://corefork.telegram.org/method/messages.getSponsoredMessages"/></para></summary>
/// <param name="peer">The currently open channel/bot.</param> /// <param name="peer">The currently open channel/bot.</param>
/// <returns>a <c>null</c> value means <a href="https://corefork.telegram.org/constructor/messages.sponsoredMessagesEmpty">messages.sponsoredMessagesEmpty</a></returns> /// <returns>a <c>null</c> value means <a href="https://corefork.telegram.org/constructor/messages.sponsoredMessagesEmpty">messages.sponsoredMessagesEmpty</a></returns>
public static Task<Messages_SponsoredMessages> Messages_GetSponsoredMessages(this Client client, InputPeer peer) public static Task<Messages_SponsoredMessages> Messages_GetSponsoredMessages(this Client client, InputPeer peer)
@ -4400,7 +4405,10 @@ namespace TL
peer = peer, peer = peer,
}); });
/// <summary><para>See <a href="https://corefork.telegram.org/method/messages.savePreparedInlineMessage"/></para></summary> /// <summary>Save a <a href="https://corefork.telegram.org/api/bots/inline#21-using-a-prepared-inline-message">prepared inline message</a>, to be shared by the user of the mini app using a <a href="https://corefork.telegram.org/api/web-events#web-app-send-prepared-message">web_app_send_prepared_message event</a> <para>See <a href="https://corefork.telegram.org/method/messages.savePreparedInlineMessage"/> [bots: ✓]</para> <para>Possible <see cref="RpcException"/> codes: 400 (<a href="https://corefork.telegram.org/method/messages.savePreparedInlineMessage#possible-errors">details</a>)</para></summary>
/// <param name="result">The message</param>
/// <param name="user_id">The user to whom the <a href="https://corefork.telegram.org/api/web-events#web-app-send-prepared-message">web_app_send_prepared_message event</a> event will be sent</param>
/// <param name="peer_types">Types of chats where this message can be sent</param>
public static Task<Messages_BotPreparedInlineMessage> Messages_SavePreparedInlineMessage(this Client client, InputBotInlineResultBase result, InputUserBase user_id, InlineQueryPeerType[] peer_types = null) public static Task<Messages_BotPreparedInlineMessage> Messages_SavePreparedInlineMessage(this Client client, InputBotInlineResultBase result, InputUserBase user_id, InlineQueryPeerType[] peer_types = null)
=> client.Invoke(new Messages_SavePreparedInlineMessage => client.Invoke(new Messages_SavePreparedInlineMessage
{ {
@ -4410,7 +4418,9 @@ namespace TL
peer_types = peer_types, peer_types = peer_types,
}); });
/// <summary><para>See <a href="https://corefork.telegram.org/method/messages.getPreparedInlineMessage"/></para></summary> /// <summary>Obtain a <a href="https://corefork.telegram.org/api/bots/inline#21-using-a-prepared-inline-message">prepared inline message</a> generated by a <a href="https://corefork.telegram.org/api/bots/webapps">mini app</a>: invoked when handling <a href="https://corefork.telegram.org/api/web-events#web-app-send-prepared-message">web_app_send_prepared_message events</a> <para>See <a href="https://corefork.telegram.org/method/messages.getPreparedInlineMessage"/></para> <para>Possible <see cref="RpcException"/> codes: 400 (<a href="https://corefork.telegram.org/method/messages.getPreparedInlineMessage#possible-errors">details</a>)</para></summary>
/// <param name="bot">The bot that owns the mini app that emitted the <a href="https://corefork.telegram.org/api/web-events#web-app-send-prepared-message">web_app_send_prepared_message event</a></param>
/// <param name="id">The <c>id</c> from the <a href="https://corefork.telegram.org/api/web-events#web-app-send-prepared-message">web_app_send_prepared_message event</a></param>
public static Task<Messages_PreparedInlineMessage> Messages_GetPreparedInlineMessage(this Client client, InputUserBase bot, string id) public static Task<Messages_PreparedInlineMessage> Messages_GetPreparedInlineMessage(this Client client, InputUserBase bot, string id)
=> client.Invoke(new Messages_GetPreparedInlineMessage => client.Invoke(new Messages_GetPreparedInlineMessage
{ {
@ -4418,7 +4428,14 @@ namespace TL
id = id, id = id,
}); });
/// <summary><para>See <a href="https://corefork.telegram.org/method/messages.searchStickers"/></para></summary> /// <summary>Search for stickers using AI-powered keyword search <para>See <a href="https://corefork.telegram.org/method/messages.searchStickers"/></para></summary>
/// <param name="emojis">If set, returns <a href="https://corefork.telegram.org/api/custom-emoji">custom emoji stickers</a></param>
/// <param name="q">The search term</param>
/// <param name="emoticon">Space-separated list of emojis to search for</param>
/// <param name="lang_code">List of possible IETF language tags of the user's input language; may be empty if unknown</param>
/// <param name="offset"><a href="https://corefork.telegram.org/api/offsets">Offset for pagination</a></param>
/// <param name="limit">Maximum number of results to return, <a href="https://corefork.telegram.org/api/offsets">see pagination</a></param>
/// <param name="hash"><a href="https://corefork.telegram.org/api/offsets#hash-generation">Hash used for caching, for more info click here</a>. <br/>The hash may be generated locally by using the <c>id</c>s of the returned or stored sticker <see cref="Document"/>s.</param>
public static Task<Messages_FoundStickersBase> Messages_SearchStickers(this Client client, string q, string emoticon, string[] lang_code, int offset = default, int limit = int.MaxValue, long hash = default, bool emojis = false) public static Task<Messages_FoundStickersBase> Messages_SearchStickers(this Client client, string q, string emoticon, string[] lang_code, int offset = default, int limit = int.MaxValue, long hash = default, bool emojis = false)
=> client.Invoke(new Messages_SearchStickers => client.Invoke(new Messages_SearchStickers
{ {
@ -5756,7 +5773,9 @@ namespace TL
bot = bot, bot = bot,
}); });
/// <summary><para>See <a href="https://corefork.telegram.org/method/bots.updateUserEmojiStatus"/></para></summary> /// <summary>Change the emoji status of a user (invoked by bots, see <a href="https://corefork.telegram.org/api/emoji-status#setting-an-emoji-status-from-a-bot">here »</a> for more info on the full flow) <para>See <a href="https://corefork.telegram.org/method/bots.updateUserEmojiStatus"/> [bots: ✓]</para> <para>Possible <see cref="RpcException"/> codes: 400 (<a href="https://corefork.telegram.org/method/bots.updateUserEmojiStatus#possible-errors">details</a>)</para></summary>
/// <param name="user_id">The user whose emoji status should be changed</param>
/// <param name="emoji_status">The emoji status</param>
public static Task<bool> Bots_UpdateUserEmojiStatus(this Client client, InputUserBase user_id, EmojiStatus emoji_status) public static Task<bool> Bots_UpdateUserEmojiStatus(this Client client, InputUserBase user_id, EmojiStatus emoji_status)
=> client.Invoke(new Bots_UpdateUserEmojiStatus => client.Invoke(new Bots_UpdateUserEmojiStatus
{ {
@ -5764,7 +5783,9 @@ namespace TL
emoji_status = emoji_status, emoji_status = emoji_status,
}); });
/// <summary><para>See <a href="https://corefork.telegram.org/method/bots.toggleUserEmojiStatusPermission"/></para></summary> /// <summary>Allow or prevent a bot from <a href="https://corefork.telegram.org/api/emoji-status#setting-an-emoji-status-from-a-bot">changing our emoji status »</a> <para>See <a href="https://corefork.telegram.org/method/bots.toggleUserEmojiStatusPermission"/></para> <para>Possible <see cref="RpcException"/> codes: 400 (<a href="https://corefork.telegram.org/method/bots.toggleUserEmojiStatusPermission#possible-errors">details</a>)</para></summary>
/// <param name="bot">The bot</param>
/// <param name="enabled">Whether to allow or prevent the bot from changing our emoji status</param>
public static Task<bool> Bots_ToggleUserEmojiStatusPermission(this Client client, InputUserBase bot, bool enabled) public static Task<bool> Bots_ToggleUserEmojiStatusPermission(this Client client, InputUserBase bot, bool enabled)
=> client.Invoke(new Bots_ToggleUserEmojiStatusPermission => client.Invoke(new Bots_ToggleUserEmojiStatusPermission
{ {
@ -5772,7 +5793,10 @@ namespace TL
enabled = enabled, enabled = enabled,
}); });
/// <summary><para>See <a href="https://corefork.telegram.org/method/bots.checkDownloadFileParams"/></para></summary> /// <summary>Check if a <a href="https://corefork.telegram.org/api/bots/webapps">mini app</a> can request the download of a specific file: called when handling <a href="https://corefork.telegram.org/api/web-events#web-app-request-file-download">web_app_request_file_download events »</a> <para>See <a href="https://corefork.telegram.org/method/bots.checkDownloadFileParams"/></para> <para>Possible <see cref="RpcException"/> codes: 400 (<a href="https://corefork.telegram.org/method/bots.checkDownloadFileParams#possible-errors">details</a>)</para></summary>
/// <param name="bot">The bot that owns the <a href="https://corefork.telegram.org/api/bots/webapps">mini app</a> that requested the download</param>
/// <param name="file_name">The <c>filename</c> from the <a href="https://corefork.telegram.org/api/web-events#web-app-request-file-download">web_app_request_file_download event »</a></param>
/// <param name="url">The <c>url</c> from the <a href="https://corefork.telegram.org/api/web-events#web-app-request-file-download">web_app_request_file_download event »</a></param>
public static Task<bool> Bots_CheckDownloadFileParams(this Client client, InputUserBase bot, string file_name, string url) public static Task<bool> Bots_CheckDownloadFileParams(this Client client, InputUserBase bot, string file_name, string url)
=> client.Invoke(new Bots_CheckDownloadFileParams => client.Invoke(new Bots_CheckDownloadFileParams
{ {
@ -5781,13 +5805,16 @@ namespace TL
url = url, url = url,
}); });
/// <summary><para>See <a href="https://corefork.telegram.org/method/bots.getAdminedBots"/></para></summary> /// <summary>Get a list of bots owned by the current user <para>See <a href="https://corefork.telegram.org/method/bots.getAdminedBots"/></para></summary>
public static Task<UserBase[]> Bots_GetAdminedBots(this Client client) public static Task<UserBase[]> Bots_GetAdminedBots(this Client client)
=> client.Invoke(new Bots_GetAdminedBots => client.Invoke(new Bots_GetAdminedBots
{ {
}); });
/// <summary><para>See <a href="https://corefork.telegram.org/method/bots.updateStarRefProgram"/></para></summary> /// <summary>Create, edit or delete the <a href="https://corefork.telegram.org/api/bots/referrals">affiliate program</a> of a bot we own <para>See <a href="https://corefork.telegram.org/method/bots.updateStarRefProgram"/></para> <para>Possible <see cref="RpcException"/> codes: 400 (<a href="https://corefork.telegram.org/method/bots.updateStarRefProgram#possible-errors">details</a>)</para></summary>
/// <param name="bot">The bot</param>
/// <param name="commission_permille">The permille commission rate: it indicates the share of Telegram Stars received by affiliates for every transaction made by users they referred inside of the bot. <br/> The minimum and maximum values for this parameter are contained in the <a href="https://corefork.telegram.org/api/config#starref-min-commission-permille">starref_min_commission_permille</a> and <a href="https://corefork.telegram.org/api/config#starref-max-commission-permille">starref_max_commission_permille</a> client configuration parameters. <br/> Can be <c>0</c> to terminate the affiliate program.<br/> Both the duration and the commission may only be raised after creation of the program: to lower them, the program must first be terminated and a new one created.</param>
/// <param name="duration_months">Indicates the duration of the affiliate program; if not set, there is no expiration date.</param>
public static Task<StarRefProgram> Bots_UpdateStarRefProgram(this Client client, InputUserBase bot, int commission_permille, int? duration_months = null) public static Task<StarRefProgram> Bots_UpdateStarRefProgram(this Client client, InputUserBase bot, int commission_permille, int? duration_months = null)
=> client.Invoke(new Bots_UpdateStarRefProgram => client.Invoke(new Bots_UpdateStarRefProgram
{ {
@ -5799,7 +5826,7 @@ namespace TL
/// <summary>Get a payment form <para>See <a href="https://corefork.telegram.org/method/payments.getPaymentForm"/></para> <para>Possible <see cref="RpcException"/> codes: 400 (<a href="https://corefork.telegram.org/method/payments.getPaymentForm#possible-errors">details</a>)</para></summary> /// <summary>Get a payment form <para>See <a href="https://corefork.telegram.org/method/payments.getPaymentForm"/></para> <para>Possible <see cref="RpcException"/> codes: 400 (<a href="https://corefork.telegram.org/method/payments.getPaymentForm#possible-errors">details</a>)</para></summary>
/// <param name="invoice">Invoice</param> /// <param name="invoice">Invoice</param>
/// <param name="theme_params">A JSON object with the following keys, containing color theme information (integers, RGB24) to pass to the payment provider, to apply in eventual verification pages: <br/><c>bg_color</c> - Background color <br/><c>text_color</c> - Text color <br/><c>hint_color</c> - Hint text color <br/><c>link_color</c> - Link color <br/><c>button_color</c> - Button color <br/><c>button_text_color</c> - Button text color</param> /// <param name="theme_params"><a href="https://corefork.telegram.org/api/bots/webapps#theme-parameters">Theme parameters »</a></param>
public static Task<Payments_PaymentFormBase> Payments_GetPaymentForm(this Client client, InputInvoice invoice, DataJSON theme_params = null) public static Task<Payments_PaymentFormBase> Payments_GetPaymentForm(this Client client, InputInvoice invoice, DataJSON theme_params = null)
=> client.Invoke(new Payments_GetPaymentForm => client.Invoke(new Payments_GetPaymentForm
{ {
@ -6017,7 +6044,7 @@ namespace TL
peer = peer, peer = peer,
}); });
/// <summary>Withdraw funds from a channel or bot's <a href="https://corefork.telegram.org/api/stars#withdrawing-revenue">star balance »</a>. <para>See <a href="https://corefork.telegram.org/method/payments.getStarsRevenueWithdrawalUrl"/></para> <para>Possible <see cref="RpcException"/> codes: 400 (<a href="https://corefork.telegram.org/method/payments.getStarsRevenueWithdrawalUrl#possible-errors">details</a>)</para></summary> /// <summary>Withdraw funds from a channel or bot's <a href="https://corefork.telegram.org/api/stars#withdrawing-stars">star balance »</a>. <para>See <a href="https://corefork.telegram.org/method/payments.getStarsRevenueWithdrawalUrl"/></para> <para>Possible <see cref="RpcException"/> codes: 400 (<a href="https://corefork.telegram.org/method/payments.getStarsRevenueWithdrawalUrl#possible-errors">details</a>)</para></summary>
/// <param name="peer">Channel or bot from which to withdraw funds.</param> /// <param name="peer">Channel or bot from which to withdraw funds.</param>
/// <param name="stars">Amount of stars to withdraw.</param> /// <param name="stars">Amount of stars to withdraw.</param>
/// <param name="password">2FA password, see <a href="https://corefork.telegram.org/api/srp#using-the-2fa-password">here »</a> for more info.</param> /// <param name="password">2FA password, see <a href="https://corefork.telegram.org/api/srp#using-the-2fa-password">here »</a> for more info.</param>
@ -6029,7 +6056,7 @@ namespace TL
password = password, password = password,
}); });
/// <summary>Returns a URL for a Telegram Ad platform account that can be used to set up advertisements for channel/bot in <c>peer</c>, paid using the Telegram Stars owned by the specified <c>peer</c>, see <a href="https://corefork.telegram.org/api/stars#paying-for-ads">here »</a> for more info. <para>See <a href="https://corefork.telegram.org/method/payments.getStarsRevenueAdsAccountUrl"/></para> <para>Possible <see cref="RpcException"/> codes: 400 (<a href="https://corefork.telegram.org/method/payments.getStarsRevenueAdsAccountUrl#possible-errors">details</a>)</para></summary> /// <summary>Returns a URL for a Telegram Ad platform account that can be used to set up advertisements for channel/bot in <c>peer</c>, paid using the Telegram Stars owned by the specified <c>peer</c>, see <a href="https://corefork.telegram.org/api/stars#paying-for-ads">here »</a> for more info. <para>See <a href="https://corefork.telegram.org/method/payments.getStarsRevenueAdsAccountUrl"/></para> <para>Possible <see cref="RpcException"/> codes: 400,403 (<a href="https://corefork.telegram.org/method/payments.getStarsRevenueAdsAccountUrl#possible-errors">details</a>)</para></summary>
/// <param name="peer">Channel or bot that owns the stars.</param> /// <param name="peer">Channel or bot that owns the stars.</param>
public static Task<Payments_StarsRevenueAdsAccountUrl> Payments_GetStarsRevenueAdsAccountUrl(this Client client, InputPeer peer) public static Task<Payments_StarsRevenueAdsAccountUrl> Payments_GetStarsRevenueAdsAccountUrl(this Client client, InputPeer peer)
=> client.Invoke(new Payments_GetStarsRevenueAdsAccountUrl => client.Invoke(new Payments_GetStarsRevenueAdsAccountUrl
@ -6047,7 +6074,7 @@ namespace TL
id = id, id = id,
}); });
/// <summary>Obtain a list of <a href="https://corefork.telegram.org/api/stars#buying-or-gifting-stars">Telegram Stars gift options »</a> as <see cref="StarsGiftOption"/>s. <para>See <a href="https://corefork.telegram.org/method/payments.getStarsGiftOptions"/></para></summary> /// <summary>Obtain a list of <a href="https://corefork.telegram.org/api/stars#buying-or-gifting-stars">Telegram Stars gift options »</a> as <see cref="StarsGiftOption"/>s. <para>See <a href="https://corefork.telegram.org/method/payments.getStarsGiftOptions"/></para> <para>Possible <see cref="RpcException"/> codes: 400 (<a href="https://corefork.telegram.org/method/payments.getStarsGiftOptions#possible-errors">details</a>)</para></summary>
/// <param name="user_id">Receiver of the gift (optional).</param> /// <param name="user_id">Receiver of the gift (optional).</param>
public static Task<StarsGiftOption[]> Payments_GetStarsGiftOptions(this Client client, InputUserBase user_id = null) public static Task<StarsGiftOption[]> Payments_GetStarsGiftOptions(this Client client, InputUserBase user_id = null)
=> client.Invoke(new Payments_GetStarsGiftOptions => client.Invoke(new Payments_GetStarsGiftOptions
@ -6056,10 +6083,10 @@ namespace TL
user_id = user_id, user_id = user_id,
}); });
/// <summary>Obtain a list of active, expired or cancelled <a href="https://corefork.telegram.org/api/invites#paid-invite-links">Telegram Star subscriptions »</a>. <para>See <a href="https://corefork.telegram.org/method/payments.getStarsSubscriptions"/> [bots: ✓]</para></summary> /// <summary>Obtain a list of active, expired or cancelled <a href="https://corefork.telegram.org/api/invites#paid-invite-links">Telegram Star subscriptions »</a>. <para>See <a href="https://corefork.telegram.org/method/payments.getStarsSubscriptions"/></para> <para>Possible <see cref="RpcException"/> codes: 400 (<a href="https://corefork.telegram.org/method/payments.getStarsSubscriptions#possible-errors">details</a>)</para></summary>
/// <param name="missing_balance">Whether to return only expired subscriptions due to an excessively low Telegram Star balance.</param> /// <param name="missing_balance">Whether to return only subscriptions expired due to an excessively low Telegram Star balance.</param>
/// <param name="peer">Always pass <see cref="InputPeerSelf"/>.</param> /// <param name="peer">Always pass <see cref="InputPeerSelf"/>.</param>
/// <param name="offset">Offset for pagination, taken from <see cref="Payments_StarsStatus">payments.starsStatus</see>.</param> /// <param name="offset">Offset for pagination, taken from <see cref="Payments_StarsStatus"/>.<c>subscriptions_next_offset</c>.</param>
public static Task<Payments_StarsStatus> Payments_GetStarsSubscriptions(this Client client, InputPeer peer, string offset, bool missing_balance = false) public static Task<Payments_StarsStatus> Payments_GetStarsSubscriptions(this Client client, InputPeer peer, string offset, bool missing_balance = false)
=> client.Invoke(new Payments_GetStarsSubscriptions => client.Invoke(new Payments_GetStarsSubscriptions
{ {
@ -6068,7 +6095,7 @@ namespace TL
offset = offset, offset = offset,
}); });
/// <summary>Activate or deactivate a <a href="https://corefork.telegram.org/api/invites#paid-invite-links">Telegram Star subscription »</a>. <para>See <a href="https://corefork.telegram.org/method/payments.changeStarsSubscription"/> [bots: ✓]</para></summary> /// <summary>Activate or deactivate a <a href="https://corefork.telegram.org/api/invites#paid-invite-links">Telegram Star subscription »</a>. <para>See <a href="https://corefork.telegram.org/method/payments.changeStarsSubscription"/></para> <para>Possible <see cref="RpcException"/> codes: 400 (<a href="https://corefork.telegram.org/method/payments.changeStarsSubscription#possible-errors">details</a>)</para></summary>
/// <param name="peer">Always pass <see cref="InputPeerSelf"/>.</param> /// <param name="peer">Always pass <see cref="InputPeerSelf"/>.</param>
/// <param name="subscription_id">ID of the subscription.</param> /// <param name="subscription_id">ID of the subscription.</param>
/// <param name="canceled">Whether to cancel or reactivate the subscription.</param> /// <param name="canceled">Whether to cancel or reactivate the subscription.</param>
@ -6081,7 +6108,7 @@ namespace TL
canceled = canceled ?? default, canceled = canceled ?? default,
}); });
/// <summary>Re-join a private channel associated to an active <a href="https://corefork.telegram.org/api/invites#paid-invite-links">Telegram Star subscription »</a>. <para>See <a href="https://corefork.telegram.org/method/payments.fulfillStarsSubscription"/> [bots: ✓]</para></summary> /// <summary>Re-join a private channel associated to an active <a href="https://corefork.telegram.org/api/invites#paid-invite-links">Telegram Star subscription »</a>. <para>See <a href="https://corefork.telegram.org/method/payments.fulfillStarsSubscription"/></para> <para>Possible <see cref="RpcException"/> codes: 400 (<a href="https://corefork.telegram.org/method/payments.fulfillStarsSubscription#possible-errors">details</a>)</para></summary>
/// <param name="peer">Always pass <see cref="InputPeerSelf"/>.</param> /// <param name="peer">Always pass <see cref="InputPeerSelf"/>.</param>
/// <param name="subscription_id">ID of the subscription.</param> /// <param name="subscription_id">ID of the subscription.</param>
public static Task<bool> Payments_FulfillStarsSubscription(this Client client, InputPeer peer, string subscription_id) public static Task<bool> Payments_FulfillStarsSubscription(this Client client, InputPeer peer, string subscription_id)
@ -6091,14 +6118,14 @@ namespace TL
subscription_id = subscription_id, subscription_id = subscription_id,
}); });
/// <summary>Fetch a list of <a href="https://corefork.telegram.org/api/giveaways#star-giveaways">star giveaway options »</a>. <para>See <a href="https://corefork.telegram.org/method/payments.getStarsGiveawayOptions"/> [bots: ✓]</para></summary> /// <summary>Fetch a list of <a href="https://corefork.telegram.org/api/giveaways#star-giveaways">star giveaway options »</a>. <para>See <a href="https://corefork.telegram.org/method/payments.getStarsGiveawayOptions"/></para></summary>
public static Task<StarsGiveawayOption[]> Payments_GetStarsGiveawayOptions(this Client client) public static Task<StarsGiveawayOption[]> Payments_GetStarsGiveawayOptions(this Client client)
=> client.Invoke(new Payments_GetStarsGiveawayOptions => client.Invoke(new Payments_GetStarsGiveawayOptions
{ {
}); });
/// <summary>Get a list of available <a href="https://corefork.telegram.org/api/gifts">gifts, see here »</a> for more info. <para>See <a href="https://corefork.telegram.org/method/payments.getStarGifts"/> [bots: ✓]</para></summary> /// <summary>Get a list of available <a href="https://corefork.telegram.org/api/gifts">gifts, see here »</a> for more info. <para>See <a href="https://corefork.telegram.org/method/payments.getStarGifts"/></para></summary>
/// <param name="hash"><a href="https://corefork.telegram.org/api/offsets#hash-generation">Hash used for caching, for more info click here</a>.</param> /// <param name="hash"><a href="https://corefork.telegram.org/api/offsets#hash-generation">Hash used for caching, for more info click here</a>.<br/>The hash may be generated locally by using the <c>id</c>s of the returned or stored sticker <see cref="StarGift"/>s.</param>
/// <returns>a <c>null</c> value means <a href="https://corefork.telegram.org/constructor/payments.starGiftsNotModified">payments.starGiftsNotModified</a></returns> /// <returns>a <c>null</c> value means <a href="https://corefork.telegram.org/constructor/payments.starGiftsNotModified">payments.starGiftsNotModified</a></returns>
public static Task<Payments_StarGifts> Payments_GetStarGifts(this Client client, int hash = default) public static Task<Payments_StarGifts> Payments_GetStarGifts(this Client client, int hash = default)
=> client.Invoke(new Payments_GetStarGifts => client.Invoke(new Payments_GetStarGifts
@ -6106,7 +6133,7 @@ namespace TL
hash = hash, hash = hash,
}); });
/// <summary>Get the <a href="https://corefork.telegram.org/api/gifts">gifts »</a> pinned on a specific user's profile. <para>See <a href="https://corefork.telegram.org/method/payments.getUserStarGifts"/> [bots: ✓]</para></summary> /// <summary>Get the <a href="https://corefork.telegram.org/api/gifts">gifts »</a> pinned on a specific user's profile. <para>See <a href="https://corefork.telegram.org/method/payments.getUserStarGifts"/></para> <para>Possible <see cref="RpcException"/> codes: 400 (<a href="https://corefork.telegram.org/method/payments.getUserStarGifts#possible-errors">details</a>)</para></summary>
/// <param name="user_id">Identifier of the user (can be the current user to fetch all gifts received by the current user).</param> /// <param name="user_id">Identifier of the user (can be the current user to fetch all gifts received by the current user).</param>
/// <param name="offset">Offset for <a href="https://corefork.telegram.org/api/offsets">pagination</a>, taken from <see cref="Payments_UserStarGifts"/> (initially empty).</param> /// <param name="offset">Offset for <a href="https://corefork.telegram.org/api/offsets">pagination</a>, taken from <see cref="Payments_UserStarGifts"/> (initially empty).</param>
/// <param name="limit">Maximum number of results to return, <a href="https://corefork.telegram.org/api/offsets">see pagination</a></param> /// <param name="limit">Maximum number of results to return, <a href="https://corefork.telegram.org/api/offsets">see pagination</a></param>
@ -6118,7 +6145,7 @@ namespace TL
limit = limit, limit = limit,
}); });
/// <summary>Display or remove a <a href="https://corefork.telegram.org/api/gifts">received gift »</a> from our profile. <para>See <a href="https://corefork.telegram.org/method/payments.saveStarGift"/> [bots: ✓]</para></summary> /// <summary>Display or remove a <a href="https://corefork.telegram.org/api/gifts">received gift »</a> from our profile. <para>See <a href="https://corefork.telegram.org/method/payments.saveStarGift"/></para> <para>Possible <see cref="RpcException"/> codes: 400 (<a href="https://corefork.telegram.org/method/payments.saveStarGift#possible-errors">details</a>)</para></summary>
/// <param name="unsave">If set, hides the gift from our profile.</param> /// <param name="unsave">If set, hides the gift from our profile.</param>
/// <param name="user_id">ID of the user that sent us the gift.</param> /// <param name="user_id">ID of the user that sent us the gift.</param>
/// <param name="msg_id">The ID of the <see cref="MessageService"/> with the <see cref="MessageActionStarGift"/>.</param> /// <param name="msg_id">The ID of the <see cref="MessageService"/> with the <see cref="MessageActionStarGift"/>.</param>
@ -6130,7 +6157,7 @@ namespace TL
msg_id = msg_id, msg_id = msg_id,
}); });
/// <summary>Convert a <a href="https://corefork.telegram.org/api/gifts">received gift »</a> into Telegram Stars: this will permanently destroy the gift, converting it into <see cref="StarGift"/>.<c>convert_stars</c> <a href="https://corefork.telegram.org/api/stars">Telegram Stars</a>, added to the user's balance. <para>See <a href="https://corefork.telegram.org/method/payments.convertStarGift"/> [bots: ✓]</para></summary> /// <summary>Convert a <a href="https://corefork.telegram.org/api/gifts">received gift »</a> into Telegram Stars: this will permanently destroy the gift, converting it into <see cref="StarGift"/>.<c>convert_stars</c> <a href="https://corefork.telegram.org/api/stars">Telegram Stars</a>, added to the user's balance. <para>See <a href="https://corefork.telegram.org/method/payments.convertStarGift"/></para> <para>Possible <see cref="RpcException"/> codes: 400 (<a href="https://corefork.telegram.org/method/payments.convertStarGift#possible-errors">details</a>)</para></summary>
/// <param name="user_id">ID of the user that sent us the gift.</param> /// <param name="user_id">ID of the user that sent us the gift.</param>
/// <param name="msg_id">The ID of the <see cref="MessageService"/> with the <see cref="MessageActionStarGift"/>.</param> /// <param name="msg_id">The ID of the <see cref="MessageService"/> with the <see cref="MessageActionStarGift"/>.</param>
public static Task<bool> Payments_ConvertStarGift(this Client client, InputUserBase user_id, int msg_id) public static Task<bool> Payments_ConvertStarGift(this Client client, InputUserBase user_id, int msg_id)
@ -6140,7 +6167,10 @@ namespace TL
msg_id = msg_id, msg_id = msg_id,
}); });
/// <summary><para>See <a href="https://corefork.telegram.org/method/payments.botCancelStarsSubscription"/></para></summary> /// <summary>Cancel a <a href="https://corefork.telegram.org/api/subscriptions#bot-subscriptions">bot subscription</a> <para>See <a href="https://corefork.telegram.org/method/payments.botCancelStarsSubscription"/></para> <para>Possible <see cref="RpcException"/> codes: 400 (<a href="https://corefork.telegram.org/method/payments.botCancelStarsSubscription#possible-errors">details</a>)</para></summary>
/// <param name="restore">If <strong>not</strong> set, disables autorenewal of the subscriptions, and prevents the user from reactivating the subscription once the current period expires: a subscription cancelled by the bot will have the <see cref="StarsSubscription"/>.<c>bot_canceled</c> flag set. <br/>The bot can can partially undo this operation by setting this flag: this will allow the user to reactivate the subscription.</param>
/// <param name="user_id">The ID of the user whose subscription should be (un)cancelled</param>
/// <param name="charge_id">The <c>provider_charge_id</c> from the <see cref="MessageActionPaymentSentMe"/> service message sent to the bot for the first subscription payment.</param>
public static Task<bool> Payments_BotCancelStarsSubscription(this Client client, InputUserBase user_id, string charge_id, bool restore = false) public static Task<bool> Payments_BotCancelStarsSubscription(this Client client, InputUserBase user_id, string charge_id, bool restore = false)
=> client.Invoke(new Payments_BotCancelStarsSubscription => client.Invoke(new Payments_BotCancelStarsSubscription
{ {
@ -6149,7 +6179,11 @@ namespace TL
charge_id = charge_id, charge_id = charge_id,
}); });
/// <summary><para>See <a href="https://corefork.telegram.org/method/payments.getConnectedStarRefBots"/></para></summary> /// <summary>Fetch all affiliations we have created for a certain peer <para>See <a href="https://corefork.telegram.org/method/payments.getConnectedStarRefBots"/></para></summary>
/// <param name="peer">The affiliated peer</param>
/// <param name="offset_date">If set, returns only results older than the specified unixtime</param>
/// <param name="offset_link">Offset for <a href="https://corefork.telegram.org/api/offsets">pagination</a>, taken from the last returned <see cref="ConnectedBotStarRef"/>.<c>url</c> (initially empty)</param>
/// <param name="limit">Maximum number of results to return, <a href="https://corefork.telegram.org/api/offsets">see pagination</a></param>
public static Task<Payments_ConnectedStarRefBots> Payments_GetConnectedStarRefBots(this Client client, InputPeer peer, int limit = int.MaxValue, DateTime? offset_date = null, string offset_link = null) public static Task<Payments_ConnectedStarRefBots> Payments_GetConnectedStarRefBots(this Client client, InputPeer peer, int limit = int.MaxValue, DateTime? offset_date = null, string offset_link = null)
=> client.Invoke(new Payments_GetConnectedStarRefBots => client.Invoke(new Payments_GetConnectedStarRefBots
{ {
@ -6160,7 +6194,9 @@ namespace TL
limit = limit, limit = limit,
}); });
/// <summary><para>See <a href="https://corefork.telegram.org/method/payments.getConnectedStarRefBot"/></para></summary> /// <summary>Fetch info about a specific <a href="https://corefork.telegram.org/api/bots/referrals">bot affiliation »</a> <para>See <a href="https://corefork.telegram.org/method/payments.getConnectedStarRefBot"/></para> <para>Possible <see cref="RpcException"/> codes: 400 (<a href="https://corefork.telegram.org/method/payments.getConnectedStarRefBot#possible-errors">details</a>)</para></summary>
/// <param name="peer">The affiliated peer</param>
/// <param name="bot">The bot that offers the affiliate program</param>
public static Task<Payments_ConnectedStarRefBots> Payments_GetConnectedStarRefBot(this Client client, InputPeer peer, InputUserBase bot) public static Task<Payments_ConnectedStarRefBots> Payments_GetConnectedStarRefBot(this Client client, InputPeer peer, InputUserBase bot)
=> client.Invoke(new Payments_GetConnectedStarRefBot => client.Invoke(new Payments_GetConnectedStarRefBot
{ {
@ -6168,7 +6204,12 @@ namespace TL
bot = bot, bot = bot,
}); });
/// <summary><para>See <a href="https://corefork.telegram.org/method/payments.getSuggestedStarRefBots"/></para></summary> /// <summary>Obtain a list of suggested <a href="https://corefork.telegram.org/api/bots/webapps">mini apps</a> with available <a href="https://corefork.telegram.org/api/bots/referrals">affiliate programs</a> <para>See <a href="https://corefork.telegram.org/method/payments.getSuggestedStarRefBots"/></para> <para>Possible <see cref="RpcException"/> codes: 403 (<a href="https://corefork.telegram.org/method/payments.getSuggestedStarRefBots#possible-errors">details</a>)</para></summary>
/// <param name="order_by_revenue">If set, orders results by the expected revenue</param>
/// <param name="order_by_date">If set, orders results by the creation date of the affiliate program</param>
/// <param name="peer">The peer that will become the affiliate: star commissions will be transferred to this peer's star balance.</param>
/// <param name="offset">Offset for pagination, taken from <see cref="Payments_SuggestedStarRefBots"/>.<c>next_offset</c>, initially empty.</param>
/// <param name="limit">Maximum number of results to return, <a href="https://corefork.telegram.org/api/offsets">see pagination</a></param>
public static Task<Payments_SuggestedStarRefBots> Payments_GetSuggestedStarRefBots(this Client client, InputPeer peer, string offset, int limit = int.MaxValue, bool order_by_revenue = false, bool order_by_date = false) public static Task<Payments_SuggestedStarRefBots> Payments_GetSuggestedStarRefBots(this Client client, InputPeer peer, string offset, int limit = int.MaxValue, bool order_by_revenue = false, bool order_by_date = false)
=> client.Invoke(new Payments_GetSuggestedStarRefBots => client.Invoke(new Payments_GetSuggestedStarRefBots
{ {
@ -6178,7 +6219,9 @@ namespace TL
limit = limit, limit = limit,
}); });
/// <summary><para>See <a href="https://corefork.telegram.org/method/payments.connectStarRefBot"/></para></summary> /// <summary>Join a bot's <a href="https://corefork.telegram.org/api/bots/referrals#becoming-an-affiliate">affiliate program, becoming an affiliate »</a> <para>See <a href="https://corefork.telegram.org/method/payments.connectStarRefBot"/></para></summary>
/// <param name="peer">The peer that will become the affiliate: star commissions will be transferred to this peer's star balance.</param>
/// <param name="bot">The bot that offers the affiliate program</param>
public static Task<Payments_ConnectedStarRefBots> Payments_ConnectStarRefBot(this Client client, InputPeer peer, InputUserBase bot) public static Task<Payments_ConnectedStarRefBots> Payments_ConnectStarRefBot(this Client client, InputPeer peer, InputUserBase bot)
=> client.Invoke(new Payments_ConnectStarRefBot => client.Invoke(new Payments_ConnectStarRefBot
{ {
@ -6186,7 +6229,10 @@ namespace TL
bot = bot, bot = bot,
}); });
/// <summary><para>See <a href="https://corefork.telegram.org/method/payments.editConnectedStarRefBot"/></para></summary> /// <summary>Leave a bot's <a href="https://corefork.telegram.org/api/bots/referrals#becoming-an-affiliate">affiliate program »</a> <para>See <a href="https://corefork.telegram.org/method/payments.editConnectedStarRefBot"/></para> <para>Possible <see cref="RpcException"/> codes: 400 (<a href="https://corefork.telegram.org/method/payments.editConnectedStarRefBot#possible-errors">details</a>)</para></summary>
/// <param name="revoked">If set, leaves the bot's affiliate program</param>
/// <param name="peer">The peer that was affiliated</param>
/// <param name="link">The affiliate link to revoke</param>
public static Task<Payments_ConnectedStarRefBots> Payments_EditConnectedStarRefBot(this Client client, InputPeer peer, string link, bool revoked = false) public static Task<Payments_ConnectedStarRefBots> Payments_EditConnectedStarRefBot(this Client client, InputPeer peer, string link, bool revoked = false)
=> client.Invoke(new Payments_EditConnectedStarRefBot => client.Invoke(new Payments_EditConnectedStarRefBot
{ {

View file

@ -42,11 +42,8 @@ namespace TL
/// <summary>Indicates the location of a photo, will be deprecated soon <para>See <a href="https://corefork.telegram.org/type/FileLocation"/></para></summary> /// <summary>Indicates the location of a photo, will be deprecated soon <para>See <a href="https://corefork.telegram.org/type/FileLocation"/></para></summary>
public abstract partial class FileLocationBase : IObject public abstract partial class FileLocationBase : IObject
{ {
/// <summary>Server volume</summary>
public virtual long VolumeId => default; public virtual long VolumeId => default;
/// <summary>File ID</summary>
public virtual int LocalId => default; public virtual int LocalId => default;
/// <summary>Checksum to access the file</summary>
public virtual long Secret => default; public virtual long Secret => default;
} }
@ -501,38 +498,25 @@ namespace TL
[TLDef(0x7C596B46)] [TLDef(0x7C596B46)]
public sealed partial class FileLocationUnavailable : FileLocationBase public sealed partial class FileLocationUnavailable : FileLocationBase
{ {
/// <summary>Server volume</summary>
public long volume_id; public long volume_id;
/// <summary>File ID</summary>
public int local_id; public int local_id;
/// <summary>Checksum to access the file</summary>
public long secret; public long secret;
/// <summary>Server volume</summary>
public override long VolumeId => volume_id; public override long VolumeId => volume_id;
/// <summary>File ID</summary>
public override int LocalId => local_id; public override int LocalId => local_id;
/// <summary>Checksum to access the file</summary>
public override long Secret => secret; public override long Secret => secret;
} }
/// <summary>File location. <para>See <a href="https://corefork.telegram.org/constructor/fileLocation"/></para></summary> /// <summary>File location. <para>See <a href="https://corefork.telegram.org/constructor/fileLocation"/></para></summary>
[TLDef(0x53D69076)] [TLDef(0x53D69076)]
public sealed partial class FileLocation : FileLocationBase public sealed partial class FileLocation : FileLocationBase
{ {
/// <summary>Number of the data center holding the file</summary>
public int dc_id; public int dc_id;
/// <summary>Server volume</summary>
public long volume_id; public long volume_id;
/// <summary>File ID</summary>
public int local_id; public int local_id;
/// <summary>Checksum to access the file</summary>
public long secret; public long secret;
/// <summary>Server volume</summary>
public override long VolumeId => volume_id; public override long VolumeId => volume_id;
/// <summary>File ID</summary>
public override int LocalId => local_id; public override int LocalId => local_id;
/// <summary>Checksum to access the file</summary>
public override long Secret => secret; public override long Secret => secret;
} }
} }