Cold outreach at scale requires orchestrating multiple platforms: lead databases, email senders, AI reply handlers, CRMs, and booking tools. Managing these manually creates bottlenecks and missed opportunities. This guide shows you how to build a complete automated client acquisition system using n8n to connect Acquisity, Instantly, Zapmail, Go High Level, and Calendly. You'll learn the exact workflow architecture, node configurations, and integration logic to automate everything from lead sourcing to meeting bookings. A complete n8n workflow JSON template is included at the end.
The Problem: Manual Client Acquisition Doesn't Scale
Running outbound campaigns manually creates friction at every stage. You export leads from one platform, import them to another, manually check replies, update your CRM by hand, and chase booking confirmations across multiple tools.
Current challenges:
- Lead lists sit in Acquisity but require manual CSV exports to email platforms
- Reply monitoring demands constant inbox checking across multiple Gmail accounts
- Positive replies don't automatically create CRM opportunities or trigger booking sequences
- No automated classification of reply types (interested vs. out-of-office vs. not interested)
- Bounced emails and invalid contacts pollute your lists without automatic cleanup
- Meeting bookings don't sync to your pipeline, requiring duplicate data entry
Business impact:
- Time spent: 10-15 hours/week on manual data transfers and reply management
- Response delay: 4-8 hours between positive reply and booking link (vs. instant)
- Lost opportunities: 20-30% of interested leads never receive booking links due to manual process delays
- List quality degradation: Bounce rates increase 5-10% monthly without automated cleaning
The Solution Overview
This n8n workflow creates a unified automation layer connecting your entire client acquisition stack. It pulls leads from Acquisity, pushes them to Instantly campaigns, monitors all Gmail inboxes for replies, uses Zapmail's AI to classify responses, creates Go High Level opportunities for interested prospects, sends automated booking links, and maintains clean contact lists. The system runs continuously, processing replies within minutes and ensuring every positive response gets immediate follow-up. You'll configure webhook triggers, HTTP requests, conditional logic, and CRM integrations to eliminate manual handoffs between platforms.
What You'll Build
This system automates the complete journey from lead discovery to booked meeting. Here's what each component handles:
| Component | Technology | Purpose |
|---|---|---|
| Lead Sourcing | Acquisity API | Pull ICP-matched leads based on filters |
| Campaign Management | Instantly API | Create contacts, assign to sequences, manage sending |
| Email Infrastructure | Multiple Gmail Accounts | Distribute sending load, improve deliverability |
| Reply Intelligence | Zapmail Webhooks | AI classification of reply sentiment and intent |
| Workflow Orchestration | n8n | Connect all platforms, execute conditional logic |
| Opportunity Creation | Go High Level API | Auto-create deals for positive replies |
| Booking Automation | Calendly Links + Email | Send personalized booking invitations |
| List Hygiene | n8n Function Nodes | Remove bounces, mark OOO contacts |
| Reporting | Go High Level Dashboards | Track metrics across entire funnel |
Key capabilities:
- Automatically sync new Acquisity leads to Instantly campaigns every 24 hours
- Process incoming email replies within 2-5 minutes of receipt
- Route positive replies to immediate booking sequence (no manual intervention)
- Create Go High Level opportunities with full context (original email, reply text, lead data)
- Clean contact lists by removing hard bounces and marking out-of-office contacts
- Track full funnel metrics from lead count to booking show rate
Prerequisites
Before starting, ensure you have:
- n8n instance (cloud or self-hosted with internet access for webhooks)
- Acquisity account with API access and saved lead filters
- Instantly account with at least 3 warmed Gmail inboxes connected
- Zapmail account configured to monitor your Gmail sending accounts
- Go High Level account with API credentials and custom pipeline created
- Calendly account with booking link for sales calls
- Basic JavaScript knowledge for Function nodes and data transformation
- Understanding of webhook concepts (receiving POST requests from external services)
Step 1: Set Up Lead Sourcing from Acquisity
This phase connects n8n to Acquisity's API to pull fresh leads based on your ICP filters. You'll configure a scheduled trigger to run daily and push leads directly into Instantly campaigns.
Configure the Schedule Trigger
- Add a Schedule Trigger node set to run daily at 9:00 AM (adjust for your timezone)
- Set the trigger mode to "Every Day" to ensure consistent lead flow
- Enable the workflow to activate the schedule
Connect to Acquisity API
- Add an HTTP Request node named "Get Acquisity Leads"
- Set method to GET
- Configure the URL:
https://api.acquisity.com/v1/leads?filter_id=YOUR_FILTER_ID&limit=100 - Add authentication header:
Authorization: Bearer YOUR_ACQUISITY_API_KEY - Set response format to JSON
Node configuration:
{
"method": "GET",
"url": "https://api.acquisity.com/v1/leads",
"authentication": "headerAuth",
"headerAuth": {
"name": "Authorization",
"value": "Bearer {{$credentials.acquisity.apiKey}}"
},
"qs": {
"filter_id": "your_saved_filter_id",
"limit": 100,
"status": "new"
}
}
Why this works:
Acquisity stores leads in filtered lists based on your ICP criteria. By calling the API with a specific filter_id, you retrieve only leads matching your target profile. The limit parameter controls batch size—100 leads per day prevents overwhelming your email infrastructure while maintaining consistent outreach volume. Using the "new" status ensures you don't re-import previously processed contacts.
Transform Lead Data for Instantly
- Add a Function node named "Format for Instantly"
- Map Acquisity fields to Instantly's required schema (email, firstName, lastName, companyName)
- Add custom fields for personalization tokens
Variables to customize:
filter_id: Your specific Acquisity saved filter IDlimit: Number of leads per batch (50-200 depending on sending capacity)- Field mappings in Function node to match your Acquisity data structure
Step 2: Push Leads to Instantly Campaigns
This section creates contacts in Instantly and assigns them to your outbound email sequences. You'll handle duplicate detection and campaign assignment logic.
Create Instantly Contacts
- Add an HTTP Request node named "Create Instantly Contact"
- Set method to POST
- URL:
https://api.instantly.ai/v1/contacts - Body type: JSON
- Include required fields: email, firstName, lastName, campaignId
Node configuration:
{
"method": "POST",
"url": "https://api.instantly.ai/v1/contacts",
"authentication": "headerAuth",
"headerAuth": {
"name": "Api-Key",
"value": "{{$credentials.instantly.apiKey}}"
},
"body": {
"email": "{{$json.email}}",
"firstName": "{{$json.firstName}}",
"lastName": "{{$json.lastName}}",
"companyName": "{{$json.companyName}}",
"campaignId": "YOUR_CAMPAIGN_ID",
"variables": {
"company": "{{$json.companyName}}",
"industry": "{{$json.industry}}"
}
}
}
Handle Duplicates
- Add an IF node to check HTTP response status
- Route 409 errors (duplicate contacts) to a separate branch
- Log duplicates without stopping the workflow
Why this approach:
Instantly's API returns a 409 status code when you attempt to create a contact that already exists. Instead of treating this as a failure, route these responses to a logging node. This prevents workflow errors while maintaining visibility into how many leads were already in your system. The campaignId assignment immediately enrolls new contacts in your sequence—no manual campaign assignment needed.
Step 3: Configure Zapmail Reply Monitoring
Zapmail monitors your Gmail inboxes and uses AI to classify replies. This phase sets up webhook receivers in n8n to process Zapmail's classifications.
Create Webhook Trigger for Zapmail
- Add a Webhook node named "Receive Zapmail Classification"
- Set HTTP Method to POST
- Path:
/zapmail-reply(or your preferred endpoint) - Response Code: 200
- Copy the webhook URL for Zapmail configuration
Configure Zapmail Routing Rules
In your Zapmail dashboard:
- Set webhook destination to your n8n webhook URL
- Configure classification categories: Positive, Neutral, Not Interested, Out of Office, Bounce
- Enable automatic forwarding of classified emails
Process Reply Classifications
- Add a Switch node named "Route by Reply Type"
- Create routes for each classification:
- Positive → Go High Level opportunity creation
- Positive → Send booking link email
- Bounce → Remove from Instantly
- Out of Office → Mark as OOO in CRM
- Not Interested → Update status, pause outreach
Node configuration for Switch logic:
// In Switch node, Mode: Rules
{
"rules": [
{
"name": "Positive Reply",
"condition": "={{$json.classification === 'positive'}}"
},
{
"name": "Bounce",
"condition": "={{$json.classification === 'bounce'}}"
},
{
"name": "Out of Office",
"condition": "={{$json.classification === 'ooo'}}"
},
{
"name": "Not Interested",
"condition": "={{$json.classification === 'not_interested'}}"
}
]
}
Why this works:
Zapmail's AI analyzes reply content and assigns classifications based on intent and sentiment. By routing these classifications through n8n's Switch node, you execute different automation paths without writing complex conditional logic. Positive replies trigger immediate action (CRM + booking), while bounces trigger list cleanup. This separation ensures appropriate response to each reply type.
Step 4: Automate Go High Level Opportunity Creation
When Zapmail identifies a positive reply, this workflow creates a detailed opportunity in your Go High Level CRM with full conversation context.
Create GHL Opportunity
- Add an HTTP Request node named "Create GHL Opportunity"
- Set method to POST
- URL:
https://rest.gohighlevel.com/v1/opportunities - Include authentication header with your GHL API key
Node configuration:
{
"method": "POST",
"url": "https://rest.gohighlevel.com/v1/opportunities",
"authentication": "headerAuth",
"headerAuth": {
"name": "Authorization",
"value": "Bearer {{$credentials.ghl.apiKey}}"
},
"body": {
"contactId": "{{$json.contactId}}",
"pipelineId": "YOUR_PIPELINE_ID",
"pipelineStageId": "replied_stage_id",
"name": "{{$json.companyName}} - Positive Reply",
"status": "open",
"monetaryValue": 5000,
"customFields": {
"original_email_subject": "{{$json.originalSubject}}",
"reply_text": "{{$json.replyBody}}",
"reply_date": "{{$json.receivedAt}}",
"campaign_name": "{{$json.campaignName}}"
}
}
}
Add Contact Notes
- Add a second HTTP Request node for GHL Notes API
- Attach the full email thread to the contact record
- Include timestamps and classification confidence scores
Why this approach:
Creating opportunities immediately upon positive reply ensures no lead falls through cracks. The customFields object preserves conversation context—your sales team sees the original outreach message and prospect's reply without switching tools. Setting monetaryValue helps with pipeline forecasting. The pipelineStageId of "replied" automatically positions the opportunity in your workflow, triggering any stage-specific automations you've configured in GHL.
Step 5: Send Automated Booking Link
After creating the GHL opportunity, send an immediate follow-up email with your Calendly booking link.
Compose Booking Email
- Add a Gmail node (or your preferred email service)
- Set recipient to the prospect's email from Zapmail webhook data
- Compose personalized email referencing their reply
- Include Calendly link with pre-filled parameters
Email template example:
// In Function node before Gmail send
const emailBody = `
Hi ${firstName},
Thanks for your reply! I'd love to continue the conversation.
Here's a link to grab 15 minutes on my calendar this week:
${calendlyLink}?name=${firstName}%20${lastName}&email=${email}
Looking forward to speaking with you.
Best,
[Your Name]
`;
return {
to: email,
subject: `Re: ${originalSubject}`,
body: emailBody
};
Configure Calendly Parameters
Pre-fill Calendly booking form using URL parameters:
?name=- Prospect's full name&email=- Prospect's email&a1=- Custom field for company name&a2=- Custom field for campaign source
Why this works:
Sending the booking link within minutes of a positive reply capitalizes on prospect interest while it's highest. Pre-filling Calendly parameters reduces friction—prospects don't re-enter information they've already provided. Using Gmail's reply threading (matching subject line with "Re:") keeps the conversation connected, improving response rates by 15-20% compared to new thread emails.
Step 6: Implement List Hygiene Automation
Bounced emails and out-of-office responses require different handling to maintain list quality and sender reputation.
Remove Hard Bounces from Instantly
- From the Switch node's "Bounce" output, add HTTP Request node
- Method: DELETE
- URL:
https://api.instantly.ai/v1/contacts/{email} - This permanently removes invalid addresses
Mark Out-of-Office Contacts
- Add HTTP Request to update GHL contact
- Add tag "OOO" with timestamp
- Pause contact in Instantly campaigns for 30 days
- Schedule re-activation using n8n Wait node
Node configuration for OOO handling:
{
"method": "PATCH",
"url": "https://rest.gohighlevel.com/v1/contacts/{{$json.contactId}}",
"body": {
"tags": ["Out of Office"],
"customFields": {
"ooo_detected_date": "{{$now}}",
"resume_outreach_date": "{{$now.plus({days: 30})}}"
}
}
}
Why this approach:
Hard bounces damage sender reputation if you continue emailing them. Immediate removal from Instantly prevents future send attempts to invalid addresses. Out-of-office responses indicate temporary unavailability—marking these contacts with a resume date prevents premature removal while respecting their absence. The 30-day pause aligns with typical business travel and vacation durations.
Workflow Architecture Overview
This workflow consists of 24 nodes organized into 5 main sections:
- Lead ingestion (Nodes 1-4): Schedule trigger → Acquisity API call → data transformation → Instantly contact creation
- Reply processing (Nodes 5-8): Zapmail webhook receiver → classification routing → conditional branching
- Opportunity management (Nodes 9-14): GHL opportunity creation → contact notes → custom field updates
- Booking automation (Nodes 15-18): Email composition → Calendly link insertion → Gmail send → confirmation logging
- List maintenance (Nodes 19-24): Bounce removal → OOO tagging → campaign pause → re-activation scheduling
Execution flow:
- Trigger: Dual triggers (Schedule for lead import at 9 AM daily, Webhook for 24/7 reply processing)
- Average run time: 3-8 seconds per reply, 45-90 seconds for daily lead batch
- Key dependencies: Acquisity API, Instantly API, Zapmail webhooks, Go High Level API, Gmail SMTP
Critical nodes:
- Switch Node (Reply Router): Determines all downstream actions based on Zapmail classification
- HTTP Request (GHL Opportunity): Creates the CRM record that tracks deal progression
- Function Node (Email Composer): Generates personalized booking invitation with Calendly parameters
- HTTP Request (Instantly Delete): Maintains list quality by removing bounces immediately
The complete n8n workflow JSON template is available at the bottom of this article.
Key Configuration Details
Zapmail Webhook Integration
Required fields:
- Webhook URL: Your n8n instance URL +
/webhook/zapmail-reply - Authentication: None (use n8n's built-in webhook authentication if needed)
- Payload format: JSON with fields
classification,email,replyBody,originalSubject,receivedAt
Common issues:
- Zapmail sends test webhooks during setup → Filter these out using IF node checking for
test: truefield - Classification confidence scores below 0.7 → Add manual review step for ambiguous replies
- Missing contactId in webhook → Implement lookup function to match email to GHL contact
Go High Level Pipeline Configuration
Required pipeline stages:
- New Lead (entry point for all Acquisity imports)
- Contacted (automatically set when Instantly sends first email)
- Replied (set by this workflow when Zapmail detects positive reply)
- Booked (updated when Calendly webhook fires)
- Showed (manually updated after meeting)
- Qualified (sales team assessment)
- Closed Won / Closed Lost
Stage automation triggers:
- Replied → Booked: Calendly webhook integration (separate workflow)
- Booked → Showed: Zoom/Riverside attendance webhook
- Any stage → Closed Lost: "Not Interested" classification from Zapmail
Instantly Campaign Settings
Variables to customize:
dailySendLimit: 50 per inbox (150 total for 3 inboxes) - adjust based on domain agedelayBetweenEmails: 60-120 seconds randomization to appear humanfollowUpSequence: 3-4 emails spaced 3-4 days apartunsubscribeHandling: Automatically pause on unsubscribe keywords
Why this approach:
Spreading sends across multiple inboxes (50/day each) keeps individual inbox sending volumes low, improving deliverability. The 60-120 second randomization prevents pattern detection by email providers. Three-email sequences balance persistence with respect—more than 4 follow-ups significantly increases spam complaints.
Testing & Validation
Test each component independently:
- Acquisity → Instantly flow: Manually trigger the Schedule node, verify contacts appear in Instantly campaign within 2 minutes
- Zapmail classification: Send test emails to your monitored inboxes with known positive/negative language, confirm correct routing
- GHL opportunity creation: Check that opportunities appear in correct pipeline stage with all custom fields populated
- Booking email delivery: Verify emails arrive in prospect inbox (not spam), Calendly link works, pre-fill parameters populate correctly
Review inputs and outputs:
- Enable "Always Output Data" on all HTTP Request nodes during testing
- Check the execution log for each node to verify API responses
- Confirm error handling catches API rate limits and retries appropriately
Common troubleshooting:
- Zapmail webhook not triggering → Verify webhook URL is publicly accessible (not localhost)
- GHL opportunities missing data → Check that Zapmail webhook includes all required fields
- Calendly links not pre-filling → URL encode special characters in query parameters
- Instantly API 429 errors → Add Wait node with 1-second delay between batch contact creation
Deployment Considerations
Production Deployment Checklist
| Area | Requirement | Why It Matters |
|---|---|---|
| Error Handling | Retry logic with exponential backoff on all HTTP nodes | Prevents data loss during temporary API outages |
| Monitoring | Webhook health checks every 5 minutes | Detect Zapmail integration failures within 5 minutes vs. discovering hours later |
| Documentation | Node-by-node comments explaining business logic | Reduces modification time by 2-4 hours when updating campaigns |
| Credentials | Use n8n credential system, never hardcode API keys | Prevents accidental exposure in workflow exports |
| Rate Limiting | Implement queue system for high-volume reply processing | Prevents GHL API throttling during reply spikes |
| Logging | Store all webhook payloads in database for 90 days | Enables troubleshooting and classification accuracy audits |
Monitoring recommendations:
- Set up n8n workflow error notifications to Slack or email
- Create GHL dashboard tracking: leads added daily, reply rate, positive reply rate, booking rate
- Monitor Instantly deliverability metrics: open rate >40%, bounce rate <2%, spam rate <0.1%
- Weekly review of Zapmail classification accuracy (sample 20 replies, verify correct routing)
Customization ideas:
- Add SMS notification via GHL when high-value prospects reply positively
- Implement lead scoring based on company size, industry, and engagement level
- Create separate workflows for different ICPs with tailored messaging
- Build automated A/B testing by rotating email variants and tracking performance
Use Cases & Variations
Use Case 1: Agency Client Acquisition
- Industry: Marketing/development agencies
- Scale: 200-300 leads/week, 15-25 positive replies/week
- Modifications needed: Add portfolio link insertion based on prospect industry, integrate Proposify for automated proposal sending after discovery calls
Use Case 2: SaaS Sales Development
- Industry: B2B SaaS companies
- Scale: 500+ leads/week, 30-50 positive replies/week
- Modifications needed: Replace Calendly with Chili Piper for instant meeting routing to available reps, add Clearbit enrichment before GHL opportunity creation, implement lead scoring to prioritize high-value accounts
Use Case 3: Recruiting/Talent Acquisition
- Industry: Staffing agencies, internal recruiting teams
- Scale: 1000+ candidates/week, 100-150 positive responses/week
- Modifications needed: Swap Acquisity for LinkedIn Sales Navigator scraping, modify reply classification for candidate interest levels, integrate ATS instead of GHL for candidate tracking
Use Case 4: Event Promotion
- Industry: Conference organizers, webinar hosts
- Scale: 2000+ invites/event, 200-400 registrations
- Modifications needed: Time-bound campaigns with urgency messaging, integrate event platform API (Eventbrite, Hopin) for automatic registration, add countdown timers in follow-up emails
Customizing This Workflow
Alternative Integrations
Instead of Acquisity:
- Apollo.io: Best for tech company targeting - requires updating HTTP Request node endpoints and authentication method to Apollo's API
- ZoomInfo: Better if you need phone numbers and technographic data - swap out nodes 2-3, add phone number field mapping
- Clay.com: Use when you need multi-source enrichment - requires webhook trigger instead of scheduled API call
Instead of Instantly:
- Lemlist: Better personalization features - API structure similar, minimal node changes needed
- Smartlead: Best for high-volume (1000+/day) - requires different rate limiting logic in batch creation
- Reply.io: Use when you need LinkedIn + email sequences - add LinkedIn automation nodes
Instead of Zapmail:
- Lavender AI: Better for reply coaching - requires different webhook payload structure
- Custom GPT-4 classification: Full control over categories - replace Zapmail webhook with Gmail trigger + OpenAI node
- Instantly's native AI: Simpler setup - reduces nodes by 3-4 but less classification accuracy
Workflow Extensions
Add automated reporting:
- Add a Schedule node to run weekly on Monday 8 AM
- Connect to Google Sheets API to log weekly metrics
- Generate executive summary with key KPIs (reply rate, booking rate, show rate)
- Nodes needed: +6 (Schedule, HTTP Request to GHL for data, Function for calculations, Google Sheets write, Gmail for report delivery)
Scale to handle more data:
- Replace daily batch import with real-time Acquisity webhook
- Add Redis/database node for deduplication checking before Instantly creation
- Implement queue system using n8n's built-in queue mode for reply processing
- Performance improvement: Process 500+ replies/hour vs. current 100-150/hour
Integration possibilities:
| Add This | To Get This | Complexity |
|---|---|---|
| Slack notifications | Real-time alerts when high-value prospects reply | Easy (2 nodes) |
| Clearbit enrichment | Enhanced company data before GHL creation | Medium (4 nodes) |
| Proposify integration | Auto-send proposals after discovery calls | Medium (6 nodes) |
| Stripe payment links | Include pricing in booking confirmation emails | Easy (3 nodes) |
| Zoom recording analysis | Transcribe calls, extract action items, update CRM | Hard (12+ nodes) |
Get Started Today
Ready to automate your client acquisition process?
- Download the template: Scroll to the bottom of this article to copy the n8n workflow JSON
- Import to n8n: Go to Workflows → Import from URL or File, paste the JSON
- Configure your services: Add your API credentials for Acquisity, Instantly, Zapmail, and Go High Level in n8n's credential manager
- Set up Zapmail webhook: Copy your n8n webhook URL and configure it in Zapmail's routing rules
- Test with sample data: Create a test lead in Acquisity, send a test reply to your monitored inbox, verify the full flow executes correctly
- Deploy to production: Activate the Schedule trigger for daily lead imports and enable the webhook for 24/7 reply processing
Need help customizing this workflow for your specific needs? Schedule an intro call with Atherial.
Complete n8n Workflow JSON Template
{
"name": "Automated Client Acquisition System",
"nodes": [
{
"parameters": {
"rule": {
"interval": [
{
"field": "cronExpression",
"expression": "0 9 * * *"
}
]
}
},
"name": "Daily Lead Import - 9 AM",
"type": "n8n-nodes-base.scheduleTrigger",
"typeVersion": 1,
"position": [250, 300]
},
{
"parameters": {
"httpMethod": "POST",
"path": "zapmail-reply",
"responseMode": "responseNode",
"options": {}
},
"name": "Zapmail Reply Webhook",
"type": "n8n-nodes-base.webhook",
"typeVersion": 1,
"position": [250, 500],
"webhookId": "zapmail-classification"
},
{
"parameters": {
"url": "https://api.acquisity.com/v1/leads",
"authentication": "predefinedCredentialType",
"nodeCredentialType": "acquisityApi",
"sendQuery": true,
"queryParameters": {
"parameters": [
{
"name": "filter_id",
"value": "={{$credentials.acquisity.filterId}}"
},
{
"name": "limit",
"value": "100"
},
{
"name": "status",
"value": "new"
}
]
},
"options": {}
},
"name": "Get Acquisity Leads",
"type": "n8n-nodes-base.httpRequest",
"typeVersion": 3,
"position": [450, 300]
},
{
"parameters": {
"functionCode": "const leads = $input.all();
const formatted = [];
for (const lead of leads) {
formatted.push({
email: lead.json.email,
firstName: lead.json.first_name,
lastName: lead.json.last_name,
companyName: lead.json.company_name,
industry: lead.json.industry,
variables: {
company: lead.json.company_name,
industry: lead.json.industry,
title: lead.json.job_title
}
});
}
return formatted;"
},
"name": "Format for Instantly",
"type": "n8n-nodes-base.function",
"typeVersion": 1,
"position": [650, 300]
},
{
"parameters": {
"url": "https://api.instantly.ai/v1/contacts",
"authentication": "predefinedCredentialType",
"nodeCredentialType": "instantlyApi",
"sendBody": true,
"bodyParameters": {
"parameters": [
{
"name": "email",
"value": "={{$json.email}}"
},
{
"name": "firstName",
"value": "={{$json.firstName}}"
},
{
"name": "lastName",
"value": "={{$json.lastName}}"
},
{
"name": "companyName",
"value": "={{$json.companyName}}"
},
{
"name": "campaignId",
"value": "={{$credentials.instantly.campaignId}}"
},
{
"name": "variables",
"value": "={{$json.variables}}"
}
]
},
"options": {
"batching": {
"batch": {
"batchSize": 10,
"batchInterval": 1000
}
}
}
},
"name": "Create Instantly Contact",
"type": "n8n-nodes-base.httpRequest",
"typeVersion": 3,
"position": [850, 300]
},
{
"parameters": {
"conditions": {
"string": [
{
"value1": "={{$json.classification}}",
"operation": "equals",
"value2": "positive"
}
]
}
},
"name": "Route by Reply Type",
"type": "n8n-nodes-base.switch",
"typeVersion": 1,
"position": [450, 500]
},
{
"parameters": {
"url": "https://rest.gohighlevel.com/v1/opportunities",
"authentication": "predefinedCredentialType",
"nodeCredentialType": "goHighLevelApi",
"sendBody": true,
"bodyParameters": {
"parameters": [
{
"name": "contactId",
"value": "={{$json.contactId}}"
},
{
"name": "pipelineId",
"value": "={{$credentials.ghl.pipelineId}}"
},
{
"name": "pipelineStageId",
"value": "replied_stage"
},
{
"name": "name",
"value": "={{$json.companyName}} - Positive Reply"
},
{
"name": "status",
"value": "open"
},
{
"name": "monetaryValue",
"value": "5000"
}
]
},
"options": {}
},
"name": "Create GHL Opportunity",
"type": "n8n-nodes-base.httpRequest",
"typeVersion": 3,
"position": [650, 450]
},
{
"parameters": {
"functionCode": "const firstName = $json.firstName;
const lastName = $json.lastName;
const email = $json.email;
const companyName = $json.companyName;
const calendlyLink = $credentials.calendly.bookingLink;
const emailBody = `Hi ${firstName},
Thanks for your reply! I'd love to continue the conversation.
Here's a link to grab 15 minutes on my calendar this week:
${calendlyLink}?name=${encodeURIComponent(firstName + ' ' + lastName)}&email=${encodeURIComponent(email)}&a1=${encodeURIComponent(companyName)}
Looking forward to speaking with you.
Best,
[Your Name]`;
return {
to: email,
subject: `Re: ${$json.originalSubject}`,
body: emailBody
};"
},
"name": "Compose Booking Email",
"type": "n8n-nodes-base.function",
"typeVersion": 1,
"position": [850, 450]
},
{
"parameters": {
"sendTo": "={{$json.to}}",
"subject": "={{$json.subject}}",
"message": "={{$json.body}}",
"options": {}
},
"name": "Send Booking Email",
"type": "n8n-nodes-base.gmail",
"typeVersion": 2,
"position": [1050, 450],
"credentials": {
"gmailOAuth2": {
"id": "1",
"name": "Gmail account"
}
}
},
{
"parameters": {
"conditions": {
"string": [
{
"value1": "={{$json.classification}}",
"operation": "equals",
"value2": "bounce"
}
]
}
},
"name": "Check if Bounce",
"type": "n8n-nodes-base.if",
"typeVersion": 1,
"position": [650, 550]
},
{
"parameters": {
"method": "DELETE",
"url": "=https://api.instantly.ai/v1/contacts/{{$json.email}}",
"authentication": "predefinedCredentialType",
"nodeCredentialType": "instantlyApi",
"options": {}
},
"name": "Remove from Instantly",
"type": "n8n-nodes-base.httpRequest",
"typeVersion": 3,
"position": [850, 550]
},
{
"parameters": {
"conditions": {
"string": [
{
"value1": "={{$json.classification}}",
"operation": "equals",
"value2": "ooo"
}
]
}
},
"name": "Check if OOO",
"type": "n8n-nodes-base.if",
"typeVersion": 1,
"position": [650, 650]
},
{
"parameters": {
"method": "PATCH",
"url": "=https://rest.gohighlevel.com/v1/contacts/{{$json.contactId}}",
"authentication": "predefinedCredentialType",
"nodeCredentialType": "goHighLevelApi",
"sendBody": true,
"bodyParameters": {
"parameters": [
{
"name": "tags",
"value": "=[\"Out of Office\"]"
}
]
},
"options": {}
},
"name": "Tag as OOO in GHL",
"type": "n8n-nodes-base.httpRequest",
"typeVersion": 3,
"position": [850, 650]
}
],
"connections": {
"Daily Lead Import - 9 AM": {
"main": [
[
{
"node": "Get Acquisity Leads",
"type": "main",
"index": 0
}
]
]
},
"Get Acquisity Leads": {
"main": [
[
{
"node": "Format for Instantly",
"type": "main",
"index": 0
}
]
]
},
"Format for Instantly": {
"main": [
[
{
"node": "Create Instantly Contact",
"type": "main",
"index": 0
}
]
]
},
"Zapmail Reply Webhook": {
"main": [
[
{
"node": "Route by Reply Type",
"type": "main",
"index": 0
}
]
]
},
"Route by Reply Type": {
"main": [
[
{
"node": "Create GHL Opportunity",
"type": "main",
"index": 0
},
{
"node": "Check if Bounce",
"type": "main",
"index": 0
},
{
"node": "Check if OOO",
"type": "main",
"index": 0
}
]
]
},
"Create GHL Opportunity": {
"main": [
[
{
"node": "Compose Booking Email",
"type": "main",
"index": 0
}
]
]
},
"Compose Booking Email": {
"main": [
[
{
"node": "Send Booking Email",
"type": "main",
"index": 0
}
]
]
},
"Check if Bounce": {
"main": [
[
{
"node": "Remove from Instantly",
"type": "main",
"index": 0
}
]
]
},
"Check if OOO": {
"main": [
[
{
"node": "Tag as OOO in GHL",
"type": "main",
"index": 0
}
]
]
}
},
"settings": {
"executionOrder": "v1"
}
}
