AB
AiBoss
project

OpenCLI - an open-source AI command-line tool that allows you to convert your website into a command-line interface with a single click.

OpenCLI is an open-source command-line tool that transforms any website and Electron desktop application into a command-line interface. The tool connects to a local daemon via a Chrome browser extension, reusing the user's logged-in account permissions...

What is OpenCLI?

OpenCLI is an open-source command-line tool that transforms any website and Electron desktop application into a command-line interface. The tool connects to a local daemon via a Chrome browser extension, reusing the user's already logged-in account permissions without requiring additional API key configuration. OpenCLI supports over 30 platforms, including Bilibili, Zhihu, Cursor, Notion, and WeChat, providing... explore,synthesize,cascade Three AI-specific commands can automatically discover APIs, generate adapters, and probe authentication policies. The tool enables the AI Agent to uniformly control various software, achieving true "CLI for everything".

Main functions of OpenCLI

  • Website CLIIt transforms 30+ websites, including Bilibili, Zhihu, Xiaohongshu, Twitter/X, into command-line tools, supporting operations such as viewing trending lists, searching content, and downloading data.
  • CLI-based Electron applicationsControl desktop applications such as Cursor, Notion, Discord, ChatGPT, and WeChat through the Chrome DevTools Protocol to achieve functions such as sending messages, reading content, and automating interactions.
  • External CLI hubIt integrates existing command-line tools such as gh, docker, kubectl, and obsidian, providing unified discovery, automatic installation, and pass-through execution capabilities.
  • AI-native discovery engine:pass explore Automatically explore website APIs,synthesize Generate adapter code,cascade The detection and authentication strategy enables the AI Agent to learn and control the new platform autonomously.
  • Multi-format structured outputIt supports multiple output formats such as JSON, YAML, Markdown, CSV, and Table, making it easy for AI Agents to directly process and analyze data.
  • Content download and exportIt supports downloading content such as Xiaohongshu images and videos, Bilibili videos, Twitter media, and Zhihu articles to your local device.
  • Zero-configuration security architectureReuse the logged-in account status in Chrome browser without requiring additional API Key configuration.

Key information and usage requirements for OpenCLI

  • positionGeneral CLI hub and AI-native runtime
  • Core CompetenciesTransform any website, Electron application, or local CLI tool into a standardized command-line interface.
  • Technical ArchitectureCLI → Local Daemon (localhost:19825) → WebSocket → Chrome Extension → Browser/Application
  • Authentication methodReuse Chrome browser login state, zero configuration, no API key required.
  • AI-specific commands:explore(Discover API)synthesize(Generate adapter)cascade(Detection and authentication)
  • Output format:JSON, YAML, Markdown, CSV, Table
  • Chrome browserIt must be installed and running, and you must be logged into the target website.
  • Browser extensionRequires the OpenCLI Browser Bridge extension to be installed (loaded in developer mode).
  • Network requirementsThe local daemon communicates with Chrome via WebSocket.
  • Video downloadAdditional installation required. yt-dlp(Download from Bilibili and other streaming media)

OpenCLI's core advantages

  • Full platform coverageIt supports websites (Bilibili, Zhihu, Twitter, etc.), Electron desktop applications (Cursor, Notion, Discord, etc.) and local CLI tools (gh, docker, etc.), realizing "everything can be CLI".
  • AI Native Design:built-in explore,synthesize,cascade Three commands enable the AI Agent to autonomously discover APIs, generate adapters, and detect authentication policies, allowing it to control new platforms without requiring manual coding.
  • Unified standardizationAll platforms are converted to a unified CLI interface, supporting structured outputs such as JSON, YAML, and Markdown, which facilitates AI Agent orchestration of cross-application workflows.
  • Safe and trustworthyUser account passwords are always stored in the browser and communicate through a local daemon process, without going through a third-party server, reducing the risk of credential leakage.
  • Dynamically scalableSupports hot reloading .ts or .yaml Adapters enable the community to share commands, continuously enriching the ecosystem.

How to use OpenCLI

  • Environmental preparationInstall Node.js >= 20.0.0, and ensure that Chrome browser is installed and logged into the target website.
  • Install OpenCLI:implement npm install -g @jackwener/opencli Install command-line tools globally.
  • Install browser extensionsDownload from GitHub Releases opencli-extension.zipAfter decompression, enable developer mode in the Chrome extensions management page and load the decompressed extension folder.
  • Verify installation:run opencli doctor Check the connection status of extensions and daemons, and automatically diagnose and fix problems.
  • View available commands:implement opencli list Browse the list of built-in supported website and application commands.
  • Execute command:use opencli <平台> <操作> Format call, such as opencli bilibili hot -f json Retrieve Bilibili's trending topics JSON data.opencli cursor send "hello" Send a message to the Cursor.
  • Generate a custom adapter: Execution on the new website opencli generate https://example.com --goal "hot"Explore, generate, and register with a single click.
  • Integrate external CLIRun directly opencli gh pr list or opencli docker psOpenCLI will automatically pass through and support the automatic installation of tools that are not installed.

OpenCLI project address

  • GitHub repositoryhttps://github.com/jackwener/opencli

Comparison of OpenCLI with similar products

Comparison Dimensions OpenCLI Playwright Puppeteer
position Universal CLI hub and AI-native runtime Browser automated testing framework Headless Chrome control library
Core Competencies Transform website/Electron/local CLI into a unified command-line interface. End-to-end web testing and automation Programmatic control of the Chrome browser
Technical Architecture CLI → Daemon → WebSocket → Chrome Extension Scripts directly drive browser instances Node.js libraries control the browser via the DevTools Protocol.
Usage threshold Zero configuration, reuse browser login state Test scripts need to be written and the environment needs to be configured. You need to write code and understand the browser API.
AI Agent Support Native design, with built-in explore/synthesize/cascade Requires secondary packaging; no built-in AI workflow. Requires custom development; no AI-specific commands available.
Electron supports Native support, direct control via CDP Additional configuration required, limited support. Supported, but application startup and port connection need to be handled manually.
Local CLI Integration Supports pass-through of external CLIs such as gh and docker. Not supported Not supported

Application scenarios of OpenCLI

  • AI Agent AutomationThis enables AI to autonomously control browsers and desktop applications, performing cross-platform tasks such as automatically collecting information, filling out forms, and publishing content.
  • Data capture and monitoringIt supports scheduled scraping of Bilibili trending topics, Zhihu topics, stock quotes, and news information, and outputs structured data for analysis or push notifications.
  • Content creation assistanceThe tool can automatically download Xiaohongshu notes, Zhihu articles, and Twitter media, and import them into Notion or Cursor for organization and secondary creation.
  • Cross-application workflow orchestrationIt supports connecting multiple platforms, such as obtaining stock data from Xueqiu, analyzing it with AI and sending it to Feishu groups, or extracting subtitles from Bilibili and summarizing them into a document.