跳到正文
DEV Community· Lindenbyte·· 6 小時前AI 評分41

RSS & Atom Feed Monitor 如何避免重複接收新文章和 YouTube 影片通知

Get alerts for new blog posts and YouTube videos without duplicates

AI 導讀

RSS & Atom Feed Monitor 會記錄已讀取的資訊,每次執行只輸出未曾出現的文章或影片項目,並可透過排程和 webhook 傳送通知。每次執行收費 $0.002,每個新項目收費 $0.0008;沒有 RSS feed 的網站可改用 Sitemap Monitor。

正文

Disclosure: I'm Lindenbyte, the small studio that built the Apify Actor used below, and this post was
drafted with AI assistance. A feed reader or a Zapier RSS trigger does a similar job; this is a way to get a
clean, deduplicated stream of only-new items into any tool via a scheduled run and a webhook.

The classic RSS alert problem: every scheduled run returns the whole feed again, so your Slack channel fills with
posts you saw yesterday, and you end up writing "have I seen this?" logic yourself. The RSS & Atom Feed Monitor
keeps that memory for you: each run outputs only items that were not in the feed on the previous run.

1. Start the monitor (baseline run)

Paste feed URLs, or just a blog, a GitHub repo's releases.atom, or a YouTube @handle. The Actor finds the feed itself.

{
  "startUrls": [
    "https://wordpress.org/news/",
    "https://github.com/apify/crawlee/releases.atom",
    "https://www.youtube.com/@GoogleDevelopers",
    "https://github.blog"
  ],
  "onlyNewItems": true,
  "emitOnBaseline": true,
  "maxItemsPerFeed": 3,
  "stateKey": "my-monitor"
}

The first run has nothing to compare to, so emitOnBaseline: true outputs the newest maxItemsPerFeed items per feed as a sample.
Set it to false to remember the current items silently and only ever receive truly new ones, which is the cheapest start.
stateKey names the memory, so you can keep one monitor per Slack channel or client.

In our test (2026-11-16) the four inputs resolved to four feeds: the WordPress blog and github.blog via their <link rel="alternate"> tags,
the GitHub releases Atom feed directly, and the YouTube @GoogleDevelopers handle to its channel feed. The run returned 12 items (3 per feed),
for example "Building with Gemini in Google Antigravity" (YouTube) and "v4.0.0-rc.2" (Crawlee releases).

2. Run it again: nothing new, nothing charged

Run the same input a second time. In our test it returned 0 items and billed 0 item events (you still pay the start fee). In the run summary, 3 of the 4
feeds answered HTTP 304 (conditional GET), so they were not even downloaded again; the YouTube feed was re-read and had nothing new. The per-feed summary is
saved in the key-value store record RUN-SUMMARY.

3. Schedule it and send new items to Slack

  1. In Apify Console, open the Actor and click Schedule (hourly or daily, depending on how busy the feeds are).
  2. Under Integrations, add Slack, email, Zapier, Make or a generic webhook that fires on "Run succeeded".
  3. Add filters so you only see what matters:
{
  "startUrls": ["https://wordpress.org/news/", "https://github.blog"],
  "onlyNewItems": true,
  "emitOnBaseline": false,
  "includeKeywords": ["security", "release", "AI"],
  "excludeKeywords": ["sponsored"],
  "publishedAfter": "7 days"
}

Keywords match the title and summary, case-insensitively. Items removed by a filter are recorded as seen and are free.

You can also fetch results yourself, for example in a small script that posts the new items:

from apify_client import ApifyClient

client = ApifyClient("<YOUR_APIFY_TOKEN>")
run = client.actor("lindenbyte/rss-feed-monitor-new-items").call(run_input={
    "startUrls": ["https://www.youtube.com/@GoogleDevelopers"],
    "stateKey": "my-monitor", "emitOnBaseline": False,
})
for item in client.dataset(run["defaultDatasetId"]).iterate_items():
    print(f"{item['feedTitle']}: {item['title']} {item['link']}")

4. Don't know the feed? Use the feed finder

Set discoverOnly: true and get one row per working feed found for a list of sites, with format, item count and the latest item date.
We ran it on github.blog, theverge.com, daringfireball.net and example.com: 4 feed rows (The Verge Atom with 10 items, GitHub Blog RSS with 10,
Daring Fireball Atom with 48, and a comments feed on github.blog with 0 items). example.com has no feed, so it is reported as an error in RUN-SUMMARY and not charged.

What if the site has no feed?

Plenty of sites publish no RSS at all. For those, use our Sitemap Monitor,
which diffs a site's sitemap and reports new URLs the same way: schedule it, get only new pages.

Limits (honest ones)

  • A feed only exposes its latest N items. If more than N are published between runs, the older ones are gone before the Actor sees them; schedule more often for busy feeds.
  • "New" means a new guid (else link, else title + date). Edited items with the same guid are not reported again, and a publisher that changes guids will look like re-publishing.
  • Summary-only feeds give you the summary, not the full article. No logins, paywalls or bot-protected feeds.
  • If you only follow a handful of blogs, a free reader (Feedly, Inoreader, a Slack RSS app) is enough. This Actor is for pipelines: schedules, API, webhooks and many feeds at once.

Cost: $0.002 per run, $0.0008 per new item, $0.002 per feed found. Our baseline run with 12 items cost $0.0116, the repeat run $0.002, and the 4-feed finder run $0.010.


Not affiliated with YouTube, Google, GitHub, WordPress or any publisher whose feed it reads.

來源:DEV Community · dev.to