Skip to content

reopenGeneralForumTopic

Returns: TrueOfficial docs ↗

Use this method to reopen a closed 'General' topic in a forum supergroup chat. The bot must be an administrator in the chat for this to work and must have the can_manage_topics administrator rights. The topic will be automatically unhidden if it was hidden. Returns True on success.

Parameters

chat_idIntegerStringRequired
Unique identifier for the target chat or username of the target supergroup (in the format @supergroupusername)

Returns

On success, True is returned.

GramIO Usage

ts
// Context shorthand — reopens the General topic in the current chat
// (chat_id is injected automatically from the context)
bot
.
on
("general_forum_topic_hidden", async (
ctx
) => {
await
ctx
.
reopenGeneralTopic
();
});
ts
// Direct API call with explicit chat_id
await 
bot
.
api
.
reopenGeneralForumTopic
({
chat_id
: -1001234567890 });
ts
// Reopen the General topic in the current chat via command
bot
.
command
("opengeneraltopic", async (
ctx
) => {
await
bot
.
api
.
reopenGeneralForumTopic
({
chat_id
:
ctx
.
chat
.
id
});
await
ctx
.
reply
("General topic has been reopened.");
});
ts
// Reopen General topic by supergroup username
await 
bot
.
api
.
reopenGeneralForumTopic
({
chat_id
: "@mysupergroup" });

Errors

CodeErrorCause
400Bad Request: chat not foundchat_id is invalid or the bot is not a member of the chat
400Bad Request: TOPIC_NOT_MODIFIEDThe General topic is already open — no state change needed
400Bad Request: method is available only for supergroupsThe target chat is not a supergroup with forum mode enabled
403Forbidden: not enough rightsBot lacks the can_manage_topics admin right — required without exception for the General topic
429Too Many Requests: retry after NRate limit hit — check retry_after and use the auto-retry plugin

Tips & Gotchas

  • Automatically unhides the topic. Unlike reopenForumTopic, calling reopenGeneralForumTopic also unhides the General topic if it was previously hidden with hideGeneralForumTopic. You do not need to call unhideGeneralForumTopic separately.
  • can_manage_topics is always required. Unlike regular forum topics where the bot can manage topics it created, the General topic always requires the can_manage_topics admin right — there is no creator exemption.
  • Forum mode must be enabled. This method only works in supergroups where the "Topics" (forum) feature is turned on. Calling it on a regular group or channel returns an error.
  • Context shorthand ctx.reopenGeneralTopic() automatically fills chat_id from the current message context — use it inside message/update handlers for cleaner code.
  • The General topic is special. Unlike other topics it cannot be created or deleted — only opened, closed, hidden, and unhidden. Manage it with the dedicated *GeneralForumTopic methods.

See Also