This repository contains a workflow for N8N that automates email validation, updates deals in Pipedrive, and logs data in a Google Sheets spreadsheet. The workflow consists of multiple connected steps to perform the following tasks:
-
Receive Deal Data:
- A webhook is configured to receive deal data from Pipedrive.
-
Get Deal Information:
- Using the deal ID received from the webhook, the workflow fetches detailed deal information from Pipedrive.
-
Email Validation:
- The workflow sends the email associated with the deal to the Snov.io API for validation.
- The email validation status is periodically checked until the validation process is complete.
-
Set Variables:
- The validation results are stored in variables, including the email status and deal information.
-
Conditional Check:
- The workflow checks if the email is invalid (
not_valid
) and if the deal is in the "Lead in" stage. - If both conditions are met, the deal is marked as lost with the reason "Invalid Email."
- The workflow checks if the email is invalid (
-
Update Deal in Pipedrive:
- Deals with invalid emails are updated in Pipedrive to reflect the lost status and the reason.
-
Log Data to Google Sheets:
- The workflow appends or updates a Google Sheets spreadsheet with the deal data, including email validation status.
- Webhook:
- Receives deal data from Pipedrive.
- Pipedrive Get Deal:
- Retrieves detailed information about the deal using the deal ID.
- Email Validation:
- Sends the deal's email to Snov.io for validation.
- Check Validation Status:
- Periodically checks the validation status of the email.
- Set Variables:
- Stores email validation results and deal information in variables.
- Conditional Logic:
- Checks if the email is invalid and if the deal is in the "Lead in" stage.
- Update Deal Status:
- Updates the deal in Pipedrive to mark it as lost if the email is invalid.
- Log to Google Sheets:
- Logs deal data and validation results to a Google Sheets spreadsheet.
- Pipedrive (Get Deal): Fetches deal details using the deal ID.
- Merge (Combine Data): Combines data from multiple sources.
- If (Conditional Check): Checks if email is invalid and deal stage.
- Pipedrive (Update Deal): Updates the deal status in Pipedrive.
- Google Sheets (Append/Update): Logs deal data to a Google Sheets spreadsheet.
- HTTP Request (Email Validation): Sends email for validation and checks the status.
-
Configure Webhook:
- Set up a webhook in Pipedrive to send deal data to the N8N webhook node.
-
Set Credentials:
- Ensure that your Pipedrive and Snov.io API credentials are correctly configured in N8N.
-
Google Sheets Setup:
- Ensure that the Google Sheets document and sheet are correctly configured to receive the logged data.
-
Run Workflow:
- Start the workflow in N8N and let it handle the automation process.
This workflow helps automate the process of validating emails associated with deals, updating deal statuses based on email validity, and maintaining a log of these actions in Google Sheets.