From 253249e06aec175aac1f4dd3223272f09f782718 Mon Sep 17 00:00:00 2001
From: Wizou <11647984+wiz0u@users.noreply.github.com>
Date: Mon, 1 Sep 2025 13:37:41 +0200
Subject: [PATCH] API Layer 214: ChatTheme, main ProfileTab, user saved music,
some StarGift & Store Payment stuff...
(that might not be the most recent API layer. check https://patreon.com/wizou for the latest layers)
---
README.md | 2 +-
src/TL.Schema.cs | 233 ++++++++++++++++++++++++++++++++++---
src/TL.SchemaFuncs.cs | 159 +++++++++++++++++++++++--
src/TL.Table.cs | 42 +++++--
src/WTelegramClient.csproj | 4 +-
5 files changed, 398 insertions(+), 42 deletions(-)
diff --git a/README.md b/README.md
index 8bb243f..d085aeb 100644
--- a/README.md
+++ b/README.md
@@ -1,4 +1,4 @@
-[](https://corefork.telegram.org/methods)
+[](https://corefork.telegram.org/methods)
[](https://www.nuget.org/packages/WTelegramClient/)
[](https://www.nuget.org/packages/WTelegramClient/absoluteLatest)
[](https://buymeacoffee.com/wizou)
diff --git a/src/TL.Schema.cs b/src/TL.Schema.cs
index 299c969..08737fd 100644
--- a/src/TL.Schema.cs
+++ b/src/TL.Schema.cs
@@ -1402,7 +1402,7 @@ namespace TL
public override int ReactionsLimit => reactions_limit;
}
/// Full info about a channel, supergroup or gigagroup. See
- [TLDef(0xE07429DE)]
+ [TLDef(0xE4E0B29D)]
public sealed partial class ChannelFull : ChatFullBase
{
/// Extra bits of information, use flags.HasFlag(...) to test for those
@@ -1495,6 +1495,7 @@ namespace TL
[IfFlag(50)] public int stargifts_count;
/// If set and bigger than 0, this supergroup, monoforum or the monoforum associated to this channel has enabled paid messages » and we must pay the specified amount of Stars to send messages to it, see here » for the full flow.
This flag will be set both for the monoforum and for of the associated channel).
If set and equal to 0, the monoforum requires payment in general but we were exempted from paying.
[IfFlag(53)] public long send_paid_messages_stars;
+ [IfFlag(54)] public ProfileTab main_tab;
[Flags] public enum Flags : uint
{
@@ -1606,6 +1607,8 @@ namespace TL
paid_messages_available = 0x100000,
/// Field has a value
has_send_paid_messages_stars = 0x200000,
+ /// Field has a value
+ has_main_tab = 0x400000,
}
/// ID of the channel
@@ -2646,11 +2649,10 @@ namespace TL
public DateTime schedule_date;
}
/// The chat theme was changed See
- [TLDef(0xAA786345)]
+ [TLDef(0xB91BBD3A)]
public sealed partial class MessageActionSetChatTheme : MessageAction
{
- /// The emoji that identifies a chat theme
- public string emoticon;
+ public ChatThemeBase theme;
}
/// A user was accepted into the group by an admin See
[TLDef(0xEBBCA3CB)]
@@ -2934,7 +2936,7 @@ namespace TL
}
}
/// You received a gift, see here » for more info. See
- [TLDef(0x4717E8A4)]
+ [TLDef(0xF24DE7FA)]
public sealed partial class MessageActionStarGift : MessageAction
{
/// Extra bits of information, use flags.HasFlag(...) to test for those
@@ -2954,6 +2956,8 @@ namespace TL
[IfFlag(12)] public Peer peer;
/// For channel gifts, ID to use in s.
[IfFlag(12)] public long saved_id;
+ [IfFlag(14)] public string prepaid_upgrade_hash;
+ [IfFlag(15)] public int gift_msg_id;
[Flags] public enum Flags : uint
{
@@ -2979,6 +2983,12 @@ namespace TL
has_from_id = 0x800,
/// Fields and have a value
has_peer = 0x1000,
+ prepaid_upgrade = 0x2000,
+ /// Field has a value
+ has_prepaid_upgrade_hash = 0x4000,
+ /// Field has a value
+ has_gift_msg_id = 0x8000,
+ upgrade_separate = 0x10000,
}
}
/// A gift » was upgraded to a collectible gift ». See
@@ -3028,6 +3038,7 @@ namespace TL
has_can_transfer_at = 0x200,
/// Field has a value
has_can_resell_at = 0x400,
+ prepaid_upgrade = 0x800,
}
}
/// See
@@ -3422,11 +3433,13 @@ namespace TL
public Auth_AuthorizationBase authorization;
}
/// See
- [TLDef(0xD7CEF980)]
+ [TLDef(0xD7A2FCF9)]
public sealed partial class Auth_SentCodePaymentRequired : Auth_SentCodeBase
{
public string store_product;
public string phone_code_hash;
+ public string support_email_address;
+ public string support_email_subject;
}
/// Object contains info on user authorization. See Derived classes: ,
@@ -3769,7 +3782,7 @@ namespace TL
}
/// Extended user info See
- [TLDef(0x7E63CE1F)]
+ [TLDef(0xC577B5AD)]
public sealed partial class UserFull : IObject
{
/// Extra bits of information, use flags.HasFlag(...) to test for those
@@ -3800,8 +3813,7 @@ namespace TL
[IfFlag(11)] public int folder_id;
/// Time To Live of all messages in this chat; once a message is this many seconds old, it must be deleted.
[IfFlag(14)] public int ttl_period;
- /// Emoji associated with chat theme
- [IfFlag(15)] public string theme_emoticon;
+ [IfFlag(15)] public ChatThemeBase theme;
/// Anonymized text to be shown instead of the user's name on forwarded messages
[IfFlag(16)] public string private_forward_name;
/// A suggested set of administrator rights for the bot, to be shown when adding the bot as admin to a group, see here for more info on how to handle them ».
@@ -3839,6 +3851,8 @@ namespace TL
[IfFlag(49)] public StarsRating stars_rating;
[IfFlag(50)] public StarsRating stars_my_pending_rating;
[IfFlag(50)] public DateTime stars_my_pending_rating_date;
+ [IfFlag(52)] public ProfileTab main_tab;
+ [IfFlag(53)] public DocumentBase saved_music;
[Flags] public enum Flags : uint
{
@@ -3866,8 +3880,8 @@ namespace TL
video_calls_available = 0x2000,
/// Field has a value
has_ttl_period = 0x4000,
- /// Field has a value
- has_theme_emoticon = 0x8000,
+ /// Field has a value
+ has_theme = 0x8000,
/// Field has a value
has_private_forward_name = 0x10000,
/// Field has a value
@@ -3935,6 +3949,10 @@ namespace TL
has_stars_rating = 0x20000,
/// Fields and have a value
has_stars_my_pending_rating = 0x40000,
+ /// Field has a value
+ has_main_tab = 0x100000,
+ /// Field has a value
+ has_saved_music = 0x200000,
}
}
@@ -15534,6 +15552,42 @@ namespace TL
[TLDef(0xE926D63E)]
public sealed partial class Account_ResetPasswordOk : Account_ResetPasswordResult { }
+ /// See
+ public abstract partial class ChatThemeBase : IObject { }
+ /// See
+ [TLDef(0xC3DFFC04)]
+ public sealed partial class ChatTheme : ChatThemeBase
+ {
+ public string emoticon;
+ }
+ /// See
+ [TLDef(0x3458F9C8)]
+ public sealed partial class ChatThemeUniqueGift : ChatThemeBase
+ {
+ public StarGiftBase gift;
+ public ThemeSettings[] theme_settings;
+ }
+
+ /// See
+ /// a value means account.chatThemesNotModified
+ [TLDef(0x16484857)]
+ public sealed partial class Account_ChatThemes : IObject, IPeerResolver
+ {
+ public Flags flags;
+ public long hash;
+ public ChatThemeBase[] themes;
+ public Dictionary chats;
+ public Dictionary users;
+ [IfFlag(0)] public int next_offset;
+
+ [Flags] public enum Flags : uint
+ {
+ has_next_offset = 0x1,
+ }
+ /// returns a or for the given Peer
+ public IPeerInfo UserOrChat(Peer peer) => peer?.UserOrChat(users, chats);
+ }
+
/// A sponsored message. See
[TLDef(0x7DBF8673)]
public sealed partial class SponsoredMessage : IObject
@@ -16243,6 +16297,13 @@ namespace TL
ton = 0x1,
}
}
+ /// See
+ [TLDef(0x9A0B48B8)]
+ public sealed partial class InputInvoiceStarGiftPrepaidUpgrade : InputInvoice
+ {
+ public InputPeer peer;
+ public string hash;
+ }
/// Exported invoice deep link See
[TLDef(0xAED0CBD9)]
@@ -16385,15 +16446,23 @@ namespace TL
}
}
/// Used to top up the Telegram Stars balance of the current account. See
- [TLDef(0xDDDD0F56)]
+ [TLDef(0xF9A2A6CB)]
public sealed partial class InputStorePaymentStarsTopup : InputStorePaymentPurpose
{
+ public Flags flags;
/// Amount of stars to topup
public long stars;
/// Three-letter ISO 4217 currency code
public string currency;
/// Total price in the smallest units of the currency (integer, not float/double). For example, for a price of US$ 1.45 pass amount = 145. See the exp parameter in currencies.json, it shows the number of digits past the decimal point for each currency (2 for the majority of currencies).
public long amount;
+ [IfFlag(0)] public InputPeer spend_purpose_peer;
+
+ [Flags] public enum Flags : uint
+ {
+ /// Field has a value
+ has_spend_purpose_peer = 0x1,
+ }
}
/// Used to gift Telegram Stars to a friend. See
[TLDef(0x1D741EF7)]
@@ -19768,6 +19837,7 @@ namespace TL
/// Fields and have a value
has_ads_proceeds_from_date = 0x800000,
posts_search = 0x1000000,
+ stargift_prepaid_upgrade = 0x2000000,
}
}
@@ -20149,7 +20219,7 @@ namespace TL
public virtual Peer ReleasedBy => default;
}
/// Represents a star gift, see here » for more info. See
- [TLDef(0x00BCFF5B)]
+ [TLDef(0x80AC53C3)]
public sealed partial class StarGift : StarGiftBase
{
/// Extra bits of information, use flags.HasFlag(...) to test for those
@@ -20177,6 +20247,7 @@ namespace TL
[IfFlag(6)] public Peer released_by;
[IfFlag(8)] public int per_user_total;
[IfFlag(8)] public int per_user_remains;
+ [IfFlag(9)] public DateTime locked_until_date;
[Flags] public enum Flags : uint
{
@@ -20196,6 +20267,8 @@ namespace TL
has_released_by = 0x40,
require_premium = 0x80,
limited_per_user = 0x100,
+ /// Field has a value
+ has_locked_until_date = 0x200,
}
/// Identifier of the gift
@@ -20206,13 +20279,14 @@ namespace TL
public override Peer ReleasedBy => released_by;
}
/// Represents a collectible star gift, see here » for more info. See
- [TLDef(0x3A274D50)]
+ [TLDef(0x1BEFE865)]
public sealed partial class StarGiftUnique : StarGiftBase
{
/// Extra bits of information, use flags.HasFlag(...) to test for those
public Flags flags;
/// Identifier of the gift.
public long id;
+ public long gift_id;
public string title;
public string slug;
public int num;
@@ -20225,6 +20299,9 @@ namespace TL
[IfFlag(3)] public string gift_address;
[IfFlag(4)] public StarsAmountBase[] resell_amount;
[IfFlag(5)] public Peer released_by;
+ [IfFlag(8)] public long value_amount;
+ [IfFlag(8)] public string value_currency;
+ [IfFlag(10)] public Peer theme_peer;
[Flags] public enum Flags : uint
{
@@ -20242,6 +20319,11 @@ namespace TL
has_released_by = 0x20,
require_premium = 0x40,
resale_ton_only = 0x80,
+ /// Fields and have a value
+ has_value_amount = 0x100,
+ theme_available = 0x200,
+ /// Field has a value
+ has_theme_peer = 0x400,
}
/// Identifier of the gift.
@@ -20636,23 +20718,29 @@ namespace TL
}
/// See
- [TLDef(0xCAA2F60B)]
- public sealed partial class Payments_UniqueStarGift : IObject
+ [TLDef(0x416C56E8)]
+ public sealed partial class Payments_UniqueStarGift : IObject, IPeerResolver
{
public StarGiftBase gift;
+ public Dictionary chats;
public Dictionary users;
+ /// returns a or for the given Peer
+ public IPeerInfo UserOrChat(Peer peer) => peer?.UserOrChat(users, chats);
}
/// See
- [TLDef(0xB53E8B21)]
- public sealed partial class Messages_WebPagePreview : IObject
+ [TLDef(0x8C9A88AC)]
+ public sealed partial class Messages_WebPagePreview : IObject, IPeerResolver
{
public MessageMedia media;
+ public Dictionary chats;
public Dictionary users;
+ /// returns a or for the given Peer
+ public IPeerInfo UserOrChat(Peer peer) => peer?.UserOrChat(users, chats);
}
/// See
- [TLDef(0x1EA646DF)]
+ [TLDef(0x19A9B572)]
public sealed partial class SavedStarGift : IObject
{
/// Extra bits of information, use flags.HasFlag(...) to test for those
@@ -20670,6 +20758,7 @@ namespace TL
[IfFlag(13)] public DateTime can_transfer_at;
[IfFlag(14)] public DateTime can_resell_at;
[IfFlag(15)] public int[] collection_id;
+ [IfFlag(16)] public string prepaid_upgrade_hash;
[Flags] public enum Flags : uint
{
@@ -20700,6 +20789,9 @@ namespace TL
has_can_resell_at = 0x4000,
/// Field has a value
has_collection_id = 0x8000,
+ /// Field has a value
+ has_prepaid_upgrade_hash = 0x10000,
+ upgrade_separate = 0x20000,
}
}
@@ -21087,4 +21179,107 @@ namespace TL
has_wait_till = 0x2,
}
}
+
+ /// See
+ [TLDef(0x512FE446)]
+ public sealed partial class Payments_UniqueStarGiftValueInfo : IObject
+ {
+ public Flags flags;
+ public string currency;
+ public long value;
+ public DateTime initial_sale_date;
+ public long initial_sale_stars;
+ public long initial_sale_price;
+ [IfFlag(0)] public DateTime last_sale_date;
+ [IfFlag(0)] public long last_sale_price;
+ [IfFlag(2)] public long floor_price;
+ [IfFlag(3)] public long average_price;
+ [IfFlag(4)] public int listed_count;
+ [IfFlag(5)] public int fragment_listed_count;
+ [IfFlag(5)] public string fragment_listed_url;
+
+ [Flags] public enum Flags : uint
+ {
+ has_last_sale_date = 0x1,
+ last_sale_on_fragment = 0x2,
+ has_floor_price = 0x4,
+ has_average_price = 0x8,
+ has_listed_count = 0x10,
+ has_fragment_listed_count = 0x20,
+ value_is_average = 0x40,
+ }
+ }
+
+ /// See
+ public enum ProfileTab : uint
+ {
+ ///See
+ Posts = 0xB98CD696,
+ ///See
+ Gifts = 0x4D4BD46A,
+ ///See
+ Media = 0x72C64955,
+ ///See
+ Files = 0xAB339C00,
+ ///See
+ Music = 0x9F27D26E,
+ ///See
+ Voice = 0xE477092E,
+ ///See
+ Links = 0xD3656499,
+ ///See
+ Gifs = 0xA2C0F695,
+ }
+
+ /// See
+ public abstract partial class Users_SavedMusicBase : IObject { }
+ /// See
+ [TLDef(0xE3878AA4)]
+ public sealed partial class Users_SavedMusicNotModified : Users_SavedMusicBase
+ {
+ public int count;
+ }
+ /// See
+ [TLDef(0x34A2F297)]
+ public sealed partial class Users_SavedMusic : Users_SavedMusicBase
+ {
+ public int count;
+ public DocumentBase[] documents;
+ }
+
+ /// See
+ /// a value means account.savedMusicIdsNotModified
+ [TLDef(0x998D6636)]
+ public sealed partial class Account_SavedMusicIds : IObject
+ {
+ public long[] ids;
+ }
+
+ /// See
+ public abstract partial class Payments_CheckCanSendGiftResult : IObject { }
+ /// See
+ [TLDef(0x374FA7AD)]
+ public sealed partial class Payments_CheckCanSendGiftResultOk : Payments_CheckCanSendGiftResult { }
+ /// See
+ [TLDef(0xD5E58274)]
+ public sealed partial class Payments_CheckCanSendGiftResultFail : Payments_CheckCanSendGiftResult
+ {
+ public TextWithEntities reason;
+ }
+
+ /// See
+ /// a value means inputChatThemeEmpty
+ public abstract partial class InputChatThemeBase : IObject { }
+ /// See
+ [TLDef(0xC93DE95C)]
+ public sealed partial class InputChatTheme : InputChatThemeBase
+ {
+ public string emoticon;
+ }
+ /// See
+ [TLDef(0x87E5DFE4)]
+ public sealed partial class InputChatThemeUniqueGift : InputChatThemeBase
+ {
+ public string slug;
+ }
}
diff --git a/src/TL.SchemaFuncs.cs b/src/TL.SchemaFuncs.cs
index 9ea3dd5..804263a 100644
--- a/src/TL.SchemaFuncs.cs
+++ b/src/TL.SchemaFuncs.cs
@@ -1457,6 +1457,40 @@ namespace TL
user_id = user_id,
});
+ /// See
+ public static Task Account_SetMainProfileTab(this Client client, ProfileTab tab)
+ => client.Invoke(new Account_SetMainProfileTab
+ {
+ tab = tab,
+ });
+
+ /// See
+ public static Task Account_SaveMusic(this Client client, InputDocument id, InputDocument after_id = null, bool unsave = false)
+ => client.Invoke(new Account_SaveMusic
+ {
+ flags = (Account_SaveMusic.Flags)((after_id != null ? 0x2 : 0) | (unsave ? 0x1 : 0)),
+ id = id,
+ after_id = after_id,
+ });
+
+ /// See
+ /// a null value means account.savedMusicIdsNotModified
+ public static Task Account_GetSavedMusicIds(this Client client, long hash = default)
+ => client.Invoke(new Account_GetSavedMusicIds
+ {
+ hash = hash,
+ });
+
+ /// See
+ /// a null value means account.chatThemesNotModified
+ public static Task Account_GetUniqueGiftChatThemes(this Client client, int offset = default, int limit = int.MaxValue, long hash = default)
+ => client.Invoke(new Account_GetUniqueGiftChatThemes
+ {
+ offset = offset,
+ limit = limit,
+ hash = hash,
+ });
+
/// Returns basic user info according to their identifiers. See [bots: ✓] Possible codes: -504,400 (details)
/// List of user identifiers
public static Task Users_GetUsers(this Client client, params InputUserBase[] id)
@@ -1491,6 +1525,24 @@ namespace TL
id = id,
});
+ /// See
+ public static Task Users_GetSavedMusic(this Client client, InputUserBase id, int offset = default, int limit = int.MaxValue, long hash = default)
+ => client.Invoke(new Users_GetSavedMusic
+ {
+ id = id,
+ offset = offset,
+ limit = limit,
+ hash = hash,
+ });
+
+ /// See
+ public static Task Users_GetSavedMusicByID(this Client client, InputUserBase id, params InputDocument[] documents)
+ => client.Invoke(new Users_GetSavedMusicByID
+ {
+ id = id,
+ documents = documents,
+ });
+
/// Get the telegram IDs of all contacts.
Returns an array of Telegram user IDs for all contacts (0 if a contact does not have an associated Telegram account or have hidden their account using privacy settings). See
/// Hash used for caching, for more info click here
public static Task Contacts_GetContactIDs(this Client client, long hash = default)
@@ -3522,12 +3574,11 @@ namespace TL
/// Change the chat theme of a certain chat See Possible codes: 400 (details)
/// Private chat where to change theme
- /// Emoji, identifying a specific chat theme; a list of chat themes can be fetched using Account_GetChatThemes
- public static Task Messages_SetChatTheme(this Client client, InputPeer peer, string emoticon)
+ public static Task Messages_SetChatTheme(this Client client, InputPeer peer, InputChatThemeBase theme)
=> client.Invoke(new Messages_SetChatTheme
{
peer = peer,
- emoticon = emoticon,
+ theme = theme,
});
/// Get which users read a specific message: only available for groups and supergroups with less than chat_read_mark_size_threshold members, read receipts will be stored for chat_read_mark_expire_period seconds after the message was sent, see client configuration for more info ». See Possible codes: 400 (details)
@@ -5700,6 +5751,14 @@ namespace TL
query = query,
});
+ /// See
+ public static Task Channels_SetMainProfileTab(this Client client, InputChannelBase channel, ProfileTab tab)
+ => client.Invoke(new Channels_SetMainProfileTab
+ {
+ channel = channel,
+ tab = tab,
+ });
+
/// Sends a custom request; for bots only See [bots: ✓] Possible codes: 400,403 (details)
/// The method name
/// JSON-serialized method parameters
@@ -6442,10 +6501,10 @@ namespace TL
/// See Possible codes: 400 (details)
/// Maximum number of results to return, see pagination
- public static Task Payments_GetSavedStarGifts(this Client client, InputPeer peer, string offset, int limit = int.MaxValue, int? collection_id = null, bool exclude_unsaved = false, bool exclude_saved = false, bool exclude_unlimited = false, bool exclude_limited = false, bool exclude_unique = false, bool sort_by_value = false)
+ public static Task Payments_GetSavedStarGifts(this Client client, InputPeer peer, string offset, int limit = int.MaxValue, int? collection_id = null, bool exclude_unsaved = false, bool exclude_saved = false, bool exclude_unlimited = false, bool exclude_unique = false, bool sort_by_value = false, bool exclude_upgradable = false, bool exclude_unupgradable = false)
=> client.Invoke(new Payments_GetSavedStarGifts
{
- flags = (Payments_GetSavedStarGifts.Flags)((collection_id != null ? 0x40 : 0) | (exclude_unsaved ? 0x1 : 0) | (exclude_saved ? 0x2 : 0) | (exclude_unlimited ? 0x4 : 0) | (exclude_limited ? 0x8 : 0) | (exclude_unique ? 0x10 : 0) | (sort_by_value ? 0x20 : 0)),
+ flags = (Payments_GetSavedStarGifts.Flags)((collection_id != null ? 0x40 : 0) | (exclude_unsaved ? 0x1 : 0) | (exclude_saved ? 0x2 : 0) | (exclude_unlimited ? 0x4 : 0) | (exclude_unique ? 0x10 : 0) | (sort_by_value ? 0x20 : 0) | (exclude_upgradable ? 0x80 : 0) | (exclude_unupgradable ? 0x100 : 0)),
peer = peer,
collection_id = collection_id ?? default,
offset = offset,
@@ -6558,6 +6617,20 @@ namespace TL
hash = hash,
});
+ /// See
+ public static Task Payments_GetUniqueStarGiftValueInfo(this Client client, string slug)
+ => client.Invoke(new Payments_GetUniqueStarGiftValueInfo
+ {
+ slug = slug,
+ });
+
+ /// See
+ public static Task Payments_CheckCanSendGift(this Client client, long gift_id)
+ => client.Invoke(new Payments_CheckCanSendGift
+ {
+ gift_id = gift_id,
+ });
+
/// Create a stickerset. See [bots: ✓] Possible codes: 400 (details)
/// Whether this is a mask stickerset
/// Whether this is a custom emoji stickerset.
@@ -9001,6 +9074,40 @@ namespace TL.Methods
}
}
+ [TLDef(0x5DEE78B0)]
+ public sealed partial class Account_SetMainProfileTab : IMethod
+ {
+ public ProfileTab tab;
+ }
+
+ [TLDef(0xB26732A9)]
+ public sealed partial class Account_SaveMusic : IMethod
+ {
+ public Flags flags;
+ public InputDocument id;
+ [IfFlag(1)] public InputDocument after_id;
+
+ [Flags] public enum Flags : uint
+ {
+ unsave = 0x1,
+ has_after_id = 0x2,
+ }
+ }
+
+ [TLDef(0xE09D5FAF)]
+ public sealed partial class Account_GetSavedMusicIds : IMethod
+ {
+ public long hash;
+ }
+
+ [TLDef(0xFE74EF9F)]
+ public sealed partial class Account_GetUniqueGiftChatThemes : IMethod
+ {
+ public int offset;
+ public int limit;
+ public long hash;
+ }
+
[TLDef(0x0D91A548)]
public sealed partial class Users_GetUsers : IMethod
{
@@ -9026,6 +9133,22 @@ namespace TL.Methods
public InputUserBase[] id;
}
+ [TLDef(0x788D7FE3)]
+ public sealed partial class Users_GetSavedMusic : IMethod
+ {
+ public InputUserBase id;
+ public int offset;
+ public int limit;
+ public long hash;
+ }
+
+ [TLDef(0x7573A4E9)]
+ public sealed partial class Users_GetSavedMusicByID : IMethod
+ {
+ public InputUserBase id;
+ public InputDocument[] documents;
+ }
+
[TLDef(0x7ADC669D)]
public sealed partial class Contacts_GetContactIDs : IMethod
{
@@ -10789,11 +10912,11 @@ namespace TL.Methods
public InputPeer peer;
}
- [TLDef(0xE63BE13F)]
+ [TLDef(0x081202C9)]
public sealed partial class Messages_SetChatTheme : IMethod
{
public InputPeer peer;
- public string emoticon;
+ public InputChatThemeBase theme;
}
[TLDef(0x31C1C44F)]
@@ -12603,6 +12726,13 @@ namespace TL.Methods
}
}
+ [TLDef(0x3583FCB1)]
+ public sealed partial class Channels_SetMainProfileTab : IMethod
+ {
+ public InputChannelBase channel;
+ public ProfileTab tab;
+ }
+
[TLDef(0xAA2769ED)]
public sealed partial class Bots_SendCustomRequest : IMethod
{
@@ -13260,10 +13390,11 @@ namespace TL.Methods
exclude_unsaved = 0x1,
exclude_saved = 0x2,
exclude_unlimited = 0x4,
- exclude_limited = 0x8,
exclude_unique = 0x10,
sort_by_value = 0x20,
has_collection_id = 0x40,
+ exclude_upgradable = 0x80,
+ exclude_unupgradable = 0x100,
}
}
@@ -13380,6 +13511,18 @@ namespace TL.Methods
public long hash;
}
+ [TLDef(0x4365AF6B)]
+ public sealed partial class Payments_GetUniqueStarGiftValueInfo : IMethod
+ {
+ public string slug;
+ }
+
+ [TLDef(0xC0C4EDC9)]
+ public sealed partial class Payments_CheckCanSendGift : IMethod
+ {
+ public long gift_id;
+ }
+
[TLDef(0x9021AB67)]
public sealed partial class Stickers_CreateStickerSet : IMethod
{
diff --git a/src/TL.Table.cs b/src/TL.Table.cs
index 3be9440..00b0355 100644
--- a/src/TL.Table.cs
+++ b/src/TL.Table.cs
@@ -6,7 +6,7 @@ namespace TL
{
public static partial class Layer
{
- public const int Version = 211; // fetched 16/08/2025 00:21:53
+ public const int Version = 214; // fetched 01/09/2025 11:20:56
internal const int SecretChats = 144;
internal const int MTProto2 = 73;
internal const uint VectorCtor = 0x1CB5C415;
@@ -140,7 +140,7 @@ namespace TL
[0xFE685355] = typeof(Channel),
[0x17D493D5] = typeof(ChannelForbidden),
[0x2633421B] = typeof(ChatFull),
- [0xE07429DE] = typeof(ChannelFull),
+ [0xE4E0B29D] = typeof(ChannelFull),
[0xC02D4007] = typeof(ChatParticipant),
[0xE46BCEE4] = typeof(ChatParticipantCreator),
[0xA0933F5B] = typeof(ChatParticipantAdmin),
@@ -197,7 +197,7 @@ namespace TL
[0x502F92F7] = typeof(MessageActionInviteToGroupCall),
[0x3C134D7B] = typeof(MessageActionSetMessagesTTL),
[0xB3A07661] = typeof(MessageActionGroupCallScheduled),
- [0xAA786345] = typeof(MessageActionSetChatTheme),
+ [0xB91BBD3A] = typeof(MessageActionSetChatTheme),
[0xEBBCA3CB] = typeof(MessageActionChatJoinedByRequest),
[0x47DD8079] = typeof(MessageActionWebViewDataSentMe),
[0xB4C38CB5] = typeof(MessageActionWebViewDataSent),
@@ -215,7 +215,7 @@ namespace TL
[0x41B3E202] = typeof(MessageActionPaymentRefunded),
[0x45D5B021] = typeof(MessageActionGiftStars),
[0xB00C47A2] = typeof(MessageActionPrizeStars),
- [0x4717E8A4] = typeof(MessageActionStarGift),
+ [0xF24DE7FA] = typeof(MessageActionStarGift),
[0x34F762F3] = typeof(MessageActionStarGiftUnique),
[0xAC1F1FCD] = typeof(MessageActionPaidMessagesRefunded),
[0x84B88578] = typeof(MessageActionPaidMessagesPrice),
@@ -240,7 +240,7 @@ namespace TL
[0xB2A2F663] = typeof(GeoPoint),
[0x5E002502] = typeof(Auth_SentCode),
[0x2390FE44] = typeof(Auth_SentCodeSuccess),
- [0xD7CEF980] = typeof(Auth_SentCodePaymentRequired),
+ [0xD7A2FCF9] = typeof(Auth_SentCodePaymentRequired),
[0x2EA2C0D4] = typeof(Auth_Authorization),
[0x44747E9A] = typeof(Auth_AuthorizationSignUpRequired),
[0xB434E2B8] = typeof(Auth_ExportedAuthorization),
@@ -254,7 +254,7 @@ namespace TL
[0xF47741F7] = typeof(PeerSettings),
[0xA437C3ED] = typeof(WallPaper),
[0xE0804116] = typeof(WallPaperNoFile),
- [0x7E63CE1F] = typeof(UserFull),
+ [0xC577B5AD] = typeof(UserFull),
[0x145ADE0B] = typeof(Contact),
[0xC13E3C50] = typeof(ImportedContact),
[0x16D9703B] = typeof(ContactStatus),
@@ -1079,6 +1079,10 @@ namespace TL
[0xE3779861] = typeof(Account_ResetPasswordFailedWait),
[0xE9EFFC7D] = typeof(Account_ResetPasswordRequestedWait),
[0xE926D63E] = typeof(Account_ResetPasswordOk),
+ [0xC3DFFC04] = typeof(ChatTheme),
+ [0x3458F9C8] = typeof(ChatThemeUniqueGift),
+ [0xE011E1C4] = null,//Account_ChatThemesNotModified
+ [0x16484857] = typeof(Account_ChatThemes),
[0x7DBF8673] = typeof(SponsoredMessage),
[0xFFDA656D] = typeof(Messages_SponsoredMessages),
[0x1839490F] = null,//Messages_SponsoredMessagesEmpty
@@ -1130,6 +1134,7 @@ namespace TL
[0xDABAB2EF] = typeof(InputInvoicePremiumGiftStars),
[0xF4997E42] = typeof(InputInvoiceBusinessBotTransferStars),
[0xC39F5324] = typeof(InputInvoiceStarGiftResale),
+ [0x9A0B48B8] = typeof(InputInvoiceStarGiftPrepaidUpgrade),
[0xAED0CBD9] = typeof(Payments_ExportedInvoice),
[0xCFB9D957] = typeof(Messages_TranscribedAudio),
[0x5334759C] = typeof(Help_PremiumPromo),
@@ -1137,7 +1142,7 @@ namespace TL
[0x616F7FE8] = typeof(InputStorePaymentGiftPremium),
[0xFB790393] = typeof(InputStorePaymentPremiumGiftCode),
[0x160544CA] = typeof(InputStorePaymentPremiumGiveaway),
- [0xDDDD0F56] = typeof(InputStorePaymentStarsTopup),
+ [0xF9A2A6CB] = typeof(InputStorePaymentStarsTopup),
[0x1D741EF7] = typeof(InputStorePaymentStarsGift),
[0x751F08FA] = typeof(InputStorePaymentStarsGiveaway),
[0x9BB2636D] = typeof(InputStorePaymentAuthCode),
@@ -1362,8 +1367,8 @@ namespace TL
[0x4BA3A95A] = typeof(MessageReactor),
[0x94CE852A] = typeof(StarsGiveawayOption),
[0x54236209] = typeof(StarsGiveawayWinnersOption),
- [0x00BCFF5B] = typeof(StarGift),
- [0x3A274D50] = typeof(StarGiftUnique),
+ [0x80AC53C3] = typeof(StarGift),
+ [0x1BEFE865] = typeof(StarGiftUnique),
[0xA388A368] = null,//Payments_StarGiftsNotModified
[0x2ED82995] = typeof(Payments_StarGifts),
[0x7903E3D9] = typeof(MessageReportOption),
@@ -1390,9 +1395,9 @@ namespace TL
[0x167BD90B] = typeof(Payments_StarGiftUpgradePreview),
[0x62D706B8] = typeof(Users_Users),
[0x315A4974] = typeof(Users_UsersSlice),
- [0xCAA2F60B] = typeof(Payments_UniqueStarGift),
- [0xB53E8B21] = typeof(Messages_WebPagePreview),
- [0x1EA646DF] = typeof(SavedStarGift),
+ [0x416C56E8] = typeof(Payments_UniqueStarGift),
+ [0x8C9A88AC] = typeof(Messages_WebPagePreview),
+ [0x19A9B572] = typeof(SavedStarGift),
[0x95F389B1] = typeof(Payments_SavedStarGifts),
[0x69279795] = typeof(InputSavedStarGiftUser),
[0xF101AA7F] = typeof(InputSavedStarGiftChat),
@@ -1429,6 +1434,16 @@ namespace TL
[0x564EDAEB] = null,//Stories_AlbumsNotModified
[0xC3987A3A] = typeof(Stories_Albums),
[0x3E0B5B6A] = typeof(SearchPostsFlood),
+ [0x512FE446] = typeof(Payments_UniqueStarGiftValueInfo),
+ [0xE3878AA4] = typeof(Users_SavedMusicNotModified),
+ [0x34A2F297] = typeof(Users_SavedMusic),
+ [0x4FC81D6E] = null,//Account_SavedMusicIdsNotModified
+ [0x998D6636] = typeof(Account_SavedMusicIds),
+ [0x374FA7AD] = typeof(Payments_CheckCanSendGiftResultOk),
+ [0xD5E58274] = typeof(Payments_CheckCanSendGiftResultFail),
+ [0x83268483] = null,//InputChatThemeEmpty
+ [0xC93DE95C] = typeof(InputChatTheme),
+ [0x87E5DFE4] = typeof(InputChatThemeUniqueGift),
// from TL.Secret:
[0x6ABD9782] = typeof(Layer143.DecryptedMessageMediaDocument),
[0x020DF5D0] = typeof(Layer101.MessageEntityBlockquote),
@@ -1548,6 +1563,7 @@ namespace TL
[typeof(ChatReactions)] = 0xEAFC32BC, //chatReactionsNone
[typeof(Messages_Reactions)] = 0xB06FDBDF, //messages.reactionsNotModified
// from TL.Secret:
+ [typeof(Account_ChatThemes)] = 0xE011E1C4, //account.chatThemesNotModified
[typeof(EmojiStatusBase)] = 0x2DE11AAE, //emojiStatusEmpty
[typeof(EmojiList)] = 0x481EADFA, //emojiListNotModified
[typeof(Messages_EmojiGroups)] = 0x6FB4AD87, //messages.emojiGroupsNotModified
@@ -1564,6 +1580,8 @@ namespace TL
[typeof(Contacts_SponsoredPeers)] = 0xEA32B4B1, //contacts.sponsoredPeersEmpty
[typeof(Payments_StarGiftCollections)] = 0xA0BA4F17, //payments.starGiftCollectionsNotModified
[typeof(Stories_Albums)] = 0x564EDAEB, //stories.albumsNotModified
+ [typeof(Account_SavedMusicIds)] = 0x4FC81D6E, //account.savedMusicIdsNotModified
+ [typeof(InputChatThemeBase)] = 0x83268483, //inputChatThemeEmpty
[typeof(DecryptedMessageMedia)] = 0x089F5C4A, //decryptedMessageMediaEmpty
};
}
diff --git a/src/WTelegramClient.csproj b/src/WTelegramClient.csproj
index ed47ea1..6fd580b 100644
--- a/src/WTelegramClient.csproj
+++ b/src/WTelegramClient.csproj
@@ -13,8 +13,8 @@
WTelegramClient
Wizou
0.0.0
- layer.211
- Telegram Client API (MTProto) library written 100% in C# and .NET Standard | Latest API layer: 211
+ layer.214
+ Telegram Client API (MTProto) library written 100% in C# and .NET Standard | Latest API layer: 214
Release Notes:
$(ReleaseNotes.Replace("|", "%0D%0A").Replace(" - ","%0D%0A- ").Replace(" ", "%0D%0A%0D%0A"))