Prototipo · Versión preliminar: todos los servidores del registro oficial, sincronizados cada 30 minutos. Inicia sesión con Google para escribir reseñas.Prototipo · se actualiza cada 30 min
PopNx MCPServidores MCP para quienes usan IA · en palabras sencillas

What it does

Audience-aware CLI patterns for Node.js + Commander.js. Build CLIs for humans, AI agents, or both.

  • Connects Instruction files the AI reads
  • Account or key Not confirmed yet (README not read yet)
  • Category Programación
Para autores: añade una insignia a tu README

Si lo creaste tú, pega este código en tu README. La insignia enlaza a esta página.

[![Featured on PopNx MCP](https://mcp.popnx.com/badge/skill/alexknowshtml-api2cli.svg)](https://mcp.popnx.com/en/skills/alexknowshtml-api2cli)

Úsalo junto con

Servidores MCP que conectan la IA a servicios para el mismo trabajo

REA

Reverse engineer anything from your terminal or agent with one CLI and MCP server.

de morlutoMuy usado↓ 388,7 mil/sem★ 461,8 milActualizado hace 5 días

MCP · Conecta un servicioSe ejecuta en tu computadora

Fallow

Codebase intelligence for TypeScript and JavaScript, exposed as structured MCP analysis tools.

de fallow-rsMuy usado↓ 2,4 M/sem★ 5,4 milActualizado anteayer

MCP · Conecta un servicioSe ejecuta en tu computadora

Desktop Commander

MCP server for terminal commands, file operations, and process management

de wonderwhy-erMuy usado↓ 740,3 mil/sem★ 10,3 milActualizado hace 5 días

MCP · Conecta un servicioSe ejecuta en tu computadora

Skills parecidas

Mismo tipo de trabajo, ordenadas como la lista de Skills

Comparado con otros parecidos
Este
api2cli
reaandrej-karpathy-skillsgraphifyMoneyPrinterTurbo
Autoralexknowshtmlmorlutomultica-aiGraphify-Labsharry0703
Skills11111
Estrellas de GitHub455463.670233.682148.887143.987
Último cambio de código20 feb 202617 nov 202620 abr 202617 nov 202616 nov 2026
LicenciaMITMIT–Apache-2.0MIT

1 skills (conjuntos de instrucciones) de alexknowshtml que la IA lee y sigue · no es un MCP server

En qué se diferencia un Skill de MCP

MCP = las manos

Conecta la IA a un servicio o dato externo, como leer Notion o crear una factura. Necesita un programa o servidor en marcha.

Skill = el manual

Un archivo de texto que enseña a la IA cómo hacer una tarea. No se conecta a nada.

A veces se parecen: algunas Skills ejecutan scripts que llaman herramientas y algunos MCP solo envían conocimiento. Empieza por la tarea que quieres hacer.

Funciona con

Claude Code

Según el README del autor y las carpetas del repo

Instalar

Is it safe?

  • Who made it

    GitHub account alexknowshtml (person), 18 years old

  • Use and upkeep

    ★ 455 stars, few users so far · code last changed 20 feb 2026

  • Any scripts?

    No, plain text files the AI reads and follows

  • Uses the internet?

    No scripts, so it does not go online by itself

  • Changes machine-wide settings?

    No hooks or writes to machine settings found

Checked automatically from the repo files at commit fde6f88 (read only, nothing was run). Not a safety guarantee: read it and decide for yourself

Primero: ¿qué IA usas?

Elige tu app y esta página mostrará solo cómo instalarlo en ella

Option 1Upload to claude.ai (web and app)

Uploading to claude.ai would fail: the description is over 200 characters (408). Use "Let the AI install it" instead

Option 1Deja que Claude Code lo instale

Copia esta frase y pégala en un chat de Claude Code

Where to install

Revisando los comandos · los botones de copiar aparecen cuando pasan la revisión

Revisando los comandos · los botones de copiar aparecen cuando pasan la revisión

For one project, paste it into a chat that is open in that project’s folder · The AI always shows you the path before installing

The AI tells you what it will do first and asks your permission at every step

Vuelve a abrir Claude Code y escribe /skill, o pide una tarea relacionada y Claude lo usará

Checked against official docs 12 nov 2026 · Source: code.claude.com

For Terminal users

Un Skill son instrucciones que la IA seguirá. Lee los archivos antes de instalar e instala solo de autores de confianza.

  1. Abre la Terminal

    Mac: pulsa Command+Espacio y escribe Terminal · Windows: el comando no funciona en PowerShell; usa «Que la IA lo instale» arriba

  2. Copia la carpeta del skill a ~/.claude/skills

    Descarga el repo a una carpeta temporal y copia solo las carpetas con SKILL.md

    Revisando los comandos · los botones de copiar aparecen cuando pasan la revisión

  3. Vuelve a abrir Claude Code y escribe /skill, o pide una tarea relacionada y Claude lo usará

Las skills que instalas tú funcionan en la app de escritorio de ChatGPT, en Codex CLI y en la extensión de Codex para el IDE · ChatGPT en la web y el móvil no puede usar skills instaladas por ti, solo las que vienen con un plugin del directorio

App de escritorio de ChatGPT

La app de escritorio de ChatGPT incluye Codex, y Codex lee las skills de la carpeta ~/.agents/skills

Option 1Deja que ChatGPT lo instale

Abre Codex en la app de escritorio de ChatGPT y pega esta frase en el chat

Where to install

Revisando los comandos · los botones de copiar aparecen cuando pasan la revisión

Revisando los comandos · los botones de copiar aparecen cuando pasan la revisión

The AI always shows you the path before installing

The AI tells you what it will do first and asks your permission at every step

Option 2Coloca la carpeta tú mismo

Coloca la carpeta api2cli en ~/.agents/skills/api2cli

~ es tu carpeta de inicio ($HOME)

For Terminal users

Un Skill son instrucciones que la IA seguirá. Lee los archivos antes de instalar e instala solo de autores de confianza.

  1. Abre la Terminal

    Mac: pulsa Command+Espacio y escribe Terminal · Windows: el comando no funciona en PowerShell; usa «Que la IA lo instale» arriba

  2. Copia la carpeta del skill a ~/.agents/skills

    Descarga el repo a una carpeta temporal y copia solo las carpetas con SKILL.md

    Revisando los comandos · los botones de copiar aparecen cuando pasan la revisión

Después de instalar

  • App de escritorio de ChatGPT: abre Skills en la barra lateral para ver que la skill está
  • Para usarla: en ChatGPT escribe @ y elige la skill · en Codex CLI o la extensión del IDE ejecuta /skills o escribe $ y el nombre de la skill
  • Codex detecta solo las skills recién instaladas; si una no aparece, reinicia Codex

Checked against official docs 15 nov 2026 · Source: learn.chatgpt.com

ChatGPT en la web y el móvil

Las skills que instalas tú no funcionan aquí; solo las que vienen con un plugin del directorio

Para usar esta skill con ChatGPT, usa la app de escritorio de ChatGPT como se indica arriba

Checked against official docs 15 nov 2026 · Source: learn.chatgpt.com

Option 1Deja que Codex lo instale

Copia esta frase y pégala en un chat de Codex · Sirve en Codex dentro de la app de escritorio de ChatGPT, en Codex CLI y en la extensión del IDE

Where to install

Revisando los comandos · los botones de copiar aparecen cuando pasan la revisión

Revisando los comandos · los botones de copiar aparecen cuando pasan la revisión

For one project, paste it into a chat that is open in that project’s folder · The AI always shows you the path before installing

The AI tells you what it will do first and asks your permission at every step

Codex detecta solo las skills recién instaladas; si una no aparece, reinicia Codex · Para usarla: en ChatGPT escribe @ y elige la skill · en Codex CLI o la extensión del IDE ejecuta /skills o escribe $ y el nombre de la skill

Checked against official docs 15 nov 2026 · Source: learn.chatgpt.com

For Terminal users

Un Skill son instrucciones que la IA seguirá. Lee los archivos antes de instalar e instala solo de autores de confianza.

  1. Abre la Terminal

    Mac: pulsa Command+Espacio y escribe Terminal · Windows: el comando no funciona en PowerShell; usa «Que la IA lo instale» arriba

  2. Copia la carpeta del skill a ~/.agents/skills

    Descarga el repo a una carpeta temporal y copia solo las carpetas con SKILL.md

    Revisando los comandos · los botones de copiar aparecen cuando pasan la revisión

  3. Vuelve a abrir Codex y pide una tarea relacionada; Codex mostrará el skill

Option 1Deja que Cursor lo instale

Copia esta frase y pégala en un chat de Cursor

Where to install

Revisando los comandos · los botones de copiar aparecen cuando pasan la revisión

Revisando los comandos · los botones de copiar aparecen cuando pasan la revisión

For one project, paste it into a chat that is open in that project’s folder · The AI always shows you the path before installing

The AI tells you what it will do first and asks your permission at every step

En el chat Agent de Cursor escribe / y elige skill

Checked against official docs 12 nov 2026 · Source: cursor.com

For Terminal users

Un Skill son instrucciones que la IA seguirá. Lee los archivos antes de instalar e instala solo de autores de confianza.

  1. Abre la Terminal

    Mac: pulsa Command+Espacio y escribe Terminal · Windows: el comando no funciona en PowerShell; usa «Que la IA lo instale» arriba

  2. Copia la carpeta del skill a ~/.cursor/skills

    Descarga el repo a una carpeta temporal y copia solo las carpetas con SKILL.md

    Revisando los comandos · los botones de copiar aparecen cuando pasan la revisión

  3. En el chat Agent de Cursor escribe / y elige skill

Option 1Let the AI install it

Para otras apps que leen skills. La frase incluye las rutas de Claude Code, Codex y Cursor para que la IA elija la de tu app · Copy this sentence into the app’s chat

Where to install

Revisando los comandos · los botones de copiar aparecen cuando pasan la revisión

Revisando los comandos · los botones de copiar aparecen cuando pasan la revisión

For one project, paste it into a chat that is open in that project’s folder · The AI always shows you the path before installing

The AI tells you what it will do first and asks your permission at every step

Checked against official docs 12 nov 2026 · Source: code.claude.com, learn.chatgpt.com, cursor.com

For Terminal users

Otras apps con Agent Skills (como Gemini CLI o GitHub Copilot) usan otras carpetas. Mira la guía de esa app y copia allí la carpeta con el SKILL.md.

Ver en GitHub ↗

Carpetas de skills comprobadas con las guías oficiales de Claude Code, Codex y Cursor el 11 nov 2026

Ver el SKILL.md original

El texto siguiente viene del repo del autor, no de PopNx MCP

Se muestran los primeros 8000 caracteres · Abrir el archivo completo en GitHub

---
name: api2cli
description: Generate a working CLI from any API, then wrap it in a Claude Code skill. Point it at API docs, a live URL, or a peek-api capture and get a dual-mode Commander.js CLI (human + agent output) plus a ready-to-use skill folder. Use when user wants to wrap an API in a CLI, generate a CLI from API docs, turn an API into a command-line tool, scaffold a CLI from discovered endpoints, or create a skill for an API.
---

# api2cli

Generate a working Node.js CLI from any API, then wrap it in a Claude Code skill. Discovers endpoints, scaffolds a dual-mode Commander.js CLI with a full-featured API client, and creates a skill folder so Claude knows how to use it.

## Workflow

1. **Identify the API** -- user provides a docs URL, a live API base URL, or a peek-api capture
2. **Discover endpoints** -- parse docs, probe the API, or read a peek-api catalog
3. **Build endpoint catalog** -- normalize all discovered endpoints into a standard format
4. **Generate CLI** -- scaffold Commander.js CLI from the catalog
5. **User chooses destination** -- scaffold into current project or create standalone project
6. **Generate skill** -- create a SKILL.md that teaches Claude how to use the generated CLI

## Step 1: Identify the API

Ask the user:
- "What API do you want to wrap? Share a docs URL, a base URL, or point me at a peek-api capture."

Determine which discovery paths to use based on what they provide:

| Input | Discovery Path |
|-------|---------------|
| Docs URL (e.g., `https://docs.stripe.com/api`) | Docs parsing + active probing |
| Base URL (e.g., `https://api.example.com/v1`) | Active probing |
| peek-api capture dir (e.g., `./peek-api-linkedin/`) | Read existing catalog |
| Live website URL | Suggest running peek-api first, then active probing |

Also ask:
- "What auth does this API use?" (API key, Bearer token, cookies, OAuth, none)
- "Do you want this CLI in your current project or as a standalone project?"

## Step 2: Discover Endpoints

Use all applicable discovery paths. Combine results into a single catalog.

### Path A: Docs Parsing

1. Fetch the docs URL with WebFetch
2. Extract endpoint information: method, path, description, parameters, request/response examples
3. Look for pagination patterns, auth requirements, rate limit info
4. Follow links to sub-pages for individual endpoint docs if the main page is an index

### Path B: Active Probing

1. Check well-known paths for API specs:
   - `/.well-known/openapi.json`, `/.well-known/openapi.yaml`
   - `/openapi.json`, `/openapi.yaml`, `/swagger.json`, `/swagger.yaml`
   - `/api-docs`, `/docs`, `/api/docs`
   - `/graphql` (with introspection query)
2. Try `OPTIONS` on the base URL and common resource paths
3. Probe common REST patterns: `/api/v1/`, `/api/v2/`, `/v1/`, `/v2/`
4. For each discovered resource, try standard CRUD: `GET /resources`, `GET /resources/:id`, `POST /resources`, etc.
5. Parse response shapes to understand data models
6. Check response headers for rate limit info (`X-RateLimit-*`, `Retry-After`)
7. Check for pagination patterns in responses (`next`, `cursor`, `page`, `offset`)

See `references/discovery-strategies.md` for detailed probing patterns.

### Path C: peek-api Capture

1. Read the capture directory: `endpoints.json`, `auth.json`, `CAPTURE.md`
2. Parse endpoints into the standard catalog format
3. Extract auth headers and cookies from `auth.json`

If peek-api is not installed or no capture exists, tell the user:
```
To capture endpoints from a live site, install peek-api:
  git clone https://github.com/alexknowshtml/peek-api
  cd peek-api && npm install
  node bin/cli.js https://example.com
```

## Step 3: Build Endpoint Catalog

Normalize all discovered endpoints into this format:

```typescript
interface EndpointCatalog {
  service: string;           // e.g., "stripe", "nexudus"
  baseUrl: string;
  auth: {
    type: 'api-key' | 'bearer' | 'cookies' | 'oauth' | 'none';
    headerName?: string;     // e.g., "Authorization", "X-API-Key"
    envVar: string;          // e.g., "STRIPE_API_KEY"
  };
  pagination?: {
    style: 'cursor' | 'offset' | 'page' | 'link-header';
    paramName: string;       // e.g., "starting_after", "offset", "page"
    responseField: string;   // e.g., "has_more", "next", "next_page_url"
  };
  rateLimit?: {
    requests: number;
    window: string;          // e.g., "1m", "1h"
  };
  resources: ResourceGroup[];
}

interface ResourceGroup {
  name: string;              // e.g., "customers", "invoices"
  description: string;
  endpoints: Endpoint[];
}

interface Endpoint {
  method: 'GET' | 'POST' | 'PUT' | 'PATCH' | 'DELETE';
  path: string;              // e.g., "/v1/customers/:id"
  description: string;
  parameters: Parameter[];
  requestBody?: object;      // JSON schema or example
  responseExample?: object;
}

interface Parameter {
  name: string;
  in: 'path' | 'query' | 'header';
  required: boolean;
  type: string;
  description: string;
}
```

Present the catalog to the user for review before generating:
```
Found 24 endpoints across 5 resources:
  customers (6 endpoints): list, get, create, update, delete, search
  invoices (5 endpoints): list, get, create, send, void
  ...
Ready to generate the CLI?
```

## Step 4: Generate CLI

Generate a dual-mode CLI using Commander.js. The CLI auto-detects human vs agent output via `process.stdout.isTTY`.

### File Structure

**In-project scaffold:**
```
scripts/
  {service}.ts                    # Entry point with shebang
  {service}/
    lib/
      client.ts                   # API client (auth, pagination, retry, caching)
      envelope.ts                 # Agent JSON envelope helpers
    commands/
      {resource}.ts               # One file per resource group
```

**Standalone project:**
```
{service}-cli/
  package.json
  tsconfig.json
  bin/
    {service}.ts                  # Entry point with shebang
  src/
    lib/
      client.ts
      envelope.ts
    commands/
      {resource}.ts
```

### Code Generation Patterns

See these references for the patterns to apply during generation:

- `references/api-client-template.md` -- API client class with pagination, retry, rate limiting, caching
- `references/agent-first-patterns.md` -- JSON envelope, HATEOAS next_actions, context-safe output, error fix suggestions
- `references/commander-patterns.md` -- Commander.js subcommands, global options, interactive prompts, colored output

### Key Generation Rules

**Entry point (`{service}.ts`):**
- Shebang: `#!/usr/bin/env npx tsx`
- Self-documenting root command (no args → prints full command tree as JSON)
- Global options: `--json` (force JSON output), `--verbose`, `--config <path>`

**API client (`lib/client.ts`):**
- Constructor takes base URL + auth config
- Auth from env var (name based on `catalog.auth.envVar`)
- Built-in pagination matching the API's pattern
- Retry with exponential backoff for 5xx and 429 errors
- Rate limiting based on discovered limits
- Optional response caching

**Envelope helpers (`lib/envelope.ts`):**
```typescript
const isAgent = !process.stdout.isTTY;

function respond(command: string, result: any, nextActions: Action[] = []) {
  if (isAgent) {
    console.log(JSON.stringify({ ok: true, command, result, next_actions: nextActions }));
  } else {
    return result; // caller handles human rendering
  }
}

function respondError(command: string, message: string, code: string, fix: string, nextActions: Action[] = []) {
  if (isAgent) {
    console.log(JSON.stringify({ ok: false, command, error: { message, code }, fix, next_actions: nextActions }));
  } else {
    console.error(`Error: ${message}`);
    console.error(`Fix: ${fix}`);
  }
  process.exit(1);
}
```

**Command files (`commands/{resource}.ts`):**
- One file per resource group
- Each endpoint becomes a subcommand: `mycli customers list`, `mycli customers get <id>`
- `list` commands: support `--limit`, `--offset`/`--cursor`, `--status` (if filterable)
- `get` commands: take ID as argument
- `

Conversación

Pregunta, comparte un consejo o avisa de que no funciona. Ordenado por lo que la gente marcó como útil.

Aún no hay publicaciones. Sé la primera persona en preguntar o compartir.

Lo publicado aquí lo escriben usuarios, no el equipo de PopNx.

Inicia sesión para publicar

Desde GitHub

Estrellas en GitHub
455
Autor
alexknowshtml
Licencia
MIT
Último cambio de código
20 feb 2026
Archivos SKILL.md del repo (con traducciones y plantillas)
1
Temas
ai-agent, api, claude-code, cli-generator, commander-js, nodejs, skill, typescript