zapread.com
zapread.com copied to clipboard
WebHooks
Feature Request: ZapRead WebHooks
It would be nice, if I didn't have to poll for zapread events.
If zapread would notify a server I own of new events, I could instantly react to anything which would have the following pros.
- allow for real time bots This would make every bot better, because it's faster. It would actually allow for some types of bots that are kinda unusable right now. Chat bots for example.
- reduce bot traffic I wouldn't have to call /UnreadMessages every 20 min (20 min is very slow for a bot!) if you'd call the bot. It would cost less on both sides to have webhooks.
As a first step it would be nice if I'd be notified about the fact that I have a new message or alert.
That should be relatively easy to implement at first, most events are actually in /Messages/Unread?xyz.
I think other users are also interested in features like this #65
"Draft"
Disclaimer: I have no idea how this is usually done, just thinking how I could solve my problem.
We'd need some UI to enter a url, let's call the variable webhook_url. Then, when there's a new alert or message for me, the server GETs let's say webhook_url + /NewMessageOrAlert.
My server would recieve the GET and then poll /Messages/Unread for new Messages and Alerts, handle them and wait for the next event to occur.
I might not need that anymore, I took a look at the websocket stuff and it's decent!
E.g. a chat bot is already possible!
I couldn't get everything yet, but it is already much more detailed than my proposed webhook. It doesn't seem to trigger for all alerts/messages yet, or I couldn't get it to work yet, but I would actually close this.
I still think it could be useful as an option for some users. I'll leave it open for now.