feat: generic RSS/Atom feed provider (fallback for unsupported status pages)#17
Open
anthonybaldwin wants to merge 6 commits into
Open
feat: generic RSS/Atom feed provider (fallback for unsupported status pages)#17anthonybaldwin wants to merge 6 commits into
anthonybaldwin wants to merge 6 commits into
Conversation
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Parse Atom and RSS feeds into the canonical Summary/Incident model: detect feed kind, parse timestamped update blocks into stable-id updates (marker- and prose-based status), synthesize page status, and expose a Provider whose probe matches only real feed documents. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Add "feed" to ProviderId and the monitor schema, register it last in PROBE_ORDER (matches only real feed documents), and reword the /monitor add failure to point users at a direct Atom/RSS feed URL. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
Adds a generic
feedprovider so any status page that publishes a direct Atom or RSS feed can be monitored — used as the last-resort fallback after the vendor providers (Statuspage, incident.io, Instatus). Motivated by Slack's bespokeslack-status.com, which isn't on any vendor platform but does publish/feed/atomand/feed/rss.Why a feed (not a "slack" provider, not HTML scanning)
Research against live Slack + GitHub data (JSON API vs Atom vs RSS):
<content>(a stable<id>+ timestamped update blocks that accumulate in place as the incident progresses). This maps directly onto Squawk's existing dedup-by-id polling model — "one entry = one event we watch for new updates."Per review discussion, discovery is not done by scraping a page's HTML. The user supplies a direct feed URL to
/monitor add; that URL becomes the monitor'sbaseUrl. The feed provider probes last and only matches a parseable Atom/RSS document, so vendor pages always win first and a plain HTML page falls through to a reworded error pointing at the feed-URL path.How it works
feed-text.ts— shared XML-text helpers (decodeEntities,plainTextextracted frominstatus.ts; newparseFeedTimestamp).feed.ts—detectFeedKind(atom vs rss by content),parseFeedUpdates(timestamped blocks → stable-idIncidentUpdates;<strong>STATUS</strong>marker when present, prose keyword-sniff otherwise),parseAtomFeed/parseRssFeed,feedPageStatus, and theProvider."feed"added toProviderId+ monitor schema enum; registered last inPROBE_ORDER;/monitor adderror reworded.minor— feeds carry no impact severity.Verification
bun test— 56 pass / 0 fail (newfeed.test.ts,feed-text.test.ts, registry + feed-fallback detection tests).bun run typecheckclean.Live data shows 6 of 49 Slack incidents (~12%) linger as false-active: all genuinely resolved, but Slack closed them with prose that never contains the word "resolved" (e.g. "…operating within specifications", "…viable workaround"). This is the marker-less heuristic limitation called out in the approved spec — not a parsing bug (verified against raw entries). Consequence: a Slack feed monitor's page status reads "Active Incidents" even when nothing is ongoing, and those stale incidents seed as active.
I deliberately did not expand keyword-sniffing (mid-incident text like "we've identified a fix and are monitoring" would false-positive into resolved).
Recommended follow-up: Slack populates the Atom
<summary>with a past-tense retrospective only on closed incidents — both correctly-resolved entries had it, the false-actives' resolution lived only in<content>. Treating "entry has a finalized<summary>retrospective" (or a generic staleness window) as a resolved signal would clear the false-actives. Left out of this PR as a behavior decision for review.Docs
AGENTS.md,README.md, anddocs/wiki/API-Integration.mdupdated. Design spec and implementation plan included underdocs/superpowers/.🤖 Generated with Claude Code