google-chat-mcp
google-chat-mcp
MCP-Server für Google Chat. Ermöglicht Claude (Code / Desktop) oder einem beliebigen MCP-Client, deine Spaces aufzulisten, Nachrichten zu lesen und zu durchsuchen, Threads und Mitglieder abzurufen und – optional – Nachrichten in deinem Namen zu senden.
Standardmäßig schreibgeschützt. Läuft lokal über stdio. Das Refresh-Token wird mit 0600 unter ~/.google-chat-mcp/ gespeichert.
Werkzeuge
Werkzeug | Eingabe | Hinweise |
|
| Nach letzter Aktivität sortiert. DMs haben keinen Namen, außer wenn |
|
| Neueste zuerst. |
|
| Clientseitiger Scan; die Chat-API hat keine Volltextsuche. Standardfenster 14 Tage, ≤500 Nachrichten/Space. |
|
| Alle Antworten, älteste zuerst. |
|
| Benutzer + Rollen, Namen/E-Mails über die People API. |
|
| Nur registriert, wenn |
Absendernamen stammen aus dem People-API-Verzeichnis (directory.readonly). Wenn diese API deaktiviert ist oder der Benutzer extern ist, erhältst du stattdessen users/<id> — alles andere funktioniert weiterhin.
Related MCP server: google-mcp
Einrichtung
Erfordert ein Google Workspace-Konto. Private @gmail.com-Konten können die Chat-API nicht aufrufen (403).
1. Google Cloud-Projekt (einmalig, ~10 Min.)
console.cloud.google.com → Projekt erstellen/auswählen.
APIs & Dienste → Bibliothek → Google Chat API und People API aktivieren.
Tab Google Chat API → Konfiguration → App-Name, Avatar-URL, Beschreibung ausfüllen; interaktive Funktionen aus; Sichtbarkeit für deine Domain. Speichern.
Achtung: Die Chat-API lehnt alle OAuth-Aufrufe mit
403ab, bis dieses Formular gespeichert ist, sogar für schreibgeschützte Benutzerauthentifizierung.OAuth-Zustimmungsbildschirm → Intern → Bereiche hinzufügen:
https://www.googleapis.com/auth/chat.spaces.readonlyhttps://www.googleapis.com/auth/chat.messages.readonlyhttps://www.googleapis.com/auth/chat.memberships.readonlyhttps://www.googleapis.com/auth/directory.readonlyhttps://www.googleapis.com/auth/chat.messages.create(nur wenn dusend_messagemöchtest)
Anmeldedaten → Anmeldedaten erstellen → OAuth-Client-ID → Desktop-App → JSON herunterladen. Halte es aus jedem Repository heraus.
2. Anmelden
export GOOGLE_CHAT_CLIENT_SECRET_PATH=/path/to/client_secret.json
npx google-chat-mcp login # browser opens → sign in with your Workspace account
npx google-chat-mcp whoami # sanity check3. Bei Claude Code registrieren
claude mcp add google-chat \
-e GOOGLE_CHAT_CLIENT_SECRET_PATH=/path/to/client_secret.json \
-- npx -y google-chat-mcpClaude Desktop (claude_desktop_config.json):
{
"mcpServers": {
"google-chat": {
"command": "npx",
"args": ["-y", "google-chat-mcp"],
"env": { "GOOGLE_CHAT_CLIENT_SECRET_PATH": "/path/to/client_secret.json" }
}
}
}Umgebung
Variable | Standardwert | Zweck |
| — | Desktop-OAuth-Client-JSON. Auf macOS wird auf den Keychain-Eintrag |
|
| Refresh-Token-Cache. |
|
|
|
Hinweise zum Kontingent
Chat-API: ~60 Anfragen/min/Benutzer. Space- und Mitgliederlisten werden prozessintern 5 Minuten lang zwischengespeichert; aufgelöste Benutzernamen werden auf der Festplatte in ~/.google-chat-mcp/users.json zwischengespeichert. search_messages ist die teure Operation — grenze sie mit spaces und since ein.
Entwicklung
pnpm install
pnpm dev login
pnpm typecheck && pnpm lint && pnpm buildNode ≥ 22. TypeScript strict, ESM, Build mit tsup.
Lizenz
MIT
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
Related MCP Connectors
Workspace messaging: conversations, contacts, agents, and connected lines through scoped OAuth.
Read email/chat conversations, messages, contacts and teams; draft, send and update threads.
Read Spruce Health contacts, conversations, messages, phone lines and team members (read-only).
Permissioned access to Gmail, Drive and Calendar via the user's own Google account
Related MCP Servers
- AlicenseNot gradedqualityFmaintenanceConnects Claude to Google Chat for searching messages, spaces, and DMs, automatically resolving user IDs to real display names.MIT
- AlicenseNot gradedqualityDmaintenanceEnables interaction with Google Chat through MCP, allowing listing spaces and messages, searching messages, and sending messages. Supports local and remote transports.Apache 2.0
- -licenseNot gradedqualityDmaintenanceEnables AI assistants to read and send messages in Google Chat spaces using service account authentication.-
- AlicenseAqualityBmaintenanceEnables AI assistants to work in Google Chat through natural language: find spaces and direct messages, read and send messages, manage threads, reactions, attachments, and memberships while acting as the signed-in user.20140 npmMIT