MCP vs SDK vs API for AI agent email
Should an AI agent get email through an MCP server, an SDK, the REST API or a CLI, and what does each cost?
The short answer
Use MCP when a model in somebody else's client, such as Claude Code, Cursor or ChatGPT, should decide when to read and send. Use an SDK when your own code runs the loop and calls the model, the REST API when you want no dependency or another language, and the CLI when the agent has a shell. With Zurchin all four are the same API underneath, so the same task meets the same keys, limits and refusals whichever way in you choose.
The task
Every section below is about the same small job: wait for the next email at the agent's address, then reply to it. Two calls, and both are the ones an email agent makes most.
MCP: the model holds the tools
Add the hosted server to your client. The first call sends you to Zurchin to sign in and choose what the agent can do:
claude mcp add --transport http zurchin https://zurchin.com/mcp
From then on the model makes the calls. Asked to answer the next email, it waits for a message, then replies to it by the id it got back.
Choose it when the agent already lives in an MCP client, or when you want the model to decide which of many actions to take. Two things come with it that you would otherwise write. Message bodies arrive as the Firewall's clean text unless the model asks for the original. And a reply takes only the message and the words: the recipients, the subject and the threading headers are read off the original.
The cost is control. The model chooses the calls, so the key is the access control: give it the narrowest one the job needs. A key created at read cannot send, however the prompt is phrased. Every tool description also takes room in the model's context.
Agent frameworks that speak MCP, such as the Claude Agent SDK, the OpenAI Agents SDK and the Vercel AI SDK, reach the same hosted server.
The SDK: your code runs the loop
Your code waits for the message, asks the model for the words, and sends the reply.
Choose it when your program decides what happens and calls the model for the words. The calls are typed, in TypeScript (@zurchin/sdk) and Python (zurchin), and the packages also check the signature on incoming webhooks.
The cost is that you write what MCP gives you: choosing the cleaned text over the original, and guarding against your own loop sending a reply twice.
The REST API: no dependency
Two HTTP requests with an API key: one that waits for the message, and one that sends the reply.
Choose it when you work in a language without an SDK, in a workflow tool that makes HTTP requests, or when you want to see every byte. For a server, a webhook on message.received replaces the wait.
The cost is the plumbing: retries, signatures and timeouts are yours. A long wait also needs an HTTP client that allows it.
The CLI: an agent with a shell
Two commands, one that waits and one that replies, each printing JSON.
Choose it when the agent is a coding agent that already runs commands, in a script, or in CI. The output is the API's JSON on stdout, so jq works, and a refusal exits with an error and the API's sentence on stderr.
The cost: a command is a process, so it is slower than a call from inside a program, and a script that runs twice sends twice.
Choosing
| You have | Use |
|---|---|
| A model in Claude Code, Cursor, ChatGPT or Codex | MCP |
| Your own TypeScript or Python agent loop | The SDK |
| Another language, or a workflow tool | The REST API |
| An agent or script with a terminal | The CLI |
They mix. A common shape is a webhook into your own code with the SDK, and MCP for a person asking Claude about the same inbox. All four use the same API keys, so the key decides what each can reach.
Start
Sign up and create an address. Zurchin Email has the one line that adds the MCP server to Claude Code, Codex or Cursor.
Questions
When should an agent use MCP for email?
When the agent is a model in an MCP client such as Claude Code, Cursor or ChatGPT and should choose the calls itself. The key it holds is the access control, so make it the narrowest the job needs.
Do the MCP server and the SDKs expose the same operations?
Nearly. Each MCP tool is one API call (a few, such as reply_to_message, are two), with the same access and the same refusals, and a few are left out on purpose: there is no forward_message, because passing text on to someone outside its conversation is what canary tokens refuse. The SDKs group the calls by product, and anything else goes through their request call.