Webhooks & Integromat: Gateway to Online Automation for Dummies

If you are looking to pass data from one online system to another, one of the options you may have is to use webhooks. Modern applications (such as Slack for example) with modern APIs support sending data out of/into the system via webhooks. The beauty of the webhooks is the fact that even a non-programmer like me can use it to automate dataflows in conjuction with Integromat.

In my example, I will be showing how to pass data from webhooks to Google Sheets:

Webhooks - 6 - Image for FB

What webhooks actually are?

You can imagine webhooks as “URLs listening for information”. Or in other words, it’s basically a “mailbox” which listens for a (usually) predefined set of data.

Webhooks are simple URLs. For example: https://hook.integromat.com/69yilfahqs764wyae1cp739eac12a4bg

There are several options how to send information to webhooks:

  1. By appending parameters to the url. Something like https://hook.integromat.com/69yilfahqs764wyae1cp739eac12a4bg?message=hello_world
  2. More advanced folks already know that webhooks can receive/send data structured as JSON for example.

In order to keep things simple for this article, I will stick only to sending information via parameters in the URL.

How to Get Data from Webhooks to Google Sheets?

When you visit https://hook.integromat.com/69yilfahqs764wyae1cp739eac12a4bg?message=hello_world, you see only this:

Webhooks - 1 - Message Received

This means the message was “received” by Integromat but it’s pretty much useless without being connected to the destination system.

As I’ve mentioned earlier, I will be using Integromat to generate webhooks for me and then to send some data via the webhook to a Google Sheet. Integromat is an advanced (and beautiful) online automation platform. They call themselves as the “glue of the Internet” and I can relate to that.

After you create an Integromat account you want to create a new scenario starting with Webhooks module:
Webhooks - 2 - creation

As the next step, you want to send a test message to the webhook with sample data so Integromat can learn the data structure. Assume we want to simply sent “message=hello_world”.

These are the steps you need to take:

  1. Enable listening in Integromat
  2. Append the message to the URL: https://hook.integromat.com/1xn60qdvm4dk2wvbuhih710li1r8s1at?message=hello_world (if you were to send more messages, you would add more parameters to the URL: message=hello_world&some_other_message=bla_bla…)
  3. Visit the URL
  4. Check the result in Integromat – you should see “succesfully determined” message with a green ticker.

Webhooks - 3 - data determination

As the next step on our quest to store the message in a Google Sheet, you need to connect Google Sheets module to the existing Webhooks module. You should have your target Google Sheet created before you proceed (and ideally know its ID – the odd text string in the sheet’s URL). My target Google Sheet is super simple:
Webhooks - 4 - Google Sheet Created

For every received “hello_world” via the webhook, I want to add one new row saying “hello_world”. How to set this up in Integromat? It’s quite simple again:

Webhooks - 5 - Google Sheet Connected

You can see that:

  1. I connect the Google Sheets module via file ID (you could also scroll through a list of the spreadsheets)
  2. I use the “message” from the webhook as the value for column A in the spreadsheet
  3. I save and turn on the scenario
  4. I visit the webhook URL https://hook.integromat.com/1xn60qdvm4dk2wvbuhih710li1r8s1at?message=hello_world several times.

You can see that with every visit of the URL, the message is sent to the Google Sheet and stored on a new row. Beautiful, isn’t it?

Conclusion

As you could see, webhooks are really not a rocket science to use if you:

  • Know they actually exist
  • Have proper tools to create and process them. Integromat is one of tools.

In my example, I am passing just a static text value multiple times which is pretty dumb (and probably useless). But imagine that you can use webhooks as a receiver for variable data coming from your CRM (or from your client’s CRM) and passing them to a Google Sheet. Or vice versa – when you need to pass certain values to client’s CRM via webhooks 🙂

Ready to try webhooks with Integromat yourself?

GO TO INTEGROMAT

Leave a Reply

Your email address will not be published. Required fields are marked *