Log missed EDI sales from Gmail CSVs into GoHighLevel with Slack error alerts
Ready for 3.0Ready for 3.0. This template uses no nodes that n8n 3.0 removes. No removed nodes, versions or helpers found. Static check, last run 2026-10-19.
Worth a look
- Gmail Trigger below v1.4 runs as v1.4 (drafts skipped, max emails per poll) (Gmail Trigger)
Nodes used (9)
- Gmail Trigger
n8n-nodes-base.gmailTrigger - Gmail
n8n-nodes-base.gmail - Extract from File
n8n-nodes-base.extractFromFile - Code
n8n-nodes-base.code - Loop Over Items (Split in Batches)
n8n-nodes-base.splitInBatches - If
n8n-nodes-base.if - HTTP Request
n8n-nodes-base.httpRequest - Error Trigger
n8n-nodes-base.errorTrigger - Slack
n8n-nodes-base.slack
What it does
Quick overview This workflow monitors Gmail for incoming EDI sales report emails, extracts a CSV attachment, and logs new “missed sales” line items into GoHighLevel (LeadConnector) custom objects while linking them to matching opportunities when possible, with Slack alerts on workflow errors. How it works 1. Triggers on new Gmail messages matching your configured filters and downloads the email attachments. 2. Extracts rows from the attached CSV file and processes them in batches. 3. For each row, normalizes key fields (like PO number and SAP material code) and builds a unique key for deduplication. 4. Searches GoHighLevel (LeadConnector) for an existing missed sales custom object record matching the unique key and skips rows that already exist. 5. Creates a new GoHighLevel missed sales custom object record for any new row, including quantity, pricing, value, and rejection reason details. 6. Searches GoHighLevel opportunities by PO number and, if found, creates an association linking the new missed sales record to the opportunity. 7. When any workflow error occurs, posts an alert message to a specified Slack channel. Setup 1. Connect your Gmail OAuth2 credentials and configure the Gmail Trigger filters so only the EDI report emails with CSV attachments are picked up. 2. Add a GoHighLevel (LeadConnector) Private Integration Token and replace YOURGHLAPITOKEN plus YOURGHLLOCATIONID in all HTTP requests. 3. Ensure a GoHighLevel custom object exists at customobjects.missedsales with fields matching the properties sent (for example ponumber, sapcode, quantity, and itemnetvalue). 4. Set YOURGHLASSOCIATIONID to the association that links missed sales custom object records to opportunities in your GoHighLevel account. 5. Connect Slack OAuth2 credentials and replace YOURSLACKCHANNELID with the channel that should receive workflow error alerts.