A Slack bot to post daily standup status. It launches a modal, prompting users for Yesterday, Today, Parking Lot Items, and Parking Lot Participants
Add bot to channels where you wish to use it.
/standup [title]
SLS makes it easy to deploy to AWS
Install with the command
npm install -g serverless
sls deploy --stage (prod | dev) [--aws-profile profile-name] [--region us-east-2]
To inspect the size and content of the deployment without deploying anything to AWS
sls package --stage (prod | dev) [--aws-profile profile-name]
You can also check configuration substitutions. This is useful for checking things like the target region
.
sls print --stage (prod | dev)
Create a secret in SecretsManager named SlackStandup-secret-dev
or SlackStandup-secret-prod
, depending on the target environment, with the values
SLACK_STANDUP_BOT_TOKEN
SLACK_STANDUP_SIGNING_SECRET
These can be found on the Slack website. Copy-paste the following values.
In the app's OAuth & Permissions:
In the app's Basic Settings copy the value for Signing Secret:
Testing locally requires Docker, and setting the following environment variables in a .env
file. These are the same values found in the Secrets section of this document.
SLACK_STANDUP_TOKEN
SLACK_STANDUP_SIGNING_SECRET
Deploy to Docker with the following command:
npm run serverless-localstack
This retrieves the local environment variables and creates a secret and DynamoDB table in the Localstack instance.
Localstack is loaded with scripts in src/test/scripts
. These may need updated permissions to execute.
chmod 755 src/test/scripts/*
To connect Slack to this running instance, start ngrok
with either of these commands. This assumes ngrok
is installed in the user's home directory.
npm run ngrok
~/ngrok http 5000
This will create a URL to enter into Slack's Slash Command interface for this app.
This bot uses a Slash Command and enabled Interactivity.
- Slash Commands and Interactivity use the same Request URL, which ends in
/slack/events
- For local testing, set these to the URL generated by
ngrok
- When the app is live, set these to the lambda URL
The app needs permissions to interact with the Slack workspace. Enable OAuth scopes in Slack.
chat:write
chat:write.customize
commands
users.profile:read
users:read
👤 Steve Thompson
Give a ⭐️ if this project helped you!
This README was generated with ❤️ by readme-md-generator