@freeticket/cli 0.1.0 → 0.1.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (3) hide show
  1. package/README.md +80 -80
  2. package/dist/index.js +40 -42
  3. package/package.json +3 -3
package/README.md CHANGED
@@ -9,169 +9,169 @@
9
9
 
10
10
  # FreeTicket CLI
11
11
 
12
- **Tu plataforma de eventos, desde la terminal.**
12
+ **Your event platform, from the terminal.**
13
13
 
14
- Eventos, ventas, tickets, membresías, venues, staff e informes — todo a un comando de distancia.
14
+ Events, sales, tickets, memberships, venues, staff, and reports — one command away.
15
15
 
16
16
  [![npm](https://img.shields.io/npm/v/@freeticket/cli?color=FFD500&label=npm)](https://www.npmjs.com/package/@freeticket/cli)
17
17
  [![CI](https://github.com/AppFreeticket/freeticket-cli/actions/workflows/ci.yml/badge.svg)](https://github.com/AppFreeticket/freeticket-cli/actions/workflows/ci.yml)
18
18
  [![license](https://img.shields.io/badge/license-MIT-07C2BA.svg)](./LICENSE)
19
- [![node](https://img.shields.io/badge/node-%E2%89%A520-07C2BA.svg)](#requisitos)
19
+ [![node](https://img.shields.io/badge/node-%E2%89%A520-07C2BA.svg)](#requirements)
20
20
 
21
21
  </div>
22
22
 
23
23
  ---
24
24
 
25
- ## ✨ Qué es
25
+ ## What it is
26
26
 
27
- `ft` es el cliente de línea de comandos oficial de **FreeTicket**. Consume la
28
- **API REST B2B v1** y te deja inspeccionar y operar tu workspace sin abrir el
29
- dashboard: listar eventos, revisar ventas, exportar compradores, ver KPIs — todo
30
- con salida legible o `--json` para pipelines y scripts.
27
+ `ft` is the official command-line client for **FreeTicket**. It consumes the
28
+ **B2B REST API v1** and lets you inspect and operate your workspace without
29
+ opening the dashboard: list events, review sales, export buyers, check KPIs,
30
+ and use readable output or `--json` for pipelines and scripts.
31
31
 
32
- El cliente se **genera desde el contrato OpenAPI 3.1** del backend, así que cada
33
- endpoint que existe en la API existe como comando, y nunca queda desincronizado.
32
+ The client is **generated from the backend OpenAPI 3.1 contract**, so every
33
+ endpoint exposed by the API exists as a command and never drifts out of sync.
34
34
 
35
- ## 🚀 Instalación
35
+ ## Installation
36
36
 
37
37
  ```bash
38
- # global (recomendado)
38
+ # global install (recommended)
39
39
  npm install -g @freeticket/cli
40
40
 
41
- # o sin instalar
41
+ # or run without installing
42
42
  npx @freeticket/cli whoami
43
43
  ```
44
44
 
45
- Comprobá que quedó instalado:
45
+ Check that it was installed:
46
46
 
47
47
  ```bash
48
48
  ft --version
49
49
  ```
50
50
 
51
- ## ⚡ Quickstart
51
+ ## Quickstart
52
52
 
53
53
  ```bash
54
- # 1. Emití una API key en el backend (lado servidor):
55
- # pnpm api:key tu-email@dominio.com
56
- # → te devuelve una key ft_live_xxxxx (se muestra una sola vez)
54
+ # 1. Issue an API key in the backend (server side):
55
+ # pnpm api:key you@example.com
56
+ # -> returns an ft_live_xxxxx key (shown only once)
57
57
 
58
- # 2. Iniciá sesión (guarda la key en ~/.freeticket/config.json y la verifica)
58
+ # 2. Log in (stores the key in ~/.freeticket/config.json and verifies it)
59
59
  ft login --key ft_live_xxxxx
60
60
 
61
- # 3. ¿Quién soy y a qué workspaces tengo acceso?
61
+ # 3. Who am I, and which workspaces can I access?
62
62
  ft whoami
63
63
 
64
- # 4. Empezá a explorar
64
+ # 4. Start exploring
65
65
  ft events list
66
66
  ft reports summary --period 30d
67
67
  ft sales list --status CONFIRMED --json
68
68
  ```
69
69
 
70
- ## 🧭 Comandos
70
+ ## Commands
71
71
 
72
- | Comando | Qué hace | Rol mínimo |
72
+ | Command | What it does | Minimum role |
73
73
  |---|---|---|
74
- | `ft login --key <key>` | Guarda y verifica tu API key | VIEWER |
75
- | `ft whoami` | Usuario activo + workspaces accesibles | VIEWER |
76
- | `ft config` · `ft logout` | Ver config (key enmascarada) · borrar key | — |
77
- | `ft events list` · `get <id>` | Eventos del workspace | VIEWER |
78
- | `ft ticket-types list` · `get <id>` | Tipos de ticket (`--event-date-id`) | VIEWER |
79
- | `ft sales list` · `get <id>` | Ventas (`--status`) | STAFF |
80
- | `ft plans list` · `get <id>` | Planes de membresía | VIEWER |
74
+ | `ft login --key <key>` | Stores and verifies your API key | VIEWER |
75
+ | `ft whoami` | Active user and accessible workspaces | VIEWER |
76
+ | `ft config` · `ft logout` | Show config (masked key) · remove key | — |
77
+ | `ft events list` · `get <id>` | Workspace events | VIEWER |
78
+ | `ft ticket-types list` · `get <id>` | Ticket types (`--event-date-id`) | VIEWER |
79
+ | `ft sales list` · `get <id>` | Sales (`--status`) | STAFF |
80
+ | `ft plans list` · `get <id>` | Membership plans | VIEWER |
81
81
  | `ft venues list` · `get <id>` | Venues | VIEWER |
82
- | `ft staff list` | Staff del workspace | ADMIN |
82
+ | `ft staff list` | Workspace staff | ADMIN |
83
83
  | `ft reports summary` | KPIs (`--period 7d\|30d\|90d\|1y`) | VIEWER |
84
- | `ft reports export buyers\|subscribers` | Exporta compradores / suscriptores | ADMIN |
84
+ | `ft reports export buyers\|subscribers` | Export buyers / subscribers | ADMIN |
85
85
 
86
- > Las **escrituras** (crear/editar/borrar) están declaradas en el contrato pero
87
- > responden `501` por ahora — llegan en la **fase 2**.
86
+ > **Write operations** (create/update/delete) are declared in the contract but
87
+ > currently return `501`. They are planned for **phase 2**.
88
88
 
89
- ### Flags comunes
89
+ ### Common flags
90
90
 
91
- | Flag | Aplica a | Descripción |
91
+ | Flag | Applies to | Description |
92
92
  |---|---|---|
93
- | `--json` | todos | salida JSON cruda, ideal para `jq` y scripts |
94
- | `--workspace <id>` | todos | ejecuta el comando contra otro workspace |
95
- | `--limit <n>` `--cursor <id>` | listados | paginación por cursor (1–100, default 20) |
93
+ | `--json` | all commands | Raw JSON output, ideal for `jq` and scripts |
94
+ | `--workspace <id>` | all commands | Run the command against another workspace |
95
+ | `--limit <n>` `--cursor <id>` | list commands | Cursor pagination (1-100, default 20) |
96
96
 
97
- ## 🔐 Configuración
97
+ ## Configuration
98
98
 
99
- `ft` resuelve su config en este orden de precedencia:
99
+ `ft` resolves configuration in this precedence order:
100
100
 
101
101
  ```
102
- flags > variables de entorno > ~/.freeticket/config.json > defaults
102
+ flags > environment variables > ~/.freeticket/config.json > defaults
103
103
  ```
104
104
 
105
- | Variable | Default | Descripción |
105
+ | Variable | Default | Description |
106
106
  |---|---|---|
107
- | `FT_API_URL` | `https://admin.appfreeticket.com` | base de la API (sin `/api/v1`) |
108
- | `FT_API_KEY` | — | tu key `ft_live_…` |
109
- | `FT_WORKSPACE_ID` | *home* | workspace activo por defecto |
107
+ | `FT_API_URL` | `https://admin.appfreeticket.com` | API base URL (without `/api/v1`) |
108
+ | `FT_API_KEY` | — | Your `ft_live_...` key |
109
+ | `FT_WORKSPACE_ID` | *home* | Default active workspace |
110
110
 
111
- El archivo `~/.freeticket/config.json` se crea con permisos `0600` (solo tu
112
- usuario lo lee) porque guarda la API key. Mirá [`.env.example`](./.env.example).
111
+ The `~/.freeticket/config.json` file is created with `0600` permissions (only
112
+ your user can read it) because it stores the API key. See [`.env.example`](./.env.example).
113
113
 
114
- ## 🧱 Paginación, errores y dinero
114
+ ## Pagination, errors, and money
115
115
 
116
- - **Paginación:** los listados devuelven `page.nextCursor`. El CLI te imprime la
117
- pista `--cursor <id>` en *stderr* para que `--json` quede limpio en *stdout*.
118
- - **Errores:** formato uniforme `{ error: { code, message, details } }`. El CLI
119
- traduce `401/403/404/501` a mensajes accionables y sale con código `1`.
120
- - **Dinero:** número en la moneda del recurso (`currency`, normalmente `COP`).
121
- - **Fechas:** ISO 8601 UTC.
116
+ - **Pagination:** list responses include `page.nextCursor`. The CLI prints the
117
+ `--cursor <id>` hint to *stderr* so `--json` stays clean on *stdout*.
118
+ - **Errors:** uniform format `{ error: { code, message, details } }`. The CLI
119
+ translates `401/403/404/501` into actionable messages and exits with code `1`.
120
+ - **Money:** number in the resource currency (`currency`, usually `COP`).
121
+ - **Dates:** ISO 8601 UTC.
122
122
 
123
- ## 🛠️ Desarrollo
123
+ ## Development
124
124
 
125
125
  ```bash
126
126
  pnpm install
127
- pnpm generate # genera src/client/ desde openapi.json
128
- pnpm build # bundle a dist/ con tsup
127
+ pnpm generate # generates src/client/ from openapi.json
128
+ pnpm build # bundles dist/ with tsup
129
129
  pnpm test # vitest
130
130
  pnpm lint # biome
131
131
  ```
132
132
 
133
- ### Mantener el cliente en sync con el backend
133
+ ### Keeping the client in sync with the backend
134
134
 
135
- El contrato vive commiteado en [`openapi.json`](./openapi.json). Cuando el backend
136
- cambia la API:
135
+ The contract is committed in [`openapi.json`](./openapi.json). When the backend
136
+ API changes:
137
137
 
138
138
  ```bash
139
139
  FT_OPENAPI_URL=https://admin.appfreeticket.com/api/v1/openapi.json pnpm sync-openapi
140
140
  ```
141
141
 
142
- Esto descarga el spec, lo reescribe en `openapi.json` (el diff queda en git como
143
- contrato explícito entre equipos) y regenera `src/client/`. Si un `operationId`
144
- desaparece, TypeScript falla en compilación — el cambio incompatible se ve antes
145
- de mergear.
142
+ This downloads the spec, rewrites `openapi.json` (the diff becomes the explicit
143
+ contract between teams), and regenerates `src/client/`. If an `operationId`
144
+ disappears, TypeScript fails during compilation so the breaking change is visible
145
+ before merge.
146
146
 
147
- > `src/client/` es **generado** y está en `.gitignore`: se reconstruye en cada
148
- > build y en CI. No lo edites a mano.
147
+ > `src/client/` is **generated** and listed in `.gitignore`: it is rebuilt on
148
+ > every build and in CI. Do not edit it by hand.
149
149
 
150
- ## 📂 Estructura
150
+ ## Structure
151
151
 
152
152
  ```
153
153
  freeticket-cli/
154
- ├── openapi.json # contrato — fuente de verdad versionada
154
+ ├── openapi.json # contract — versioned source of truth
155
155
  ├── src/
156
- │ ├── client/ # generado por @hey-api (gitignored)
156
+ │ ├── client/ # generated by @hey-api (gitignored)
157
157
  │ ├── commands/ # auth, resource (factory), reports
158
158
  │ ├── lib/ # config, api, output, banner
159
- │ └── index.ts # registra los comandos (commander)
159
+ │ └── index.ts # registers commands (commander)
160
160
  ├── scripts/sync-openapi.ts
161
- └── .claude/agents/ # subagentes de revisión e integración
161
+ └── .claude/agents/ # review and integration subagents
162
162
  ```
163
163
 
164
- ## 🤖 Agentes
164
+ ## Agents
165
165
 
166
- El repo trae subagentes de Claude Code en [`.claude/agents/`](./.claude/agents)
167
- para su revisión e integración continua: revisor TS/CLI, sincronizador de
168
- OpenAPI, QA del CLI y release/devops. Ver el [README de agentes](./.claude/agents/README.md).
166
+ The repo includes Claude Code subagents in [`.claude/agents/`](./.claude/agents)
167
+ for continuous review and integration: TypeScript/CLI reviewer, OpenAPI sync,
168
+ CLI QA, and release/devops. See the [agents README](./.claude/agents/README.md).
169
169
 
170
- ## Requisitos
170
+ ## Requirements
171
171
 
172
- - Node.js **≥ 20**
173
- - Una API key de FreeTicket (`ft_live_…`)
172
+ - Node.js **>= 20**
173
+ - A FreeTicket API key (`ft_live_...`)
174
174
 
175
- ## Licencia
175
+ ## License
176
176
 
177
177
  [MIT](./LICENSE) © FreeTicket
package/dist/index.js CHANGED
@@ -6,9 +6,9 @@ import { Command } from "commander";
6
6
  // package.json
7
7
  var package_default = {
8
8
  name: "@freeticket/cli",
9
- version: "0.1.0",
10
- description: "CLI oficial de FreeTicket \u2014 consume la API REST B2B (eventos, ventas, tickets, membres\xEDas, venues, staff, informes).",
11
- keywords: ["freeticket", "cli", "ticketing", "eventos", "api"],
9
+ version: "0.1.1",
10
+ description: "Official FreeTicket CLI \u2014 consumes the B2B REST API for events, sales, tickets, memberships, venues, staff, and reports.",
11
+ keywords: ["freeticket", "cli", "ticketing", "events", "api"],
12
12
  homepage: "https://github.com/AppFreeticket/freeticket-cli#readme",
13
13
  bugs: "https://github.com/AppFreeticket/freeticket-cli/issues",
14
14
  repository: {
@@ -285,9 +285,7 @@ function saveConfig(patch) {
285
285
  function configureClient(workspaceOverride) {
286
286
  const cfg = loadConfig();
287
287
  if (!cfg.apiKey) {
288
- fail(
289
- "No hay API key configurada. Ejecuta `ft login` o exporta FT_API_KEY."
290
- );
288
+ fail("No API key configured. Run `ft login` or export FT_API_KEY.");
291
289
  }
292
290
  const workspaceId = workspaceOverride ?? cfg.workspaceId;
293
291
  client.setConfig({
@@ -304,24 +302,26 @@ function unwrap(res) {
304
302
  const err = res.error?.error;
305
303
  if (err) {
306
304
  const lines = [
307
- `Error ${status ?? ""} [${err.code ?? "?"}]: ${err.message ?? "fallo desconocido"}`.trim()
305
+ `Error ${status ?? ""} [${err.code ?? "?"}]: ${err.message ?? "unknown failure"}`.trim()
308
306
  ];
309
307
  for (const d of err.details ?? [])
310
308
  lines.push(` \xB7 ${d.path ?? ""}: ${d.message ?? ""}`.trimEnd());
311
309
  fail(lines.join("\n"), hintFor(status));
312
310
  }
313
- fail(`La API respondi\xF3 ${status ?? "un error"} sin cuerpo interpretable.`);
311
+ fail(
312
+ `The API responded with ${status ?? "an error"} without a readable body.`
313
+ );
314
314
  }
315
315
  function hintFor(status) {
316
316
  switch (status) {
317
317
  case 401:
318
- return "API key inv\xE1lida, revocada o expirada. Ejecuta `ft login`.";
318
+ return "Invalid, revoked, or expired API key. Run `ft login`.";
319
319
  case 403:
320
- return "Tu rol o tu workspace no permiten esta acci\xF3n.";
320
+ return "Your role or workspace does not allow this action.";
321
321
  case 404:
322
- return "El recurso no existe o pertenece a otro workspace.";
322
+ return "The resource does not exist or belongs to another workspace.";
323
323
  case 501:
324
- return "Operaci\xF3n de escritura: disponible en la fase 2 del CLI.";
324
+ return "Write operation: planned for CLI phase 2.";
325
325
  }
326
326
  }
327
327
  function fail(message, hint) {
@@ -342,7 +342,7 @@ function print(data, opts = {}) {
342
342
  }
343
343
  if (Array.isArray(data) && data.every(isPlainRow)) {
344
344
  if (data.length === 0) {
345
- console.log(chalk.dim("(sin resultados)"));
345
+ console.log(chalk.dim("(no results)"));
346
346
  return;
347
347
  }
348
348
  const cols = opts.columns ?? Object.keys(data[0]);
@@ -359,7 +359,7 @@ function print(data, opts = {}) {
359
359
  function printNextCursor(page) {
360
360
  if (page?.nextCursor) {
361
361
  console.error(chalk.dim(`
362
- M\xE1s resultados: --cursor ${page.nextCursor}`));
362
+ More results: --cursor ${page.nextCursor}`));
363
363
  }
364
364
  }
365
365
  function isPlainRow(v) {
@@ -373,15 +373,13 @@ function fmt(v) {
373
373
 
374
374
  // src/commands/auth.ts
375
375
  function registerAuth(program2) {
376
- program2.command("login").description(
377
- "Guarda la API key y el workspace en ~/.freeticket/config.json"
378
- ).requiredOption(
376
+ program2.command("login").description("Store the API key and workspace in ~/.freeticket/config.json").requiredOption(
379
377
  "--key <ft_live_\u2026>",
380
- "API key emitida en el backend (pnpm api:key)"
378
+ "API key issued in the backend (pnpm api:key)"
381
379
  ).option(
382
380
  "--url <url>",
383
- "base URL de la API (default: https://admin.appfreeticket.com)"
384
- ).option("--workspace <id>", "workspace activo por defecto").action(async (opts) => {
381
+ "API base URL (default: https://admin.appfreeticket.com)"
382
+ ).option("--workspace <id>", "default active workspace").action(async (opts) => {
385
383
  saveConfig({
386
384
  apiKey: opts.key,
387
385
  ...opts.url ? { apiUrl: opts.url } : {},
@@ -390,22 +388,22 @@ function registerAuth(program2) {
390
388
  configureClient(opts.workspace);
391
389
  const me = unwrap(await getMe({})).data;
392
390
  console.log(
393
- `${chalk2.green("\u2713")} Sesi\xF3n guardada en ${chalk2.dim(CONFIG_PATH)}`
391
+ `${chalk2.green("\u2713")} Session saved in ${chalk2.dim(CONFIG_PATH)}`
394
392
  );
395
393
  print(me, {});
396
394
  });
397
- program2.command("whoami").description("Muestra el usuario autenticado y sus workspaces (GET /me)").option("--json", "salida JSON cruda").action(async (opts) => {
395
+ program2.command("whoami").description("Show the authenticated user and workspaces (GET /me)").option("--json", "raw JSON output").action(async (opts) => {
398
396
  configureClient();
399
397
  const me = unwrap(await getMe({})).data;
400
398
  print(me, { json: opts.json });
401
399
  });
402
- program2.command("logout").description("Borra la API key guardada").action(() => {
400
+ program2.command("logout").description("Remove the stored API key").action(() => {
403
401
  saveConfig({ apiKey: void 0 });
404
402
  console.log(
405
- `${chalk2.green("\u2713")} API key eliminada de ${chalk2.dim(CONFIG_PATH)}`
403
+ `${chalk2.green("\u2713")} API key removed from ${chalk2.dim(CONFIG_PATH)}`
406
404
  );
407
405
  });
408
- program2.command("config").description("Muestra la configuraci\xF3n activa (la API key se enmascara)").action(() => {
406
+ program2.command("config").description("Show active configuration (the API key is masked)").action(() => {
409
407
  const cfg = loadConfig();
410
408
  print(
411
409
  {
@@ -420,20 +418,20 @@ function registerAuth(program2) {
420
418
 
421
419
  // src/commands/reports.ts
422
420
  function registerReports(program2) {
423
- const root = program2.command("reports").description("KPIs y exportaciones");
424
- root.command("summary").description("Resumen de KPIs del workspace").option("--period <p>", "7d | 30d | 90d | 1y", "30d").option("--workspace <id>", "override del workspace").option("--json", "salida JSON cruda").action(async (opts) => {
421
+ const root = program2.command("reports").description("KPIs and exports");
422
+ root.command("summary").description("Workspace KPI summary").option("--period <p>", "7d | 30d | 90d | 1y", "30d").option("--workspace <id>", "workspace override").option("--json", "raw JSON output").action(async (opts) => {
425
423
  configureClient(opts.workspace);
426
424
  const body = unwrap(
427
425
  await getReportsSummary({ query: { period: opts.period } })
428
426
  );
429
427
  print(body.data, { json: opts.json });
430
428
  });
431
- const exp = root.command("export").description("Exporta compradores o suscriptores (CSV)");
429
+ const exp = root.command("export").description("Export buyers or subscribers (CSV)");
432
430
  for (const [name, fn, label] of [
433
- ["buyers", getReportsExportsBuyers, "compradores"],
434
- ["subscribers", getReportsExportsSubscribers, "suscriptores"]
431
+ ["buyers", getReportsExportsBuyers, "buyers"],
432
+ ["subscribers", getReportsExportsSubscribers, "subscribers"]
435
433
  ]) {
436
- exp.command(name).description(`Exporta ${label}`).option("--workspace <id>", "override del workspace").option("--json", "salida JSON cruda").action(async (opts) => {
434
+ exp.command(name).description(`Export ${label}`).option("--workspace <id>", "workspace override").option("--json", "raw JSON output").action(async (opts) => {
437
435
  configureClient(opts.workspace);
438
436
  const body = unwrap(await fn({}));
439
437
  print(body.data ?? body, { json: opts.json });
@@ -446,7 +444,7 @@ function registerResource(program2, spec) {
446
444
  const root = program2.command(spec.name).description(spec.describe);
447
445
  if (spec.list) {
448
446
  const list = spec.list;
449
- const cmd = root.command("list").description(`Lista ${spec.name} del workspace activo`).option("--limit <n>", "resultados por p\xE1gina (1\u2013100)", "20").option("--cursor <id>", "cursor de paginaci\xF3n").option("--workspace <id>", "override del workspace").option("--json", "salida JSON cruda");
447
+ const cmd = root.command("list").description(`List ${spec.name} from the active workspace`).option("--limit <n>", "results per page (1-100)", "20").option("--cursor <id>", "pagination cursor").option("--workspace <id>", "workspace override").option("--json", "raw JSON output");
450
448
  for (const f of spec.listFlags ?? []) cmd.option(f.flag, f.describe);
451
449
  cmd.action(async (opts) => {
452
450
  configureClient(opts.workspace);
@@ -465,7 +463,7 @@ function registerResource(program2, spec) {
465
463
  }
466
464
  if (spec.get) {
467
465
  const get = spec.get;
468
- root.command("get <id>").description(`Detalle de un ${spec.name.replace(/s$/, "")} por id`).option("--workspace <id>", "override del workspace").option("--json", "salida JSON cruda").action(async (id, opts) => {
466
+ root.command("get <id>").description(`Get one ${spec.name.replace(/s$/, "")} by id`).option("--workspace <id>", "workspace override").option("--json", "raw JSON output").action(async (id, opts) => {
469
467
  configureClient(opts.workspace);
470
468
  const body = unwrap(await get({ path: { id } }));
471
469
  print(body.data, { json: opts.json });
@@ -489,49 +487,49 @@ var ART = String.raw`
489
487
  function banner() {
490
488
  return [
491
489
  c.hex(YELLOW)(ART),
492
- c.hex(YELLOW)(" \u25CF ") + c.hex(YELLOW).bold("FreeTicket") + c.hex(YELLOW)(" \u2014 eventos, tickets y ventas desde tu terminal"),
490
+ c.hex(YELLOW)(" \u25CF ") + c.hex(YELLOW).bold("FreeTicket") + c.hex(YELLOW)(" \u2014 events, tickets, and sales from your terminal"),
493
491
  ""
494
492
  ].join("\n");
495
493
  }
496
494
 
497
495
  // src/index.ts
498
496
  var program = new Command();
499
- program.name("ft").description("CLI oficial de FreeTicket").version(package_default.version, "-v, --version").addHelpText("beforeAll", banner());
497
+ program.name("ft").description("Official FreeTicket CLI").version(package_default.version, "-v, --version").addHelpText("beforeAll", banner());
500
498
  registerAuth(program);
501
499
  registerResource(program, {
502
500
  name: "events",
503
- describe: "Eventos",
501
+ describe: "Events",
504
502
  list: getEvents,
505
503
  get: getEventsId,
506
504
  columns: ["id", "name", "status", "startsAt"]
507
505
  });
508
506
  registerResource(program, {
509
507
  name: "sales",
510
- describe: "Ventas",
508
+ describe: "Sales",
511
509
  list: getSales,
512
510
  get: getSalesId,
513
511
  columns: ["id", "reference", "status", "total", "currency", "createdAt"],
514
512
  listFlags: [
515
- { flag: "--status <s>", describe: "filtra por estado", query: "status" }
513
+ { flag: "--status <s>", describe: "filter by status", query: "status" }
516
514
  ]
517
515
  });
518
516
  registerResource(program, {
519
517
  name: "ticket-types",
520
- describe: "Tipos de ticket",
518
+ describe: "Ticket types",
521
519
  list: getTicketTypes,
522
520
  get: getTicketTypesId,
523
521
  columns: ["id", "name", "price", "currency", "stock"],
524
522
  listFlags: [
525
523
  {
526
524
  flag: "--event-date-id <id>",
527
- describe: "filtra por fecha de evento",
525
+ describe: "filter by event date",
528
526
  query: "eventDateId"
529
527
  }
530
528
  ]
531
529
  });
532
530
  registerResource(program, {
533
531
  name: "plans",
534
- describe: "Planes de membres\xEDa",
532
+ describe: "Membership plans",
535
533
  list: getMembershipPlans,
536
534
  get: getMembershipPlansId,
537
535
  columns: ["id", "name", "price", "currency", "interval"]
@@ -545,7 +543,7 @@ registerResource(program, {
545
543
  });
546
544
  registerResource(program, {
547
545
  name: "staff",
548
- describe: "Staff del workspace",
546
+ describe: "Workspace staff",
549
547
  list: getStaff,
550
548
  columns: ["id", "name", "email", "role"]
551
549
  });
package/package.json CHANGED
@@ -1,8 +1,8 @@
1
1
  {
2
2
  "name": "@freeticket/cli",
3
- "version": "0.1.0",
4
- "description": "CLI oficial de FreeTicket — consume la API REST B2B (eventos, ventas, tickets, membresías, venues, staff, informes).",
5
- "keywords": ["freeticket", "cli", "ticketing", "eventos", "api"],
3
+ "version": "0.1.1",
4
+ "description": "Official FreeTicket CLI — consumes the B2B REST API for events, sales, tickets, memberships, venues, staff, and reports.",
5
+ "keywords": ["freeticket", "cli", "ticketing", "events", "api"],
6
6
  "homepage": "https://github.com/AppFreeticket/freeticket-cli#readme",
7
7
  "bugs": "https://github.com/AppFreeticket/freeticket-cli/issues",
8
8
  "repository": {