google-workspace
Enables interaction with Google Workspace (Drive, Docs, Sheets, Gmail) via MCP tools, using OAuth credentials stored locally or inline.
README
Google Workspace MCP szerver
Ez a google-workspace skill MCP-szerver változata. A lényeg: nem kell többé
mountolni a Dokumentumok/Claude/google-workspace mappát minden sessionhöz.
Miért működik? Az MCP-szervereket a Claude Desktop indítja a host gépen, nem
a Cowork-sandboxban. Így a szerver közvetlenül látja a credential-fájljaidat a
host filerendszerről, a credentialök elérési útját / tartalmát pedig a
claude_desktop_config.json env blokkjából kapja. Minden sessionben automatikusan
elérhető, nulla kézi lépéssel.
A teljes Drive / Docs / Sheets / Gmail funkciókészlet ugyanaz, mint a skillé — a
tényleges API-logika a google_helper.py-ban van, a server.py csak betölti a
credentialöket és MCP-tool-ként közzéteszi a függvényeket.
Mire van szükség
- A meglévő credential-fájljaid:
google_token.jsonésgoogle_client_secret.json(ezek már megvannak a~/Dokumentumok/Claude/google-workspacemappádban az eredeti OAuth-setupból). - Python 3.10+ a host gépen.
Telepítés
-
Másold ezt a
google-workspace-mcpmappát egy állandó helyre, pl.~/Dokumentumok/Claude/google-workspace-mcp. -
Hozz létre egy virtuális környezetet és telepítsd a függőségeket:
cd ~/Dokumentumok/Claude/google-workspace-mcp python3 -m venv .venv .venv/bin/pip install -r requirements.txt -
Regisztráld a szervert a
claude_desktop_config.json-ban (Claude Desktop → Settings → Developer → Edit Config, vagy macOS-en~/Library/Application Support/Claude/claude_desktop_config.json).A) Egyszerű mód — a meglévő mappádra mutatsz (ajánlott; a titkok fájlban maradnak, nem a configban):
{ "mcpServers": { "google-workspace": { "command": "/ABSZOLUT/UT/google-workspace-mcp/.venv/bin/python", "args": ["/ABSZOLUT/UT/google-workspace-mcp/server.py"], "env": { "GOOGLE_WORKSPACE_DIR": "/ABSZOLUT/UT/Dokumentumok/Claude/google-workspace" } } } }B) Minden a configban — a te eredeti ötleted (a credentialök tartalma inline kerül be; nem függ semmilyen mappától):
{ "mcpServers": { "google-workspace": { "command": "/ABSZOLUT/UT/google-workspace-mcp/.venv/bin/python", "args": ["/ABSZOLUT/UT/google-workspace-mcp/server.py"], "env": { "GOOGLE_TOKEN_JSON": "{\"access_token\":\"...\",\"refresh_token\":\"...\",\"scope\":\"...\"}", "GOOGLE_CLIENT_SECRET_JSON": "{\"installed\":{\"client_id\":\"...\",\"client_secret\":\"...\"}}" } } } }A
commandlegyen a venv pythonja (abszolút út). A/ABSZOLUT/UT/...részeket cseréld a saját útjaidra. -
Indítsd újra a Claude Desktopot. A
google-workspaceszerver tooljai (search_files, read_doc, write_sheet, gmail_search, create_draft, stb.) ezután minden sessionben elérhetők.
Credential-betöltési sorrend
A server.py ebben a sorrendben keres:
GOOGLE_WORKSPACE_DIR— mappa, amiben a két JSON fájl van (A mód).GOOGLE_TOKEN_JSON+GOOGLE_CLIENT_SECRET_JSON— a fájlok tartalma inline (B mód). Induláskor egy privát temp mappába íródnak.- Fallback: a helper saját auto-felderítése (a home könyvtárban keres egy
google-workspacemappát).
Token-frissítés
A szerver hosszú életű, ezért a frissített access tokent memóriában tartja a
process futása alatt — a refresh token nem változik. A mód esetén a frissített
token vissza is íródik a mappa google_token.json fájljába. B mód esetén a
frissítés csak a process élettartamáig él (a refresh token a configban marad, így
ez nem gond).
Ha 401-et kapsz a refresh ellenére, a refresh token érvénytelen, és újra kell
futtatni az eredeti OAuth-flow-t.
Megjegyzés a régi skillről
Ha ezt használod, a google-workspace skillt akár ki is kapcsolhatod, hogy ne
ütközzön / ne kérje a mappa mountolását. A Gmail-műveletekhez továbbra is a
megfelelő OAuth scope-ok kellenek (gmail.modify, a végleges törléshez a teljes
mail.google.com).
Biztonsági megjegyzés
A GOOGLE_TOKEN_JSON egy refresh tokent tartalmaz, ami tartós hozzáférést ad a
fiókodhoz. Akár fájlban (A), akár configban (B) tárolod, kezeld titkosan: ne tedd
verziókövetésbe, és korlátozd a fájl jogosultságait.
Recommended Servers
playwright-mcp
A Model Context Protocol server that enables LLMs to interact with web pages through structured accessibility snapshots without requiring vision models or screenshots.
Magic Component Platform (MCP)
An AI-powered tool that generates modern UI components from natural language descriptions, integrating with popular IDEs to streamline UI development workflow.
Audiense Insights MCP Server
Enables interaction with Audiense Insights accounts via the Model Context Protocol, facilitating the extraction and analysis of marketing insights and audience data including demographics, behavior, and influencer engagement.
VeyraX MCP
Single MCP tool to connect all your favorite tools: Gmail, Calendar and 40 more.
graphlit-mcp-server
The Model Context Protocol (MCP) Server enables integration between MCP clients and the Graphlit service. Ingest anything from Slack to Gmail to podcast feeds, in addition to web crawling, into a Graphlit project - and then retrieve relevant contents from the MCP client.
Kagi MCP Server
An MCP server that integrates Kagi search capabilities with Claude AI, enabling Claude to perform real-time web searches when answering questions that require up-to-date information.
Neon Database
MCP server for interacting with Neon Management API and databases
E2B
Using MCP to run code via e2b.
Exa Search
A Model Context Protocol (MCP) server lets AI assistants like Claude use the Exa AI Search API for web searches. This setup allows AI models to get real-time web information in a safe and controlled way.
Qdrant Server
This repository is an example of how to create a MCP server for Qdrant, a vector search engine.