Skip to main content

Generate stock trading signals with Gemini 2.5 Pro & TwelveData via Telegram Bot

Workflow preview

Workflow preview
100%
Generate stock trading signals with Gemini 2.5 Pro & TwelveData via Telegram Bot preview
Open on n8n.io

Important notice

This workflow is provided as-is. Please review and test before using in production.

1. Workflow Overview

Purpose and Audience This n8n workflow template creates an intelligent stock technical analysis system that delivers professional grade trading signals directly to your Telegram. Designed for retai...

Best for

  • Crypto Trading automation workflows
  • AI Chatbot automation workflows
  • advanced n8n builders looking for reusable templates

Tools used

n8n-nodes-base.httprequest, n8n-nodes-base.merge, @n8n/n8n-nodes-langchain.outputparserstructured, @n8n/n8n-nodes-langchain.memorybufferwindow, @n8n/n8n-nodes-langchain.lmchatgooglegemini, n8n-nodes-base.telegramtrigger, n8n-nodes-base.stickynote, n8n-nodes-base.set

Source and attribution

This workflow is cataloged by N8N Workflows and links back to its original n8n.io source page by Malik Hashir.

Original n8n.io source

1.1 Workflow description

Title
Generate stock trading signals with Gemini 2.5 Pro & TwelveData via Telegram Bot
Workflow name
Generate stock trading signals with Gemini 2.5 Pro & TwelveData via Telegram Bot

Purpose and Audience

This n8n workflow template creates an intelligent stock technical analysis system that delivers professional-grade trading signals directly to your Telegram. Designed for retail traders, investors, and financial professionals who want to combine technical analysis with AI-powered insights for better market timing decisions.

Who Is It For

  • Retail Traders: Looking to enhance their technical analysis with AI-driven insights
  • Swing Traders: Need reliable signals for entry and exit timing
  • Investment Professionals: Want automated technical screening for multiple stocks
  • Financial Enthusiasts: Interested in combining traditional TA with modern AI tools
  • Portfolio Managers: Seeking systematic approach to market timing

How It Works

The workflow operates as a comprehensive technical analysis engine:

  1. Data Collection: Fetches real-time stock prices and 90-day historical data from TwelveData API
  2. Technical Calculation: Computes key indicators including EMAs, RSI, ATR, and support/resistance levels
  3. AI Analysis: Uses Google Gemini 2.5 Pro to analyze confluence of indicators and generate single, high-probability signals
  4. Signal Generation: Produces clear BUY/SELL/NEUTRAL recommendations with specific entry, stop-loss, and take-profit levels
  5. Delivery: Sends formatted analysis and interactive charts via Telegram bot
  6. Risk Management: Includes built-in risk parameters and confidence scoring

Setup Requirements

  1. Create Telegram bot via BotFather
  2. Set up Google Gemini credentials
  3. Configure additional nodes as you see in the sticky notes
  4. Deploy and test with stock symbols (e.g., "AAPL", "TSLA")

Note: Complete setup guide is provided with the workflow file.

Technical Indicators Used in Strategy

Core Indicators (1-Day Timeframe):

  1. EMA 50 & EMA 200: Trend direction and momentum confirmation
  2. RSI (14-period): Momentum oscillator for overbought/oversold conditions
  3. ATR (14-period): Volatility measurement for risk sizing
  4. Support/Resistance: Dynamic levels calculated from 90-day price history.
  5. Fibonacci Retracements: Additional confluence levels.

Important Disclaimers

  • ⚠️ Analysis timeframe is set to 1-day by default - suitable for swing trading, not day trading
  • ⚠️ Not a get-rich-quick system - This tool provides technical analysis, not financial advice
  • ⚠️ Use with fundamental analysis - Technical signals work best when combined with fundamental research for timing entries and exits
  • ⚠️ Not recommended for isolated use - Always consider fundamentals, market conditions, news, and risk management

Key Features

  • Single, clear signal per analysis (no conflicting recommendations; either buy or sell)
  • Built-in confidence scoring system
  • Automated chart generation and delivery
  • Support for any US stock ticker
  • Professional-grade risk management parameters

Use Case Examples

  1. Pre-market Analysis: Send "AAPL" stock ticker as a message to your telegram bot and get comprehensive technical analysis with 1 Day candlesticks chart
  2. Swing Trading: Use signals to time entries on already-researched stocks
  3. Portfolio Review: Analyze multiple positions for exit timing
  4. Educational Tool: Learn technical analysis through AI explanations

This template transforms complex technical analysis into accessible, actionable trading insights while maintaining professional risk management standards.

1.2 Logical Blocks

This catalog entry is organized from the workflow JSON. The node-level section below shows the executable blocks available for review before importing the template.

2. Block-by-Block Analysis

Block 1 - Real Time Price

Type / Role
n8n-nodes-base.httpRequest - httpRequest
Config choices
Version 4.2

Block 2 - Merge1

Type / Role
n8n-nodes-base.merge - merge
Config choices
Version 3.1

Block 3 - Structured Output Parser

Type / Role
@n8n/n8n-nodes-langchain.outputParserStructured - outputParserStructured
Config choices
Version 1.2

Block 4 - Simple Memory

Type / Role
@n8n/n8n-nodes-langchain.memoryBufferWindow - memoryBufferWindow
Config choices
Version 1.3

Block 5 - Google Gemini Chat Model

Type / Role
@n8n/n8n-nodes-langchain.lmChatGoogleGemini - lmChatGoogleGemini
Config choices
Version 1

Block 6 - Telegram Trigger

Type / Role
n8n-nodes-base.telegramTrigger - telegramTrigger
Config choices
Version 1.2

Block 7 - EMA 50 - 1D

Type / Role
n8n-nodes-base.httpRequest - httpRequest
Config choices
Version 4.1

Block 8 - EMA 200 -1D

Type / Role
n8n-nodes-base.httpRequest - httpRequest
Config choices
Version 4.1

Block 9 - RSI -1D

Type / Role
n8n-nodes-base.httpRequest - httpRequest
Config choices
Version 4.1

Block 10 - ATR -1D

Type / Role
n8n-nodes-base.httpRequest - httpRequest
Config choices
Version 4.1

Block 11 - Sticky Note

Type / Role
n8n-nodes-base.stickyNote - stickyNote
Config choices
Version 1

Block 12 - Add Twelve Data API Key

Type / Role
n8n-nodes-base.set - set
Config choices
Version 3.4

Block 13 - Sticky Note1

Type / Role
n8n-nodes-base.stickyNote - stickyNote
Config choices
Version 1

Block 14 - Wait -65s

Type / Role
n8n-nodes-base.wait - wait
Config choices
Version 1.1

Block 15 - Wait1 -65s

Type / Role
n8n-nodes-base.wait - wait
Config choices
Version 1.1

Block 16 - Sticky Note2

Type / Role
n8n-nodes-base.stickyNote - stickyNote
Config choices
Version 1

Block 17 - OHLC -1Day

Type / Role
n8n-nodes-base.httpRequest - httpRequest
Config choices
Version 4.1

Block 18 - Calculate Support Resistance

Type / Role
n8n-nodes-base.code - code
Config choices
Version 2

Block 19 - Sticky Note3

Type / Role
n8n-nodes-base.stickyNote - stickyNote
Config choices
Version 1

Block 20 - Sticky Note4

Type / Role
n8n-nodes-base.stickyNote - stickyNote
Config choices
Version 1

Block 21 - Set Stock Ticker

Type / Role
n8n-nodes-base.set - set
Config choices
Version 3.4

Block 22 - Sticky Note5

Type / Role
n8n-nodes-base.stickyNote - stickyNote
Config choices
Version 1

Block 23 - Sticky Note6

Type / Role
n8n-nodes-base.stickyNote - stickyNote
Config choices
Version 1

Block 24 - Organizing Data

Type / Role
n8n-nodes-base.code - code
Config choices
Version 2

Showing the first 24 of 36 workflow blocks. Download the JSON for the full node graph.

3. Summary Table

Workflow Generate stock trading signals with Gemini 2.5 Pro & TwelveData via Telegram Bot
Complexity advanced
Nodes 36
Categories Crypto Trading, AI Chatbot
Author Malik Hashir
Published 27 Sept 2025

4. Reproducing the Workflow from Scratch

  1. 1. Download the workflow JSON

    Use the JSON export at /data/workflows/9015/9015.json as the source template for this automation.

  2. 2. Import the template into n8n

    Open n8n, import the downloaded JSON, and review each node before activating the workflow.

  3. 3. Configure credentials and variables

    Replace placeholder credentials, API keys, webhook URLs, account IDs, and environment-specific values with your own settings.

  4. 4. Test with sample data

    Run the workflow manually or in a staging workspace, inspect node output, and confirm downstream systems receive the expected data.

  5. 5. Activate and monitor

    Enable the workflow only after testing, then monitor executions, errors, and rate limits during the first production runs.

5. General Notes & Resources

Review imported nodes carefully before activation. This catalog entry is intended to help you inspect the workflow structure, understand required services, and find related templates faster.

Node names, credentials, schedules, webhook paths, and external service limits may need adjustment for your workspace.

Frequently asked questions

What does Generate stock trading signals with Gemini 2.5 Pro & TwelveData via Telegram Bot do?

Purpose and Audience This n8n workflow template creates an intelligent stock technical analysis system that delivers professional grade trading signals directly to your Telegram. Designed for retai...

What do I need before importing this workflow?

Review the workflow JSON, configure any required credentials in n8n, and test the automation in a safe workspace before using it in production.

Can I customize this workflow?

Yes. Use the block-by-block analysis and the downloadable JSON to inspect each node, then adjust credentials, prompts, schedules, filters, or destinations for your Crypto Trading, AI Chatbot use case.