Financial Data Q&A Chatbot with Google Finance, SerpAPI, and OpenAI
Created by
rbRobert BreenLast edited 58 days ago
Replace YOUR_API_KEY with your actual SerpApi key.
2️⃣ Set Up OpenAI Connection
- Go to OpenAI Platform
- Navigate to Billing and ensure your account has credits/funding
- Copy your API Key into the OpenAI credentials in n8n
🧠 Workflow Breakdown
- Chat Trigger → User enters a financial question (e.g., “What’s the current price of Tesla?”).
- HTTP Request (SerpApi Finance Search) → Fetches the latest market data for the requested ticker or index.
- OpenAI Node → Takes both the raw financial data and the user’s query, then formulates a natural language response.
- Output → Returns a clear, conversational answer that can be displayed in chat, Slack, or another integration.
🎛️ Customization Guidance
- Multiple Tickers: Update the workflow to query multiple tickers (e.g., TSLA, AAPL, AMZN) and return a combined report.
- Scheduling: Add a Schedule Trigger to run this workflow every morning and send a market recap.
- Delivery Channels: Use Slack, Email, or Google Sheets nodes to distribute reports automatically.
- Extended Data: Adjust the SerpApi query to include more than prices — e.g., company info, market news, or related tickers.
- Custom Prompts: Change the OpenAI system prompt to make the chatbot more formal (for reporting) or casual (for quick insights).
💬 Example Questions & Responses
Question: “What’s the current price of the S&P 500?”
Expected Response:
“The S&P 500 (^GSPC) is currently trading at 4,725.13, down 0.8% today.”
Question: “Summarize the performance of Tesla and Apple today.”
Expected Response:
- Tesla (TSLA): $238.45, up 1.5%
- Apple (AAPL): $192.11, down 0.3%
Question: “Give me a quick market recap.”
Expected Response:
“Markets are mixed today — the S&P 500 is slightly down, while tech stocks like Tesla are showing gains. Apple dipped slightly after earnings news.”
📬 Contact
Need help customizing this workflow (e.g., multiple tickers, daily summaries, or integrating into dashboards)?
You may also like
New to n8n?
Need help building new n8n workflows? Process automation for you or your company will save you time and money, and it's completely free!





