find_newsletters
Scans an Outlook folder for bulk mail carrying List-Unsubscribe headers and reports how each sender can be unsubscribed, grouped by sender with read/unread counts.
Instructions
Scan a folder for bulk mail (messages carrying a List-Unsubscribe header) and report how each sender can be unsubscribed.
Grouped by sender by default, because unsubscribing is per sender while the underlying listing is per message — the ungrouped form makes the model dedupe 200 rows by hand to reach the ~50 decisions that actually exist. Each row carries read/unread counts so a sender can be judged on engagement rather than on what its name suggests.
IMPORTANT: the List-Unsubscribe header marks a bulk sender, not junk. Order confirmations, delivery updates, statements and voucher codes all carry it. Treat this as a list of candidates to show the user, never as a list to sweep.
Returns {checked, headers_ok, header_fetch_failed, newsletter_messages, senders: [...]}. The header counts are there so a discrepancy between this and bulk_by_query(only_newsletters=True) is visible rather than mysterious: header sub-requests that fail are silently dropped from the scan.
Args: folder: folder id or well-known name. max_check: how many recent messages to scan. group_by_sender: set False for the raw per-message rows.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| folder | No | inbox | |
| max_check | No | ||
| group_by_sender | No |