I want to set webhook for telegram for certain user input so that telegram replied automatically to predefined question and I am able to write the program which is running perfectly fine, but when I tried to set webhook for that program it is showing an error:
{
"ok": false,"error_code": 400,"description": "Bad Request: bad webhook: Ip is reserved"
}
I tried to set webhook like that:
https://api.telegram.org/bot<token>/setwebhook?url=https://localhost/Manisha/bot.php
You need to use a publically available URL that the Telegram servers can reach. http://localhost/
is not public.
You are trying to make an HTTP request to the computer the bot is running on.
This isn't your server, it is Telegram's server. It doesn't work because:
then how can i do it and is there any publically available URL / server which i can use for my work ?
Rent a VPS or something.