OpenCLI

Turns websites and Electron apps into CLI commands and lets AI agents drive your logged-in Chrome via a Browser Bridge extension and opencli browser primitives.

install

OpenCLI converts websites into command-line interfaces and exposes browser automation for AI agents. It connects to Chrome/Chromium through a Browser Bridge extension and a small local daemon that auto-starts, so commands run inside your existing logged-in browser session. Built-in adapters cover sites such as Bilibili, Zhihu, Xiaohongshu, Reddit, HackerNews and Twitter/X, run as opencli <site> <command> (for example opencli hackernews top --limit 5). opencli list shows all registered commands and opencli doctor diagnoses browser connectivity. It also includes desktop adapters for Electron apps like Cursor, Codex, ChatGPT and Trae.

For AI agents, opencli browser <session> provides primitives including open, state, click, type, fill, select, keys, wait, get, find, extract, network, screenshot, eval and tab management. Page content is read as structured DOM snapshots rather than screenshots, and network API responses can be intercepted. Skills installed with npx skills add jackwener/opencli (opencli-browser, opencli-adapter-author, opencli-autofix, opencli-usage) let agents such as Claude Code or Cursor use these commands, write new adapters, or repair broken ones from natural-language prompts.

Users can extend it by writing adapters. The documented workflow covers recon of the site pattern (SPA, SSR, JSONP, token, streaming), endpoint discovery, choosing an auth mode (PUBLIC, COOKIE, INTERCEPT, UI, LOCAL), and opencli browser recon verify. Commands can be kept in a personal Git repo via opencli plugin create and opencli plugin install, or installed from GitHub with opencli plugin install github:user/repo. Multiple Chrome profiles can be aliased with opencli profile, and behavior is tunable through environment variables such as OPENCLI_PROFILE, OPENCLI_CDP_ENDPOINT and timeouts. It suits developers who want scripted access to logged-in sites and people building browser-driving agents. Installing via npm requires Node.js 20.18.1 or later.

Installation

# via npm
npm install -g @jackwener/opencli
# via Agent skills (npx)
npx skills add jackwener/opencli

Alternatives & related tools

add a badge to your README

Maintain OpenCLI? Show that it's featured on trmn. The badge links back to this page.

Featured on trmn
Markdown
[![Featured on trmn](https://www.trmn.sh/badge/opencli.svg)](https://www.trmn.sh/tools/opencli?utm_source=badge)
HTML
<a href="https://www.trmn.sh/tools/opencli?utm_source=badge"><img src="https://www.trmn.sh/badge/opencli.svg" alt="Featured on trmn" height="20"></a>