This commit is contained in:
2026-01-03 05:21:55 +05:30
parent 278f0a3d40
commit 412a9c7bec
22 changed files with 950 additions and 0 deletions

View File

@@ -0,0 +1,26 @@
from dataclasses import dataclass
from datetime import datetime
from typing import Optional, Dict
@dataclass(frozen=True)
class MailIntakeMessage:
"""
Canonical internal representation of a single email message.
This model is provider-agnostic and safe to persist.
No Gmail-specific fields should appear here.
"""
message_id: str
thread_id: str
timestamp: datetime
from_email: str
from_name: Optional[str]
subject: str
body_text: str
snippet: str
raw_headers: Dict[str, str]