atipugin / telegram-bot-ruby

Ruby wrapper for Telegram's Bot API
https://core.telegram.org/bots/api
Do What The F*ck You Want To Public License
1.35k stars 218 forks source link

Deleting messages #111

Closed mafia-007 closed 1 year ago

mafia-007 commented 7 years ago
Telegram Bot API - Deleting messages: https://core.telegram.org/bots/api#deleteMessage
ivanovaleksey commented 7 years ago

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

mafia-007 commented 7 years ago

Added method Deleting messages Is testing telegram

ivanovaleksey commented 7 years ago

Sorry I can't understand you.

LuisGi93 commented 7 years ago

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)
ivanovaleksey commented 7 years ago

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

ivanovaleksey commented 7 years ago

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 commented 7 years ago

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

LuisGi93 commented 7 years ago

Working fine, for me this issue is resolved.

lecabel commented 4 years ago

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

ivanovaleksey commented 4 years ago

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

github-actions[bot] commented 1 year ago

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.