CRM Event-Based Channel Notifications and Logging - n8n Workflow

Use this powerful n8n workflow to capture TwentyCRM events, log them to Google Sheets, and conditionally send notifications via Gmail or Slack based on the event type. This n8n template ensures reliable event routing.

Workflow Preview

Ready to automate?

Download this n8n workflow template and start using it instantly.

Who is this best for?

CRM administrators needing real-time updates on critical system events.
Automation specialists looking for examples of conditional logic (If n8n node) routing.
Teams that require different notification methods (Email vs. Slack) based on the event priority or type.
Users searching for reliable n8n templates for event monitoring and logging.

Overview

Managing high volumes of system events from a CRM like TwentyCRM can be challenging. Not every event requires the same level of attention or communication channel. This specific n8n workflow solves this by providing intelligent routing and mandatory logging.

It utilizes a robust n8n trigger (the Webhook) to instantly capture event data. Before processing, the data is cleaned and standardized using an n8n node (Set). Every event is recorded in Google Sheets for auditing purposes, offering a complete log history.

The core value lies in its conditional routing: critical events (like 'delete' operations) are routed to a high-priority channel (Gmail), ensuring that management or specific users receive immediate email alerts. All other, potentially less critical, events are channeled to a team communication tool (Slack). This optimized approach ensures that notifications are delivered efficiently using the appropriate platform, making this a highly valuable n8n template for operational integrity.

How it Works

This automation initiates when TwentyCRM sends an event notification to the dedicated webhook URL, which acts as the n8n trigger.


  1. Capture Event: The on new twentycrm event webhook n8n node receives the POST request payload from TwentyCRM.

  2. Filter Data: The filter required data #eventType mandatory Set n8n node immediately standardizes the incoming JSON, extracting key metrics like eventName, objectMetadata.id, and record.id.

  3. Event Logging: Regardless of the event type, the data is passed to the events log Google Sheets n8n node, ensuring every transaction is logged for future auditing.

  4. Conditional Evaluation: The workflow then moves to the message channel evaluation If n8n node. This node splits the primary eventName (e.g., contact.delete) and checks if the event action is 'delete'.

  5. Route 1 (True): If the event is a 'delete' event, the flow is routed to the email channel for delete eventType Gmail n8n node, sending a detailed email alert.

  6. Route 2 (False/Default): If the event is anything other than 'delete', the flow continues to the message channel for all other eventTypes Slack n8n node, delivering a summary notification to a designated Slack channel. This sophisticated use of the If n8n node is central to the entire n8n workflow's efficiency.

Installation Guide

To deploy this n8n workflow successfully, follow these steps:


  1. Import the n8n workflow: Copy the provided JSON data and paste it into your n8n instance using the 'New' -> 'Import from JSON' function.

  2. Setup the Trigger: Activate the on new twentycrm event Webhook n8n trigger. Copy the generated test or production webhook URL.

  3. Configure TwentyCRM: Go to your TwentyCRM settings and configure the webhook integration using the URL copied in Step 2. This links the n8n trigger to the CRM.

  4. Set up Google Sheets: Connect your Google Sheets credentials to the events log n8n node and specify the Document ID and Sheet Name where events should be recorded.

  5. Set up Messaging Credentials:

For the Gmail n8n node (email channel for delete eventType), configure your Gmail credentials and specify the recipient address.
For the Slack n8n node (message channel for all other eventTypes), configure your Slack credentials and specify the target Channel ID.

  1. Activate: Ensure all required n8n node connections are valid, and then set the overall n8n workflow to 'Active'.

Node Details

on new twentycrm event (Webhook n8n node): Serves as the primary n8n trigger, initiating the automation when TwentyCRM sends data. It uses a specific, fixed path for reception.
filter required data #eventType mandatory (Set n8n node): Extracts and standardizes crucial data points (eventName, objectMetadata.id, record.id) from the incoming webhook payload, ensuring clean data is passed to subsequent steps.
events log (Google Sheets n8n node): Performs the Append operation. Logs the filtered data for every single incoming event, providing an audit trail. Requires configuration of Document ID and Sheet Name.
message channel evaluation (If n8n node): The flow control n8n node. It checks if the parsed event type (derived by splitting the eventName) is exactly 'delete', routing the data to Gmail if true, and Slack otherwise.
email channel for delete eventType (Gmail n8n node): Executes if a deletion event occurs. Sends a structured email notification with key record metadata, using the event details populated by earlier n8n nodes.
message channel for all other eventTypes (Slack n8n node): Executes for all non-delete events. Sends a concise notification containing event and record IDs to a specified Slack channel.

Related n8n Workflows

Free

Nodes: 7 Nodes
Updated: December 26 2025
View all
Created by
sateshcharan
sateshcharan

Featured*