Outlook Email Webhook
Outlook Email Webhook starts a flow every time a new email arrives in a folder of your Outlook mailbox. It can also react when an email is deleted from that folder.
NappAI checks the folder every short while and, if it finds new emails, runs the flow with the details of each one. You don’t need to set anything up in Microsoft: the credential and a subscription for the flow are enough.
When to use it
- You want an AI agent to read every support email that arrives and suggest a reply.
- You need to save into your CRM or a spreadsheet the details of orders that arrive by email.
- You want to post an alert to Teams when an email from a key client arrives.
- You want to sort the emails that land in your inbox automatically.
Configuration
You need a Microsoft Outlook credential, which connects by signing in with your Microsoft account. See Credentials.
| Field | What it does |
|---|---|
| Credential (required) | The Microsoft Outlook credential of the mailbox you want to watch. |
| Events | The changes that start the flow: Message Received (a new email arrives) and Message Deleted (an email is removed from the folder). By default, Message Received. |
| Mail Folder | The folder being watched: Inbox, SentItems, Drafts, DeletedItems, Archive or JunkEmail. By default, Inbox. |
| Data | Test field. It lets you try the flow with a sample email without waiting for a real one. Leave it empty in normal use. |
Turning on the subscription
The flow only receives emails while it is subscribed:
- Save the flow and publish a version. A published version of the flow is required to subscribe. See Versions and publishing.
- In the node’s settings panel, click Subscribe.
- In the panel that opens, click Subscribe. The status changes to Synced.
If you later change the events or the folder, the status shows Out of sync: subscribe again to apply the changes. From the same panel you can Unsubscribe.
Output
The Data output contains one item for each email, with the type of change (received or deleted), the email and conversation identifiers, the sender (address and name), the recipients, the subject, an excerpt of the body, the date received, whether it has been read and whether it has attachments. If several emails arrive at once, they all come out together.
Connect it to an AI agent to read or classify the email, or to Email to read it in full, reply to it or move it to another folder.
Example
An online shop wants to answer the questions it receives by email faster.
- Add Outlook Email Webhook and choose the Microsoft Outlook credential of the customer service mailbox.
- Keep Events on
Message Receivedand Mail Folder onInbox. - Connect the Data output to an agent that drafts a reply from the email’s subject and excerpt.
- Connect the agent to Email with the
Reply Messageoperation, using the identifier of the received email. - Publish the flow and click Subscribe.
Good practices
- To read the full body or the attachments, use the email identifier with Email and the
Get Messageoperation: the webhook only brings an excerpt. - If the flow sends emails to the same account it watches, it may run again with its own messages. Filter by sender before replying.
Related components
- Email: read, send, reply to and organise Outlook emails.
- Outlook Calendar Webhook: start a flow when your calendar changes.