Google Chat
Google Chat adapter using Webhook / HTTP events backed by a Google Cloud Service Account.
Prerequisites
- Create a project in Google Cloud Console → enable Google Chat API.
- Create a Service Account → download JSON key.
- Publish an App via the Chat API → Configuration:
- App type: Bot
- Connection settings: HTTP endpoint
- URL:
https://<your-public-host>/googlechat - Scope:
chat.messages
Environment
export GOOGLECHAT_SERVICE_ACCOUNT_JSON='{"type":"service_account","project_id":"...","private_key":"..."}'export GOOGLECHAT_AUTH_AUDIENCE=https://<your-public-host>/googlechatexport GOOGLECHAT_WEBHOOK_HOST=0.0.0.0export GOOGLECHAT_WEBHOOK_PORT=16668export GOOGLECHAT_WEBHOOK_PATH=/googlechatThe JSON must be a single line (or base64-wrap and decode at startup).
Thread semantics
Google Chat’s thread.name is used directly as thread key.
Troubleshooting
- 401 from webhook:
GOOGLECHAT_AUTH_AUDIENCEmust exactly match the HTTP endpoint audience used by Google Chat. - Unresponsive despite online: Chat API defaults limit bots to Workspace users; confirm Service Account has domain authorization.
- JSON parse error: preserve
\nas literal\nin the private key (not a real newline).