gws-gmail-watch

Stream Gmail messages as NDJSON to Pub/Sub or local directories.

Updated Aug 23, 2026
One-click install
npx skills add https://github.com/nomad3/servicetsunami-agents --skill gws-gmail-watch-nomad3
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: gws-gmail-watch
Source: https://github.com/nomad3/servicetsunami-agents/tree/main/apps/api/app/skills/community/gws_gmail_watch
Command: npx skills add https://github.com/nomad3/servicetsunami-agents --skill gws-gmail-watch-nomad3

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Gmail emails arrive in silos, making real-time automation difficult. This Skill streams new Gmail messages as NDJSON for seamless ingestion into downstream workflows.

Core Features & Use Cases

  • Watch Gmail for new messages and emit them as NDJSON for easy processing.
  • Route messages to Pub/Sub or write per-message records to a local directory for archival and analysis.
  • Use in automation pipelines to trigger workflows when new emails arrive, enabling event-driven processes.

Quick Start

Run gws gmail +watch with your project, topic, and optional filters to start streaming new emails as NDJSON.

Frequently Asked Questions about gws-gmail-watch

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I stream new Gmail messages as NDJSON for real-time automation?

To stream new Gmail messages as NDJSON, you run the watch command with your project and topic configurations. This emits incoming emails as structured NDJSON records for seamless ingestion into downstream automation pipelines.

What do I need to watch Gmail for new emails and route them to Pub/Sub?

You need the gws CLI and Gmail API access to watch Gmail and route messages to Pub/Sub. Configurable options like --project, --subscription, and --topic let you define the streaming pipeline parameters.

Can I filter Gmail emails by label when streaming events as NDJSON?

Yes, you can filter Gmail emails during streaming by using the --label-ids option. This ensures only messages matching your specified labels are emitted as NDJSON records to your downstream workflows.

How does NDJSON streaming work for Gmail event ingestion?

NDJSON streaming for Gmail ingestion works by emitting each new email event as a separate JSON line. This format allows downstream processes to consume and route messages to Pub/Sub or data stores in real time without loading the entire batch.

What is the best way to archive Gmail messages locally for analysis?

The best way to archive Gmail messages locally is using the --output-dir option. This writes per-message NDJSON records to a local directory, enabling offline analysis and archival of your email events.

Are there limits on Gmail message streaming when using poll intervals?

You can control Gmail message streaming volume using the --max-messages and --poll-interval options. These settings configure how frequently the system checks for new emails and how many events to process during each polling cycle.