antigravity-claude-proxy 2.4.3 → 2.5.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.
package/README.md CHANGED
@@ -132,7 +132,10 @@ You can configure these settings in two ways:
132
132
 
133
133
  1. Open the WebUI at `http://localhost:8080`.
134
134
  2. Go to **Settings** → **Claude CLI**.
135
- 3. Select your preferred models and click **Apply to Claude CLI**.
135
+ 3. Use the **Connection Mode** toggle to switch between:
136
+ - **Proxy Mode**: Uses the local proxy server (Antigravity Cloud Code). Configure models, base URL, and presets here.
137
+ - **Paid Mode**: Uses the official Anthropic Credits directly (requires your own subscription). This hides proxy settings to prevent accidental misconfiguration.
138
+ 4. Click **Apply to Claude CLI** to save your changes.
136
139
 
137
140
  > [!TIP] > **Configuration Precedence**: System environment variables (set in shell profile like `.zshrc`) take precedence over the `settings.json` file. If you use the Web Console to manage settings, ensure you haven't manually exported conflicting variables in your terminal.
138
141
 
@@ -221,6 +224,18 @@ claude
221
224
 
222
225
  > **Note:** If Claude Code asks you to select a login method, add `"hasCompletedOnboarding": true` to `~/.claude.json` (macOS/Linux) or `%USERPROFILE%\.claude.json` (Windows), then restart your terminal and try again.
223
226
 
227
+ ### Proxy Mode vs. Paid Mode
228
+
229
+ Toggle in **Settings** → **Claude CLI**:
230
+
231
+ | Feature | 🔌 Proxy Mode | 💳 Paid Mode |
232
+ | :--- | :--- | :--- |
233
+ | **Backend** | Local Server (Antigravity) | Official Anthropic Credits |
234
+ | **Cost** | Free (Google Cloud) | Paid (Anthropic Credits) |
235
+ | **Models** | Claude + Gemini | Claude Only |
236
+
237
+ **Paid Mode** automatically clears proxy settings so you can use your official Anthropic account directly.
238
+
224
239
  ### Multiple Claude Code Instances (Optional)
225
240
 
226
241
  To run both the official Claude Code and Antigravity version simultaneously, add this alias:
@@ -298,7 +313,8 @@ antigravity-claude-proxy start --strategy=round-robin # Load-balanced
298
313
 
299
314
  - **Health Score Tracking**: Accounts earn points for successful requests and lose points for failures/rate-limits
300
315
  - **Token Bucket Rate Limiting**: Client-side throttling with regenerating tokens (50 max, 6/minute)
301
- - **Quota Awareness**: Accounts with critical quota (<5%) are deprioritized; exhausted accounts trigger emergency fallback
316
+ - **Quota Awareness**: Accounts below configurable quota thresholds are deprioritized; exhausted accounts trigger emergency fallback
317
+ - **Quota Protection**: Set minimum quota levels globally, per-account, or per-model to switch accounts before quota runs out
302
318
  - **Emergency Fallback**: When all accounts appear exhausted, bypasses checks with throttle delays (250-500ms)
303
319
  - **Automatic Cooldown**: Rate-limited accounts recover automatically after reset time expires
304
320
  - **Invalid Account Detection**: Accounts needing re-authentication are marked and skipped
@@ -340,16 +356,17 @@ The proxy includes a built-in, modern web interface for real-time monitoring and
340
356
  ### Key Features
341
357
 
342
358
  - **Real-time Dashboard**: Monitor request volume, active accounts, model health, and subscription tier distribution.
343
- - **Visual Model Quota**: Track per-model usage and next reset times with color-coded progress indicators.
344
- - **Account Management**: Add/remove Google accounts via OAuth, view subscription tiers (Free/Pro/Ultra) and quota status at a glance.
359
+ - **Visual Model Quota**: Track per-model usage and next reset times with color-coded progress indicators and draggable per-account threshold markers.
360
+ - **Account Management**: Add/remove Google accounts via OAuth, view subscription tiers (Free/Pro/Ultra), quota status, and per-account threshold settings.
345
361
  - **Manual OAuth Mode**: Add accounts on headless servers by copying the OAuth URL and pasting the authorization code.
346
362
  - **Claude CLI Configuration**: Edit your `~/.claude/settings.json` directly from the browser.
347
363
  - **Persistent History**: Tracks request volume by model family for 30 days, persisting across server restarts.
348
364
  - **Time Range Filtering**: Analyze usage trends over 1H, 6H, 24H, 7D, or All Time periods.
349
365
  - **Smart Analysis**: Auto-select top 5 most used models or toggle between Family/Model views.
350
366
  - **Live Logs**: Stream server logs with level-based filtering and search.
367
+ - **Quota Protection**: Set global or per-account minimum quota thresholds to proactively switch accounts before quota runs out.
351
368
  - **Advanced Tuning**: Configure retries, timeouts, and debug mode on the fly.
352
- - **Multi-language Interface**: Full support for English, Chinese (中文), Indonesian (Bahasa), and Portuguese (PT-BR).
369
+ - **Multi-language Interface**: Full support for English, Chinese (中文), Indonesian (Bahasa), Portuguese (PT-BR), and Turkish (Türkçe).
353
370
 
354
371
  ---
355
372
 
@@ -367,6 +384,7 @@ While most users can use the default settings, you can tune the proxy behavior v
367
384
  - **Load Balancing**: Adjust `defaultCooldownMs` and `maxWaitBeforeErrorMs`.
368
385
  - **Persistence**: Enable `persistTokenCache` to save OAuth sessions across restarts.
369
386
  - **Max Accounts**: Set `maxAccounts` (1-100) to limit the number of Google accounts. Default: 10.
387
+ - **Quota Threshold**: Set `globalQuotaThreshold` (0-0.99) to switch accounts before quota drops below a minimum level. Supports per-account and per-model overrides.
370
388
  - **Endpoint Fallback**: Automatic 403/404 endpoint fallback for API compatibility.
371
389
 
372
390
  Refer to `config.example.json` for a complete list of fields and documentation.
@@ -387,6 +405,7 @@ For macOS users who prefer a native experience, there's a companion menu bar app
387
405
  - **Status Indicator**: Menu bar icon shows server running state at a glance.
388
406
  - **WebUI Access**: Open the web management console directly from the menu.
389
407
  - **Port Configuration**: Customize the proxy server port (default: 8080).
408
+ - **Account Selection Strategy**: Choose between Hybrid, Sticky, or Round-Robin load balancing strategies.
390
409
  - **Auto-Start Options**: Launch server on app start and launch app at login.
391
410
  - **Native Experience**: Clean, native SwiftUI interface designed for macOS.
392
411
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "antigravity-claude-proxy",
3
- "version": "2.4.3",
3
+ "version": "2.5.0",
4
4
  "description": "Proxy server to use Antigravity's Claude models with Claude Code CLI",
5
5
  "main": "src/index.js",
6
6
  "type": "module",