Skip to main content

Part 5 โ€” Notification content & channels

How a matched digest becomes an actual message per channel. Email carries the full designed cards; SMS and WhatsApp carry a capped summary + the See-all link. WhatsApp additionally requires a pre-approved WABA template.

Email โ€” newsletter-style cardsโ€‹

The email mirrors the design-system NewsletterCard structure: per event โ€” image ยท title ยท ๐Ÿ“… date ๐Ÿ• time ๐Ÿท๏ธ tags ยท ๐Ÿ“ location ยท leader. It shows up to 3 cards + a "See all events" link, with a BeWith header bar and footer; each card links to the event itself. Composed in apps/notifications/src/notify-digest/notify-digest.composer.ts.

SMSโ€‹

Plain text, capped to a few event titles + the See-all link (SMS is billed per 160-char segment, so the list must be bounded).

WhatsApp โ€” requires a WABA templateโ€‹

WhatsApp cannot send free-form designed cards; it needs a pre-approved WABA template: positional variables ({{1}}, {{2}}), no HTML, footer โ‰ค 60 chars, create โ†’ PENDING โ†’ webhook โ†’ APPROVED. A variable-length card list is not expressible โ€” the WA message is a summary + See-all link/button. This is why WhatsApp is deferred until the template phase.

The bespoke composer works for email/SMS, but the platform already has a template mechanism (notification_template + per-platform content, WABA submission, managed in the internal support-tool). The recommendation:

  • Build the digest templates behind the scenes, editable in the support-tool (the existing internal manager) โ€” not in the customer area. Same multi-language edit mechanism as Part 1.
  • A digest notification_config + default EMAIL / SMS / WHATSAPP templates, whose body holds the frame + an event-list placeholder (a new macro โ€” the macro registry has no event-list macro today) + a see_all_url macro.
  • Dispatch passes templateId (instead of a raw body) so it rides the pipeline correctly (the macro engine strips unknown {...}, so raw card HTML with braces is unsafe) and so WhatsApp can use its approved template.
  • Filter the digest templates out of the customer-facing notifications/templates list; the customer must not see or edit them.

Acceptance criteriaโ€‹

  • The email renders the card structure (image/date/time/tags/location/leader) with 3 events + See-all, header + footer.
  • SMS stays within a bounded segment count.
  • WhatsApp sends only via an approved WABA template; before approval, WA is not attempted.

Open questionsโ€‹

  • Who authors/approves the WABA template, and the approval lead time.
  • The exact shape of the event-list macro and whether customers may ever edit the template structure.