From e57e413f690fd836fa3d5635ef2abf41fc5ee114 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" <41898282+github-actions[bot]@users.noreply.github.com> Date: Fri, 9 Oct 2026 03:43:38 +0000 Subject: [PATCH] Update MTProto API schema to Layer 230 --- compiler/api/source/main_api.tl | 134 ++++++++++++++++++++++++++++++-- news/20261009034333.misc.rst | 4 + 2 files changed, 130 insertions(+), 8 deletions(-) create mode 100644 news/20261009034333.misc.rst diff --git a/compiler/api/source/main_api.tl b/compiler/api/source/main_api.tl index ff0c9c377..e33723d41 100644 --- a/compiler/api/source/main_api.tl +++ b/compiler/api/source/main_api.tl @@ -221,6 +221,8 @@ messageActionPollDeleteAnswer#399674dc answer:PollAnswer = MessageAction; messageActionManagedBotCreated#16605e3e bot_id:long = MessageAction; messageActionChangeCommunity#5d20bae8 flags:# community_id:flags.0?long = MessageAction; messageActionChatJoinedViaCommunity#4a8bfe80 community_id:long = MessageAction; +messageActionGramTransfer#9329ea33 flags:# comment_encrypted:flags.1?true amount:long peer_address:string transaction_id:string comment:flags.0?string = MessageAction; +messageActionWalletTonConnectRequest#69b8c4bf flags:# accepted:flags.2?true declined:flags.3?true session_id:long expires:int topic:flags.0?string trace_id:flags.1?string dapp_name:flags.4?string = MessageAction; dialog#fc89f7f3 flags:# pinned:flags.2?true unread_mark:flags.3?true view_forum_as_messages:flags.6?true peer:Peer top_message:int read_inbox_max_id:int read_outbox_max_id:int unread_count:int unread_mentions_count:int unread_reactions_count:int unread_poll_votes_count:int notify_settings:PeerNotifySettings pts:flags.0?int draft:flags.1?DraftMessage folder_id:flags.4?int ttl_period:flags.5?int = Dialog; dialogFolder#71bd134c flags:# pinned:flags.2?true folder:Folder peer:Peer top_message:int unread_muted_peers_count:int unread_unmuted_peers_count:int unread_muted_messages_count:int unread_unmuted_messages_count:int = Dialog; @@ -491,6 +493,11 @@ updateDeleteEphemeralMessages#56dbfcf8 peer:Peer ids:Vector = Update; updateEditEphemeralMessage#4bbb8f01 message:EphemeralMessage = Update; updateEphemeralBotCallbackQuery#7c1079d6 flags:# query_id:long user_id:long peer:flags.0?Peer msg_id:int data:bytes chat_instance:flags.1?long message:EphemeralMessage = Update; updateBotStarsSubscription#6c0d8e23 flags:# canceled:flags.0?true payment_failed:flags.1?true restored:flags.2?true user_id:long payload:bytes qts:int = Update; +updateWalletState#6ac3f2aa state:WalletState = Update; +updateSentWalletTransaction#b1434d4a flags:# gasless:flags.0?true msg_hash:string transaction:flags.1?WalletTransaction = Update; +updateWalletGaslessInfo#a8ae1cac flags:# available:flags.0?true left:int reset_at:int min_amount:long relayer_address:string = Update; +updateWalletTonConnectSession#50a38e0e session:TonConnectSession = Update; +updateWalletTonConnectPendingDisconnect#d1ee8199 session_ids:Vector = Update; updates.state#a56c2a3e pts:int qts:int date:int seq:int unread_count:int = updates.State; @@ -752,6 +759,7 @@ messageEntityFormattedDate#904ac7c7 flags:# relative:flags.0?true short_time:fla messageEntityDiffInsert#71777116 offset:int length:int = MessageEntity; messageEntityDiffReplace#c6c1e5a7 offset:int length:int old_text:string = MessageEntity; messageEntityDiffDelete#652c1c5 offset:int length:int = MessageEntity; +messageEntityTonAddress#fdabbfcd offset:int length:int = MessageEntity; inputChannelEmpty#ee8c1e86 = InputChannel; inputChannel#f35aec28 channel_id:long access_hash:long = InputChannel; @@ -939,6 +947,7 @@ textMentionName#1a9fbfc text:RichText user_id:long = RichText; textDate#a5b45e2b flags:# relative:flags.0?true short_time:flags.1?true long_time:flags.2?true short_date:flags.3?true long_date:flags.4?true day_of_week:flags.5?true text:RichText date:int = RichText; textDiff#9686cb50 text:RichText old_text:RichText = RichText; textButton#afc79cd6 flags:# text:RichText type:InlineButtonType style:flags.0?RichButtonStyle = RichText; +textTonAddress#3cd2a36a text:RichText = RichText; pageBlockUnsupported#13567e8a = PageBlock; pageBlockTitle#70abc3fd text:RichText = PageBlock; @@ -1650,7 +1659,7 @@ messageExtendedMedia#ee479c64 media:MessageMedia = MessageExtendedMedia; stickerKeyword#fcfeb29c document_id:long keyword:Vector = StickerKeyword; -username#b4073647 flags:# editable:flags.0?true active:flags.1?true username:string = Username; +username#b4073647 flags:# editable:flags.0?true active:flags.1?true deletable:flags.2?true expired:flags.3?true username:string = Username; forumTopicDeleted#23f109b id:int = ForumTopic; forumTopic#fcdad815 flags:# my:flags.1?true closed:flags.2?true pinned:flags.3?true short:flags.5?true hidden:flags.6?true title_missing:flags.7?true id:int date:int peer:Peer title:string icon_color:int icon_emoji_id:flags.0?long top_message:int read_inbox_max_id:int read_outbox_max_id:int unread_count:int unread_mentions_count:int unread_reactions_count:int unread_poll_votes_count:int from_id:Peer notify_settings:PeerNotifySettings draft:flags.4?DraftMessage = ForumTopic; @@ -2015,9 +2024,9 @@ starsTonAmount#74aee3e0 amount:long = StarsAmount; messages.foundStickersNotModified#6010c534 flags:# next_offset:flags.0?int = messages.FoundStickers; messages.foundStickers#82c9e290 flags:# next_offset:flags.0?int hash:long stickers:Vector = messages.FoundStickers; -botVerifierSettings#b0cd6617 flags:# can_modify_custom_description:flags.1?true icon:long company:string custom_description:flags.0?string = BotVerifierSettings; +botVerifierSettings#a12aefff flags:# can_modify_custom_description:flags.1?true icon:long company:string custom_description:flags.0?TextWithEntities = BotVerifierSettings; -botVerification#f93cd45c bot_id:long icon:long description:string = BotVerification; +botVerification#f72e0ed9 bot_id:long icon:long description:TextWithEntities = BotVerification; starGiftAttributeModel#565251e2 flags:# crafted:flags.0?true name:string document:Document rarity:StarGiftAttributeRarity = StarGiftAttribute; starGiftAttributePattern#4e7085ea name:string document:Document rarity:StarGiftAttributeRarity = StarGiftAttribute; @@ -2164,7 +2173,6 @@ inputPasskeyResponseRegister#3e63935c client_data:DataJSON attestation_data:byte inputPasskeyResponseLogin#c31fc14a client_data:DataJSON authenticator_data:bytes signature:bytes user_handle:string = InputPasskeyResponse; inputPasskeyCredentialPublicKey#3c27b78f id:string raw_id:string response:InputPasskeyResponse = InputPasskeyCredential; -inputPasskeyCredentialFirebasePNV#5b1ccb28 pnv_token:string = InputPasskeyCredential; starGiftBackground#aff56398 center_color:int edge_color:int text_color:int = StarGiftBackground; @@ -2279,6 +2287,77 @@ pageButton#692a5488 flags:# text:RichText type:InlineButtonType style:flags.0?Ri ephemeral.welcomeMessagesNotModified#59ffdb31 = ephemeral.WelcomeMessages; ephemeral.welcomeMessages#104fc872 hash:long messages:Vector = ephemeral.WelcomeMessages; +currencyRate#30d9743c currency:string rate:double = CurrencyRate; + +payments.currencyRates#bbcce4c2 rates:Vector = payments.CurrencyRates; + +toncenter.apiResponse#ac8dfe19 response:DataJSON = toncenter.ApiResponse; + +toncenter.streamingUrl#19887601 url:string expires:int = toncenter.StreamingUrl; + +onrampMethodAvailability#9ec8c6a8 flags:# available:flags.0?true payment_method:string = OnrampMethodAvailability; + +onrampProviderInfo#dc27582 flags:# supports_base_currencies:flags.0?true supports_limits:flags.1?true supports_quote:flags.2?true id:string name:string crypto_currencies:Vector = OnrampProviderInfo; + +onrampAvailability#f9c84973 flags:# allowed:flags.0?true buy_allowed:flags.1?true country_code:string state:flags.2?string methods:Vector = OnrampAvailability; + +onrampLimits#7be2677e base_currency:string base_min_amount:string base_max_amount:string crypto_min_amount:string crypto_max_amount:string payment_method:string = OnrampLimits; + +onrampQuote#7a8011e9 base_currency:string base_amount:string crypto_currency:string crypto_amount:string crypto_price:string fee_amount:string extra_fee_amount:string network_fee_amount:string total_amount:string payment_method:string expires_date:int = OnrampQuote; + +onrampSession#d1e42e24 provider:string session_id:string url:string expires_date:int = OnrampSession; + +walletStateEmpty#9cb9b2ec flags:# creating:flags.0?true = WalletState; +walletState#95c5346b flags:# backup_enabled:flags.0?true can_export_phrase:flags.1?true can_enable_backup:flags.2?true address:string public_key:bytes balance:long = WalletState; + +walletUserAddress#fe78eecc flags:# user_id:flags.0?long address:string public_key:bytes = WalletUserAddress; + +wallet.userAddresses#928e7b55 addresses:Vector users:Vector = wallet.UserAddresses; + +walletTransactionPeerUser#d4ea706d flags:# user_id:long address:string domain:flags.0?string = WalletTransactionPeer; +walletTransactionPeerAddress#62cc1bc flags:# address:string domain:flags.0?string = WalletTransactionPeer; +walletTransactionPeerOnramp#e595186e flags:# address:string domain:flags.0?string provider_name:string = WalletTransactionPeer; +walletTransactionPeerUnsupported#728bed5a = WalletTransactionPeer; + +walletTransaction#952dc143 flags:# incoming:flags.0?true gasless:flags.1?true failed:flags.2?true key_change:flags.5?true comment_encrypted:flags.6?true id:string amount:long fee:long date:int peer:WalletTransactionPeer comment:flags.3?string tx_hash:flags.4?string nft:flags.7?wallet.NftItem = WalletTransaction; + +wallet.transactions#4322d5a5 flags:# balance:long transactions:Vector next_offset:flags.0?string chats:Vector users:Vector = wallet.Transactions; + +wallet.secretPhraseParts#e6d0ef01 token:string dcs:Vector = wallet.SecretPhraseParts; + +wallet.encryptedSecretPhrasePart#18e82537 data:bytes = wallet.EncryptedSecretPhrasePart; + +wallet.holderDc#f9d612ef dc:int public_key:bytes = wallet.HolderDc; + +wallet.proofChallenge#99e41707 payload:string expires:int domain:string = wallet.ProofChallenge; + +walletOwnershipProof#60bccb0d timestamp:int signature:bytes = WalletOwnershipProof; + +inputWalletNew#63a440dc = InputWalletReplacement; +inputWalletImported#66a66a3b flags:# public_key:bytes anchor_public_key:flags.0?bytes proof:WalletOwnershipProof = InputWalletReplacement; + +tonConnectManifest#12229264 flags:# url:string name:string icon:flags.0?WebDocument = TonConnectManifest; + +tonConnectSession#126556c6 flags:# pending:flags.0?true closing:flags.1?true closed:flags.2?true id:long dapp_client_id:string client_id:flags.3?string nonce:bytes manifest:flags.4?TonConnectManifest manifest_error:flags.5?int date:int = TonConnectSession; + +wallet.tonConnectChallenge#4bc89693 challenge:bytes event_id:long = wallet.TonConnectChallenge; + +tonConnectNextEventId#582464e3 event_id:long = TonConnectNextEventId; + +tonConnectRequest#a15f8513 flags:# session_id:long msg_id:int body:bytes expires:int topic:flags.0?string trace_id:flags.1?string = TonConnectRequest; + +wallet.tonConnectPending#85c0f124 session:TonConnectSession requests:Vector = wallet.TonConnectPending; + +wallet.tonConnectSessions#e1f6896 sessions:Vector = wallet.TonConnectSessions; + +wallet.existingBalance#bde90a8d flags:# has_balance:flags.0?true url:string = wallet.ExistingBalance; + +wallet.nftAttribute#4c1ef10e trait_type:string value:string = wallet.NftAttribute; + +wallet.nftItem#3441fd1c flags:# collection_address:flags.0?string address:string owner_address:string index:string name:flags.1?string description:flags.2?string image:flags.3?WebDocument image_small:flags.4?WebDocument content_url:flags.5?WebDocument lottie:flags.6?WebDocument attributes:flags.7?Vector extra:flags.8?DataJSON = wallet.NftItem; + +wallet.nftItems#794d486f flags:# items:Vector next_offset:flags.0?string = wallet.NftItems; + auth.firebasePnvIntent#df5ac00c nonce:string digital_credential_payload:string = auth.FirebasePnvIntent; ---functions--- @@ -2321,7 +2400,8 @@ auth.reportMissingCode#cb9deff6 phone_number:string phone_code_hash:string mnc:s auth.checkPaidAuth#56e59f9c phone_number:string phone_code_hash:string form_id:long = auth.SentCode; auth.initPasskeyLogin#518ad0b7 api_id:int api_hash:string = auth.PasskeyLoginOptions; auth.finishPasskeyLogin#9857ad07 flags:# credential:InputPasskeyCredential from_dc_id:flags.0?int from_auth_key_id:flags.0?long = auth.Authorization; -auth.initFirebasePnvLogin#777df37a api_id:int api_hash:string = auth.FirebasePnvIntent; +auth.cancelWebTokenAuthorization#490dada1 web_auth_token:string = Bool; +auth.initFirebasePnvLogin#644f15c0 flags:# except_ids:flags.0?Vector api_id:int api_hash:string = auth.FirebasePnvIntent; auth.finishFirebasePnvLogin#2c85094c google_token:string = auth.Authorization; auth.firebasePnvSignUp#783f6b56 flags:# no_joined_notifications:flags.0?true first_name:string last_name:string = auth.Authorization; @@ -2883,9 +2963,9 @@ bots.toggleUserEmojiStatusPermission#6de6392 bot:InputUser enabled:Bool = Bool; bots.checkDownloadFileParams#50077589 bot:InputUser file_name:string url:string = Bool; bots.getAdminedBots#b0711d83 = Vector; bots.updateStarRefProgram#778b5ab3 flags:# bot:InputUser commission_permille:int duration_months:flags.0?int = StarRefProgram; -bots.setCustomVerification#8b89dfbd flags:# enabled:flags.1?true bot:flags.0?InputUser peer:InputPeer custom_description:flags.2?string = Bool; +bots.setCustomVerification#f4946757 flags:# enabled:flags.1?true bot:flags.0?InputUser peer:InputPeer custom_description:flags.2?TextWithEntities = Bool; bots.getBotRecommendations#a1b70815 bot:InputUser = users.Users; -bots.checkUsername#87f2219b username:string = Bool; +bots.checkUsername#e3ac4c61 flags:# additional:flags.0?true username:string = Bool; bots.createBot#e5b17f2b flags:# via_deeplink:flags.0?true name:string username:string manager_id:InputUser = User; bots.exportBotToken#bd0d99eb bot:InputUser revoke:Bool = bots.ExportedBotToken; bots.requestWebViewButton#31a2a35e user_id:InputUser button:KeyboardButton = bots.RequestedButton; @@ -2893,6 +2973,8 @@ bots.getRequestedWebViewButton#bf25b7f3 bot:InputUser webapp_req_id:string = Key bots.getAccessSettings#213853a3 bot:InputUser = bots.AccessSettings; bots.editAccessSettings#31813cd8 flags:# restricted:flags.0?true bot:InputUser add_users:flags.1?Vector = Bool; bots.setJoinChatResults#e71a4810 query_id:long result:JoinChatBotResult = Bool; +bots.addUsername#3501c08a bot:InputUser username:string = Bool; +bots.removeUsername#c704147d bot:InputUser username:string = Bool; payments.getPaymentForm#37148dbb flags:# invoice:InputInvoice theme_params:flags.0?DataJSON = payments.PaymentForm; payments.getPaymentReceipt#2478d1cc peer:InputPeer msg_id:int = payments.PaymentReceipt; @@ -2959,6 +3041,13 @@ payments.sendStarGiftOffer#8fb86b41 flags:# peer:InputPeer slug:string price:Sta payments.getStarGiftUpgradeAttributes#6d038b58 gift_id:long = payments.StarGiftUpgradeAttributes; payments.getCraftStarGifts#fd05dd00 gift_id:long offset:string limit:int = payments.SavedStarGifts; payments.craftStarGift#b0f9684f stargift:Vector = Updates; +payments.getCurrencyRates#d35983e8 = payments.CurrencyRates; +payments.getOnrampProviders#3f3e00dc flags:# crypto_currency:flags.0?string = Vector; +payments.getOnrampBaseCurrencies#1c8bedf3 provider:string crypto_currency:string = Vector; +payments.getOnrampAvailability#2ec29951 flags:# provider:string crypto_currency:string base_currency:flags.0?string = OnrampAvailability; +payments.getOnrampLimits#80e851fd flags:# provider:string crypto_currency:string base_currency:string payment_method:flags.0?string = OnrampLimits; +payments.getOnrampQuote#e06645fa flags:# provider:string crypto_currency:string base_currency:string base_amount:flags.0?string crypto_amount:flags.1?string payment_method:flags.2?string = OnrampQuote; +payments.createOnrampSession#a2197cf6 flags:# provider:string crypto_currency:string address:string payment_method:flags.0?string base_currency:flags.1?string base_amount:flags.2?string memo:flags.3?string theme:flags.4?string success_return_url:flags.5?string fail_return_url:flags.6?string crypto_amount:flags.7?string = OnrampSession; stickers.createStickerSet#9021ab67 flags:# masks:flags.0?true emojis:flags.5?true text_color:flags.6?true user_id:InputUser title:string short_name:string thumb:flags.2?InputDocument stickers:Vector software:flags.3?string = messages.StickerSet; stickers.removeStickerFromSet#f7760f51 sticker:InputDocument = messages.StickerSet; @@ -3122,4 +3211,33 @@ ephemeral.deleteWelcomeMessage#e882a9e1 peer:InputPeer id:int = Bool; ephemeral.deleteAllWelcomeMessages#734f9721 peer:InputPeer = Bool; ephemeral.getWelcomeMessages#db9ac18d peer:InputPeer hash:long = ephemeral.WelcomeMessages; -// LAYER 229 +toncenter.performApiRequest#8d7bdd61 flags:# post:flags.0?true endpoint:string query:flags.1?string payload:flags.2?string = toncenter.ApiResponse; +toncenter.getStreamingUrl#cdaf63c7 = toncenter.StreamingUrl; + +wallet.getState#ab83b33a = WalletState; +wallet.getUserAddresses#5275dfdd flags:# force:flags.0?true id:Vector addresses:Vector = wallet.UserAddresses; +wallet.getTransactions#a8830a83 flags:# inbound:flags.0?true outbound:flags.1?true offset:string limit:int = wallet.Transactions; +wallet.getTransactionsByIDs#811ceab6 id:Vector = wallet.Transactions; +wallet.getTransactionsByMsgHash#a6bb795d msg_hash:Vector = wallet.Transactions; +wallet.exportSecretPhrase#9077c9ac flags:# password:flags.0?InputCheckPasswordSRP = wallet.SecretPhraseParts; +wallet.fetchEncryptedSecretPhrasePart#f53925cf token:string public_key:bytes = wallet.EncryptedSecretPhrasePart; +wallet.replaceWallet#d8c72eec flags:# wallet:InputWalletReplacement password:flags.0?InputCheckPasswordSRP = WalletState; +wallet.disableBackup#b0bf0da flags:# password:flags.0?InputCheckPasswordSRP new_public_key:flags.1?bytes proof:flags.2?WalletOwnershipProof = WalletState; +wallet.getBackupHolderDcs#d179d494 = Vector; +wallet.enableBackup#4500c525 flags:# parts:Vector new_public_key:flags.1?bytes proof:flags.2?WalletOwnershipProof = WalletState; +wallet.getProofChallenge#2025e697 = wallet.ProofChallenge; +wallet.sendTransfer#d9e5d9e2 flags:# data_normal:bytes data_gasless:flags.0?bytes user_id:InputUser random_id:long = Updates; +wallet.getGaslessInfo#742df0a1 = Updates; +wallet.getExistingWaltBalance#691f4360 = wallet.ExistingBalance; +wallet.getNfts#8c12f3a4 offset:string limit:int = wallet.NftItems; +wallet.tonConnectCreateSession#cc931046 dapp_client_id:string manifest_url:string = TonConnectSession; +wallet.tonConnectRegisterKey#338bcf1c session_id:long client_id:string = wallet.TonConnectChallenge; +wallet.tonConnectSubmitConnectResult#c2c00779 flags:# error:flags.0?true session_id:long challenge_answer:bytes body:bytes trace_id:flags.1?string = Bool; +wallet.tonConnectGetPending#11aee065 flags:# dapp_client_id:flags.0?string session_id:flags.1?long = wallet.TonConnectPending; +wallet.tonConnectClaimRequest#66b57b41 flags:# declined:flags.1?true session_id:long msg_id:int app_request_id:string challenge_answer:flags.0?bytes = Bool; +wallet.tonConnectSubmitResponse#fac67d3c flags:# session_id:long msg_id:int body:bytes trace_id:flags.0?string = Bool; +wallet.tonConnectNextEventId#775d7244 session_id:long = TonConnectNextEventId; +wallet.tonConnectCloseSession#d63f61ce flags:# session_id:long body:flags.0?bytes = Bool; +wallet.tonConnectGetSessions#a7ffb56e = wallet.TonConnectSessions; + +// LAYER 230 diff --git a/news/20261009034333.misc.rst b/news/20261009034333.misc.rst new file mode 100644 index 000000000..3ccc9958e --- /dev/null +++ b/news/20261009034333.misc.rst @@ -0,0 +1,4 @@ +API Layer Update +================ + +Updated MTProto API schema to Layer 230.