Answer the question
In order to leave comments, you need to log in
How to overcome the error "Wrong response from the webhook: 404 Not Found"?
I created a domain for the bot, got an ssl certificate, checked it for authenticity. I started connecting the webhook and then ran into a problem - I connected the webhook ({"ok":true,"result":true,"description":"Webhook is already set"}), wrote the code for the bot and it doesn't work. At first I started to blame the domain and the ssl certificate for this, but then I realized that they had nothing to do with it. It turns out that when I request https://api.telegram.org/bot[BOT_TOKEN]/getWebhookInfo I get the following error - "last_error_message": "Wrong response from the webhook: 404 Not Found". Can't figure out how to deal with it?
Answer the question
In order to leave comments, you need to log in
Solved the problem: it turns out that it was necessary to place the file with the code for the bot on the server, because only the request will go there and it will be processed there
Make sure that in the domain name you indicate the name of the file with the executable code, and not some other name (For example: the code is called bot.php, so the domain name will look like this - example.com/bot.php)
It seems to be trite, but nowhere is it written about when you start creating a bot from scratch
I hope I explained everything more or less clearly
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question