This is a sample Slack Bot Application using Rails and Relax. Relax powers bot platforms such as Nestor and Dunstin.
- Install
postgresql
&&redis
- Run
cp .env-example .env
- Create a new Slack Application. Remember: To Setup a Bot User for the application and set a name for the bot.
- Get the Client ID and the Secret from the Slack Application and replace
SLACK_CLIENT_ID
andSLACK_CLIENT_SECRET
in.env
with the client ID and secret respectively. - Download and install relax in your path (make sure the
relax
binary is available in your$PATH
). - Run
rake db:create db:migrate
- Run
./script/server
- Go to
localhost:5000
in your browser
Right now, the bot sends a random greeting when it encounters the string hello
. To change this behavior goto config/initializers/relax.rb
and change the way bot responds to messages.
This project is brought to you by the creators of Nestor – the programmable Slack Bot Platform.