Send NSE stock watchlist alerts with Google Sheets and Gmail
Ready for 3.0What this workflow does
This workflow has 14 nodes and runs on a schedule (cron */5 9-15 * * 1-5). Along the way it connects Google Sheets and Gmail. It also calls memic-nse-quotes-api.hf.space over HTTP.
How it runs
Trigger: On a schedule (cron */5 9-15 * * 1-5).
- Load Stock Watchlist (Google Sheets): uses Google Sheets
- Filter Active Stocks (Code): runs custom JavaScript code
- Prepare NSE Quote Request (Edit Fields (Set)): sets 2 fields: apiBody, watchlistRows
- Fetch NSE Market Quotes (HTTP Request): calls memic-nse-quotes-api.hf.space (POST)
- Detect Buy Sell Signals (Code): runs custom JavaScript code
- Check Alert Availability (If): checks a condition and branches into true / false
- Route Alert Type (Switch): routes items into 2 branches
- Build Sell Alert Message (Edit Fields (Set)): sets 6 fields: alertMessage, subject, symbol…
- Build Buy Alert Message (Edit Fields (Set)): sets 6 fields: alertMessage, subject, symbol…
- Combine Alert Streams (Merge): merges the data from its input branches
…plus 2 more steps. See the full node list below.
Services it uses
HTTP calls to: memic-nse-quotes-api.hf.space
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)
- Schedule Trigger
n8n-nodes-base.scheduleTrigger - Google Sheets
n8n-nodes-base.googleSheets - Code
n8n-nodes-base.code - Edit Fields (Set)
n8n-nodes-base.set - If
n8n-nodes-base.if - No Operation, do nothing
n8n-nodes-base.noOp - Switch
n8n-nodes-base.switch - Merge
n8n-nodes-base.merge - Gmail
n8n-nodes-base.gmail - HTTP Request
n8n-nodes-base.httpRequest
From the author
Quick overview This workflow polls a Google Sheets stock watchlist every five minutes during weekday market hours, fetches live quotes from an NSE quotes HTTP API, and sends Gmail alerts when prices cross buy-below or sell-above thresholds while logging each…