Why a CLI?
The Monitoring Portal is great when you're learning, or when you need visual context — a video feed, a site map, an event timeline. But for experienced operators handling dozens of events per shift, clicks are the bottleneck.
The Operator CLI lets you drive every monitoring action from your keyboard, pipe results into other tools, and script repetitive workflows. The CLI is also the fastest way for an AI agent to operate CHeKT — every command is documented, every output is machine-parsable.
Install opcli
opcli ships as a single static binary for macOS, Linux, and Windows. No runtime dependencies. Pick your preferred installer:
# macOS / Linux (Homebrew)
brew install chekt/tap/opcli
# Windows (Scoop)
scoop install opcli
# Or grab a static binary
curl -sSL https://get.chekt.com/cli | shFirst-run setup
On first launch, log in via OAuth. The CLI opens your browser, completes the handshake with dealer.chekt.com, and stores a short-lived token in your OS keyring.
# Authenticate (opens browser, completes OAuth on dealer.chekt.com)
opcli login
# Verify your identity
opcli whoami
# → josh@dealer-co.com · East Bay Monitoring · opcli 1.0.0
# Quick smoke test
opcli alarms --activeAnatomy of an opcli command
Every command follows the same shape: opcli <noun> [<id>] <verb> [flags]. The grammar is deliberate — once you learn the verbs, every noun follows the same pattern.
verb- What to do. Examples: list, get, acknowledge, dispatch, watch.
noun- The resource. Examples: alarms, sites, devices, cameras, incidents.
filter flags- --active, --site, --priority, --status — narrow the result set.
output format- --json or --table (default). JSON output is stable and pipe-friendly.
Common commands
The ten commands operators reach for daily — covers ~90% of shift work.
opcli alarms --activeList active alarms in real-time table view.opcli alarms --site 'East Bay'Filter alarms by site name or ID.opcli alarm A-10293 detailShow full alarm details with events, video, history.opcli alarm A-10293 acknowledgeAcknowledge a specific alarm.opcli alarm A-10293 acknowledge --reason 'false-positive'Acknowledge with an audit-logged reason.opcli dispatch guard --to 'Main Entrance'Dispatch a responder to a location.opcli camera 'Main Entrance' --liveOpen a live camera feed (uses mpv on Unix).opcli incidents --todayToday's incidents grouped by site.opcli sites list --status armedList sites currently armed.opcli audit --operator $USER --since 24hPull the operator action audit log.The Detect → Notify → Act → Resolve loop
Every operator workflow follows the same loop, and opcli is designed around it. Here's the loop in five steps with the actors involved.
- 01CHeKTopcliDetectAlarm fires in Central Station
- 02opcliOperatorNotifyReal-time row in opcli watch terminal
- 03OperatoropcliActAcknowledge / dispatch / escalate
- 04opcliCHeKTApplyAPI call with audit trail
- 05CHeKTOperatorResolveIncident closed. Logged.
Watching in real time
opcli watch streams every event from your sites in a live-updating table — like top(1) for alarms. Most ops teams keep one terminal tab open with opcli watch --active all shift long.
Pipe-friendly by design
Every command supports --json, which emits a stable, documented JSON structure on stdout. This makes opcli a first-class citizen in any Unix pipeline.
# Acknowledge every motion alarm from one flaky sensor in a single pipe
opcli alarms --device dev_8h2j3kfm --status new --json \
| jq -r '.[] | .id' \
| xargs -I{} opcli alarm {} acknowledge --reason "sensor recalibration"
# Export today's incidents as CSV for a compliance report
opcli incidents --today --json \
| jq -r '.[] | [.id, .site, .priority, .status] | @csv' \
> incidents.csvScripting opcli
Bash, Python, Zig — anything that can spawn a process and read stdout works. Here's a script most ops teams run at start-of-shift to triage overnight events.
1#!/usr/bin/env bash
2# nightly-health.sh — run every morning at start-of-shift
3set -euo pipefail
4
5echo "== Devices offline overnight =="
6opcli devices --status offline --since 12h --json \
7 | jq -r '.[] | "\(.site_name): \(.name) — offline since \(.last_seen_at)"'
8
9echo
10echo "== Unacknowledged high-priority alarms =="
11opcli alarms --status new --priority high --json \
12 | jq -r '.[] | "[\(.id)] \(.site_name): \(.alarm_type)"'opcli + AI agents
The CLI ships with an --mcp flag that exposes every command as an MCP tool. Drop the binary into Claude Desktop, ChatGPT desktop, or your own agent loop — and an LLM can drive CHeKT the same way an operator does.
See the MCP page for setup, or the production workflows guide for real examples.