See llms.txt for all machine-readable content.

Back to Templates

Summarize new YouTube videos with Apify and OpenAI and log to Notion and Slack

Quick overview

Each morning this lists a channel's newest videos, pulls the YouTube transcript for the ones it has not seen, writes an AI summary, takeaways and a relevance score into a Notion database, and posts to Slack only when a video mentions the topics you track.

How it works

  1. A schedule starts the workflow every morning.
  2. The first Actor call lists the newest videos on each channel you watch. Listing rows are free.
  3. Remove Duplicates drops every video seen in a previous run, so only new uploads continue.
  4. The new URLs are collected into one batch; if nothing is new the workflow stops here.
  5. The second Actor call fetches the YouTube transcript for the new videos only.
  6. Videos without a caption track take a lower path and are still logged with the reason.
  7. A Code node finds each tracked topic in the timestamped transcript, counts the hits and builds a link that opens the video at the first mention.
  8. The Information Extractor asks the chat model for a summary, three takeaways, tags, a 0 to 10 relevance score and a one-line reason.
  9. A decision node sets Status to "Watch this" when a topic was found or the score reaches your threshold, otherwise "Archived".
  10. Every video becomes a page in your Notion database.
  11. Slack gets a message only for the pages marked "Watch this".

Setup

  1. Create a free Apify account, copy the API token from Settings, Integrations, and add it as an Apify credential on both Actor nodes.
  2. Add an OpenAI credential on the chat model node, or replace that node with any other chat model.
  3. In Notion, create an internal integration, create a database with the 13 properties listed in the sticky note, share the database with the integration, add the token as a Notion credential, and pick the database in the Notion node.
  4. In Slack, create an app with the chat:write scope, install it, invite the bot to your channel, add the bot token as a Slack credential, and pick the channel in the Slack node.
  5. Edit the first node: your channels, the topics to track, the transcript language and the relevance threshold.
  6. Run the workflow once by hand, check the Notion pages and the Slack message, then activate it.

Requirements

  • An Apify account; the free tier covers a daily channel watch
  • An OpenAI API key, or any chat model credential n8n supports
  • A Notion internal integration and a database with the 13 listed properties
  • A Slack bot token with the chat:write scope
  • Videos with captions; auto-generated captions work, and videos without captions are logged as "No transcript"

Customization

  • Change topics to the phrases you care about; matching is case-insensitive and counts every mention
  • Raise or lower relevanceThreshold to make the model stricter or looser about what reaches Slack
  • Watch several channels at once by adding handles, channel IDs or URLs to channels
  • maxVideos controls how far back the first run looks; later runs only see new uploads
  • Swap the OpenAI chat model node for Gemini, Anthropic, Ollama or any other chat model
  • Use the optional Gmail node for a daily email digest instead of Slack
  • Add the optional filter to skip Shorts and clips under 90 seconds
  • Replace the channel listing with the optional fixed-list node to summarize a set of URLs
  • Set language for channels that publish captions in another language

Additional info

How do I extract the transcript from a YouTube video automatically? This template does it on a schedule. It lists a channel, remembers which videos it has already processed, and fetches the YouTube transcript for the new ones through an Actor that reads the public caption track. There is no audio to upload and no transcription model to pay for.

Does the YouTube Data API v3 provide transcripts? No. The Data API returns titles, statistics and comments, and its captions endpoint only works for videos you own. That gap is why this workflow uses a transcript Actor instead of a YouTube API key.

Can AI make a transcript of a YouTube video here? The transcript itself is YouTube's caption track, manual or auto-generated. The AI step only summarizes it, pulls out takeaways and tags, and scores how relevant the video is to your topics, so the text you search is what the video actually says.

Why does the workflow call the Actor twice? The first call only lists the channel's newest videos, and listing rows cost nothing. The dedupe step then removes anything seen in a previous run, and the second call fetches transcripts for the remaining videos. A channel you have watched for months costs you only its new uploads.

How is "Watch this" decided? A video is flagged when one of your tracked topics appears in the transcript, or when the model's relevance score reaches your threshold. Both signals are written to the Notion page, along with the model's one-line reason, so you can see why something was flagged and tune the threshold.

Why does a video show "No transcript"? Some videos have no caption track, and some are unavailable or private. The Actor returns a clear error for those, the workflow takes the lower path, and the video still gets a Notion page with the reason in the Why property instead of disappearing.

What does it cost? Listing rows are free. On Apify's free tier a transcript costs about $0.0028, charged only for new videos, and the two Actor runs use 256 MB each. The transcript sent to the chat model is capped at 40,000 characters, so a long video has a bounded model cost.

What else can the Actor do? YouTube Transcript & Subtitles Scraper API also translates transcripts, exports SRT and VTT, transcribes a whole channel in one run, and caches results for 90 days so repeated requests return in seconds. If you self-host n8n, the n8n-nodes-youtube-transcripts-api community node wraps the same Actor with a form instead of JSON.

About Apify. YouTube Transcript & Subtitles Scraper API runs on Apify, a platform of ready-made scrapers and APIs for sources that have no usable public API. Actors are pay per use with no subscription, and they run in the cloud, so nothing runs on your machine and nothing breaks when the source changes its markup.

New to Apify? You can set up a free account and get the API token this template needs in a couple of minutes.