Exchange Web Service icon

Exchange Web Service

Exchange Web Service API

Actions4

Item → Find

AI-generated

Overview

The Exchange Web Service (EWS) - Item: Find node allows you to search for items (such as emails, calendar events, contacts, etc.) within a specified folder of an Exchange mailbox using Advanced Query Syntax (AQS). This is particularly useful for automating workflows that require filtering or retrieving specific items from Exchange Online or on-premises Exchange servers.

Common scenarios:

  • Searching for emails in the Inbox matching certain criteria (e.g., from a specific sender).
  • Retrieving upcoming calendar events.
  • Finding contacts with specific attributes.
  • Automating data extraction and processing from Exchange folders.

Practical example:
You could use this node to find all unread emails in the "Inbox" folder and then process them further in your workflow (e.g., send notifications, archive, or extract attachments).


Properties

Name Type Meaning
Authentication options The method used to authenticate with the Exchange service. Only "NTLM" is supported here.
Search Query (Advanced Query Syntax (AQS)) string The query string using AQS to filter items (e.g., from:someone@example.com). Required.
Well Known Folder options The target folder to search in (e.g., Inbox, Calendar, SentItems, etc.). Required.
Item Count number The maximum number of items to return from the search. Required.

Output

The node outputs a JSON array where each element represents an item found in the specified folder matching the search query. Each output object typically contains fields relevant to the type of item (email, event, contact, etc.), such as:

{
  "Subject": "Sample Email",
  "Sender": "user@example.com",
  "ReceivedTime": "2024-06-01T10:00:00Z",
  "Body": "...",
  // ...other Exchange item properties
}
  • If an error occurs and "Continue On Fail" is enabled, the output will include an error field with the error message for the failed item.

Dependencies

  • External Services: Requires access to a Microsoft Exchange server (Online or on-premises) with EWS enabled.
  • API Key / Credentials: Needs valid NTLM credentials configured in n8n under the "ewsApi" credential type.
  • n8n Configuration: The node must be properly configured with the correct authentication method and credentials.

Troubleshooting

Common issues:

  • Authentication errors:
    • Error message: Settings are not valid or authentification failed: ...
      Resolution: Check that your NTLM credentials are correct and have sufficient permissions.
  • No authentication method found:
    • Error message: No authentification method found
      Resolution: Ensure the "Authentication" property is set to "NTLM".
  • Empty results:
    • Possible causes: Incorrect search query syntax, wrong folder selected, or no matching items.
      Resolution: Double-check your AQS query and folder selection.

Links and References

Discussion