mirror of
https://github.com/aiogram/aiogram.git
synced 2025-12-06 07:50:32 +00:00
* Remove warnings about pytest asyncio mode * Update Bot API to 6.4 * Bump version * Added changelog * Update translations
26 lines
906 B
Python
26 lines
906 B
Python
from __future__ import annotations
|
|
|
|
from typing import TYPE_CHECKING, Any, Dict, Union
|
|
|
|
from .base import Request, TelegramMethod
|
|
|
|
if TYPE_CHECKING:
|
|
from ..client.bot import Bot
|
|
|
|
|
|
class UnhideGeneralForumTopic(TelegramMethod[bool]):
|
|
"""
|
|
Use this method to unhide the '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. Returns :code:`True` on success.
|
|
|
|
Source: https://core.telegram.org/bots/api#unhidegeneralforumtopic
|
|
"""
|
|
|
|
__returning__ = bool
|
|
|
|
chat_id: Union[int, str]
|
|
"""Unique identifier for the target chat or username of the target supergroup (in the format :code:`@supergroupusername`)"""
|
|
|
|
def build_request(self, bot: Bot) -> Request:
|
|
data: Dict[str, Any] = self.dict()
|
|
|
|
return Request(method="unhideGeneralForumTopic", data=data)
|