CLI reference
Every command and subcommand of the OpenLatch client.
openlatch init
openlatch setup
Installs the hooks of the agents found on this machine, starts the daemon and checks that it answers. Safe to run again: it frees the client's ports first, then confirms that the daemon it started is the one serving.
openlatch status
Shows the daemon's state, its uptime and event counts, the health of each part of the client, and the license line: its state, hosts, fair use and contract end.
openlatch start
Starts the daemon. Refuses with OL-1501 when a daemon already runs on this machine.
openlatch stop
Stops the daemon. It also removes the agents' model relay wiring, and says so.
openlatch restart
Stops the daemon and starts it again, for example to apply a configuration change.
openlatch logs
Shows the client's event log.
openlatch doctor
Diagnoses the client's configuration and connectivity, and gives the cause and the remedy of every problem it finds. --fix applies the repairs it can, --restore undoes them, and --rescue writes a diagnostic file for support.
openlatch uninstall
Removes the agents' hooks and stops the daemon. --agent limits it to the agents you name.
openlatch docs
Opens the documentation in your browser.
openlatch system
Groups the commands that inspect or control one part of the client: aip, auth, hooks, model-relay, proxy, supervision, telemetry and inventory. Every remedy openlatch doctor gives names the exact system command to run.
openlatch system aip
Fetches and inspects the policy bundle resident on this machine, which holds the Autonomy Zone rules the client enforces.
openlatch system aip refresh
openlatch system aip update
Makes the running daemon fetch the policy bundle now, and waits up to 15 seconds for the result: changed, unchanged, pending, refused or offline, with the facts of the bundle in use. A pending result exits with code 7; a refusal or an offline daemon exits with code 1.
openlatch system auth
Groups the commands that connect the client to the platform.
openlatch system auth login
Signs the client in to the platform through your browser and stores the credential in the operating system's keychain.
openlatch system auth logout
Signs the client out and removes the stored credential.
openlatch system auth status
Shows whether the client is signed in, and where its credential comes from.
openlatch system auth switch
Moves this machine to another of your organizations.
openlatch system hooks
Groups the commands that manage agent hooks. system hooks install is the same as openlatch init.
openlatch system hooks install
Installs the agents' hooks; the same as openlatch init.
openlatch system hooks uninstall
Removes the agents' hooks; the same as openlatch uninstall.
openlatch system hooks status
Shows the hooks installed for each agent, in detail.
openlatch system model-relay
Groups the commands that inspect or switch the model relay, the local listener that records each agent's model calls.
openlatch system model-relay status
Reports whether the model relay is up, its port, and whether each agent's model calls go through it. An agent whose hooks work but whose model calls are not recorded reads as enforced, not measured.
openlatch system model-relay enable
Turns the model relay on in the configuration, then offers to restart the daemon to apply it.
openlatch system model-relay disable
Turns the model relay off in the configuration, then offers to restart the daemon to apply it.
openlatch system model-relay explain
Prints a model relay record by its id, read from local storage. Its content never leaves the machine.
openlatch system proxy
Groups the commands that inspect, discover, set or test the proxy every outbound request takes.
openlatch system proxy status
Shows the route outbound requests take, for the CLI and, when it differs, for the daemon.
openlatch system proxy discover
Runs the operating system's proxy discovery again, tests each candidate and keeps the one that works.
openlatch system proxy set
Sets the proxy by hand. A proxy set this way is never replaced by discovery or automatic repair.
openlatch system proxy clear
Removes the proxy and its credential, so requests go directly to their destination.
openlatch system proxy test
Tests the route step by step: the proxy connection, TLS, HTTP and a streamed response.
openlatch system supervision
Groups the commands that manage the operating-system supervisor (launchd, systemd or Task Scheduler) that starts the daemon at login and restarts it. Everything stays at user scope.
openlatch system supervision install
Installs the operating-system supervisor, so the daemon starts at login and after a reboot.
openlatch system supervision uninstall
Removes the operating-system supervisor. The daemon keeps running but no longer starts on its own.
openlatch system supervision status
Shows whether the supervisor is installed and running, and which one this system uses.
openlatch system supervision enable
Turns supervision back on after disable, and installs the supervisor again.
openlatch system supervision disable
Removes the supervisor and records that supervision is off on this machine.
openlatch system telemetry
Groups the commands that manage usage telemetry, which you can turn off.
openlatch system telemetry status
Shows whether usage telemetry is on, which setting decides it, and whether this build includes it.
openlatch system telemetry enable
Turns usage telemetry on.
openlatch system telemetry disable
Turns usage telemetry off.
openlatch system telemetry purge
Turns usage telemetry off and empties the queue of unsent events in a running daemon.
openlatch system telemetry debug
Shows how to run any command so it prints the telemetry events it would send.
openlatch system inventory
Groups the commands that inspect the configuration plane: the agent configuration sources the client watches, their change events, rescans and the watcher's health.
openlatch system inventory list
Lists the configuration sources the client watches, from the local audit log.
openlatch system inventory log
Shows the configuration change events in the local audit log.
openlatch system inventory rescan
Rescans every watched configuration source now.
openlatch system inventory status
Reports the configuration watcher's health: whether it is on, whether its list of sources loaded, and how many sources it holds.
openlatch system inventory inspect
Shows one configuration source in detail: its current fingerprint and its pending alerts.
openlatch system inventory projects
Lists the project folders the client knows from the configuration files it watches.
openlatch system inventory ack
Acknowledges a pending configuration alert, so the agent is no longer reminded of it.
openlatch update
Checks for a new client version. On a terminal, it then asks whether to install it, and installs it if you accept. Without a terminal (a script, a pipe, a management tool), it only reports the release. --yes installs without asking; --check only checks.
Error codes
Every code the client can print, with what happened and what to do.
- OL-1002 — Event is too large
- OL-1003 — Duplicate event ignored
- OL-1100 — Custom pattern does not compile
- OL-1200 — Platform is unreachable
- OL-1201 — Platform rejected the credential
- OL-1202 — Platform rate limit reached
- OL-1204 — Outbox write failed
- OL-1205 — Outbox only partly sent
- OL-1206 — Platform channel is congested
- OL-1207 — Outbox entry set aside
- OL-1208 — Retained event expired
- OL-1210 — Policy bundle fetch failed
- OL-1211 — Policy bundle failed verification
- OL-1212 — Policy bundle cannot be used
- OL-1213 — Policy bundle refresh is overdue
- OL-1214 — One rule in the bundle was set aside
- OL-1215 — Local policy is switched off
- OL-1216 — New version cannot read the policy cache
- OL-1220 — No route to the platform
- OL-1221 — Proxy is unreachable
- OL-1222 — Proxy rejected the credential
- OL-1223 — Proxy scheme is not supported
- OL-1224 — TLS certificate not trusted
- OL-1225 — Proxy auto-config is unavailable
- OL-1226 — Proxy configuration is invalid
- OL-1227 — Direct connection not allowed
- OL-1228 — Proxy buffers streamed responses
- OL-1229 — No Kerberos ticket for the proxy
- OL-1240 — Evaluation input row is malformed
- OL-1241 — Evaluation bundle was rejected
- OL-1242 — No bundle to evaluate against
- OL-1243 — Session state does not match the bundle
- OL-1244 — Evaluation failed on one row
- OL-1250 — Platform paused ingest for licensing
- OL-1300 — Configuration value is invalid
- OL-1301 — Required configuration field is missing
- OL-1302 — Configuration changed but not applied
- OL-1400 — No supported agent found
- OL-1401 — Agent settings cannot be written
- OL-1402 — Agent settings file cannot be parsed
- OL-1403 — Other hooks found in agent settings
- OL-1404 — Hook binary cannot be installed
- OL-1405 — Hooks installed but not running
- OL-1406 — Agent TOML config cannot be parsed
- OL-1407 — Selected agent cannot take hooks
- OL-1408 — Expected Cline component is missing
- OL-1409 — Cline component state is unknown
- OL-1410 — Cline actions cannot be refused
- OL-1411 — Cline.app model calls not captured
- OL-1412 — OpenLatch plugin not loaded in Cline
- OL-1413 — Cursor hooks file has an unknown format
- OL-1414 — Cursor install cannot be confirmed
- OL-1415 — Cursor hook cannot reach the daemon
- OL-1416 — Some agents left without a daemon
- OL-1417 — Agent plugin waiting for its first load
- OL-1418 — Another file holds the plugin path
- OL-1419 — Agent version below the supported floor
- OL-1420 — Agent component state is unknown
- OL-1421 — Agent plugin cannot reach the daemon
- OL-1422 — Agent plugin did not load
- OL-1423 — Agent relay not yet proven
- OL-1424 — Agent surface not covered by the relay
- OL-1425 — Agent command-line tool bypasses the relay
- OL-1500 — Port already in use
- OL-1501 — Daemon already running
- OL-1502 — Daemon did not become healthy
- OL-1503 — Newer client version available
- OL-1504 — Update could not be applied
- OL-1505 — Built from source, cannot self-update
- OL-1506 — Daemon did not answer the update
- OL-1507 — Daemon could not be stopped
- OL-1510 — Part of the daemon restarted
- OL-1511 — Part of the daemon keeps failing
- OL-1512 — Daemon is degraded
- OL-1513 — Nothing restarts the daemon
- OL-1600 — No credential found
- OL-1601 — Credential expired
- OL-1602 — Keychain is unavailable
- OL-1603 — Keychain denied access
- OL-1604 — Encrypted credential file failed
- OL-1605 — Sign-in timed out
- OL-1606 — Sign-in failed
- OL-1607 — Key revocation failed at sign-out
- OL-1608 — Organization must be chosen
- OL-1609 — Organization picker left unanswered
- OL-1610 — Organization not found
- OL-1611 — Organization name is ambiguous
- OL-1612 — API key belongs to another organization
- OL-1613 — Organization could not be confirmed
- OL-1614 — Machine is enrolled in another organization
- OL-1615 — Organization switch not applied
- OL-1616 — Switch refused: the key comes from the environment
- OL-1617 — Sign-in code expired
- OL-1618 — Account has no organization
- OL-1619 — Organization is unavailable
- OL-1620 — Too many sign-ins in progress
- OL-1700 — Telemetry consent file is corrupt
- OL-1701 — Telemetry consent file cannot be written
- OL-1702 — Telemetry batch not sent
- OL-1703 — Telemetry could not start
- OL-1704 — Telemetry hand-off refused
- OL-1800 — Doctor repair journal is corrupt
- OL-1801 — Nothing to restore
- OL-1802 — Diagnostic file cannot be written
- OL-1803 — Diagnostic file is incomplete
- OL-1900 — Hook integrity key unavailable
- OL-1901 — Hook state file is corrupt
- OL-1902 — Hook state file cannot be written
- OL-1903 — Hook marker version not supported
- OL-1904 — Hook entry could not be processed
- OL-1905 — Older hook marker upgraded
- OL-1906 — Changed hooks were repaired
- OL-1910 — Settings file cannot be replaced
- OL-1911 — Settings file link cannot be resolved
- OL-1950 — Supervision not supported on this system
- OL-1951 — Supervisor could not be installed
- OL-1952 — Supervisor could not be registered
- OL-1953 — Supervisor refused a command
- OL-2000 — Configuration watcher could not start
- OL-2001 — Configuration source list not found
- OL-2002 — Configuration source list is invalid
- OL-2003 — Watched path cannot be expanded
- OL-2004 — One path cannot be watched
- OL-2005 — Configuration file could not be fingerprinted
- OL-2006 — Configuration rescan was partial
- OL-2007 — Session start details unavailable
- OL-2008 — Configuration watching is off
- OL-9999 — Unexpected internal error
- OL-RELAY-CA — Model relay certificate not trusted
- OL-RELAY-CURSOR-UNPROVEN — Cursor relay not yet proven
- OL-RELAY-CURSOR-UNSUPPORTED — Cursor surface not covered by the relay
- OL-RELAY-DOWN — Model relay is not running
- OL-RELAY-FOREIGN — Another process holds the relay port
- OL-RELAY-IO — Model relay input or output error
- OL-RELAY-MISCONFIG — Relay setting is overridden
- OL-RELAY-NEXTSTART — Relay applies at the editor's next start
- OL-RELAY-NOFIND — No local record for this id
- OL-RELAY-PORT — Model relay port is in use
- OL-RELAY-PORTS — No relay port for a provider
- OL-RELAY-PREFLIGHT — Model relay could not reach the provider
- OL-RELAY-PROVIDER — Agent config holds another provider entry
- OL-RELAY-SERVE — Model relay stopped on an error
- OL-RELAY-SETTINGS — Agent settings hold your own proxy
- OL-RELAY-STATEFILE — Agent state file cannot be edited safely
- OL-RELAY-TRUSTPROOF — Relay trust not yet proven here
- OL-RELAY-UNCOVERED — Provider not carried by the relay