Created
April 17, 2016 13:26
-
-
Save KimuraTakaumi/a03a69e322d6b2574e8991341b87ca15 to your computer and use it in GitHub Desktop.
Botkitを使ってSlackの応答を返す
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var Botkit = require('botkit'); | |
var controller = Botkit.slackbot({ | |
debug: false | |
}); | |
controller.spawn({ | |
token: process.env.token | |
}).startRTM(); | |
// say techium | |
controller.hears('techium',['direct_message','direct_mention','mention'],function(bot,message) { | |
console.log(message); | |
bot.reply(message,'Hello, techium.'); | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment