MCP server for email attachments: let AI agents read your downloads

MCP server for email attachments: let GitHub Copilot, Claude Code or any AI agent ask what was saved, what failed and what needs you. Read-only, local.

MCP server for email attachments: the AI agents window of Mail Attachment Downloader with Let AI agents on this computer ask what I've downloaded ticked, port 17820, a hidden token, What agents may see, and Copy VS Code setup, Copy Claude Code command, Copy Gemini CLI command and Copy address and token

Mail Attachment Downloader has a built-in MCP server for your email attachments. Switch on AI agents, and GitHub Copilot in Visual Studio Code, Claude Code, Gemini CLI or any other MCP agent on the same system can ask which files were saved, which downloads failed and which accounts need you. It only reads, it is off until you turn it on, it listens on your own system only, and an agent needs a token.

The examples use Contoso’s mailboxes finance@contoso.com and ap@contoso.com, invoices from Acme and Northwind, and the parser Supplier invoices.

What can you ask an AI agent about your email downloads?

MCP (Model Context Protocol) is the way AI agents call tools. With the server on, you ask in your own words and the agent picks the tool. For example:

  • “Which invoices from Acme were saved this week, and in which folder?”
  • “Did any downloads fail since Monday? Why?”
  • “Which accounts need me to sign in again?”
  • “How many files did each rule save in the last 7 days?”
  • “How is the Supplier invoices parser doing, and what is waiting for review?”

It saves you opening the program to look, and it lets an agent use the answer in the work it is doing, such as a report or a script that reads the saved files.

What you need

  • The edition: any PRO edition, from PRO Backup up. The Parser tools come with PRO Parser and up.
  • The program open: the server runs in Mail Attachment Downloader’s window, not in the Windows service. While the window is open it also reads what the service downloaded.
  • An agent: on the same system, one that speaks MCP over HTTP: GitHub Copilot in VS Code, Claude Code, Gemini CLI or another.

How to turn on the MCP server

  1. Open Settings › Sources › AI Agents (MCP server), pick AI agents (MCP) and click Edit….
  2. Tick Let AI agents on this computer ask what I’ve downloaded (MCP server).
  3. Keep the Port (17820) unless another program uses it. A Token is made for you; Show and Copy it, or New token… to replace it.
  4. Under What agents may see, choose what to share (below).
  5. Click OK. The server starts at once.
MCP server for email attachments: the AI agents window of Mail Attachment Downloader with Let AI agents on this computer ask what I've downloaded ticked, port 17820, a hidden token, What agents may see, and Copy VS Code setup, Copy Claude Code command, Copy Gemini CLI command and Copy address and token
The AI agents window: on, local, with a token, and you choose what agents see.

Connect GitHub Copilot, Claude Code or Gemini CLI

Under Connect an agent, one click copies what each agent needs:

  • GitHub Copilot in VS Code: Copy VS Code setup copies the server’s entry for VS Code’s mcp.json, with the address and the token. Paste it in, start the server in VS Code, and ask Copilot in agent mode.
  • Claude Code: Copy Claude Code command copies a claude mcp add command to run once in a terminal.
  • Gemini CLI: Copy Gemini CLI command copies the matching gemini mcp add command.
  • Any other MCP agent: Copy address and token. The address is http://127.0.0.1:17820/mcp, and the token goes in an Authorization: Bearer header.

What you copy holds the token: keep it to yourself, as you would a password.

What can an AI agent read?

Seven tools tell an agent about your downloads, from the same History the Downloads tab shows:

  • Status: the version and edition, whether a download is running, the accounts and the latest runs.
  • Accounts and runs: the accounts set up, and for each run who started it, how it ended, files saved and failed.
  • Search saved files: by words, account, rule, run or time, or only the problems.
  • Summary: counts for the last days, by account and by rule.
  • Needs action: accounts that can’t download until you fix something, such as an expired sign-in or a save folder that can’t be reached, with what to do.
  • Rules: what your rules do, in plain words: which emails, what they save, where, and the kinds of their steps.
AI agent read email downloads: the History of saved files in Mail Attachment Downloader, with invoices such as INV-2026-0412.pdf saved to D:\Finance\Invoices, their size, date processed, status Saved or Replaced, the rule and the run
What an agent searches: the saved files, where they went, and how each one ended.

With PRO Parser and up, six more tools cover the Parser: the parsers and their fields, one parser in detail, its health (how often each field was found), what waits for review, the latest results, and a test of a parser’s patterns on a text the agent gives.

The Results of the Supplier invoices parser in Mail Attachment Downloader: invoice number, supplier, due date and total read from emails from Acme, Northwind, Fabrikam and Contoso, each Done
The values a parser read: hidden from agents unless you allow them.

What agents may see, and what they never see

You decide under What agents may see, and a change counts at once:

  • Who sent each email, who it went to and its subject: off, they are neither shown nor searched.
  • The full path of each saved file (off: only its name).
  • What my rules do (their conditions, folders and kinds of actions): also needed for the Parser tools.
  • Let agents read the values the parsers read out of emails: off by default, as names, amounts and addresses can be personal data. Then at most 50 records at a time.

Never shared: the text of your emails, the files themselves, passwords, connection details, and where a rule or parser sends data. File names, times and the status of each download always are.

Keep in mind that what an agent reads goes to the AI model the agent uses, as any tool result does. Share only what you are happy for that model to see.

What it can’t do

The server only reads. No tool starts a download, changes a setting, touches a file, or approves or rejects an email waiting for review. An agent can’t make the program do anything; it can only ask. To run downloads on a timetable, use the Schedule tab.

The Mail Attachment Downloader main window with Connect and Download and the Downloads tab listing invoices and purchase orders from ap@contoso.example, each Saved 1 file
Downloads still start here or on the schedule: agents only look.

How the MCP server is protected

  • Local only: it listens on 127.0.0.1, so nothing on the network can reach it, and web pages in a browser can’t call it.
  • A token: a long random token, kept encrypted for your Windows user, never in the settings or the logs. New token… replaces it at once.
  • Careful with what agents send: an agent’s questions are treated as untrusted, and answers are limited in size.
  • Off means off: when it is off, nothing listens.

Microsoft Copilot Studio and Microsoft 365 Copilot

Copilot Studio agents and Microsoft 365 Copilot run in Microsoft’s cloud, so they can’t reach an address on your own system. To use one, you have to make the address reachable from the internet yourself, such as with a Microsoft dev tunnel or a reverse proxy you control, then add it in Copilot Studio as an MCP server with the token as its key. Think it over first: whoever has the token and can reach the address can read what you allowed. Using it with Microsoft 365 Copilot and Copilot Studio… in the window explains it.

Questions people ask

Can the agent start a download or change a rule?

No. It can only read. To change a rule with AI, use the AI Assistant in the program.

Can GitHub Copilot read my email?

Not the text of your emails or the files. It sees file names, times and statuses, and senders and subjects if you allow it.

Does it work in the free edition?

No. AI agents need a PRO edition, from PRO Backup up.

Does it work when the Windows service downloads?

Yes, while the program’s window is open: it reads the service’s History too. The service itself doesn’t run the MCP server.

Try it: download Mail Attachment Downloader and start with the free edition, or compare the PRO editions, each with a 30-day money-back guarantee.

Related

Questions about this post? Contact us.