Daily list of leads going cold, on Slack
Every workday, post the open leads nobody has contacted for 3+ days, grouped by salesperson.
How it works
Trigger: Schedule — weekdays at 9:00
- Read the Leads sheet (name, company, owner, stage, last contact).
- Keep open leads with no contact for 3 days or more.
- Post the list to Slack, grouped by owner, oldest first.
Diagram
Trigger App Code
Code
JavaScript used in the Code step — already included in the template below.
// Leads sheet columns: name | company | phone | email | owner | stage | last_contact (YYYY-MM-DD)
// Lists open leads nobody has contacted for 3+ days, grouped by owner.
const DAY = 24 * 60 * 60 * 1000;
const CLOSED = ["won", "lost"];
const stale = $input.all()
.map((item) => item.json)
.filter((l) => !CLOSED.includes(String(l.stage).toLowerCase()))
.map((l) => ({ ...l, days: l.last_contact ? Math.floor((Date.now() - new Date(l.last_contact)) / DAY) : null }))
.filter((l) => l.days === null || l.days >= 3)
.sort((a, b) => (b.days ?? Infinity) - (a.days ?? Infinity));
if (!stale.length) return [];
const byOwner = {};
for (const l of stale) (byOwner[l.owner || "Unassigned"] ||= []).push(l);
const message = Object.entries(byOwner)
.map(([owner, leads]) =>
`*${owner}*\n` +
leads.map((l) => `• ${l.name}${l.company ? ` (${l.company})` : ""}: ${l.stage}, ${l.days === null ? "never contacted" : `${l.days} days ago`}`).join("\n"))
.join("\n\n");
return [{ json: { count: stale.length, message } }];Build it
Pick your tool — same automation, step by step.
Copy and paste straight into an n8n canvas (Ctrl+V), or download and use Import from File. Then connect your own credentials and replace every YOUR_… placeholder.
Show code (140 lines)
{
"name": "Daily list of leads going cold, on Slack (Flowngn)",
"nodes": [
{
"parameters": {
"content": "## Daily list of leads going cold, on Slack\nEvery workday, post the open leads nobody has contacted for 3+ days, grouped by salesperson.\n\n**Setup**\n1. Open each node and connect your own credentials.\n2. Replace every YOUR_… placeholder.\n3. Test once, then activate.\n\nFree template from Flowngn",
"height": 260,
"width": 340
},
"id": "458223d5-3782-4a17-a45a-6fb8fafe73d6",
"name": "Setup notes",
"type": "n8n-nodes-base.stickyNote",
"typeVersion": 1,
"position": [
-420,
-60
]
},
{
"parameters": {
"rule": {
"interval": [
{
"field": "cronExpression",
"expression": "0 9 * * 0-4"
}
]
}
},
"id": "458223d5-3782-4a17-a45a-6fb8fafe73d6",
"name": "Weekdays 9:00",
"type": "n8n-nodes-base.scheduleTrigger",
"typeVersion": 1.2,
"position": [
0,
0
]
},
{
"parameters": {
"operation": "read",
"documentId": {
"__rl": true,
"value": "YOUR_SPREADSHEET_ID",
"mode": "id"
},
"sheetName": {
"__rl": true,
"value": "Leads",
"mode": "name"
},
"options": {}
},
"id": "458223d5-3782-4a17-a45a-6fb8fafe73d6",
"name": "Read leads",
"type": "n8n-nodes-base.googleSheets",
"typeVersion": 4.5,
"position": [
300,
0
]
},
{
"parameters": {
"jsCode": "// Leads sheet columns: name | company | phone | email | owner | stage | last_contact (YYYY-MM-DD)\n// Lists open leads nobody has contacted for 3+ days, grouped by owner.\nconst DAY = 24 * 60 * 60 * 1000;\nconst CLOSED = [\"won\", \"lost\"];\n\nconst stale = $input.all()\n .map((item) => item.json)\n .filter((l) => !CLOSED.includes(String(l.stage).toLowerCase()))\n .map((l) => ({ ...l, days: l.last_contact ? Math.floor((Date.now() - new Date(l.last_contact)) / DAY) : null }))\n .filter((l) => l.days === null || l.days >= 3)\n .sort((a, b) => (b.days ?? Infinity) - (a.days ?? Infinity));\n\nif (!stale.length) return [];\n\nconst byOwner = {};\nfor (const l of stale) (byOwner[l.owner || \"Unassigned\"] ||= []).push(l);\n\nconst message = Object.entries(byOwner)\n .map(([owner, leads]) =>\n `*${owner}*\\n` +\n leads.map((l) => `• ${l.name}${l.company ? ` (${l.company})` : \"\"}: ${l.stage}, ${l.days === null ? \"never contacted\" : `${l.days} days ago`}`).join(\"\\n\"))\n .join(\"\\n\\n\");\n\nreturn [{ json: { count: stale.length, message } }];"
},
"id": "458223d5-3782-4a17-a45a-6fb8fafe73d6",
"name": "Leads going cold",
"type": "n8n-nodes-base.code",
"typeVersion": 2,
"position": [
600,
0
]
},
{
"parameters": {
"select": "channel",
"channelId": {
"__rl": true,
"value": "#sales",
"mode": "name"
},
"text": "=🧊 {{ $json.count }} leads need a follow-up today:\n\n{{ $json.message }}",
"otherOptions": {}
},
"id": "458223d5-3782-4a17-a45a-6fb8fafe73d6",
"name": "Post to sales",
"type": "n8n-nodes-base.slack",
"typeVersion": 2.2,
"position": [
900,
0
]
}
],
"connections": {
"Weekdays 9:00": {
"main": [
[
{
"node": "Read leads",
"type": "main",
"index": 0
}
]
]
},
"Read leads": {
"main": [
[
{
"node": "Leads going cold",
"type": "main",
"index": 0
}
]
]
},
"Leads going cold": {
"main": [
[
{
"node": "Post to sales",
"type": "main",
"index": 0
}
]
]
}
},
"pinData": {},
"settings": {
"executionOrder": "v1"
},
"meta": {
"templateCredsSetupCompleted": false
},
"tags": []
}In Make, create a new scenario and add these modules in order:
- Schedule the scenario: Weekdays 9:00
- Google Sheets › Search Rows
- Tools › Set variable / Iterator + Array aggregator (same logic as the Code step)
- Slack › Create a Message
- Every module run uses Make operations — the free plan includes a monthly quota.
- Make's built-in functions (map, sum, formatDate…) can replace most Code steps; for complex logic use a code module.
- Module and step names can differ slightly as Make and Zapier update their apps.
In Zapier, create a new Zap and add these steps in order:
- Schedule by Zapier — Weekdays 9:00
- Google Sheets — Lookup Spreadsheet Rows (or Code by Zapier)
- Code by Zapier — Run JavaScript (paste the code from the Code section)
- Slack — Send Channel Message
- Zaps with more than two steps need a paid Zapier plan.
- Webhooks, Filters/Paths and Code by Zapier are premium features on some Zapier plans.
- Code by Zapier runs JavaScript: reuse the code shown above, reading inputs from inputData instead of $json.
- Module and step names can differ slightly as Make and Zapier update their apps.
Tips
- Change the 3-day limit in the Code step to suit your sales cycle.
Related flows
Sales & CRMEasy
New form lead → CRM contact + team ping
Leads from your website form go straight into HubSpot and your team is notified.
Typeform → HubSpot → Slack5h/mo
Sales & CRMAdvanced
AI lead qualifier
AI scores each new lead and fast-tracks the hot ones to your sales team.
Webhook → AI model → Slack → Gmail8h/mo
Sales & CRMMedium
Welcome new subscribers from Stripe
When someone subscribes, send a personal welcome email and celebrate in Slack.
Stripe → Gmail → Slack2h/mo