Fetches daily precipitation data from the NOAA NCEI public API (no API key needed) for the current rain season (Oct 1 – present) and generates a report.
# No dependencies beyond Python 3.10+ standard library
python weather/noaa_rainfall.py
python weather/noaa_rainfall.py # Pretty-printed console report
python weather/noaa_rainfall.py --json # Raw JSON
python weather/noaa_rainfall.py --csv # CSV (pipeable)
Credentials are stored in your macOS Keychain — nothing is saved in plaintext.
# 1. One-time setup (interactive, saves to Keychain)
python weather/noaa_rainfall.py --setup-email
# 2. Send a report
python weather/noaa_rainfall.py --email you@gmail.com
For Gmail, use an App Password (not your main password).
Credentials are stored under the Keychain service noaa-rainfall-tracker. You can view/delete them in Keychain Access.app or via security delete-generic-password -s noaa-rainfall-tracker -a smtp_pass.
Non-macOS fallback: set SMTP_USER and SMTP_PASS environment variables.
Send yourself a weekly update every Monday at 8 AM:
0 8 * * 1 cd /path/to/atlas && python weather/noaa_rainfall.py --email you@gmail.com
python weather/noaa_rainfall.py --start 2024-10-01 --end 2025-03-15
https://www.ncei.noaa.gov/access/services/data/v1 (public, no auth)daily-summaries)