This workflow receives Salesforce Quote events via a webhook, enriches them with Salesforce Opportunity and Account data, benchmarks the deal against historical outcomes stored in Google Sheets, uses Groq (via a LangChain agent) to generate AI-powered pricing recommendations, updates the Salesforce Quote with the recommended pricing, and sends a Slack notification to the sales team.
- Receives a POST webhook request containing a Salesforce Quote payload (including the Opportunity ID and Quote ID).
- Retrieves the related Opportunity and Account records from Salesforce and normalizes key deal attributes such as amount, stage, segment, industry, and deal size.
- Loads historical deal records from Google Sheets and identifies similar opportunities based on deal size, customer segment, and industry.
- Calculates pricing benchmarks including historical win rate, average discounts for won and lost deals, and a recommended discount range.
- Sends the current deal context and benchmark data to a Groq-hosted LLM through a LangChain Agent to generate a structured recommendation containing:
- Recommended discount
- Suggested final price
- Win probability
- Confidence score
- Risk level
- Business justification
- Updates the Salesforce Quote using the Salesforce REST API with the AI-generated recommendation.
- Sends a detailed pricing recommendation and benchmark summary to Slack for the sales team.
- n8n account (Self-hosted or Cloud)
- Salesforce OAuth2 credentials
- Google Sheets OAuth2 credentials
- Groq API credentials
- Slack OAuth2 credentials
- Webhook Trigger node
- Create an n8n workflow and configure the Webhook Trigger URL.
- Configure Salesforce to send Quote events to the webhook whenever a new quote is created or updated.
- Add Salesforce OAuth2 credentials and update the Salesforce REST API endpoint with your Salesforce instance URL.
- Connect Google Sheets OAuth2 credentials and configure the spreadsheet containing historical opportunity and pricing data.
- Add a Groq API credential and select the desired Llama model for the LangChain Agent.
- Connect Slack OAuth2 credentials and choose the user or channel that should receive pricing recommendations.
- Test the webhook using a sample Salesforce Quote payload before activating the workflow.
Customize:
- Receive additional Salesforce events
- Add webhook authentication
- Validate incoming payloads
Modify to:
- Fetch additional Opportunity fields
- Include Product or Quote Line Item details
- Update custom Salesforce fields
Replace with:
- Airtable
- PostgreSQL
- MySQL
- CRM exports
- Data Warehouse
Customize:
- Similarity scoring rules
- Discount calculations
- Historical filtering
- Win-rate weighting
- Industry-specific pricing models
Extend the AI prompt to include:
- Competitive pricing
- Customer lifetime value
- Regional pricing rules
- Product margin targets
- Sales playbook guidance
- Approval recommendations
Customize:
- Channel or user
- Message formatting
- Executive summaries
- Approval links
You can extend this workflow with:
- Automatic manager approval workflows
- Email notifications
- Microsoft Teams integration
- CRM activity logging
- Pricing approval dashboards
- Revenue forecasting
- Deal health scoring
- Historical pricing analytics
- Executive reporting
- Multi-stage pricing approvals
Generate AI-driven pricing recommendations for high-value enterprise opportunities.
Recommend discounts based on historical deal performance instead of manual estimates.
Automatically identify quotes that require management approval.
Increase win rates while protecting profit margins through AI-assisted pricing.
Provide sales representatives with real-time pricing insights before sending customer quotes.
This workflow can also support:
- CPQ automation
- Dynamic pricing engines
- Sales coaching
- Partner pricing
- Channel sales optimization
- Renewal pricing
- Contract negotiation support
| Issue | Possible Cause | Solution |
|---|---|---|
| Webhook not triggered | Incorrect webhook URL | Verify Salesforce webhook configuration |
| Salesforce API fails | OAuth token expired | Reconnect Salesforce credentials |
| Historical data missing | Google Sheets configuration incorrect | Verify spreadsheet ID and column mapping |
| AI recommendation unavailable | Groq API issue | Verify API credentials and model configuration |
| JSON parsing fails | Invalid AI response | Enforce structured JSON output in the prompt |
| Slack notification not sent | Invalid Slack credentials | Reconnect Slack OAuth credentials |
| Salesforce Quote not updated | Incorrect Quote ID or field mapping | Verify REST endpoint and field mappings |
| Benchmark calculations incorrect | Historical data format mismatch | Review Google Sheets data structure |
Need assistance setting up, customizing, or extending this workflow?
Our team can help with:
- n8n workflow implementation
- Salesforce integrations
- Groq AI and LangChain implementation
- Pricing automation
- Revenue intelligence workflows
- Google Workspace integrations
- Slack automation
- Enterprise workflow development
- AI-powered sales automation
Our n8n workflow experts can help you build intelligent sales automation that improves pricing accuracy, increases win rates, and streamlines quote approvals.
- Hire n8n Developers: https://www.weblineindia.com/hire-n8n-developers/
- Business Automation Solutions: https://www.weblineindia.com/process-automation-solutions/
- n8n Automation Services: https://www.weblineindia.com/n8n-automation/