Skip to content

The Kizuna CLI (kz) is a command-line interface for interacting with the Kizuna platform. Built in Rust, it provides fast, cross-platform access to all Kizuna features — including an optional terminal user interface (TUI) for keyboard-driven workflows.

Installation

Pre-built Binaries

Download the latest release for your platform:

bash
# macOS (Apple Silicon)
curl -L https://releases.kizuna.codes/cli/latest/kz-darwin-arm64 -o kz
chmod +x kz && sudo mv kz /usr/local/bin/

# macOS (Intel)
curl -L https://releases.kizuna.codes/cli/latest/kz-darwin-amd64 -o kz
chmod +x kz && sudo mv kz /usr/local/bin/

# Linux (x86_64)
curl -L https://releases.kizuna.codes/cli/latest/kz-linux-amd64 -o kz
chmod +x kz && sudo mv kz /usr/local/bin/

# Windows (via PowerShell)
Invoke-WebRequest -Uri https://releases.kizuna.codes/cli/latest/kz-windows-amd64.exe -OutFile kz.exe

Build from Source

Requires Rust 1.85+ (edition 2024):

bash
git clone https://github.com/kizuna-platform/kizuna.git
cd kizuna/rust
cargo build --release -p kizuna-cli

# Binary is at target/release/kz
sudo cp target/release/kz /usr/local/bin/

To build without the TUI (smaller binary):

bash
cargo build --release -p kizuna-cli --no-default-features

Verify Installation

bash
kz --version

Quick Setup

bash
# Initialize configuration
kz config init

# Authenticate with your Kizuna instance
kz auth login

# Verify connection
kz auth status

Feature Overview

FeatureDescription
AuthenticationOAuth login, multi-profile support, token management
ConfigurationTOML-based profiles, per-instance settings
Policy GatewayCheck and invoke policies from CI/CD or scripts
Identity (OIDC)Manage OIDC clients for agent and service auth
TUI ModeFull terminal interface with vim keybindings

Coming Soon

These commands are scaffolded and under active development:

  • kz repo — Repository operations (create, clone, list, delete)
  • kz pr — Pull request management
  • kz issue — Issue tracking and Kanban board
  • kz agent — AI agent lifecycle management
  • kz pipeline — CI/CD pipeline control
  • kz change — Jujutsu change operations
  • kz marketplace — Agent marketplace browsing

Global Options

Every command supports these flags:

--profile <PROFILE>   Use a specific configuration profile
--instance <URL>      Override instance URL for this command
--json                Output as JSON instead of formatted text
--quiet, -q           Minimal output
--debug               Enable debug logging
--offline             Use cached data only (no network requests)

Architecture

The CLI is built as part of the Kizuna Rust workspace:

rust/crates/kizuna-cli/
├── src/
│   ├── main.rs          # Entry point and command routing
│   ├── commands/        # Subcommand implementations
│   │   ├── auth.rs      # Authentication flows
│   │   ├── config.rs    # Configuration management
│   │   ├── policy.rs    # Policy gateway interaction
│   │   └── identity.rs  # OIDC client management
│   ├── config/          # Configuration loading and paths
│   │   ├── paths.rs     # Cross-platform directory resolution
│   │   └── settings.rs  # TOML config structures
│   └── tui/             # Terminal user interface
│       ├── mod.rs       # TUI app state and rendering
│       └── keybindings.rs # Keybinding system
└── examples/
    └── README.md        # Advanced usage examples

Next Steps