apple-mail-search

Search Apple Mail envelope metadata with SQLite and fetch message bodies via AppleScript.

17|5|Updated Jan 15, 2026
One-click install
npx skills add https://github.com/gumadeiras/fruitmail-cli --skill apple-mail-search-gumadeiras
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: apple-mail-search
Source: https://github.com/gumadeiras/fruitmail-cli/tree/main
Command: npx skills add https://github.com/gumadeiras/fruitmail-cli --skill apple-mail-search-gumadeiras

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes scripts (resource) components.

What problem does it solve?

Apple Mail on macOS can be slow to search and fetch full message bodies; this skill enables fast, SQLite-backed lookups with optional full body retrieval to speed up mail workflows.

Core Features & Use Cases

  • Fast metadata search across Apple Mail envelopes with subject/sender/date filters.
  • Full body retrieval on demand to view message content without opening Mail.app.
  • Use Case: Quickly locate important emails and extract their contents for reporting or archival.

Quick Start

Run a search for unread messages with fruitmail to locate messages quickly.

Frequently Asked Questions about apple-mail-search

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I search Apple Mail messages quickly using SQLite on macOS?

You can search Apple Mail messages quickly by performing a SQLite-backed read-only search over the Envelope Index, applying subject, sender, recipient, and date filters to locate specific emails without opening the Mail application.

Can I extract the full email body from Apple Mail without launching the app?

Yes, you can extract full email bodies on demand using AppleScript, allowing you to retrieve and read message content directly from the command line interface without needing to open or interact with the Mail.app graphical interface.

Does this SQLite mail search approach require copying the Envelope Index database first?

No, copying the Envelope Index database is not required as it defaults to a read-only access mode, but an optional copy mode is supported if you prefer to work on a duplicate database for additional safety.

How do I filter Apple Mail searches by sender and date range?

You can filter Apple Mail searches by sender and date range by passing specific metadata constraints to the CLI, which queries the SQLite Envelope Index and returns matching envelopes with pagination support for browsing results.

What is the best way to locate unread Apple Mail messages via the command line?

The best way to locate unread Apple Mail messages is to run a CLI search against the Envelope Index, filtering by read status to quickly return metadata for unread emails and optionally fetching their bodies using AppleScript.

Can I specify a custom database path for the Apple Mail Envelope Index?

Yes, the CLI interface allows you to target a specific database path, enabling you to point the SQLite search at a custom or copied Envelope Index file instead of using the default system location.