Configuration
Configure the Enrich Layer CLI with settings, environment variables, and shell completions.
Environment variables
| Variable | Description |
|---|---|
ENRICHLAYER_API_KEY | API key (overrides stored credentials) |
When set, this variable takes priority over the key stored by el login.
API key resolution order
When running any command, the CLI resolves your API key in this order:
-t, --token <key>(or its alias--api-key <key>) passed on the command lineENRICHLAYER_API_KEYenvironment variable- Stored credentials at
~/.config/enrichlayer/credentials.json
Credentials storage
After el login, your API key is stored at:
~/.config/enrichlayer/credentials.jsonTo remove stored credentials:
el logoutSettings
View and modify CLI settings:
el config list # Show all settings
el config path # Show config directory path
el config get <key> # Read a single setting
el config set <key> <value> # Write a setting
el config unset <key> # Remove a settingShell completions
Enable tab completion for commands, options, and arguments.
Bash
echo 'eval "$(el completion bash)"' >> ~/.bashrc
source ~/.bashrcZsh
echo 'eval "$(el completion zsh)"' >> ~/.zshrc
source ~/.zshrcFish
el completion fish > ~/.config/fish/completions/el.fishBatch processing
The profile and company commands accept batch input natively — no need to write a shell loop.
# Read URLs from a file (one per line, blank lines and #-comments are skipped)
el profile --file urls.txt --jsonl > profiles.jsonl
# Read URLs from standard input
cat urls.txt | el profile --stdin --jsonl
# Combine with --output and --fields
el profile --file urls.txt --jsonl --fields full_name,headline -o results.jsonl| Flag | Description |
|---|---|
--file <path> | Read one URL per line from a file |
--stdin | Read URLs from standard input |
--jsonl | Stream JSON Lines (one object per line) |
Errors in batch mode are emitted as JSON Lines with "error": true, so a single failure never interrupts the stream. Successful rows come through as normal profile objects.
Output behavior
- In an interactive terminal, commands print a formatted summary card.
- When output is piped to another command or redirected to a file, the CLI switches to full JSON automatically so tools like
jqwork without extra flags. -q, --quietsuppresses informational messages; only the data is printed.--no-colordisables colored output for logs or CI.
Exit codes
| Code | Meaning |
|---|---|
0 | Success |
1 | Any error (authentication failure, API error, invalid input, rate limit exhaustion) |
The CLI currently uses a single non-zero exit code. For fine-grained error handling in scripts, parse the JSON error body from stderr or use --json and check the response shape.