Compliance and debugging both need logs. nylas audit logs enable handles the enable audit logging. records all cli activity to a local log file for compliance and debugging.
The nylas audit logs enable command activates audit logging, recording every CLI action — email sends, calendar reads, auth changes — to a local file. By default logs are written to ~/.
Quick Start
brew install nylas/nylas-cli/nylas
nylas init
nylas audit logs enable
Syntax
nylas audit logs enable [--output PATH]
How It Works
Every entry in the audit log captures: the exact command, all arguments (with secrets redacted), the invoker identity (human or AI agent name), the exit code, and a nanosecond timestamp. This level of detail is what compliance auditors expect.
Key Flags
Run nylas audit logs enable --help to see all available flags. Add --json for machine-readable output — useful when piping into jq or feeding data to scripts.
nylas audit logs enable --help
Examples
Enable audit logging to default location:
nylas audit logs enable
Enable logging to a custom file:
nylas audit logs enable --output /var/log/nylas-audit.log
Related Commands
-
nylas audit init— Initialize audit logging for the Nylas CLI. Creates the log directory, default c -
nylas audit logs show— View and filter audit log entries. Supports filtering by date range, command, st -
nylas audit logs summary— View summary statistics of audit log entries including command counts, error rat -
nylas audit logs clear— Clear all audit log entries. This is a destructive action — consider exporting l
Full docs: nylas audit logs enable 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)