openclaw webhooks
Webhook helpers and integrations. Today this surface is scoped to Gmail Pub/Sub flows built on the bundled gog watcher.
Subcommands
The Gateway also auto-starts
gog gmail watch serve on boot once hooks.enabled=true and hooks.gmail.account is set (set by gmail setup). gmail run is the same logic in the foreground, useful for debugging or when the Gateway watcher is disabled. See Gmail Pub/Sub integration for the auto-start details and OPENCLAW_SKIP_GMAIL_WATCHER opt-out.webhooks gmail setup
gcloud and gog if missing, authenticates gcloud, creates the Pub/Sub topic and subscription, starts the Gmail watch, and writes hooks.gmail config with hooks.enabled=true. Prints Next: openclaw webhooks gmail run.
Required
Pub/Sub options
OpenClaw delivery options
gog watch serve options
Tailscale exposure
Output
webhooks gmail run
gog watch serve plus the watch auto-renew loop in the foreground, restarting gog watch serve after a 2s delay if it exits unexpectedly.
run accepts the same Pub/Sub, OpenClaw delivery, gog watch serve, and Tailscale flags as setup, except:
--accountis optional onrun; it falls back tohooks.gmail.account.rundoes not accept--project,--push-endpoint, or--json.- Every flag falls back to the matching
hooks.gmail.*config value (written bysetup), then to the same built-in defaultsetupuses, with one exception:--tailscaledefaults tooffonrun(notfunnel) when neither the flag norhooks.gmail.tailscale.modeis set.
For
run, the --topic value is the full Pub/Sub topic path (projects/.../topics/...), not just the short topic name.