This video tutorial explains how one can routinely send Slack messages from Google Forms with the assistance of Document Studio.
For this instance, we’ve an occasion registration kind created with Google Types. When a participant completes the shape and clicks the submit button, a message is immediately posted within the firm’s Slack channel with particulars of the attendee like their title and e mail handle.
The Google Kind has a “Most well-liked Location” query as properly and based mostly on this reply, a particular member of the staff can be tagged or talked about within the Slack message. As an illustration, if the attended selects New York as the placement within the kind, the inner Slack message will tag @Angus since they takes care of New York registrations.
Ship Slack Messages on Google Kind Submit
Go to your Google Kind and launch Document Studio. Create a brand new workflow and add a Slack
process.
Join your Google Account to your Slack account and also you’ll be introduced with an inventory of #channels obtainable within the Slack workspace that you’ve linked together with your account.
Choose the related Slack channel the place you want to put up messages and specify the message template that can be despatched to Slack on new kind submissions.
The template message contains variables like {{ Attendee Title }}
which can be changed with the values from the shape submission. It additionally features a scriptlet so as to add conditional content material within the Slack message.
The Scriptlet seems on the Location
entered within the Google Kind and, based mostly on the reply, a particular person will get tagged within the Slack message. You may study extra in regards to the syntax of Scriptlets right here.
🎉 {{Attendee Title}} would attend the occasion from {{Location}}
{% assign reply = "{{ Location }}" %}
{% if reply == "New York" %}
<@U08N2HAQTF9>
{% elsif reply == "Boston" %}
<@U05N6HAQZM1>
{% else %}
<@U09PX8AQLJ1>
{% endif %}
The best way to @Point out a Slack Person
Slack assigns a novel ID to every account and we put this ID within the Slack message to say / tag that person within the message.
To acquire the Person ID of a Slack account, comply with these steps:
- Open
slack.com
, navigate to your Slack channel and discover any @point out of the person you’re interested by. - Proper-click the @point out, and from the contextual menu, choose “Copy hyperlink.”
The person hyperlink you’ve copied could have the next format:
labnol.slack.com/staff/U05N6HAQZM1
On this hyperlink, the portion beginning with U… represents the Person ID of the Slack person.
If you wish to @point out this person in your Slack message, enclose the Person ID inside angle brackets and prefix it with the @ image, like this:
How are you <@UABC123> 🎉