Command reference
Every wrkq command with its usage line and flags, generated at build time from the CLI’s own --help output. Nothing here is written by hand, so it cannot drift from the binary you installed.
generated from v0.1.0-272-g7854f29
global flags
Accepted by every command below, so they are listed once here and never repeated. Each command also takes -h, --help.
--as string Alias for --principal-ref; accepts agent:<id> or a full agent ScopeRef --db string Path to database file (overrides WRKQ_DB_PATH) --output string Output mode: table, human, json, ndjson, porcelain, yaml, tsv, raw --principal-ref string Caller principal for write attribution: agent:<id> or full agent ScopeRef --project string Project to operate under (overrides WRKQ_PROJECT_ROOT)files12
wrkq ls
alias list
List containers and tasks
$ wrkq ls [path...] [flags]| flag | description | |
|---|---|---|
| -a, --all | Include archived and deleted items | |
| --cursor string | string | Pagination cursor from previous page |
| --json | Output as JSON | |
| --limit int | int | Maximum number of results to return (0 = no limit) |
| --ndjson | Output as newline-delimited JSON | |
| -0, --nul | NUL-separated output | |
| -1, --one | One entry per line | |
| --porcelain | Machine-readable output | |
| --pretty | Force human-readable table output even when not a TTY | |
| -R, --recursive | List recursively | |
| --reverse | Reverse sort order | |
| --sort string | string | Sort by field: slug, updated_at, created_at, id (default "slug") |
| --type string | string | Filter by type (p=project, t=task) |
wrkq tree
Display containers and tasks in a tree structure
$ wrkq tree [path...] [flags]| flag | description | |
|---|---|---|
| -a, --all | Include completed/archived/deleted tasks and empty containers | |
| --fields string | string | Fields to display (comma-separated) |
| --json | Output as JSON | |
| -L, --level int | int | Maximum depth to display (0 = unlimited) |
| --ndjson | Output as newline-delimited JSON | |
| --open | Show only open tasks | |
| --porcelain | Machine-readable output | |
| --pretty | Force human-readable tree output even when not a TTY | |
| --state string | string | Promise leaf state: open (default) or all |
wrkq cat
alias show
Print one or more tasks, containers, or promises.
JSON output is always array-shaped for compatibility, even with one selector. Singleton automation should use --json --one, which asserts exactly one explicit selector and one resolved resource and emits that object without an array wrapper. Shell expansion still counts toward the explicit-selector cardinality.
$ wrkq cat <path|id>... [flags]| flag | description | |
|---|---|---|
| --exclude-comments | Exclude comments from output | |
| --json | Output as JSON | |
| --ndjson | Output as newline-delimited JSON | |
| --no-frontmatter | Print body only without front matter | |
| --one | Assert one selector/result and emit one bare JSON object (requires --json) | |
| --porcelain | Machine-readable output | |
| --pretty | Force the styled task card even when not a TTY |
$ wrkq cat T-00001 --json$ wrkq cat T-00001 T-00002 --json$ wrkq cat T-00001 --json --onewrkq stat
Print metadata for tasks or containers
$ wrkq stat <path|id>... [flags]| flag | description | |
|---|---|---|
| --json | Output as JSON | |
| -0, --nul | NUL-separated output |
wrkq touch
Create one or more tasks
$ wrkq touch <path>... [flags]| flag | description | |
|---|---|---|
| --assigned-project string | string | Assignee project ID |
| --assignee string | string | Assignee principal ref or bare agent slug |
| --campaign string | string | Enroll the new task in a draft or active campaign by ID or path (the task keeps its own project) |
| --caused-by string | string | Causal lineage: comma-separated task IDs whose work caused this defect/rework (e.g. T-00012,T-00034) |
| -d, --description string | string | Description for the task (use @file.md for file or - for stdin) |
| --due-at string | string | Initial task due date |
| --force-uuid string | string | Force specific UUID instead of auto-generating (must be valid UUIDv4) |
| --json | Output as JSON | |
| --kind string | string | Task kind: task, subtask, spike, bug, chore (default: task) |
| --labels string | string | Initial labels (comma shorthand unless starting '[' for JSON array; empty/[] clears; JSON allows commas) |
| --meta string | string | Initial task metadata (JSON object or null) |
| --meta-file string | string | Load task metadata from file (JSON object or null) |
| --parent-task string | string | Parent task ID or path (for subtasks) |
| --priority int | int | Initial task priority (1-4) (default 3) |
| --requested-by string | string | Requester project ID (return-to target) |
| --resolution string | string | Task resolution (done, wont_do, duplicate, needs_info) |
| --specification string | string | Specification for the task (use @file.md for file or - for stdin) |
| --start-at string | string | Initial task start date |
| --state string | string | Initial task state (idea, draft, open, in_progress, completed, blocked, cancelled, archived, deleted) (default "open") |
| -t, --title string | string | Title for the task (defaults to slug) |
wrkq mkdir
Create one or more containers
$ wrkq mkdir <path>... [flags]| flag | description | |
|---|---|---|
| --kind string | string | Container kind: project, directory, feature, area (default: directory) |
| -p, --parents | Create parent containers as needed |
wrkq mv
Move or rename tasks and containers
$ wrkq mv <src>... <dst> [flags]| flag | description | |
|---|---|---|
| --dry-run | Show what would be moved without applying | |
| --if-match int | int | Only move if etag matches |
| --nullglob | Zero matches is a no-op instead of error | |
| --overwrite-task | Allow overwriting existing tasks | |
| --type string | string | Force type: t (task), p (project/container) |
| --yes | Skip confirmation prompts |
wrkq cp
Copy tasks and containers
$ wrkq cp <source>... <destination> [flags]| flag | description | |
|---|---|---|
| --0 | NUL-separated output | |
| --1 | One per line | |
| --continue-on-error | Continue on errors | |
| --dry-run | Show what would be copied | |
| --if-match int | int | Conditional copy based on source etag |
| -j, --jobs int | int | Parallel workers (default 1) |
| --json | Output JSON | |
| --ndjson | Output NDJSON | |
| --nullglob | Zero matches is not an error | |
| --overwrite | Overwrite existing tasks | |
| --porcelain | Machine-readable output | |
| -r, --recursive | Copy containers recursively | |
| --shallow | Skip attachments entirely | |
| --with-attachments | Copy attachment files | |
| --yes | Skip confirmation prompts |
wrkq rm
Archives (soft delete) or permanently deletes tasks and containers.
By default, performs soft delete (sets archived_at). Use --purge for hard delete. Container purge only removes empty containers; use rmdir --force for recursive deletion.
WARNING: --purge permanently deletes tasks and attachments. This CANNOT be undone!
$ wrkq rm <path|id>... [flags]| flag | description | |
|---|---|---|
| --continue-on-error | Continue on errors | |
| --dry-run | Show what would be removed | |
| -f, --force | Force removal | |
| -j, --jobs int | int | Parallel workers (default 1) |
| --json | Output JSON | |
| --ndjson | Output NDJSON | |
| --nullglob | Zero matches is not an error | |
| --porcelain | Machine-readable output | |
| --purge | Permanently delete (CANNOT BE UNDONE) | |
| -r, --recursive | Remove containers recursively | |
| --yes | Skip confirmation prompts |
wrkq rmdir
Remove one or more containers
$ wrkq rmdir <path|id>... [flags]| flag | description | |
|---|---|---|
| -f, --force | Force removal of non-empty containers | |
| --yes | Skip confirmation prompts |
wrkq restore
Restores a deleted or archived task to active state.
The task must be in 'deleted' or 'archived' state. By default, restores to 'open' state. Subtasks are cascade-restored when their parent is restored.
$ wrkq restore <path|id|uuid> [flags]| flag | description | |
|---|---|---|
| --assignee string | string | Update assignee on restore |
| --comment string | string | Add comment explaining restoration |
| --description string | string | Update description on restore |
| --if-match int | int | Conditional restore (etag) |
| --labels string | string | Update labels on restore (comma shorthand unless starting '[' for JSON array; empty/[] clears; JSON allows commas) |
| --priority int | int | Update priority on restore (1-4) |
| --state string | string | Restore to specific state (default: open) |
| --title string | string | Update title on restore |
| --to string | string | Restore to different container/slug (path) |
wrkq rename-container
Rename a container by updating both its slug and title.
By default, the title is set to match the new slug. Use --title to specify a custom title.
Examples: # Rename both slug and title to "new-project" wrkq rename-container old-project new-project
# Rename with custom title wrkq rename-container P-00001 new-project --title "New Project Name"
# Rename a top-level container in canonical DB WRKQ_PROJECT_ROOT="" wrkq rename-container rex rex-control-plane
$ wrkq rename-container <path|id> <new-slug> [flags]| flag | description | |
|---|---|---|
| --dry-run | Show what would change without applying | |
| --if-match int | int | Only rename if etag matches |
| --title string | string | Custom title (defaults to new slug) |
work10
wrkq set
alias edit
Update task fields; outcome is curated, comments are raw, and completion never requires outcome
$ wrkq set <path|id>... [flags]| flag | description | |
|---|---|---|
| --assigned-project string | string | Update assignee project ID |
| --assignee string | string | Update task assignee |
| --campaign string | string | Enroll in a draft or active campaign by ID or path; the task keeps its own project (empty string unenrolls) |
| --caused-by string | string | Replace causal lineage with comma-separated task IDs (empty string clears; omit to leave unchanged) |
| --continue-on-error | Continue processing on errors | |
| -d, --description string | string | Update task description |
| --dry-run | Show what would be changed without applying | |
| --due-at string | string | Update task due date |
| --if-match int | int | Only update if etag matches |
| -j, --jobs int | int | Number of parallel workers (0 = auto-detect CPU count) (default 1) |
| --kind string | string | Update task kind |
| --labels string | string | Update labels (comma shorthand unless starting '[' for JSON array; empty/[] clears; JSON allows commas) |
| --meta string | string | Update task metadata (JSON object or null) |
| --meta-file string | string | Load task metadata from file |
| --ordered | Preserve input order (disables parallelism) | |
| --outcome string | string | Set curated task outcome (use @file or - for stdin; blank clears) |
| --parent-id string | string | Alias for --parent-task |
| --parent-task string | string | Set parent task ID or path |
| --priority int | int | Update task priority (1-4) |
| --requested-by string | string | Update requester project ID |
| --resolution string | string | Update task resolution |
| --root string | string | Set a top-level project's checkout root (stored as ~/... when under $HOME; empty clears; consumers expand it) |
| --slug string | string | Update task slug |
| --specification string | string | Update task specification |
| --start-at string | string | Update task start date |
| --state string | string | Update task state |
| --title string | string | Update task title |
wrkq apply
Update task description/specification from file or stdin
$ wrkq apply <PATHSPEC|ID> <FILE|-> [flags]| flag | description | |
|---|---|---|
| --dry-run | Show what would be changed without applying | |
| --format string | string | Input format: md, yaml, json (auto-detected if not specified) |
| --if-match int | int | Only apply if etag matches (0 = no check) |
| --with-metadata | Update metadata fields (title, state, priority, due_at) in addition to description/specification |
wrkq comment
Manage task comments
$ wrkq comment [flags]wrkq comment cat
Print comment details
$ wrkq comment cat <comment-id|c:token>... [flags]| flag | description | |
|---|---|---|
| --json | Output as JSON | |
| --ndjson | Output as newline-delimited JSON | |
| --raw | Print raw comment bodies |
wrkq comment ls
List comments for task(s)
$ wrkq comment ls <task>... [flags]| flag | description | |
|---|---|---|
| --cursor string | string | Pagination cursor |
| --human | Human-readable output | |
| --include-deleted | Include soft-deleted comments | |
| --json | Output as JSON | |
| --limit int | int | Maximum number of results (0 = no limit) |
| --ndjson | Output as NDJSON | |
| --porcelain | Machine-readable output | |
| --reverse | Reverse sort order | |
| --sort string | string | Sort field |
| --tsv | Output as TSV | |
| --yaml | Output as YAML |
wrkq comment rm
Remove comment(s)
$ wrkq comment rm <comment-id|c:token>... [flags]| flag | description | |
|---|---|---|
| --dry-run | Preview without deleting | |
| --if-match int | int | Only delete if comment etag matches (0 = skip check) |
| --purge | Hard delete (remove from database) | |
| --yes | Skip confirmation |
wrkq attach
Manage task attachments
$ wrkq attach [flags]wrkq attach get
Get an attachment file
$ wrkq attach get <attachment-id> [flags]| flag | description | |
|---|---|---|
| --as string | string | Output path (use '-' for stdout) (default "-") |
wrkq attach ls
List attachments for a task
$ wrkq attach ls <task> [flags]| flag | description | |
|---|---|---|
| --cursor string | string | Pagination cursor |
| --json | Output as JSON | |
| --limit int | int | Maximum number of results |
| --ndjson | Output as NDJSON | |
| --porcelain | Machine-readable output |
wrkq attach put
Attach a file to a task
$ wrkq attach put <task> <file|-|> [flags]| flag | description | |
|---|---|---|
| --mime string | string | MIME type (auto-detected if not specified) |
| --name string | string | Filename (defaults to basename of file) |
wrkq attach rm
Remove attachment(s)
$ wrkq attach rm <attachment-id>... [flags]| flag | description | |
|---|---|---|
| --yes | Skip confirmation |
wrkq relation
Manage task relations
$ wrkq relation [flags]wrkq relation add
Created a relation between tasks
$ wrkq relation add <from-task> <kind> <to-task> [flags]wrkq relation ls
List relations for a task
$ wrkq relation ls <task> [flags]| flag | description | |
|---|---|---|
| --json | Output as JSON | |
| --ndjson | Output as newline-delimited JSON | |
| --porcelain | Machine-readable output |
wrkq relation rm
Removed a relation between tasks
$ wrkq relation rm <from-task> <kind> <to-task> [flags]wrkq claim
Atomically claim a task for this session
$ wrkq claim <task> [flags]| flag | description | |
|---|---|---|
| --json | Output JSON | |
| --porcelain | Output compact machine-readable JSON | |
| --scope string | string | Task-scoped sessionRef (defaults to the active runtime scope) |
| --take-over | Supersede the current holder and bump generation | |
| --yes | Skip takeover confirmation |
wrkq release
Release task holdership without changing task state
$ wrkq release <task> [flags]| flag | description | |
|---|---|---|
| --claim-generation int | int | Current claim generation |
| --claim-token string | string | Claim token returned by wrkq claim |
| --force | Operator force release without holder token | |
| --json | Output JSON | |
| --scope string | string | Claimed task sessionRef (defaults to active runtime scope) |
| --yes | Skip force-release confirmation |
wrkq ack
Acknowledge completed tasks
$ wrkq ack <task|id>... [flags]| flag | description | |
|---|---|---|
| --force | Allow ack on non-completed tasks |
wrkq check
Run pre-flight checks on tasks
$ wrkq check [flags]| flag | description | |
|---|---|---|
| --for string | string | Promise owner principal (bare agent slug or agent:<id>) |
| --json | Output as JSON | |
| --ndjson | Output as newline-delimited JSON | |
| --porcelain | Stable machine-readable output | |
| --pretty | Force human-readable output even when not a TTY |
wrkq check blocked
Check if a task is blocked by incomplete dependencies
$ wrkq check blocked <task> [flags]| flag | description | |
|---|---|---|
| --json | Output blockers as JSON | |
| --quiet | Suppress output, exit code only |
wrkq diff
Compare two tasks or task versions
$ wrkq diff <A> [B] [flags]| flag | description | |
|---|---|---|
| --json | Output as JSON | |
| --unified int | int | Lines of unified context (default 3) |
find6
wrkq find
Search for tasks and containers
$ wrkq find [PATH...] [flags]| flag | description | |
|---|---|---|
| --ack-pending | Filter for ack-pending tasks (completed/cancelled, not yet acknowledged) | |
| --assigned-project string | string | Filter by assignee project ID |
| --assignee string | string | Filter by assignee principal ref or bare agent slug |
| --campaign string | string | Find resident and enrolled members of a campaign |
| --caused-by string | string | Filter tasks whose caused_by lineage includes this task ID (e.g. T-00012) |
| --claimed-by string | string | Filter by claim holder principal ref |
| --claimed-node string | string | Filter by server-derived claim node |
| --cursor string | string | Pagination cursor |
| --due-after string | string | Filter tasks due after date (YYYY-MM-DD) |
| --due-before string | string | Filter tasks due before date (YYYY-MM-DD) |
| --has-outcome | Filter for tasks with a curated outcome | |
| --json | Output as JSON | |
| --kind string | string | Filter by task kind: task, subtask, spike, bug, chore |
| --label stringArray | stringArray | Filter by exact task label (repeatable; all must match) |
| --limit int | int | Limit number of results |
| --ndjson | Output as newline-delimited JSON | |
| --parent-task string | string | Filter subtasks of a specific parent task (ID or path) |
| --porcelain | Stable machine-readable output | |
| --pretty | Force human-readable table output even when not a TTY | |
| -0, --print0 | NUL-separated output | |
| --requested-by string | string | Filter by requester project ID |
| --reverse | Reverse sort order | |
| --slug-glob string | string | Filter by slug glob pattern (e.g. 'login-*') |
| --sort string | string | Sort by field: updated_at, created_at, id, path |
| --state string | string | Filter by state (or 'all' for everything) |
| --type string | string | Filter by type: t (task), p (project/container) |
wrkq search
Search task and comment text
$ wrkq search <query> [PATH...] [flags]| flag | description | |
|---|---|---|
| --assignee string | string | Filter by assignee principal ref or bare agent slug |
| --candidate-limit int | int | Candidate chunks to retrieve before aggregation (default 300) |
| --explain | Include ranking diagnostics in JSON output | |
| --fresh | Fail if the search index is stale | |
| --human | Force human-readable output | |
| --json | Output as JSON | |
| --kind string | string | Filter by task kind |
| --label stringArray | stringArray | Filter by exact task label (repeatable; all must match) |
| --limit int | int | Maximum number of task results (default 20) |
| --ndjson | Output as newline-delimited JSON | |
| --porcelain | Stable machine-readable output | |
| --pretty | Force human-readable output even when not a TTY | |
| --reverse | Reverse sort order | |
| --sort string | string | Sort by relevance, updated_at, or created_at (default "relevance") |
| --state string | string | Filter by state (default open, use all for non-deleted states) |
wrkq index
Inspect and rebuild the local search index
$ wrkq index [flags]wrkq index pause
Pause background search indexing
$ wrkq index pause [flags]wrkq index rebuild
Rebuild the local search index
$ wrkq index rebuild [flags]| flag | description | |
|---|---|---|
| --foreground | Run rebuild in the foreground |
wrkq index resume
Resume background search indexing
$ wrkq index resume [flags]wrkq index status
Show local search index status
$ wrkq index status [flags]| flag | description | |
|---|---|---|
| --json | Output as JSON |
wrkq index update
Index pending canonical changes
$ wrkq index update [flags]wrkq index vacuum
Vacuum the local search index
$ wrkq index vacuum [flags]wrkq log
Show change history for a task, container, or promise
$ wrkq log <PATHSPEC|ID> [flags]| flag | description | |
|---|---|---|
| --cursor string | string | Pagination cursor from previous page |
| --json | Output as JSON | |
| --limit int | int | Limit number of events (0 = unlimited) (default 50) |
| --oneline | Compact one-line format | |
| --patch | Show detailed payload changes | |
| --porcelain | Machine-readable output with cursor on stderr | |
| --since string | string | Show changes since date/time (YYYY-MM-DD or RFC3339) |
| --until string | string | Show changes until date/time (YYYY-MM-DD or RFC3339) |
wrkq timeline
Show the container-neutral composite timeline.
Entries are ordered by durable event id. Outcome display collapses multiple task.outcome events to the latest text and marks tasks whose outcome was amended.
$ wrkq timeline <container> [flags]| flag | description | |
|---|---|---|
| --cursor string | string | Continue an event-id-fenced snapshot page |
| --limit int | int | Maximum entries in this page |
wrkq usage
alias info
Displays the embedded WRKQ-USAGE.md documentation for agents and users.
$ wrkq usage [flags]| flag | description | |
|---|---|---|
| --json | Output as JSON |
watch2
wrkq monitor
Stream and query task events for agent observation via the Claude Monitor tool.
Subcommands: watch [TASK...] Stream task events (Monitor feed) wait [TASK...] Block until condition is met, then exit
Examples: wrkq monitor watch T-04466 --state-only --until state=completed --timeout 30m wrkq monitor wait T-1 T-2 T-3 --until all-terminal --stall-after 30m wrkq monitor wait EN-00012 --until terminal --timeout 10m
Exit codes: 0=condition met, or a bounded follow with no --until ended on its --timeout/--stall-after clock; 1=--until left unmet by timeout/stall; 2=selector error; 3=stream error.
$ wrkq monitor [flags]wrkq monitor wait
Block until the --until condition is satisfied for watched tasks, then exit. Shares the exact condition evaluator and exit-code contract with monitor watch --until.
Useful for scripted sequencing: wrkq monitor wait T-00001 --until state=completed An envelope group waits with: wrkq monitor wait EN-00012 --until terminal
$ wrkq monitor wait [TASK...] [flags]| flag | description | |
|---|---|---|
| --stall-after string | string | Exit after this duration with no new events |
| --timeout string | string | Maximum wait duration (e.g. 30m) |
| --until string | string | Condition: state=<s>[,<s>...], all-terminal, acked, or terminal |
wrkq monitor watch
Stream typed NDJSON events for watched tasks. Emits per-event lines and exactly one terminal line before exit. With no --until, follows until --timeout or --stall-after expires, if either is given, and otherwise indefinitely.
The feed starts at the current high-water mark: it tails what happens NEXT. Use --since <id> to start from an earlier event (--since 0 replays the whole log) or --last N to replay the last N events before following.
Selectors: T-XXXXX friendly IDs or container paths (e.g. inbox/my-task), plus R-XXXXX rooms and EN-XXXXX envelopes. A task selector also carries that task's room, so state changes and the conversation stream on ONE selector; --state-only still emits only task lifecycle changes. An EN- selector that is a fan-out group head covers every envelope of that group. Invalid selectors fail with exit code 2 before any streaming.
$ wrkq monitor watch [TASK...] [flags]| flag | description | |
|---|---|---|
| --event-type string | string | Comma-separated event_type filter |
| --format string | string | Output format: ndjson or compact |
| --last int | int | Replay last N events before following |
| --ndjson | Output as NDJSON | |
| --raw | Whole-log unfiltered tail as NDJSON (honors --since, --timeout, --stall-after) | |
| --scope string | string | Filter by scope ref |
| --since int | int | Start from event ID (overrides high-water default) |
| --stall-after string | string | Exit after this duration with no new events; applies with or without --until |
| --state-only | Only emit lifecycle state-change events | |
| --timeout string | string | Maximum follow duration (e.g. 30m); bounds the follow with or without --until |
| --until string | string | Condition: state=<s>[,<s>...], all-terminal, acked, or terminal |
wrkq webhook
Manage global webhook subscriptions.
Global webhooks live on the internal root container and are inherited by every project, so a sink registered here fires for all projects without per-project duplication. Per-project or per-container webhooks are managed with 'wrkq container set --webhook-url'.
Examples: wrkq webhook list wrkq webhook add http://127.0.0.1:18451/api/webhooks/wrkq wrkq webhook rm http://127.0.0.1:18451/api/webhooks/wrkq
$ wrkq webhook [flags]wrkq webhook add
Add a global webhook URL
$ wrkq webhook add <url> [flags]wrkq webhook list
List global webhook URLs
$ wrkq webhook list [flags]wrkq webhook rm
Remove a global webhook URL
$ wrkq webhook rm <url> [flags]agents8
wrkq agent-info
Displays a condensed quick reference of essential wrkq commands for coding agents.
$ wrkq agent-info [flags]| flag | description | |
|---|---|---|
| --json | Output as JSON |
wrkq agent-context
Resolve the active agent scope from --scope, AGENT_SCOPE_REF, ASP_SCOPE_REF, ASP_HANDLE, or ASP_AGENT_ID + ASP_PROJECT and print the result.
Useful for debugging agent runtime context. Works without a database connection — actor / container UUID lookups are best-effort extras.
Exits 0 on success, 2 when no scope is resolvable.
Output defaults to a human-readable table on a TTY and JSON when piped. Use --json or --human to force a mode.
$ wrkq agent-context [flags]| flag | description | |
|---|---|---|
| --human | Force human-readable output | |
| --json | Force JSON output | |
| --scope string | string | Override scope (ScopeRef like agent:cody:project:wrkq or handle like cody@wrkq) |
wrkq agent
Run a chat turn against the predefined agent "seshat".
This is a thin pass-through to 'hrcchat turn seshat'. The 'hrcchat' binary must be on PATH; wrkq does not depend on it at build time. Project context is resolved by hrcchat itself (ASP_PROJECT), exactly as for any other caller.
The prompt is taken from positional args (joined), --file, or stdin ("-"). All hrcchat output is streamed through unchanged.
Common 'hrcchat turn' flags are surfaced directly (--new, --format, --follow, --file). Anything after "--" is forwarded verbatim, so any other hrcchat flag remains reachable without a wrkq change:
wrkq agent "summarize open risks" wrkq agent --follow 30s "work the inbox" echo "long prompt" | wrkq agent - wrkq agent "do X" -- --stall-after 20m --reply-to msg_01J...
$ wrkq agent [prompt] [-- extra hrcchat-turn args] [flags]| flag | description | |
|---|---|---|
| --file string | string | Read prompt from file |
| --follow string | string | Emit bounded progress at the given interval (e.g. 30s) |
| --format string | string | Output format: tree, compact, ndjson, json |
| --new | Clear context before dispatching (clean slate) |
wrkq whoami
Displays the resolved external principal and runtime scope based on configuration and environment.
$ wrkq whoami [flags]| flag | description | |
|---|---|---|
| --json | Output as JSON |
wrkq handoff
Manage agent session handoffs
$ wrkq handoff [flags]wrkq handoff create
Create a new pending handoff for the resolved agent/project scope.
Exactly one body source must be explicitly selected: --body or --body-file.
$ wrkq handoff create [flags]| flag | description | |
|---|---|---|
| --body string | string | Inline Markdown body (mutually exclusive with --body-file) |
| --body-file string | string | Path to a Markdown body file, or '-' for stdin (mutually exclusive with --body) |
| --dry-run | Validate inputs and print the prospective handoff without writing it | |
| --human | Force human-readable output | |
| --idempotency-key string | string | Idempotency key to safely retry create without producing duplicates |
| --json | Force JSON output | |
| --meta string | string | Optional JSON object of additional metadata |
| --ndjson | Force NDJSON output | |
| --profile string | string | Named profile to resolve scope/defaults from |
| --scope string | string | Override scope (ScopeRef like agent:cody:project:wrkq or handle like cody@wrkq) |
| -t, --title string | string | Handoff title (required) |
wrkq handoff get
Get a single handoff by ID
$ wrkq handoff get <handoff-id> [flags]| flag | description | |
|---|---|---|
| --human | Force human-readable output | |
| --json | Force JSON output |
wrkq handoff list
List handoffs for the resolved agent/project scope
$ wrkq handoff list [flags]| flag | description | |
|---|---|---|
| --cursor string | string | Pagination cursor from a previous page |
| --human | Force human-readable output | |
| --json | Force JSON output | |
| --limit int | int | Maximum number of results (0 = server default) |
| --ndjson | Force NDJSON output | |
| --porcelain | Emit next_cursor=<token> on stderr (mirrors 'wrkq comment ls --porcelain') | |
| --scope string | string | Override scope (ScopeRef like agent:cody:project:wrkq or handle like cody@wrkq) |
| --status string | string | Status filter: pending, acknowledged, or all (default: pending) (default "pending") |
wrkq handoff search
Search handoffs by title, body, scope, or status
$ wrkq handoff search <query> [flags]| flag | description | |
|---|---|---|
| --cursor string | string | Pagination cursor from a previous page |
| --human | Force human-readable output | |
| --json | Force JSON output | |
| --limit int | int | Maximum number of results (0 = server default) |
| --ndjson | Force NDJSON output | |
| --porcelain | Emit next_cursor=<token> on stderr (mirrors 'wrkq handoff list --porcelain') | |
| --scope string | string | Override scope (ScopeRef like agent:cody:project:wrkq or handle like cody@wrkq) |
| --status string | string | Status filter: pending, acknowledged, or all (default: pending) (default "pending") |
wrkq promise
Manage future-attention promises
$ wrkq promise [flags]wrkq promise abandon
Deliberately abandon a promise after review
$ wrkq promise abandon <promise> [flags]| flag | description | |
|---|---|---|
| --etag int | int | Alias for --if-match |
| --if-match int | int | Only mutate if the promise etag matches |
| --json | Output as JSON | |
| --ndjson | Output as newline-delimited JSON | |
| --note string | string | Review note (literal, @file, or - for stdin) |
| --porcelain | Stable machine-readable output | |
| --pretty | Force human-readable output even when not a TTY |
wrkq promise add
Record a promise to revisit a subject
$ wrkq promise add [flags]| flag | description | |
|---|---|---|
| --campaign string | string | Alias for --container |
| --container string | string | Attach to a container |
| --for string | string | Owner principal (bare agent slug or agent:<id>) |
| --in string | string | Relative review duration resolved by the API (for example 7d or 36h) |
| --json | Output as JSON | |
| --meta string | string | Metadata JSON object |
| --meta-file string | string | Read metadata JSON from a file or - for stdin |
| --ndjson | Output as newline-delimited JSON | |
| --on-behalf | Assert the named owner requested this accepted promise | |
| --porcelain | Stable machine-readable output | |
| --pretty | Force human-readable output even when not a TTY | |
| --question string | string | Review question (literal, @file, or - for stdin) |
| --review-at string | string | Absolute review timestamp (forwarded verbatim to the API) |
| --subject string | string | Subject snapshot (literal, @file, or - for stdin) |
| --task string | string | Attach to a task |
wrkq promise attach
Attach a promise to a task or container
$ wrkq promise attach <promise> [flags]| flag | description | |
|---|---|---|
| --campaign string | string | Alias for --container |
| --container string | string | Attach to a container |
| --etag int | int | Alias for --if-match |
| --if-match int | int | Only mutate if the promise etag matches |
| --json | Output as JSON | |
| --ndjson | Output as newline-delimited JSON | |
| --porcelain | Stable machine-readable output | |
| --pretty | Force human-readable output even when not a TTY | |
| --task string | string | Attach to a task |
wrkq promise detach
Detach a promise while preserving its subject snapshot
$ wrkq promise detach <promise> [flags]| flag | description | |
|---|---|---|
| --etag int | int | Alias for --if-match |
| --if-match int | int | Only mutate if the promise etag matches |
| --json | Output as JSON | |
| --ndjson | Output as newline-delimited JSON | |
| --porcelain | Stable machine-readable output | |
| --pretty | Force human-readable output even when not a TTY |
wrkq promise edit
Edit an open promise
$ wrkq promise edit <promise> [flags]| flag | description | |
|---|---|---|
| --etag int | int | Alias for --if-match |
| --if-match int | int | Only mutate if the promise etag matches |
| --in string | string | Relative review duration resolved by the API |
| --json | Output as JSON | |
| --meta string | string | Metadata JSON object |
| --meta-file string | string | Read metadata JSON from a file or - for stdin |
| --ndjson | Output as newline-delimited JSON | |
| --porcelain | Stable machine-readable output | |
| --pretty | Force human-readable output even when not a TTY | |
| --question string | string | Review question (literal, @file, or - for stdin; empty clears) |
| --review-at string | string | Absolute review timestamp (forwarded verbatim to the API) |
| --subject string | string | Subject snapshot (literal, @file, or - for stdin) |
wrkq promise list
List promises
$ wrkq promise list [flags]| flag | description | |
|---|---|---|
| --campaign string | string | Alias for --container |
| --container string | string | Filter by attached container |
| --for string | string | Owner principal (bare agent slug or agent:<id>) |
| --json | Output as JSON | |
| --ndjson | Output as newline-delimited JSON | |
| --porcelain | Stable machine-readable output | |
| --pretty | Force human-readable output even when not a TTY | |
| --state string | string | Filter by open, resolved, abandoned, or all |
| --task string | string | Filter by attached task |
wrkq promise ready
List promises ready for review
$ wrkq promise ready [flags]| flag | description | |
|---|---|---|
| --for string | string | Owner principal (bare agent slug or agent:<id>) |
| --include-global | Include standalone owner-global promises | |
| --json | Output as JSON | |
| --ndjson | Output as newline-delimited JSON | |
| --porcelain | Stable machine-readable output | |
| --pretty | Force human-readable output even when not a TTY |
wrkq promise renew
Record a review and choose the next review time
$ wrkq promise renew <promise> [flags]| flag | description | |
|---|---|---|
| --etag int | int | Alias for --if-match |
| --if-match int | int | Only mutate if the promise etag matches |
| --in string | string | Relative review duration resolved by the API |
| --json | Output as JSON | |
| --ndjson | Output as newline-delimited JSON | |
| --note string | string | Review note (literal, @file, or - for stdin) |
| --porcelain | Stable machine-readable output | |
| --pretty | Force human-readable output even when not a TTY | |
| --review-at string | string | Absolute review timestamp (forwarded verbatim to the API) |
wrkq promise resolve
Resolve a promise after review
$ wrkq promise resolve <promise> [flags]| flag | description | |
|---|---|---|
| --etag int | int | Alias for --if-match |
| --if-match int | int | Only mutate if the promise etag matches |
| --json | Output as JSON | |
| --ndjson | Output as newline-delimited JSON | |
| --note string | string | Review note (literal, @file, or - for stdin) |
| --porcelain | Stable machine-readable output | |
| --pretty | Force human-readable output even when not a TTY |
wrkq check-inbox
List open tasks in the inbox
$ wrkq check-inbox [flags]| flag | description | |
|---|---|---|
| --json | Output as JSON | |
| --ndjson | Output as newline-delimited JSON | |
| --porcelain | Stable machine-readable output |
projects7
wrkq projects
Lists all top-level projects (containers with no parent) in the database.
This command always shows all projects regardless of WRKQ_PROJECT_ROOT, making it easy to see what projects exist when working in a scoped context.
Examples: wrkq projects # List all projects in table format wrkq projects --json # Output as JSON wrkq projects -1 # One project slug per line wrkq projects -a # Include archived projects
$ wrkq projects [flags]| flag | description | |
|---|---|---|
| -a, --all | Include archived projects | |
| --cursor string | string | Pagination cursor from previous page |
| --json | Output as JSON | |
| --limit int | int | Maximum number of results to return (0 = no limit) |
| --ndjson | Output as newline-delimited JSON | |
| -0, --nul | NUL-separated output | |
| -1, --one | One entry per line | |
| --porcelain | Machine-readable output |
wrkq container
Manage containers
$ wrkq container [flags]wrkq container cat
Print container details
$ wrkq container cat <path|id> [flags]| flag | description | |
|---|---|---|
| --json | Output as JSON | |
| --ndjson | Output as newline-delimited JSON | |
| --no-frontmatter | Print body only without front matter | |
| --porcelain | Machine-readable output |
wrkq container set
Update container configuration fields.
A webhook subscription is either a bare URL (receives every event family) or a URL narrowed to one or more event classes: task, workflow, container — or an exact event name. --webhook-events narrows every URL passed with --webhook-url / --add-webhook-url in the same invocation; --webhook-urls takes the stored JSON form directly and may mix bare and narrowed entries.
Examples:
wrkq container set inbox --webhook-urls '["http://localhost/hook/{ticket_id}"]'
wrkq container set inbox --webhook-urls '[{"url":"http://localhost/hook","events":["container"]}]'
wrkq container set P-00001 --webhook-url http://localhost/hook/{ticket_id}
wrkq container set inbox --webhook-url http://localhost/hook --webhook-events container
wrkq container set inbox --add-webhook-url http://localhost/hook2
wrkq container set inbox --add-webhook-url http://localhost/hook2 --webhook-events task,workflow
wrkq container set inbox --remove-webhook-url http://localhost/old-hook
wrkq container set --all --remove-webhook-url http://localhost/old-hook$ wrkq container set <container> [flags]| flag | description | |
|---|---|---|
| --add-webhook-url stringArray | stringArray | Add webhook URL to existing list (repeatable) |
| --all | Apply to all containers | |
| --if-match int | int | Conditional update (etag) |
| --remove-webhook-url stringArray | stringArray | Remove webhook URL from existing list, matched by URL (repeatable) |
| --webhook-events strings | strings | Narrow --webhook-url/--add-webhook-url to these event classes (task, workflow, container) or exact event names |
| --webhook-url stringArray | stringArray | Webhook URL (repeatable) |
| --webhook-urls string | string | Webhook subscriptions JSON array; entries are "url" or {"url":...,"events":[...]} |
wrkq campaign
Manage a container's campaign lifecycle.
Campaigns adorn ordinary containers; the container kind and archive state remain independent. Brief/specification edits are mechanically retained as full-body container.updated event snapshots. Use kind=decision container comments for the curated judgment behind a specification change.
$ wrkq campaign [flags]wrkq campaign activate
Activate a draft campaign
$ wrkq campaign activate <container> [flags]| flag | description | |
|---|---|---|
| --if-match int | int | Only activate if the campaign etag matches |
wrkq campaign close
Declare campaign closure.
Completed close requires every resident or enrolled member to be completed, cancelled, archived, deleted, moved, or unenrolled first. Completed members without outcomes are displayed but never block close. Cancelled close is a wholesale abandonment and leaves open members unchanged.
$ wrkq campaign close <container> [flags]| flag | description | |
|---|---|---|
| --if-match int | int | Only close if the container etag matches |
| --state string | string | Terminal campaign state: completed or cancelled |
wrkq campaign convert
Convert a plain container into a draft or active campaign
$ wrkq campaign convert <container> [flags]| flag | description | |
|---|---|---|
| -d, --description string | string | Campaign brief (literal, @file, or - for stdin) |
| --if-match int | int | Only convert if the container etag matches |
| --labels string | string | Campaign labels (comma shorthand unless starting '[' for JSON array; empty/[] clears; JSON allows commas) |
| --specification string | string | Campaign specification (literal, @file, or - for stdin) |
| --state string | string | Initial campaign state: draft or active (default "active") |
wrkq campaign edit
Edit campaign content.
The generic container.updated event snapshots BOTH complete bodies after every edit. Use a kind=decision container comment for curated amendment rationale.
$ wrkq campaign edit <container> [flags]| flag | description | |
|---|---|---|
| -d, --description string | string | Campaign brief (literal, @file, or - for stdin; empty clears) |
| --if-match int | int | Only edit if the container etag matches |
| --labels string | string | Campaign labels (comma shorthand unless starting '[' for JSON array; empty/[] clears; JSON allows commas) |
| --specification string | string | Campaign specification (literal, @file, or - for stdin; empty clears) |
wrkq campaign portfolio
Show the complete campaign portfolio aggregate
$ wrkq campaign portfolio [flags]| flag | description | |
|---|---|---|
| --include-archived | Include archived campaign containers | |
| --state strings | strings | Campaign states to include (repeatable or comma-separated) |
wrkq server
Manage the wrkq daemon server
$ wrkq server [flags]| flag | description | |
|---|---|---|
| --addr string | string | Listen/status address |
| --db-path string | string | Database path override |
| --token string | string | Shared token for local auth |
| --unix string | string | Listen/status Unix socket path |
| --unsafe-no-token | Allow non-loopback listen without a token (dev only) |
wrkq server health
Check wrkq daemon server health
$ wrkq server health [flags]wrkq server restart
Restart the wrkq daemon server
$ wrkq server restart [flags]| flag | description | |
|---|---|---|
| --daemon | Run as a background process when launchd is not loaded | |
| --force | Escalate to SIGKILL if graceful shutdown times out | |
| --foreground | Run in the foreground when launchd is not loaded | |
| --timeout-ms int | int | Shutdown/startup timeout in milliseconds (default 30000) |
wrkq server serve
Run the wrkq daemon server in the foreground
$ wrkq server serve [flags]wrkq server start
Start the wrkq daemon server
$ wrkq server start [flags]| flag | description | |
|---|---|---|
| --daemon | Run as a background process when launchd is not loaded | |
| --foreground | Run in the foreground when launchd is not loaded | |
| --timeout-ms int | int | Startup timeout in milliseconds (default 30000) |
wrkq server status
Show wrkq daemon server status
$ wrkq server status [flags]| flag | description | |
|---|---|---|
| --json | Output as JSON |
wrkq server stop
Stop the wrkq daemon server
$ wrkq server stop [flags]| flag | description | |
|---|---|---|
| --force | Escalate to SIGKILL if graceful shutdown times out | |
| --timeout-ms int | int | Shutdown timeout in milliseconds (default 5000) |
wrkq rpc
Serve wrkq/wrkf JSON-RPC over stdio
$ wrkq rpc --stdio [flags]| flag | description | |
|---|---|---|
| --stdio | Use stdin/stdout JSON-RPC transport |
wrkq completion
Generate the autocompletion script for the specified shell
$ wrkq completion [flags]wrkq completion bash
Generate the autocompletion script for bash
$ wrkq completion bash| flag | description | |
|---|---|---|
| --no-descriptions | disable completion descriptions |
wrkq version
Displays version, commit, and build date information.
$ wrkq version [flags]| flag | description | |
|---|---|---|
| --json | Output as JSON |
wrkq comment add
Add a comment to a task or container.
Comment text can be supplied with -m/--message or as a positional argument. Use '-' as the comment-text argument to read the body from stdin. If comment-text is omitted, the body is also read from stdin.