@emit-vision/cli
v0.2.5
Published
CLI for Emit Vision — query telemetry, manage projects and ingest keys, and control feature flags from the terminal.
Maintainers
Readme
@emit-vision/cli
Command-line interface for Emit Vision — the self-hostable analytics, error tracking, and feature-flag stack.
Query telemetry, manage projects and ingest keys, and control feature flags from your terminal, a deploy script, or a coding agent.
Installation
npm install -g @emit-vision/cli
# or: pnpm add -g @emit-vision/cliAuthentication
Log in once — credentials are stored locally and reused by every command.
emit-vision login --browser # browser OAuth
emit-vision login --token <pat> # non-interactive (or set EMIT_VISION_PAT)
emit-vision status # verify the stored tokenPoint at a self-hosted instance with --api-url:
emit-vision login --token <pat> --api-url https://api.your-host.comFeature flags
emit-vision flags list <projectId>
emit-vision flags enable <projectId> compare-pages
emit-vision flags rollout <projectId> new-checkout 25
emit-vision flags create <projectId> dark-mode --name "Dark Mode"
emit-vision flags evaluate <projectId> --environment productionFlags are referenced by their key, not an internal id. Creating, updating, enabling, disabling, and archiving require a token with the admin role; listing and evaluating do not.
For multivariate flags, pipe a full definition in:
cat flag.json | emit-vision flags create <projectId> --from-json -Querying telemetry
emit-vision overview <projectId>
emit-vision events recent <projectId> --limit 20
emit-vision errors grouped <projectId> --environment production
emit-vision logs <projectId> --severity errorMost commands accept --from/--to (ISO timestamps), --environment, --limit, and --json.
Projects and keys
emit-vision project list
emit-vision project create "My App"
emit-vision key get <projectId>
emit-vision key rotate <projectId> --yesScripting and agents
Every read command supports --json, so output pipes cleanly into jq or an agent's tool loop:
# Top error groups as JSON
emit-vision errors grouped <projectId> --json | jq '.[0:5]'
# Gate a deploy step on a flag
if [ "$(emit-vision flags evaluate <projectId> --environment production --flag safe-deploy --json | jq -r '."safe-deploy".variantValue')" = "true" ]; then
./deploy.sh
fiDestructive commands (key rotate, flags archive) prompt for confirmation and
require --yes to run non-interactively — they fail rather than prompt when
stdin isn't a TTY, so a script can't hang waiting on input.
Run emit-vision --help for the complete command list, or emit-vision --version.
Documentation
- CLI reference — every command, flag, and example
- Getting started
- Installation & configuration
- Browser SDK · Node SDK
- Changelog
- Troubleshooting
License
MIT
