Count Messages
mailbox_count_messagesCount messages in a mailbox using filters like sender, subject, or date range without retrieving full results.
Instructions
Use this to count messages matching mailbox filters without listing every result. Follow with mailbox_list_messages only when examples are needed.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| q | No | Full-text search query across message fields. | |
| cc | No | Filter by CC recipient email address or display name. | |
| to | No | Filter by To recipient email address or display name. | |
| bcc | No | Filter by BCC recipient email address or display name. | |
| body | No | Filter by message body text. | |
| from | No | Filter by sender email address or display name. | |
| after | No | Filter to messages after this ISO 8601 timestamp. | |
| before | No | Filter to messages before this ISO 8601 timestamp. | |
| keyword | No | Require this message keyword, such as `$seen`. | |
| subject | No | Filter by subject text. | |
| folder_id | No | Filter to messages in this folder ID. | |
| is_unread | No | When true, only return unread messages. | |
| thread_id | No | Filter to messages in this thread ID. | |
| mailbox_id | No | Mailbox public ID to target when the credential grants access to more than one mailbox. Omit when the credential is scoped to exactly one mailbox. | |
| header_name | No | Header name to match with `header_value`. | |
| not_keyword | No | Exclude messages with this keyword. | |
| header_value | No | Header value to match with `header_name`. | |
| has_attachment | No | When true, only return messages with attachments. | |
| max_size_bytes | No | Maximum message size in bytes. | |
| min_size_bytes | No | Minimum message size in bytes. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||