Commit Graph

6 Commits

Author SHA1 Message Date
James 25343c9b7e IMAP idle and parser improvements 2026-02-04 22:57:30 -05:00
James b133ac7a8a feat: add sort param to messages endpoint, default desc (newest first) 2026-02-01 05:00:12 +00:00
James 36637c0d70 Simplify: remove L1/L2/L3 triage, webhook to main session
All intelligence now lives in OpenClaw (James). Mail Agent is just:
- IMAP API (list/read/move/delete)
- IMAP IDLE monitoring
- Webhook POST to /hooks/mail

Removed:
- L1 Fireworks llama triage
- L2/L3 escalation logic
- Hardcoded shipping detection
- Rule-based routing
- All AI logic

974 lines deleted, complexity moved to the right place.
2026-01-31 12:18:04 +00:00
James 7994c4b4a7 chore: remove __pycache__ from tracking 2026-01-31 09:01:22 +00:00
James d62b62bb89 fix: handle imapclient named tuple format for ENVELOPE and Address
- parse_envelope now handles Envelope named tuple (imapclient format)
- parse_address now handles Address named tuple
- date field preserved as datetime object, not stringified
- Add .venv and __pycache__ to .gitignore
2026-01-31 09:00:36 +00:00
James 5d9e58f5ae Initial mail-agent implementation
Full IMAP-based email triage system with multi-tier escalation.

Components:
- IMAP client with IDLE push notifications
- Email parsing with RFC 2047 header decoding
- FastAPI REST API (accounts, messages, SSE events)
- Triage pipeline (L1/L2/L3) with configurable rules
- Shipping dashboard integration
- Unsubscribe link detection

Pre-configured for Proton Bridge (tj@jongsma.me).
2026-01-31 01:09:00 +00:00