Alert crop scouts to wind-driven pest threats with GBIF, Gemini, and Slack

Go to Workflow
0 views
Built by iamvaar iamvaar
Created on August 09, 2026

Description

Quick overview
Workflow Link: https://youtu.be/3ExkAWTyEXU?si=R7bAUzHqf1_LpHnT

This workflow runs daily at 6 AM to check GBIF for recent invasive pest occurrences near a farm, combines them with Open-Meteo wind data to assess whether winds could carry pests toward the farm, and uses Gemini send a concise Slack alert to field scouts.

How it works
Runs every day at 6 AM on a schedule.
Sets the farm latitude/longitude, search radius, lookback windows, wind-alignment tolerance, and the target Slack channel.
Queries the GBIF Occurrence Search API for recent invasive/introduced pest occurrences within the configured distance of the farm.
If any nearby occurrences are found, fetches recent wind speed and direction data for the farm location from the Open-Meteo API.
Calculates average wind direction and flags occurrences where the wind direction aligns with the bearing from the occurrence toward the farm.
If at least one wind-aligned threat exists, sends the threat data to a Google Gemini-powered agent to draft a short, prioritized scouting alert.
Posts the generated alert text to the configured Slack channel.

Setup
Replace the farm latitude and longitude values with your coordinates (as numbers) and adjust radius, lookback days, and alignment tolerance to match your scouting area.
Add Google Gemini (Google PaLM) API credentials for the Gemini chat model used to generate the Slack alert text.
Add Slack API credentials and set a valid destination channel name in the configuration so the workflow can post alerts.

Nodes Used (5)

AI Agent
@n8n/n8n-nodes-langchain.agent
Code
n8n-nodes-base.code
Google Gemini Chat Model
@n8n/n8n-nodes-langchain.lmChatGoogleGemini
HTTP Request
n8n-nodes-base.httpRequest
Slack
n8n-nodes-base.slack