Answer the question
In order to leave comments, you need to log in
Sending messages from telegram bots via https request, how to implement?
Everyone knows that a message from a bot can be sent to a chat by clicking on the link in the browser
https://api.telegram.org/bot50your_bot_token/sendm...
In Mikrotik routers, this is wonderfully implemented in scripts using the fetch utility. On different events, fetch loads the required URL and as a result we get convenient monitoring.
I would like to implement the same thing under windows so that you can track different events and send messages on behalf of the bot.
I tried to implement an http request through the wget utility, the result is not encouraging:
Распознаётся api.telegram.org... 149.154.167.220
Устанавливается соединение с api.telegram.org|149.154.167.220|:443... соединение установлено.
ПРЕДУПРЕЖДЕНИЕ: невозможно проверить сертификат api.telegram.org, запрошенный `/C=US/ST=Arizona/L=Scottsdale/O=GoDaddy.com, Inc./OU=http://certs.godaddy.co
m/repository//CN=Go Daddy Secure Certificate Authority - G2':
Обнаружен самостоятельно подписанный сертификат.
Запрос HTTP послан, ожидается ответ... 400 Bad Request
2018-10-24 08:57:28 ОШИБКА 400: Bad Request.
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question