I Automated My Weekly Reporting With 40 Lines of Node (No Zapier, No n8n)
Description and use
Automated weekly reporting with 40 lines of Node: collect, normalize, compute, and render in ~6 s, avoiding SaaS tools.
Problem
Every Friday the author spent two hours copy‑pasting numbers into a report, and existing SaaS automation tools failed when upstream fields changed, hit free‑tier limits, or hid logic.
Outcome
The script automates weekly reporting in ~6 s, eliminates manual effort, and provides idempotent, fail‑early behavior.
Workflow
- Collect data from CSV, SQLite, and JSON API
- Normalize rows to {date, metric, value, source}
- Group by week and compute deltas
- Render Markdown and HTML summary
- Write idempotent marker and exit with non‑zero on failure
Evidence
Every Friday I used to lose two hours copy-pasting numbers into a report. Now it runs itself in about 6 seconds.
A field changed name upstream and the whole chain silently produced garbage.
If it runs twice, nothing double-counts. When automation runs unattended, "safe to run again" matters more than "fast."
- Record date: 2026-10-11T11:56:09.324Z