Skip to content

CLI Commands

Core Commands

niki watch

Monitor a command from start to finish.

Terminal window
niki watch [OPTIONS] -- <COMMAND>
OptionDescription
--name, -nHuman-readable task name
--timeout, -tTimeout in seconds
--quiet, -qSuppress output

Examples:

Terminal window
niki watch -- python train.py
niki watch --name "Training" -- python train.py --epochs 100
niki watch --timeout 3600 -- ./long_job.sh

niki attach

Attach to an already-running process.

Terminal window
niki attach <PID> [OPTIONS]
OptionDescription
--name, -nHuman-readable task name

Examples:

Terminal window
niki attach 12345
niki attach 12345 --name "Alignment job"

niki status

Show running and recent tasks.

Terminal window
niki status [OPTIONS]
OptionDescription
--running, -rShow only running tasks
--failed, -fShow only failed tasks
--limit, -lMaximum tasks to show

niki history

Query historical tasks.

Terminal window
niki history [OPTIONS]
OptionDescription
--lastTime range (7d, 24h, 1w)
--name, -nFilter by name pattern
--exit-code, -eFilter by exit code
--limit, -lMaximum tasks to show

Daemon Commands

niki daemon start

Start the background daemon.

Terminal window
niki daemon start [OPTIONS]
OptionDescription
--foreground, -fRun in foreground

niki daemon stop

Stop the running daemon.

Terminal window
niki daemon stop

niki daemon status

Check daemon status.

Terminal window
niki daemon status

Configuration Commands

niki config init

Run interactive configuration wizard.

Terminal window
niki config init

niki config show

Display current configuration.

Terminal window
niki config show

niki config path

Show configuration file path.

Terminal window
niki config path

Utility Commands

niki doctor

Check configuration and dependencies.

Terminal window
niki doctor

Validates:

  • Config file exists
  • Dependencies installed
  • API key configured
  • Daemon running

niki mode

Change notification mode.

Terminal window
niki mode <active|focus|meeting>

niki version

Show version.

Terminal window
niki version
niki --version
niki -V

Chat Commands

niki chat history

View chat history.

Terminal window
niki chat history [OPTIONS]
OptionDescription
--platformFilter by platform (telegram, slack)
--limit, -lMaximum messages to show

niki chat stats

Show chat statistics.

Terminal window
niki chat stats

niki chat clear

Clear chat history.

Terminal window
niki chat clear --all --force