{"url":"https://xstate.com/blog/agent-permissions","title":"What an AI app can do with your mail, and why send is off by default","summary":"How access works when you connect Claude, Codex, Cursor or ChatGPT to xstate, and what an app can never do.","date":"2026-11-16","updated":null,"author":"xstate","tags":["agents","mcp","security"],"minutes":3,"markdown":"https://xstate.com/blog/agent-permissions.md","content_markdown":"xstate runs an MCP server at `https://mcp.xstate.com/mcp`. Claude, Claude Code, Codex, Cursor, ChatGPT and any other\napp that speaks remote MCP with OAuth can connect to it and work with your mail, calendar, files and contacts.\n\nGiving an AI app your inbox is a real decision. This post explains what you choose when you connect one, what we\nchose for you, and why.\n\n## You approve every app\n\nThe first time an app connects, it sends you to xstate to sign in. Before you approve anything, xstate shows you:\n\n- **Which app is asking.** Apps that publish their details on their own domain (Claude, ChatGPT and Cursor do) show\n  that domain. Any other app shows only the name it gave, marked as unverified.\n- **Where access will be sent.** If that is a program on your own computer, you get a warning. Continue only if you\n  just started connecting from it.\n\n## You choose what it may do\n\n| Choice | Options | Starts on |\n| - | - | - |\n| Organization | Any you belong to | The first |\n| Mailboxes | Mailboxes you can read | Your own mailbox |\n| Email | Read only · Draft only · Draft and send | Draft only |\n| Calendar, Storage, Contacts | Off · Read · Read and change | Read |\n| Manage domains and mailboxes | Off or on, for owners and admins | Off |\n\nThe column that matters most is the last one. Every choice starts at the narrowest setting that is still useful.\n\n## Why sending starts off\n\nWith **Draft only**, an app can read your mail, write replies and save them to Drafts. You read the draft and press\nsend. The app cannot send anything until you choose **Draft and send**.\n\nWe made this the default because email is written by other people. A message in your inbox can contain text meant\nto talk an AI app into doing something you didn't ask for, such as forwarding an invoice or replying to someone on\nyour behalf. xstate tells connected apps to treat what they read as information, not instructions. But the safest\nanswer is that a draft hurts nobody until a person sends it.\n\nIf an app needs to send on its own, for example a support assistant that answers routine questions, turn sending on\nfor that app and only for the mailbox it needs.\n\n## An app never gets more than you have\n\nEvery call an app makes is checked twice: first against your own access, then against what you chose for that app.\nMailboxes you didn't pick are out of reach, including through search. If you lose access to a mailbox, every app you\nconnected loses it too.\n\nSome things are never available to a connected app, whatever you choose:\n\n- resetting passwords\n- giving people access to mailboxes\n- API keys, AI provider keys and other secrets\n- inviting or removing members\n- public file links\n\n## Taking access back\n\n**Settings → Connected apps** lists every app you connected, what it may do and when it was last active.\n**Disconnect** ends its access at once. Owners and admins see every app connected to the organization and can\ndisconnect any of them.\n\nConnections also end on their own 30 days after their last use, so an app you tried once and forgot doesn't keep\naccess forever. To change what an app may do, connect it again: the new choices replace the old ones.\n\nThe full list of tools and what each one needs is in [Connect AI apps](https://xstate.com/docs/mcp)."}