Closed Resousse closed 1 year ago
@Resousse thanks for working on this but there are few things I want to mention :
Instructions for telegram bot : this is too much hand holding / spoon feeding, I don't support this and creating a bot is very simple plus a lot of tutorials already available on google
API : as I mentioned in the issue as well, webhook will be better since then we can support multiple platforms like telegram and discord at once instead of adding multiple api calls for each
If I understand well, it means that the user provide a URL like 'https://api.telegram.org/botxxxxx:423423/sendMessage?chat_id=123&text=' and the content to be sent is just appended to this url? (I don't know Discord API, but I think this logic won't work) Or the web hook is sent to an endpoint, that expect a specific format and call the telegram/discord API?
Thanks
@Resousse I know the level of some users in the issues section and that is exactly the point due to the nature of this tool most of the users are up to no good for obvious reasons :D
webhooks are basically endpoints where we can simply send POST requests, so users will simply put their webhook url as input, it can be any webhook so basically a URL and in the code we just need to send a POST request, this makes the code much short and simple as we dont need to make api calls
In that issue i suggested them to create a separate script to use api/webhook because this is the first time someone needs to send to a bot, a single person demanding a feature
Actually, I've already thought about this feature, but I told me to wait until the first request :D Do you want webhook in addition to telegram integration or instead? (personally, I would let both of them to have basic/simple integration and a more complex one)
Thanks!
@thewhiteh4t , your advise about my last message?
@Resousse lets add support for tele and webhooks in general, i will review the PR soon, thanks! also sorry for the delay, life happened lol
@thewhiteh4t great!, I've just completed the PR with webhook support. I implemented a very basic retry mechanism, and I tested it with https://webhook.site I let you review this :)
tested and working
As suggested by https://github.com/thewhiteh4t/seeker/issues/454 Here a change to support telegram notification. As a pre-requisite, a telegram bot should be created for this use (see sendToTelegramBot.md file), and token and chat id should be retrieved. Then just provide telegram token & chat Id to seeker : all information/results will be sent to you via telegram, and you will see events directly on your phone
N.B: I've also added a dev Dockerfile to ease testing/devloppement