ccx-relay 1.6.0 → 1.7.0

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/ccx-init.js +7 -3
  2. package/package.json +1 -1
package/bin/ccx-init.js CHANGED
@@ -3,7 +3,7 @@
3
3
  import { createInterface } from 'node:readline';
4
4
  import { rmSync, existsSync } from 'node:fs';
5
5
  import { load, save, configPath } from '../src/config.js';
6
- import { enhance, listModels } from '../src/gemini.js';
6
+ import { enhance, listModels, RateLimitError } from '../src/gemini.js';
7
7
 
8
8
  const args = process.argv.slice(2);
9
9
 
@@ -77,8 +77,12 @@ async function runWizard() {
77
77
  await enhance('hello', { geminiApiKey: key, geminiModel: 'gemini-2.5-flash', timeoutSeconds: 10 });
78
78
  console.log('\x1b[32m✓ Valid\x1b[0m');
79
79
  } catch (err) {
80
- console.log(`\x1b[31m✗ Invalid key\x1b[0m — ${err.message}`);
81
- process.exit(1);
80
+ if (err instanceof RateLimitError) {
81
+ console.log('\x1b[32m✓ Valid\x1b[0m \x1b[2m(quota exceeded — key authenticated)\x1b[0m');
82
+ } else {
83
+ console.log(`\x1b[31m✗ Invalid key\x1b[0m — ${err.message}`);
84
+ process.exit(1);
85
+ }
82
86
  }
83
87
 
84
88
  // Fetch available models, fall back to hardcoded list
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "type": "module",
3
3
  "name": "ccx-relay",
4
- "version": "1.6.0",
4
+ "version": "1.7.0",
5
5
  "description": "Transparent PTY wrapper for Claude Code (or any CLI) that lets you refine your prompt with Gemini AI before submitting it, without leaving your terminal session.",
6
6
  "main": "bin/ccx.js",
7
7
  "bin": {