Guide
manus-mcp-cli: Set Up Email and Calendar MCP Servers for Manus AI
manus-mcp-cli is the built-in command-line tool inside the Manus AI sandbox for managing MCP server connections. This guide walks through registering the Nylas CLI as an MCP server, configuring email providers like Gmail, Outlook, Exchange, Yahoo, iCloud, and IMAP, sending email, managing calendar events, and troubleshooting common issues.
By Pouya Sanooei
What is manus-mcp-cli?
manus-mcp-cli is the command-line interface built into the Manus AI sandbox for managing Model Context Protocol (MCP) server connections. MCP is a standard that lets AI agents call external tools through a typed, discoverable interface. With manus-mcp-cli, you register MCP servers so your Manus agent can discover and invoke their tools automatically, without writing integration code or managing API keys manually. Think of it as the control plane for everything your agent can do beyond text generation.
How do I access manus-mcp-cli?
manus-mcp-cli comes pre-installed in every Manus sandbox environment. You do not need to install it separately. When Manus creates a sandbox for your task, the binary is already on the PATH. You can verify it is available by asking Manus to check the version, or by running the command directly in a Manus code block.
# Verify manus-mcp-cli is available
manus-mcp-cli --version
# List currently registered servers
manus-mcp-cli list serversIf you are working outside the Manus sandbox (for example, testing locally), you will not have access to manus-mcp-cli directly. In that case, use the Nylas CLI's own nylas mcp install command to register with your local AI assistant instead. See the MCP setup guide for local configuration.
How do I register an MCP server with manus-mcp-cli?
Registering an MCP server tells Manus where to find the server binary, what arguments to pass, and what environment variables it needs. Once registered, Manus automatically discovers the server's tools and makes them available during your conversation. The registration uses a JSON configuration object that follows the MCP server specification.
# Register a server with inline JSON config
manus-mcp-cli register server --config '{
"name": "nylas",
"command": "nylas",
"args": ["mcp", "serve"],
"env": {}
}'You can also register from a configuration file, which is cleaner for complex setups with multiple servers or environment variables.
# Register from a config file
manus-mcp-cli register server --config-file /path/to/mcp-config.jsonAfter registration, verify the server appears in the list and that Manus can discover its tools:
# List registered servers
manus-mcp-cli list servers
# List tools exposed by the nylas server
manus-mcp-cli list tools --server nylasHow do I configure the Nylas CLI as an MCP server for Manus?
The Nylas CLI has a built-in MCP server mode that exposes 16 email and calendar tools through the Model Context Protocol. To use it with manus-mcp-cli, you first install and authenticate the Nylas CLI inside the Manus sandbox, then register it as an MCP server. This gives your Manus agent full email and calendar access through structured tool calls.
# Step 1: Install the Nylas CLI in the Manus sandbox
curl -fsSL https://cli.nylas.com/install.sh | bash
export PATH="$PATH:$HOME/.nylas/bin"
# Step 2: Authenticate with your email provider
nylas auth login
# Step 3: Register the Nylas CLI as an MCP server
manus-mcp-cli register server --config '{
"name": "nylas",
"command": "nylas",
"args": ["mcp", "serve"],
"env": {
"PATH": "/usr/local/bin:/usr/bin:/bin:$HOME/.nylas/bin"
}
}'The full JSON configuration for the Nylas MCP server looks like this. Save it as nylas-mcp.json for reuse across sessions:
{
"name": "nylas",
"command": "nylas",
"args": ["mcp", "serve"],
"env": {
"PATH": "/usr/local/bin:/usr/bin:/bin:$HOME/.nylas/bin"
},
"description": "Email and calendar tools via Nylas CLI",
"timeout": 30000
}Once registered, your Manus agent has access to tools like nylas_send_email, nylas_list_emails,nylas_create_event, and nylas_get_availability. See the command reference for the full list.
How do I send email with manus-mcp-cli?
After registering the Nylas CLI as an MCP server, you can send email either through natural language prompts to your Manus agent or by calling the MCP tool directly. The agent automatically selects the nylas_send_email tool when you ask it to send a message. For direct invocation, use the manus-mcp-cli call command.
# Send email via manus-mcp-cli tool call
manus-mcp-cli call nylas nylas_send_email '{
"to": "recipient@example.com",
"subject": "Weekly report",
"body": "Hi team, here is the weekly status update.",
"reply_to": "me@example.com"
}'For HTML email with attachments:
# Send HTML email with an attachment
manus-mcp-cli call nylas nylas_send_email '{
"to": "client@example.com",
"subject": "Project proposal",
"body": "<h1>Proposal</h1><p>Please find the proposal attached.</p>",
"content_type": "text/html",
"attach": ["/tmp/proposal.pdf"]
}'You can also ask Manus in natural language: “Send an email to alice@example.com with the meeting notes from today.” Manus will compose the message and call the MCP tool. It will ask for confirmation before sending unless you include --yes in the tool configuration.
How do I configure Gmail in manus-mcp-cli?
Gmail configuration happens at the Nylas CLI authentication layer, not in manus-mcp-cli itself. You authenticate once with Gmail through the Nylas CLI, and the MCP server automatically uses that grant. The OAuth flow handles all the Google API complexity: scopes, consent screens, token refresh, and quota management.
# Authenticate with Gmail
nylas auth login --provider google
# Verify the grant
nylas auth list
# The MCP server auto-detects your Gmail grant
manus-mcp-cli call nylas nylas_list_emails '{
"limit": 5,
"folders": ["INBOX"]
}'How do I configure Yahoo email in manus-mcp-cli?
Yahoo Mail works the same way as Gmail. Authenticate through the Nylas CLI with the Yahoo provider, and the MCP server picks up the grant automatically. No app passwords, no IMAP server addresses, no port numbers. The Nylas CLI handles Yahoo's OAuth2 flow and abstracts the underlying protocol differences.
# Authenticate with Yahoo Mail
nylas auth login --provider yahoo
# Verify authentication
nylas auth list
# Read Yahoo inbox through manus-mcp-cli
manus-mcp-cli call nylas nylas_list_emails '{
"limit": 10,
"query": "from:support@yahoo.com"
}'How do I configure Exchange email in manus-mcp-cli?
Microsoft Exchange and Exchange Online (Office 365) use the same authentication flow. The Nylas CLI connects through Microsoft's OAuth2 endpoints and handles EWS or Graph API routing behind the scenes. You get a unified interface regardless of whether your organization runs on-premises Exchange or cloud-hosted Microsoft 365.
# Authenticate with Exchange / Office 365
nylas auth login --provider microsoft
# Search Exchange mailbox through manus-mcp-cli
manus-mcp-cli call nylas nylas_list_emails '{
"query": "subject:quarterly review",
"limit": 20
}'
# Create a calendar event
manus-mcp-cli call nylas nylas_create_event '{
"title": "Sprint planning",
"start": "2026-03-17T10:00:00",
"end": "2026-03-17T11:00:00",
"participants": ["team@company.com"]
}'How do I register a skill with manus-mcp-cli?
Beyond MCP servers, manus-mcp-cli can register Skills, which are instruction packages that teach your Manus agent specific workflows. Skills complement MCP by providing procedural knowledge. While MCP gives the agent tools, Skills tell the agent when and how to use those tools for a specific task.
# Register a Nylas email skill
manus-mcp-cli register skill --path /path/to/nylas-email-skill/
# The skill directory should contain SKILL.md:
# nylas-email-skill/
# SKILL.md <- Instructions and metadata
# scripts/
# setup.sh <- Install and auth Nylas CLI
# send-email.sh <- Email sending wrapper
# references/
# tools.md <- Available MCP toolsFor a complete walkthrough of creating a Manus Skill for email and calendar, see the Manus AI Skills guide.
What does a manus-mcp-cli server configuration look like?
Server configurations are JSON objects that follow the MCP specification. Here are common patterns for different use cases. Each configuration specifies the server name, the command to start it, arguments, and optional environment variables or timeout settings.
{
"servers": [
{
"name": "nylas",
"command": "nylas",
"args": ["mcp", "serve"],
"env": {
"PATH": "/usr/local/bin:/usr/bin:/bin:$HOME/.nylas/bin"
},
"description": "Email and calendar tools",
"timeout": 30000
},
{
"name": "nylas-eu",
"command": "nylas",
"args": ["mcp", "serve", "--region", "eu"],
"env": {
"PATH": "/usr/local/bin:/usr/bin:/bin:$HOME/.nylas/bin"
},
"description": "Email and calendar tools (EU region)",
"timeout": 30000
}
]
}For multi-account setups where you need to route to specific grants:
{
"name": "nylas-work",
"command": "nylas",
"args": ["mcp", "serve", "--grant", "work@company.com"],
"env": {
"PATH": "/usr/local/bin:/usr/bin:/bin:$HOME/.nylas/bin"
},
"description": "Work email and calendar"
}manus-mcp-cli vs Manus Skills vs direct Nylas CLI
There are three ways to give your Manus agent email and calendar access. Each has trade-offs. The right choice depends on whether you want structured tool access, procedural automation, or maximum flexibility. Here is a side-by-side comparison.
| Feature | manus-mcp-cli (MCP) | Manus Skills | Direct Nylas CLI |
|---|---|---|---|
| Tool discovery | Automatic (typed schemas) | Manual (read SKILL.md) | Manual (read docs) |
| Setup complexity | Register server once | Create SKILL.md + scripts | Install binary + auth |
| Reusable workflows | No (tools only) | Yes (procedural instructions) | Via shell scripts |
| Output format | Structured JSON | Varies (text or JSON) | JSON with --json flag |
| Error handling | MCP error codes | Agent interprets output | Exit codes + stderr |
| Multi-provider | Yes (auto-detects grant) | Yes (via CLI commands) | Yes |
| Best for | Structured agent access | Repeatable procedures | Ad hoc commands, scripts |
For most Manus users, the recommended approach is MCP via manus-mcp-cli for tool access, combined with a Skill for any multi-step workflows you repeat often. See the Skills guide and the MCP guide for the full setup of each approach.
Troubleshooting common manus-mcp-cli issues
Here are the most common problems when setting up manus-mcp-cli with the Nylas CLI, and how to fix them.
Server not found after registration
The most common cause is a PATH issue. The Nylas CLI binary needs to be on the PATH that manus-mcp-cli uses when spawning the server process. Include the full PATH in your server configuration.
# Check if nylas is on the PATH
which nylas
# If not found, add it
export PATH="$PATH:$HOME/.nylas/bin"
# Re-register with explicit PATH in env
manus-mcp-cli register server --config '{
"name": "nylas",
"command": "/home/user/.nylas/bin/nylas",
"args": ["mcp", "serve"],
"env": {
"PATH": "/usr/local/bin:/usr/bin:/bin:/home/user/.nylas/bin"
}
}'No authenticated grants found
The MCP server requires at least one authenticated email account. Run nylas auth login before registering the server, and verify with nylas auth list.
# Check existing grants
nylas auth list
# If empty, authenticate
nylas auth login
# Then test the MCP server manually
echo '{"jsonrpc":"2.0","method":"initialize","id":1,"params":{"capabilities":{}}}' | nylas mcp serveTool calls timing out
Increase the timeout in your server configuration. The default may be too low for operations that involve large mailboxes or slow network connections. Set it to 30000ms (30 seconds) or higher.
Wrong email account used
If you have multiple authenticated grants, the MCP server picks the first one by default. Specify the grant explicitly in the server args to route to a specific account.
# Register with a specific grant
manus-mcp-cli register server --config '{
"name": "nylas-personal",
"command": "nylas",
"args": ["mcp", "serve", "--grant", "personal@gmail.com"],
"env": {}
}'Next steps
- Create a Manus Skill for Email and Calendar for reusable multi-step workflows
- Give AI Agents Email Access via MCP for local setup with Claude Desktop, Cursor, or VS Code
- Automate Email with Manus AI: Beginner Guide if you are new to Manus
- Command Reference for the complete list of CLI commands and MCP tools