Installation
- npm
- Homebrew
- Binary Download
Quick Start
Get your API key
Go to Settings > MCP Integration in the Outlit dashboard. Click Generate API Key, copy it, and keep it safe.
Authenticate
~/.config/outlit/credentials.json with 0600 permissions.You can also pass the key directly:Set up AI agents (optional)
Configure all detected AI agents with one command:Or target a specific agent (Cursor, Claude Code, Claude Desktop, VS Code, Gemini, OpenClaw):See AI Agent Setup for the full list of supported agents.
Authentication
The CLI resolves your API key from the following sources, in order:| Priority | Source | How to set |
|---|---|---|
| 1 | --api-key flag | outlit customers list --api-key ok_... |
| 2 | OUTLIT_API_KEY env var | export OUTLIT_API_KEY=ok_... |
| 3 | Config file | outlit auth login |
Auth Commands
auth status makes a live API call to validate your key:
auth whoami validates your key and outputs a single line in TTY mode — useful for scripting:
Available Commands
| Command | Description |
|---|---|
customers list | Filter and list customers by billing status, MRR, activity |
customers get | Get a detailed customer profile with optional sections (users, revenue, etc.) |
customers timeline | View activity timeline filtered by channel and event type |
users list | Filter and list users by journey stage, activity, customer |
facts | Retrieve AI-generated facts and signals for a customer |
search | Natural language search across customer context |
sql | Run SQL queries against analytics tables |
schema | Discover database tables and columns |
setup | Configure AI agent MCP integrations |
doctor | Run environment diagnostics |
completions | Generate shell completion scripts |
Output Modes
The CLI has two output modes: interactive (tables, spinners, colors) and JSON (machine-readable). JSON mode activates automatically when:- stdout is piped (
outlit customers list | jq) --jsonflag is passed- Running in CI (
CI=trueorGITHUB_ACTIONSis set) - Terminal is dumb (
TERM=dumb)
AI agents like Claude Code and Cursor run commands with piped stdout, so they automatically receive JSON output — no
--json flag needed.