Working with nylas contacts list: List all contacts from your address book
Source: Dev.to
Overview
Your address book shouldn’t require a web browser to access. nylas contacts list brings it to the terminal.
The nylas contacts list command displays contacts from your connected address book. Use --limit to control how many contacts are returned.
Syntax
nylas contacts list [--limit N] [--json]
Examples
List first 20 contacts
nylas contacts list --limit 20
Export all contacts as JSON
nylas contacts list --json > contacts-backup.json
Count total contacts
nylas contacts list --json | jq length
Tips
- CI/CD ready: This command works in non‑interactive mode. Set
NYLAS_API_KEYas an environment variable and it picks up credentials automatically. - Pipe to jq:
nylas contacts list --json | jq '.'gives you structured data you can filter and transform.
How It Works
Contact data spans multiple providers and formats. Google Contacts uses its own People API, Outlook uses Microsoft Graph, and Exchange uses EWS. The CLI gives you a single interface across all of them.