Keepin' the Herd in Line - Integrating a Slack Workflow for Feed Order Reminders
Set up Slack workflows for automated reminders
- Go to Slack Automations
- Create a new Workflow using the Slack Workflow Builder
💡 Tip: Use your username as prefix for the Workflow name to make it unique 💡 Tip: Make the workflow name something meaningful
- Set Trigger. There are a lot of different options here, but we're going to do an event based workflow using a Webhook.
- Trigger: Webhook
- Copy the generated webhook URL
- Add the webhook URL to your Heroku Config Settings
heroku config:set SLACK_WEBHOOK_URL='your-Slack-Webhook-URL'❗️Warning: Keep you webhook url secure.
- Add a Slack Message Step in the Workflow & select a channel/recipient
- Message: "The herd's feed supply is running low. Cowpoke
<your username>says it's time to order more feed.!" - Channnel
#supply-orders
- Message: "The herd's feed supply is running low. Cowpoke
- Test the Workflow
- Currently the app starts with a feed level of 40% and the notification is triggered when the feed level goes below 25%.
- "Feed" the cattle twice to take the feed level down to 20% and check the
supply-orderschannel for the automated response.