Link Search Menu Expand Document

Method: channels.updatePinnedForumTopic

Back to methods index

Pin or unpin forum topics


channelUsername, chat ID, Update, Message or InputChannelSupergroup IDOptional
topic_idintForum topic IDOptional
pinnedBoolWhether to pin or unpin the topicYes

Return type: Updates

Can bots use this method: YES

MadelineProto Example (now async for huge speed and parallelism!):

if (!file_exists('madeline.php')) {
    copy('', 'madeline.php');
include 'madeline.php';

$MadelineProto = new \danog\MadelineProto\API('session.madeline');

$Updates = $MadelineProto->channels->updatePinnedForumTopic(channel: $InputChannel, topic_id: $int, pinned: $Bool, );