Name: slack-grouper
Owner: Human Made
Description: User group commands for slack
Created: 2017-03-29 19:23:25.0
Updated: 2017-04-06 03:46:11.0
Pushed: 2017-04-11 15:09:33.0
Homepage: null
Size: 26
Language: JavaScript
GitHub Committers
User | Most Recent Commit | # Commits |
---|
Other Committers
User | Most Recent Commit | # Commits |
---|
Create a serverless Slack App with AWS Lambda, API Gateway, DynamoDB, and CloudFormation. All services will be automatically provisioned for you. All that's needed is your Slack App keys.
Setup your AWS Credentials
Install Serverless.js
install -g serverless
Install The Serverless Slack App Template and provision all AWS services
erless install --url https://github.com/johnagan/serverless-slack-app
erverless-slack-app
install
erless deploy
Slack | Serverless :—:|:—: |
serverless deploy
/greet
lash Command handler
k.on('/greet', (msg, bot) => {
t message = {
text: "How would you like to greet the channel?",
attachments: [{
fallback: 'actions',
callback_id: "greetings_click",
actions: [
{ type: "button", name: "Wave", text: ":wave:", value: ":wave:" },
{ type: "button", name: "Hello", text: "Hello", value: "Hello" },
{ type: "button", name: "Howdy", text: "Howdy", value: "Howdy" },
{ type: "button", name: "Hiya", text: "Hiya", value: "Hiya" }
]
}]
ephemeral reply
t.replyPrivate(message);
nteractive Message handler
k.on('greetings_click', (msg, bot) => {
t message = {
// selected button value
text: msg.actions[0].value
public reply
t.reply(message);
serverless deploy
to deploy your changes to AWSAll the tokens and urls above were invalidated before posting this tutorial. You will need to use your own tokens