- Home
- Skills
- APIs & Backend
- Google Chat (No OAuth)
Google Chat (No OAuth)
Send and receive Google Chat messages from your agent via webhooks and a service account — no interactive OAuth consent, no pip dependencies.
Free
Works with the AI Agents you already use
Google Chat (No OAuth)
Example session with this skill installed
Post a card to our #deploys Google Chat space saying the auth-service production deploy succeeded, with a button to the build logs at https://ci.internal.net/build/auth-service/10293/logs. Keep it in the auth-service-prod thread.
- Read your context and instructions
- Compiled the google chat no
Summary
Sent a cardsV2 message to the #deploys space via the configured webhook, grouped under the auth-service-prod thread. Google returned the message name spaces/AAAA1234/messages/xyz.abc.
Command run
python3 scripts/send.py --card-file /tmp/deploy-card.json --text "auth-service deployed to production" --thread-key auth-service-prod
/tmp/deploy-card.json
{
"cardsV2": [{
"cardId": "deploy_status",
"card": {
"header": {"title": "Deployment Success", "subtitle": "auth-service | production"},
"sections": [{
"widgets": [
{"decoratedText": {"topLabel": "Environment", "text": "<b>Production</b>", "startIcon": {"knownIcon": "TICKET"}}},
{"buttonList": {"buttons": [{"text": "View Build Logs", "onClick": {"openLink": {"url": "https://ci.internal.net/build/auth-service/10293/logs"}}}]}}
]
}]
}
}]
}
What the request looked like (--dry-run output, secret redacted)
POST https://chat.googleapis.com/v1/spaces/AAAA1234/messages?key=***&token=***&messageReplyOption=REPLY_MESSAGE_FALLBACK_TO_NEW_THREAD
{"cardsV2": [...], "text": "auth-service deployed to production", "fallbackText": "auth-service deployed to production", "thread": {"threadKey": "auth-service-prod"}}
Next steps
- Check the card in #deploys; the
--textvalue is also the notification fallback shown by clients that can't render cards. - Reuse
--thread-key auth-service-prodfor future deploys of this service so they stay in one thread. - Rotate the webhook URL (delete and re-add the webhook in the space) if the CI environment is ever compromised.
Connects securely to your tools. The creator never sees your data.
About this skill
Integrating with Google Chat usually means an OAuth consent screen and a client library. This skill skips both for automated workflows: incoming webhooks for sending (the only credential is a webhook URL) and service-account app authentication for reading. Python 3.9+ standard library only.
What it does
- Send notifications through an incoming webhook — no Google Cloud project needed.
- Thread messages with a stable key, sent as
thread.threadKeyin the body (the deprecatedthreadKeyquery parameter is not used). - Format text with Google Chat markup:
*bold*,_italic_,~strike~,\code`,https://url|label,<users/all>`. - Send cards from a cardsV2 JSON file (buttons, icons, rich layouts);
--textdoubles asfallbackText. - Read recent messages of a space as JSON lines or plain text, and list the spaces the app can see with
--list-spaces. - Retry automatically on HTTP 429/5xx with exponential backoff, honouring
Retry-After(capped at 30 s). - Pipe stdin with
--text -;--quietfor CI logs;--dry-runpreviews the request with the secret redacted.
How it works
- Webhook setup — in the target space: Apps & integrations → Webhooks → Add webhook. Export the URL as
GOOGLE_CHAT_WEBHOOK_URL. - Send —
python3 scripts/send.py --text "Deploy finished"; add--thread-key ci-buildsto group,--card-file card.jsonfor a card. - Reading setup (once, Workspace admin) — Google Cloud project with the Chat API, a Chat app, a service-account key, a Marketplace-compatible OAuth client plus Marketplace SDK app configuration, admin approval of
chat.app.messages.readonly, and the app added to the space. The SKILL.md walks through each step. - Read —
python3 scripts/receive.py --list-spaces --plain, thenpython3 scripts/receive.py --space spaces/AAAA1234 --plain --since 2026-10-01T00:00:00Z.
Frameworks & tools
Python 3.9+ standard library only. The service-account JWT is signed with the openssl binary, so there is nothing to install. Secrets stay in environment variables; send.py only talks to https://chat.googleapis.com, never follows redirects, and never prints the webhook secret.
Why this beats prompting it yourself
Hand-written webhook calls get Google Chat markup, the threading parameters and cardsV2 wrong in small ways, and they have no retry on Google's 1-request-per-second quota. These scripts encode the current API behaviour, exit with clear codes (0 sent / 1 HTTP error / 2 usage error) instead of tracebacks, and the SKILL.md tells the agent when to confirm with you before posting and to treat received messages as untrusted text.
Use cases
- Post build status or deployment alerts from a CI/CD pipeline, grouped per service with a thread key.
- Send monitoring reports as cards with buttons that open log URLs.
- Pipe
git logor test output straight into a space with--text -. - Read the latest messages of a space to summarise activity for a standup.
- Notify everyone in a space with
<users/all>— only when the user asks for it.
Known limitations
Needs a Google Workspace (Business/Enterprise) account; personal @gmail.com has no webhooks. Webhooks are registered per space and work in DMs only when every participant has Chat apps enabled. Reading needs a one-time Workspace-admin approval and returns only spaces the app is a member of. Google's quota is 1 request per second per space, shared by all webhooks in that space; send.py backs off automatically on HTTP 429.
Google Workspace only (no personal @gmail.com). Webhooks are per space; DMs only when all participants have Chat apps enabled. Reading needs one-time admin approval and the app must be a member of the space. Quota: 1 request/sec per space (shared by all webhooks there); send.py retries with backoff.
How to use
- 1
Connect your agent to the Agensi MCP
Copy the prompt and paste it into Claude, ChatGPT, Cursor or any agent that supports MCP. It sets up the connection for you. Manual setup
- 2
Sign in to Agensi
Your agent shows a sign-in link. Sign in and click Allow.
- 3
Ask for what you need
Your agent loads this skill and uses it on your task. It always asks before any payment.
Reviews
No reviews yet
Be one of the first to try it. Every listed skill goes through the trust checks below.
Security scanned
Checked by our 8-point scan before listing
1 use
Times used to date
Free forever
No account required to browse
Trust & safety
Security scan
Security scan passed 25 days ago
- Free with an Agensi account
Requires
Permissions
Allowed Hosts