Nylas Swaps API Keys for 15-Minute Tokens in Its MCP Server
AI clients can now sign in to the Nylas MCP server with a Nylas account, pick up to five mailboxes and get tokens that expire in 15 minutes.

The Nylas MCP server now supports OAuth, so Claude Code, ChatGPT, Cursor and Codex CLI can connect to it by URL and sign in with a Nylas account instead of an API key, Nylas said in its Nov. 20 changelog. The access tokens last 15 minutes, and the client refreshes them until it is disconnected.
Five mailboxes and a permission choice
A sign-in reaches at most five connected accounts, which Nylas calls grants, according to the changelog. The client is pointed at https://mcp.us.nylas.com or https://mcp.eu.nylas.com with no Authorization header. On the first call it opens the Nylas Dashboard in a browser to pick an organization, choose the accounts and set access to Read only, Read and write or custom permissions.
The updated MCP server page, also dated Nov. 20, says custom permissions set email, calendar, contacts and meeting notes separately. A sign-in can’t grant more than the signer’s Dashboard role allows. Organization owners and admins can also attach an IAM principal, and the agent then gets only the access the sign-in and the principal have in common.
Each sign-in covers one organization and one data region, so a US sign-in sees only US grants, the docs say.
What a sign-in can’t do
The server has 38 tools for email, calendar, contacts and Notetaker, and a sign-in can use all of them except the five standalone Notetaker tools, which act on a whole application and still need an API key, according to the MCP server page. Sending mail takes two calls: confirm_send_message or confirm_send_draft generates a confirmation hash, and the send tool won’t run without it.
Disconnecting a client stops it from refreshing its token, so it loses access within 15 minutes. Changing a client’s accounts or access means signing in again.
API keys stay for hosted agents
Nylas said API keys still work and are the right choice for agents a backend runs for its users, for CI and for any agent with nobody present to sign in. For those, the docs recommend one IAM API key per user, bound to that user’s grant with only the permissions the agent needs. Nylas added cookbook guides for that setup, for a read-only key that can’t send or delete, and for rotating an agent’s key after a leak.
Key takeaways
- The Nylas MCP server accepts OAuth sign-in from Claude Code, ChatGPT, Cursor, Codex CLI and other MCP clients.
- A sign-in covers up to five grants in one organization and region.
- Access tokens expire after 15 minutes and refresh until the client is disconnected.
- The five standalone Notetaker tools still require an API key.
The take
We think this is the right default for a person working with their own mailbox. An API key is a standing secret. It sits in a config file, often for months, and anyone who copies the file holds the access. A 15-minute token that the client must keep refreshing expires on its own once you disconnect, so a leaked config is worth much less.
The five-account limit matters as much as the token length. An API key bound to a whole application reaches every mailbox a company has connected. A sign-in reaches the handful you picked, at the access level you picked. That is least privilege, meaning the agent gets only what the task needs.
Teams should not read this as a reason to drop keys for hosted agents. Nylas says a backend agent with no person present still needs a key, and the safe version is one narrow IAM key per user. Our advice: if anyone on your team has a broad Nylas key pasted into a local MCP config, swap it for a sign-in this week and revoke the key.


