Source: https://cli.nylas.com/docs/commands/webhook-pubsub-create

# nylas webhook pubsub create

Create a Pub/Sub channel

Written by [Qasim Muhammad](https://cli.nylas.com/authors/qasim-muhammad) Staff SRE

Published February 13, 2026

Updated June 21, 2026

## What does nylas webhook pubsub create do?

The nylas webhook pubsub create command creates a Pub/Sub channel. It is part of the Webhooks commands, which create and manage webhooks for real-time event notifications.

## Usage

```bash
nylas webhook pubsub create
```

## Flags

| Flag | Description |
| --- | --- |
| --description string | Channel description |
| --encryption-key string | Optional encryption key identifier |
| --notify stringSlice(-n) | Notification email addresses |
| --topic string | Google Cloud Pub/Sub topic path (required) |
| --triggers stringSlice(-t) | Trigger types (required, comma-separated or repeated) |
| --json | Output as JSON |
| --no-color | Disable color output |
| --verbose(-v) | Enable verbose output |
| --config | Custom config file path |
| --help(-h) | Show help for the command |
| --limit | Limit results (most list commands) |
| --yes(-y) | Skip confirmations |

## Examples

The nylas webhook pubsub create command creates a Pub/Sub channel.

### JSON output for scripting

```bash
nylas webhook pubsub create --json
```

### Filter by description

```bash
nylas webhook pubsub create --description <value> --json
```

## Troubleshooting

### Command not found or fails

Run `nylas auth config` and `nylas auth login` to authenticate first.

## Related commands

[nylas webhook createCreate a webhook for real-time event notifications.](https://cli.nylas.com/docs/commands/webhook-create)

[nylas webhook deleteDelete an existing webhook by ID.](https://cli.nylas.com/docs/commands/webhook-delete)

[nylas webhook listList all webhooks.](https://cli.nylas.com/docs/commands/webhook-list)

[nylas webhook pubsub deleteDelete a Pub/Sub channel](https://cli.nylas.com/docs/commands/webhook-pubsub-delete)

[nylas webhook pubsub listList Pub/Sub channels](https://cli.nylas.com/docs/commands/webhook-pubsub-list)

[nylas webhook pubsub showShow Pub/Sub channel details](https://cli.nylas.com/docs/commands/webhook-pubsub-show)

## Recommended guides

[Send OTP and 2FA Codes by EmailGenerate a cryptographically secure one-time code and send it by email from the terminal — no SMTP. Test the full round trip and learn email OTP's limits.](https://cli.nylas.com/guides/send-otp-email-cli)

[Email Prometheus Alerts without SMTPSend Prometheus Alertmanager alerts to email via a webhook receiver that runs nylas email send, instead of configuring Alertmanager's built-in SMTP relay.](https://cli.nylas.com/guides/prometheus-alertmanager-email)

[Send Sentry Issue Alerts by Email (CLI)Turn a Sentry issue alert webhook into an enriched email with nylas email send: parse the issue title, level, and permalink, then route by severity.](https://cli.nylas.com/guides/sentry-email-alerts-cli)

[Send Grafana Alert Emails without SMTPPoint a Grafana webhook contact point at a handler that runs nylas email send to route alert emails without configuring the built-in SMTP server.](https://cli.nylas.com/guides/grafana-alert-emails-cli)

[How to Evaluate an Email AI AgentEvaluate an email agent with a labeled test set, classification and action-accuracy metrics, and prompt-injection guardrail tests you run on every change.](https://cli.nylas.com/guides/evaluate-email-agents)

[Send Email to Discord with a Webhook (CLI)Post email to a Discord channel from the terminal. Pull messages as JSON with the Nylas CLI and POST them to a Discord webhook as rich embeds. No bot to host.](https://cli.nylas.com/guides/email-to-discord-notifications)

Run `nylas webhook pubsub create --help` for full help output.
