mail_search_messages
Search Microsoft 365 mailbox messages by subject, keyword, sender, recipient, or date range using safe Graph queries and filters.
Instructions
Search messages safely. Prefer subject for a known title; query is full-text and may match message bodies.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| mode | No | auto selects safe KQL search for text and safe OData filter for structured-only criteria. | auto |
| query | No | Quoted full-text phrase that may match subject, body, or indexed message content. Use subject instead when the subject is known. | |
| cursor | No | Opaque signed cursor returned by a previous call. | |
| sentUtc | No | Inclusive UTC sent-time bounds. | |
| subject | No | One or more subject phrases. Prefer this over query when locating a known email title. | |
| bodyMode | No | Message content to return: none omits body and preview, preview returns bodyPreview, and text/html returns body in the requested format. | preview |
| pageSize | No | Microsoft Graph page size. | |
| folderIds | No | Optional Graph folder IDs that bound the search. | |
| maxResults | No | Maximum messages returned across fetched pages. | |
| receivedUtc | No | Inclusive UTC received-time bounds. | |
| mailboxScope | No | ||
| participants | No | Sender or recipient email-address filters. | |
| conversationId | No | Mailbox-local conversation ID, normally used internally for thread reconstruction. | |
| hasAttachments | No | Filter by Graph hasAttachments state. |