Skip to main content
Version: main 🚧

CAIPE CLI

Refactor in Progress

The CLI is under active development. Track progress in PR #1184. Commands, flags, and installation paths may change before the final merge.

AI-assisted coding, workflows, and platform engineering from the terminal.

CAIPE CLI is a TypeScript/Bun CLI that connects to a CAIPE server via the A2A or AG-UI streaming protocol. It provides an interactive chat REPL, headless mode for CI/CD pipelines, skill management, and secure credential storage.

Installation

curl -fsSL https://raw.githubusercontent.com/cnoe-io/ai-platform-engineering/main/cli/install.sh | sh

Installs the correct binary for your platform (macOS/Linux, arm64/x64) to /usr/local/bin/caipe.

Options:

  • CAIPE_INSTALL_DIR — override install directory (default: /usr/local/bin)
  • CAIPE_VERSION — pin a specific version (default: latest)

npm

npm install -g caipe

Build from source

git clone https://github.com/cnoe-io/ai-platform-engineering.git
cd ai-platform-engineering/cli
bun install
npm run compile # produces dist/caipe (Bun single-file binary)
./dist/caipe --version

Quick Start

# 1. Point to your CAIPE server
caipe config set server.url https://your-caipe-server.example.com

# 2. Authenticate (opens browser for OAuth)
caipe auth login

# 3. Start chatting
caipe

Commands

CommandDescription
caipeOpen interactive chat REPL
caipe chatOpen chat (explicit). Options: --agent, --protocol, --headless, --resume
caipe auth loginAuthenticate via OAuth (browser or --device flow)
caipe auth logoutRemove stored credentials
caipe auth statusPrint current auth state
caipe config set <key> <value>Set a configuration key
caipe config get <key>Print the current value of a key
caipe config unset <key>Remove a configuration key
caipe skills listList available skills from catalog
caipe skills install <name>Install a skill
caipe skills preview <name>Display full SKILL.md content
caipe skills update [name]Check and update installed skills
caipe agents listList available server agents
caipe agents info <name>Show agent capabilities
caipe memoryManage persistent context files
caipe commitDCO-compliant commit with AI attribution

Global Options

--agent <name>    CAIPE server agent to use (default: "default")
--url <url> Override server.url from settings.json
--no-color Disable ANSI color output
--json Machine-readable JSON output
-v, --version Print version and exit

Interactive Chat

The chat REPL provides:

  • Streaming responses via A2A or AG-UI Server-Sent Events
  • Slash commands — type / for a picker: /clear, /compact, /login, /skills, /agents, /help, /exit
  • Readline keybindingsCtrl+A/E, Ctrl+B/F, Alt+B/F, Ctrl+U/K/W, Ctrl+D
  • Input historyUp/Down or Ctrl+P/N
  • Shell pipes!command runs a shell command and injects output
  • Tool call visualization — active tool calls shown in the status footer

Headless Mode

For CI/CD pipelines and scripting:

# Single prompt
caipe chat --headless --prompt "Explain the deployment architecture"

# From file
caipe chat --headless --prompt-file question.txt --output json

# Multi-turn via stdin
echo -e "Hello\nWhat is A2A?" | caipe chat --headless --interactive-stdin

# With explicit token
caipe chat --headless --token "$JWT" --prompt "status check"

Configuration

Settings are stored in ~/.config/caipe/settings.json.

KeyDescriptionExample
server.urlCAIPE server base URLhttps://caipe.example.com
auth.urlOAuth authorization endpoint (auto-discovered if not set)https://auth.example.com
auth.apiKeyStatic API key (alternative to OAuth)sk-...
auth.credential-storageCredential backend: encrypted-file or keychainencrypted-file

Source

cli/ directory in ai-platform-engineering