Per-location alert feed (RSS / JSON / iCal) #75
Labels
No labels
area:ai
area:ci-cd
area:notifications
area:observability
area:public-pages
backlog
bug
duplicate
enhancement
help wanted
invalid
question
type:decision
type:feature
type:infra
type:maintenance
type:security
v1.0.1
v1.1.0
v1.2.0
v1.3.0
v2.0.0
wontfix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
rbrooks/WeatherBot#75
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Public pages exist; a
/p/{token}.jsonor RSS variant makes locations consumable by other homelab automations (Home Assistant!). Effort S, value M for the integration-minded.Filed from the 2026-07-17 codebase audit (
docs/.internal/report-2026-07-17.md), finding I-05.Done in #112 (merged).
GET /p/{location_id}.json|.rss|.ics— JSON, RSS 2.0, and iCal feeds of a location's active alerts, gated byLocation.public_enabled+ the public rate limiter, exposing the same alert set as the public HTML page. Stdlib-only builders inservices/feeds.py(proper XML escaping; RFC-5545 iCal escaping + line folding), no new deps. Routes are defined before the/p/{token}catch-all and the PublicToken alphabet has no dots, so there's no collision.Implementation note: I used the location's own
idas the feed token (mirroring the existing/api/locations/{id}/publicpage) rather than minting single-alertPublicTokens, since those map to one alert lifecycle each, not a whole-location feed.Follow-up (not blocking):
SentAlerthas noonset/area_desccolumns (they live onNWSAlertSnapshot), so the JSON exposes them as null and iCalDTSTARTfalls back tosent_at. A snapshot-join backfill would enrich the feeds (and pairs naturally with #84's lead-time work).