Closed zsanzharko closed 2 years ago
That error implies that you are running 2 instances of the bot, as per Telegram limitation, you can only run one of them. You should be able to create a simple Bean and then inject it whenever you need your bot.
@rubenlagus Thanks!
Hello! How to use these two classes together using Spring?
Sample code
one of the main clases using TelegramLongPollingBot extention `
`
i have conflict in running the project
org.telegram.telegrambots.meta.exceptions.TelegramApiRequestException: Error getting updates: [409] Conflict: terminated by other getUpdates request; make sure that only one bot instance is running at org.telegram.telegrambots.meta.api.methods.updates.GetUpdates.deserializeResponse(GetUpdates.java:93) ~[telegrambots-meta-5.7.1.jar:na] at org.telegram.telegrambots.updatesreceivers.DefaultBotSession$ReaderThread.getUpdatesFromServer(DefaultBotSession.java:260) ~[telegrambots-5.7.1.jar:na] at org.telegram.telegrambots.updatesreceivers.DefaultBotSession$ReaderThread.run(DefaultBotSession.java:189) ~[telegrambots-5.7.1.jar:na]