Slack
Easily send messages to a Slack channel when users take actions in your Flows
Create a Slack Workflow
In Slack, open the Workflow page by searching for Workflows in the search bar and click the Create a Workflow button. Then, choose the From a webhook option:
Create a webhook in Frigade
Copy the Webhook request URL from Slack. Then press X.
In the Frigade dashboard, navigate to the Developer section and click on Webhooks. Click the New webhook button and fill in the details as shown below with your Flow of choice. In this example, we use a simple Form Flow:
Set up data variables in Slack
In the Slack Workflow, click the Starts with a webhook card at the top and add the variables you’d like to send in your Slack message as seen below:
By default Frigade sends user__email
and user__name
for the given user if the data has been provided in the SDK. In this case, we also want to send the value of the message
field from the Form Flow. To do this, we add a new variable data__data__message
to map it to the field. You can target any field in a Frigade Form by prefixing the variable name with data__data__
.
industry
you should use data__data__industry__label
to get the label or data__data__industry__value
to get the value.Send a message to a Slack channel
Add a new step to the Slack Workflow by clicking the Messages link in the right menu. Then pick your channel of choice and add the variables you’d like to send in your Slack message as seen below:
Finally, hit the Publish button in the top right corner to make your Slack Workflow live.
Test your Slack integration
You’re now all set to test your Slack integration. In your application, complete the Flow you’ve set up the webhook for. In this case, we’ll submit the Form Flow:
After completing a step in the Frigade Flow, you should now see the following show up in your Slack channel:
That’s it! You’ve successfully integrated Slack with Frigade. Remember, Frigade webhooks are unique for the Development and Production environments, so make sure to create a new webhook for each environment you want to integrate with Slack.
Example
If you want a new Slack message when a user provides an NPS score in a Frigade Form, you can set up a webhook in Frigade and a Slack Workflow as follows:
- Create a new workflow in Slack and copy the Webhook URL.
- Create a new webhook in Frigade and paste the Slack Webhook URL.
- Pick Flow completed and Flow dismissed.
- Add the variables
data__nps-score-page__nps-score
(for the NPS Score) anddata__nps-feedback-page__nps-feedback-text
(for the NPS Comment) to the Slack Workflow. - Craft a message and pick a channel to send the data to.