This workflow automatically fetches daily stock market news, analyzes sentiment using Gemini AI, calculates impact scores, sends alerts for high-impact news and stores structured results in Google Sheets.
This workflow runs every day at 8 AM and automatically collects the latest stock market news from a public API. It filters, cleans and processes the data to ensure only relevant and unique articles are analyzed.
Each news article is sent to Google Gemini AI, which classifies the sentiment as bullish, bearish or neutral, along with a confidence score and reasoning. The workflow then calculates an impact score based on sentiment and confidence.
High-impact news is immediately flagged and sent via email alerts, while all processed results are stored in a structured format in Google Sheets for tracking and analysis.
To use this workflow, you need:
https://api.tradient.org/v1/api/market/news
data.latest_news
You can change this limit in:
return output.slice(0, 2);
news_object.titlenews_object.textstock_namemodels/gemini-3.1-flash-lite-preview
Formula logic:
confidence × 1.2confidence × -1.2confidence × 0.3You MUST configure:
sendTo)Example message:
Stock: XYZ
Title: News title
Sentiment: bullish
Impact: 75
Reason: Strong earnings report
Create a sheet with EXACT column names:
Title
Stock
Sentiment
Reason
Important:
Modify:
return output.slice(0, 2);
In IF node:
> 60< -60Edit Generate Sentiment Prompt node to:
Update Google Sheets node mapping:
confidenceimpact_scoreDaily Trading Signals
Portfolio Monitoring
Market Intelligence Systems
Algo Trading Input
Financial News Aggregators
And many more custom use cases depending on your strategy.
| Issue | Possible Cause | Solution |
|---|---|---|
| No data in Google Sheets | Incorrect column names | Ensure exact match: Title, Stock, Sentiment, Reason |
| Emails not sending | Gmail not configured | Add credentials + recipient email |
| AI response parsing error | Invalid JSON from Gemini | Check Parse node logs |
| Duplicate news still appearing | Title mismatch | Improve deduplication logic |
| Workflow not triggering | Schedule inactive | Activate workflow |
| API returns empty data | API downtime | Test endpoint manually |
If you need help with:
Reach out to our n8n workflow development experts at WeblineIndia for advanced assistance.
We can help you build production-grade automation tailored to your business needs.