Send Make.com Error Notifications to Slack Channel

Learn how to set up Make.com Slack alerts with this easy guide. Follow this step-by-step instructions to keep your team informed and efficient.

30 Aug 2024

Automation

8 mins

Make.com, Gmail and Slack logos side by side, connected by a blue arrow. Illustrates Lucas Ostrowski's guide on integrating Make.com with Slack for automated alerts. Represents efficiency in team communication and no-code automation expertise.
Make.com, Gmail and Slack logos side by side, connected by a blue arrow. Illustrates Lucas Ostrowski's guide on integrating Make.com with Slack for automated alerts. Represents efficiency in team communication and no-code automation expertise.
Make.com, Gmail and Slack logos side by side, connected by a blue arrow. Illustrates Lucas Ostrowski's guide on integrating Make.com with Slack for automated alerts. Represents efficiency in team communication and no-code automation expertise.

As a software guy, I used to have all critical alerts in one place (except on-duty messaging) in Slack. And you, too, probably want to stay on top of essential messages without constantly checking your email (I do it twice daily). And if you work with Make.com, you know that its alerting is, well… not the best. The only way to get information when your scenario is failing or has just stopped is to get an email notification. And if you are on a Pro plan or lower, you can get it only for one email inbox. You can always redirect it to the group or others, but let's be honest: we don't want this in our inboxes.

Well… let's move it to Slack then!

Step 1: Trigger Make.com scenario on Custom mailhook

Start by creating a new scenario in Make.com (or if you don't have an account yet, make one with my affiliate link).

Remember to give the scenario an explicit name.

  1. Click on the trigger module in the middle of the workspace.

  2. Search for Webhooks.

  3. Select Custom mailhook.

  4. Click Create a webhook (yeah, the name is a bit confusing here).

  5. Input the name for you mailhook and Save.

  6. Click on Copy address to clipboard.

Make.com Webhooks setup interface: Custom mailhook configuration with email alert form and webhook address, demonstrating Slack integration process


Before the next step, Start the scenario. (This is a crucial step to verify the forwarding address in Gmail).

Step 2: Forward all Make.com alerts to your mailhook

Part I: Add a forwarding address to your Gmail account

Here's a suggested alt text for this image: "Gmail settings page showing email forwarding setup for Lucas Ostrowski's account to Evernote integration, demonstrating automation workflow
  1. Login to your Gmail account.

  2. Go to settings -> Click on the Gear icon at the top right of the page and then See all settings.

  3. From the top menu, select Forwarding and POP/IMAP.

  4. Click on Add a forwarding address button.

  5. Paste the email you've just copied from the Make.com mailhook and click Next.

  6. Follow Google instructions.

  7. Open your scenario in Make.com. In the payload of the mailhook, you will find a link to confirm your address.

    Make.com Webhooks interface showing email forwarding confirmation details for Lucas Ostrowski's automation setup
  8. Copy it and open it in a browser to finish the verification.


Double-check that your mailhook email is visible as a verified forwarding email in Gmail settings.

Part II: Create a forwarding filter

Gmail advanced search interface showing Make.com alert filter setup: from:noreply@eu2.make.com subject:(warning|error|stopped)
  1. Go to Gmail's main page.

  2. Click on the gear icon at the right of the search box.

  3. Add the following filters:
    From: noreply@eu2.make.com(check the Make.com notifications email, it might be different for different regions)
    Subject: warning|error|stopped
    Or you can put it directly in the search input: from:(noreply@eu2.make.com) subject:(warning|error|stopped)

  4. Click Create filter at the bottom of the form.

  5. Check Forward it to: checkbox and select your Make.com mailhook email from a dropdown next to it.

Gmail filter settings interface showing how to forward Make.com alerts. Red arrow highlights 'Forward it to' checkbox. Demonstrates Lucas Ostrowski's automation setup for Make.com error notifications via Gmail filters. Essential step in building automated monitoring system.

Finally, click on Create filter

You can add other options too; just make sure you forward it to Make.com mailhook.

Step 3: Extract all the information from the email

Let's get back to the Make.com interface with our scenario.

Now, we need to extract all the information we want to post later on Slack from the email. There are many ways to do this. I chose the "lazy" path and used OpenAI GPT.

Part I: OpenAI Module

Add a new module next to the Webhook trigger. Search for OpenAI and then select Create a Completion.

For this tutorial, I assume you have already created a connection.

Here's an appropriate alt text for this image: "Make.com interface showing Webhooks module and OpenAI integration options for automated Slack alerts setup

Select Model: GPT-4o: gpt-4o-mini (system) (good enough for our needs and the cheapest one, at least when I write this tutorial).

-> Add message

Make.com OpenAI module configuration for Slack alerts: GPT-4 setup with system role and custom message content

Role: System (I explain roles here)

Message Content:

You are a helpful email assistant. 
You will receive an email message with an error or warning. Your job is to extract information and return it in JSON format. 

If the message is a warning or error, follow the example:
{
  "scenario": "scenario name",
  "scenarioUrl": "scenario url",
  "execution": "execution id",
  "executionUrl": "execution url",
  "details": "details of the warning",
  "moreDetailsUrl": "link to more details",
  "logsUrl": "link to logs"
}

If the message is about stopped execution:
{
  "scenario": "scenario name",
  "scenarioUrl": "scenario url",
  "execution": "execution id",
  "reason": "reason of stopping",
  "moreDetailsUrl": "link to more details"
}

The messages for warning and error are similar, but the messages for stopped execution differ. That's why I use two schemas.

-> Add message

Role: User

Message Content: Text field from webhook.

Max Tokens: 1500

Temperature: 0.65

Response Format: JSON Object(Using this option ensures that the output will always be in JSON, which allows us to easily parse it in the next step.)

Click OK to save the OpenAI module config.


Part II: Parse JSON

"Make.com interface showing OpenAI module output and JSON parser setup for automated Slack alerts workflow

Add a new module next to OpenAI. Search for JSON and then select Parse JSON. Copy one of the JSON objects we use in OpenAI prompt, paste it in Sample data and click Generate. In the generated structure, add a missing field from the second object.

Make.com JSON parser configuration for email alerts: data structure setup with sample JSON input

While adding the structure is not required, it makes life much easier.

Click on Create a data structure. And then, in the Specification section, use Generate the option.

JSON String: Result from OpenAI module output.

Save with the OK button.

Step 3.1: Test the scenario (optional)

If you follow my instructions strictly, you can skip this step. But it's always good to test early.

Let's test it, then.

Start the scenario by clicking on Run once button.

Copy your mailhook email address (you can find it by clicking on the first module in the scenario).

Go to your Gmail, find any alert from Make.com, and forward it to the address you just copied.

Make.com workflow showing Webhooks, OpenAI, and JSON parser modules for automated Slack alerts with test scenario results

Step 4: Transform Scenario name

Sometimes, Scenario field containing the scenario name can have some special characters, which might cause issues when sending a Slack message.

There is one simple trick we can do to avoid that.

After the Parse JSON module add a new JSON module, but this time, select Transform to JSON. As the object, insert the Scenario field from the previous step.

Make.com workflow: JSON Transform module setup for escaping special characters in scenario names before Slack message creation

This module will escape all special characters that might break Slack messages.

Step 5: Send them the right way - Make.com Router

Next to the Transform to JSON module, add a new one. Search for Flow control and select Router.

Add three paths to the Router (just click on the router).

Click on each path and set up filters as follows:

  1. Warning

Label: Warning
Condition: Mailhook subject
Text operators: Contains (case insensitive) -> warning

  1. Alert

Label: Alert
Condition: Mailhook subject
Text operators: Contains (case insensitive) -> error

  1. Stopped

Label: Stopped
Condition: Mailhook subject
Text operators: Contains (case insensitive) -> stopped


Make.com Router module configuration: three-path setup for Warning, Alert, and Stopped conditions in Slack alert automation workflow


Step 6: Send Slack notification

There is only one step left (it just needs to be done three times).

Click on the empty module at the end of the `Warning" path (the first grey "+" sign).

Search for Slack and select Create a Message.

For the Slack integration, you have two ways to send a message:

  • Text - it's just simple text—no fancy formatting etc. However, it's used as a fallback for the second option. I suggest you always put some value on this parameter.

  • Blocks - with this one, you can build a nice-looking interactive message. This field requires you to send a JSON message with all blocks. You can use the Slack Block Kit Builder to build or test your message structure.

As I suggest, we will use both.

Start by selecting a channel to which you want to send your messages. I usually create a separate channel only for alerts.

Then, for Text the field, put Subiect from the mailhook.

Finally, build and put a JSON into Blocks — you can play a bit with this one. Just remember to replace all test text with values extracted from the email.

You can build blocks by yourself, or you can start with my example:

{
	"blocks": [
		{
			"type": "header",
			"text": {
				"type": "plain_text",
				"text": ":warning: Encountered warnings in scenario",
				"emoji": true
			}
		},
		{
			"type": "section",
			"text": {
				"type": "mrkdwn",
				"text": "{{2.subject}}"
			}
		},
		{
			"type": "section",
			"fields": [
				{
					"type": "mrkdwn",
					"text": "*Execution:*\n<{{4.executionUrl}}|{{4.execution}}>"
				},
				{
					"type": "mrkdwn",
					"text": "*Scenario:*\n<{{4.scenarioUrl}}|{{4.scenario}}>"
				}
			]
		},
		{
			"type": "divider"
		},
		{
			"type": "section",
			"text": {
				"type": "mrkdwn",
				"text": "We recommend paying attention to these warnings."
			}
		},
		{
			"type": "actions",
			"elements": [
				{
					"type": "button",
					"text": {
						"type": "plain_text",
						"text": "See More Details",
						"emoji": true
					},
					"value": "view_details",
					"action_id": "view_scenario_details",
					"url": "{{4.moreDetailsUrl}}"
				}
			]
		}
	]
}

Repeat for Alert and Warning paths.

Free Blueprint

Get a free blueprint for this automation: Make.com Error Notifications from Slack Blueprint.

Conclusion

Just before you go, ensure you tested all three scenarios and confirm all work as expected.

And that's all.

This scenario saved me a lot of frustration for myself and my customers. I think it was worth spending these 20 minutes building and testing it.

What about you? How do you monitor your scenarios?

Reach out to me on X @OstrowskiLukasz or send me an email.

Best of Templates & Blueprints

The Money OS Notion template displayed on two MacBook laptops against a dark, professional backdrop. Left screen shows sophisticated financial analytics with multiple line graphs tracking income and expenses over time. Right screen demonstrates the dark-mode interface with navigation icons and current month financial tracking. 'Made for Notion' badge in top-left corner emphasizes native integration. Stylish product visualization highlighting The Money OS's comprehensive financial management and analysis capabilities in a modern, premium presentation.
Advanced KPIs Tracker Notion template: Dark-mode interface with KPI dashboard, progress bars, and performance chart on laptop screen. Made for Notion."
Simple KPIs Tracker Notion template in dark mode on laptop screen. Dashboard displays three KPI cards with progress bars, targets, and current values. Clean interface for efficient performance tracking, ideal for startups and small businesses using Notion.

Best of Templates & Blueprints

The Money OS Notion template displayed on two MacBook laptops against a dark, professional backdrop. Left screen shows sophisticated financial analytics with multiple line graphs tracking income and expenses over time. Right screen demonstrates the dark-mode interface with navigation icons and current month financial tracking. 'Made for Notion' badge in top-left corner emphasizes native integration. Stylish product visualization highlighting The Money OS's comprehensive financial management and analysis capabilities in a modern, premium presentation.
Advanced KPIs Tracker Notion template: Dark-mode interface with KPI dashboard, progress bars, and performance chart on laptop screen. Made for Notion."
Simple KPIs Tracker Notion template in dark mode on laptop screen. Dashboard displays three KPI cards with progress bars, targets, and current values. Clean interface for efficient performance tracking, ideal for startups and small businesses using Notion.

Best of Templates & Blueprints

The Money OS Notion template displayed on two MacBook laptops against a dark, professional backdrop. Left screen shows sophisticated financial analytics with multiple line graphs tracking income and expenses over time. Right screen demonstrates the dark-mode interface with navigation icons and current month financial tracking. 'Made for Notion' badge in top-left corner emphasizes native integration. Stylish product visualization highlighting The Money OS's comprehensive financial management and analysis capabilities in a modern, premium presentation.
Advanced KPIs Tracker Notion template: Dark-mode interface with KPI dashboard, progress bars, and performance chart on laptop screen. Made for Notion."
Simple KPIs Tracker Notion template in dark mode on laptop screen. Dashboard displays three KPI cards with progress bars, targets, and current values. Clean interface for efficient performance tracking, ideal for startups and small businesses using Notion.
Table of contents

Title

Title

Title

Join 1K+ Readers

Get the latest on AI, automations and systems to optimise your life and businesses.

Join 1K+ Readers

Get the latest on AI, automations and systems to optimise your life and businesses.

Join 1K+ Readers

Get the latest on AI, automations and systems to optimise your life and businesses.