list-mail-messages
list-mail-messagesFind specific messages in a Microsoft 365 mailbox by applying full-text KQL search, OData filters, and time ranges—so you can locate emails by sender, recipient, subject, attachment, or importance.
Instructions
List/search messages in the signed-in user's mailbox. Supports full-text KQL search (sender, recipient, cc, subject, keyword, attachment, read/unread, importance) and time ranges.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| to | No | End of explicit time range (ISO date or datetime) | |
| from | No | Start of explicit time range (ISO date or datetime, overrides timeRange) | |
| cursor | No | Continuation token (nextCursor of a previous truncated response). Continues that listing; other query inputs are ignored. | |
| filter | No | OData $filter expression, e.g. "importance eq 'high'" or "hasAttachments eq true" | |
| search | No | Full-text search (KQL supported), e.g. 'from:kiss.peter@ceg.hu subject:"AI projekt" hasattachment:true' | |
| select | No | Comma separated list of properties to return (OData $select) | |
| orderby | No | OData $orderby, e.g. "receivedDateTime desc" | |
| maxItems | No | Maximum items to return across pages (default 50, max 500). Pagination via @odata.nextLink is handled automatically; when the result is truncated, pass its nextCursor as cursor to continue. | |
| timeRange | No | Named time range applied on receivedDateTime |