Webhooks fire when email arrives, events change, or contacts update. nylas webhook update helps you update an existing webhook's url or triggers.
The nylas webhook update command modifies a webhook destination. Change the delivery URL with --url, or add and remove trigger types with --triggers.
Syntax
nylas webhook update --id WEBHOOK_ID [--url URL] [--triggers TRIGGERS]
How It Works
Webhooks replace polling. Instead of checking every 30 seconds whether new email arrived, the webhook pushes the event to your endpoint within seconds. This reduces API calls and improves latency for your application.
Examples
Change the webhook URL:
nylas webhook update --id wh_abc123def456 --url https://new-endpoint.example.com/webhook
Add a trigger type:
nylas webhook update --id wh_abc123def456 --triggers message.created,event.created,event.updated
Key Flags
Run nylas webhook update --help to see all available flags. Add --json for machine-readable output — useful when piping into jq or feeding data to scripts.
nylas webhook update --help
Common Issues
Webhook not found
Run nylas webhook list to confirm the webhook ID. It may have been deleted.
Invalid trigger type
Run nylas webhook triggers to see valid types. Trigger names are case-sensitive.
Full docs: nylas webhook update reference — all flags, advanced examples, and troubleshooting.
All commands: Nylas CLI Command Reference
Get started: brew install nylas/nylas-cli/nylas — other install methods
Top comments (0)