outlook.onNewEmail handles messages created in the connected account’s Inbox.
Example
automations/process-outlook-mail.automation.ts
Options
Optional staticaccount: string | IntegrationAccountReference<"microsoft"> selects the mailbox and defaults to the project binding. The mailbox can’t change at runtime.
Trigger data
ReturnsSignal<OutlookMessage> with messageId, subject, body, preview, recipients, sender, timestamps, conversation and folder IDs, read/draft and attachment state, categories, importance, flag, Focused Inbox classification, web link, and ETag where Microsoft supplies them. Recipient arrays and categories default to []. Subject defaults to an empty string.
The trigger watches message creation in Inbox. It reports hasAttachments but doesn’t embed attachment data. Call outlook.listAttachments with messageId to read attachments.