OriginRouter CLIOverview and install

OriginRouter CLI: overview and install

OriginRouter CLI is the open-source execution and control layer that runs on a developer's device. It provides a unified local entry point for Claude Code and Codex. Services, routes, providers, remote control, and approval policies are enabled after installation when needed.

Follow the steps here to install the CLI and common local runtime components. Continue with Quickstart for first sign-in, Cloud routes, and workspace operation; provider and remote capabilities are documented in their respective guides.

Requirements

  • Node.js 22 or newer. The official Node.js installer includes npm; the OriginRouter installer verifies node and npm independently.
  • On systems without Node.js or with an outdated version, the install script installs Node.js 22 LTS automatically: system package managers (apt, dnf/yum, apk) when root or passwordless sudo is available, otherwise nvm into the user's home directory with no sudo at all. On other systems, install Node.js 22 or newer from nodejs.org before running the install command. See Troubleshooting when automatic installation fails.
  • Network access to the npm registry, GitHub Releases, and the official Claude Code and Codex download services; configure npm and terminal proxy settings according to your organization's policy when required.
  • Local Proxy uses an isolated Python runtime managed by OriginRouter; a system Python installation is not required.
  • Sign-in, a Cloud account, and provider credentials are not prerequisites for installing the CLI; configure them in later workflows.

Install the CLI

The installer is the recommended installation path. Direct npm iation remains available when the CLI version must be managed explicitly.

Choose an installation source

macOS, Linux, and WSL:
curl -fsSL https://originrouter.com/install.sh | bash
Windows PowerShell:
irm https://originrouter.com/install.ps1 | iex
The installer installs the CLI, agent runtimes, managed Python, Local Proxy, and background service, then verifies the local environment.

Verify the installation

All installation methods provide the full originrouter executable and the equivalent short alias or. First verify the command entry point:

originrouter --version
or --help

The installer has already completed initialization and verification. After a direct npm iation, run the originrouter setup command shown in that installation option to prepare the local runtime environment.

To recheck the installation state, run:

originrouter setup --verify

If the shell reports that the command is missing, verify that npm's global bin directory is on PATH, then reopen the terminal. Do not mix a global npm iation with an old npm link checkout.

For setup options, the background service, Local Proxy, and Shell completion, see Service and runtime setup, Local Proxy, and Shell completion.

Initialization flow

originrouter setup prepares the complete local runtime after the CLI is installed, including agent runtimes, the background service, Local Proxy, and its dependencies. The flow verifies the installation when complete.

Common options

originrouter setup --yes

Skip interactive confirmations in automation environments.

originrouter setup --dry-run

Show detection results and the execution plan without changing the local environment.

originrouter setup --no-proxy

Skip Local Proxy and its managed Python runtime when using only OriginRouter Cloud or remote devices.

originrouter setup --verify

Verify Claude Code, Codex, managed Python, Local Proxy, and background-service status without installing components.

Shell completion

Interactive setup asks whether to install completion for the current shell. After an automated installation, you can install it separately with:

originrouter completion install

Background service

The initialization flow installs and starts a current-user background service and configures it to start when the user signs in. For independent service management, see Service and daemon.

Retry and repair

setup rechecks actual files, versions, and service state on every run. If a step is interrupted, rerun the same command; completed steps are skipped and missing or incomplete components are installed or repaired.

Continue with Quickstart to sign in and configure Cloud routes; use Models and routing for a private API or enterprise gateway.

Next steps

Was this page helpful?