mail_find_correspondent
Find people you have emailed with by name, address, company, or domain. Get the address they actually use and message counts each way when contacts search fails.
Instructions
Find people the owner has exchanged email with by approximate name, address or company, with the address they really use and message counts each way.
Use when: contacts_search_contacts finds nobody, or you need the address a person actually writes from. Not for saved contacts (use contacts_search_contacts) or for messages from someone (use mail_search_messages with from_address). Parameters: every word of query must match a name, address part or domain; misspellings match as 'similar'. limit is clamped to 1-25. search_all_history=false scans the newest ~3,000 INBOX and ~1,500 Sent messages; true scans both whole. Behavior: read-only; reads only From, To and Cc headers in INBOX and Sent, never bodies or other folders. The scan is cached 10 minutes, so the newest mail may be missing. Exact matches rank first. Returns: {query, returned, matches, scanned}; each match has name, address, also_written_as, messages_from_them, messages_to_them, last_contact and match ('exact' or 'similar'). 'similar' means only similar in spelling or sound: ask the owner to confirm which person they meant before sending or inviting anyone. No match gives a hint: retry with search_all_history=true, or ask the owner. Errors: an empty query is refused.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| limit | No | Max people to return (1-25). | |
| query | Yes | Name, email address or company/domain of a person you have emailed with: 'laura', 'l.jansen', 'acme'. Misspellings are tolerated. | |
| search_all_history | No | false = the most recent ~3,000 received and ~1,500 sent messages (fast). true = the whole mailbox (slower, up to ~20 seconds). |