telegram-bot-ruby icon indicating copy to clipboard operation
telegram-bot-ruby copied to clipboard

Deleting messages

Open mafia-007 opened this issue 8 years ago • 10 comments

Telegram Bot API - Deleting messages: https://core.telegram.org/bots/api#deleteMessage

mafia-007 avatar May 11 '17 21:05 mafia-007

What do you mean by that? The link is broken.

ivanovaleksey avatar May 11 '17 22:05 ivanovaleksey

Added method Deleting messages Is testing telegram

mafia-007 avatar May 11 '17 23:05 mafia-007

Sorry I can't understand you.

ivanovaleksey avatar May 12 '17 06:05 ivanovaleksey

The method for deleting messages: deleteMessage is not implement it throws an :

api.rb:53:in `method_missing': undefined method `delete_message' 

when used example:

        @@bot.api.delete_message( chat_id: @id_chat, message_id: @id_mensaje)

LuisGi93 avatar May 28 '17 15:05 LuisGi93

Now I see, thank you for the report. I will take a look in a few hours.

ivanovaleksey avatar May 28 '17 15:05 ivanovaleksey

As I can see deleteMessage method was added in Bot API 3.0 (CHANGELOG), right? We plan to implement API 3.0 changes in #118

ivanovaleksey avatar May 28 '17 20:05 ivanovaleksey

@mafia-007 @LuisGi93 Bot API 3.0 changes was implemented. Please check once again.

ivanovaleksey avatar May 29 '17 21:05 ivanovaleksey

Working fine, for me this issue is resolved.

LuisGi93 avatar Jun 03 '17 11:06 LuisGi93

Hello, is it possible to clear the history of the chat ? if so how ? I tried like bot.api.deleteMessage(chat_id: message.chat.id, message_id: message.from.id) but does not work. Thanks

lecabel avatar Jan 27 '20 06:01 lecabel

@lecabel the gem is just a simple wrapper over Bot API. Please read the documentation thoroughly.

ivanovaleksey avatar Jan 27 '20 08:01 ivanovaleksey

This issue is stale because it has been open 60 days with no activity. Remove stale label or comment or this will be closed in 7 days.

github-actions[bot] avatar Feb 19 '23 15:02 github-actions[bot]