Command
nylas audit logs enable
Enable audit logging. Records all CLI activity to a local log file for compliance and debugging.
Written by Qasim Muhammad Staff SRE
What does nylas audit logs enable do?
The nylas audit logs enable command activates audit logging, recording every CLI action — email sends, calendar reads, auth changes — to a local audit log. Log entries include timestamps, commands, grant IDs, and response codes. Logging stays on until you run nylas audit logs disable; review activity with nylas audit logs show and check state with nylas audit logs status.
Usage
nylas audit logs enableFlags
| Flag | Description |
|---|---|
| --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 audit logs enable command activates audit logging, recording every CLI action — email sends, calendar reads, auth changes — to a local audit log.
Enable audit logging
nylas audit logs enableEnable logging, then review recent activity
nylas audit logs enable
nylas audit logs showExample output
✓ Audit logging enabled
Command execution history is now being recorded.Troubleshooting
Audit log appears empty after enabling
Logging only captures actions taken after it is enabled. Run a command (e.g. nylas email list), then check nylas audit logs show.
Confirm whether logging is active
Run nylas audit logs status to see whether audit logging is currently enabled, and nylas audit logs summary for statistics.
Recommended guides
Thunderbird vs Nylas: GUI vs CLI email
Thunderbird is a desktop GUI email client with OAuth and calendar built in. Compare it to a scriptable, headless CLI for servers, cron jobs, and AI agents.
Pipedream vs Nylas for Email Automation
Pipedream wires 3,000+ apps with event workflows and code steps. Nylas is a native email API with a CLI for agents and cron. Compare as a Pipedream alternative.
Detect Calendar Conflicts from the CLI
Spot double-booked meetings and overlapping events from the terminal. AI conflict detection and jq scripts catch calendar conflicts before they derail your day.
Block Focus Time on Your Calendar (CLI)
Context-switching costs 23 minutes of focus per interruption. Block focus time on Google Calendar from your terminal so meetings can't eat your deep-work slots.
Build a Strands Email Agent
Give a Strands Agents SDK agent email access using the Nylas CLI as a @tool. One function reaches Gmail, Outlook, and 4 more providers — no OAuth code needed.
Cloudflare Agents Email Tools
Use the Cloudflare Agents SDK to build a stateful email agent on Workers — connect to the Nylas MCP server over HTTP and call email tools in TypeScript.
Run nylas audit logs enable --help for full help output.