diff --git a/data/web/corefork.telegram.org/api/bots/webapps.html b/data/web/corefork.telegram.org/api/bots/webapps.html
index cf10d4bf4e..188acb0281 100644
--- a/data/web/corefork.telegram.org/api/bots/webapps.html
+++ b/data/web/corefork.telegram.org/api/bots/webapps.html
@@ -111,14 +111,15 @@ Note that eventual errors will not be sent as a failed
event if the
Simple webapps can only send back data to the bot through the MTProto API via a web_app_data_send
JS event ».
Simple webapps can be opened from a keyboardButtonSimpleWebView button contained in a reply keyboard identified by a replyKeyboardMarkup constructor, or by clicking on the inlineBotWebView button on top of the inline result list, contained in messages.botResults.switch_webview
, returned by messages.getInlineBotResults.
To open them, users should call messages.requestSimpleWebView passing the original url
, and then open a webview using the url
contained in the returned simpleWebViewResultUrl.
Upon receiving a web_app_data_send
JS event » from the web app, clients should invoke messages.sendWebViewData, passing the following arguments:
If and only if the webapp was opened from a keyboardButtonSimpleWebView reply keyboard button, upon receiving a web_app_data_send
JS event » from the web app, clients should invoke messages.sendWebViewData, passing the following arguments:
bot
- Bot IDrandom_id
- Unique random ID to avoid resending the same event multiple timesbutton_text
- Text of the keyboardButtonSimpleWebView that was pressed to open the simple web appdata
- Contents of the data
field of the JS event. Make sure to ignore all web_app_data_send
events sent after the first one, messages.sendWebViewData must be called only once.
+
Always ignore all web_app_data_send
events received from inlineBotWebView webapps, as only keyboardButtonSimpleWebView webapps can send this event.
+Make sure to ignore all web_app_data_send
events sent after the first one, messages.sendWebViewData must be called only once.
The webview must be closed after invoking the messages.sendWebViewData method.
This will generate a messageActionWebViewDataSent update for the user, and a messageActionWebViewDataSentMe update for the bot, containing the event data.
These links are different from bot attachment menu deep links », because they don't require the user to install an attachment menu, and a single bot can offer multiple web apps, distinguished by their short_name
.
These links should be handled as follows:
@@ -179,6 +178,8 @@ The webview must be closed after invoking the messages.getBotApp, passing an inputBotAppShortName with theshort_name
contained in the appname
query string parameter.
If the client has already encountered an app with this short name from the same bot before, pass the hash
of the cached botApp constructor to messages.getBotApp.
+request_write_access
flag is set, show a prompt to the user, indicating that the bot is asking permission to send messages to the user.write_allowed
flag when invoking messages.requestAppWebView in the next step.id
and access_hash
of the returned botApp, or from previously cached information if we already met the bot app and botAppNotModified was returned. peer
; otherwise pass the bot's peer information, instead.inactive
flag is set, ask confirmation from the user before opening the web app.usernames
vector must be shown in-UI as the main username.
Immediately after association, a username is marked as not active
(i.e. only the owner can see it in the usernames
list): use account.toggleUsername, bots.toggleUsername or channels.toggleUsername to mark it as active.
Note that you can't mark as inactive the basic (non-collectible) username, if any.
channels.deactivateAllUsernames may also be used to mark as inactive all collectible usernames associated to a certain supergroup or channel.
+channels.deactivateAllUsernames may also be used to mark as inactive all collectible usernames associated to a certain supergroup or channel: useful for example when making a group or channel private, by first invoking channels.updateUsername with an empty username to remove the editable username (if present), and then invoking this method to remove all associated collectible usernames.
Use account.reorderUsernames/bots.reorderUsernames/channels.reorderUsernames to change the order of the usernames associated to an account, channel or supergroup: all currently active usernames must be specified.
diff --git a/data/web/corefork.telegram.org/method/channels.updateUsername b/data/web/corefork.telegram.org/method/channels.updateUsername index 9e82c86c8f..e3f85968f4 100644 --- a/data/web/corefork.telegram.org/method/channels.updateUsername +++ b/data/web/corefork.telegram.org/method/channels.updateUsername @@ -42,7 +42,7 @@Change the username of a supergroup/channel
+Change or remove the username of a supergroup/channel