@musistudio/claude-code-router 1.0.28 → 1.0.29

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
@@ -44,6 +44,7 @@ The `config.json` file has several key sections:
44
44
 
45
45
  - **`Providers`**: Used to configure different model providers.
46
46
  - **`Router`**: Used to set up routing rules. `default` specifies the default model, which will be used for all requests if no other route is configured.
47
+ - **`API_TIMEOUT_MS`**: Specifies the timeout for API calls in milliseconds.
47
48
 
48
49
  Here is a comprehensive example:
49
50
 
@@ -52,6 +53,7 @@ Here is a comprehensive example:
52
53
  "APIKEY": "your-secret-key",
53
54
  "PROXY_URL": "http://127.0.0.1:7890",
54
55
  "LOG": true,
56
+ "API_TIMEOUT_MS": 600000,
55
57
  "Providers": [
56
58
  {
57
59
  "name": "openrouter",
@@ -166,6 +168,16 @@ ccr code
166
168
  > ccr restart
167
169
  > ```
168
170
 
171
+ ### 4. UI Mode
172
+
173
+ For a more intuitive experience, you can use the UI mode to manage your configuration:
174
+
175
+ ```shell
176
+ ccr ui
177
+ ```
178
+
179
+ This will open a web-based interface where you can easily view and edit your `config.json` file.
180
+
169
181
  #### Providers
170
182
 
171
183
  The `Providers` array is where you define the different model providers you want to use. Each provider object requires:
package/README_zh.md CHANGED
@@ -40,6 +40,7 @@ npm install -g @musistudio/claude-code-router
40
40
  - **`HOST`** (可选): 您可以设置服务的主机地址。如果未设置 `APIKEY`,出于安全考虑,主机地址将强制设置为 `127.0.0.1`,以防止未经授权的访问。例如:`"HOST": "0.0.0.0"`。
41
41
  - **`Providers`**: 用于配置不同的模型提供商。
42
42
  - **`Router`**: 用于设置路由规则。`default` 指定默认模型,如果未配置其他路由,则该模型将用于所有请求。
43
+ - **`API_TIMEOUT_MS`**: API 请求超时时间,单位为毫秒。
43
44
 
44
45
  这是一个综合示例:
45
46
 
@@ -48,6 +49,7 @@ npm install -g @musistudio/claude-code-router
48
49
  "APIKEY": "your-secret-key",
49
50
  "PROXY_URL": "http://127.0.0.1:7890",
50
51
  "LOG": true,
52
+ "API_TIMEOUT_MS": 600000,
51
53
  "Providers": [
52
54
  {
53
55
  "name": "openrouter",
@@ -162,6 +164,16 @@ ccr code
162
164
  > ccr restart
163
165
  > ```
164
166
 
167
+ ### 4. UI 模式
168
+
169
+ 为了获得更直观的体验,您可以使用 UI 模式来管理您的配置:
170
+
171
+ ```shell
172
+ ccr ui
173
+ ```
174
+
175
+ 这将打开一个基于 Web 的界面,您可以在其中轻松查看和编辑您的 `config.json` 文件。
176
+
165
177
  #### Providers
166
178
 
167
179
  `Providers` 数组是您定义要使用的不同模型提供商的地方。每个提供商对象都需要:
@@ -113,5 +113,6 @@
113
113
  "webSearch": "gemini,gemini-2.5-flash"
114
114
  },
115
115
  "APIKEY": "your-secret-key",
116
- "HOST": "0.0.0.0"
116
+ "HOST": "0.0.0.0",
117
+ "API_TIMEOUT_MS": 600000
117
118
  }