ZeusLock CLI command reference

Every ZeusLock CLI command in one page: what each one does, what it changes, every option and default, worked examples and exit codes.

Every ZeusLock CLI command, with what it does, what it changes, and what it returns. The CLI covers the same ground as the dashboard — incidents, agents, policies, users, keys, Shadow AI, MCP and SIEM — plus two things the dashboard cannot do: scan content from a terminal, and block a Git commit before secrets leave a laptop.

Install

Requires Node.js 22.12 or newer. The package is published as zeuslock-dlp-cli and installs a single executable named zeuslock.

npm install -g zeuslock-dlp-cli@latest
zeuslock --version
zeuslock --help

To run it once without installing: npm exec --package zeuslock-dlp-cli@latest -- zeuslock status.

Two credentials, on purpose

The CLI uses two different credentials, and picking the wrong one is the most common reason a command fails.

CredentialPrefixActs asUsed by
Personal CLI access tokenzlu_You, with your roleDashboard-data commands: incidents, agents, users, keys, tokens, policies, Shadow AI, MCP, extensions, deploy
Organization API keyzl_The organizationContent and machine commands: scan, anonymize, hook run, siem pull/tail, license check in status

A personal token is never accepted for content commands, and an organization key is never accepted for dashboard-data commands. That separation is deliberate: content commands run unattended in CI, where a credential tied to one person would break the moment that person leaves.

Getting a personal CLI access token

The CLI does not sign in with an email and password. The backend requires a reCAPTCHA challenge on login, which a terminal cannot complete. Generate a token from the CLI page in the dashboard, or from a machine that is already authenticated with zeuslock tokens create.

zeuslock auth login --token zlu_your_cli_access_token
zeuslock whoami

Saving the organization API key

zeuslock auth api-key set zl_your_org_api_key
zeuslock auth api-key status

Global options

OptionValuesDefaultWhat it does
--token <zlu_…>zlu_…noneUse this personal token for one invocation. Must appear before the subcommand: zeuslock --token zlu_… whoami.
-V, --version——Print the installed CLI version.
-h, --help——Works on every command and subcommand.

Environment variables

VariableWhat it does
ZEUSLOCK_API_URLBackend base URL. Default https://api.zeuslock.ai. Set it to https://api-staging.zeuslock.ai to work against staging.
ZEUSLOCK_API_TOKENPersonal CLI access token for user commands. Ideal for CI.
ZEUSLOCK_API_KEYOrganization API key for content and machine commands.
ZEUSLOCK_CONFIG_DIROverrides where the CLI stores its files.

Credential precedence

When more than one is present, the CLI uses the first that applies.

#User commandsContent commands
1--token zlu_…--api-key zl_…
2ZEUSLOCK_API_TOKENZEUSLOCK_API_KEY
3Saved token from auth login --tokenSaved key from auth api-key set

Exit codes

Every command returns 0 on success and 1 on failure, so any command can gate a CI step. Four commands return a meaningful non-zero code that reflects a finding rather than an error — they are the ones worth wiring into a pipeline.

CommandNon-zero means
scanSensitive content met the --fail-on threshold.
hook runThe commit should be blocked.
rules diffLocal policy file differs from live policy.
deploy agent-verifyNo agent matched, or it is not in the expected state.
status --require-licenseBackend health, readiness or license validation failed.

Output

Commands print aligned tables by default. Add --json for machine-readable output — every data-returning command supports it, and the shape is stable enough to parse. siem pull defaults to JSONL (one event per line) because that is what SIEM collectors ingest. The CLI never prints a stored token or API key unless you explicitly pass --show-secret.

Where the CLI stores things

FileContents
auth.jsonYour CLI access token, mode 0600.
api-key.jsonThe saved organization API key, mode 0600.
siem-cursors.jsonResume positions for siem tail, one per cursor name.

Location: macOS ~/Library/Application Support/zeuslock/, Windows %APPDATA%\ZeusLock\, Linux ~/.config/zeuslock/. The directory is created mode 0700 where the filesystem supports it.

zeuslock auth — Sign in and store credentials

Stores your personal token and your organization API key on this machine, and shows who you are.

zeuslock auth login --token

Validate a personal CLI access token and save it for future commands.

Credential: None · Impact: Writes local files

The token is checked against the backend before it is written, so a typo fails immediately rather than at the next command. It is saved to auth.json with mode 0600. There is no email and password login — see above.

OptionValuesDefaultWhat it does
--token <zlu_…>zlu_[object Object]noneThe token from the dashboard CLI page. Format is validated locally first.
--api-url <url>URLZEUSLOCK_API_URLBackend to validate against and store with the token.
--jsonBooleanoffPrint machine-readable JSON instead of a table.
zeuslock auth login --token zlu_your_cli_access_token
zeuslock auth login --token zlu_… --api-url https://api-staging.zeuslock.ai

A revoked or expired token returns 401. Tokens never refresh — generate a new one and run this again.

zeuslock auth logout

Remove the saved personal token from this machine.

Credential: None · Impact: Writes local files

Deletes auth.json only. Your saved organization API key is left in place, so scan, anonymize and SIEM commands keep working. It does not revoke the token server-side — use tokens revoke for that.

OptionValuesDefaultWhat it does
--jsonBooleanoffPrint machine-readable JSON instead of a table.
zeuslock auth logout

zeuslock auth api-key set [key]

Validate an organization API key and save it for content and SIEM commands.

Credential: Organization API key · Impact: Writes local files

The key is verified against the backend before it is saved, so an invalid key is rejected up front. Written to api-key.json with mode 0600; the full value is never printed back.

ArgumentRequiredWhat it is
keyNoThe zl_… key. If omitted, the CLI reads ZEUSLOCK_API_KEY or prompts.
OptionValuesDefaultWhat it does
--api-url <url>URLZEUSLOCK_API_URLBackend the key belongs to; stored alongside it.
--jsonBooleanoffPrint machine-readable JSON instead of a table.
zeuslock auth api-key set zl_your_org_api_key
zeuslock auth api-key set   # prompts, so the key stays out of shell history

zeuslock auth api-key status

Show whether an organization API key is configured, and which one.

Credential: None · Impact: Reads only

Prints the source, the backend URL and a masked key. The full value is never shown.

OptionValuesDefaultWhat it does
--jsonBooleanoffPrint machine-readable JSON instead of a table.
zeuslock auth api-key status

zeuslock auth api-key clear

Remove the saved organization API key from this machine.

Credential: None · Impact: Writes local files

Deletes api-key.json. The key stays valid in the dashboard — this only forgets it locally. Content commands will then need --api-key or ZEUSLOCK_API_KEY.

OptionValuesDefaultWhat it does
--jsonBooleanoffPrint machine-readable JSON instead of a table.
zeuslock auth api-key clear

zeuslock auth whoami

Identical to zeuslock whoami, for people who expect it under auth.

Credential: Personal CLI access token · Impact: Reads only

OptionValuesDefaultWhat it does
--jsonBooleanoffPrint machine-readable JSON instead of a table.
zeuslock auth whoami

zeuslock whoami / status — Who am I, and is anything wrong

zeuslock whoami

Show the account the CLI is currently acting as.

Credential: Personal CLI access token · Impact: Reads only

Returns email, user id, role, organization id, status and the backend URL. The first command to run when a permission error is unexplained — it tells you which account and which environment you are really on.

OptionValuesDefaultWhat it does
--jsonBooleanoffPrint machine-readable JSON instead of a table.
zeuslock whoami
zeuslock whoami --json
zeuslock --token zlu_… whoami   # check a token without saving it

zeuslock status

Show local configuration, backend health and readiness, and licence validity.

Credential: Organization API key (for the license check) · Impact: Reads only

One command that answers "is it me, or is it the service?". Health and readiness are checked without credentials; the licence check runs only when an organization API key is available. Use --require-license in CI to make a degraded backend fail the job.

OptionValuesDefaultWhat it does
--api-key <key>zl_…ZEUSLOCK_API_KEYKey used for the licence check.
--require-licenseBooleanoffExit non-zero unless health, readiness and licence all pass.
--jsonBooleanoffPrint machine-readable JSON instead of a table.
zeuslock status
zeuslock status --json
zeuslock status --require-license   # CI gate

zeuslock scan — Check content before it reaches an AI tool

zeuslock scan [path]

Run a file, a directory or piped text through your organization's DLP policy.

Credential: Organization API key · Impact: Reads only

Returns the same decision the desktop agent and browser extension would return — allow, alert or block — and records an incident when something is found, so terminal activity appears in the dashboard alongside browser activity. Directories are walked locally, .git is skipped, and files are uploaded in batches of five. The exit code follows --fail-on, which is what makes this usable as a CI gate.

ArgumentRequiredWhat it is
pathNoFile or directory to scan. Required unless --stdin is used; the two cannot be combined.
OptionValuesDefaultWhat it does
--stdinBooleanoffRead text from standard input instead of a path.
--api-key <key>zl_…[object Object]ZEUSLOCK_API_KEYOrganization API key to authenticate this call.
--fail-on <decision>alert | block | neverblockWhich decision makes the command exit non-zero. alert is strict (fails on alerts and blocks), never always exits 0 for reporting runs.
--source <source>Any textcliSource label recorded on the incident.
--platform <platform>Any textcliPlatform label sent with the request. Note that the incident's platform column is derived from the URL, so this value is not stored on the incident.
--hostname <hostname>Any textlocal hostnameHostname recorded on the incident.
--path <path>Any text/cli/<file>Destination label recorded on the incident; normalised to start with a slash.
--user-email <email>Any textnoneAttributes the incident to a person instead of leaving it anonymous. Worth setting in CI.
--include-sensitiveBooleanoffInclude the backend's anonymization map in JSON output. It contains the original values, so treat that output as sensitive.
--jsonBooleanoffPrint machine-readable JSON instead of a table.
zeuslock scan ./secrets.txt
zeuslock scan ./src --fail-on alert
cat prompt.txt | zeuslock scan --stdin --json
zeuslock scan ./build --fail-on never --user-email ci@example.com

Every scan that finds something creates a dashboard incident. Scanning a large tree repeatedly in CI will fill the incident timeline — scope the path, or use a narrower directory.

zeuslock anonymize — Strip sensitive values out of text

zeuslock anonymize <file>

Replace sensitive values in a UTF-8 text file with realistic substitutes.

Credential: Organization API key · Impact: Reads only

Unlike scan, this rewrites the content rather than judging it, and records no incident. Substitutes are plausible values of the same shape — a card number becomes a different valid-looking card number — so the text stays usable as a prompt or a test fixture. Use it to share a real document with an external LLM without leaking the real values.

ArgumentRequiredWhat it is
fileYesUTF-8 text file to anonymize.
OptionValuesDefaultWhat it does
--api-key <key>zl_…[object Object]ZEUSLOCK_API_KEYOrganization API key to authenticate this call.
--output <path>Writable pathstdoutWrite the anonymized text to a file instead of printing it.
--include-sensitive-mapBooleanoffInclude the original-to-masked pairs in JSON output. This reveals the real values — handle accordingly.
--jsonBooleanoffPrint machine-readable JSON instead of a table.
zeuslock anonymize customer-data.txt
zeuslock anonymize customer-data.txt --output customer-data.safe.txt
zeuslock anonymize customer-data.txt --json

zeuslock hook — Block secrets at the commit, not at review

Installs a Git pre-commit hook that scans staged content and refuses the commit when the DLP policy says so.

zeuslock hook install

Write the ZeusLock pre-commit hook into a repository.

Credential: None · Impact: Writes local files

Creates .git/hooks/pre-commit with mode 0755, calling zeuslock hook run. It refuses to overwrite an existing hook unless --force is given, so it will not silently destroy another tool's hook. The hook is local to the clone — it is not shared through Git, so each developer runs this once.

OptionValuesDefaultWhat it does
--repo <path>Pathcurrent repositoryRepository to install into.
--fail-on <decision>alert | blockalertThreshold written into the hook. The default is strict: alerts stop the commit too.
--forceBooleanoffReplace an existing pre-commit hook.
--jsonBooleanoffPrint machine-readable JSON instead of a table.
zeuslock hook install
zeuslock hook install --fail-on block --force

zeuslock hook run

Scan the staged changes and decide whether the commit may proceed.

Credential: Organization API key · Impact: Reads only

Reads the staged blobs, not the working tree, so what is scanned is exactly what would be committed — editing a file after staging it cannot sneak content past the check. Only added, copied, modified and renamed files are scanned; untracked, unstaged and deleted files are ignored, as is the repository's history. Exits non-zero to stop the commit.

OptionValuesDefaultWhat it does
--repo <path>Pathcurrent repositoryRepository to scan.
--api-key <key>zl_…[object Object]ZEUSLOCK_API_KEYOrganization API key to authenticate this call.
--fail-on <decision>alert | block | neveralertThreshold that stops the commit.
--user-email <email>Any textnoneAttributes any incident to a person.
--jsonBooleanoffPrint machine-readable JSON instead of a table.
zeuslock hook run
zeuslock hook run --fail-on block --json
git commit -m 'feature'   # the hook runs automatically

The hook needs an organization API key at commit time. Save one with `auth api-key set` so it works from a Git GUI, where environment variables are usually absent.

zeuslock incidents — What was detected, and how often

The same data as the dashboard Incidents page. Filters are applied locally after fetching a day window, which is why the day values are fixed.

zeuslock incidents list

List recent incidents with dashboard-equivalent filters.

Credential: Personal CLI access token · Impact: Reads only

Clean prompts are hidden, exactly as the dashboard hides them: a row is kept only if it has findings, was blocked, or has an action other than allowed. --days 90 requires a Business or Enterprise plan.

OptionValuesDefaultWhat it does
--days <days>7 | 30 | 9030History window. Other values are rejected before the request.
--severity <level>critical | warningnoneSeverity follows the policy outcome, not the detector score: critical means the request was blocked, warning means everything else. This matches what the dashboard shows.
--search <text>Any textnoneFilter on user email, URL or finding type.
--jailbreakBooleanoffKeep only incidents carrying a jailbreak-attempt finding.
--jsonBooleanoffPrint machine-readable JSON instead of a table.
zeuslock incidents list --days 7
zeuslock incidents list --severity critical
zeuslock incidents list --jailbreak --json

zeuslock incidents stats

Show aggregate incident statistics.

Credential: Personal CLI access token · Impact: Reads only

Severity breakdown, detected data types, a daily timeline and AI-platform usage — the numbers behind the dashboard overview, in one screen.

OptionValuesDefaultWhat it does
--days <days>1 | 7 | 30 | 36530Stats window. 365 requires a Business or Enterprise plan.
--jsonBooleanoffPrint machine-readable JSON instead of a table.
zeuslock incidents stats
zeuslock incidents stats --days 365 --json

zeuslock incidents export

Write filtered incidents to a CSV or JSON file.

Credential: Personal CLI access token · Impact: Writes local files

Produces the evidence file an auditor asks for. The CSV carries both severity (the policy outcome the dashboard displays) and risk_level (the raw detector score) — they legitimately differ, and keeping both means nothing is lost. Export requires a Business or Enterprise plan.

OptionValuesDefaultWhat it does
--days <days>7 | 30 | 9030History window.
--severity <level>critical | warningnoneSeverity follows the policy outcome, not the detector score: critical means the request was blocked, warning means everything else. This matches what the dashboard shows.
--search <text>Any textnoneFilter on user email, URL or finding type.
--jailbreakBooleanoffKeep only incidents carrying a jailbreak-attempt finding.
--format <format>csv | jsoncsvOutput format.
--output <path>Writable pathincidents-<timestamp>.<ext>Destination file.
--jsonBooleanoffPrint machine-readable JSON instead of a table.
zeuslock incidents export --days 7
zeuslock incidents export --days 30 --severity critical --format json --output incidents.json

zeuslock agents / extensions — Is the fleet actually protected

zeuslock agents list

List enrolled desktop agents with their heartbeat state.

Credential: Personal CLI access token · Impact: Reads only

Shows hostname, platform, version, online state and last heartbeat, plus an update_available marker when a newer version has been published. An agent counts as online if it checked in within the last five minutes. This is how you find machines that stopped reporting.

OptionValuesDefaultWhat it does
--status <status>all | online | offlineallHeartbeat filter.
--search <text>Any textnoneSearches hostname and platform only.
--jsonBooleanoffPrint machine-readable JSON instead of a table.
zeuslock agents list
zeuslock agents list --status offline
zeuslock agents list --search windows --json

zeuslock agents revoke <agent_id>

Revoke one enrolled desktop agent.

Credential: Personal CLI access token · Impact: Changes organization state

The agent loses its enrolment and stops being trusted by the backend. Use it when a laptop is lost or decommissioned. The command prompts before acting unless you pass --yes.

ArgumentRequiredWhat it is
agent_idYesExact id from agents list.
OptionValuesDefaultWhat it does
-y, --yesBooleanoffSkip the confirmation prompt. Required in scripts and CI.
--jsonBooleanoffPrint machine-readable JSON instead of a table.
zeuslock agents revoke AGENT-123
zeuslock agents revoke AGENT-123 --yes --json

zeuslock extensions status

Show browser extensions that are currently active.

Credential: Personal CLI access token · Impact: Reads only

Counts extensions and users seen in the last 30 minutes. A low count against a large fleet usually means the force-install policy did not reach those browsers.

OptionValuesDefaultWhat it does
--jsonBooleanoffPrint machine-readable JSON instead of a table.
zeuslock extensions status --json

zeuslock users / keys / tokens — Who has access, and with what

Three separate things: people, organization API keys, and personal CLI tokens. Removing a person does not revoke a key they created.

zeuslock users list

List the people in your organization.

Credential: Personal CLI access token · Impact: Reads only

Shows email, role, status, active flag and creation date. Roles are validated against the roles your plan actually exposes, so an invalid role is rejected rather than silently matching nothing.

OptionValuesDefaultWhat it does
--search <text>Any textnoneLocal filter over email, role, status and display name.
--role <role>admin, user, viewer…noneValidated against the roles your plan exposes.
--jsonBooleanoffPrint machine-readable JSON instead of a table.
zeuslock users list
zeuslock users list --role admin
zeuslock users list --search alice --json

zeuslock users remove <user>

Remove one person from the organization.

Credential: Personal CLI access token · Impact: Changes organization state

Two guards are enforced server-side and cannot be overridden: you cannot remove yourself, and you cannot remove the last active admin. Accepts an id or an email, resolved against the user list first.

ArgumentRequiredWhat it is
userYesUser id or email address.
OptionValuesDefaultWhat it does
-y, --yesBooleanoffSkip the confirmation prompt. Required in scripts and CI.
--jsonBooleanoffPrint machine-readable JSON instead of a table.
zeuslock users remove departing@example.com
zeuslock users remove user-uuid --yes --json

zeuslock keys list

List organization API keys.

Credential: Personal CLI access token · Impact: Reads only

Key values are masked by default. --show-secret prints full values only for keys the backend can still decrypt; older keys may only ever show masked.

OptionValuesDefaultWhat it does
--status <status>all | active | revokedallLocal status filter.
--show-secretBooleanoffReveal full key values where available.
--jsonBooleanoffPrint machine-readable JSON instead of a table.
zeuslock keys list
zeuslock keys list --status active
zeuslock keys list --show-secret --json

zeuslock keys create --name <name>

Create a new organization API key.

Credential: Personal CLI access token · Impact: Changes organization state

The full key is returned once, in this response. Copy it immediately — the CLI cannot show it again later if the backend stops returning it.

OptionValuesDefaultWhat it does
--name <name>Any textnoneRequired. Name it after where it will be used, so it can be revoked confidently later.
--jsonBooleanoffPrint machine-readable JSON instead of a table.
zeuslock keys create --name ci-pipeline
zeuslock keys create --name fleet-deploy --json

zeuslock keys revoke <key_id>

Revoke one active organization API key.

Credential: Personal CLI access token · Impact: Changes organization state

Anything using the key stops working immediately — agents configured with it, CI jobs, hooks. The CLI refuses to act on an already-revoked key, because a second delete on the backend permanently destroys the record rather than revoking it.

ArgumentRequiredWhat it is
key_idYesId from keys list.
OptionValuesDefaultWhat it does
-y, --yesBooleanoffSkip the confirmation prompt. Required in scripts and CI.
--jsonBooleanoffPrint machine-readable JSON instead of a table.
zeuslock keys revoke key-uuid --yes

zeuslock tokens list

List your personal CLI access tokens.

Credential: Personal CLI access token · Impact: Reads only

Shows name, masked value, status, expiry and last use. The last-used column is the quickest way to find tokens that can safely be revoked.

OptionValuesDefaultWhat it does
--status <status>all | active | revoked | expiredallLocal status filter.
--show-secretBooleanoffReveal full token values where the backend returns them.
--jsonBooleanoffPrint machine-readable JSON instead of a table.
zeuslock tokens list
zeuslock tokens list --status expired

zeuslock tokens create --name <name>

Create a personal CLI access token.

Credential: Personal CLI access token · Impact: Changes organization state

The full zlu_… token is returned once. This is the scriptable alternative to the dashboard CLI page — useful for issuing a short-lived token to a CI job from a machine that is already authenticated.

OptionValuesDefaultWhat it does
--name <name>1-255 charactersnoneRequired. Identifies the token in the list.
--expires-in-days <days>1-365backend default (90)Shorter lifetimes are better for CI. Out-of-range values are rejected locally.
--jsonBooleanoffPrint machine-readable JSON instead of a table.
zeuslock tokens create --name work-laptop
zeuslock tokens create --name ci-job --expires-in-days 30 --json

zeuslock tokens revoke <token_id>

Revoke one personal CLI access token.

Credential: Personal CLI access token · Impact: Changes organization state

The token returns 401 from the next request onward. The record is kept so it stays visible in the list as revoked — this is the reversible-looking step, and the one to use when a laptop goes missing.

ArgumentRequiredWhat it is
token_idYesId from tokens list.
OptionValuesDefaultWhat it does
-y, --yesBooleanoffSkip the confirmation prompt. Required in scripts and CI.
--jsonBooleanoffPrint machine-readable JSON instead of a table.
zeuslock tokens revoke token-uuid --yes

zeuslock tokens purge <token_id>

Permanently delete an already-revoked CLI token.

Credential: Personal CLI access token · Impact: Changes organization state

Removes the record entirely, so it disappears from the list and from any audit view. The token must be revoked first — the CLI refuses to purge an active one, which makes accidental destruction of a working credential impossible in one step.

ArgumentRequiredWhat it is
token_idYesId of a revoked token.
OptionValuesDefaultWhat it does
-y, --yesBooleanoffSkip the confirmation prompt. Required in scripts and CI.
--jsonBooleanoffPrint machine-readable JSON instead of a table.
zeuslock tokens revoke token-uuid --yes
zeuslock tokens purge token-uuid --yes

zeuslock rules — Policy as code

Export live policy state to a reviewable file, and detect when the live state has drifted from it. Read-only — the CLI never writes policy back.

zeuslock rules get

Export the current DLP policy state as YAML or JSON.

Credential: Personal CLI access token · Impact: Reads only

Output is normalised: ordering is deterministic and volatile fields such as created_at, updated_at and org_id are stripped, so two exports of an unchanged policy are byte-identical. That is what makes the file safe to commit and diff.

OptionValuesDefaultWhat it does
--scope <scope>policies | default | policypoliciespolicies exports every visible policy plus assignment groups; default exports only the org-wide Default Policy; policy exports one document.
--policy-id <id>Any textnoneRequired with --scope policy.
--format <format>yaml | jsonyamlExport format.
--output <path>Writable pathstdoutWrite to a file instead of printing.
zeuslock rules get --output zeuslock.rules.yaml
zeuslock rules get --scope default --format json
zeuslock rules get --scope policy --policy-id default

zeuslock rules diff [file]

Compare a local policy file against the live policy state.

Credential: Personal CLI access token · Impact: Reads only

Exits 0 when they match and 1 when they differ, printing a path-level diff of what changed. Run it in CI against a committed export to catch policy edits made in the dashboard that nobody reviewed.

ArgumentRequiredWhat it is
fileNoExported YAML or JSON. Defaults to zeuslock.rules.yaml, then .yml, then .json.
OptionValuesDefaultWhat it does
--scope <scope>policies | default | policypoliciesMust match the scope recorded in the file.
--policy-id <id>Any textnoneRequired with --scope policy.
--format <format>text | jsontextDiff output format.
zeuslock rules diff zeuslock.rules.yaml
zeuslock rules diff --scope default zeuslock.default.rules.yaml
zeuslock rules diff policy.json --scope policy --policy-id default --format json

zeuslock siem — Feed events to your SIEM

Retrieves DLP events in OCSF format. These commands read events only — SIEM destinations such as Splunk, Sentinel and Elastic are configured in the dashboard, not here.

zeuslock siem pull

Retrieve one page of OCSF events.

Credential: Organization API key · Impact: Reads only

Prints JSONL by default — one event per line — which is what SIEM collectors ingest directly. The response carries a next_cursor; pass it back through --since to page forward. Use this for backfills and one-off queries.

OptionValuesDefaultWhat it does
--api-key <key>zl_…[object Object]ZEUSLOCK_API_KEYOrganization API key for this call.
--since <cursor>Cursor stringnoneA next_cursor from a previous response. Not a date.
--from <time>ISO date/time or epochnoneStart of the time window.
--to <time>ISO date/time or epochnoneEnd of the time window.
--days <n>Positive integernoneLook back this many days. Mutually exclusive with --from.
--category <value>dlpnoneEvent category. Current events use dlp.
--severity <level>unknown | low | medium | high | criticalnoneTreated as a minimum severity, not an exact match.
--limit <n>1-500100Page size. Validated before the request.
--format <format>jsonl | jsonjsonljsonl pipes into collectors; json returns an envelope with next_cursor.
zeuslock siem pull --limit 100
zeuslock siem pull --days 7 --severity high --category dlp
zeuslock siem pull --format json | jq .next_cursor

zeuslock siem tail

Poll continuously and emit new events as they arrive.

Credential: Organization API key · Impact: Reads continuously until stopped

Runs until you stop it, saving its position to siem-cursors.json after each poll, so a restart resumes without duplicating or skipping events. There is no streaming endpoint behind this — it polls. Give each consumer its own --cursor-name so two pipelines do not fight over one position.

OptionValuesDefaultWhat it does
--api-key <key>zl_…[object Object]ZEUSLOCK_API_KEYOrganization API key for this call.
--since <cursor>Cursor stringsaved cursorOverride the saved position for this run.
--category <value>dlpnoneAlso part of the cursor's identity.
--severity <level>unknown…criticalnoneMinimum severity; also part of the cursor's identity.
--limit <n>1-500100Page size per poll.
--interval <seconds>Positive number5Seconds between polls.
--cursor-name <name>Any textdefaultNamespace for this consumer's saved position.
--reset-cursorBooleanoffIgnore the saved position and replay from the beginning.
--max-polls <count>Positive integernoneStop after this many polling cycles instead of running forever. Useful in a cron job.
zeuslock siem tail --category dlp
zeuslock siem tail --cursor-name splunk-prod --interval 10
zeuslock siem tail --max-polls 12 --interval 5   # ~1 minute, then exit

zeuslock shadow-ai — AI tools nobody approved

Read-only view of the dashboard Shadow AI page. Available only when Shadow AI is enabled for your organization; otherwise the commands say so and make no data call.

zeuslock shadow-ai stats

KPI totals for unapproved AI tool usage.

Credential: Personal CLI access token · Impact: Reads only

Totals plus period-over-period change, so you can tell whether shadow usage is growing after a policy announcement.

OptionValuesDefaultWhat it does
--days <days>7 | 30 | 9030History window.
--source <source>all | endpoint | browser | bothallWhere the usage was observed.
--status <status>all | sanctioned | shadowallshadow means the tool has not been approved.
--category <category>all | chatbot | coding_assistant | image_gen | agent | otherallTool category.
--jsonBooleanoffPrint machine-readable JSON instead of a table.
zeuslock shadow-ai stats
zeuslock shadow-ai stats --days 7 --status shadow --category chatbot

zeuslock shadow-ai tools

List the AI tools detected in your environment.

Credential: Personal CLI access token · Impact: Reads only

Tool, category, policy status, source, user count, connection count and risk score — the list to work through when deciding what to sanction or block.

OptionValuesDefaultWhat it does
--days <days>7 | 30 | 9030History window.
--source <source>all | endpoint | browser | bothallWhere the usage was observed.
--status <status>all | sanctioned | shadowallshadow means the tool has not been approved.
--category <category>all | chatbot | coding_assistant | image_gen | agent | otherallTool category.
--jsonBooleanoffPrint machine-readable JSON instead of a table.
zeuslock shadow-ai tools --status shadow
zeuslock shadow-ai tools --category coding_assistant --json

zeuslock shadow-ai users

List the people using shadow AI tools.

Credential: Personal CLI access token · Impact: Reads only

User, number of distinct tools and most-used tool. Aimed at finding teams that need an approved alternative, not at singling people out.

OptionValuesDefaultWhat it does
--days <days>7 | 30 | 9030History window.
--jsonBooleanoffPrint machine-readable JSON instead of a table.
zeuslock shadow-ai users --days 7 --json

zeuslock mcp — Model Context Protocol activity

What AI agents connected to, and what they were allowed to do. The backend stores sanitized metadata and non-reversible content hashes only, so prompts and tool payloads are never exposed here.

zeuslock mcp stats

KPI totals for MCP activity.

Credential: Personal CLI access token · Impact: Reads only

Events, tool calls, blocked and alerted counts, active servers and affected users, grouped by transport, direction and method.

OptionValuesDefaultWhat it does
--days <days>7 | 30 | 9030History window.
--jsonBooleanoffPrint machine-readable JSON instead of a table.
zeuslock mcp stats --days 7 --json

zeuslock mcp events

List individual MCP audit events.

Credential: Personal CLI access token · Impact: Reads only

Paginated at 50 rows per page. Follow next_cursor through --cursor to walk a longer window.

OptionValuesDefaultWhat it does
--days <days>7 | 30 | 9030History window.
--transport <transport>all | http | sse | stdioallHow the agent connected.
--direction <direction>all | client_to_server | server_to_clientallMessage direction.
--decision <decision>all | allow | alert | blockallWhat the policy decided.
--method <method>tools/call…noneExact MCP method name.
--search <text>Any textnoneSearches server, tool, user, method, hostname and path.
--cursor <cursor>Cursor stringnoneContinue from a previous page.
--jsonBooleanoffPrint machine-readable JSON instead of a table.
zeuslock mcp events --decision block
zeuslock mcp events --transport stdio --method tools/call --json

zeuslock mcp servers

List the MCP servers discovered in your environment.

Credential: Personal CLI access token · Impact: Reads only

A deduplicated inventory over a fixed 90-day window — the answer to "what has anyone connected an agent to?".

OptionValuesDefaultWhat it does
--jsonBooleanoffPrint machine-readable JSON instead of a table.
zeuslock mcp servers --json

zeuslock deploy — Roll out to a fleet, then prove it worked

zeuslock deploy generate (alias: gpo-config)

Generate the managed-configuration files that enrol machines automatically.

Credential: Personal CLI access token · Impact: Writes local files

Writes local files only — nothing is sent to Active Directory, Intune or Jamf. Push them with whatever tool you already use and machines arrive already pointed at your organization, with no per-user setup. Files containing the API key are written mode 0600; the key is never printed to the terminal or written into deployment-summary.json.

OptionValuesDefaultWhat it does
--artifact <set>all | extension | agentallWhich files to generate. Extension artifacts need a Business or Enterprise plan.
--browser <browser>all | chrome | edgeallApplies to extension artifacts only.
--output <dir>Pathzeuslock-deployOutput directory. Existing files with the same names are overwritten.
--api-key <key>zl_…noneKey to embed. Highest precedence.
--key-id <id>Any textnoneUse an existing key from keys list.
--create-key-name <name>Any textnoneCreate a new key and embed it. This changes organization state.
--jsonBooleanoffPrint machine-readable JSON instead of a table.
zeuslock deploy generate --key-id key-uuid
zeuslock deploy generate --artifact agent --output ./rollout
zeuslock deploy generate --artifact extension --browser chrome --create-key-name fleet-2026

If your organization has more than one active key, the command refuses to guess — pass --key-id, --api-key or --create-key-name.

Extension configuration is delivered in two separate files on purpose: browser policy controls installation, while the API key travels in the managed-configuration file. Deploy both, or the extension installs and then asks each user to configure it.

zeuslock deploy agent-verify

Confirm that machines actually enrolled and are checking in.

Credential: Personal CLI access token · Impact: Reads only

Exits non-zero unless a matching agent exists in the expected state, so it can gate a rollout script. Returns one of verified, offline, online or not_found — the distinction between "never arrived" and "arrived and went quiet" is what tells you whether the deployment or the machine is at fault.

OptionValuesDefaultWhat it does
--agent-id <id>Any textnoneExact agent id match.
--hostname <name>Any textnoneExact hostname match, case-insensitive.
--platform <platform>windows | macos | linuxnonePlatform filter.
--status <status>online | offline | anyonlineThe state you expect. Use any to check enrolment without requiring a live heartbeat.
--jsonBooleanoffPrint machine-readable JSON instead of a table.
zeuslock deploy agent-verify --hostname LAPTOP-01
zeuslock deploy agent-verify --platform windows --status any --json

Troubleshooting

What you seeWhat it meansWhat to do
Not logged in. Run `zeuslock auth login` first.No personal token is saved on this machine.Generate one on the dashboard CLI page and run zeuslock auth login --token zlu_….
invalid CLI tokenThe token is revoked, expired, or belongs to a different environment.Tokens are environment-specific: a staging token returns 401 against production. Check ZEUSLOCK_API_URL, then issue a new token.
API key is required.A content command ran without an organization API key.A personal token does not work for scan, anonymize, hook run or SIEM. Run zeuslock auth api-key set.
Multiple active API keys are available.deploy generate will not guess which key to embed.Pass --key-id, --api-key or --create-key-name.
A command needs 90 or 365 days and refuses.Long history windows and export are plan-gated.Business or Enterprise is required. Shorter windows keep working.
A command hangs.siem tail polls until stopped; that is expected.Press Ctrl-C, or use --max-polls for a bounded run.

Working against staging

Credentials are environment-specific and do not cross over. Point the CLI at staging and authenticate again with a staging token.

export ZEUSLOCK_API_URL="https://api-staging.zeuslock.ai"
zeuslock auth login --token zlu_your_staging_token
zeuslock status

What the CLI deliberately does not do

The CLI mirrors the dashboard and backend rather than inventing capabilities on top of them. These are absent on purpose, so you do not go looking:

Not availableWhy
Email and password loginThe login endpoint requires a reCAPTCHA challenge that a terminal cannot complete.
Applying or editing policiesrules is export and diff only; policy changes stay in the dashboard, where they are reviewed.
Configuring SIEM destinationsSplunk, Sentinel and Elastic connections are managed in the dashboard. The CLI reads events only.
Rotating a key or token in one stepThere is no atomic rotate endpoint. Create the replacement, move traffic to it, then revoke the old one.
Bulk user removalThe backend removes one user at a time, and the safety guards apply to each.
Building installersdeploy generate produces configuration files. Download installers from the dashboard.