CLI Printing Press is an open-source project aimed at generating high-quality CLI tools for AI agents. Its core philosophy is: in the age of AI agents, time and token consumption are critical, and a well-designed CLI can become an agent's muscle memory, avoiding consulting documentation, taking detours, and wasting tokens.
Key Capabilities
- Automated research: Reads official API documentation, studies popular community CLIs and MCP servers, and sniffs undocumented APIs (such as Google Flights, Dominos).
- Generates dual interfaces: For each API, generates a Cobra CLI (
<api>-pp-cli) and an MCP server (<api>-pp-mcp), sharing the same client, storage, and authentication, with zero code duplication. - Local-first data layer: Creates domain-specific SQLite tables, FTS5 full-text search indexes, and incremental sync for high-value resources, supporting offline search and direct SQL queries.
- Compound commands: Implements cross-resource joins and historical analysis based on local data, such as
stale、health、bottleneck、reconcile, etc. - Agent-native design: Displays human-friendly tables in the terminal, with piped output automatically converted to JSON;
--compactoutputs only key fields (reducing tokens by 60-80%); typed exit codes (0/2/3/4/5/7) facilitate agent self-correction;--dry-runis used for safe exploration. - Works without a spec: If there is no OpenAPI spec, you can point it at a website, and the tool will launch a browser to capture traffic, reverse-engineer the API, and generate a spec. HAR files are also supported.
- Validation mechanism: Through four mechanical checks—scorecard, dogfooding tests, behavioral proof, and live API smoke tests—it catches hallucinated paths, dead flags, authentication mismatches, and broken data pipelines.
- Non-Obvious Insight (NOI): Every generated CLI is built on a one-sentence redefinition, i.e., the API's "secret identity", ensuring the CLI is built around genuinely valuable use cases.
Usage
- Installation: Requires Go 1.26.11 or later, a skill-capable agent (such as Claude Code), and Node/npm. Running the installer will execute
go installto install the generator binary, and refresh the skill viaskills@latest add --skill '*'. You can use--cli-onlyor--skills-onlyto install only one side. The default install target is Claude Code; use--agent codexto install to Codex. - Start a printing session: In Claude Code, use the
/printing-press <api>command to drive the binary through research, generation, scoring, and release checks. - Output locations: Active runs are in
~/printing-press/.runstate/<scope>/runs/<run-id>/working/, published CLIs are in~/printing-press/library/<api>, and archived manuscripts are in~/printing-press/manuscripts/<api>/<run-id>/. - Publish: Once satisfied, you can publish the CLI to the library.
Use cases
- Quickly generate AI agent-friendly CLIs and MCP servers for any API (REST, GraphQL, or browser traffic sniffing).
- Scenarios requiring offline search, local data synchronization, and compound queries.
- For developers who want to reduce AI agent token consumption and improve interaction efficiency.
- Build CLIs for websites that do not have an official API.
Limitations
- Requires Go 1.26.11+, Node/npm, and an agent environment that supports skills.
- Skills are primarily tested for Claude Code; Codex support requires reference to specific documentation.
- Generation quality depends on research depth; if you cannot write a NOI, the research is insufficient.
- Details such as specific fees, pricing, and platform compatibility are not provided at this time.