Build Google Chat bots, webhooks, and interactive forms with Cards v2, Spaces/Members/Reactions APIs, and bearer token verification.
Works with
Supports two integration modes: incoming webhooks for one-way notifications and HTTP endpoints for interactive bots with button clicks and form submissions
Cards v2 with Markdown and HTML formatting, 15+ widget types (text, buttons, inputs, date pickers), and 100-widget-per-card limit
Spaces API for creating/listing/searching spaces, Members API for man
AI-first code editor with Composer
Before installing skills in Cursor, ensure your development environment meets these requirements:
node --versiongoogle-chat-apiExecute the skills CLI command in your project's root directory to begin installation:
Fetches google-chat-api from jezweb/claude-skills and configures it for Cursor.
The CLI shows a list of agents. Use arrow keys and space to select Cursor:
Confirm successful installation by checking the skill directory location:
Restart Cursor to activate google-chat-api. Access via /google-chat-api in your agent's command palette.
We perform automated surface-level scans (Gen AI Scanner, Socket, Snyk) during installation. These checks detect common vulnerabilities but do not guarantee complete security. Always review skill source code and verify the publisher's reputation before production use.
Skills execute code in your environment. Always review source, verify the publisher, and test in isolation before production.
Submit your Claude Code skill and start earning
Automate repetitive workflows and reduce manual effort
Example
Generate reports, summarize documents, draft communications
Save 3-5 hours per week on routine tasks
Learn new skills, understand complex topics, get expert guidance
Example
Explain concepts, provide examples, suggest learning resources
Accelerate learning and skill development by 2x
Enhance output quality through reviews, suggestions, and refinements
Example
Review drafts, suggest improvements, catch errors
Improve work quality by 30-40% with less effort
2
total installs
2
this week
695
GitHub stars
0
upvotes
Run in your terminal
2
installs
2
this week
695
stars
Status: Production Ready Last Updated: 2026-01-09 (Added: Spaces API, Members API, Reactions API, Rate Limits) Dependencies: Cloudflare Workers (recommended), Web Crypto API for token verification Latest Versions: Google Chat API v1 (stable), Cards v2 (Cards v1 deprecated), [email protected]
# No code needed - just configure in Google Chat
# 1. Go to Google Cloud Console
# 2. Create new project or select existing
# 3. Enable Google Chat API
# 4. Configure Chat app with webhook URL
Webhook URL: https://your-worker.workers.dev/webhook
Why this matters:
export default {
async fetch(request: Request, env: Env): Promise<Response> {
const event = await request.json()
// Respond with a card
return Response.json({
text: "Hello from bot!",
cardsV2: [{
cardId: "unique-card-1",
card: {
header: { title: "Welcome" },
sections: [{
widgets: [{
textParagraph: { text: "Click the button below" }
}, {
buttonList: {
buttons: [{
text: "Click me",
onClick: {
action: {
function: "handleClick",
parameters: [{ key: "data", value: "test" }]
}
}
}]
}
}]
}]
}
}]
})
}
}
CRITICAL:
cardsV2 arrayasync function verifyToken(token: string): Promise<boolean> {
// Verify token is signed by [email protected]
// See templates/bearer-token-verify.ts for full implementation
return true
}
Why this matters:
Option A: Incoming Webhook (Notifications Only)
Best for:
Setup:
No code required - just HTTP POST:
curl -X POST 'https://chat.googleapis.com/v1/spaces/.../messages?key=...' \
-H 'Content-Type: application/json' \
-d '{"text": "Hello from webhook!"}'
Option B: HTTP Endpoint Bot (Interactive)
Best for:
Setup:
Requires code - see templates/interactive-bot.ts
IMPORTANT: Use Cards v2 only. Cards v1 was deprecated in 2025. Cards v2 matches Material Design on web (faster rendering, better aesthetics).
Cards v2 structure:
{
"cardsV2": [{
"cardId": "unique-id",
"card": {
"header": {
"title": "Card Title",
"subtitle": "Optional subtitle",
"imageUrl": "https://..."
},
"sections": [{
"header": "Section 1",
"widgets": [
{ "textParagraph": { "text": "Some text" } },
{ "buttonList": { "buttons": [...] } }
]
}]
}
}]
}
Widget Types:
textParagraph - Text contentbuttonList - Buttons (text or icon)textInput - Text input fieldselectionInput - Dropdowns, checkboxes, switchesdateTimePicker - Date/time selectiondivider - Horizontal lineimage - ImagesdecoratedText - Text with icon/buttonText Formatting (NEW: Sept 2025 - GA):
Cards v2 supports both HTML and Markdown formatting:
// HTML formatting (traditional)
{
textParagraph: {
text: "This is <b>bold</b> and <i>italic</i> text with <font color='#ea9999'>color</font>"
}
}
// Markdown formatting (NEW - better for AI agents)
{
textParagraph: {
text: "This is **bold** and *italic* text\n\n- Bullet list\n- Second item\n\n```\ncode block\n```"
}
}
Supported Markdown (text messages and cards):
**bold** or *italic*`code` for inline code- list item or 1. ordered for lists```code block``` for multi-line code~strikethrough~Supported HTML (cards only):
<b>bold</b>, <i>italic</i>, <u>underline</u><font color="#FF0000">colored</font><a href="url">link</a>Why Markdown matters: LLMs naturally output Markdown. Before Sept 2025, you had to convert Markdown→HTML. Now you can pass Markdown directly to Chat.
CRITICAL:
When user clicks button or submits form:
export default {
async fetch(request: Request): Promise<Response> {
const event = await request.json()
// Check event type
if (event.type === 'MESSAGE') {
// User sent message
return handleMessage(event)
}
if (event.type === 'CARD_CLICKED') {
// User clicked button
const action = event.action.actionMethodName
const params = event.action.parameters
if (action === 'submitForm') {
return handleFormSubmission(event)
}
}
return Response.json({ text: "Unknown event" })
}
}
Event Types:
ADDED_TO_SPACE - Bot added to spaceREMOVED_FROM_SPACE - Bot removedMESSAGE - User sent messageCARD_CLICKED - User clicked button/submitted form✅ Return valid JSON with cardsV2 array structure
✅ Set unique cardId for each card
✅ Verify bearer tokens for HTTP endpoints (production)
✅ Handle all event types (MESSAGE, CARD_CLICKED, etc.)
✅ Keep widget count under 100 per card
✅ Validate form inputs server-side
❌ Store secrets in code (use Cloudflare Workers secrets) ❌ Exceed 100 widgets per card (silently fails) ❌ Return malformed JSON (breaks entire message) ❌ Skip bearer token verification (security risk) ❌ Trust client-side validation only (validate server-side) ❌ Use synchronous blocking operations (timeout risk)
This skill prevents 6 documented issues:
Error: "Unauthorized" or "Invalid credentials" Source: Google Chat API Documentation Why It Happens: Token not verified or wrong verification method Prevention: Template includes Web Crypto API verification (Cloudflare Workers compatible)
Error: "Invalid JSON payload" or "Unknown field"
Source: Cards v2 API Reference
Why It Happens: Typo in field name, wrong nesting, or extra fields
Prevention: Use google-chat-cards library or templates with exact schema
Error: No error - widgets beyond 100 simply don't render Source: Google Chat API Limits Why It Happens: Adding too many widgets to single card Prevention: Skill documents 100 widget limit + pagination patterns
Prerequisites
Time Estimate
15-45 minutes depending on use case complexity
Steps
Common Pitfalls
✓ Do
✗ Don't
💡 Pro Tips
✓ Use when
Use when skill capabilities match your task, clear ROI on time saved, and you can validate outputs. Best for repetitive tasks, learning, and quality improvement.
✗ Avoid when
Avoid when task requires deep expertise you can't validate, involves sensitive decisions, or when learning process is more valuable than speed of completion.
jezweb/claude-skills
jezweb/claude-skills
kostja94/marketing-skills
jwynia/agent-skills
mindrally/skills
github/awesome-copilot
google-chat-api is among the better-maintained entries we tried; worth keeping pinned for repeat workflows.
Keeps context tight: google-chat-api is the kind of skill you can hand to a new teammate without a long onboarding doc.
google-chat-api fits our agent workflows well — practical, well scoped, and easy to wire into existing repos.
Useful defaults in google-chat-api — fewer surprises than typical one-off scripts, and it plays nicely with `npx skills` flows.
google-chat-api reduced setup friction for our internal harness; good balance of opinion and flexibility.
google-chat-api has been reliable in day-to-day use. Documentation quality is above average for community skills.
google-chat-api has been reliable in day-to-day use. Documentation quality is above average for community skills.
google-chat-api reduced setup friction for our internal harness; good balance of opinion and flexibility.
Keeps context tight: google-chat-api is the kind of skill you can hand to a new teammate without a long onboarding doc.
We added google-chat-api from the explainx registry; install was straightforward and the SKILL.md answered most questions upfront.
showing 1-10 of 71