n8n

How to Generate OpenAI Stock Reports Email?

Send daily stock analysis by email with AI that blends chart signals and news sentiment. Ideal for investor updates, research briefings, and finance newsletters in Hebrew or any local market language.

The flow starts from a form or a schedule. It collects the stock symbol and the recipient email, then calls an AI agent that uses GPT 4o and a structured output format to produce a clear report. Data comes from chart images, price history, and indicators like Bollinger Bands and MACD. It also fetches recent news and scores sentiment. Results are merged, refined, and turned into right to left HTML. The system cleans the layout and emails a finished report.

Setup needs API keys for OpenAI, Twelve Data, Alpha Vantage, and Chart img, plus SMTP for sending. Expect faster research, consistent output, and less manual work. Teams can publish a daily market brief, create investor summaries, or offer paid alerts with little effort.

What are the key features?

  • Form capture for ticker and email address to start the run
  • AI agent with GPT 4o and a structured parser to return fixed fields
  • Technical indicators from Twelve Data including Bollinger Bands and MACD
  • Support and resistance levels calculated from recent price history
  • News sentiment from Alpha Vantage with topic extraction and relevance
  • Chart image generation and download from Chart img for visual context
  • Right to left HTML builder and a cleaner that removes weak topics
  • SMTP email sender that delivers the final report to the recipient
  • Schedule trigger for daily sends and memory to keep context within a session

What are the benefits?

  • Reduce manual research from hours to minutes by automating chart reading and news review
  • Streamline report creation by 80 percent with a single flow from data to email
  • Improve consistency with a structured output that follows the same format every day
  • Connect four data sources in one place to cut copy paste errors by 90 percent
  • Scale to many tickers and recipients without adding staff time
  • Deliver right to left HTML for Hebrew readers with clean layout

How do you set it up?

  1. Import the template into n8n: Create a new workflow in n8n > Click the three dots menu > Select 'Import from File' > Choose the downloaded JSON file.
  2. You'll need accounts with OpenAI, Alpha Vantage, Twelve Data, Chart img and SMTP. See the Tools Required section above for links to create accounts with these services.
  3. In the n8n credentials manager, open the GPT 4o or AI nodes. In the credential dropdown, click Create new credential for OpenAI, then paste your API key from your OpenAI account. Save and test.
  4. For Twelve Data, double click the price and indicator request nodes. In the credentials dropdown, Create new credential using API Key. Get the key from your Twelve Data dashboard. Save and test with a known ticker.
  5. For Alpha Vantage, open the news request node. Create new credential with API Key from your Alpha Vantage account. Run the node once to confirm you receive recent articles.
  6. For Chart img, open the chart URL or download nodes. Create new credential using HTTP Header Auth. Add the required header name and your Chart img API key value. Save and test to receive an image URL and a file.
  7. For SMTP email, open the Send Stock Analysis node. Create new credential with your SMTP host, port, username, and password. Use a from email you control. Send a test email to confirm delivery.
  8. Open the Form Trigger node. Confirm it collects Ticker symbol and Email fields. Copy the form URL and submit a sample entry to verify data arrives in n8n.
  9. Check the Structured Output Parser and AI Agent nodes. Ensure the schema fields match your report needs. Keep Hebrew output if you target right to left readers.
  10. Review the schedule trigger. Set the time and timezone for your daily send. Save and enable the workflow.
  11. Run a full test: submit the form with a live ticker, watch each node run, and confirm the HTML report looks correct and reaches your inbox.
  12. Troubleshoot common issues: rate limits on Alpha Vantage or Twelve Data, invalid Chart img header, OpenAI model access, or SMTP auth errors. Check node error messages and retry with lower frequency if needed.

Tools Required

$24 / mo or $20 / mo billed annually to use n8n in the cloud. However, the local or self-hosted n8n Community Edition is free.

Alpha Vantage

Sign up

Free tier: $0 / mo, up to 25 API requests/day

Chart img

Sign up

Free (BASIC): $0, 50 requests/day, 800x600 max resolution, watermark; API key required

OpenAI

Sign up

Pay-as-you-go: GPT-5 at $1.25 per 1M input tokens and $10 per 1M output tokens

Twelve Data

Sign up

Basic (Free): $0 / mo, 800 API credits/day

Similar Templates

Join Futurise to access 1,200+ automation templates

Get instant access to ready-made automation workflows for n8n, Make.com, AI agents, and more. Download, customise, and deploy in minutes.