From c5f35694718a6b45f3a107440eb5ee5002bba5fa Mon Sep 17 00:00:00 2001 From: Alex Root Junior Date: Sat, 7 Jan 2023 22:41:36 +0200 Subject: [PATCH] Update from API docs --- .butcher/methods/editForumTopic/entity.json | 6 +++--- .butcher/methods/getChatMember/entity.json | 6 +++--- .butcher/schema/schema.json | 12 ++++++------ aiogram/client/bot.py | 4 ++-- aiogram/methods/edit_forum_topic.py | 2 +- aiogram/methods/get_chat_member.py | 2 +- aiogram/types/chat.py | 2 +- 7 files changed, 17 insertions(+), 17 deletions(-) diff --git a/.butcher/methods/editForumTopic/entity.json b/.butcher/methods/editForumTopic/entity.json index 57bd3d5b..8b65f5c9 100644 --- a/.butcher/methods/editForumTopic/entity.json +++ b/.butcher/methods/editForumTopic/entity.json @@ -32,9 +32,9 @@ { "type": "String", "required": false, - "description": "New topic name, 0-128 characters. If not specififed or empty, the current name of the topic will be kept", - "html_description": "New topic name, 0-128 characters. If not specififed or empty, the current name of the topic will be kept", - "rst_description": "New topic name, 0-128 characters. If not specififed or empty, the current name of the topic will be kept\n", + "description": "New topic name, 0-128 characters. If not specified or empty, the current name of the topic will be kept", + "html_description": "New topic name, 0-128 characters. If not specified or empty, the current name of the topic will be kept", + "rst_description": "New topic name, 0-128 characters. If not specified or empty, the current name of the topic will be kept\n", "name": "name" }, { diff --git a/.butcher/methods/getChatMember/entity.json b/.butcher/methods/getChatMember/entity.json index b33af127..57a4e1c2 100644 --- a/.butcher/methods/getChatMember/entity.json +++ b/.butcher/methods/getChatMember/entity.json @@ -9,9 +9,9 @@ "object": { "anchor": "getchatmember", "name": "getChatMember", - "description": "Use this method to get information about a member of a chat. The method is guaranteed to work only if the bot is an administrator in the chat. Returns a ChatMember object on success.", - "html_description": "

Use this method to get information about a member of a chat. The method is guaranteed to work only if the bot is an administrator in the chat. Returns a ChatMember object on success.

", - "rst_description": "Use this method to get information about a member of a chat. The method is guaranteed to work only if the bot is an administrator in the chat. Returns a :class:`aiogram.types.chat_member.ChatMember` object on success.", + "description": "Use this method to get information about a member of a chat. The method is guaranteed to work for other users, only if the bot is an administrator in the chat. Returns a ChatMember object on success.", + "html_description": "

Use this method to get information about a member of a chat. The method is guaranteed to work for other users, only if the bot is an administrator in the chat. Returns a ChatMember object on success.

", + "rst_description": "Use this method to get information about a member of a chat. The method is guaranteed to work for other users, only if the bot is an administrator in the chat. Returns a :class:`aiogram.types.chat_member.ChatMember` object on success.", "annotations": [ { "type": "Integer or String", diff --git a/.butcher/schema/schema.json b/.butcher/schema/schema.json index b79d08ae..1594155f 100644 --- a/.butcher/schema/schema.json +++ b/.butcher/schema/schema.json @@ -7282,9 +7282,9 @@ { "anchor": "getchatmember", "name": "getChatMember", - "description": "Use this method to get information about a member of a chat. The method is guaranteed to work only if the bot is an administrator in the chat. Returns a ChatMember object on success.", - "html_description": "

Use this method to get information about a member of a chat. The method is guaranteed to work only if the bot is an administrator in the chat. Returns a ChatMember object on success.

", - "rst_description": "Use this method to get information about a member of a chat. The method is guaranteed to work only if the bot is an administrator in the chat. Returns a :class:`aiogram.types.chat_member.ChatMember` object on success.", + "description": "Use this method to get information about a member of a chat. The method is guaranteed to work for other users, only if the bot is an administrator in the chat. Returns a ChatMember object on success.", + "html_description": "

Use this method to get information about a member of a chat. The method is guaranteed to work for other users, only if the bot is an administrator in the chat. Returns a ChatMember object on success.

", + "rst_description": "Use this method to get information about a member of a chat. The method is guaranteed to work for other users, only if the bot is an administrator in the chat. Returns a :class:`aiogram.types.chat_member.ChatMember` object on success.", "annotations": [ { "type": "Integer or String", @@ -7426,9 +7426,9 @@ { "type": "String", "required": false, - "description": "New topic name, 0-128 characters. If not specififed or empty, the current name of the topic will be kept", - "html_description": "New topic name, 0-128 characters. If not specififed or empty, the current name of the topic will be kept", - "rst_description": "New topic name, 0-128 characters. If not specififed or empty, the current name of the topic will be kept\n", + "description": "New topic name, 0-128 characters. If not specified or empty, the current name of the topic will be kept", + "html_description": "New topic name, 0-128 characters. If not specified or empty, the current name of the topic will be kept", + "rst_description": "New topic name, 0-128 characters. If not specified or empty, the current name of the topic will be kept\n", "name": "name" }, { diff --git a/aiogram/client/bot.py b/aiogram/client/bot.py index f293da9f..f5fb2285 100644 --- a/aiogram/client/bot.py +++ b/aiogram/client/bot.py @@ -1117,7 +1117,7 @@ class Bot(ContextInstanceMixin["Bot"]): :param chat_id: Unique identifier for the target chat or username of the target supergroup (in the format :code:`@supergroupusername`) :param message_thread_id: Unique identifier for the target message thread of the forum topic - :param name: New topic name, 0-128 characters. If not specififed or empty, the current name of the topic will be kept + :param name: New topic name, 0-128 characters. If not specified or empty, the current name of the topic will be kept :param icon_custom_emoji_id: New unique identifier of the custom emoji shown as the topic icon. Use :class:`aiogram.methods.get_forum_topic_icon_stickers.GetForumTopicIconStickers` to get all allowed custom emoji identifiers. Pass an empty string to remove the icon. If not specified, the current icon will be kept :param request_timeout: Request timeout :return: Returns :code:`True` on success. @@ -1417,7 +1417,7 @@ class Bot(ContextInstanceMixin["Bot"]): ChatMemberBanned, ]: """ - Use this method to get information about a member of a chat. The method is guaranteed to work only if the bot is an administrator in the chat. Returns a :class:`aiogram.types.chat_member.ChatMember` object on success. + Use this method to get information about a member of a chat. The method is guaranteed to work for other users, only if the bot is an administrator in the chat. Returns a :class:`aiogram.types.chat_member.ChatMember` object on success. :param chat_id: Unique identifier for the target chat or username of the target supergroup or channel (in the format :code:`@channelusername`) :param user_id: Unique identifier of the target user diff --git a/aiogram/methods/edit_forum_topic.py b/aiogram/methods/edit_forum_topic.py index 64a78558..2e76a190 100644 --- a/aiogram/methods/edit_forum_topic.py +++ b/aiogram/methods/edit_forum_topic.py @@ -22,7 +22,7 @@ class EditForumTopic(TelegramMethod[bool]): message_thread_id: int """Unique identifier for the target message thread of the forum topic""" name: Optional[str] = None - """New topic name, 0-128 characters. If not specififed or empty, the current name of the topic will be kept""" + """New topic name, 0-128 characters. If not specified or empty, the current name of the topic will be kept""" icon_custom_emoji_id: Optional[str] = None """New unique identifier of the custom emoji shown as the topic icon. Use :class:`aiogram.methods.get_forum_topic_icon_stickers.GetForumTopicIconStickers` to get all allowed custom emoji identifiers. Pass an empty string to remove the icon. If not specified, the current icon will be kept""" diff --git a/aiogram/methods/get_chat_member.py b/aiogram/methods/get_chat_member.py index 29d264ab..2d4e9d0b 100644 --- a/aiogram/methods/get_chat_member.py +++ b/aiogram/methods/get_chat_member.py @@ -29,7 +29,7 @@ class GetChatMember( ] ): """ - Use this method to get information about a member of a chat. The method is guaranteed to work only if the bot is an administrator in the chat. Returns a :class:`aiogram.types.chat_member.ChatMember` object on success. + Use this method to get information about a member of a chat. The method is guaranteed to work for other users, only if the bot is an administrator in the chat. Returns a :class:`aiogram.types.chat_member.ChatMember` object on success. Source: https://core.telegram.org/bots/api#getchatmember """ diff --git a/aiogram/types/chat.py b/aiogram/types/chat.py index 78e7c301..7dc9baf8 100644 --- a/aiogram/types/chat.py +++ b/aiogram/types/chat.py @@ -506,7 +506,7 @@ class Chat(TelegramObject): - :code:`chat_id` - Use this method to get information about a member of a chat. The method is guaranteed to work only if the bot is an administrator in the chat. Returns a :class:`aiogram.types.chat_member.ChatMember` object on success. + Use this method to get information about a member of a chat. The method is guaranteed to work for other users, only if the bot is an administrator in the chat. Returns a :class:`aiogram.types.chat_member.ChatMember` object on success. Source: https://core.telegram.org/bots/api#getchatmember