Skip to content

Starts a scheduled task that scrapes disruption data from the S-Bahn Berlin website and writes it to a webhook

Notifications You must be signed in to change notification settings

DavidNiessen/disruption-notifier

Repository files navigation

Public Transport Disruption Notifier

This app runs a scheduled task that scrapes data from the S-Bahn Berlin website and notifies users about disruptions via webhook.

It uses a real browser to scrape the data and run JS scripts to load the entire page and support SPAs.

Runs every 5 minutes by default

screenshot

Data Flow Diagram (Mermaid)

flowchart TD
    A[TaskScheduler] -->|Runs every 5 minutes| B[ProviderService]
    B -->|For each provider| C[WebScraper]
    C -->|Scrapes URL| D[Selenium WebDriver]
    D -->|Returns loaded page| E[SBahnDataProcessor]
    E -->|Extracts disruption data| F[SBahnDisruptionData]
    F -->|Converts to formatted string| G[DataToFormatedStringConverter]
    G -->|Returns formatted string| H[OutputData]
    H -->|Checks if data changed| I[ProviderCache]
    I -->|If data changed| J[WebHookWriter]
    J -->|Sends notification| K[Webhook]
Loading

About

Starts a scheduled task that scrapes disruption data from the S-Bahn Berlin website and writes it to a webhook

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published