# anshuman9468/cold-mail-automation-workflow architecture

> Architecture diagram of the GitHub repository anshuman9468/cold-mail-automation-workflow, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-09-28). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/anshuman9468/cold-mail-automation-workflow
- Repository: https://github.com/anshuman9468/cold-mail-automation-workflow

## Overview

This is an n8n cold-email campaign workflow: a manual run reads lead rows, filters for pending contacts, processes each lead, personalizes and sends an email, then records the result and waits before continuing. The README documents the node sequence and Google Sheets/Gmail integrations; no workflow source excerpt was available to verify additional wiring or failure handling. Daily scheduling is described as an optional extension, not included as an active workflow component.

Main entry points: [`Cold_mail_agent.json`](https://github.com/anshuman9468/cold-mail-automation-workflow/blob/main/Cold_mail_agent.json) (Fetch leads)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_control["Campaign Control"]
  node_manual["Manual trigger"]
  node_filter["Pending check"]
  node_loop["Loop contacts"]
  node_wait["Send delay"]
end

subgraph group_message["Email Preparation"]
  node_personalize["Personalize content"]
  node_merge["Merge lead data"]
  node_format["Format email"]
  node_merge_result["Merge send result"]
end

subgraph group_integrations["External Services"]
  node_fetch["Fetch leads"]
  node_sheets[("Google Sheets")]
  node_refetch["Refetch row"]
  node_gmail["Gmail"]
  node_update["Update lead status"]
end

node_operator(("Workflow operator"))

node_operator -->|"starts"| node_manual
node_manual -->|"triggers"| node_fetch
node_fetch -->|"reads leads"| node_sheets
node_fetch -->|"passes rows"| node_filter
node_filter -->|"passes pending"| node_loop
node_loop -->|"selects lead"| node_refetch
node_refetch -->|"reads row"| node_sheets
node_refetch -->|"provides lead"| node_personalize
node_personalize -->|"provides message"| node_merge
node_merge -->|"combines fields"| node_format
node_format -->|"sends email"| node_gmail
node_gmail -->|"returns send info"| node_merge_result
node_merge_result -->|"provides status data"| node_update
node_update -->|"writes status"| node_sheets
node_update -->|"continues"| node_wait
node_wait -->|"resumes iteration"| node_loop

click node_manual "https://github.com/anshuman9468/cold-mail-automation-workflow/blob/main/Cold_mail_agent.json"
click node_fetch "https://github.com/anshuman9468/cold-mail-automation-workflow/blob/main/Cold_mail_agent.json"
click node_filter "https://github.com/anshuman9468/cold-mail-automation-workflow/blob/main/Cold_mail_agent.json"
click node_loop "https://github.com/anshuman9468/cold-mail-automation-workflow/blob/main/Cold_mail_agent.json"
click node_refetch "https://github.com/anshuman9468/cold-mail-automation-workflow/blob/main/Cold_mail_agent.json"
click node_personalize "https://github.com/anshuman9468/cold-mail-automation-workflow/blob/main/Cold_mail_agent.json"
click node_merge "https://github.com/anshuman9468/cold-mail-automation-workflow/blob/main/Cold_mail_agent.json"
click node_format "https://github.com/anshuman9468/cold-mail-automation-workflow/blob/main/Cold_mail_agent.json"
click node_merge_result "https://github.com/anshuman9468/cold-mail-automation-workflow/blob/main/Cold_mail_agent.json"
click node_update "https://github.com/anshuman9468/cold-mail-automation-workflow/blob/main/Cold_mail_agent.json"
click node_wait "https://github.com/anshuman9468/cold-mail-automation-workflow/blob/main/Cold_mail_agent.json"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_manual,node_filter,node_loop,node_wait toneBlue
class node_personalize,node_merge,node_format,node_merge_result toneAmber
class node_fetch,node_sheets,node_refetch,node_gmail,node_update toneMint
class node_operator toneIndigo
```

## Components

### Campaign Control

- [Manual trigger](https://github.com/anshuman9468/cold-mail-automation-workflow/blob/main/Cold_mail_agent.json): `Cold_mail_agent.json`
- [Pending check](https://github.com/anshuman9468/cold-mail-automation-workflow/blob/main/Cold_mail_agent.json): `Cold_mail_agent.json`
- [Loop contacts](https://github.com/anshuman9468/cold-mail-automation-workflow/blob/main/Cold_mail_agent.json): `Cold_mail_agent.json`
- [Send delay](https://github.com/anshuman9468/cold-mail-automation-workflow/blob/main/Cold_mail_agent.json): `Cold_mail_agent.json`

### Email Preparation

- [Personalize content](https://github.com/anshuman9468/cold-mail-automation-workflow/blob/main/Cold_mail_agent.json): `Cold_mail_agent.json`
- [Merge lead data](https://github.com/anshuman9468/cold-mail-automation-workflow/blob/main/Cold_mail_agent.json): `Cold_mail_agent.json`
- [Format email](https://github.com/anshuman9468/cold-mail-automation-workflow/blob/main/Cold_mail_agent.json): `Cold_mail_agent.json`
- [Merge send result](https://github.com/anshuman9468/cold-mail-automation-workflow/blob/main/Cold_mail_agent.json): `Cold_mail_agent.json`

### External Services

- [Fetch leads](https://github.com/anshuman9468/cold-mail-automation-workflow/blob/main/Cold_mail_agent.json): `Cold_mail_agent.json`
- **Google Sheets**
- [Refetch row](https://github.com/anshuman9468/cold-mail-automation-workflow/blob/main/Cold_mail_agent.json): `Cold_mail_agent.json`
- **Gmail**
- [Update lead status](https://github.com/anshuman9468/cold-mail-automation-workflow/blob/main/Cold_mail_agent.json): `Cold_mail_agent.json`

### Other components

- **Workflow operator**

## Connections

- Workflow operator → Manual trigger: starts
- Manual trigger → Fetch leads: triggers
- Fetch leads → Google Sheets: reads leads
- Fetch leads → Pending check: passes rows
- Pending check → Loop contacts: passes pending
- Loop contacts → Refetch row: selects lead
- Refetch row → Google Sheets: reads row
- Refetch row → Personalize content: provides lead
- Personalize content → Merge lead data: provides message
- Merge lead data → Format email: combines fields
- Format email → Gmail: sends email
- Gmail → Merge send result: returns send info
- Merge send result → Update lead status: provides status data
- Update lead status → Google Sheets: writes status
- Update lead status → Send delay: continues
- Send delay → Loop contacts: resumes iteration
