-
Notifications
You must be signed in to change notification settings - Fork 13
Configure Telegram in able to receive notification
HungPV edited this page Sep 27, 2021
·
5 revisions
(Optional)
This bot supports pushing notification via Telegram, this is how to do it
- Register a Telegram account (if you don't have it)
- Talk to Bot Father as described here and follow a few simple steps. Once you've created a bot and received your authorization token (for example
9999999999:XXXXXXXXXXX-XXXXXXXXXXXXXXXXXXXXXXX
), fill it into thetelegram.token
key on user-config.properties file. For example:telegram.token=9999999999:XXXXXXXXXXX-XXXXXXXXXXXXXXXXXXXXXXX
- Create a private Telegram channel, find the channel id. Here is a stackoverflow topic about it. One found it, fill it into
telegram.channel-id
key on user-config.properties. - Save change
Later on, if you want to disable Telegram, you can choose one of the following ways:
- Remove either value of the telegram keys on user-config.properties
- Provide
--mute
flag when running program
P/s: from 1.7.3
, there is new key added telegram.instance-id
. In case you run bot on multiple machines (for multiple accounts purpose), you can give a value to this flag, it will be added to telegram message so you will know which machine sent this message. For example you filled value boo
into this case: telegram.instance-id=boo
so all Telegram messages from this boo
machine will look like: [AFK:
boo] Finished
Hi, I'm a bot. Please give me a Star for this repository, thank you 😜