AgentKit
DocsKitsCLI ReferenceDesktop App

Reference

CLI conventions

Global flags, output modes, and standard exit codes shared by every ak command.

Every ak command follows the same conventions for flags, output, and exit codes. Command pages in the CLI reference list only what is specific to that command; everything on this page applies everywhere.

Global flags

FlagDescription
--jsonEmit machine-readable JSON (implies --no-interactive)
--no-interactiveDisable interactive prompts (CI-safe)
-q, --quietSuppress non-error output on stderr
-V, --verboseExtra diagnostic output on stderr (loses to --quiet)
-y, --yesAssume yes for all prompts
-h, --helpPrint help for the command

Output modes

ModeBehavior
prettydefault on TTY (colors, ASCII markers)
plainauto when stdout piped or --no-interactive
json--json (single-object envelope, NDJSON-safe)

Exit codes

Every runnable command reports the same three base outcomes:

CodeMeaning
0success
1command failure
2invalid flags or arguments

Codes 3 and above are command-specific, and the same number can mean different things on different commands. A command page's Exit codes section lists only those: 3 is user cancel on ak recover, ak backups restore, and ak setup, but reports a completed preview on the ak analytics subcommands.