Class TelegramConfig
java.lang.Object
es.urjc.etsii.grafo.services.messaging.TelegramConfig
@Configuration
@ConfigurationProperties(prefix="event.telegram")
public class TelegramConfig
extends Object
Telegram configuration, see event.telegram section inside the application.yml file.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionDestination Chat ID, where we will send the messagesgetToken()Telegram API token, as returned by BotFatherbooleanIs the Telegram integration enabled?voidDestination Chat ID, where we will send the messagesvoidsetEnabled(boolean enabled) Is the Telegram integration enabled?voidTelegram API token, as returned by BotFather
-
Constructor Details
-
TelegramConfig
public TelegramConfig()
-
-
Method Details
-
isEnabled
public boolean isEnabled()Is the Telegram integration enabled?- Returns:
- true if enabled, false otherwise
-
setEnabled
public void setEnabled(boolean enabled) Is the Telegram integration enabled?- Parameters:
enabled- true to enablee, false otherwise
-
getToken
Telegram API token, as returned by BotFather- Returns:
- Telegram API token
-
setToken
Telegram API token, as returned by BotFather- Parameters:
token- Telegram API token
-
getChatId
Destination Chat ID, where we will send the messages- Returns:
- destination chat ID.
-
setChatId
Destination Chat ID, where we will send the messages- Parameters:
chatId- destination chat ID.
-