File tree Expand file tree Collapse file tree 5 files changed +5
-3
lines changed
Expand file tree Collapse file tree 5 files changed +5
-3
lines changed Original file line number Diff line number Diff line change @@ -57,7 +57,7 @@ This section walks you through code snippets to set up your Slack bot. If you wa
5757
5858In your app, add the following lines to create your Slack controller using Botkit:
5959``` js
60- const slackController = Botkit .slackbot ();
60+ const slackController = Botkit .slackbot ({ clientSigningSecret : YOUR_SLACK_SIGNING_SECRET } );
6161```
6262
6363Spawn a Slack bot using the controller:
Original file line number Diff line number Diff line change @@ -13,6 +13,7 @@ ASSISTANT_IAM_APIKEY=apikey
1313
1414# SLACK
1515SLACK_TOKEN = your_slack_bot_token
16+ SLACK_SIGNING_SECRET = your_slack_signing_secret
1617
1718# FACEBOOK
1819# FB_ACCESS_TOKEN=your_fb_bot_alphanumeric_access_token
Original file line number Diff line number Diff line change 1616
1717var Botkit = require ( 'botkit' ) ;
1818
19- var controller = Botkit . slackbot ( ) ;
19+ var controller = Botkit . slackbot ( { clientSigningSecret : process . env . SLACK_SIGNING_SECRET } ) ;
2020var bot = controller . spawn ( {
2121 token : process . env . SLACK_TOKEN
2222} ) ;
Original file line number Diff line number Diff line change @@ -10,6 +10,7 @@ WORKSPACE_ID=your_workspace_id
1010
1111# SLACK
1212SLACK_TOKEN = your_slack_bot_token
13+ SLACK_SIGNING_SECRET = your_slack_signing_secret
1314
1415# if is apikey
1516ASSISTANT_IAM_APIKEY = apikey
Original file line number Diff line number Diff line change @@ -27,7 +27,7 @@ var middleware = require('botkit-middleware-watson')({
2727} ) ;
2828
2929// Configure your bot.
30- var slackController = Botkit . slackbot ( ) ;
30+ var slackController = Botkit . slackbot ( { clientSigningSecret : process . env . SLACK_SIGNING_SECRET } ) ;
3131var slackBot = slackController . spawn ( {
3232 token : process . env . SLACK_TOKEN
3333} ) ;
You can’t perform that action at this time.
0 commit comments