Files
worldmonitor/convex
Elie Habib e14dc5b103 feat(notifications): PRO entitlement check before delivery (#2899)
* feat(notifications): PRO entitlement check before delivery in relay/digest/proactive

All three notification delivery paths now verify the user has PRO tier
before sending. Uses a new /relay/entitlement Convex HTTP endpoint
(RELAY_SHARED_SECRET auth) with 15min Redis cache per user.

Fail-open design: if entitlement service is unreachable, delivery
proceeds (don't block paying users on a service hiccup). Cache shared
across relay, digest, and proactive scripts via relay:entitlement:{userId}.

Prevents downgraded users from continuing to receive notifications
after their subscription expires.

Requires Convex deploy for the new /relay/entitlement route.

* fix(notifications): show second delivery time for twice_daily digest mode

When user selects "Twice daily", show "Also sends at X PM/AM" hint below
the hour selector so they know when the second digest arrives.
Updates dynamically when hour or mode changes.
2026-04-10 15:34:52 +04:00
..