频道和超级组合的提升

电报Telegram Premium用户可以为他们喜爱的频道和超级群组授予额外的功能,例如通过给予推广来发布故事。频道和超级群组会随着获得更多增益而升级——每个级别都会增加额外的功能。

此外,频道管理员还可以通过举办赠送活动获得更多推广机会»。

通道的最大可能提升级别在boosts_channel_level_max配置键中指定。

模式:

myBoost#c448415c flags:# slot:int peer:flags.0?Peer date:int expires:int cooldown_until_date:flags.1?int = MyBoost;premium.myBoosts#9ae228e2 my_boosts:Vector<MyBoost> chats:Vector<Chat> users:Vector<User> = premium.MyBoosts;prepaidGiveaway#b2539d54 id:long months:int quantity:int date:int = PrepaidGiveaway;premium.boostsStatus#4959427a flags:# my_boost:flags.2?true level:int current_level_boosts:int boosts:int gift_boosts:flags.4?int next_level_boosts:flags.0?int premium_audience:flags.1?StatsPercentValue boost_url:string prepaid_giveaways:flags.3?Vector<PrepaidGiveaway> my_boost_slots:flags.2?Vector<int> = premium.BoostsStatus;boost#4b3e14d6 flags:# gift:flags.1?true giveaway:flags.2?true unclaimed:flags.3?true id:string user_id:flags.0?long giveaway_msg_id:flags.2?int date:int expires:int used_gift_slug:flags.4?string multiplier:flags.5?int stars:flags.6?long = Boost;premium.boostsList#86f8613c flags:# count:int boosts:Vector<Boost> next_offset:flags.0?string users:Vector<User> = premium.BoostsList;message#9815cec8 flags:# out:flags.1?true mentioned:flags.4?true media_unread:flags.5?true silent:flags.13?true post:flags.14?true from_scheduled:flags.18?true legacy:flags.19?true edit_hide:flags.21?true pinned:flags.24?true noforwards:flags.26?true invert_media:flags.27?true flags2:# offline:flags2.1?true video_processing_pending:flags2.4?true paid_suggested_post_stars:flags2.8?true paid_suggested_post_ton:flags2.9?true id:int from_id:flags.8?Peer from_boosts_applied:flags.29?int peer_id:Peer saved_peer_id:flags.28?Peer fwd_from:flags.2?MessageFwdHeader via_bot_id:flags.11?long via_business_bot_id:flags2.0?long reply_to:flags.3?MessageReplyHeader date:int message:string media:flags.9?MessageMedia reply_markup:flags.6?ReplyMarkup entities:flags.7?Vector<MessageEntity> views:flags.10?int forwards:flags.10?int replies:flags.23?MessageReplies edit_date:flags.15?int post_author:flags.16?string grouped_id:flags.17?long reactions:flags.20?MessageReactions restriction_reason:flags.22?Vector<RestrictionReason> ttl_period:flags.25?int quick_reply_shortcut_id:flags.30?int effect:flags2.2?long factcheck:flags2.3?FactCheck report_delivery_until_date:flags2.5?int paid_message_stars:flags2.6?long suggested_post:flags2.7?SuggestedPost = Message; channelFull#e4e0b29d flags:# can_view_participants:flags.3?true can_set_username:flags.6?true can_set_stickers:flags.7?true hidden_prehistory:flags.10?true can_set_location:flags.16?true has_scheduled:flags.19?true can_view_stats:flags.20?true blocked:flags.22?true flags2:# can_delete_channel:flags2.0?true antispam:flags2.1?true participants_hidden:flags2.2?true translations_disabled:flags2.3?true stories_pinned_available:flags2.5?true view_forum_as_messages:flags2.6?true restricted_sponsored:flags2.11?true can_view_revenue:flags2.12?true paid_media_allowed:flags2.14?true can_view_stars_revenue:flags2.15?true paid_reactions_available:flags2.16?true stargifts_available:flags2.19?true paid_messages_available:flags2.20?true id:long about:string participants_count:flags.0?int admins_count:flags.1?int kicked_count:flags.2?int banned_count:flags.2?int online_count:flags.13?int read_inbox_max_id:int read_outbox_max_id:int unread_count:int chat_photo:Photo notify_settings:PeerNotifySettings exported_invite:flags.23?ExportedChatInvite bot_info:Vector<BotInfo> migrated_from_chat_id:flags.4?long migrated_from_max_id:flags.4?int pinned_msg_id:flags.5?int stickerset:flags.8?StickerSet available_min_id:flags.9?int folder_id:flags.11?int linked_chat_id:flags.14?long location:flags.15?ChannelLocation slowmode_seconds:flags.17?int slowmode_next_send_date:flags.18?int stats_dc:flags.12?int pts:int call:flags.21?InputGroupCall ttl_period:flags.24?int pending_suggestions:flags.25?Vector<string> groupcall_default_join_as:flags.26?Peer theme_emoticon:flags.27?string requests_pending:flags.28?int recent_requesters:flags.28?Vector<long> default_send_as:flags.29?Peer available_reactions:flags.30?ChatReactions reactions_limit:flags2.13?int stories:flags2.4?PeerStories wallpaper:flags2.7?WallPaper boosts_applied:flags2.8?int boosts_unrestrict:flags2.9?int emojiset:flags2.10?StickerSet bot_verification:flags2.17?BotVerification stargifts_count:flags2.18?int send_paid_messages_stars:flags2.21?long main_tab:flags2.22?ProfileTab = ChatFull;messageActionBoostApply#cc02aa6d boosts:int = MessageAction; messageService#7a800e0a flags:# out:flags.1?true mentioned:flags.4?true media_unread:flags.5?true reactions_are_possible:flags.9?true silent:flags.13?true post:flags.14?true legacy:flags.19?true id:int from_id:flags.8?Peer peer_id:Peer saved_peer_id:flags.28?Peer reply_to:flags.3?MessageReplyHeader date:int action:MessageAction reactions:flags.20?MessageReactions ttl_period:flags.25?int = Message;---functions---premium.getMyBoosts#0be77b4a = premium.MyBoosts; premium.applyBoost#6b7da746 flags:# slots:flags.0?Vector<int> peer:InputPeer = premium.MyBoosts;premium.getBoostsStatus#042f1f61 peer:InputPeer = premium.BoostsStatus;premium.getUserBoosts#39854d1f peer:InputPeer user_id:InputUser = premium.BoostsList;premium.getBoostsList#60f67660 flags:# gifts:flags.0?true peer:InputPeer offset:string limit:int = premium.BoostsList;

每个用户都有一定数量的推广槽位,可以分配给频道和超级群组:具体数量取决于他们是否购买或获赠了高级订阅,可以使用premium.getMyBoosts获取,以及当前占用每个槽位的频道和超级群组的信息(如果有)。

将 Telegram Premium订阅赠送给其他用户将为我们创建boosts_per_sent_gift个新的推广名额,并为接收用户创建一个推广名额。

使用premium.applyBoost将你的一些推广名额分配给频道或超级群组。

PREMIUM_ACCOUNT_REQUIRED如果当前帐户没有Telegram Premium会员资格,则会返回错误。如果用户已使用相同的推广槽位推广指定的频道或超级群组,则调用上述两种方法中的任何一种都会返回 RPC 错误
。BOOST_NOT_MODIFIED

在为某个槽位分配频道或超级组之后,用户在myBoost字段中指定的冷却时间内,不能更改该槽位的增强频道或超级组:cooldown_until_date如果冷却时间尚未结束,该方法将返回 420FLOOD_WAIT_X错误,指示在可以增强其他频道或超级组之前剩余的秒数。

用户还可以调用premium.getBoostsStatus来获取频道或超级组的当前提升状态。作为premium.boostsStatus构造函数,请查看构造函数页面以获取更多信息。

我们当前分配给频道/超级组的推广次数也会在channelFull中显示。boosts_applied

频道或超级群组管理员可以调用premium.getBoostsList来获取当前正在推广频道或超级群组的用户列表,并调用premium.getUserBoosts来获取有关特定用户向频道或超级群组发送的推广信息。

提升频道或超级群组将发出(不会立即发出,最多 15 秒后发出,以便对重复提升进行分组)一个消息服务,其中包含一个消息操作提升应用到所有用户(超级群组)或仅发送者(频道)的消息,其from_id值等于提升的发送者。

特征

以频道或超级群组的形式发布故事

每次推广后,频道和超级群组每天可以向其订阅者的动态消息中额外发布 1 条动态。

inputPeerChannel#27bcbbfc channel_id:long access_hash:long = InputPeer;messages.chats#64ff9fd5 chats:Vector<Chat> = messages.Chats;---functions---stories.getChatsToSend#a56a8b60 = messages.Chats;

一切操作都与用户发布故事时完全相同,唯一的区别是客户端应该将适当的inputPeerChannel而不是inputPeerSelf传递给stories.canSendStory、stories.sendStory和所有其他故事方法,请参阅主文档»了解更多信息。

使用stories.getChatsToSend获取用户可以发布故事的频道或超级群组列表;在上传故事之前,仍然必须使用stories.canSendStory来确保没有达到其他限制,如主文档中所述 »。

超级群组消息的提升指标

仅当收到来自非匿名群组成员的超级群组消息时,`message.` 字段from_boosts_applied包含消息作者为该超级群组分配的转发次数。此计数器
应显示在用户界面消息头中。请注意,对于
非匿名发出的超级群组消息,应根据 `channelFull.` 的当前值本地覆盖 `message.`的值,以确保即使对于当前用户在超级群组被转发之前(或转发过期或转发次数发生变化之后)发送的消息,该值也正确;即使其他用户的转发次数发生变化,也不要更新来自他们的消息的此值。from_boosts_appliedboosts_applied

频道自动翻译

channel_autotranslation_level_min当频道达到配置参数中指定的提升级别后,频道即可为所有用户启用自动翻译功能。

更改消息强调色

当所选调色板的help.peerColorOptionchannel_min_level构造函数字段中指定的增强级别达到一定值后,(只有)频道才能更改其消息强调调色板 »。

更改消息重音表情符号

channel_bg_icon_level_min达到配置参数中指定的提升级别后,(只有)频道才能更改消息强调调色板中使用的表情符号 »。

更改个人资料强调色/表情符号

channel_profile_bg_icon_level_min 当频道/超级组达到»/group_profile_bg_icon_level_min »配置参数中指定的提升级别以及所选调色板的help.peerColorOptionchannel_min_level构造函数的/字段中指定的提升级别后,频道/超级组即可更改个人资料强调调色板中使用的表情符号和颜色 »。group_min_level

设置壁纸

当频道/超级组达到至少在channel_wallpaper_level_min “/group_wallpaper_level_min ”配置参数中指定的增强级别后,它们将能够设置填充频道/超级组壁纸,详情请参见此处“/”配置参数。当频道/超级组
达到至少在channel_custom_wallpaper_level_min “/group_custom_wallpaper_level_min ”配置参数中指定的增强级别后,它们将能够设置任何自定义壁纸,而不仅仅是填充频道/超级组壁纸,详情请参见此处“/”配置参数。

设置自定义表情符号状态

channel_emoji_status_level_min 当频道/超级群组达到“/group_emoji_status_level_min ”配置参数中指定的提升级别后,它们将能够更改其状态表情符号。

绕过慢模式和聊天限制

channelFull#e4e0b29d flags:# can_view_participants:flags.3?true can_set_username:flags.6?true can_set_stickers:flags.7?true hidden_prehistory:flags.10?true can_set_location:flags.16?true has_scheduled:flags.19?true can_view_stats:flags.20?true blocked:flags.22?true flags2:# can_delete_channel:flags2.0?true antispam:flags2.1?true participants_hidden:flags2.2?true translations_disabled:flags2.3?true stories_pinned_available:flags2.5?true view_forum_as_messages:flags2.6?true restricted_sponsored:flags2.11?true can_view_revenue:flags2.12?true paid_media_allowed:flags2.14?true can_view_stars_revenue:flags2.15?true paid_reactions_available:flags2.16?true stargifts_available:flags2.19?true paid_messages_available:flags2.20?true id:long about:string participants_count:flags.0?int admins_count:flags.1?int kicked_count:flags.2?int banned_count:flags.2?int online_count:flags.13?int read_inbox_max_id:int read_outbox_max_id:int unread_count:int chat_photo:Photo notify_settings:PeerNotifySettings exported_invite:flags.23?ExportedChatInvite bot_info:Vector<BotInfo> migrated_from_chat_id:flags.4?long migrated_from_max_id:flags.4?int pinned_msg_id:flags.5?int stickerset:flags.8?StickerSet available_min_id:flags.9?int folder_id:flags.11?int linked_chat_id:flags.14?long location:flags.15?ChannelLocation slowmode_seconds:flags.17?int slowmode_next_send_date:flags.18?int stats_dc:flags.12?int pts:int call:flags.21?InputGroupCall ttl_period:flags.24?int pending_suggestions:flags.25?Vector<string> groupcall_default_join_as:flags.26?Peer theme_emoticon:flags.27?string requests_pending:flags.28?int recent_requesters:flags.28?Vector<long> default_send_as:flags.29?Peer available_reactions:flags.30?ChatReactions reactions_limit:flags2.13?int stories:flags2.4?PeerStories wallpaper:flags2.7?WallPaper boosts_applied:flags2.8?int boosts_unrestrict:flags2.9?int emojiset:flags2.10?StickerSet bot_verification:flags2.17?BotVerification stargifts_count:flags2.18?int send_paid_messages_stars:flags2.21?long main_tab:flags2.22?ProfileTab = ChatFull;---functions---channels.setBoostsToUnblockRestrictions#ad399cee channel:InputChannel boosts:int = Updates;

拥有ban_users 管理员权限的超级组管理员 »可以允许对组应用一定数量的提升的用户绕过慢速模式 »以及其他 »超级组限制,使用channels.setBoostsToUnblockRestrictions。

必须在参数中指定所需的提升次数boosts(1-8,0 表示禁用),并将在channelFull中返回。boosts_unrestrict

为超级组合设置自定义表情贴纸集

channelFull#e4e0b29d flags:# can_view_participants:flags.3?true can_set_username:flags.6?true can_set_stickers:flags.7?true hidden_prehistory:flags.10?true can_set_location:flags.16?true has_scheduled:flags.19?true can_view_stats:flags.20?true blocked:flags.22?true flags2:# can_delete_channel:flags2.0?true antispam:flags2.1?true participants_hidden:flags2.2?true translations_disabled:flags2.3?true stories_pinned_available:flags2.5?true view_forum_as_messages:flags2.6?true restricted_sponsored:flags2.11?true can_view_revenue:flags2.12?true paid_media_allowed:flags2.14?true can_view_stars_revenue:flags2.15?true paid_reactions_available:flags2.16?true stargifts_available:flags2.19?true paid_messages_available:flags2.20?true id:long about:string participants_count:flags.0?int admins_count:flags.1?int kicked_count:flags.2?int banned_count:flags.2?int online_count:flags.13?int read_inbox_max_id:int read_outbox_max_id:int unread_count:int chat_photo:Photo notify_settings:PeerNotifySettings exported_invite:flags.23?ExportedChatInvite bot_info:Vector<BotInfo> migrated_from_chat_id:flags.4?long migrated_from_max_id:flags.4?int pinned_msg_id:flags.5?int stickerset:flags.8?StickerSet available_min_id:flags.9?int folder_id:flags.11?int linked_chat_id:flags.14?long location:flags.15?ChannelLocation slowmode_seconds:flags.17?int slowmode_next_send_date:flags.18?int stats_dc:flags.12?int pts:int call:flags.21?InputGroupCall ttl_period:flags.24?int pending_suggestions:flags.25?Vector<string> groupcall_default_join_as:flags.26?Peer theme_emoticon:flags.27?string requests_pending:flags.28?int recent_requesters:flags.28?Vector<long> default_send_as:flags.29?Peer available_reactions:flags.30?ChatReactions reactions_limit:flags2.13?int stories:flags2.4?PeerStories wallpaper:flags2.7?WallPaper boosts_applied:flags2.8?int boosts_unrestrict:flags2.9?int emojiset:flags2.10?StickerSet bot_verification:flags2.17?BotVerification stargifts_count:flags2.18?int send_paid_messages_stars:flags2.21?long main_tab:flags2.22?ProfileTab = ChatFull;channelAdminLogEventActionChangeEmojiStickerSet#46d840ab prev_stickerset:InputStickerSet new_stickerset:InputStickerSet = ChannelAdminLogEventAction;---functions---channels.setEmojiStickers#3cd930b7 channel:InputChannel stickerset:InputStickerSet = Bool;

group_emoji_stickers_level_min 当超级群组达到“配置参数”中指定的至少提升级别后,它们将能够关联自定义表情贴纸集,群组中的所有用户(包括非高级用户!)都可以在群组内发送的消息中使用该贴纸集。

此功能是超级群组贴纸集功能的自定义表情贴纸集对应功能,可通过channels.setStickers获取。

调用channels.setEmojiStickers来选择要与超级组关联的自定义表情贴纸集,该贴纸集将对channelFull中的用户可用。emojiset在选择自定义表情时,应优先考虑此设置;调用该方法后, 将在管理日志中发出channelAdminLogEventActionChangeEmojiStickerSet事件。

为超级乐队提供无限量的语音留言转录服务

group_transcribe_level_min 当达到“配置参数”中指定的至少提升级别后,超级组中的非高级用户将能够转录任何语音消息,而不会消耗其免费转录配额。

关闭频道广告

channelFull#e4e0b29d flags:# can_view_participants:flags.3?true can_set_username:flags.6?true can_set_stickers:flags.7?true hidden_prehistory:flags.10?true can_set_location:flags.16?true has_scheduled:flags.19?true can_view_stats:flags.20?true blocked:flags.22?true flags2:# can_delete_channel:flags2.0?true antispam:flags2.1?true participants_hidden:flags2.2?true translations_disabled:flags2.3?true stories_pinned_available:flags2.5?true view_forum_as_messages:flags2.6?true restricted_sponsored:flags2.11?true can_view_revenue:flags2.12?true paid_media_allowed:flags2.14?true can_view_stars_revenue:flags2.15?true paid_reactions_available:flags2.16?true stargifts_available:flags2.19?true paid_messages_available:flags2.20?true id:long about:string participants_count:flags.0?int admins_count:flags.1?int kicked_count:flags.2?int banned_count:flags.2?int online_count:flags.13?int read_inbox_max_id:int read_outbox_max_id:int unread_count:int chat_photo:Photo notify_settings:PeerNotifySettings exported_invite:flags.23?ExportedChatInvite bot_info:Vector<BotInfo> migrated_from_chat_id:flags.4?long migrated_from_max_id:flags.4?int pinned_msg_id:flags.5?int stickerset:flags.8?StickerSet available_min_id:flags.9?int folder_id:flags.11?int linked_chat_id:flags.14?long location:flags.15?ChannelLocation slowmode_seconds:flags.17?int slowmode_next_send_date:flags.18?int stats_dc:flags.12?int pts:int call:flags.21?InputGroupCall ttl_period:flags.24?int pending_suggestions:flags.25?Vector<string> groupcall_default_join_as:flags.26?Peer theme_emoticon:flags.27?string requests_pending:flags.28?int recent_requesters:flags.28?Vector<long> default_send_as:flags.29?Peer available_reactions:flags.30?ChatReactions reactions_limit:flags2.13?int stories:flags2.4?PeerStories wallpaper:flags2.7?WallPaper boosts_applied:flags2.8?int boosts_unrestrict:flags2.9?int emojiset:flags2.10?StickerSet bot_verification:flags2.17?BotVerification stargifts_count:flags2.18?int send_paid_messages_stars:flags2.21?long main_tab:flags2.22?ProfileTab = ChatFull;---functions---channels.restrictSponsoredMessages#9ae91519 channel:InputChannel restricted:Bool = Updates;

channel_restrict_sponsored_level_min 当频道达到“配置”参数中指定的提升级别后,频道所有者可以使用channels.restrictSponsoredMessages为所有用户禁用频道上的广告。

如果频道上禁用了广告,则会设置channelFull标志(仅限所有者) 。restricted_sponsored