Automatically close cold HubSpot deals with Gmail feedback & Slack notifications
How it works
This workflow identifies HubSpot deals that have gone untouched for 21+ days and automatically updates their status to Closed Lost. It fetches associated contacts, retrieves their details, and sends personalized follow-up emails requesting feedback. Finally, it notifies your team via Slack about the deals moved to Closed Lost. The workflow runs on a scheduled interval, ensuring consistent lead management without manual intervention.
Step-by-step
1. Trigger the workflow
- Schedule Trigger – Runs the workflow at a defined interval (daily, weekly, etc.).
- Get HubSpot Deals – Retrieves all deals with key properties from HubSpot.
- Extract Deal Fields – Normalizes deal data for consistent processing.
2. Identify and update cold deals
- Filter Cold Leads (21+ days) – Keeps only deals not updated in the past 21 days.
- Update Deal to Closed Lost – Marks stale deals as Closed Lost in HubSpot.
3. Map deals to contacts
- Fetch Deal Associations – Retrieves contacts linked to filtered deals.
- Extract Contact IDs – Parses associations to get contactId, dealId, and dealName.
- Get Contact Details – Fetches enriched contact information.
- Extract Contact Email – Simplifies data, keeping only the email field.
4. Follow-up & team notification
- Send Gmail Feedback Request – Sends a personalized thank-you email requesting feedback.
- Send Slack Notification – Alerts the team about deals updated to Closed Lost.
Why use this?
- Ensures timely closure of stale HubSpot deals, keeping your pipeline clean.
- Automates follow-up emails to gather valuable feedback from disengaged leads.
- Reduces manual effort in deal management and contact outreach.
- Keeps your team informed in real-time with Slack notifications.
- Improves sales process efficiency and lead data hygiene.
Automatically Close Cold HubSpot Deals with Gmail Feedback & Slack Notifications
This n8n workflow automates the process of identifying and closing "cold" deals in HubSpot based on a lack of recent email activity, sending a final feedback email via Gmail, and notifying a Slack channel about the closed deal.
What it does
This workflow streamlines your sales process by:
- Schedules Execution: Runs daily to check for cold deals.
- Fetches Cold Deals from HubSpot: Retrieves deals from HubSpot that are in a specified stage ("Cold") and haven't had an email interaction in the last 30 days.
- Filters for Deals with Contact Information: Ensures that only deals associated with a contact that has an email address proceed.
- Sends Feedback Email via Gmail: For each identified cold deal, it sends a personalized email to the associated contact, asking for feedback on why the deal didn't progress.
- Updates HubSpot Deal Status: Changes the stage of the deal in HubSpot to "Closed Lost" and updates the "last activity date" to the current date.
- Notifies Slack Channel: Posts a message to a designated Slack channel, informing the team about the deal that was closed as "Lost" and the contact it was associated with.
Prerequisites/Requirements
To use this workflow, you will need:
- n8n Account: Self-hosted or cloud.
- HubSpot Account: With API access and deals in various stages.
- Gmail Account: Configured for sending emails.
- Slack Account: With a channel for notifications and an incoming webhook or bot token.
Setup/Usage
- Import the Workflow: Download the JSON provided and import it into your n8n instance.
- Configure Credentials:
- HubSpot: Set up your HubSpot API credentials (OAuth or API Key).
- Gmail: Configure your Gmail OAuth credentials.
- Slack: Set up your Slack credentials (OAuth or Webhook).
- Customize Nodes:
- Schedule Trigger (Node 839): Adjust the schedule as needed (e.g., daily at a specific time).
- HubSpot (Node 76):
- In the first HubSpot node, ensure the "Deal Stage" is set to the stage you consider "cold" (e.g., "Cold").
- In the second HubSpot node, verify the "Deal Stage" is set to "Closed Lost" for updating.
- Gmail (Node 356): Customize the email subject and body to fit your feedback request. Ensure you're using expressions to dynamically insert deal and contact information.
- Slack (Node 40): Customize the message content and select the appropriate Slack channel for notifications.
- Code (Node 834): This node is likely used for date calculations or data formatting. Review its JavaScript code to ensure it aligns with your date logic for identifying cold deals.
- Filter (Node 844): This node likely filters for deals that have an associated email address. Review its conditions.
- Activate the Workflow: Once configured, activate the workflow to start automating.
Related Templates
Track daily moods with AI analysis & reports using GPT-4o, Data Tables & Gmail
Track your daily mood in one tap and receive automated AI summaries of your emotional trends every week and month. Perfect for self-reflection, wellness tracking, or personal analytics. This workflow logs moods sent through a webhook (/mood) into Data Tables, analyzes them weekly and monthly with OpenAI (GPT-4o), and emails you clear summaries and actionable recommendations via Gmail. ⚙️ How It Works Webhook – Mood → Collects new entries (🙂, 😐, or 😩) plus an optional note. Set Mood Data → Adds date, hour, and note fields automatically. Insert Mood Row → Stores each record in a Data Table. Weekly Schedule (Sunday 20:00) → Aggregates the last 7 days and sends a summarized report. Monthly Schedule (Day 1 at 08:00) → Aggregates the last 30 days for a deeper AI analysis. OpenAI Analysis → Generates insights, patterns, and 3 actionable recommendations. Gmail → Sends the full report (chart + AI text) to your inbox. 📊 Example Auto-Email Weekly Mood Summary (last 7 days) 🙂 5 ██████████ 😐 2 ████ 😩 0 Average: 1.7 (Positive 🙂) AI Insights: You’re trending upward this week — notes show that exercise days improved mood. Try keeping short walks mid-week to stabilize energy. 🧩 Requirements n8n Data Tables enabled OpenAI credential (GPT-4o or GPT-4 Turbo) Gmail OAuth2 credential to send summaries 🔧 Setup Instructions Connect your credentials: Add your own OpenAI and Gmail OAuth2 credentials. Set your Data Table ID: Open the Insert Mood Row node and enter your own Data Table ID. Without this, new moods won’t be stored. Replace the email placeholder: In the Gmail nodes, replace your.email@example.com with your actual address. Deploy and run: Send a test POST request to /mood (e.g. { "mood": "🙂", "note": "productive day" }) to log your first entry. ⚠️ Before activating the workflow, ensure you have configured the Data Table ID in the “Insert Mood Row” node. 🧠 AI Analysis Interprets mood patterns using GPT-4o. Highlights trends, potential triggers, and suggests 3 specific actions. Runs automatically every week and month. 🔒 Security No personal data is exposed outside your n8n instance. Always remove or anonymize credential references before sharing publicly. 💡 Ideal For Personal mood journaling and AI feedback Therapists tracking client progress Productivity or self-quantification projects 🗒️ Sticky Notes Guide 🟡 Mood Logging Webhook POST /mood receives mood + optional note. ⚠️ Configure your own Data Table ID in the “Insert Mood Row” node before running. 🟢 Weekly Summary Runs every Sunday 20:00 → aggregates last 7 days → generates AI insights + emails report. 🔵 Monthly Summary Runs on Day 1 at 08:00 → aggregates last 30 days → creates monthly reflection. 🟣 AI Analysis Uses OpenAI GPT-4o to interpret trends and recommend actions. 🟠 Email Delivery Sends formatted summaries to your inbox automatically.
IT ops AI SlackBot workflow - chat with your knowledge base
Video Demo: Click here to see a video of this workflow in action. Summary Description: The "IT Department Q&A Workflow" is designed to streamline and automate the process of handling IT-related inquiries from employees through Slack. When an employee sends a direct message (DM) to the IT department's Slack channel, the workflow is triggered. The initial step involves the "Receive DMs" node, which listens for new messages. Upon receiving a message, the workflow verifies the webhook by responding to Slack's challenge request, ensuring that the communication channel is active and secure. Once the webhook is verified, the workflow checks if the message sender is a bot using the "Check if Bot" node. If the sender is identified as a bot, the workflow terminates the process to avoid unnecessary actions. If the sender is a human, the workflow sends an acknowledgment message back to the user, confirming that their query is being processed. This is achieved through the "Send Initial Message" node, which posts a simple message like "On it!" to the user's Slack channel. The core functionality of the workflow is powered by the "AI Agent" node, which utilizes the OpenAI GPT-4 model to interpret and respond to the user's query. This AI-driven node processes the text of the received message, generating an appropriate response based on the context and information available. To maintain conversation context, the "Window Buffer Memory" node stores the last five messages from each user, ensuring that the AI agent can provide coherent and contextually relevant answers. Additionally, the workflow includes a custom Knowledge Base (KB) tool (see that tool template here) that integrates with the AI agent, allowing it to search the company's internal KB for relevant information. After generating the response, the workflow cleans up the initial acknowledgment message using the "Delete Initial Message" node to keep the conversation thread clean. Finally, the generated response is sent back to the user via the "Send Message" node, providing them with the information or assistance they requested. This workflow effectively automates the IT support process, reducing response times and improving efficiency. To quickly deploy the Knowledge Ninja app in Slack, use the app manifest below and don't forget to replace the two sample urls: { "display_information": { "name": "Knowledge Ninja", "description": "IT Department Q&A Workflow", "background_color": "005e5e" }, "features": { "bot_user": { "display_name": "IT Ops AI SlackBot Workflow", "always_online": true } }, "oauth_config": { "redirect_urls": [ "Replace everything inside the double quotes with your slack redirect oauth url, for example: https://n8n.domain.com/rest/oauth2-credential/callback" ], "scopes": { "user": [ "search:read" ], "bot": [ "chat:write", "chat:write.customize", "groups:history", "groups:read", "groups:write", "groups:write.invites", "groups:write.topic", "im:history", "im:read", "im:write", "mpim:history", "mpim:read", "mpim:write", "mpim:write.topic", "usergroups:read", "usergroups:write", "users:write", "channels:history" ] } }, "settings": { "event_subscriptions": { "request_url": "Replace everything inside the double quotes with your workflow webhook url, for example: https://n8n.domain.com/webhook/99db3e73-57d8-4107-ab02-5b7e713894ad", "bot_events": [ "message.im" ] }, "orgdeployenabled": false, "socketmodeenabled": false, "tokenrotationenabled": false } }
Publishing videos across multiple platforms with Blotato (Instagram, YouTube)
Description This workflow automates video distribution to 9 social platforms simultaneously using Blotato's API. It includes both a scheduled publisher (checks Google Sheets for videos marked "Ready") and a subworkflow (can be called from other workflows). Perfect for creators and marketers who want to eliminate manual posting across Instagram, YouTube, TikTok, Facebook, LinkedIn, Threads, Twitter, Bluesky, and Pinterest. --- How It Works Scheduled Publisher Workflow Schedule Trigger – Runs daily at 10 PM (configurable). Fetch Video – Pulls video URL and description from Google Sheets where "ReadyToPost" = "Ready". Upload to Blotato – Sends video to Blotato's media service. Broadcast to 9 Platforms – Publishes simultaneously to all connected social accounts. Update Sheet – Changes "ReadyToPost" to "Finished" so it won't repost. --- Subworkflow: Video Publisher (Reusable) Receive Input – Gets URL, title, and description from parent workflow. Fetch Credentials – Pulls Blotato API key from n8n Data Table. Upload & Distribute – Uploads to Blotato, then posts to all platforms. Completion Signal – Returns to parent workflow when done. > 💡 Tip: The subworkflow can be called from ANY workflow - great for posting videos generated by AI workflows, webhook triggers, or manual forms. --- Test Workflow (Optional) Form Submission – Upload a video file with title and description. Upload to Dropbox – Generates shareable URL via "[SUB] Dropbox Upload Link" subworkflow. Trigger Publisher – Calls the subworkflow above to distribute the video. --- Setup Instructions Estimated Setup Time: 20-25 minutes Step 1: Blotato Account Setup Create account at Blotato Dashboard Connect all your social media accounts (most time-consuming step) Go to Settings and copy your account IDs for each platform Go to API Settings and copy your API key Step 2: Configure Workflow Update Social IDs: Open "Assign Social Media IDs" node Replace placeholder IDs with your actual Blotato account IDs: json { "instagramid": "YOURID", "youtubeid": "YOURID", "tiktokid": "YOURID", ... } Create Data Table: Create n8n Data Table named "Credentials" Add columns: service and token Add row: service = blotato, token = YOURAPIKEY Set Up Google Sheet: Create sheet with columns: URL VIDEO, ReadyToPost, Description, Titre (Title) Add video data Set ReadyToPost to "Ready" for videos you want to post Connect Your Sheet: Update "Get my video" node with your Google Sheet ID > ⚙️ Pro Tip: If you don't need the scheduled version, just use the subworkflow and call it from other workflows. --- Use Cases AI Video Workflows: Automatically post videos generated by Veo, Sora, or other AI models to all platforms. Content Schedulers: Queue videos in Google Sheets, let the scheduler post them automatically. Batch Publishing: Generate 10 videos, mark them all "Ready", and let the workflow distribute them. Marketing Campaigns: Coordinate multi-platform launches with a single click. Agencies: Manage multiple client accounts by swapping Blotato credentials in the Data Table. --- Customization Options Remove Unused Platforms: Disconnect any social media nodes you don't use (speeds up execution). Change Schedule: Modify the Schedule Trigger to run multiple times per day or on specific days. Different File Hosts: Replace Dropbox with Google Drive, S3, or Cloudinary in the test workflow. Platform-Specific Captions: Add IF nodes before each platform to customize descriptions or add hashtags. Add Approval Step: Insert a WhatsApp or Telegram notification before posting for manual review. Watermarks: Add a Code node to overlay branding before uploading to Blotato. --- Important Notes ⚠️ Two Workflows in One File: Lines 1-600: Scheduled publisher (checks Google Sheets) Lines 600+: Subworkflow (called by other workflows) ⚠️ Data Table vs. Hardcoding: Scheduled workflow: Hardcoded API keys in HTTP nodes Subworkflow: Uses Data Table for API keys (recommended approach) ⚠️ Why Use the Subworkflow? Can be called from ANY workflow Easier to manage API keys (one place to update) More flexible for complex automation systems