Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR PYTHON

send telegram bot message python

import requests

def send_msg(text):
   token = "your_token"
   chat_id = "your_chatId"
   url_req = "https://api.telegram.org/bot" + token + "/sendMessage" + "?chat_id=" + chat_id + "&text=" + text 
   results = requests.get(url_req)
   print(results.json())

send_msg("Hello there!")
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #send #telegram #bot #message #python
ADD COMMENT
Topic
Name
5+3 =