feat(admin): track email delivery attempts

This commit is contained in:
Thomas Durieux committed 2026-11-14 12:51:32 +00:00
1 parent 104af7d261
commit 6400760fcb
24 files changed
+376 -44

No files matched your search

+9
View File
@@ -150,6 +150,15 @@ expiration date gets one delivery attempt across workers. Failed or ambiguous
deliveries retain the guard to prevent duplicate emails and are logged without
email addresses. Existing expired repositories are not scanned for notifications.
Administrators can inspect email attempts at `/admin/emails`, filtered by type
and provider outcome. Tracking covers new expiration and GitHub access emails;
older sends are not backfilled. History stores the recipient address, resource
identity, timestamps, and HTTP status in MongoDB, without message bodies or API
keys. Accepted means the provider accepted the message, not confirmed inbox
delivery. Unknown outcomes and interrupted sends remain visible for investigation.
Audit storage failures are logged and do not stop delivery, so history can be
incomplete during a database outage.
Registration saves a verified GitHub email address, preferring the primary address.
OAuth requests `user:email`; GitHub App sign-in uses the read-only email permission
described in the setup guide. Later sign-ins also fill missing addresses. Saved