In this tutorial, I'll show you how to use Zapier to connect Slack to Google Sheets, such that when a Slack message is sent to a specific channel, it will update a Google Sreadsheet with a new row containing the timestamp, who sent the message, and what was sent.
Think of Zapier as a big connector of various online services and apps. Normally, a developer would need to integrate services via APIs, but with Zapier, you can get these services to talk to each other with zero coding.
At it's simplest, Zapier is a set of triggers - conditions on one service that cause things to happen (in this case, a Slack message), and actions which happen in response (like updating a Google Sheet). Companies are using Zapier to automate all sorts of chunks of their business without writing code.
Note: You'll need Slack and Google Sheets accounts and familiarity for this how-to.
Getting started with Zapier
Here's how I accomplished hooking up Slack to Google Sheets. First, sign up and you'll see the "zap" explorer:
Don't get tempted to start a zap here! Instead, click on "Zaps" on the top menu:
Then on the right you'll see you have no zaps, and a blue button to make one - click the blue button:
Now you're in zap-maker land. Notice on the left, Zapier sets you up with two steps by default; an Trigger step and an Action step:
Setting a trigger for Slack
For this how-to, the trigger will be "Slack message sent" and the action will be "create a new row in a Google Sheet".
Lets choose Slack for our trigger by searching for it here:
Type in "slack" and you'll see it come up - choose "Slack":
Then choose "New message posted to channel" as a trigger:
Note: Different apps will have different trigger possibilities. This is where the flexibility of Zapier comes in - thousands of triggers X thousands of actions = virtually endless possibilities
Click to add an account, and Zapier will automatically figure out what Slack accounts you have access to. Choose the one you'd like to integrate with.
Note - if Zapier tells you that "a webhook wasn't found, you can ignore that". You can test that Zapier is hooked up to Slack and get a nice green "success" status check. Then hit "save and continue".
Choose the channel you'd like to monitor for changes, then it's pretty much on to setting up the Action step - updating a Google Sheet.
Creating an action - update Google Sheets
Search for Google Sheets in the app search area, similar to what you did with Slack. Then choose "Create spreadsheet row":
Give Zapier permission to control your Drive, and choose the spreadsheet you'd like to hook up. Create a new spreadsheet now if you haven't already and then choose that one, and be sure to name the columns properly. Zapier will use these column names. Note that Zapier allows you to refresh and look for spreadsheets directly in it's drop-downs, which is convenient.
Tell Zapier which columns you'd like to fill in with which information from Slack. It's pretty self-explanatory, and Zapier will show you an example of what data it will place in the row using the last message sent in the Slack chat:
Once set up, you can have Zapier send a test row to your spreadsheet:
After that, hit the big "On" button and your Zap should be working.
You can test it by sending a message in your Slack chat and seeing new rows appear in Google Sheets immediately.
That's all there is to a simple Zapier "zap". Armed with this knowledge, if browse through the many integrations they have you'll no doubt find a way to build a piece of your product and increase your productivity without having to write a line of code.
Keep on Learning!