docs(email): record message detail evidence
CI and Deploy / test (pull_request) Failing after 1m33s
CI and Deploy / deploy (pull_request) Has been skipped

This commit is contained in:
cesnimda
2026-08-09 21:47:27 +02:00
parent a20775c24a
commit 3a7e4f1088
7 changed files with 40 additions and 19 deletions
+10
View File
@@ -389,3 +389,13 @@
- **Consequences:** the hub can truthfully identify connected Gmail/Outlook/IMAP accounts and a shared API exists for later UI composition. Provider-native state changes and send remain unavailable and must be introduced with capability flags, re-consent and delivery-state tests. Message detail returns plain text only.
- **User approval required:** No; this is a local, fake-tested repository increment within MAIL-001 and invokes no provider or email service.
- **Reversible:** Yes. Revert `536d403`; no schema, dependency, OAuth scope, provider token or persisted message changes.
## DEC-040 — Message detail is plain text with an explicit saved-copy fallback
- **Date:** 2026-08-09
- **Decision:** Fetch live detail through the neutral provider endpoint when a row has a provider/message ID, but render only plain text. If provider access fails, warn and fetch the tenant-scoped persisted correspondence copy. Manual entries use the persisted path directly.
- **Reason/evidence:** imported correspondence remains useful after token expiry or provider outage, while returning/rendering provider HTML would widen the untrusted-content surface. The existing correspondence row is already the local job record and needs no duplicate store.
- **Alternatives considered:** render provider HTML; fail the whole view when reauthorization is required; silently fall back; include full message bodies in every inbox list response; add a message-cache table. These increase XSS/payload/state risk, hide stale provenance or duplicate existing data.
- **Consequences:** users can distinguish live and saved content availability, malformed legacy metadata cannot break detail, and late responses cannot populate another selected row. The saved copy may be stale and is labeled as such when live access fails.
- **User approval required:** No; this is local read-only behavior with synthetic/mocked tests and no provider invocation.
- **Reversible:** Yes. Revert `a20775c`; no schema, dependency, provider scope or persisted data changes.