Get your re-engagement automation running in 5 steps.
Get the automation package and unzip it
Unzip the file to a folder on your server or local machine.
unzip reengage-email-v1.zip -d reengage-email
cd reengage-email
Install the required Node.js packages
npm install
This installs nodemailer, node-cron, and dotenv.
Set up your SMTP credentials
First, copy the example files:
cp config.example.json config.json
cp .env.example .env
Then add your SMTP credentials to .env:
SMTP_HOST=smtp.sendgrid.net
SMTP_PORT=587
SMTP_SECURE=false
SMTP_USER=apikey
SMTP_PASS=SG.your_api_key_here
Create a CSV file with your user data
Create data/users.csv with this format:
email,firstName,lastName,lastActivityDate
john@example.com,John,Doe,2024-12-15
jane@example.com,Jane,Smith,2024-12-20
mike@example.com,Mike,Wilson,2025-01-10
email — User's email addressfirstName — For personalizationlastActivityDate — Date of last activity (YYYY-MM-DD)Also update config.json with your business details:
{
"business": {
"name": "Your Business Name",
"website": "https://yourbusiness.com",
"supportEmail": "support@yourbusiness.com"
},
"trigger": {
"type": "no_activity",
"daysInactive": 7
}
}
Test and start sending emails
npm test
You should see which users would receive emails without actually sending them.
npm start
This starts the scheduler. It will check for inactive users daily at 9 AM (configurable).
node automation.js --once
Your re-engagement automation is now running. Inactive users will automatically receive your email sequence.
Back to Home