fossasia / susi_slackbot

Ask Susi Messengers http://susi.ai
GNU Lesser General Public License v2.1
1.5k stars 26 forks source link

Slack instance not waking up on messaging #16

Closed shivenmian closed 8 years ago

shivenmian commented 8 years ago

@sudheesh001 When I message Slack on asksusi.slack.com, it doesn't message me back right now. Is this because the Slack integration is just a script and not an app, and that I'll have to add routes to it to make it wake up when I message it?

When I messaged on the asksusi FB messenger bot though, it woke up. Is that purely because it's set up as an app and has a webhook? And I'll then have to convert mine too?

We need to get this done quickly, so that teams can add susi to their channels.

sudheesh001 commented 8 years ago

Integration of https://github.com/hubot-scripts/hubot-heroku-keepalive should help ? any keepalive system with curl request pinging itself should keep this alive.

shivenmian commented 8 years ago

@sudheesh001 Still, the 18 hour keepalive limit of Heroku exists right?

We don't want the bot to be alive every second. What we want is the bot to come alive only when we message it. That's what's happening with the Messenger bot too. So probably to implement this, we need to set up the webhooks, and the bots will work on different routes. What do you think?

sudheesh001 commented 8 years ago

the library that you've utilized for slackbots doesn't have the webhook integration available in it. You'd have to include another library for slack-node which supports webhooks and from that call the required functions

shivenmian commented 8 years ago

@sudheesh001 Wouldn't it work if I just wrapped my current code inside an app.post or something, like you did for the Messenger bot? Or will I have to use a different library?

shivenmian commented 8 years ago

@sudheesh001 @mariobehling Please check #18 and give feedback, I have tried to fix this issue.