Command reference

Use contd from the terminal

Run contd help for the same reference from the executable.

Documentation home ยท Getting started

Commands

contd validate [--config PATH] [--json]
contd run [options]
contd cancel [--reason TEXT] [--json] <run-id>
contd status [--json] <run-id>
contd runs [--json] [--limit N]
contd logs [--json] <run-id> [job]
contd artifacts [--json] [--all] <run-id>
contd artifacts download --output PATH <run-id> <artifact-id>
contd inspect [--json] <run-id>
contd analyze [options] <run-id>
contd daemon start [--socket PATH] [--json]
contd daemon status [--socket PATH] [--json]
contd daemon stop [--socket PATH]
contd submit [options]
contd help [command]

run options

OptionMeaning
--config PATHRead a specific configuration file.
--job NAMERun one job and its prerequisites.
--from NAMERun a job, its dependents, and their prerequisites.
--socket PATHUse a specific daemon socket.
--foreground, -fgRun in the client instead of the daemon.
--followWait for a daemon run and print lifecycle events.
--logsInclude live logs with --follow.
--verbosePrint live logs in foreground mode.
--jsonEmit machine-readable output.

submit options

OptionMeaning
--socket PATHDaemon socket.
--workspace PATHAbsolute workspace path. Defaults to the current directory.
--config PATHConfig path. Defaults to the first discovered config name.
--request-id IDStable ID for idempotent resubmission.
--job NAMERun one job and its prerequisites.
--from NAMERun a job, its dependents, and their prerequisites.
--jsonPrint the queued request as JSON.

analyze options

OptionDefault
--job NAMERequired.
--artifact IDNo artifacts unless selected. Repeatable.
--data-policy POLICYlocal-only.
--max-context-bytes N131072.
--max-log-bytes N32768 per log.
--max-artifact-bytes N16384 per artifact.
--max-artifacts N4.
--max-turns N1.
--max-tokens N1000.
--max-budget NUnlimited.
--timeout DURATION30s.
--jsonPrint the structured artifact.

Application paths

PathPurpose
.contd/contd.dbRun and lifecycle metadata for a submitted workspace.
.contd/runs/<run-id>/Run-scoped logs, artifacts, and cancellation records.
$XDG_RUNTIME_DIR/contd/contd.sockDefault daemon HTTP/JSON socket.
~/.contd/contd.sockDefault socket when XDG_RUNTIME_DIR is unavailable.
<socket>.grpcMatching gRPC socket.

The daemon queue database is stored beside its socket. These paths are application state, not inputs that a job should rely on.

JSON output

Commands with --json emit stable objects. run --follow --json emits one JSON object per lifecycle event and a final run object, making it suitable for line-oriented consumers.

Process exit codes

CodeMeaning
0Success.
1CLI or infrastructure failure.
2Configuration or validation failure.
3Run failure or timeout.
4Cancellation.