Send multi-city weather forecasts with AI-enhanced formatting from OpenWeatherMap to Gmail
Ready for 3.0What this workflow does
This AI workflow has 12 nodes and runs when someone submits an n8n form (“Weather predictor demo task”). Along the way it connects Gmail and OpenAI. It also calls api.openweathermap.org over HTTP.
How it runs
Trigger: When someone submits an n8n form (“Weather predictor demo task”).
- JS - Normalize City Inputs (Code): runs custom JavaScript code
- HTTP - OWM Geocoding (HTTP Request): calls api.openweathermap.org
- Merge: merges the data from its input branches
- JS - Pick Lat/Lon (Code): runs custom JavaScript code
- SET - Carry Asked City to Forecast (Edit Fields (Set)): sets 1 field: asked_city
- OpenWeatherMap: 5 day forecast
- JS - Build Daily Summaries (5 days) (Code): runs custom JavaScript code
- JS - Bundle Cities for LLM (Code): runs custom JavaScript code
- LLM - AI Weather Briefing Composer (OpenAI): uses OpenAI
- JS - Validate JSON from LLM (Code): runs custom JavaScript code
…plus 1 more step. See the full node list below.
Services it uses
HTTP calls to: api.openweathermap.org
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 (8)
- Code
n8n-nodes-base.code - Gmail
n8n-nodes-base.gmail - OpenWeatherMap
n8n-nodes-base.openWeatherMap - Edit Fields (Set)
n8n-nodes-base.set - Merge
n8n-nodes-base.merge - HTTP Request
n8n-nodes-base.httpRequest - n8n Form Trigger
n8n-nodes-base.formTrigger - OpenAI
@n8n/n8n-nodes-langchain.openAi
From the author
Overview This workflow automates weather forecast delivery by collecting city names, fetching 5-day forecasts from OpenWeatherMap, and generating professionally formatted HTML emails using GPT-4. The AI creates condition-based color-coded reports with safety…