Microsoft 365 mail via Microsoft Graph app-only (zero per-mailbox setup)

FeatureEmailService
Shipped
July 13, 2026 at 10:03 PM UTC
Author
Kamo
Commit
b73dd49

Microsoft 365 mail now reads/sends through Microsoft Graph app-only (Mail.ReadWrite/Mail.Send application permissions) instead of IMAP — one app credential covers all current and future mailboxes tenant-wide, so adding a mailbox in Kamo just works: no New-ServicePrincipal, no per-mailbox grants. - GraphMailProvider (new): Graph **************** send/draft/search, adapting opaque Graph ids to the existing numeric-uid contract via GraphMessageIdService. Folders normalized to INBOX/Sent/Drafts/ Junk/Trash/Archive via locale-independent well-known-folder id resolution. Attachment $select uses the fileAttachment type-cast for contentId. - GraphMessageIdService (new): stable 52-bit synthetic uid; race-safe ON CONFLICT upsert. - Microsoft365Provider: extends GraphMailProvider; mail uses an app-only Graph token (tenant from the mailbox domain, creds from the platform OAuth registry); admin ops keep the delegated token. - ProviderHttpClient: URI-typed overloads (no RestTemplate re-encoding) + binary getBytes. - MailProviderResolver: MICROSOFT_365 no longer builds IMAP creds (Graph self- authenticates); removed now-dead platform-resolver wiring. KamoMail and the other IMAP providers (Exchange/Google/Zoho/IceWarp), the controller, metadata, and the frontend are all unchanged (numeric-uid contract preserved). Needs the new shared-lib table (KI run) and Graph Mail.ReadWrite + Mail.Send application permissions + admin consent on the M365 tenant.

All changes

Like what you see shipping?

Every one of these updates lands in your workspace automatically. Start free and watch it grow week after week.

Start Free ForeverView Pricing