chatbot-in-20-mins
chatbot-in-20-mins copied to clipboard
This repo contains everything you need to get started building a Slack bot with Botkit
Materials for "Chatbot in 20 minutes" presentation
This repo contains everything you need to get started building a Slack bot with Botkit. The repo is a modified version of Botkit Starter Slack project.
Getting Started
- Remix a project on Glitch
- Change auto-generated project name to one that makes more sense
Configure Slack
- Create new Slack application here
- Set
client idandclient secretvalues in.envfile - Set a nice bot icon
- Open
<OAuth & Permissions>and set redirect url to<botUrl>/oauth - Open
<Interactive Components>and set request url to<botUrl>/slack/receive - Open
<Event subscriptions>and set request url to<botUrl>/slack/receive - Open and enable
<Bot User Events>. Enable events, set request url to<botUrl>/slack/receiveand include all/message.*/workspace events - Open
<Bot Users>, check<Always Show My Bot as Online>and add the bot user - Visit the
<botUrl>and press<Add to Slack>
Let's code!
- Invite bot to a channel
- Implement skills/welcome_on_join.js (reinstall the bot if it doesn work)
- Implement skills/say_something.js
- Open
<Slash commands>and set up/picslash command that points to<botUrl>/slack/receive. The Slack should prompt you to reinstall the bot. Follow<reinstall>link - Implement skills/pic.js
- Enhance skills/pic.js with recommendations
- Implement skills/respond_on_endorsement.js