How to Give Your AI Agent Access to Your Mac Apps Safely
You want your AI agent to read your emails, check your calendar, and write notes — but you don't want to upload your entire personal data to a cloud provider. There's a way to have both.
The answer: a local MCP server that exposes your Mac apps through the Model Context Protocol, with the agent calling it from outside your machine via a secure tunnel.
The Architecture in 30 Seconds
- A small MCP server runs on your Mac (port 3939)
- It exposes tools like
mail_read_inbox,notes_create,calendar_today - A Cloudflare tunnel gives it a public HTTPS URL
- Your AI agent in the cloud calls the tunnel URL, which forwards to localhost
- The MCP server talks to your apps and returns results
Your data never leaves your Mac. The cloud agent just gets the answers.
Why Not Just Upload Your Emails?
The "easy" way is to OAuth into Gmail or Outlook with the cloud provider, give them a long-lived token, and let them read your inbox directly. Most AI products do this. It works. It's also a privacy nightmare:
- The provider has read access to your entire mailbox
- Your tokens live in their database
- A breach of the provider exposes your emails
- Your messages may end up in their training data
Local-first inverts this. The cloud never sees your messages — only the specific summaries the agent extracts in response to your specific requests.
How Noomachy Does It
Noomachy ships with a desktop app (Electron-based) that bundles:
- A local MCP server with 19+ macOS tools
- An auto-started Cloudflare quick tunnel
- Auto-registration so the cloud agent picks it up automatically
When you launch the desktop app, the tunnel comes online and your agent gains access to:
- Mail — read inbox, search, send (via direct SQLite access, no AppleScript prompts)
- Notes — list, read, create, update, delete, search, lock
- Calendar — read events, create new ones
- Reminders — list, create with due dates
- Files — read, write, list (sandboxed to your Documents)
- Clipboard — read, write
- Browser — open URLs
- System — info, notifications, command execution
All from inside the chat. No copy/paste.
The Permissions Model
macOS has three layers of automation permission:
- Files — Documents folder, etc. Granted on first prompt.
- App automation — for AppleScript-based access (Notes, Calendar, Reminders).
- Full Disk Access — required for some Mail integrations.
For Mail specifically, Noomachy uses a different approach: it reads Mail's SQLite envelope index directly (~/Library/Mail/V10/MailData/Envelope Index). This gives instant, permission-free access for reading. Sending still uses AppleScript and triggers the standard prompt.
The Tunnel Question
Cloudflare quick tunnels give you a free, no-account public URL. The downside: the URL rotates and the connection is best-effort.
For more robust deployments you can:
- Use a named Cloudflare tunnel (free with a Cloudflare account)
- Use ngrok with a static subdomain
- Self-host with a reverse proxy
- Run the agent locally too and skip the tunnel entirely
Noomachy handles tunnel rotation automatically — when the URL changes, it updates the registered MCP endpoint in your account.
Try It
Download Noomachy desktop and your local Mac apps become available to the agent within seconds.
Ready to try Noomachy?
Build AI agents with sovereign memory in minutes. Free tier, no credit card.
Get Started FreeRelated posts
A Beginner's Guide to AI Agent Skills and Custom Tools
Skills extend what your agent can do. Learn what they are, how they work, and how to create your own with the Model Context Protocol.
Connecting AI Agents to Telegram, Discord, and Slack
Your agent should not be locked inside a web app. Multi-channel deployment lets it follow you across platforms with shared memory.
The Best Slash Commands for AI Productivity
Slash commands turn complex AI workflows into one-keystroke shortcuts. Here are the best ones for daily productivity.