Hi,
I’m about to migrate all my rules DSL rules to JS Scripting and there is one thing I just could not find out in any of the documentation: how to send a telegram message with JS to only one chat ID.
In rules DSL I used this:
val telegramAction = getActions("telegram","telegram:telegramBot:xxx")
telegramAction.sendTelegram(1234L, message)
telegramAction.sendTelegram(2345L, message)
But in JSScripting there is only this method available:
var telegramAction = actions.get("telegram", "telegram:telegramBot:xxx")
telegramAction.sendTelegram(message);
I tried to create separate bots for each chatID, but then I get thousands of warnings “Telegram exception: GetUpdates failed with error_code 409 Conflict: terminated by other getUpdates request; make sure that only one bot instance is running” (which is quite obvious, but at least it is sending correctly).
Is there a way to configure only one bot with several chatIDs and use it in JS like in rules DSL?
Thanks,
Martin