# Workspace MCP — Google Workspace Tools via MCP > Workspace MCP exposes Gmail/Drive/Calendar tools over MCP with uv launch tiers and an HTTP mode designed to work with Claude Code OAuth flows. ## Install Merge the JSON below into your `.mcp.json`: ## Quick Use 1. Set credentials and launch a minimal tier: ```bash export GOOGLE_OAUTH_CLIENT_ID="..." export GOOGLE_OAUTH_CLIENT_SECRET="..." uvx workspace-mcp --tool-tier core ``` 2. (Claude Code) Use HTTP transport: ```bash uv run main.py --transport streamable-http claude mcp add --transport http workspace-mcp http://localhost:8000/mcp ``` 3. Pick services explicitly if needed: ```bash uv run main.py --tools gmail drive calendar ``` ## Intro Workspace MCP exposes Gmail/Drive/Calendar tools over MCP with uv launch tiers and an HTTP mode designed to work with Claude Code OAuth flows. - **Best for:** agents that need Google Workspace automation with OAuth and fine-grained tool selection - **Works with:** Python + uv/uvx, Google OAuth credentials, MCP clients (HTTP recommended for OAuth) - **Setup time:** 25–60 minutes ## Practical Notes - Data point: default HTTP endpoint in docs is `http://localhost:8000/mcp`. - Quant: start with `--tool-tier core` before enabling extended/complete to reduce scope. ## Pattern: separate auth setup from tool rollout With Google OAuth, the most reliable rollout is: 1) make auth succeed for one user, 2) run read-only tools, 3) then enable write scopes. ## Hardening tips - Prefer HTTP transport for OAuth flows and multi-user setups. - Store OAuth client secrets in a secret manager (not `.env` committed to git). - Restrict available tools to the minimum required per workflow. ### FAQ **Q: Can it run in stdio mode?** A: The README recommends HTTP mode for OAuth 2.1 and multi-user support. **Q: How do I limit permissions?** A: Start with a smaller tool tier and enable write tools only when needed. **Q: Does it support VS Code MCP?** A: Yes. The README includes a `.vscode/mcp.json` example and notes about HTTP transport. ## Source & Thanks > Source: https://github.com/taylorwilsdon/google_workspace_mcp > License: MIT > GitHub stars: 2,380 · forks: 724 --- ## 快速使用 1. 配置凭证并启动最小工具集: ```bash export GOOGLE_OAUTH_CLIENT_ID="..." export GOOGLE_OAUTH_CLIENT_SECRET="..." uvx workspace-mcp --tool-tier core ``` 2.(Claude Code)用 HTTP transport: ```bash uv run main.py --transport streamable-http claude mcp add --transport http workspace-mcp http://localhost:8000/mcp ``` 3. 需要时按服务精确选择: ```bash uv run main.py --tools gmail drive calendar ``` ## 简介 Workspace MCP 通过 MCP 暴露 Gmail/Drive/Calendar 等工具;提供 uv 启动分层与 HTTP 模式,并给出适配 Claude Code OAuth 流程的配置示例。 - **适合谁:** 需要通过 OAuth 自动化 Google Workspace,并希望工具集可精细控制的 agent - **可搭配:** Python + uv/uvx、Google OAuth 凭证、MCP 客户端(OAuth 推荐 HTTP) - **准备时间:** 25–60 分钟 ## 实战建议 - 数据点:文档默认的 HTTP 端点是 `http://localhost:8000/mcp`。 - 量化建议:先用 `--tool-tier core`,再逐步开启 extended/complete,减少授权范围。 ## 常用打法:把鉴权与工具放量分开 Google OAuth 最稳的落地顺序: 1)先让一个用户授权跑通, 2)先跑只读工具, 3)再逐步开放写入权限。 ## 加固建议 - OAuth 场景与多人场景优先用 HTTP transport。 - OAuth client secret 放到密钥管理(不要提交 `.env`)。 - 每个 workflow 只暴露最小工具集。 ### FAQ **能用 stdio 模式吗?** 答:README 更推荐 OAuth 场景使用 HTTP 模式以保证完整支持。 **怎么限制权限?** 答:先用更小的 tool tier,只有需要时再开放写工具。 **支持 VS Code MCP 吗?** 答:支持。README 给了 `.vscode/mcp.json` 示例并提示要用 HTTP transport。 ## 来源与感谢 > Source: https://github.com/taylorwilsdon/google_workspace_mcp > License: MIT > GitHub stars: 2,380 · forks: 724 --- Source: https://tokrepo.com/en/workflows/workspace-mcp-google-workspace-tools-via-mcp Author: MCP Hub