troxy-cli 1.4.19 → 1.4.20

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 (2) hide show
  1. package/bin/troxy.js +10 -1
  2. package/package.json +1 -1
package/bin/troxy.js CHANGED
@@ -55,7 +55,15 @@ switch (command) {
55
55
  case '-v': {
56
56
  const { createRequire } = await import('module');
57
57
  const { version } = createRequire(import.meta.url)('../package.json');
58
- console.log(version);
58
+ process.stdout.write(version);
59
+ try {
60
+ const res = await fetch('https://registry.npmjs.org/troxy-cli/latest', { signal: AbortSignal.timeout(3000) });
61
+ const { version: latest } = await res.json();
62
+ if (version !== latest) {
63
+ process.stdout.write(` ⚠ ${latest} available — run: troxy update`);
64
+ }
65
+ } catch {}
66
+ process.stdout.write('\n');
59
67
  break;
60
68
  }
61
69
 
@@ -416,6 +424,7 @@ switch (command) {
416
424
  troxy policies describe --name "Block Amazon"
417
425
  troxy policies create --name "X" --action BLOCK --field amount --operator gte --value 500
418
426
  troxy policies create --name "X" --action BLOCK --mcp "My Laptop" (scoped to one MCP)
427
+ troxy policies set-priority --name "X" --priority 10
419
428
  troxy policies enable --name "X"
420
429
  troxy policies disable --name "X"
421
430
  troxy policies delete --name "X"
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "troxy-cli",
3
- "version": "1.4.19",
3
+ "version": "1.4.20",
4
4
  "description": "AI payment control — protect your agent's payments with policies",
5
5
  "type": "module",
6
6
  "bin": {