Skip to main content

Monthly analytics digest

· INTERNAL · integration · The Contentment Foundation

One scheduled function that reads five analytics and marketing tools and posts a single summary to Slack, replacing a five-dashboard login routine with a thirty-second read.

Problem

The team wanted to know how the site was doing. Answering that meant logging into five separate tools, each with its own login, its own interface and its own way of framing the same question. Nobody on the non-technical side had one place to look, so most months the numbers simply were not checked.

Intervention

A single serverless function queries all five sources in parallel, normalises them into one shape, and posts a Slack message grouped into four scannable sections: traffic, search, sign-ups, and site health. Each section leads with the number that matters, set as label above value rather than prose, so it reads as a glance rather than a report. Google service-account auth is one signed JWT built with the runtime's own crypto, so a function that runs twelve times a year pulls in no SDK. Every source is fetched independently and wrapped, so one API having a bad day renders as a single honest line rather than throwing away the whole report: a monthly job that fails silently is not noticed for a month. The schedule lives in versioned config, so the pause switch is an environment variable that redeploying cannot quietly undo.

Result

Stack: Node, Vercel Functions, Google Analytics 4, Search Console, PostHog, Sentry, Flodesk, Slack Block Kit