better-ccflare 3.2.0-beta9 → 3.2.2

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
@@ -16,7 +16,7 @@ https://github.com/user-attachments/assets/c859872f-ca5e-4f8b-b6a0-7cc7461fe62a
16
16
  ## Why better-ccflare?
17
17
 
18
18
  - **🚀 Zero Rate Limit Errors** - Automatically distribute requests across multiple accounts
19
- - **🤖 Multi-Provider Support** - Claude OAuth, Claude API console, Vertex AI, NanoGPT, z.ai, Minimax, Anthropic-compatible, and OpenAI-compatible providers
19
+ - **🤖 Multi-Provider Support** - Claude OAuth, Claude API console, Vertex AI, AWS Bedrock, NanoGPT, z.ai, Minimax, Anthropic-compatible, and OpenAI-compatible providers
20
20
  - **🔒 OAuth Token Health** - Real-time monitoring of OAuth token status with automatic refresh and health indicators
21
21
  - **🔗 Custom API Endpoints** - Configure custom endpoints for Anthropic accounts for enterprise deployments
22
22
  - **☁️ OpenAI-Compatible Support** - Use OpenAI-compatible providers like OpenRouter, Together AI, and more with Claude API format
@@ -36,7 +36,7 @@ This project builds upon the excellent foundation of [snipeship/ccflare](https:/
36
36
  **🎯 Core Improvements (v3.0.0):**
37
37
  - **Enhanced Security** - Critical fixes for authentication bypass, command injection, and PKCE implementation
38
38
  - **OAuth Token Health Monitoring** - Real-time status indicators and automatic token refresh with 30-minute buffer
39
- - **Extended Provider Support** - NanoGPT (with dynamic pricing), Minimax, Anthropic-compatible, and OpenAI-compatible providers
39
+ - **Extended Provider Support** - AWS Bedrock, NanoGPT (with dynamic pricing), Minimax, Anthropic-compatible, and OpenAI-compatible providers
40
40
  - **Simplified Load Balancing** - Removed tier system for O(1) priority-based selection
41
41
  - **Real-time Analytics Dashboard** - Beautiful web UI with fixed request history (no disappearing requests)
42
42
  - **Package Distribution** - Available via npm and bun for easy installation
@@ -71,6 +71,8 @@ npm install -g better-ccflare
71
71
  better-ccflare
72
72
  ```
73
73
  Continue to [Configure Claude SDK](https://github.com/tombii/better-ccflare#configure-claude-sdk).
74
+
75
+ **⚠️ Windows npm Installation Issue**: If you installed via npm on Windows and encounter a path error like `"C:\\Program Files\\nodejs\\\\node_modules\\better-ccflare\\dist\\better-ccflare" is either misspelled or could not be found`, this is a known [npm bug on Windows](https://github.com/npm/cli/issues/969) affecting how npm generates wrapper scripts. See [Windows Troubleshooting](#windows-troubleshooting) for workarounds.
74
76
  ### Install via bun
75
77
 
76
78
  ```bash
@@ -533,6 +535,75 @@ No `NODE_OPTIONS` needed - Traefik provides trusted certificates automatically!
533
535
  curl -k https://yourhostname:8080/health
534
536
  ```
535
537
 
538
+ ## Windows Troubleshooting
539
+
540
+ ### Issue: "Command is misspelled or could not be found" after npm install
541
+
542
+ If you installed better-ccflare via npm on Windows and encounter an error like:
543
+
544
+ ```
545
+ The command "C:\Program Files\nodejs\\node_modules\better-ccflare\dist\better-ccflare" is either
546
+ misspelled or could not be found.
547
+ ```
548
+
549
+ This is a **known npm bug on Windows** (see [npm/cli#969](https://github.com/npm/cli/issues/969) and [nodejs/node#39010](https://github.com/nodejs/node/issues/39010)) affecting how npm generates wrapper scripts with double backslashes in paths.
550
+
551
+ ### Workarounds
552
+
553
+ **Option 1: Use `npx` (Recommended)**
554
+
555
+ ```powershell
556
+ npx better-ccflare
557
+ ```
558
+
559
+ This bypasses the npm wrapper script entirely and runs better-ccflare directly.
560
+
561
+ **Option 2: Use the Pre-compiled Binary**
562
+
563
+ Download the standalone Windows executable from [GitHub Releases](https://github.com/tombii/better-ccflare/releases/latest):
564
+
565
+ ```powershell
566
+ # Download better-ccflare-windows-x64.exe and run it directly
567
+ .\better-ccflare-windows-x64.exe
568
+ ```
569
+
570
+ **Option 3: Update npm**
571
+
572
+ Sometimes updating to the latest npm version fixes the issue:
573
+
574
+ ```powershell
575
+ npm install -g npm@latest
576
+ npm install -g better-ccflare
577
+ ```
578
+
579
+ **Option 4: Direct Execution**
580
+
581
+ If you need to use the npm-installed version, you can execute the binary directly:
582
+
583
+ ```powershell
584
+ node "%APPDATA%\npm\node_modules\better-ccflare\dist\better-ccflare"
585
+ ```
586
+
587
+ **Option 5: Use Bun Package Manager**
588
+
589
+ Bun doesn't have this bug and works correctly on Windows:
590
+
591
+ ```powershell
592
+ # Install bun from https://bun.sh
593
+ bun install -g better-ccflare
594
+ better-ccflare
595
+ ```
596
+
597
+ ### Root Cause
598
+
599
+ This issue is caused by a bug in npm's wrapper script generation on Windows, where it incorrectly constructs paths with double backslashes (`\\nodejs\\\\node_modules`). This is a longstanding npm bug that affects many CLI packages, not just better-ccflare.
600
+
601
+ The issue is being tracked in:
602
+ - [npm/cli#969](https://github.com/npm/cli/issues/969) - Generated .cmd script bugs
603
+ - [nodejs/node#39010](https://github.com/nodejs/node/issues/39010) - Double slashes in Windows paths
604
+
605
+ We recommend using one of the workarounds above until the npm bug is fixed.
606
+
536
607
  ## Features
537
608
 
538
609
  ### 🎯 Intelligent Load Balancing
@@ -568,12 +639,14 @@ No `NODE_OPTIONS` needed - Traefik provides trusted certificates automatically!
568
639
  ### ☁️ Multi-Provider Support
569
640
  - **Claude OAuth** - Anthropic OAuth accounts with 5-hour usage windows and session tracking (rate limit window based)
570
641
  - **Claude Console API** - Anthropic API key accounts with pay-as-you-go model (no session tracking)
642
+ - **AWS Bedrock** - Native AWS Bedrock integration with SigV4 authentication, inference profile support (geographic/global/regional), and automatic credential chain resolution via AWS CLI profiles
643
+ - **Vertex AI** - Google Cloud Vertex AI integration with service account authentication
571
644
  - **z.ai, Minimax** - API key based providers with pay-as-you-go model
572
645
  - **Anthropic-Compatible** - Custom Anthropic-compatible providers with pay-as-you-go model
573
646
  - **OpenAI-Compatible** - OpenAI-compatible providers (OpenRouter, Together AI, etc.) with Claude API format
574
647
  - **Universal API Format** - Use OpenAI-compatible providers (OpenRouter, Together AI, etc.) with Claude API format
575
648
  - **Automatic Format Conversion** - Seamless conversion between Anthropic and OpenAI request/response formats
576
- - **Model Mapping** - Map Claude models (opus, sonnet, haiku) to equivalent OpenAI models
649
+ - **Model Mapping** - Map Claude models (Opus, Sonnet, Haiku) to equivalent OpenAI models
577
650
  - **Streaming Support** - Full support for streaming responses from OpenAI-compatible providers
578
651
  - **API Key Authentication** - Secure API key management for OpenAI-compatible providers
579
652
  - **Cost Tracking** - Automatic cost calculation for usage monitoring and budgeting
@@ -660,7 +733,9 @@ Inspired by [snipeship/ccflare](https://github.com/snipeship/ccflare) - thanks f
660
733
  - [@anonym-uz](https://github.com/anonym-uz) - Critical auto-pause bug fix, analytics performance optimizations, request body truncation, and incremental vacuum implementation
661
734
  - [@makhweeb](https://github.com/makhweeb) - Enhanced request handling and analytics improvements
662
735
  - [@jw409](https://github.com/jw409) - Fixed OAuth account addition in WSL2 and compiled binaries by replacing unreliable prompt() with readline
663
- - [@materemias](https://github.com/materemias) - Testing and validation of Vertex AI provider implementation, thorough debugging of OAuth API key authentication (issue #54), extensive testing of new releases and features including AWS Bedrock support
736
+ - [@materemias](https://github.com/materemias) - Testing and validation of Vertex AI provider implementation, thorough debugging of OAuth API key authentication (issue #54), requesting and validating AWS Bedrock support (issue #49), and extensive testing of new releases and features
737
+ - [@tqtensor](https://github.com/tqtensor) - Comprehensive memory leak fix preventing OOM kills with smart chunk capping, memory monitoring, and optimized cleanup (PR #67)
738
+ - [@lunetics](https://github.com/lunetics) - Force-reset rate limit feature allowing manual clearing of stale rate-limit locks via API, CLI, and dashboard with immediate usage polling (PR #68), OOM kill prevention with periodic data retention cleanup, 3-day default retention, and time-scoped stats queries (PR #70), model registry sync removing retired models and adding sonnet-4.6 CLI shortcut (PR #71)
664
739
 
665
740
  ## Contributing
666
741
 
Binary file
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "better-ccflare",
3
- "version": "3.2.0-beta9",
3
+ "version": "3.2.2",
4
4
  "description": "Load balancer proxy for Claude API with intelligent distribution across multiple OAuth accounts to avoid rate limiting",
5
5
  "license": "MIT",
6
6
  "repository": {