From 1a7f41c9304a41d4c360185c2921339028d21c60 Mon Sep 17 00:00:00 2001 From: danielperez9430 Date: Thu, 9 Dec 2021 02:27:50 +0100 Subject: [PATCH] docs: Generate new docs --- doc/api.md | 22 ++++++++++++---------- 1 file changed, 12 insertions(+), 10 deletions(-) diff --git a/doc/api.md b/doc/api.md index 6741bfe..7729dcd 100644 --- a/doc/api.md +++ b/doc/api.md @@ -707,9 +707,12 @@ Returns True on success. -### telegramBot.banChatSenderChat(chatId, senderChatId, [options]) ⇒ Promise +### telegramBot.banChatSenderChat(chatId, senderChatId, [options]) ⇒ Boolean Use this method to ban a channel chat in a supergroup or a channel. -The owner of the chat will not be able to send messages and join live streams on behalf of the chat, unless it is unbanned first. +The owner of the chat will not be able to send messages and join live streams +on behalf of the chat, unless it is unbanned first. +The bot must be an administrator in the supergroup or channel for this to work +and must have the appropriate administrator rights. Returns True on success. **Kind**: instance method of [TelegramBot](#TelegramBot) @@ -717,13 +720,13 @@ Returns True on success. | Param | Type | Description | | --- | --- | --- | -| chatId | Number \| String | Unique identifier for the target chat or username of the target channel | -| senderChatId | Number | Unique identifier of the target sender chat | +| chatId | Number \| String | Unique identifier for the target group or username of the target supergroup | +| senderChatId | Number | Unique identifier of the target user | | [options] | Object | Additional Telegram query options | -### telegramBot.unbanChatSenderChat(chatId, senderChatId, [options]) ⇒ Promise +### telegramBot.unbanChatSenderChat(chatId, senderChatId, [options]) ⇒ Boolean Use this method to unban a previously banned channel chat in a supergroup or channel. The bot must be an administrator for this to work and must have the appropriate administrator rights. Returns True on success. @@ -733,8 +736,8 @@ Returns True on success. | Param | Type | Description | | --- | --- | --- | -| chatId | Number \| String | Unique identifier for the target chat or username of the target channel | -| senderChatId | Number | Unique identifier of the target sender chat | +| chatId | Number \| String | Unique identifier for the target group or username of the target supergroup | +| senderChatId | Number | Unique identifier of the target user | | [options] | Object | Additional Telegram query options | @@ -822,7 +825,7 @@ Returns the revoked invite link as ChatInviteLink object. ### telegramBot.approveChatJoinRequest(chatId, userId, [options]) ⇒ Boolean -Use this method to approve a chat join request. +Use this method to approve a chat join request. The bot must be an administrator in the chat for this to work and must have the can_invite_users administrator right. Returns True on success. @@ -1066,8 +1069,7 @@ Otherwise, message type can be changed arbitrarily. When inline message is edite Use previously uploaded file via its file_id or specify a URL. On success, the edited Message is returned. -Note that you must provide one of chat_id, message_id, or -inline_message_id in your request. +Note that you must provide one of chat_id, message_id, or inline_message_id in your request. **Kind**: instance method of [TelegramBot](#TelegramBot) **See**: https://core.telegram.org/bots/api#editmessagemedia