Back to Browse

Mailport MCP Server

Developer ToolsUse Caution4.6MCP RegistryLocal
Free

Server data from the Official MCP Registry

Gmail messages, threads, labels, drafts and sending, as MCP tools via the Gmail API.

About

Gmail messages, threads, labels, drafts and sending, as MCP tools via the Gmail API.

Security Report

4.6
Use Caution4.6High Risk

mailport is a clean-role Gmail MCP server that uses a user-supplied bearer token from GOOGLE_ACCESS_TOKEN and has no hardcoded secrets, shell execution, or exfiltration patterns. The main concerns are that to, cc, bcc and subject are concatenated into RFC822 headers without stripping CR/LF, allowing header injection in send and draft tools, and that GMAIL_API_URL can redirect the bearer token to an arbitrary host. Email sending is inherently high-impact, but it matches the server's stated purpose. Supply chain analysis found 4 known vulnerabilities in dependencies (0 critical, 2 high severity). Package verification found 1 issue.

8 files analyzed · 9 issues found

Security scores are indicators to help you make informed decisions, not guarantees. Always review permissions before connecting any MCP server.

Permissions Required

This plugin requests these system permissions. Most are normal for its category.

HTTP Network Access

Connects to external APIs or services over the internet.

env_vars

Check that this permission is expected for this type of plugin.

email_send

Check that this permission is expected for this type of plugin.

email_read

Check that this permission is expected for this type of plugin.

label_modify

Check that this permission is expected for this type of plugin.

What You'll Need

Set these up before or after installing:

GOOGLE_ACCESS_TOKENRequired

How to Install

Add this to your MCP configuration file:

{
  "mcpServers": {
    "io-github-cloudcorprecords-mailport": {
      "env": {
        "GOOGLE_ACCESS_TOKEN": "your-google-access-token-here"
      },
      "args": [
        "-y",
        "@reneturcios/mailport"
      ],
      "command": "npx"
    }
  }
}

Documentation

View on GitHub

From the project's GitHub README.

mailport

Gmail messages, threads and labels as MCP tools, talking to the Gmail API. mailport is a clean-room rebuild of the core surface of the Gmail reference MCP server, under a new name: fresh code written from the public Gmail API documentation, no copied branding.

Tools (core subset, 10)

list_messages, get_message, list_threads, get_thread, list_labels, send_message, create_draft, modify_message, trash_message, create_label.

Label update/delete, draft get/update/delete/send, message delete and batchModify, history, profile/settings/watch, and attachment downloads from the wider Gmail surface are not in this subset.

Setup

Set a Google OAuth access token:

export GOOGLE_ACCESS_TOKEN=ya29....

Optionally override the API base with GMAIL_API_URL (default https://gmail.googleapis.com/gmail/v1). Without the token, every tool call fails with an error naming the missing variable.

CLI

npx @reneturcios/mailport list_messages '{"query":"in:inbox","max_results":5}'
npx @reneturcios/mailport mcp        # stdio MCP server

Each tool name is a subcommand taking one JSON object argument.

MCP client config

{
  "mcpServers": {
    "mailport": {
      "command": "npx",
      "args": ["-y", "@reneturcios/mailport", "mcp"],
      "env": { "GOOGLE_ACCESS_TOKEN": "ya29...." }
    }
  }
}

Docker

docker run -i -e GOOGLE_ACCESS_TOKEN ghcr.io/cloudcorprecords/mailport

Development

npm install
npm run build
npm test

License

MIT

Reviews

No reviews yet

Be the first to review this server!