Send Storm Alert Email
send_storm_alert.RdMain orchestrator: fetches forecasts, detects storms, and sends an email alert if strong gale winds (Beaufort 9+) are forecast. If no storms are detected, no email is sent. Uses the same Gmail SMTP pattern as the weekly email report.
Usage
send_storm_alert(
threshold_knots = NULL,
recipient = Sys.getenv("GMAIL_USERNAME"),
sender = Sys.getenv("GMAIL_USERNAME"),
dry_run = FALSE
)Value
List with: status ("sent", "no_storms", "preview", "error"), n_storms, stations_affected, preview_file (if dry_run), error (if failed).
See also
Other storm-alert:
beaufort_to_description(),
create_storm_alert_email(),
detect_storm_events(),
fetch_all_forecasts(),
fetch_all_marine_forecasts(),
fetch_met_eireann_warnings(),
fetch_open_meteo_forecast(),
fetch_open_meteo_marine(),
knots_to_beaufort(),
p_hmax_exceedance(),
summarise_forecast_rogue_risk()