Hello There, Guest! Login Register
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5

Error in commands notify-service-by-telegram and notify-host-by-telegram

#6
Posting this here in case it helps someone since I couldn't find a straight forward explanation.  There may be a simpler way of doing this, but this is how I made it work.  None of this is my original work, so I've included links to where I found the answers.  

First create a bot: 

Within the Telegram app, send a message to @BotFather
/start
/newbot <botname>

Make note of the Token you receive in return.  This is what you'll use for the "Your Bot" field in NEMS System Settings Tool (must add 'bot' before the token). 
https://core.telegram.org/bots#3-how-do-i-create-a-bot

Allow your bot to join groups: 
send a message to @BotFather
/setjoingroups
<botname>

The Chat ID seems to be a bit tricky to obtain.  
Compose a new message in Telegram, choosing the new group option.   
Add <botname> to the group.

Message your bot. 
/my_id <botname>
https://api.telegram.org/bot<Token>/getUpdates

Look for 'chat":{"id":'.   The id will be something like -12345678910. This is what you'll use for the Chat ID.   

https://stackoverflow.com/questions/3242...up-chat-id


Hit save and hopefully you'll be in business.
 Reply
 
Messages In This Thread
 
Forum Jump:

Users browsing this thread: 1 Guest(s)