@velaro/cli 1.4.153 → 1.4.154

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.
@@ -3,12 +3,12 @@ import { runCommand } from '../run.js';
3
3
 
4
4
  const print = (data) => console.log(JSON.stringify(data, null, 2));
5
5
 
6
- // velaro canned-learning <list|generate|approve|reject|rollback|edits|record-edit|teams> (REST: messaging /CannedLearning/*)
6
+ // velaro canned-learning <list|generate|approve|reject|rollback|edits|record-edit|teams|usage> (REST: messaging /CannedLearning/*)
7
7
  export const cannedLearningCommand = {
8
8
  command: 'canned-learning <action> [id]',
9
9
  describe: 'AI canned message learning: list/generate suggestions, approve/reject/rollback (human review)',
10
10
  builder: (y) => y
11
- .positional('action', { choices: ['list', 'generate', 'approve', 'reject', 'rollback', 'edits', 'record-edit', 'teams'] })
11
+ .positional('action', { choices: ['list', 'generate', 'approve', 'reject', 'rollback', 'edits', 'record-edit', 'teams', 'usage'] })
12
12
  .positional('id', { type: 'number' })
13
13
  .option('team-id', { type: 'number', describe: 'list/edits: only this team; generate: run for this team (team managers must pass one they manage)' })
14
14
  .option('state', { type: 'string', default: 'pending_review', describe: 'pending_review|approved|rejected|rolled_back|all' })
@@ -22,6 +22,7 @@ export const cannedLearningCommand = {
22
22
  if (a.action === 'generate') return print(await messagingPost(`${base}/generate`, { teamId: a.teamId ?? null }));
23
23
  if (a.action === 'edits') return print(await messagingGet(`${base}/edit-events${a.teamId != null ? `?teamId=${encodeURIComponent(a.teamId)}` : ''}`));
24
24
  if (a.action === 'teams') return print(await messagingGet(`${base}/teams`));
25
+ if (a.action === 'usage') return print(await messagingGet(`${base}/usage`));
25
26
  if (a.action === 'record-edit') {
26
27
  if (a.id == null || !a.finalText) throw new Error('record-edit requires a canned response id and --final-text');
27
28
  return print(await messagingPost(`${base}/edit-events`, { cannedResponseId: a.id, finalText: a.finalText }));
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@velaro/cli",
3
- "version": "1.4.153",
3
+ "version": "1.4.154",
4
4
  "description": "Velaro Workspace v20 — command-line interface for managing bots, knowledge base ingestion, MCP API keys, search indexes, and ops health.",
5
5
  "type": "module",
6
6
  "bin": {