Skip to main content
Unsupported HAIP 1 archive. This page records historical HAIP 1 chat and streaming guidance. Its APIs, package examples and security advice are incompatible with a HAIP 2 deployment. Start with the current HAIP 2 guides.
New protocol version released: This page may contain outdated information.
The HAIP CLI can be installed and used in multiple ways. Choose the method that best fits your environment and requirements.

Prerequisites

Node.js

Version 20.0.0 or higher

npm

Version 9.0.0 or higher

Git

For cloning the repository

Source installation

Installing from source is recommended.
1

Clone the Repository

2

Install Dependencies

3

Build the Project

4

Verify Installation

You should see the HAIP CLI banner and help information.

Optional: Install Globally

npm installation

Available Now: The HAIP CLI is available on npm as @haip/cli.
npm version npm downloads License: MIT

Docker installation

Docker: Docker images will be available on Docker Hub as haip/cli in the future.

Pull the Image

Run the Container

Development Setup

Prerequisites for Development

  • Node.js 20.0.0 or higher
  • npm 9.0.0 or higher
  • TypeScript 5.0.0 or higher
  • Git for version control

Development Installation

Development Mode

Verification

After installation, verify that the CLI is working correctly:

Check version

Expected output:

System information

Expected output:

Help system

You should see the ASCII art banner and complete command listing.

Test commands

Configuration

Environment Variables

The CLI can be configured using environment variables:

Configuration file

Configuration files are a planned enhancement. Create a configuration file for persistent settings:

Troubleshooting

Common Issues

Permission Denied

Node Version Issues

Build Errors

Test Failures

Getting Help

If you encounter issues:
  1. Check the logs - Run with verbose output: node dist/index.js --verbose
  2. Check Node.js version - Ensure you’re using Node.js 16+
  3. Check dependencies - Run npm install to ensure all dependencies are installed
  4. Check TypeScript - Run npx tsc --noEmit to check for type errors
  5. Check tests - Run npm test to ensure everything is working

Next Steps