diff --git a/data/web/corefork.telegram.org/api/premium.html b/data/web/corefork.telegram.org/api/premium.html index 4811360dff..e1f2bee1bc 100644 --- a/data/web/corefork.telegram.org/api/premium.html +++ b/data/web/corefork.telegram.org/api/premium.html @@ -48,16 +48,22 @@

This page describes how should client apps handle Premium features: for a user-friendly overview of Telegram Premium features, see the Telegram Premium FAQ.

-

Telegram Premium features

+

Telegram Premium users

inputUserSelf#f7c1b13f = InputUser;
 
 user#3ff6ecb0 flags:# self:flags.10?true contact:flags.11?true mutual_contact:flags.12?true deleted:flags.13?true bot:flags.14?true bot_chat_history:flags.15?true bot_nochats:flags.16?true verified:flags.17?true restricted:flags.18?true min:flags.20?true bot_inline_geo:flags.21?true support:flags.23?true scam:flags.24?true apply_min_photo:flags.25?true fake:flags.26?true bot_attach_menu:flags.27?true premium:flags.28?true attach_menu_enabled:flags.29?true id:long access_hash:flags.0?long first_name:flags.1?string last_name:flags.2?string username:flags.3?string phone:flags.4?string photo:flags.5?UserProfilePhoto status:flags.6?UserStatus bot_info_version:flags.14?int restriction_reason:flags.18?Vector<RestrictionReason> bot_inline_placeholder:flags.19?string lang_code:flags.22?string = User;
 
+help.premiumPromo#8a4f3c29 status_text:string status_entities:Vector<MessageEntity> video_sections:Vector<string> videos:Vector<Document> currency:string monthly_amount:long users:Vector<User> = help.PremiumPromo;
+
 ---functions---
 
-users.getUsers#d91a548 id:Vector<InputUser> = Vector<User>;
+users.getUsers#d91a548 id:Vector<InputUser> = Vector<User>; +help.getPremiumPromo#b81b93d4 = help.PremiumPromo; +

Premium users will have the premium flag of the user set.

+

Use users.getUsers with inputUserSelf to fetch info about the current subscription status of the current user.
+You can also directly use help.getPremiumPromo, as it will return info about the current user in the users field.

+

Telegram Premium features

Telegram Premium offers a set of additional features and raised limits: clients should be aware of the current subscription status to accordingly modify client behavior.

-

Use users.getUsers with inputUserSelf to fetch info about the current subscription status from the premium flag of the returned user constructor.

Promo page

help.premiumPromo#8a4f3c29 status_text:string status_entities:Vector<MessageEntity> video_sections:Vector<string> videos:Vector<Document> currency:string monthly_amount:long users:Vector<User> = help.PremiumPromo;
 
@@ -68,35 +74,11 @@
 

Clients should show a Telegram Premium button in the settings.
Clicking on this button in the settings, clicking on the badge of a Premium user or hitting one of the Premium limits listed below should open a Telegram Premium modal.

Call help.getPremiumPromo and help.getAppConfig to fetch info on how to build the premium modal.

-

help.getAppConfig will return a list of Premium features in the premium_promo_order appConfig field, and the modal should contain a row for each feature identifier.

-

The help.premiumPromo constructor returned by help.getPremiumPromo contains the following fields:

+

help.getAppConfig will return a list of Premium feature identifiers in the premium_promo_order appConfig field (array of strings): the modal should contain a row for each returned feature.

+

Possible feature identifiers:

-
Feature identifiers
-

This list contains the feature identifiers returned in the premium_promo_order appConfig array field.

-

Note that whenever config keys end with a * in the following list, the * should be replaced with default or premium, to fetch the appropriate limit value for normal and Premium users.

- +

The help.premiumPromo constructor returned by help.getPremiumPromo contains the following fields:

+ +

Premium limits

+

What follows is a list of appConfig integer config parameters.

+

Note that whenever config keys end with a * in the following list, the * should be replaced with default or premium, to fetch the appropriate limit value for normal and Premium users.

+

Badge

Users with a Telegram Premium subscription (user.premium is set) should have a Telegram Premium badge next to their name.

Animated profile pictures