Ir al contenido principal
Petanque Life

Notification System

F09.02 12 funcionalidades Plataforma+

En resumen

The Notification System is a unified hub that delivers transactional email, SMS, and push messages from every Petanque Life feature. Mustache templates resolve per tenant, channel, locale, and event so any federation can override defaults without code. Dispatch is idempotent on the booking, event, and channel tuple, every recipient controls channels, frequency, and quiet hours, and a per-user delivery log keeps support staff honest.

Cómo funciona

When any part of the platform — bookings, draws, license renewals, ranking jobs — needs to reach a user, it raises a notification event rather than calling an email or SMS API directly. The hub picks the right channel mix (Email notifications via ACS/SendGrid, SMS notifications via ACS/46elks, Push notifications via FCM) based on the event type and the user's notification preferences, including chosen channels, frequency caps, and quiet hours.

Template resolution walks a four-key lookup: tenant, channel, locale, event. A custom template at the federation layer wins; otherwise the platform default applies. Notification templates are Mustache-rendered, so editors can drop in {{player.name}}, {{match.startsAt}}, or {{competition.title}} without touching code, and previews render against sample data before going live. Each tenant maintains its own template library per language, satisfying the multi-language obligation across 43+ FIPJP locales.

Dispatch is idempotent on the tuple (booking or event id, channel, recipient): if a worker retries, the recipient does not get duplicates. Every send is written to the notification delivery log with status (queued, sent, delivered, bounced, opened where allowed), so support staff can audit a single user's history end-to-end. Competition-specific notifications fire on draw published, next match imminent, and final results; license renewal reminders ramp up at T-60, T-30, T-7, and T-0 days; ranking change notifications fire after the periodic recompute when a player crosses a configured threshold.

For mass communication the same engine powers federation circular distribution — bulk sends to filtered member segments — with per-channel opt-out and unsubscribe links injected automatically. The hub respects the shared suppression list with the newsletter engine, so a hard bounce or complaint anywhere in the platform protects the user across both transactional and marketing flows.

Capacidades clave

  • Unified email, SMS, and push delivery via ACS, 46elks, and FCM
  • Mustache templates with custom-over-default resolution per tenant, channel, locale, event
  • Per-user notification preferences for channels, frequency, and quiet hours
  • Idempotent dispatch keyed on event, channel, and recipient
  • Built-in event types for competitions, license renewals, and ranking changes
  • Federation circular bulk distribution with opt-out and unsubscribe links
  • Full delivery log per user for auditing and support

En la práctica

A licensed player in Bordeaux finishes registration for a regional doubles tournament. The competition module raises a registration-confirmed event; the hub looks up the French-language email template for that event in the FFPJP tenant, renders the player's name and bracket details, and sends it via ACS Email. Two days before the event, the draw is published — the hub fires a draw-published push to her phone (her preferred channel for in-event updates) at 09:30, respecting her 22:00–08:00 quiet hours.

On match day she receives an SMS five minutes before her court is called. Every message is recorded in her delivery log, viewable in her account.

Funcionalidades de este subsistema

12
ID Status Funcionalidades
F09.02.01 Entregado Email notifications (SendGrid) ✅ PL-F0902a
F09.02.02 Entregado SMS notifications (46elks) ✅ PL-F0902a
F09.02.03 Entregado Push notifications (FCM) ✅ PL-F0902a
F09.02.04 Entregado Notification templates (customizable per federation, per language) ✅ PL-F0902a
F09.02.05 Entregado Notification preferences per user (channels, frequency, quiet hours) ✅ PL-F0902a
F09.02.06 Entregado Competition-specific notifications (draw published, next match, results) ✅ PL-F0902b
F09.02.07 Entregado License renewal reminders (notification type) ✅ PL-F0902b
F09.02.08 Entregado Ranking change notifications (notification type) ✅ PL-F0902b
F09.02.09 Entregado Federation circular distribution (bulk send) ✅ PL-F0902b
F09.02.10 Entregado Notification delivery log (history per user) ✅ PL-F0902b
F09.02.11 Entregado Engagement attribution capture — EngagementAttribution-events (email_opened/clicked/bounced, webinar_attended, resource_downloaded, signup) konsumeras från notification-pipen och webinar/resource-event-bus — PL-T223 ✅ PL-T223
F09.02.12 Entregado Engagement snapshot builder — idempotent aggregat per (federation_id, club_id, period_type, period_start) med viktad engagement_score 0–100 — PL-T223 ✅ PL-T223