CLI

View verbs

The kraft view verbs: read the board, follow a running item, and review its diff and documents.

kraft view reads work items without changing them. Wherever a command takes an ID, you can omit it inside that item's worktree. Every verb here accepts --json; the exceptions are in Output format.

Verbs at a glance

VerbWhat it does
view listThe board, scoped to the repo you are in.
view showOne work item in full.
view searchSearches specs, plans and session summaries.
view logsA worker session's log.
view eventsThe item's node transitions, gate decisions and escalations.
view watchA live board, redrawn on every event.
view diffWhat the agent changed.
view docsDocuments linked to the item, and the spec or plan it was filed with.
view docPrints one document, or opens it in an editor.
view artifactThe document the pending gate is about.
view threadsReview threads on the item, drafts marked.
view compareDiffs two review targets, such as two attempts.
view mr, pipelines, jobs, job-log, merged, labelsThe item's merge request, CI and project labels, as the forge has them. Added in 2.5
view storageWhat worktrees use against the disk quota and limit. Added in 2.1

Reading the board

view list

kraft view list [flags]

The board, scoped to the repo you are in.

FlagTypeDefaultMeaning
--allswitchoffSpans every repo, ignoring where you stand.
--repopaththe repo you are standing inPicks one repo.
--statusstored or displayed statusevery status but abandonedA stored status, such as needs_human, or a displayed one, such as failed. A word both have means the stored status; needs you may be typed needs_you.
--include-abandonedswitchoffAdds abandoned items, cancelled ones included.

What view list prints

view list prints one line per item, with the columns ID, STATUS, GATE, NODE and TITLE. GATE is the gate the item waits at, and NODE the node it is on, with 3/6 after it while the item reports its progress through a plan (task 3 of 6). An empty cell reads -, and the last column is cut with … to fit the terminal. With no items, it prints (nothing).

STATUS is the item's displayed status, the word the web board and the console show, with _ printed as a space (needs you). --json carries it as display_status, beside the stored status. --status takes either word, and a word both have, such as waiting, means the stored status: a rate-limited item shows waiting but isn't listed by --status waiting. Type needs you with its space or as needs_you.

ID                                STATUS     GATE           NODE                TITLE
3f9c1e7a5b2d4c80a6e1d97f0b34c2aa  needs you  spec_approval  spec_approval       Fix flaky retry
b81d0c42e6a94f3d8c5a7e19f2046b13  running    -              implementation 3/6  Add JSON export
07ae5d3c91b84e26a4f8c0d1e7b352f9  paused     -              -                   Bump the lockfile

A sliced item's STATUS ends with (slices: 2 done, 1 needs you), and each of its slices follows it, indented, with the slice's status, node and cost in the TITLE column. --status lists a parent whose slice matches with just the slices that match.

ID                                  STATUS                                GATE  NODE            TITLE
8c2f4a1d9e3b4750b6a8d0c1e7f92b34    needs you (slices: 1 done, 1 needs…)  -     slices          Add the cache
  5d1e7a0c3b924f68a1c4e9d2b7058f13  done                                  -     verification    $0.42  Add the cache · slice 1: Reads
  e90b3c5d7a114e28b0f6c2a8d4713e59  needs you                             -     implementation  $0.18  Add the cache · slice 2: Writes

view list --json carries display_status on every row, and slices and children on a parent's row.

view show

kraft view show [flags] [ID]

One work item in full. With no ID, the one whose worktree you are in, or the in-place item whose branch your checkout is on. It takes no flags.

What view show prints

view show prints one key value line for each of these fields the item has, and None for one with no value. dependencies lists the items it comes after as ID (status), or none. --json prints the item's full detail instead.

queued says which start the item waits to make and since when. When no busy slot holds it, it also says why: waiting for the checkout: “<title>” is using it for an in-place item, or held by the worktree storage limit: 12G counted against the 10G limit.

id                3f9c1e7a5b2d4c80a6e1d97f0b34c2aa
title             Fix flaky retry
...
repo              /Users/you/code/app
status            needs_human
display_status    needs you
current_node_id   spec_approval
pending_gate      spec_approval
gate_artifact     items/3f9c1e7a5b2d4c80a6e1d97f0b34c2aa/docs/spec.md
...
next_node_id      plan
FieldMeaning
id, title, description, repo, bead_idWhat the item is and where it lives.
status, display_status, current_node_id, next_node_idWhere it stands: its stored status, its displayed status as view list prints it, the node it is on, and the node after.
pending_gate, gate_artifactThe gate it waits at, and the name of the document that gate is about: items/<id>/docs/<kind>.md under Kraft's run/ folder, or .engineering/<kind>s/<id>.md in the worktree for one written before Kraft kept one folder per item. kraft view artifact prints it.
worktree_pathWhere its worktree is.
attachmentsThe spec or plan it was filed with, and what each trimmed.
progressWhere the implementer is in its plan, such as "3 of 6", when it is on that node.
usageWhat the item has spent. See below.
policy_overrideThe item's own policy override, only when it has one.
concernsWhat a task flagged about its own work when it finished, since the last gate that was decided. Only when there is one.
chainOn an item filed with a one-off chain, after status: one-off, extends <chain> when it extends one, then awaiting review, approved by <who> (<door>) <when> or library-only, joined by ·. Added in 2.5
in_placeyes on an item that runs in place; absent on any other. Added in 2.1
stop_kindOn a stopped item, the kind of stop, such as gate, cap or checkout. Added in 2.1
stop_reason, suggested_actionOn a stopped item, why it stopped, and the one command the chain proposes.
slices, children, slice_ofOn a sliced parent, its slices by state, then one line per slice: key, ID, displayed status (as view list prints it), node, cost and title. On a slice, its parent's ID and its key. Added in 2.6
nextOn a stop on a dollar cap the item can raise, and with no suggested_action: kraft item raise-budget ID --usd N, the command behind the board's Raise cap.

usage lists uncached input, cache writes, cache reads and output tokens, then cost. A session recorded before cache tokens were split out has a single input figure, counted under in, and the line says (cache not split on older sessions). A token_budget counts all four kinds.

A session reports its output tokens when it ends, and one that was paused or killed never does. While a session's count is missing, the line reads at least N out, or out not known when no session has reported one.

The cap next names is the item's own, or its policy's item-wide budget_usd. A stop on a cap raise-budget doesn't take adds no next line.

kraft view search [flags] QUERY

Searches the document index: specs, plans and session summaries.

FlagTypeDefaultMeaning
--limitinteger20Caps the result count.

Following a running item

view logs

kraft view logs [flags] [ID]

view logs reads the newest session's log. While the item is stopped, it reads the log of the session that stopped it instead, such as the failed test command. It then names the newest session on stderr, such as the auto-escalation that started after the stop.

FlagTypeDefaultMeaning
-f, --followswitchoffFollows the newest session until it stops. While the item is stopped, stderr names the session that stopped it.
-ninteger50Sets the backlog lines shown first.
--sessionsession IDthe newest; while the item is stopped and with no -f, the one that stopped itReads that session of the item.
--agentsub-agent ID or mainevery agentShows only that Claude Code sub-agent's lines, or main for the main agent's. Applied before -n; output that isn't JSON stays. Added in 2.6

-n 0 -f prints only lines written after it starts.

A session ID is unique only within its work item, so --session reads the session of the item you name, or of the worktree you are in. With neither, it asks for the session by its ID alone, which works only when one session has that ID: Kraft otherwise answers 404 and names the item's route. When view logs names another session on stderr, it prints the whole command, kraft view logs <item> --session <id>.

view events

kraft view events [flags] [ID]

Node transitions, gate decisions and escalations.

FlagTypeDefaultMeaning
--afterinteger0Shows only events after that sequence number.
--typeevent typeevery typeFilters by type; see Events for every type.
-f, --followswitchoffStreams until the item completes or is abandoned; with --json, every event is one line of NDJSON.

view watch

kraft view watch [flags]

A live board, redrawn on every event. Needs a terminal. It takes no --json.

FlagTypeDefaultMeaning
--repopaththe repo you are standing inPicks the repo.

Reviewing before you approve

view diff

kraft view diff [flags] [ID]

The coloured diff, through $PAGER. For an in-place item, its branch's commits only, never your uncommitted or untracked files.

FlagTypeDefaultMeaning
--statswitchoffSize of the change: per-file counts only.
--name-onlyswitchoffChanged and untracked paths.
-w, --ignore-whitespaceswitchoffLeaves out files whose only change is whitespace.
--no-pagerswitchoffPrints straight to the terminal.

What the diff shows

Once an item has commits, view diff and view diff --stat show two blocks. The change under review is every commit on the item's branch since its base, the spec and plan documents included. Uncommitted is what an agent left in the worktree without committing; Kraft commits after every task, so it is usually empty and reads "(nothing uncommitted)". An item with no commits yet shows one block.

A truncated diff always says so on its last line. Files the agent wrote without git add are listed separately, because a unified diff doesn't show them.

view docs

kraft view docs [flags] [ID]

Specs, plans and summaries linked to the item, including the spec or plan it was filed with.

FlagTypeDefaultMeaning
--attachmentspec or plannoneShows the spec or plan as Kraft stored it at filing, which is what its worktree gets. It is the only way to read the document before the item starts.
--jsonswitchoffPrints the same list; with --attachment, prints its path, title and content.
--no-pagerswitchoffWith --attachment, prints straight to the terminal.

A document the index doesn't hold yet is listed as attachment:<id>:spec (or :plan). Kraft reads it from the item's worktree, or, before the item starts, from the copy stored at filing. kraft view doc takes that ID.

The document a pending gate is about is listed as gate:<id>:<gate> until approval indexes it. It is read from disk and isn't searchable until then, because it is still a draft. kraft view doc takes that ID too.

view doc

kraft view doc [flags] ID

Prints one document, or opens it in an editor.

FlagTypeDefaultMeaning
--openoptional editor: code, cursor, zed, obsidian or systemnot opened; with no editor named, the Default editor in Settings, else KRAFT_EDITOR, else the OS openerOpens the document in an editor on the server's machine. system is the OS opener.
--no-pagerswitchoffPrints straight to the terminal.
RefusalCause
409 naming view docs --attachmentAn attachment: ID opens only once the item has started and has a worktree.

view artifact

kraft view artifact [flags] [ID]

The document the pending gate is about.

FlagTypeDefaultMeaning
--no-pagerswitchoffPrints straight to the terminal.

Reading the forge

Added in 2.5

A step reads its item's merge request and CI through these verbs, never through gh or glab, and holds no forge login to do it. The server derives the project and the merge request from the item.

Each verb takes [ID] and --repo MOUNT, a workspace member's mount path. status is the forge's own word. A workspace item reads its root repository; --repo MOUNT reads the member mounted there. A rate limit answers 429, and an unusable forge 502.

In a sandboxed worker the same verbs print the JSON payload. Ids come from view pipelines and view jobs.

view mr

kraft view mr [flags] [ID]

The merge request: !N title [state] labels url. Refused with 404 until the item has one. It takes only --repo.

view pipelines

kraft view pipelines [flags] [ID]

One line each: id kind status ref url. kind is branch, merge_request, train or merge_group. The newest 20 only (GitHub: 20 branch runs and 20 merge-queue runs): jobs and job-log answer 404 for an older one. It takes only --repo.

view jobs

kraft view jobs [flags] [ID]

The jobs of one of the item's pipelines, one line each. The first 100 only: a job past them answers 404.

FlagTypeDefaultMeaning
--pipelinepipeline IDnone given: requiredA pipeline ID from view pipelines.
--repomount paththe root repositoryReads that workspace member.

view job-log

kraft view job-log [flags] [ID]

The last lines of one job's log, colour codes removed.

FlagTypeDefaultMeaning
--pipelinepipeline IDnone given: requiredA pipeline ID from view pipelines.
--jobjob IDnone given: requiredA job ID from view jobs.
-n, --linesinteger, 1 to 5000200How many lines from the end.
--repomount paththe root repositoryReads that workspace member.

view merged

kraft view merged [flags] [ID]

The latest merged merge requests into the base branch.

FlagTypeDefaultMeaning
--limitinteger, 1 to 10020How many.
--repomount paththe root repositoryReads that workspace member.

view labels

kraft view labels [flags] [ID]

The project's labels. It takes only --repo.

Reviewing threads and comparing attempts

view threads

kraft view threads [flags] [ID]

Review threads on the item, drafts marked.

FlagTypeDefaultMeaning
--openswitchoffDrops resolved ones.

Each line range carries its side as the diff marks it:

  • calc.py:+8 is new line 8.
  • calc.py:-3 to -4 is old lines 3 to 4.
  • calc.py:-2 to +2 is a removed line through its replacement.

view compare

kraft view compare [flags] [ID]

Diffs two review targets, such as two attempts. With neither --from nor --to it shows the whole change so far.

FlagTypeDefaultMeaning
--frombase, attempt:N, last_review or latestbaseWhere the diff starts. latest is the working tree; attempt:N needs a pending gate.
--tobase, attempt:N, last_review or latestlatestWhere the diff ends.
--nodesnode IDs, comma-separatedevery nodeLimits it to files those node IDs touched.
--stat, --name-only, -wswitchoffMirror view diff.
--no-pagerswitchoffPrints straight to the terminal.
--jsonswitchoffEach file also carries viewed.

The size of the change between two attempts:

kraft view compare --from attempt:1 --to attempt:2 --stat

base and latest resolve at any time. last_review needs a review you have already submitted, and attempt:N needs a pending gate. latest can only be the --to end.

Worktree disk use

Added in 2.1

view storage

kraft view storage [flags]

It takes no flags but --json.

view storage prints what the worktrees use against the quota and limit, the totals per category, and one line per item, largest first, with its title, status, size, documents, step outputs and age. A finished item that archiving would free is marked yes under RECLAIMABLE. A folder that belongs to no item reads orphan. It exits 0 in every state, held included: it is a read.

SIZE is the item's worktree and sandbox home, which archiving frees. DOCUMENTS is its docs/ and session summaries, which count toward the quota, and which archiving keeps and abandoning removes. Since archiving can't free them, they never hold a start on their own. OUTPUTS is the step outputs its tasks left for later tasks: they count toward the quota, and archiving frees them with the worktree.

worktrees    12G of 10G (held)
quota        8G
reclaimable  9.1G
measured     4m ago

CATEGORY   SIZE
worktrees  11.5G
...

ID        STATUS     SIZE  DOCUMENTS  OUTPUTS  AGE      RECLAIMABLE  TITLE
3f9c1e7a  completed  4.2G  12K        2M       3d ago   yes          Fix flaky retry
b81d0c42  active     1.1G  -          -        2h ago   -            Add JSON export

With no limit set it prints 1G (no limit set) and no quota. --json prints the GET /api/storage payload. The figure is the last measurement, taken at startup and every 10 minutes while a limit is set, and on the first request when there is none. To archive what it marks, use kraft item archive --reclaimable.

  • Item verbs: act on what you read here: approve, reject, comment, retry.
  • Reviewing a change: how threads, comments and outcomes fit together.
  • Events: every event type view events can show.
Copyright © 2026