Quick overview
This workflow runs hourly (or manually) to scrape posts from public Telegram channels via Apify, batch-scores them with OpenAI against an intelligence goal, saves qualified items to Google Sheets, and sends a short digest to a Telegram chat while preventing duplicate delivery.
How it works
- Runs on an hourly schedule or is started manually and ensures a delivery-ledger table exists to track what has already been processed.
- Reads the list of public Telegram channel handles plus analysis thresholds and limits, validates the inputs, and builds the Apify Actor request payload.
- Starts FetchCat Telegram Channel Posts Scraper, downloads the resulting dataset, normalizes the post fields, and generates a stable key for every post.
- Filters out posts that are already recorded in the delivery ledger and sends the remaining posts to OpenAI in one structured batch for relevance scoring, summaries, and “why it matters” notes.
- Keeps only posts that meet the minimum relevance score, then upserts them into a Google Sheets tab and formats a Telegram digest of the top items.
- Sends the digest to a Telegram chat and records all evaluated post keys in the delivery ledger so future runs skip them.
Setup
- Add FetchCat Telegram Channel Posts Scraper to your Apify account and create an API token. In n8n, create an HTTP Header Auth credential with header Authorization and value Bearer YOUR_APIFY_TOKEN, then select it in both Apify HTTP Request steps.
- Add an OpenAI API credential and select a model for the batch analysis node.
- Make your own copy of the Telegram Intelligence spreadsheet template. Connect Google Sheets OAuth in n8n, select your copied spreadsheet and its Telegram Intelligence tab, and keep the tab name and row-one headers unchanged.
- Create a Telegram bot with BotFather, connect its token as an n8n Telegram credential, and set the destination chat ID for the digest. Make sure the bot is allowed to post in that chat or channel.
- Update the channel handles, intelligence goal, relevance threshold, and per-run limits in the configuration step before enabling the hourly schedule.
Requirements
Customization
- Change the public channel handles, intelligence goal, minimum relevance score, maximum posts per channel and per run, and maximum alerts per digest in the numbered configuration node. Keep the default hourly schedule for timely monitoring, or change it to daily to reduce executions and cost.
Additional info
Before running the workflow, make your own copy of the Telegram Intelligence spreadsheet template and preserve its Telegram Intelligence tab name and row-one headers. The workflow uses FetchCat Telegram Channel Posts Scraper for public posts and one structured OpenAI batch per non-empty run. It records evaluated post keys only after the Google Sheets write and Telegram delivery succeed, preventing lost or duplicate alerts. Private channels and content unavailable to public web visitors cannot be monitored.