Sitemap New Pages Watch: Added & Removed URLs avatar

Sitemap New Pages Watch: Added & Removed URLs

Pricing

from $20.00 / 1,000 sitemap change reports

Go to Apify Store
Sitemap New Pages Watch: Added & Removed URLs

Sitemap New Pages Watch: Added & Removed URLs

Compare a site's robots-permitted public sitemap with the previous run and report added, removed and updated URLs as JSON or CSV.

Pricing

from $20.00 / 1,000 sitemap change reports

Rating

0.0

(0)

Developer

Practical AI Lab

Practical AI Lab

Maintained by Community

Actor stats

0

Bookmarked

2

Total users

1

Monthly active users

19 hours ago

Last modified

Security

Limited permissions

Share

Give this Actor a public HTTPS site root. It reads the site's robots.txt, fetches only the sitemap files that robots.txt permits, stores a per-domain baseline of listed URLs, and on every later run reports which URLs were added, removed, or had their sitemap lastmod changed. Results are available as a dataset (JSON) and as a CSV file.

It does not crawl pages. It only reads sitemap XML, so runs are small and fast.

Typical uses

  • SEO and content teams tracking when a competitor or partner publishes new pages.
  • Agencies watching client sites for pages that disappear after a redeploy.
  • Directory, catalog and documentation owners who want a scheduled "what changed" list.

Quick start (copy this input)

{
"startUrl": "https://www.python.org/",
"maxUrls": 5000,
"reportUpdated": true
}

Replace startUrl with a site you are allowed to monitor. Whether a given site publishes a usable sitemap is up to that site; the Actor reports NO_SITEMAP when none is found.

  1. First run creates the baseline and outputs one BASELINE_CREATED row. No changes are reported.
  2. Later runs compare against the baseline and output one row per change.

Input

FieldDefaultMeaning
startUrl (required)Public HTTPS site root, no path or query.
includePathPrefixesnoneTrack only URLs under these paths (e.g. /blog/). Each distinct set has its own baseline.
reportUpdatedtrueAlso report URLs whose lastmod changed.
maxUrls5000Hard cap (max 50000). Exceeding it ends the run as INCOMPLETE_SCAN.
maxSitemapFiles25Cap on sitemap files read, including those named in sitemap indexes (max 100).
maxChangesReported2000Cap on dataset rows; totals are still in SUMMARY.
resetBaselinefalseReplace the stored baseline with this run's snapshot.
baselineStoreNamepal-sitemap-watch-baselinesNamed key-value store holding baselines.

Output

Dataset rows (recordType: "CHANGE") contain changeType (ADDED, REMOVED, UPDATED), url, lastmod, previousLastmod, sourceSitemap, startUrl, domain, detectedAt, previousCheckedAt and baselineCreatedAt. Runs without changes produce one RUN_STATUS row with a status and message.

Key-value store records of the run: SUMMARY (counts, skip counters, status) and CHANGES_CSV (the same rows as CSV).

Run statuses

StatusMeaningRun resultBillable event
BASELINE_CREATEDFirst run for this site/filterSucceededNo
NO_CHANGESNothing changedSucceededNo
CHANGES_DETECTEDAdded, removed or updated URLs foundSucceededYes (one sitemap-change-report event)
ROBOTS_BLOCKEDrobots.txt forbids access to the sitemapsSucceededNo
NO_SITEMAPNo sitemap found, or it contains no usable URLsSucceededNo
INCOMPLETE_SCANA limit was hit or a listed file failed; nothing savedFailedNo
SITEMAP_ERROR / FETCH_ERRORBroken XML, HTTP errors, unsafe redirectFailedNo
INVALID_INPUTBad or unsafe inputFailedNo

A failed or incomplete run never overwrites the baseline, so the next good run still compares against the last complete snapshot.

The code requests one sitemap-change-report charge event only when changes are reported. No price is configured in this project; pricing is set separately by the publisher.

Scheduling

Create a Task with your input and add an Apify Schedule (for example daily). Keep the default baselineStoreName: baselines live in a named key-value store, which persists across runs, unlike the per-run default store. Use a different name per customer or project if you want separate baselines. Because baselines are keyed by hostname, two tasks watching the same host with the same filters and the same store share one baseline.

Safety behavior

  • HTTPS only, default port only, no credentials in URLs, no IP-address hosts, no localhost or internal-style hostnames.
  • The hostname must resolve only to public addresses (checked before every request).
  • Redirects are followed at most 3 times and only to the same HTTPS host; anything else is refused.
  • robots.txt is read first. Sitemap files and listed URLs that it disallows for this Actor are skipped. A 401/403 on robots.txt is treated as a block; an unreachable robots.txt is an error.
  • Response sizes are bounded (robots 512 KB, sitemap download 10 MB, decompressed 20 MB). Sitemap DTD/entity declarations are rejected.
  • URLs that look like they contain an email address are dropped. The Actor never visits listed pages, logs in, uses proxies, or sends notifications.

Limitations and caveats

  • A sitemap is not the whole site. Pages missing from the sitemap are invisible, and a URL leaving the sitemap does not necessarily mean the page was deleted.
  • lastmod quality varies. Many sites omit it or set it to the build time, which can create noisy UPDATED rows. Turn off reportUpdated for such sites.
  • Caps are strict. Sites with more than maxUrls URLs (max 50,000) cannot be monitored in a single baseline; use includePathPrefixes to split them.
  • Only URLs on exactly the monitored hostname are tracked; sitemaps on other hosts or subdomains are ignored.
  • Robots handling uses Python's standard parser, which follows first-match rules and may differ from other crawlers on complex wildcard rules.
  • Address checks happen before each request but the HTTP library resolves the name again when connecting, so DNS rebinding cannot be ruled out entirely.
  • Sitemap index nesting is limited to 3 levels, and gzip sitemaps are supported.
  • Time-of-run is when the Actor observed the change, not when the site published it.
  • The offline test suite uses mocked HTTP only. Behavior on real sites has not been benchmarked here, so no performance, accuracy or demand figures are claimed.

Development

python -m unittest discover -s tests

Tests need no network and no Apify runtime.