Give goose an email inbox as an MCP extension
Add a streamable_http extension to goose's config.yaml with the URI https://api.trotta.email/mcp, an Authorization header and TROTTA_MAIL_API_KEY listed in env_keys. goose runs autonomously by default, so switch to approve mode, or load only the read and draft tools, before it handles mail.
Updated
Add the extension in config.yaml
You need a key. If you have none, sign the agent up and export the api_key as TROTTA_MAIL_API_KEY.
curl -X POST https://api.trotta.email/ v1/ agents/ signup \
-H "Content-Type: application/ json" \
-d '{"display_name": "Riley"}'Then merge this into ~/.config/goose/config.yaml. On Windows the file is %APPDATA%\Block\goose\config\config.yaml.
extensions:
trotta:
type: streamable_http
name: trotta
enabled: true
uri: https://api.trotta.email/ mcp
env_keys:
- TROTTA_MAIL_API_KEY
headers:
Authorization: "Bearer ${TROTTA_MAIL_API_KEY}"
timeout: 300env_keys is the line to get right. goose fills ${TROTTA_MAIL_API_KEY} only from names listed there or under envs. It looks in your environment, then in its secret store. A name it does not find is sent as written.
Or add it with goose configure
- Run
goose configureand choose Add Extension. - Choose Remote Extension (Streamable HTTP) and name it
trotta. - Enter
https://api.trotta.email/mcp, then a timeout and a description. - Add a custom header:
Authorization, with the valueBearerfollowed by your key.
This path writes the key into the config as typed. You can also skip the key: leave env_keys and headers out, and goose opens a browser sign-in when the server asks for one.
Will goose send email without asking?
Yes, by default. goose starts in Autonomous mode and uses extensions without approval. Change that before it touches mail.
| Mode | GOOSE_MODE | With this inbox |
|---|---|---|
| Autonomous (default) | auto | Sends without asking |
| Smart Approval | smart_approve | Asks for what it judges to be a write |
| Manual Approval | approve | Asks before every tool call |
Set GOOSE_MODE: "approve" in config.yaml, or type /mode approve in a session. Smart Approval leaves the read or write call to the model, so it is the weaker choice for mail.
Load only the tools the job needs
available_tools limits what goose loads from an extension. Added to the entry above, this list lets goose read and draft, with no way to send:
available_tools:
- list_inboxes
- get_inbox_updates
- wait_for_message
- read_message
- thread_context
- create_draftIt also saves room: goose's docs advise fewer than 25 enabled tools across all extensions, and the full inbox is 15 of them.
What goose reads from the inbox
- Delivered mail in the safe view: hidden text removed, instructions aimed at a model marked, risky links defanged.
- Held mail as a reason with no content. A human releases it.
- Verification codes in its own inbox, by
wait_for_messagewithhas_code.
No filter catches everything, and goose can run commands on your computer. See agent hijacking. Before a human claims the agent it only replies, up to 50 sends a day, and writes to its own organization's inboxes. There is no IMAP or SMTP.
These steps follow the goose docs and source code at version 1.61.1, checked on 2026-12-03.
Questions
Does goose support a remote MCP server with a bearer header?
Yes. Use a streamable_http extension with a headers map. goose no longer supports SSE.
Why did goose send the variable name instead of the key?
The name is missing from env_keys, or no value was found for it, so goose left the ${...} text as it was.
Can goose get an email address with no account?
Yes. The signup call returns an inbox and a key. A human claims the agent later so it can write to new addresses.
Can I add the server for one session only?
Yes, with goose session --with-streamable-http-extension "https://api.trotta.email/mcp", signing in through the browser when asked.