The Problem

Teams need to interact with APIs but face a choice between raw HTTP clients (which require API knowledge) and AI-assisted workflows (which lack consistent command interfaces). This gap means every new API integration requires either manual CLI construction or context-switching to AI tools without persistent command schemas. The pain point is concrete: onboarding a new API typically requires 2-3 hours of endpoint discovery, type definitions, and CLI scaffolding before any actual work gets done.

What This Does

api2cli is a Claude Code skill that automates API-to-CLI conversion. The repository contains 8 files across a skill/ directory (5 files) and root (3 files), all Markdown-based documentation. The core flow, per the README, is: point the tool at API docs, a live URL, or a peek-api capture; it discovers endpoints and builds an endpoint catalog capturing auth, pagination, and rate limit info; then generates a Commander.js CLI with one subcommand per endpoint, plus a dual-mode output (human-readable terminal + JSON envelope when piped); finally generates a SKILL.md teaching Claude how to use the CLI. The skill lives in skill/ and can be copied into a Claude Code project. Example: pointing at the Resend API yields 15 endpoints across 5 resources (emails, domains, api-keys, audiences, contacts) with generated CLI at scripts/resend.ts and skill at .claude/skills/resend/SKILL.md.

Key files from structure: .gitignore, LICENSE, README.md, skill/SKILL.md, skill/references/agent-first-patterns.md, skill/references/api-client-template.md, skill/references/commander-patterns.md, skill/references/discovery-strategies.md.

How It Is Wired

Execution flow has not been mapped for this repository. The README describes a user-facing workflow—point at docs, discover endpoints, generate CLI and skill—but the internal call graph, entry points, and function-level wiring are not documented in the available files. What is known: the tool reads API documentation (docs pages, live probing, or peek-api captures), produces an endpoint catalog, and outputs two artifacts: a Commander.js CLI script and a SKILL.md. No entry-point file, main function, or runtime configuration (e.g., package.json, tsconfig.json) is present in the file listing, so the precise code-to-effect paths remain unmapped. Any attempt to trace entry -> function -> external effect would be speculative without further code inspection.

How To Use It

Setup: Clone the repository using the verified URL: git clone https://github.com/moses-y/api2cli.git. Copy the skill/ folder into your Claude Code project: cp -r api2cli/skill/ /path/to/your/project/.claude/skills/api2cli/.

Configuration: No environment variables or config files are documented in the extracted structure beyond the LICENSE file present at root. The README mentions exporting RESEND_API_KEY=re_your_key_here as an example for the Resend API, but no general .env or config file is listed in the file tree.

Running it: The README does not provide a runtime entry point or build command. No package.json, Makefile, or server-start command is visible in the file structure. Without evidence from the repo, the invocation command cannot be confirmed.

Real-World Use

A practical scenario: a developer needs to manage the Resend email API. Instead of manually constructing HTTP requests or writing type definitions, they point api2cli at the Resend docs. The tool discovers 15 endpoints across 5 resources and generates a CLI where npx tsx scripts/resend.ts domains list returns human-readable output, or piped output returns JSON with auto-derived next-actions. Simultaneously, a SKILL.md is generated so future Claude sessions can invoke resend emails send --to user@example.com --subject "Hello" --html "<p>Hi there</p>" without re-reading the code. The skill is then copied into the project's .claude/skills/ directory, and the API interaction becomes a persistent, discoverable command set.

Code Health & Issues

  • Medium - No test files detected: untested code paths - repository-wide
  • Medium - No CI/CD pipeline detected: no automated build/test gate - .github/ or CI config absent

Repository hygiene (deterministic): tests present: no | CI: no | Dockerfile: no | licence: yes | lockfile: no | committed secrets: none found.

Beyond these measured findings, the file structure supports only Markdown documentation; no source code, configuration, or build artifacts are present in the listed files, which limits the scope of health assessment.

The Bottom Line

api2cli provides a concrete automation for API-to-CLI conversion, generating Commander.js CLIs and Claude Code skills from API documentation. The mechanism works as described in the README, but the repository contains no source code, tests, CI configuration, or lockfile—only 8 Markdown files. It is suitable as a reference implementation or starting point for teams comfortable generating CLI scaffolding manually or via custom tooling, but it is not a runnable, maintained product out of the box. Teams seeking a zero-config API wrapper should look elsewhere; those wanting a scaffold they can inspect and extend will find the skill-format and discovery strategies useful starting points.