Test
Merged
SW
4mo ago+1+1+0123456789-599-599-012345678901234567890123456789
Summary by cubic
Replaced /api/notifications with a smarter /api/emails endpoint. You can now omit to and subject — we’ll fill them in for you.
-
New Features
tois optional. Defaults to the authenticated account’s email(s); 400 if none on file.subjectis optional. Derived from the first heading/line oftext(or strippedhtml), else "Message from Recoup".- Recipient restriction enforced during validation (limits
to/ccwithout a payment method). - Added
firstMeaningfulLine,stripHtml, andresolveEmailSubjectwith unit tests.
-
Migration
- Move calls from
/api/notificationsto/api/emails(old route removed). You can omittoto “email me this,” and omitsubjectto auto-derive it.
- Move calls from