Detect revenue leakage with Salesforce, Google Sheets, Gemini, and Slack
Ready for 3.0What this workflow does
This AI workflow has 12 nodes and runs manually, when you click “Execute workflow”. Along the way it connects Google Gemini, Salesforce, Google Sheets and Slack.
How it runs
Trigger: Manually, when you click “Execute workflow”.
- Fetch Salesforce Opportunities (Salesforce): get many (opportunity)
- Iterate Opportunities (Loop Over Items (Split in Batches)): loops over the items in batches
- API Rate Limit Delay (Wait): waits 3 seconds
- Lookup Billing Record (Google Sheets): uses Google Sheets
- Compare Revenue Totals (Code): runs custom JavaScript code
- Analyze Revenue Gap (Google Gemini): uses Google Gemini
- Format AI Results (Edit Fields (Set)): sets 11 fields: opportunityId, dealId, dealName…
- Inconsistency Found? (If): checks a condition and branches into true / false
- Prepare Slack Message (Code): runs custom JavaScript code
- Alert Revenue Gap (Slack): uses Slack
…plus 1 more step. See the full node list below.
Services it uses
Before you upgrade to n8n 3.0
Nothing in this workflow is removed in n8n 3.0, so it should import and run after the upgrade.
Nodes used (10)
- If
n8n-nodes-base.if - Google Gemini
@n8n/n8n-nodes-langchain.googleGemini - Salesforce
n8n-nodes-base.salesforce - Loop Over Items (Split in Batches)
n8n-nodes-base.splitInBatches - Wait
n8n-nodes-base.wait - Google Sheets
n8n-nodes-base.googleSheets - Code
n8n-nodes-base.code - Slack
n8n-nodes-base.slack - Edit Fields (Set)
n8n-nodes-base.set - Manual Trigger
n8n-nodes-base.manualTrigger
From the author
Quick overview This workflow manually audits Closed Won Salesforce opportunities against billed amounts in Google Sheets, uses Google Gemini to analyze any revenue gap, then alerts a Slack user and writes an audit note back to the Salesforce opportunity. How…