Power Gws Events
Boost productivity using this subscribe, google, workspace, events. Includes structured workflows, validation checks, and reusable patterns for google workspace.
Power GWS Events
Comprehensive Google Workspace event management for subscriptions, notifications, and event pipeline operations.
When to Use This Command
Run this command when you need to:
- Manage multiple event subscriptions across different Workspace services from a single interface
- Configure advanced event routing with filters, transformations, and delivery guarantees
- Audit event delivery history and troubleshoot failed or delayed notifications
Consider alternatives when:
- You need to set up a simple one-resource watch which the instant command handles with less configuration
- You are building a new integration and want to explore what events are available before subscribing
Quick Start
Configuration
name: power-gws-events type: command category: google-workspace
Example Invocation
claude command:run power-gws-events --action audit --service all --days 7
Example Output
Auditing event subscriptions...
Services: all
Period: last 7 days
Active Subscriptions: 5
Service Resource Channel Expires Events/day
Calendar primary ch_cal_01 Apr 14 124
Drive shared-drive-1 ch_drv_01 Apr 10 856
Drive shared-drive-2 ch_drv_02 Apr 10 312
Admin directory ch_adm_01 Apr 08 47
Gmail [email protected] ch_gml_01 Mar 28 203
Delivery Stats (7 days):
Total events: 10,794
Delivered: 10,781 (99.88%)
Failed: 13 (0.12%)
Avg latency: 1.2 seconds
Expiring soon: ch_gml_01 (13 days remaining)
Core Concepts
Event Management Overview
| Aspect | Details |
|---|---|
| Subscriptions | Create, list, renew, and delete event watch channels across services |
| Routing | Direct events to different webhooks based on service, type, or content |
| Audit | Track delivery history, failure rates, latency metrics, and quota usage |
| Bulk Operations | Manage multiple subscriptions simultaneously: renew-all, pause, resume |
| Alerting | Get notified when subscriptions approach expiration or delivery fails |
Event Pipeline Workflow
Source Services
| | | |
v v v v
Cal Drive Admin Gmail
| | | |
v v v v
Event Router
(filters + transforms)
|
+----> Webhook A (high priority)
|
+----> Webhook B (batch delivery)
|
+----> Dead Letter Queue
(failed deliveries)
Configuration
| Parameter | Type | Default | Description |
|---|---|---|---|
| action | string | (required) | Operation: list, create, renew, delete, audit, renew-all |
| service | string | all | Target service: calendar, drive, admin, gmail, or all |
| days | integer | 7 | Audit period for delivery statistics |
| webhook | string | (none) | Webhook URL for new subscriptions or routing changes |
| alert-days | integer | 7 | Days before expiration to trigger renewal alerts |
Best Practices
-
Audit weekly - Run the audit action weekly to monitor delivery health. A gradual increase in failure rate often indicates webhook endpoint degradation before it causes a full outage.
-
Set up renewal alerts - Configure alert-days to get warned well before subscriptions expire. Production integrations should renew at least a week before expiration.
-
Use separate webhooks per service - Routing Calendar and Drive events to the same webhook makes debugging harder. Dedicate webhook endpoints per service for clearer separation.
-
Monitor quota usage - Google imposes limits on the number of active watch channels. The audit action shows quota consumption so you can plan capacity accordingly.
Common Issues
-
Renew-all fails for some subscriptions - Subscriptions from different services may have different renewal requirements. Check the error details and renew failed channels individually.
-
High failure rate on specific webhook - Network issues or endpoint downtime causes delivery failures. Google retries with exponential backoff, but prolonged failures cause the channel to be suspended.
-
Event latency spikes during peak hours - Google Workspace event delivery can experience latency during high-traffic periods. Design your consumers to handle delayed events gracefully.
Reviews
No reviews yet. Be the first to review this template!
Similar Templates
Git Commit Message Generator
Generates well-structured conventional commit messages by analyzing staged changes. Follows Conventional Commits spec with scope detection.
React Component Scaffolder
Scaffolds a complete React component with TypeScript types, Tailwind styles, Storybook stories, and unit tests. Follows project conventions automatically.
CI/CD Pipeline Generator
Generates GitHub Actions workflows for CI/CD including linting, testing, building, and deploying. Detects project stack automatically.