π Monitor Truth Social posts for Iran-Israel risk and alert Discord with Bright Data and OpenAI
β‘ 0 views Β· π Market Research & Insights
Description
Quick overview
This workflow polls a Truth Social account every minute via Bright Data, tracks the newest processed post ID in an n8n Data Table, uses OpenAI (GPT-4o-mini) to classify posts about IranβIsraelβUS tensions, and sends relevant alerts to a Discord channel.
How it works
- Runs every minute on a cron schedule.
- Reads the stored
last_idcursor from an n8n Data Table and requests newer Truth Social statuses through the Bright Data API. - If new statuses are returned, extracts key fields (content and timestamp) and updates
last_idto the highest status ID in the batch. - Prefilters posts with a keyword/regex check to avoid sending obviously irrelevant content to OpenAI.
- Sends remaining posts to OpenAI (GPT-4o-mini) to extract a relevance flag, severity level, and one-sentence reason.
- Posts a formatted alert to Discord for items OpenAI marks as relevant.
Setup
- Create or select a Bright Data HTTP Bearer credential and ensure the
fetch_truthszone exists in your Bright Data account. - Add an OpenAI API credential and confirm the selected model (for example,
gpt-4o-mini) is available to your account. - Add a Discord Webhook credential and set it to the channel where alerts should be posted.
- Run the included one-time setup path to create the
workflow_stateData Table and initializelast_id(rerunning it resets the cursor to 0).
π Nodes Used
Cron, HTTP Request, Discord, OpenAI Chat Model, Information Extractor, Data table
π₯ Import
Download workflow.json and import into n8n:
Workflow menu β Import from File