Reference
CLI reference.
The command line is an independently useful product interface. Output on stdout is parseable; progress and human text go to stderr. Every JSON response is schema-versioned and free of ANSI sequences.
Workspace
Command Does Risk
intralock init --workspace . --read-onlyRegisters a directory; no file writes. read
intralock workspaces listLists registered workspaces and IDs. read
intralock workspace inspect <id>Root, policy, exclusions, counts, health. read
intralock workspace archive <id>Marks unavailable; preserves identity and history. mutate
Index
Command Does Risk
intralock index run --workspace <id> [--dry-run]Builds or refreshes the catalog. derive
intralock index status --workspace <id>Queue depth, freshness, failures, coverage gaps. read
intralock reindex object <id>Re-extracts one object after a parser change. derive
Search and relationships
Command Does Risk
intralock search "query" --workspace <id> --jsonPermission-filtered FTS5 search. read
intralock graph neighbors <obj> --depth 2Typed traversal with evidence. read
intralock context bundle --workspace <id> --mode engineering --max-tokens 6000Budgeted context assembly. derive
intralock object get <id> --jsonMetadata, versions, provenance, edges. read
Homepages and snapshots
Command Does Risk
intralock homepage preview --workspace <id>Renders a virtual homepage; no write. derive
intralock homepage publish --workspace <id> --approval <apr>Writes adopted, owned regions only. mutate
intralock snapshot create --workspace <id>Captures digest-bound state. derive
intralock snapshot verify --workspace <id>Reports verified, stale, modified, unverifiable, or invalid. read
Governance
Command Does Risk
intralock policies explain --actor <id> --action <op> --object <id>Shows why an operation is allowed or denied. read
intralock capabilities list --format jsonCapability registry with risk and scope. read
intralock tokens issue --actor … --capability … --expires 24hIssues a scoped token; value shown once. admin
intralock tokens revoke <id>Immediate denial; no cache window. admin
intralock tasks list --state runningDurable task ledger. read
intralock tasks cancel <id>Re-authorized cancellation. mutate
Operations
Command Does Risk
intralock backup create --target /safe/pathConsistent backup with integrity metadata. derive
intralock backup restore <id>Rehearsed restore into a verified target. mutate
intralock manifest validateExact failing line and rule, with migration hint. read
intralock doctor --fullSchema, disk reserve, queues, event coverage, integrity. read
intralock mcp serve --transport stdioLocal MCP server over the same policy engine. read
intralock server start --bind 127.0.0.1:8765Local HTTP server; loopback by default. admin
Global flags
Flag Meaning
--workspace <id>Scope the operation; no ambient default when omitted.
--format json|table|textOutput format. --json is shorthand.
--expected-version <rev>Refuse the write if the object changed.
--dry-runResolve and report; no effect.
--request-id <id>Correlate logs, receipts, and support.
--quiet / --verboseSuppress or expand stderr diagnostics.
--yesOnly where safe. Never bypasses an approval.
Exit codes
Code Meaning
0 Success
1 Internal fault
2 Invalid input or usage
3 Policy denial
4 Conflict: version or precondition
5 Daemon unavailable
6 Partial completion (see receipt)
JSON shape
json copy
{
"schema": "intralock.cli/v1",
"request_id": "req_01JEX7",
"ok": true,
"data": { "results": [ … ] },
"freshness": { "indexed_at": "…", "lag_seconds": 12 }
}