diff --git a/data/web/corefork.telegram.org/api/colors.html b/data/web/corefork.telegram.org/api/colors.html new file mode 100644 index 0000000000..534b24527f --- /dev/null +++ b/data/web/corefork.telegram.org/api/colors.html @@ -0,0 +1,118 @@ + + +
+ +Typical fields included in the resulting JSON object are:
emojies_animated_zoom
stories_entities
Whether styled text entities and links in story text captions can be used by all users (enabled
), only [Premium](/api/premium users) (premium
), or no one (disabled
). (string)
This field is used both when posting stories, to indicate to the user whether they can use entities, and when viewing stories, to hide entities (client-side) on stories posted by users whose Premium subscription has expired (if stories_entities == "premium"
and user.premium
is not set, or if stories_entities == "disabled"
).
giveaway_gifts_purchase_available
giveaway_add_peers_max
giveaway_countries_max
giveaway_boosts_per_premium
giveaway_period_max
boosts_channel_level_max
boosts_per_sent_gift
quote_length_max
channel_color_level_min
transcribe_audio_trial_weekly_number
transcribe_audio_trial_duration_max
recommended_channels_limit_default
recommended_channels_limit_premium
The API can return a set of useful suggestions for users of graphical clients.
"VALIDATE_PHONE_NUMBER"
- Users should check whether their authorization phone number is correct and change the phone number if it is inaccessible."NEWCOMER_TICKS"
- Show the user a hint about the meaning of one and two ticks on sent messages."SETUP_PASSWORD"
- Show the user a hint, asking them to check whether they still remember their 2FA password"PREMIUM_ANNUAL"
- Suggests the user to subscribe to the Premium subscription (with annual payments)"PREMIUM_UPGRADE"
- Suggests the user to upgrade their existing Premium subscription from monthly payments to annual payments"PREMIUM_RESTORE"
- Suggests the user to restore a recently expired Premium subscriptionfaster_download
- Premium users have no download speed limits.
wallpapers
- Premium users can set custom chat wallpapers both for them and the other user in the chat.
peer_colors
- Premium users can choose a custom color and background emoji for their profile background and messages.
voice_to_text
- Premium users can transcribe voice messages.
rotation
indicates clockwise rotation angle of the gradient
account.wallPapersNotModified#1c199183 = account.WallPapers;
account.wallPapers#cdc3858c hash:long wallpapers:Vector<WallPaper> = account.WallPapers;
-messageActionSetChatWallPaper#5060a3f4 flags:# same:flags.0?true for_both:flags.1?true wallpaper:WallPaper = MessageAction;
-messageActionSetSameChatWallPaper#c0787d6d wallpaper:WallPaper = MessageAction;
-
---functions---
account.getWallPaper#fc8ddbea wallpaper:InputWallPaper = WallPaper;
@@ -134,9 +131,7 @@ If set, rotation
indicates clockwise rotation angle of the gradient
account.saveWallPaper#6c5a5b37 wallpaper:InputWallPaper unsave:Bool settings:WallPaperSettings = Bool;
account.installWallPaper#feed5769 wallpaper:InputWallPaper settings:WallPaperSettings = Bool;
account.getWallPapers#7967d36 hash:long = account.WallPapers;
-account.resetWallPapers#bb3b9804 = Bool;
-
-messages.setChatWallPaper#8ffacae1 flags:# for_both:flags.3?true revert:flags.4?true peer:InputPeer wallpaper:flags.0?InputWallPaper settings:flags.2?WallPaperSettings id:flags.1?int = Updates;
+account.resetWallPapers#bb3b9804 = Bool;
Once you've uploaded your wallpaper or received a wallpaper deep link, it can be installed as follows.
Note that fill wallpapers cannot be globally installed using account.installWallPaper or account.saveWallPaper, clients should install and keep track of them only locally, without synchronizing the wallpaper list or signaling installations.
The API keeps a list of wallpapers that the user can set as chat background, including some preinstalled ones.
@@ -150,10 +145,26 @@ Note that calling this method will also automatically save the wallpaper, if it'
messageActionSetChatWallPaper#5060a3f4 flags:# same:flags.0?true for_both:flags.1?true wallpaper:WallPaper = MessageAction;
+messageActionSetSameChatWallPaper#c0787d6d wallpaper:WallPaper = MessageAction;
+
+---functions---
+
+messages.setChatWallPaper#8ffacae1 flags:# for_both:flags.3?true revert:flags.4?true peer:InputPeer wallpaper:flags.0?InputWallPaper settings:flags.2?WallPaperSettings id:flags.1?int = Updates;
+Wallpapers can also be installed in a specific private chat, by using messages.setChatWallPaper: this will emit a messageActionSetChatWallPaper service message, displaying the wallpaper in the UI along with an invitation for the other user to apply the same wallpaper.
+To wallpaper
, pass an:
Wallpapers can also be installed in a specific chat, by using messages.setChatWallPaper: this will emit a messageActionSetChatWallPaper service message, displaying the wallpaper in the UI along with an invitation for the other user to apply the same wallpaper.
If the other user decides to apply the same wallpaper to the chat, messages.setChatWallPaper should be invoked passing the wallpaper settings
received in the messageActionSetChatWallPaper service message (or some different settings, if the user customized them before applying the wallpaper), along with the id
of the messageActionSetChatWallPaper service message, without the wallpaper
: this way, the action will emit a different messageActionSetSameChatWallPaper, which should be displayed in the UI as a simple acknowledgment service message, without the full wallpaper and without an invitation for the other user to apply it (since both participants already just did that).
However, if we have Premium subscription, we can change the other user's wallpaper without explicit confirmation from the other side: to do so, set the for_both
flag when invoking messages.setChatWallPaper.
+This will change the wallpaper for both sides of the chat, without requiring confirmation; the userFull.wallpaper_overridden
flag will also be set for the other user.
+If the other user does not like the new wallpaper we have chosen for them, they can re-set their previous wallpaper just on their side, by invoking messages.setChatWallPaper, providing only the revert
flag (and obviously the peer
parameter).
Note that in order to pass image or pattern wallpapers to messages.setChatWallPaper, the for_chat
flag must be set when uploading them with account.uploadWallPaper.
Also note that unlike account.installWallPaper or account.saveWallPaper, messages.setChatWallPaper accepts fill wallpapers as well.
diff --git a/data/web/corefork.telegram.org/constructor/userFull.html b/data/web/corefork.telegram.org/constructor/userFull.html index a1e71e1330..514545593e 100644 --- a/data/web/corefork.telegram.org/constructor/userFull.html +++ b/data/web/corefork.telegram.org/constructor/userFull.html @@ -124,7 +124,7 @@for_both
flag, see here » for more info.for_both
flag, we can re-set our previous wallpaper just on our side using this flag.