@eddyskywalker/dsh-chatgpt-subscription 0.3.9 → 0.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.
Files changed (97) hide show
  1. package/CHANGELOG.md +51 -1
  2. package/lib/client.js +959 -503
  3. package/lib/client.js.map +1 -1
  4. package/lib/index.js +5592 -3670
  5. package/lib/types/client/CodexSubscriptionSection.d.ts +1 -1
  6. package/lib/types/client/CodexSubscriptionSection.d.ts.map +1 -1
  7. package/lib/types/client/antigravity/AntigravitySection.d.ts.map +1 -1
  8. package/lib/types/client/antigravity/locales.d.ts +63 -153
  9. package/lib/types/client/antigravity/locales.d.ts.map +1 -1
  10. package/lib/types/client/antigravity/styles.d.ts.map +1 -1
  11. package/lib/types/client/api.d.ts +13 -1
  12. package/lib/types/client/api.d.ts.map +1 -1
  13. package/lib/types/client/command-code/CommandCodeSection.d.ts.map +1 -1
  14. package/lib/types/client/command-code/locales.d.ts +72 -201
  15. package/lib/types/client/command-code/locales.d.ts.map +1 -1
  16. package/lib/types/client/common/AccountPoolSection.d.ts +41 -0
  17. package/lib/types/client/common/AccountPoolSection.d.ts.map +1 -0
  18. package/lib/types/client/common/account-pool-labels.d.ts +43 -0
  19. package/lib/types/client/common/account-pool-labels.d.ts.map +1 -0
  20. package/lib/types/client/common/styles.d.ts +11 -0
  21. package/lib/types/client/common/styles.d.ts.map +1 -0
  22. package/lib/types/client/index.d.ts.map +1 -1
  23. package/lib/types/client/kimi-code/KimiCodeSection.d.ts.map +1 -1
  24. package/lib/types/client/kimi-code/locales.d.ts +69 -336
  25. package/lib/types/client/kimi-code/locales.d.ts.map +1 -1
  26. package/lib/types/client/locales.d.ts +49 -3
  27. package/lib/types/client/locales.d.ts.map +1 -1
  28. package/lib/types/host/antigravity/account-pool.d.ts +60 -0
  29. package/lib/types/host/antigravity/account-pool.d.ts.map +1 -0
  30. package/lib/types/host/antigravity/adapter.d.ts +3 -1
  31. package/lib/types/host/antigravity/adapter.d.ts.map +1 -1
  32. package/lib/types/host/antigravity/mapper.d.ts.map +1 -1
  33. package/lib/types/host/antigravity/oauth.d.ts +1 -1
  34. package/lib/types/host/antigravity/oauth.d.ts.map +1 -1
  35. package/lib/types/host/antigravity/routes.d.ts +3 -2
  36. package/lib/types/host/antigravity/routes.d.ts.map +1 -1
  37. package/lib/types/host/antigravity/token-store.d.ts +3 -0
  38. package/lib/types/host/antigravity/token-store.d.ts.map +1 -1
  39. package/lib/types/host/codex-account-pool.d.ts +64 -0
  40. package/lib/types/host/codex-account-pool.d.ts.map +1 -0
  41. package/lib/types/host/command-code/account-pool.d.ts +60 -0
  42. package/lib/types/host/command-code/account-pool.d.ts.map +1 -0
  43. package/lib/types/host/command-code/adapter.d.ts +11 -1
  44. package/lib/types/host/command-code/adapter.d.ts.map +1 -1
  45. package/lib/types/host/command-code/client.d.ts +17 -1
  46. package/lib/types/host/command-code/client.d.ts.map +1 -1
  47. package/lib/types/host/command-code/mapper.d.ts.map +1 -1
  48. package/lib/types/host/command-code/oauth.d.ts +4 -1
  49. package/lib/types/host/command-code/oauth.d.ts.map +1 -1
  50. package/lib/types/host/command-code/routes.d.ts +12 -3
  51. package/lib/types/host/command-code/routes.d.ts.map +1 -1
  52. package/lib/types/host/command-code/token-store.d.ts +3 -0
  53. package/lib/types/host/command-code/token-store.d.ts.map +1 -1
  54. package/lib/types/host/common/account-pool.d.ts +179 -0
  55. package/lib/types/host/common/account-pool.d.ts.map +1 -0
  56. package/lib/types/host/common/home.d.ts +8 -0
  57. package/lib/types/host/common/home.d.ts.map +1 -0
  58. package/lib/types/host/kimi-code/account-pool.d.ts +48 -0
  59. package/lib/types/host/kimi-code/account-pool.d.ts.map +1 -0
  60. package/lib/types/host/kimi-code/adapter.d.ts +10 -1
  61. package/lib/types/host/kimi-code/adapter.d.ts.map +1 -1
  62. package/lib/types/host/kimi-code/client.d.ts +16 -0
  63. package/lib/types/host/kimi-code/client.d.ts.map +1 -1
  64. package/lib/types/host/kimi-code/mapper.d.ts.map +1 -1
  65. package/lib/types/host/kimi-code/oauth.d.ts +2 -0
  66. package/lib/types/host/kimi-code/oauth.d.ts.map +1 -1
  67. package/lib/types/host/kimi-code/routes.d.ts +11 -3
  68. package/lib/types/host/kimi-code/routes.d.ts.map +1 -1
  69. package/lib/types/host/kimi-code/token-store.d.ts +3 -0
  70. package/lib/types/host/kimi-code/token-store.d.ts.map +1 -1
  71. package/lib/types/host/model-catalog.d.ts.map +1 -1
  72. package/lib/types/host/oauth-service.d.ts +41 -2
  73. package/lib/types/host/oauth-service.d.ts.map +1 -1
  74. package/lib/types/host/preferences.d.ts.map +1 -1
  75. package/lib/types/host/preset-sync.d.ts +7 -1
  76. package/lib/types/host/preset-sync.d.ts.map +1 -1
  77. package/lib/types/host/responses-client.d.ts +15 -0
  78. package/lib/types/host/responses-client.d.ts.map +1 -1
  79. package/lib/types/host/routes.d.ts +2 -1
  80. package/lib/types/host/routes.d.ts.map +1 -1
  81. package/lib/types/host/token-store-windows.d.ts.map +1 -1
  82. package/lib/types/host/usage-service.d.ts +15 -0
  83. package/lib/types/host/usage-service.d.ts.map +1 -1
  84. package/lib/types/index.d.ts +6 -0
  85. package/lib/types/index.d.ts.map +1 -1
  86. package/lib/types/shared/account-pool-contracts.d.ts +47 -0
  87. package/lib/types/shared/account-pool-contracts.d.ts.map +1 -0
  88. package/lib/types/shared/antigravity-contracts.d.ts +12 -0
  89. package/lib/types/shared/antigravity-contracts.d.ts.map +1 -1
  90. package/lib/types/shared/command-code-contracts.d.ts +16 -0
  91. package/lib/types/shared/command-code-contracts.d.ts.map +1 -1
  92. package/lib/types/shared/contracts.d.ts +8 -0
  93. package/lib/types/shared/contracts.d.ts.map +1 -1
  94. package/lib/types/shared/kimi-code-contracts.d.ts +16 -0
  95. package/lib/types/shared/kimi-code-contracts.d.ts.map +1 -1
  96. package/lib/types/shared/preferences.d.ts.map +1 -1
  97. package/package.json +1 -1
@@ -45,7 +45,8 @@ export declare const zh: {
45
45
  readonly routeOwned: "模型路由由本插件提供";
46
46
  readonly routeConflict: "模型路由已被其他 Provider 占用:{detail}。请在 DSH 设置中移除重复的 Provider 配置后重试。";
47
47
  readonly modelsSection: "模型";
48
- readonly modelsHint: "勾选后模型才会出现在对话页的模型选择列表中;至少保留一个。";
48
+ readonly enableProvider: "启用此供应商";
49
+ readonly modelsHint: "勾选后模型才会出现在对话页的模型选择列表中;全部取消勾选或关闭上方开关可在列表中隐藏该供应商。";
49
50
  readonly refreshCatalog: "刷新模型目录";
50
51
  readonly refreshingCatalog: "刷新中...";
51
52
  readonly selectAll: "全选";
@@ -109,118 +110,28 @@ export declare const zh: {
109
110
  readonly loginFailed: "登录失败";
110
111
  readonly requests: "次请求";
111
112
  readonly tokens: "tokens";
113
+ readonly accountPool: string;
114
+ readonly addAccount: string;
115
+ readonly accountCount: string;
116
+ readonly primaryAccount: string;
117
+ readonly activeAccount: string;
118
+ readonly setPrimary: string;
119
+ readonly deleteAccount: string;
120
+ readonly cooling: string;
121
+ readonly cooldownLeft: string;
122
+ readonly clearCooldown: string;
123
+ readonly needsRelogin: string;
124
+ readonly relogin: string;
125
+ readonly rotationStrategy: string;
126
+ readonly strategySequential: string;
127
+ readonly strategyRoundRobin: string;
128
+ readonly strategySticky: string;
129
+ readonly noAccounts: string;
130
+ readonly expires: string;
131
+ readonly lastUsed: string;
132
+ readonly accountId: string;
112
133
  };
113
- export declare const en: {
114
- readonly title: "Kimi Code";
115
- readonly pageDesc: "Sign in to the Kimi Code subscription and manage models, thinking level, context windows, and quota.";
116
- readonly account: "Account";
117
- readonly signedIn: "Signed in";
118
- readonly signedOut: "Not signed in";
119
- readonly nickname: "Nickname";
120
- readonly email: "Email";
121
- readonly plan: "Plan";
122
- readonly planUnknown: "—";
123
- readonly region: "Region";
124
- readonly regionMainland: "Mainland China (kimi.com)";
125
- readonly regionGlobal: "Global (kimi.ai)";
126
- readonly authenticatedAt: "Signed in at";
127
- readonly storage: "Credential storage";
128
- readonly storageNotice: "The OAuth credential is stored locally by the Host ($DSH_HOME/storages/kimi-code-credentials.json) and never reaches the browser. Access tokens refresh automatically.";
129
- readonly refreshRejected: "The refresh token was rejected — sign in again.";
130
- readonly signIn: "Sign in with device code";
131
- readonly signInAgain: "Sign in again";
132
- readonly signingIn: "Signing in...";
133
- readonly signOut: "Sign out";
134
- readonly cancelSignIn: "Cancel";
135
- readonly deviceCodeSection: "Device authorization";
136
- readonly deviceCodeHint: "Open the link below in a browser (the user code is pre-filled) and approve it with the same account.";
137
- readonly openSignInPage: "Open the sign-in page";
138
- readonly copyCode: "Copy user code";
139
- readonly copied: "Copied";
140
- readonly userCode: "User code";
141
- readonly codeExpires: "Expires at";
142
- readonly waitingAuthorization: "Waiting for browser authorization...";
143
- readonly requestingCode: "Requesting a device code...";
144
- readonly connection: "Connection";
145
- readonly provider: "Provider";
146
- readonly providerValue: "Kimi Code · kimi-code";
147
- readonly oauthHost: "OAuth host";
148
- readonly codingEndpoint: "Model endpoint";
149
- readonly connectionState: "Connection state";
150
- readonly connected: "Connected";
151
- readonly untested: "Untested";
152
- readonly testConnection: "Test connection";
153
- readonly testingConnection: "Testing...";
154
- readonly testSuccess: "Connection OK";
155
- readonly testFailed: "Connection failed: Kimi Code did not accept the stored credential";
156
- readonly routeOwned: "This plugin serves the model route";
157
- readonly routeConflict: "Another provider already owns the model route: {detail}. Remove the duplicate provider configuration in DSH settings and reload.";
158
- readonly modelsSection: "Models";
159
- readonly modelsHint: "Checked models appear in the DSH conversation model list; keep at least one.";
160
- readonly refreshCatalog: "Refresh catalog";
161
- readonly refreshingCatalog: "Refreshing...";
162
- readonly selectAll: "Select all";
163
- readonly unselectAll: "Deselect all";
164
- readonly wireAnthropic: "Anthropic";
165
- readonly wireOpenai: "OpenAI";
166
- readonly capVideo: "Video*";
167
- readonly capDynamicTools: "Dynamic tools";
168
- readonly capImageOnly: "Images";
169
- readonly capNone: "—";
170
- readonly capVideoFootnote: "* Video input is attached with the kimi_attach_video tool (an absolute local path or an http(s) URL); the paste/upload path still accepts images only.";
171
- readonly capabilitiesTitle: "Capabilities";
172
- readonly capColMedia: "Multimodal";
173
- readonly capColTools: "Dynamic tools";
174
- readonly capColNotes: "Notes";
175
- readonly capPlan: "Requires plan: {plan}";
176
- readonly speedRegular: "Regular";
177
- readonly speedHighspeed: "HighSpeed (~6x)";
178
- readonly quotaCost: "Quota cost";
179
- readonly minimumPlan: "Required plan";
180
- readonly enhanced: "Thinking";
181
- readonly defaultReasoningEffort: "Default thinking level";
182
- readonly defaultReasoningEffortHint: "Kimi Code accepts only low / high / max; none disables thinking. Switching the level invalidates the context cache, so keep it steady within a session.";
183
- readonly defaultEffortAuto: "Use the model default";
184
- readonly effortLow: "Low";
185
- readonly effortHigh: "High";
186
- readonly effortMax: "Max";
187
- readonly effortNone: "Thinking off";
188
- readonly contextWindowSection: "Model context window";
189
- readonly contextWindowHint: "Defaults to the catalog context length. k3 reaches 1M only on Allegretto and above, so it defaults to 256K; raise the override here after upgrading.";
190
- readonly contextWindowPlan: "Full context requires the {plan} plan";
191
- readonly save: "Save";
192
- readonly saved: "Saved";
193
- readonly saving: "Saving...";
194
- readonly cacheSection: "Cache & K3 tuning";
195
- readonly cacheDesc: "Kimi's prefix cache is automatic and content-hash based — there is no marker to set — so the cache-read ratio is the only evidence it is working.";
196
- readonly cacheEmpty: "No request in this process has reported usage yet.";
197
- readonly cacheHitRatio: "Cache hit ratio";
198
- readonly cacheCached: "Cached tokens";
199
- readonly cacheFresh: "Fresh tokens";
200
- readonly cacheOutput: "Output tokens";
201
- readonly cacheRequests: "Requests";
202
- readonly cacheHint: "Within one session: any change to the system prompt or the tool list invalidates the whole prefix cache, so keep the tool set stable and append new material at the tail for the best hit rate.";
203
- readonly preserveThinking: "Preserved Thinking";
204
- readonly preserveOn: "On (the official default): reasoning_content is retained across turns, which keeps multi-step tool use coherent — its tokens are billed as output.";
205
- readonly preserveOff: "Off: the service is not asked to return reasoning. Set DSH_KIMI_CODE_PRESERVE_THINKING=0 to disable.";
206
- readonly outputCap: "Output cap follows the context window, so long reasoning is not cut off at 32K";
207
- readonly quotaSection: "Usage & quota";
208
- readonly quotaDesc: "Read from the Kimi Code account endpoints; refreshes at most once every 60 seconds while visible.";
209
- readonly refreshQuota: "Refresh quota";
210
- readonly refreshingQuota: "Refreshing...";
211
- readonly quotaEmpty: "No quota data yet — use \"Refresh quota\" to retry.";
212
- readonly quotaPlan: "Current plan";
213
- readonly quotaWallet: "Booster wallet";
214
- readonly quotaWalletLimit: "Monthly cap";
215
- readonly quotaWalletUsed: "Used this month";
216
- readonly quotaUnlimited: "Unlimited";
217
- readonly updatedAt: "Updated at: {time}";
218
- readonly resetAt: "Reset: {time}";
219
- readonly loading: "Loading...";
220
- readonly loginFailed: "Sign-in failed";
221
- readonly requests: "requests";
222
- readonly tokens: "tokens";
223
- };
134
+ export declare const en: Record<keyof typeof zh, string>;
224
135
  export declare const dictionaries: {
225
136
  zh: {
226
137
  readonly title: "Kimi Code";
@@ -268,7 +179,8 @@ export declare const dictionaries: {
268
179
  readonly routeOwned: "模型路由由本插件提供";
269
180
  readonly routeConflict: "模型路由已被其他 Provider 占用:{detail}。请在 DSH 设置中移除重复的 Provider 配置后重试。";
270
181
  readonly modelsSection: "模型";
271
- readonly modelsHint: "勾选后模型才会出现在对话页的模型选择列表中;至少保留一个。";
182
+ readonly enableProvider: "启用此供应商";
183
+ readonly modelsHint: "勾选后模型才会出现在对话页的模型选择列表中;全部取消勾选或关闭上方开关可在列表中隐藏该供应商。";
272
184
  readonly refreshCatalog: "刷新模型目录";
273
185
  readonly refreshingCatalog: "刷新中...";
274
186
  readonly selectAll: "全选";
@@ -332,6 +244,26 @@ export declare const dictionaries: {
332
244
  readonly loginFailed: "登录失败";
333
245
  readonly requests: "次请求";
334
246
  readonly tokens: "tokens";
247
+ readonly accountPool: string;
248
+ readonly addAccount: string;
249
+ readonly accountCount: string;
250
+ readonly primaryAccount: string;
251
+ readonly activeAccount: string;
252
+ readonly setPrimary: string;
253
+ readonly deleteAccount: string;
254
+ readonly cooling: string;
255
+ readonly cooldownLeft: string;
256
+ readonly clearCooldown: string;
257
+ readonly needsRelogin: string;
258
+ readonly relogin: string;
259
+ readonly rotationStrategy: string;
260
+ readonly strategySequential: string;
261
+ readonly strategyRoundRobin: string;
262
+ readonly strategySticky: string;
263
+ readonly noAccounts: string;
264
+ readonly expires: string;
265
+ readonly lastUsed: string;
266
+ readonly accountId: string;
335
267
  };
336
268
  'zh-CN': {
337
269
  readonly title: "Kimi Code";
@@ -379,7 +311,8 @@ export declare const dictionaries: {
379
311
  readonly routeOwned: "模型路由由本插件提供";
380
312
  readonly routeConflict: "模型路由已被其他 Provider 占用:{detail}。请在 DSH 设置中移除重复的 Provider 配置后重试。";
381
313
  readonly modelsSection: "模型";
382
- readonly modelsHint: "勾选后模型才会出现在对话页的模型选择列表中;至少保留一个。";
314
+ readonly enableProvider: "启用此供应商";
315
+ readonly modelsHint: "勾选后模型才会出现在对话页的模型选择列表中;全部取消勾选或关闭上方开关可在列表中隐藏该供应商。";
383
316
  readonly refreshCatalog: "刷新模型目录";
384
317
  readonly refreshingCatalog: "刷新中...";
385
318
  readonly selectAll: "全选";
@@ -443,229 +376,29 @@ export declare const dictionaries: {
443
376
  readonly loginFailed: "登录失败";
444
377
  readonly requests: "次请求";
445
378
  readonly tokens: "tokens";
379
+ readonly accountPool: string;
380
+ readonly addAccount: string;
381
+ readonly accountCount: string;
382
+ readonly primaryAccount: string;
383
+ readonly activeAccount: string;
384
+ readonly setPrimary: string;
385
+ readonly deleteAccount: string;
386
+ readonly cooling: string;
387
+ readonly cooldownLeft: string;
388
+ readonly clearCooldown: string;
389
+ readonly needsRelogin: string;
390
+ readonly relogin: string;
391
+ readonly rotationStrategy: string;
392
+ readonly strategySequential: string;
393
+ readonly strategyRoundRobin: string;
394
+ readonly strategySticky: string;
395
+ readonly noAccounts: string;
396
+ readonly expires: string;
397
+ readonly lastUsed: string;
398
+ readonly accountId: string;
446
399
  };
447
- en: {
448
- readonly title: "Kimi Code";
449
- readonly pageDesc: "Sign in to the Kimi Code subscription and manage models, thinking level, context windows, and quota.";
450
- readonly account: "Account";
451
- readonly signedIn: "Signed in";
452
- readonly signedOut: "Not signed in";
453
- readonly nickname: "Nickname";
454
- readonly email: "Email";
455
- readonly plan: "Plan";
456
- readonly planUnknown: "—";
457
- readonly region: "Region";
458
- readonly regionMainland: "Mainland China (kimi.com)";
459
- readonly regionGlobal: "Global (kimi.ai)";
460
- readonly authenticatedAt: "Signed in at";
461
- readonly storage: "Credential storage";
462
- readonly storageNotice: "The OAuth credential is stored locally by the Host ($DSH_HOME/storages/kimi-code-credentials.json) and never reaches the browser. Access tokens refresh automatically.";
463
- readonly refreshRejected: "The refresh token was rejected — sign in again.";
464
- readonly signIn: "Sign in with device code";
465
- readonly signInAgain: "Sign in again";
466
- readonly signingIn: "Signing in...";
467
- readonly signOut: "Sign out";
468
- readonly cancelSignIn: "Cancel";
469
- readonly deviceCodeSection: "Device authorization";
470
- readonly deviceCodeHint: "Open the link below in a browser (the user code is pre-filled) and approve it with the same account.";
471
- readonly openSignInPage: "Open the sign-in page";
472
- readonly copyCode: "Copy user code";
473
- readonly copied: "Copied";
474
- readonly userCode: "User code";
475
- readonly codeExpires: "Expires at";
476
- readonly waitingAuthorization: "Waiting for browser authorization...";
477
- readonly requestingCode: "Requesting a device code...";
478
- readonly connection: "Connection";
479
- readonly provider: "Provider";
480
- readonly providerValue: "Kimi Code · kimi-code";
481
- readonly oauthHost: "OAuth host";
482
- readonly codingEndpoint: "Model endpoint";
483
- readonly connectionState: "Connection state";
484
- readonly connected: "Connected";
485
- readonly untested: "Untested";
486
- readonly testConnection: "Test connection";
487
- readonly testingConnection: "Testing...";
488
- readonly testSuccess: "Connection OK";
489
- readonly testFailed: "Connection failed: Kimi Code did not accept the stored credential";
490
- readonly routeOwned: "This plugin serves the model route";
491
- readonly routeConflict: "Another provider already owns the model route: {detail}. Remove the duplicate provider configuration in DSH settings and reload.";
492
- readonly modelsSection: "Models";
493
- readonly modelsHint: "Checked models appear in the DSH conversation model list; keep at least one.";
494
- readonly refreshCatalog: "Refresh catalog";
495
- readonly refreshingCatalog: "Refreshing...";
496
- readonly selectAll: "Select all";
497
- readonly unselectAll: "Deselect all";
498
- readonly wireAnthropic: "Anthropic";
499
- readonly wireOpenai: "OpenAI";
500
- readonly capVideo: "Video*";
501
- readonly capDynamicTools: "Dynamic tools";
502
- readonly capImageOnly: "Images";
503
- readonly capNone: "—";
504
- readonly capVideoFootnote: "* Video input is attached with the kimi_attach_video tool (an absolute local path or an http(s) URL); the paste/upload path still accepts images only.";
505
- readonly capabilitiesTitle: "Capabilities";
506
- readonly capColMedia: "Multimodal";
507
- readonly capColTools: "Dynamic tools";
508
- readonly capColNotes: "Notes";
509
- readonly capPlan: "Requires plan: {plan}";
510
- readonly speedRegular: "Regular";
511
- readonly speedHighspeed: "HighSpeed (~6x)";
512
- readonly quotaCost: "Quota cost";
513
- readonly minimumPlan: "Required plan";
514
- readonly enhanced: "Thinking";
515
- readonly defaultReasoningEffort: "Default thinking level";
516
- readonly defaultReasoningEffortHint: "Kimi Code accepts only low / high / max; none disables thinking. Switching the level invalidates the context cache, so keep it steady within a session.";
517
- readonly defaultEffortAuto: "Use the model default";
518
- readonly effortLow: "Low";
519
- readonly effortHigh: "High";
520
- readonly effortMax: "Max";
521
- readonly effortNone: "Thinking off";
522
- readonly contextWindowSection: "Model context window";
523
- readonly contextWindowHint: "Defaults to the catalog context length. k3 reaches 1M only on Allegretto and above, so it defaults to 256K; raise the override here after upgrading.";
524
- readonly contextWindowPlan: "Full context requires the {plan} plan";
525
- readonly save: "Save";
526
- readonly saved: "Saved";
527
- readonly saving: "Saving...";
528
- readonly cacheSection: "Cache & K3 tuning";
529
- readonly cacheDesc: "Kimi's prefix cache is automatic and content-hash based — there is no marker to set — so the cache-read ratio is the only evidence it is working.";
530
- readonly cacheEmpty: "No request in this process has reported usage yet.";
531
- readonly cacheHitRatio: "Cache hit ratio";
532
- readonly cacheCached: "Cached tokens";
533
- readonly cacheFresh: "Fresh tokens";
534
- readonly cacheOutput: "Output tokens";
535
- readonly cacheRequests: "Requests";
536
- readonly cacheHint: "Within one session: any change to the system prompt or the tool list invalidates the whole prefix cache, so keep the tool set stable and append new material at the tail for the best hit rate.";
537
- readonly preserveThinking: "Preserved Thinking";
538
- readonly preserveOn: "On (the official default): reasoning_content is retained across turns, which keeps multi-step tool use coherent — its tokens are billed as output.";
539
- readonly preserveOff: "Off: the service is not asked to return reasoning. Set DSH_KIMI_CODE_PRESERVE_THINKING=0 to disable.";
540
- readonly outputCap: "Output cap follows the context window, so long reasoning is not cut off at 32K";
541
- readonly quotaSection: "Usage & quota";
542
- readonly quotaDesc: "Read from the Kimi Code account endpoints; refreshes at most once every 60 seconds while visible.";
543
- readonly refreshQuota: "Refresh quota";
544
- readonly refreshingQuota: "Refreshing...";
545
- readonly quotaEmpty: "No quota data yet — use \"Refresh quota\" to retry.";
546
- readonly quotaPlan: "Current plan";
547
- readonly quotaWallet: "Booster wallet";
548
- readonly quotaWalletLimit: "Monthly cap";
549
- readonly quotaWalletUsed: "Used this month";
550
- readonly quotaUnlimited: "Unlimited";
551
- readonly updatedAt: "Updated at: {time}";
552
- readonly resetAt: "Reset: {time}";
553
- readonly loading: "Loading...";
554
- readonly loginFailed: "Sign-in failed";
555
- readonly requests: "requests";
556
- readonly tokens: "tokens";
557
- };
558
- 'en-US': {
559
- readonly title: "Kimi Code";
560
- readonly pageDesc: "Sign in to the Kimi Code subscription and manage models, thinking level, context windows, and quota.";
561
- readonly account: "Account";
562
- readonly signedIn: "Signed in";
563
- readonly signedOut: "Not signed in";
564
- readonly nickname: "Nickname";
565
- readonly email: "Email";
566
- readonly plan: "Plan";
567
- readonly planUnknown: "—";
568
- readonly region: "Region";
569
- readonly regionMainland: "Mainland China (kimi.com)";
570
- readonly regionGlobal: "Global (kimi.ai)";
571
- readonly authenticatedAt: "Signed in at";
572
- readonly storage: "Credential storage";
573
- readonly storageNotice: "The OAuth credential is stored locally by the Host ($DSH_HOME/storages/kimi-code-credentials.json) and never reaches the browser. Access tokens refresh automatically.";
574
- readonly refreshRejected: "The refresh token was rejected — sign in again.";
575
- readonly signIn: "Sign in with device code";
576
- readonly signInAgain: "Sign in again";
577
- readonly signingIn: "Signing in...";
578
- readonly signOut: "Sign out";
579
- readonly cancelSignIn: "Cancel";
580
- readonly deviceCodeSection: "Device authorization";
581
- readonly deviceCodeHint: "Open the link below in a browser (the user code is pre-filled) and approve it with the same account.";
582
- readonly openSignInPage: "Open the sign-in page";
583
- readonly copyCode: "Copy user code";
584
- readonly copied: "Copied";
585
- readonly userCode: "User code";
586
- readonly codeExpires: "Expires at";
587
- readonly waitingAuthorization: "Waiting for browser authorization...";
588
- readonly requestingCode: "Requesting a device code...";
589
- readonly connection: "Connection";
590
- readonly provider: "Provider";
591
- readonly providerValue: "Kimi Code · kimi-code";
592
- readonly oauthHost: "OAuth host";
593
- readonly codingEndpoint: "Model endpoint";
594
- readonly connectionState: "Connection state";
595
- readonly connected: "Connected";
596
- readonly untested: "Untested";
597
- readonly testConnection: "Test connection";
598
- readonly testingConnection: "Testing...";
599
- readonly testSuccess: "Connection OK";
600
- readonly testFailed: "Connection failed: Kimi Code did not accept the stored credential";
601
- readonly routeOwned: "This plugin serves the model route";
602
- readonly routeConflict: "Another provider already owns the model route: {detail}. Remove the duplicate provider configuration in DSH settings and reload.";
603
- readonly modelsSection: "Models";
604
- readonly modelsHint: "Checked models appear in the DSH conversation model list; keep at least one.";
605
- readonly refreshCatalog: "Refresh catalog";
606
- readonly refreshingCatalog: "Refreshing...";
607
- readonly selectAll: "Select all";
608
- readonly unselectAll: "Deselect all";
609
- readonly wireAnthropic: "Anthropic";
610
- readonly wireOpenai: "OpenAI";
611
- readonly capVideo: "Video*";
612
- readonly capDynamicTools: "Dynamic tools";
613
- readonly capImageOnly: "Images";
614
- readonly capNone: "—";
615
- readonly capVideoFootnote: "* Video input is attached with the kimi_attach_video tool (an absolute local path or an http(s) URL); the paste/upload path still accepts images only.";
616
- readonly capabilitiesTitle: "Capabilities";
617
- readonly capColMedia: "Multimodal";
618
- readonly capColTools: "Dynamic tools";
619
- readonly capColNotes: "Notes";
620
- readonly capPlan: "Requires plan: {plan}";
621
- readonly speedRegular: "Regular";
622
- readonly speedHighspeed: "HighSpeed (~6x)";
623
- readonly quotaCost: "Quota cost";
624
- readonly minimumPlan: "Required plan";
625
- readonly enhanced: "Thinking";
626
- readonly defaultReasoningEffort: "Default thinking level";
627
- readonly defaultReasoningEffortHint: "Kimi Code accepts only low / high / max; none disables thinking. Switching the level invalidates the context cache, so keep it steady within a session.";
628
- readonly defaultEffortAuto: "Use the model default";
629
- readonly effortLow: "Low";
630
- readonly effortHigh: "High";
631
- readonly effortMax: "Max";
632
- readonly effortNone: "Thinking off";
633
- readonly contextWindowSection: "Model context window";
634
- readonly contextWindowHint: "Defaults to the catalog context length. k3 reaches 1M only on Allegretto and above, so it defaults to 256K; raise the override here after upgrading.";
635
- readonly contextWindowPlan: "Full context requires the {plan} plan";
636
- readonly save: "Save";
637
- readonly saved: "Saved";
638
- readonly saving: "Saving...";
639
- readonly cacheSection: "Cache & K3 tuning";
640
- readonly cacheDesc: "Kimi's prefix cache is automatic and content-hash based — there is no marker to set — so the cache-read ratio is the only evidence it is working.";
641
- readonly cacheEmpty: "No request in this process has reported usage yet.";
642
- readonly cacheHitRatio: "Cache hit ratio";
643
- readonly cacheCached: "Cached tokens";
644
- readonly cacheFresh: "Fresh tokens";
645
- readonly cacheOutput: "Output tokens";
646
- readonly cacheRequests: "Requests";
647
- readonly cacheHint: "Within one session: any change to the system prompt or the tool list invalidates the whole prefix cache, so keep the tool set stable and append new material at the tail for the best hit rate.";
648
- readonly preserveThinking: "Preserved Thinking";
649
- readonly preserveOn: "On (the official default): reasoning_content is retained across turns, which keeps multi-step tool use coherent — its tokens are billed as output.";
650
- readonly preserveOff: "Off: the service is not asked to return reasoning. Set DSH_KIMI_CODE_PRESERVE_THINKING=0 to disable.";
651
- readonly outputCap: "Output cap follows the context window, so long reasoning is not cut off at 32K";
652
- readonly quotaSection: "Usage & quota";
653
- readonly quotaDesc: "Read from the Kimi Code account endpoints; refreshes at most once every 60 seconds while visible.";
654
- readonly refreshQuota: "Refresh quota";
655
- readonly refreshingQuota: "Refreshing...";
656
- readonly quotaEmpty: "No quota data yet — use \"Refresh quota\" to retry.";
657
- readonly quotaPlan: "Current plan";
658
- readonly quotaWallet: "Booster wallet";
659
- readonly quotaWalletLimit: "Monthly cap";
660
- readonly quotaWalletUsed: "Used this month";
661
- readonly quotaUnlimited: "Unlimited";
662
- readonly updatedAt: "Updated at: {time}";
663
- readonly resetAt: "Reset: {time}";
664
- readonly loading: "Loading...";
665
- readonly loginFailed: "Sign-in failed";
666
- readonly requests: "requests";
667
- readonly tokens: "tokens";
668
- };
400
+ en: Record<"tokens" | "title" | "pageDesc" | "account" | "signedIn" | "signedOut" | "accountPool" | "addAccount" | "primaryAccount" | "activeAccount" | "setPrimary" | "deleteAccount" | "cooling" | "clearCooldown" | "rotationStrategy" | "strategySequential" | "strategyRoundRobin" | "strategySticky" | "noAccounts" | "plan" | "accountId" | "expires" | "storage" | "storageNotice" | "signInAgain" | "signOut" | "signIn" | "signingIn" | "connection" | "provider" | "providerValue" | "connectionState" | "connected" | "untested" | "enableProvider" | "modelsHint" | "selectAll" | "unselectAll" | "enhanced" | "defaultReasoningEffort" | "defaultReasoningEffortHint" | "defaultEffortAuto" | "contextWindowSection" | "contextWindowHint" | "save" | "saved" | "saving" | "quotaSection" | "quotaDesc" | "refreshQuota" | "refreshingQuota" | "quotaEmpty" | "updatedAt" | "loading" | "loginFailed" | "planUnknown" | "authenticatedAt" | "cancelSignIn" | "openSignInPage" | "testConnection" | "testingConnection" | "routeOwned" | "routeConflict" | "modelsSection" | "refreshCatalog" | "refreshingCatalog" | "wireAnthropic" | "wireOpenai" | "quotaUnlimited" | "accountCount" | "cooldownLeft" | "needsRelogin" | "relogin" | "email" | "lastUsed" | "nickname" | "region" | "regionMainland" | "regionGlobal" | "refreshRejected" | "deviceCodeSection" | "deviceCodeHint" | "copyCode" | "copied" | "userCode" | "codeExpires" | "waitingAuthorization" | "requestingCode" | "oauthHost" | "codingEndpoint" | "testSuccess" | "testFailed" | "capVideo" | "capDynamicTools" | "capImageOnly" | "capNone" | "capVideoFootnote" | "capabilitiesTitle" | "capColMedia" | "capColTools" | "capColNotes" | "capPlan" | "speedRegular" | "speedHighspeed" | "quotaCost" | "minimumPlan" | "effortLow" | "effortHigh" | "effortMax" | "effortNone" | "contextWindowPlan" | "cacheSection" | "cacheDesc" | "cacheEmpty" | "cacheHitRatio" | "cacheCached" | "cacheFresh" | "cacheOutput" | "cacheRequests" | "cacheHint" | "preserveThinking" | "preserveOn" | "preserveOff" | "outputCap" | "quotaPlan" | "quotaWallet" | "quotaWalletLimit" | "quotaWalletUsed" | "resetAt" | "requests", string>;
401
+ 'en-US': Record<"tokens" | "title" | "pageDesc" | "account" | "signedIn" | "signedOut" | "accountPool" | "addAccount" | "primaryAccount" | "activeAccount" | "setPrimary" | "deleteAccount" | "cooling" | "clearCooldown" | "rotationStrategy" | "strategySequential" | "strategyRoundRobin" | "strategySticky" | "noAccounts" | "plan" | "accountId" | "expires" | "storage" | "storageNotice" | "signInAgain" | "signOut" | "signIn" | "signingIn" | "connection" | "provider" | "providerValue" | "connectionState" | "connected" | "untested" | "enableProvider" | "modelsHint" | "selectAll" | "unselectAll" | "enhanced" | "defaultReasoningEffort" | "defaultReasoningEffortHint" | "defaultEffortAuto" | "contextWindowSection" | "contextWindowHint" | "save" | "saved" | "saving" | "quotaSection" | "quotaDesc" | "refreshQuota" | "refreshingQuota" | "quotaEmpty" | "updatedAt" | "loading" | "loginFailed" | "planUnknown" | "authenticatedAt" | "cancelSignIn" | "openSignInPage" | "testConnection" | "testingConnection" | "routeOwned" | "routeConflict" | "modelsSection" | "refreshCatalog" | "refreshingCatalog" | "wireAnthropic" | "wireOpenai" | "quotaUnlimited" | "accountCount" | "cooldownLeft" | "needsRelogin" | "relogin" | "email" | "lastUsed" | "nickname" | "region" | "regionMainland" | "regionGlobal" | "refreshRejected" | "deviceCodeSection" | "deviceCodeHint" | "copyCode" | "copied" | "userCode" | "codeExpires" | "waitingAuthorization" | "requestingCode" | "oauthHost" | "codingEndpoint" | "testSuccess" | "testFailed" | "capVideo" | "capDynamicTools" | "capImageOnly" | "capNone" | "capVideoFootnote" | "capabilitiesTitle" | "capColMedia" | "capColTools" | "capColNotes" | "capPlan" | "speedRegular" | "speedHighspeed" | "quotaCost" | "minimumPlan" | "effortLow" | "effortHigh" | "effortMax" | "effortNone" | "contextWindowPlan" | "cacheSection" | "cacheDesc" | "cacheEmpty" | "cacheHitRatio" | "cacheCached" | "cacheFresh" | "cacheOutput" | "cacheRequests" | "cacheHint" | "preserveThinking" | "preserveOn" | "preserveOff" | "outputCap" | "quotaPlan" | "quotaWallet" | "quotaWalletLimit" | "quotaWalletUsed" | "resetAt" | "requests", string>;
669
402
  };
670
403
  export type KimiCodeLocaleKey = keyof typeof zh;
671
404
  //# sourceMappingURL=locales.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"locales.d.ts","sourceRoot":"","sources":["../../../../src/client/kimi-code/locales.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,YAAY,kBAAkB,CAAA;AAE3C,eAAO,MAAM,EAAE;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CA8GL,CAAA;AAEV,eAAO,MAAM,EAAE;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CA8GL,CAAA;AAEV,eAAO,MAAM,YAAY;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAKxB,CAAA;AAED,MAAM,MAAM,iBAAiB,GAAG,MAAM,OAAO,EAAE,CAAA"}
@@ -37,8 +37,11 @@ export declare const zh: {
37
37
  readonly testConnection: "测试连接";
38
38
  readonly testing: "测试中…";
39
39
  readonly latency: "最近延迟";
40
+ readonly enableProvider: "启用此供应商";
41
+ readonly selectAll: "全选";
42
+ readonly unselectAll: "全不选";
40
43
  readonly models: "可用模型";
41
- readonly modelsHint: "勾选后模型才会显示在对话页的模型选择列表中;至少保留一个。";
44
+ readonly modelsHint: "勾选后模型才会显示在对话页的模型选择列表中;全部取消勾选或关闭上方开关可在列表中隐藏该供应商。";
42
45
  readonly proxySettings: "网络代理";
43
46
  readonly proxyMode: "代理模式";
44
47
  readonly proxyModeHint: "GPT 与 Antigravity(Gemini)共用此代理设置;支持自动读取系统代理,修改后对后续请求生效。";
@@ -123,6 +126,26 @@ export declare const zh: {
123
126
  readonly imagePreviewOpenOriginal: "打开原图";
124
127
  readonly retry: "重试";
125
128
  readonly unknown: "未知";
129
+ readonly accountPool: string;
130
+ readonly addAccount: string;
131
+ readonly accountCount: string;
132
+ readonly primaryAccount: string;
133
+ readonly activeAccount: string;
134
+ readonly setPrimary: string;
135
+ readonly deleteAccount: string;
136
+ readonly cooling: string;
137
+ readonly cooldownLeft: string;
138
+ readonly clearCooldown: string;
139
+ readonly needsRelogin: string;
140
+ readonly relogin: string;
141
+ readonly rotationStrategy: string;
142
+ readonly strategySequential: string;
143
+ readonly strategyRoundRobin: string;
144
+ readonly strategySticky: string;
145
+ readonly noAccounts: string;
146
+ readonly storageNotice: string;
147
+ readonly email: string;
148
+ readonly lastUsed: string;
126
149
  };
127
150
  export declare const en: Record<keyof typeof zh, string>;
128
151
  export type LocaleKey = keyof typeof zh;
@@ -165,8 +188,11 @@ export declare const dictionaries: {
165
188
  readonly testConnection: "测试连接";
166
189
  readonly testing: "测试中…";
167
190
  readonly latency: "最近延迟";
191
+ readonly enableProvider: "启用此供应商";
192
+ readonly selectAll: "全选";
193
+ readonly unselectAll: "全不选";
168
194
  readonly models: "可用模型";
169
- readonly modelsHint: "勾选后模型才会显示在对话页的模型选择列表中;至少保留一个。";
195
+ readonly modelsHint: "勾选后模型才会显示在对话页的模型选择列表中;全部取消勾选或关闭上方开关可在列表中隐藏该供应商。";
170
196
  readonly proxySettings: "网络代理";
171
197
  readonly proxyMode: "代理模式";
172
198
  readonly proxyModeHint: "GPT 与 Antigravity(Gemini)共用此代理设置;支持自动读取系统代理,修改后对后续请求生效。";
@@ -251,7 +277,27 @@ export declare const dictionaries: {
251
277
  readonly imagePreviewOpenOriginal: "打开原图";
252
278
  readonly retry: "重试";
253
279
  readonly unknown: "未知";
280
+ readonly accountPool: string;
281
+ readonly addAccount: string;
282
+ readonly accountCount: string;
283
+ readonly primaryAccount: string;
284
+ readonly activeAccount: string;
285
+ readonly setPrimary: string;
286
+ readonly deleteAccount: string;
287
+ readonly cooling: string;
288
+ readonly cooldownLeft: string;
289
+ readonly clearCooldown: string;
290
+ readonly needsRelogin: string;
291
+ readonly relogin: string;
292
+ readonly rotationStrategy: string;
293
+ readonly strategySequential: string;
294
+ readonly strategyRoundRobin: string;
295
+ readonly strategySticky: string;
296
+ readonly noAccounts: string;
297
+ readonly storageNotice: string;
298
+ readonly email: string;
299
+ readonly lastUsed: string;
254
300
  };
255
- en: Record<"tokens" | "title" | "hubTitle" | "intro" | "account" | "signedOut" | "signedIn" | "plan" | "accountId" | "expires" | "storage" | "storageWindows" | "storageMacKeychain" | "storageLinuxFile" | "storageMemory" | "storageUnavailable" | "securityWindows" | "securityMacKeychain" | "securityLinuxFile" | "securityMemory" | "securityUnavailable" | "signIn" | "signInAgain" | "cancel" | "signOut" | "refreshToken" | "pending" | "popupBlocked" | "continueLogin" | "loading" | "connection" | "provider" | "connectionState" | "connected" | "untested" | "testConnection" | "testing" | "latency" | "models" | "modelsHint" | "proxySettings" | "proxyMode" | "proxyModeHint" | "proxyModeAuto" | "proxyModeCustom" | "proxyModeDirect" | "customProxyUrl" | "customProxyUrlHint" | "customProxyUrlPlaceholder" | "saveProxyUrl" | "proxyDetected" | "proxyDetectedEffective" | "proxyNoneDetected" | "proxyDirectHint" | "enhancements" | "fastMode" | "fastModeHint" | "outputVerbosity" | "outputVerbosityHint" | "verbosityLow" | "verbosityMedium" | "verbosityHigh" | "reasoningSummary" | "reasoningSummaryHint" | "summaryAuto" | "summaryConcise" | "summaryDetailed" | "summaryNone" | "searchProvider" | "searchProviderHint" | "searchProviderDsh" | "searchProviderCodex" | "providerDefault" | "contextWindows" | "contextWindowsHint" | "contextWindow" | "contextWindowInvalid" | "saveContextWindow" | "save" | "quickQuota" | "quickQuotaHint" | "quota" | "quotaIntro" | "refreshQuota" | "refreshing" | "noQuota" | "quotaSignedOut" | "stale" | "updated" | "primary" | "secondary" | "limitWindow" | "used" | "remaining" | "available" | "unavailable" | "unlimited" | "credits" | "monthlySpend" | "resetCredits" | "resetCreditExpires" | "useResetCredit" | "usingResetCredit" | "useResetCreditConfirm" | "resetCreditUsed" | "spendControlReached" | "limit" | "exhausted" | "resets" | "quickQuotaLabel" | "quickQuotaLoading" | "imageToolRunning" | "imageToolDone" | "imageToolFailed" | "image" | "openImage" | "openNamedImage" | "imageLoading" | "imageLoadFailed" | "imagePreviewClose" | "imagePreviewOpenOriginal" | "retry" | "unknown", string>;
301
+ en: Record<"accountId" | "relogin" | "pending" | "tokens" | "title" | "hubTitle" | "intro" | "account" | "signedOut" | "signedIn" | "plan" | "expires" | "storage" | "storageWindows" | "storageMacKeychain" | "storageLinuxFile" | "storageMemory" | "storageUnavailable" | "securityWindows" | "securityMacKeychain" | "securityLinuxFile" | "securityMemory" | "securityUnavailable" | "signIn" | "signInAgain" | "cancel" | "signOut" | "refreshToken" | "popupBlocked" | "continueLogin" | "loading" | "connection" | "provider" | "connectionState" | "connected" | "untested" | "testConnection" | "testing" | "latency" | "enableProvider" | "selectAll" | "unselectAll" | "models" | "modelsHint" | "proxySettings" | "proxyMode" | "proxyModeHint" | "proxyModeAuto" | "proxyModeCustom" | "proxyModeDirect" | "customProxyUrl" | "customProxyUrlHint" | "customProxyUrlPlaceholder" | "saveProxyUrl" | "proxyDetected" | "proxyDetectedEffective" | "proxyNoneDetected" | "proxyDirectHint" | "enhancements" | "fastMode" | "fastModeHint" | "outputVerbosity" | "outputVerbosityHint" | "verbosityLow" | "verbosityMedium" | "verbosityHigh" | "reasoningSummary" | "reasoningSummaryHint" | "summaryAuto" | "summaryConcise" | "summaryDetailed" | "summaryNone" | "searchProvider" | "searchProviderHint" | "searchProviderDsh" | "searchProviderCodex" | "providerDefault" | "contextWindows" | "contextWindowsHint" | "contextWindow" | "contextWindowInvalid" | "saveContextWindow" | "save" | "quickQuota" | "quickQuotaHint" | "quota" | "quotaIntro" | "refreshQuota" | "refreshing" | "noQuota" | "quotaSignedOut" | "stale" | "updated" | "primary" | "secondary" | "limitWindow" | "used" | "remaining" | "available" | "unavailable" | "unlimited" | "credits" | "monthlySpend" | "resetCredits" | "resetCreditExpires" | "useResetCredit" | "usingResetCredit" | "useResetCreditConfirm" | "resetCreditUsed" | "spendControlReached" | "limit" | "exhausted" | "resets" | "quickQuotaLabel" | "quickQuotaLoading" | "imageToolRunning" | "imageToolDone" | "imageToolFailed" | "image" | "openImage" | "openNamedImage" | "imageLoading" | "imageLoadFailed" | "imagePreviewClose" | "imagePreviewOpenOriginal" | "retry" | "unknown" | "accountPool" | "addAccount" | "accountCount" | "primaryAccount" | "activeAccount" | "setPrimary" | "deleteAccount" | "cooling" | "cooldownLeft" | "clearCooldown" | "needsRelogin" | "rotationStrategy" | "strategySequential" | "strategyRoundRobin" | "strategySticky" | "noAccounts" | "storageNotice" | "email" | "lastUsed", string>;
256
302
  };
257
303
  //# sourceMappingURL=locales.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"locales.d.ts","sourceRoot":"","sources":["../../../src/client/locales.ts"],"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;;;;;;;;;;;CAAa,CAAA"}
@@ -0,0 +1,60 @@
1
+ import type { CredentialStore } from '../token-store.ts';
2
+ import { FileCredentialStore, type AntigravityCredentials } from './token-store.ts';
3
+ import type { AntigravityAccountSummaryDto, AccountRotationStrategy } from '../../shared/antigravity-contracts.ts';
4
+ export interface AntigravityPoolAccount {
5
+ id: string;
6
+ alias: string;
7
+ email?: string;
8
+ projectId?: string;
9
+ planLabel?: string;
10
+ credentials: AntigravityCredentials;
11
+ addedAt: number;
12
+ lastUsedAt?: number;
13
+ cooldownUntil?: number;
14
+ cooldownReason?: string;
15
+ isPrimary?: boolean;
16
+ }
17
+ export interface AntigravityPoolData {
18
+ version: 1;
19
+ activeAccountId?: string;
20
+ rotationStrategy: AccountRotationStrategy;
21
+ accounts: AntigravityPoolAccount[];
22
+ }
23
+ export declare function poolPath(): string;
24
+ export declare function parseAntigravityPoolData(value: unknown): AntigravityPoolData;
25
+ /**
26
+ * Antigravity's account pool.
27
+ *
28
+ * The storage, eligibility, rotation and cooldown rules live in the shared
29
+ * {@link AccountPoolCore}; this facade keeps the provider-shaped API the routes
30
+ * and the adapter were written against, including the credential projection
31
+ * (`token` / `projectId`) that predates the shared core.
32
+ */
33
+ export declare class AccountPoolStore {
34
+ private readonly core;
35
+ private readonly legacyStore;
36
+ constructor(filePath?: string, backend?: CredentialStore<AntigravityPoolData>, legacyStore?: FileCredentialStore);
37
+ /** Human description of where this pool's credentials live. */
38
+ path(): string;
39
+ read(): Promise<AntigravityPoolData>;
40
+ write(data: AntigravityPoolData): Promise<void>;
41
+ listAccounts(): Promise<AntigravityAccountSummaryDto[]>;
42
+ addAccount(credentials: AntigravityCredentials, alias?: string): Promise<AntigravityPoolAccount>;
43
+ setPrimary(accountId: string): Promise<void>;
44
+ setAlias(accountId: string, alias: string): Promise<void>;
45
+ deleteAccount(accountId: string): Promise<void>;
46
+ setStrategy(strategy: AccountRotationStrategy): Promise<void>;
47
+ markCooldown(accountId: string, durationMs: number, reason: string): Promise<void>;
48
+ clearCooldown(accountId: string): Promise<void>;
49
+ hasAnotherAvailableAccount(triedAccountIds: ReadonlySet<string>): Promise<boolean>;
50
+ /**
51
+ * Pick the account for the next request, with the credential projection the
52
+ * Antigravity adapter consumes.
53
+ */
54
+ getEffectiveAccount(excludeIds?: ReadonlySet<string>, fetchFn?: typeof fetch): Promise<{
55
+ account: AntigravityPoolAccount;
56
+ token: string;
57
+ projectId?: string;
58
+ }>;
59
+ }
60
+ //# sourceMappingURL=account-pool.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"account-pool.d.ts","sourceRoot":"","sources":["../../../../src/host/antigravity/account-pool.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,mBAAmB,CAAA;AAMxD,OAAO,EACL,mBAAmB,EAEnB,KAAK,sBAAsB,EAC5B,MAAM,kBAAkB,CAAA;AAEzB,OAAO,KAAK,EACV,4BAA4B,EAC5B,uBAAuB,EACxB,MAAM,uCAAuC,CAAA;AAE9C,MAAM,WAAW,sBAAsB;IACrC,EAAE,EAAE,MAAM,CAAA;IACV,KAAK,EAAE,MAAM,CAAA;IACb,KAAK,CAAC,EAAE,MAAM,CAAA;IACd,SAAS,CAAC,EAAE,MAAM,CAAA;IAClB,SAAS,CAAC,EAAE,MAAM,CAAA;IAClB,WAAW,EAAE,sBAAsB,CAAA;IACnC,OAAO,EAAE,MAAM,CAAA;IACf,UAAU,CAAC,EAAE,MAAM,CAAA;IACnB,aAAa,CAAC,EAAE,MAAM,CAAA;IACtB,cAAc,CAAC,EAAE,MAAM,CAAA;IACvB,SAAS,CAAC,EAAE,OAAO,CAAA;CACpB;AAED,MAAM,WAAW,mBAAmB;IAClC,OAAO,EAAE,CAAC,CAAA;IACV,eAAe,CAAC,EAAE,MAAM,CAAA;IACxB,gBAAgB,EAAE,uBAAuB,CAAA;IACzC,QAAQ,EAAE,sBAAsB,EAAE,CAAA;CACnC;AAED,wBAAgB,QAAQ,IAAI,MAAM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