@roo-code/types 1.12.0 → 1.14.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/src/index.d.ts DELETED
@@ -1,1211 +0,0 @@
1
- import { EventEmitter } from 'events';
2
- import { Socket } from 'node:net';
3
-
4
- type GlobalSettings = {
5
- currentApiConfigName?: string | undefined;
6
- listApiConfigMeta?: {
7
- id: string;
8
- name: string;
9
- apiProvider?: ("anthropic" | "glama" | "openrouter" | "bedrock" | "vertex" | "openai" | "ollama" | "vscode-lm" | "lmstudio" | "gemini" | "openai-native" | "mistral" | "deepseek" | "unbound" | "requesty" | "human-relay" | "fake-ai" | "xai" | "groq" | "chutes" | "litellm") | undefined;
10
- }[] | undefined;
11
- pinnedApiConfigs?: {
12
- [x: string]: boolean;
13
- } | undefined;
14
- lastShownAnnouncementId?: string | undefined;
15
- customInstructions?: string | undefined;
16
- taskHistory?: {
17
- id: string;
18
- number: number;
19
- ts: number;
20
- task: string;
21
- tokensIn: number;
22
- tokensOut: number;
23
- cacheWrites?: number | undefined;
24
- cacheReads?: number | undefined;
25
- totalCost: number;
26
- size?: number | undefined;
27
- workspace?: string | undefined;
28
- }[] | undefined;
29
- autoApprovalEnabled?: boolean | undefined;
30
- alwaysAllowReadOnly?: boolean | undefined;
31
- alwaysAllowReadOnlyOutsideWorkspace?: boolean | undefined;
32
- alwaysAllowWrite?: boolean | undefined;
33
- alwaysAllowWriteOutsideWorkspace?: boolean | undefined;
34
- writeDelayMs?: number | undefined;
35
- alwaysAllowBrowser?: boolean | undefined;
36
- alwaysApproveResubmit?: boolean | undefined;
37
- requestDelaySeconds?: number | undefined;
38
- alwaysAllowMcp?: boolean | undefined;
39
- alwaysAllowModeSwitch?: boolean | undefined;
40
- alwaysAllowSubtasks?: boolean | undefined;
41
- alwaysAllowExecute?: boolean | undefined;
42
- allowedCommands?: string[] | undefined;
43
- allowedMaxRequests?: number | undefined;
44
- browserToolEnabled?: boolean | undefined;
45
- browserViewportSize?: string | undefined;
46
- screenshotQuality?: number | undefined;
47
- remoteBrowserEnabled?: boolean | undefined;
48
- remoteBrowserHost?: string | undefined;
49
- cachedChromeHostUrl?: string | undefined;
50
- enableCheckpoints?: boolean | undefined;
51
- ttsEnabled?: boolean | undefined;
52
- ttsSpeed?: number | undefined;
53
- soundEnabled?: boolean | undefined;
54
- soundVolume?: number | undefined;
55
- maxOpenTabsContext?: number | undefined;
56
- maxWorkspaceFiles?: number | undefined;
57
- showRooIgnoredFiles?: boolean | undefined;
58
- maxReadFileLine?: number | undefined;
59
- terminalOutputLineLimit?: number | undefined;
60
- terminalShellIntegrationTimeout?: number | undefined;
61
- terminalShellIntegrationDisabled?: boolean | undefined;
62
- terminalCommandDelay?: number | undefined;
63
- terminalPowershellCounter?: boolean | undefined;
64
- terminalZshClearEolMark?: boolean | undefined;
65
- terminalZshOhMy?: boolean | undefined;
66
- terminalZshP10k?: boolean | undefined;
67
- terminalZdotdir?: boolean | undefined;
68
- terminalCompressProgressBar?: boolean | undefined;
69
- rateLimitSeconds?: number | undefined;
70
- diffEnabled?: boolean | undefined;
71
- fuzzyMatchThreshold?: number | undefined;
72
- experiments?: {
73
- autoCondenseContext: boolean;
74
- powerSteering: boolean;
75
- } | undefined;
76
- language?: ("ca" | "de" | "en" | "es" | "fr" | "hi" | "it" | "ja" | "ko" | "nl" | "pl" | "pt-BR" | "ru" | "tr" | "vi" | "zh-CN" | "zh-TW") | undefined;
77
- telemetrySetting?: ("unset" | "enabled" | "disabled") | undefined;
78
- mcpEnabled?: boolean | undefined;
79
- enableMcpServerCreation?: boolean | undefined;
80
- mode?: string | undefined;
81
- modeApiConfigs?: {
82
- [x: string]: string;
83
- } | undefined;
84
- customModes?: {
85
- slug: string;
86
- name: string;
87
- roleDefinition: string;
88
- whenToUse?: string | undefined;
89
- customInstructions?: string | undefined;
90
- groups: (("read" | "edit" | "browser" | "command" | "mcp" | "modes") | [
91
- "read" | "edit" | "browser" | "command" | "mcp" | "modes",
92
- {
93
- fileRegex?: string | undefined;
94
- description?: string | undefined;
95
- }
96
- ])[];
97
- source?: ("global" | "project") | undefined;
98
- }[] | undefined;
99
- customModePrompts?: {
100
- [x: string]: {
101
- roleDefinition?: string | undefined;
102
- whenToUse?: string | undefined;
103
- customInstructions?: string | undefined;
104
- } | undefined;
105
- } | undefined;
106
- customSupportPrompts?: {
107
- [x: string]: string | undefined;
108
- } | undefined;
109
- enhancementApiConfigId?: string | undefined;
110
- historyPreviewCollapsed?: boolean | undefined;
111
- };
112
-
113
- type ProviderName = "anthropic" | "glama" | "openrouter" | "bedrock" | "vertex" | "openai" | "ollama" | "vscode-lm" | "lmstudio" | "gemini" | "openai-native" | "mistral" | "deepseek" | "unbound" | "requesty" | "human-relay" | "fake-ai" | "xai" | "groq" | "chutes" | "litellm";
114
-
115
- type ProviderSettings = {
116
- apiProvider?: ("anthropic" | "glama" | "openrouter" | "bedrock" | "vertex" | "openai" | "ollama" | "vscode-lm" | "lmstudio" | "gemini" | "openai-native" | "mistral" | "deepseek" | "unbound" | "requesty" | "human-relay" | "fake-ai" | "xai" | "groq" | "chutes" | "litellm") | undefined;
117
- includeMaxTokens?: boolean | undefined;
118
- reasoningEffort?: ("low" | "medium" | "high") | undefined;
119
- diffEnabled?: boolean | undefined;
120
- fuzzyMatchThreshold?: number | undefined;
121
- modelTemperature?: (number | null) | undefined;
122
- rateLimitSeconds?: number | undefined;
123
- modelMaxTokens?: number | undefined;
124
- modelMaxThinkingTokens?: number | undefined;
125
- apiModelId?: string | undefined;
126
- apiKey?: string | undefined;
127
- anthropicBaseUrl?: string | undefined;
128
- anthropicUseAuthToken?: boolean | undefined;
129
- glamaModelId?: string | undefined;
130
- glamaApiKey?: string | undefined;
131
- openRouterApiKey?: string | undefined;
132
- openRouterModelId?: string | undefined;
133
- openRouterBaseUrl?: string | undefined;
134
- openRouterSpecificProvider?: string | undefined;
135
- openRouterUseMiddleOutTransform?: boolean | undefined;
136
- awsAccessKey?: string | undefined;
137
- awsSecretKey?: string | undefined;
138
- awsSessionToken?: string | undefined;
139
- awsRegion?: string | undefined;
140
- awsUseCrossRegionInference?: boolean | undefined;
141
- awsUsePromptCache?: boolean | undefined;
142
- awsProfile?: string | undefined;
143
- awsUseProfile?: boolean | undefined;
144
- awsCustomArn?: string | undefined;
145
- vertexKeyFile?: string | undefined;
146
- vertexJsonCredentials?: string | undefined;
147
- vertexProjectId?: string | undefined;
148
- vertexRegion?: string | undefined;
149
- openAiBaseUrl?: string | undefined;
150
- openAiApiKey?: string | undefined;
151
- openAiLegacyFormat?: boolean | undefined;
152
- openAiR1FormatEnabled?: boolean | undefined;
153
- openAiModelId?: string | undefined;
154
- openAiCustomModelInfo?: ({
155
- maxTokens?: (number | null) | undefined;
156
- maxThinkingTokens?: (number | null) | undefined;
157
- contextWindow: number;
158
- supportsImages?: boolean | undefined;
159
- supportsComputerUse?: boolean | undefined;
160
- supportsPromptCache: boolean;
161
- inputPrice?: number | undefined;
162
- outputPrice?: number | undefined;
163
- cacheWritesPrice?: number | undefined;
164
- cacheReadsPrice?: number | undefined;
165
- description?: string | undefined;
166
- reasoningEffort?: ("low" | "medium" | "high") | undefined;
167
- thinking?: boolean | undefined;
168
- minTokensPerCachePoint?: number | undefined;
169
- maxCachePoints?: number | undefined;
170
- cachableFields?: string[] | undefined;
171
- tiers?: {
172
- contextWindow: number;
173
- inputPrice?: number | undefined;
174
- outputPrice?: number | undefined;
175
- cacheWritesPrice?: number | undefined;
176
- cacheReadsPrice?: number | undefined;
177
- }[] | undefined;
178
- } | null) | undefined;
179
- openAiUseAzure?: boolean | undefined;
180
- azureApiVersion?: string | undefined;
181
- openAiStreamingEnabled?: boolean | undefined;
182
- enableReasoningEffort?: boolean | undefined;
183
- openAiHostHeader?: string | undefined;
184
- openAiHeaders?: {
185
- [x: string]: string;
186
- } | undefined;
187
- ollamaModelId?: string | undefined;
188
- ollamaBaseUrl?: string | undefined;
189
- vsCodeLmModelSelector?: {
190
- vendor?: string | undefined;
191
- family?: string | undefined;
192
- version?: string | undefined;
193
- id?: string | undefined;
194
- } | undefined;
195
- lmStudioModelId?: string | undefined;
196
- lmStudioBaseUrl?: string | undefined;
197
- lmStudioDraftModelId?: string | undefined;
198
- lmStudioSpeculativeDecodingEnabled?: boolean | undefined;
199
- geminiApiKey?: string | undefined;
200
- googleGeminiBaseUrl?: string | undefined;
201
- openAiNativeApiKey?: string | undefined;
202
- openAiNativeBaseUrl?: string | undefined;
203
- mistralApiKey?: string | undefined;
204
- mistralCodestralUrl?: string | undefined;
205
- deepSeekBaseUrl?: string | undefined;
206
- deepSeekApiKey?: string | undefined;
207
- unboundApiKey?: string | undefined;
208
- unboundModelId?: string | undefined;
209
- requestyApiKey?: string | undefined;
210
- requestyModelId?: string | undefined;
211
- fakeAi?: unknown | undefined;
212
- xaiApiKey?: string | undefined;
213
- groqApiKey?: string | undefined;
214
- chutesApiKey?: string | undefined;
215
- litellmBaseUrl?: string | undefined;
216
- litellmApiKey?: string | undefined;
217
- litellmModelId?: string | undefined;
218
- };
219
-
220
- type ProviderSettingsEntry = {
221
- id: string;
222
- name: string;
223
- apiProvider?: ("anthropic" | "glama" | "openrouter" | "bedrock" | "vertex" | "openai" | "ollama" | "vscode-lm" | "lmstudio" | "gemini" | "openai-native" | "mistral" | "deepseek" | "unbound" | "requesty" | "human-relay" | "fake-ai" | "xai" | "groq" | "chutes" | "litellm") | undefined;
224
- };
225
-
226
- type ClineMessage = {
227
- ts: number;
228
- type: "ask" | "say";
229
- ask?: ("followup" | "command" | "command_output" | "completion_result" | "tool" | "api_req_failed" | "resume_task" | "resume_completed_task" | "mistake_limit_reached" | "browser_action_launch" | "use_mcp_server" | "auto_approval_max_req_reached") | undefined;
230
- say?: ("error" | "api_req_started" | "api_req_finished" | "api_req_retried" | "api_req_retry_delayed" | "api_req_deleted" | "text" | "reasoning" | "completion_result" | "user_feedback" | "user_feedback_diff" | "command_output" | "shell_integration_warning" | "browser_action" | "browser_action_result" | "mcp_server_request_started" | "mcp_server_response" | "subtask_result" | "checkpoint_saved" | "rooignore_error" | "diff_error" | "condense_context") | undefined;
231
- text?: string | undefined;
232
- images?: string[] | undefined;
233
- partial?: boolean | undefined;
234
- reasoning?: string | undefined;
235
- conversationHistoryIndex?: number | undefined;
236
- checkpoint?: {
237
- [x: string]: unknown;
238
- } | undefined;
239
- progressStatus?: {
240
- icon?: string | undefined;
241
- text?: string | undefined;
242
- } | undefined;
243
- contextCondense?: {
244
- cost: number;
245
- prevContextTokens: number;
246
- newContextTokens: number;
247
- summary: string;
248
- } | undefined;
249
- };
250
-
251
- type TokenUsage = {
252
- totalTokensIn: number;
253
- totalTokensOut: number;
254
- totalCacheWrites?: number | undefined;
255
- totalCacheReads?: number | undefined;
256
- totalCost: number;
257
- contextTokens: number;
258
- };
259
-
260
- type RooCodeEvents = {
261
- message: [
262
- {
263
- taskId: string;
264
- action: "created" | "updated";
265
- message: {
266
- ts: number;
267
- type: "ask" | "say";
268
- ask?: ("followup" | "command" | "command_output" | "completion_result" | "tool" | "api_req_failed" | "resume_task" | "resume_completed_task" | "mistake_limit_reached" | "browser_action_launch" | "use_mcp_server" | "auto_approval_max_req_reached") | undefined;
269
- say?: ("error" | "api_req_started" | "api_req_finished" | "api_req_retried" | "api_req_retry_delayed" | "api_req_deleted" | "text" | "reasoning" | "completion_result" | "user_feedback" | "user_feedback_diff" | "command_output" | "shell_integration_warning" | "browser_action" | "browser_action_result" | "mcp_server_request_started" | "mcp_server_response" | "subtask_result" | "checkpoint_saved" | "rooignore_error" | "diff_error" | "condense_context") | undefined;
270
- text?: string | undefined;
271
- images?: string[] | undefined;
272
- partial?: boolean | undefined;
273
- reasoning?: string | undefined;
274
- conversationHistoryIndex?: number | undefined;
275
- checkpoint?: {
276
- [x: string]: unknown;
277
- } | undefined;
278
- progressStatus?: {
279
- icon?: string | undefined;
280
- text?: string | undefined;
281
- } | undefined;
282
- contextCondense?: {
283
- cost: number;
284
- prevContextTokens: number;
285
- newContextTokens: number;
286
- summary: string;
287
- } | undefined;
288
- };
289
- }
290
- ];
291
- taskCreated: [
292
- string
293
- ];
294
- taskStarted: [
295
- string
296
- ];
297
- taskModeSwitched: [
298
- string,
299
- string
300
- ];
301
- taskPaused: [
302
- string
303
- ];
304
- taskUnpaused: [
305
- string
306
- ];
307
- taskAskResponded: [
308
- string
309
- ];
310
- taskAborted: [
311
- string
312
- ];
313
- taskSpawned: [
314
- string,
315
- string
316
- ];
317
- taskCompleted: [
318
- string,
319
- {
320
- totalTokensIn: number;
321
- totalTokensOut: number;
322
- totalCacheWrites?: number | undefined;
323
- totalCacheReads?: number | undefined;
324
- totalCost: number;
325
- contextTokens: number;
326
- },
327
- {
328
- [x: string]: {
329
- attempts: number;
330
- failures: number;
331
- };
332
- }
333
- ];
334
- taskTokenUsageUpdated: [
335
- string,
336
- {
337
- totalTokensIn: number;
338
- totalTokensOut: number;
339
- totalCacheWrites?: number | undefined;
340
- totalCacheReads?: number | undefined;
341
- totalCost: number;
342
- contextTokens: number;
343
- }
344
- ];
345
- taskToolFailed: [
346
- string,
347
- "execute_command" | "read_file" | "write_to_file" | "apply_diff" | "insert_content" | "search_and_replace" | "search_files" | "list_files" | "list_code_definition_names" | "browser_action" | "use_mcp_tool" | "access_mcp_resource" | "ask_followup_question" | "attempt_completion" | "switch_mode" | "new_task" | "fetch_instructions",
348
- string
349
- ];
350
- };
351
-
352
- type IpcMessage = {
353
- type: "Ack";
354
- origin: "server";
355
- data: {
356
- clientId: string;
357
- pid: number;
358
- ppid: number;
359
- };
360
- } | {
361
- type: "TaskCommand";
362
- origin: "client";
363
- clientId: string;
364
- data: {
365
- commandName: "StartNewTask";
366
- data: {
367
- configuration: {
368
- apiProvider?: ("anthropic" | "glama" | "openrouter" | "bedrock" | "vertex" | "openai" | "ollama" | "vscode-lm" | "lmstudio" | "gemini" | "openai-native" | "mistral" | "deepseek" | "unbound" | "requesty" | "human-relay" | "fake-ai" | "xai" | "groq" | "chutes" | "litellm") | undefined;
369
- includeMaxTokens?: boolean | undefined;
370
- reasoningEffort?: ("low" | "medium" | "high") | undefined;
371
- diffEnabled?: boolean | undefined;
372
- fuzzyMatchThreshold?: number | undefined;
373
- modelTemperature?: (number | null) | undefined;
374
- rateLimitSeconds?: number | undefined;
375
- modelMaxTokens?: number | undefined;
376
- modelMaxThinkingTokens?: number | undefined;
377
- apiModelId?: string | undefined;
378
- apiKey?: string | undefined;
379
- anthropicBaseUrl?: string | undefined;
380
- anthropicUseAuthToken?: boolean | undefined;
381
- glamaModelId?: string | undefined;
382
- glamaApiKey?: string | undefined;
383
- openRouterApiKey?: string | undefined;
384
- openRouterModelId?: string | undefined;
385
- openRouterBaseUrl?: string | undefined;
386
- openRouterSpecificProvider?: string | undefined;
387
- openRouterUseMiddleOutTransform?: boolean | undefined;
388
- awsAccessKey?: string | undefined;
389
- awsSecretKey?: string | undefined;
390
- awsSessionToken?: string | undefined;
391
- awsRegion?: string | undefined;
392
- awsUseCrossRegionInference?: boolean | undefined;
393
- awsUsePromptCache?: boolean | undefined;
394
- awsProfile?: string | undefined;
395
- awsUseProfile?: boolean | undefined;
396
- awsCustomArn?: string | undefined;
397
- vertexKeyFile?: string | undefined;
398
- vertexJsonCredentials?: string | undefined;
399
- vertexProjectId?: string | undefined;
400
- vertexRegion?: string | undefined;
401
- openAiBaseUrl?: string | undefined;
402
- openAiApiKey?: string | undefined;
403
- openAiLegacyFormat?: boolean | undefined;
404
- openAiR1FormatEnabled?: boolean | undefined;
405
- openAiModelId?: string | undefined;
406
- openAiCustomModelInfo?: ({
407
- maxTokens?: (number | null) | undefined;
408
- maxThinkingTokens?: (number | null) | undefined;
409
- contextWindow: number;
410
- supportsImages?: boolean | undefined;
411
- supportsComputerUse?: boolean | undefined;
412
- supportsPromptCache: boolean;
413
- inputPrice?: number | undefined;
414
- outputPrice?: number | undefined;
415
- cacheWritesPrice?: number | undefined;
416
- cacheReadsPrice?: number | undefined;
417
- description?: string | undefined;
418
- reasoningEffort?: ("low" | "medium" | "high") | undefined;
419
- thinking?: boolean | undefined;
420
- minTokensPerCachePoint?: number | undefined;
421
- maxCachePoints?: number | undefined;
422
- cachableFields?: string[] | undefined;
423
- tiers?: {
424
- contextWindow: number;
425
- inputPrice?: number | undefined;
426
- outputPrice?: number | undefined;
427
- cacheWritesPrice?: number | undefined;
428
- cacheReadsPrice?: number | undefined;
429
- }[] | undefined;
430
- } | null) | undefined;
431
- openAiUseAzure?: boolean | undefined;
432
- azureApiVersion?: string | undefined;
433
- openAiStreamingEnabled?: boolean | undefined;
434
- enableReasoningEffort?: boolean | undefined;
435
- openAiHostHeader?: string | undefined;
436
- openAiHeaders?: {
437
- [x: string]: string;
438
- } | undefined;
439
- ollamaModelId?: string | undefined;
440
- ollamaBaseUrl?: string | undefined;
441
- vsCodeLmModelSelector?: {
442
- vendor?: string | undefined;
443
- family?: string | undefined;
444
- version?: string | undefined;
445
- id?: string | undefined;
446
- } | undefined;
447
- lmStudioModelId?: string | undefined;
448
- lmStudioBaseUrl?: string | undefined;
449
- lmStudioDraftModelId?: string | undefined;
450
- lmStudioSpeculativeDecodingEnabled?: boolean | undefined;
451
- geminiApiKey?: string | undefined;
452
- googleGeminiBaseUrl?: string | undefined;
453
- openAiNativeApiKey?: string | undefined;
454
- openAiNativeBaseUrl?: string | undefined;
455
- mistralApiKey?: string | undefined;
456
- mistralCodestralUrl?: string | undefined;
457
- deepSeekBaseUrl?: string | undefined;
458
- deepSeekApiKey?: string | undefined;
459
- unboundApiKey?: string | undefined;
460
- unboundModelId?: string | undefined;
461
- requestyApiKey?: string | undefined;
462
- requestyModelId?: string | undefined;
463
- fakeAi?: unknown | undefined;
464
- xaiApiKey?: string | undefined;
465
- groqApiKey?: string | undefined;
466
- chutesApiKey?: string | undefined;
467
- litellmBaseUrl?: string | undefined;
468
- litellmApiKey?: string | undefined;
469
- litellmModelId?: string | undefined;
470
- currentApiConfigName?: string | undefined;
471
- listApiConfigMeta?: {
472
- id: string;
473
- name: string;
474
- apiProvider?: ("anthropic" | "glama" | "openrouter" | "bedrock" | "vertex" | "openai" | "ollama" | "vscode-lm" | "lmstudio" | "gemini" | "openai-native" | "mistral" | "deepseek" | "unbound" | "requesty" | "human-relay" | "fake-ai" | "xai" | "groq" | "chutes" | "litellm") | undefined;
475
- }[] | undefined;
476
- pinnedApiConfigs?: {
477
- [x: string]: boolean;
478
- } | undefined;
479
- lastShownAnnouncementId?: string | undefined;
480
- customInstructions?: string | undefined;
481
- taskHistory?: {
482
- id: string;
483
- number: number;
484
- ts: number;
485
- task: string;
486
- tokensIn: number;
487
- tokensOut: number;
488
- cacheWrites?: number | undefined;
489
- cacheReads?: number | undefined;
490
- totalCost: number;
491
- size?: number | undefined;
492
- workspace?: string | undefined;
493
- }[] | undefined;
494
- autoApprovalEnabled?: boolean | undefined;
495
- alwaysAllowReadOnly?: boolean | undefined;
496
- alwaysAllowReadOnlyOutsideWorkspace?: boolean | undefined;
497
- alwaysAllowWrite?: boolean | undefined;
498
- alwaysAllowWriteOutsideWorkspace?: boolean | undefined;
499
- writeDelayMs?: number | undefined;
500
- alwaysAllowBrowser?: boolean | undefined;
501
- alwaysApproveResubmit?: boolean | undefined;
502
- requestDelaySeconds?: number | undefined;
503
- alwaysAllowMcp?: boolean | undefined;
504
- alwaysAllowModeSwitch?: boolean | undefined;
505
- alwaysAllowSubtasks?: boolean | undefined;
506
- alwaysAllowExecute?: boolean | undefined;
507
- allowedCommands?: string[] | undefined;
508
- allowedMaxRequests?: number | undefined;
509
- browserToolEnabled?: boolean | undefined;
510
- browserViewportSize?: string | undefined;
511
- screenshotQuality?: number | undefined;
512
- remoteBrowserEnabled?: boolean | undefined;
513
- remoteBrowserHost?: string | undefined;
514
- cachedChromeHostUrl?: string | undefined;
515
- enableCheckpoints?: boolean | undefined;
516
- ttsEnabled?: boolean | undefined;
517
- ttsSpeed?: number | undefined;
518
- soundEnabled?: boolean | undefined;
519
- soundVolume?: number | undefined;
520
- maxOpenTabsContext?: number | undefined;
521
- maxWorkspaceFiles?: number | undefined;
522
- showRooIgnoredFiles?: boolean | undefined;
523
- maxReadFileLine?: number | undefined;
524
- terminalOutputLineLimit?: number | undefined;
525
- terminalShellIntegrationTimeout?: number | undefined;
526
- terminalShellIntegrationDisabled?: boolean | undefined;
527
- terminalCommandDelay?: number | undefined;
528
- terminalPowershellCounter?: boolean | undefined;
529
- terminalZshClearEolMark?: boolean | undefined;
530
- terminalZshOhMy?: boolean | undefined;
531
- terminalZshP10k?: boolean | undefined;
532
- terminalZdotdir?: boolean | undefined;
533
- terminalCompressProgressBar?: boolean | undefined;
534
- experiments?: {
535
- autoCondenseContext: boolean;
536
- powerSteering: boolean;
537
- } | undefined;
538
- language?: ("ca" | "de" | "en" | "es" | "fr" | "hi" | "it" | "ja" | "ko" | "nl" | "pl" | "pt-BR" | "ru" | "tr" | "vi" | "zh-CN" | "zh-TW") | undefined;
539
- telemetrySetting?: ("unset" | "enabled" | "disabled") | undefined;
540
- mcpEnabled?: boolean | undefined;
541
- enableMcpServerCreation?: boolean | undefined;
542
- mode?: string | undefined;
543
- modeApiConfigs?: {
544
- [x: string]: string;
545
- } | undefined;
546
- customModes?: {
547
- slug: string;
548
- name: string;
549
- roleDefinition: string;
550
- whenToUse?: string | undefined;
551
- customInstructions?: string | undefined;
552
- groups: (("read" | "edit" | "browser" | "command" | "mcp" | "modes") | [
553
- "read" | "edit" | "browser" | "command" | "mcp" | "modes",
554
- {
555
- fileRegex?: string | undefined;
556
- description?: string | undefined;
557
- }
558
- ])[];
559
- source?: ("global" | "project") | undefined;
560
- }[] | undefined;
561
- customModePrompts?: {
562
- [x: string]: {
563
- roleDefinition?: string | undefined;
564
- whenToUse?: string | undefined;
565
- customInstructions?: string | undefined;
566
- } | undefined;
567
- } | undefined;
568
- customSupportPrompts?: {
569
- [x: string]: string | undefined;
570
- } | undefined;
571
- enhancementApiConfigId?: string | undefined;
572
- historyPreviewCollapsed?: boolean | undefined;
573
- };
574
- text: string;
575
- images?: string[] | undefined;
576
- newTab?: boolean | undefined;
577
- };
578
- } | {
579
- commandName: "CancelTask";
580
- data: string;
581
- } | {
582
- commandName: "CloseTask";
583
- data: string;
584
- };
585
- } | {
586
- type: "TaskEvent";
587
- origin: "server";
588
- relayClientId?: string | undefined;
589
- data: {
590
- eventName: "message";
591
- payload: [
592
- {
593
- taskId: string;
594
- action: "created" | "updated";
595
- message: {
596
- ts: number;
597
- type: "ask" | "say";
598
- ask?: ("followup" | "command" | "command_output" | "completion_result" | "tool" | "api_req_failed" | "resume_task" | "resume_completed_task" | "mistake_limit_reached" | "browser_action_launch" | "use_mcp_server" | "auto_approval_max_req_reached") | undefined;
599
- say?: ("error" | "api_req_started" | "api_req_finished" | "api_req_retried" | "api_req_retry_delayed" | "api_req_deleted" | "text" | "reasoning" | "completion_result" | "user_feedback" | "user_feedback_diff" | "command_output" | "shell_integration_warning" | "browser_action" | "browser_action_result" | "mcp_server_request_started" | "mcp_server_response" | "subtask_result" | "checkpoint_saved" | "rooignore_error" | "diff_error" | "condense_context") | undefined;
600
- text?: string | undefined;
601
- images?: string[] | undefined;
602
- partial?: boolean | undefined;
603
- reasoning?: string | undefined;
604
- conversationHistoryIndex?: number | undefined;
605
- checkpoint?: {
606
- [x: string]: unknown;
607
- } | undefined;
608
- progressStatus?: {
609
- icon?: string | undefined;
610
- text?: string | undefined;
611
- } | undefined;
612
- contextCondense?: {
613
- cost: number;
614
- prevContextTokens: number;
615
- newContextTokens: number;
616
- summary: string;
617
- } | undefined;
618
- };
619
- }
620
- ];
621
- } | {
622
- eventName: "taskCreated";
623
- payload: [
624
- string
625
- ];
626
- } | {
627
- eventName: "taskStarted";
628
- payload: [
629
- string
630
- ];
631
- } | {
632
- eventName: "taskModeSwitched";
633
- payload: [
634
- string,
635
- string
636
- ];
637
- } | {
638
- eventName: "taskPaused";
639
- payload: [
640
- string
641
- ];
642
- } | {
643
- eventName: "taskUnpaused";
644
- payload: [
645
- string
646
- ];
647
- } | {
648
- eventName: "taskAskResponded";
649
- payload: [
650
- string
651
- ];
652
- } | {
653
- eventName: "taskAborted";
654
- payload: [
655
- string
656
- ];
657
- } | {
658
- eventName: "taskSpawned";
659
- payload: [
660
- string,
661
- string
662
- ];
663
- } | {
664
- eventName: "taskCompleted";
665
- payload: [
666
- string,
667
- {
668
- totalTokensIn: number;
669
- totalTokensOut: number;
670
- totalCacheWrites?: number | undefined;
671
- totalCacheReads?: number | undefined;
672
- totalCost: number;
673
- contextTokens: number;
674
- },
675
- {
676
- [x: string]: {
677
- attempts: number;
678
- failures: number;
679
- };
680
- }
681
- ];
682
- } | {
683
- eventName: "taskTokenUsageUpdated";
684
- payload: [
685
- string,
686
- {
687
- totalTokensIn: number;
688
- totalTokensOut: number;
689
- totalCacheWrites?: number | undefined;
690
- totalCacheReads?: number | undefined;
691
- totalCost: number;
692
- contextTokens: number;
693
- }
694
- ];
695
- };
696
- };
697
-
698
- type TaskCommand = {
699
- commandName: "StartNewTask";
700
- data: {
701
- configuration: {
702
- apiProvider?: ("anthropic" | "glama" | "openrouter" | "bedrock" | "vertex" | "openai" | "ollama" | "vscode-lm" | "lmstudio" | "gemini" | "openai-native" | "mistral" | "deepseek" | "unbound" | "requesty" | "human-relay" | "fake-ai" | "xai" | "groq" | "chutes" | "litellm") | undefined;
703
- includeMaxTokens?: boolean | undefined;
704
- reasoningEffort?: ("low" | "medium" | "high") | undefined;
705
- diffEnabled?: boolean | undefined;
706
- fuzzyMatchThreshold?: number | undefined;
707
- modelTemperature?: (number | null) | undefined;
708
- rateLimitSeconds?: number | undefined;
709
- modelMaxTokens?: number | undefined;
710
- modelMaxThinkingTokens?: number | undefined;
711
- apiModelId?: string | undefined;
712
- apiKey?: string | undefined;
713
- anthropicBaseUrl?: string | undefined;
714
- anthropicUseAuthToken?: boolean | undefined;
715
- glamaModelId?: string | undefined;
716
- glamaApiKey?: string | undefined;
717
- openRouterApiKey?: string | undefined;
718
- openRouterModelId?: string | undefined;
719
- openRouterBaseUrl?: string | undefined;
720
- openRouterSpecificProvider?: string | undefined;
721
- openRouterUseMiddleOutTransform?: boolean | undefined;
722
- awsAccessKey?: string | undefined;
723
- awsSecretKey?: string | undefined;
724
- awsSessionToken?: string | undefined;
725
- awsRegion?: string | undefined;
726
- awsUseCrossRegionInference?: boolean | undefined;
727
- awsUsePromptCache?: boolean | undefined;
728
- awsProfile?: string | undefined;
729
- awsUseProfile?: boolean | undefined;
730
- awsCustomArn?: string | undefined;
731
- vertexKeyFile?: string | undefined;
732
- vertexJsonCredentials?: string | undefined;
733
- vertexProjectId?: string | undefined;
734
- vertexRegion?: string | undefined;
735
- openAiBaseUrl?: string | undefined;
736
- openAiApiKey?: string | undefined;
737
- openAiLegacyFormat?: boolean | undefined;
738
- openAiR1FormatEnabled?: boolean | undefined;
739
- openAiModelId?: string | undefined;
740
- openAiCustomModelInfo?: ({
741
- maxTokens?: (number | null) | undefined;
742
- maxThinkingTokens?: (number | null) | undefined;
743
- contextWindow: number;
744
- supportsImages?: boolean | undefined;
745
- supportsComputerUse?: boolean | undefined;
746
- supportsPromptCache: boolean;
747
- inputPrice?: number | undefined;
748
- outputPrice?: number | undefined;
749
- cacheWritesPrice?: number | undefined;
750
- cacheReadsPrice?: number | undefined;
751
- description?: string | undefined;
752
- reasoningEffort?: ("low" | "medium" | "high") | undefined;
753
- thinking?: boolean | undefined;
754
- minTokensPerCachePoint?: number | undefined;
755
- maxCachePoints?: number | undefined;
756
- cachableFields?: string[] | undefined;
757
- tiers?: {
758
- contextWindow: number;
759
- inputPrice?: number | undefined;
760
- outputPrice?: number | undefined;
761
- cacheWritesPrice?: number | undefined;
762
- cacheReadsPrice?: number | undefined;
763
- }[] | undefined;
764
- } | null) | undefined;
765
- openAiUseAzure?: boolean | undefined;
766
- azureApiVersion?: string | undefined;
767
- openAiStreamingEnabled?: boolean | undefined;
768
- enableReasoningEffort?: boolean | undefined;
769
- openAiHostHeader?: string | undefined;
770
- openAiHeaders?: {
771
- [x: string]: string;
772
- } | undefined;
773
- ollamaModelId?: string | undefined;
774
- ollamaBaseUrl?: string | undefined;
775
- vsCodeLmModelSelector?: {
776
- vendor?: string | undefined;
777
- family?: string | undefined;
778
- version?: string | undefined;
779
- id?: string | undefined;
780
- } | undefined;
781
- lmStudioModelId?: string | undefined;
782
- lmStudioBaseUrl?: string | undefined;
783
- lmStudioDraftModelId?: string | undefined;
784
- lmStudioSpeculativeDecodingEnabled?: boolean | undefined;
785
- geminiApiKey?: string | undefined;
786
- googleGeminiBaseUrl?: string | undefined;
787
- openAiNativeApiKey?: string | undefined;
788
- openAiNativeBaseUrl?: string | undefined;
789
- mistralApiKey?: string | undefined;
790
- mistralCodestralUrl?: string | undefined;
791
- deepSeekBaseUrl?: string | undefined;
792
- deepSeekApiKey?: string | undefined;
793
- unboundApiKey?: string | undefined;
794
- unboundModelId?: string | undefined;
795
- requestyApiKey?: string | undefined;
796
- requestyModelId?: string | undefined;
797
- fakeAi?: unknown | undefined;
798
- xaiApiKey?: string | undefined;
799
- groqApiKey?: string | undefined;
800
- chutesApiKey?: string | undefined;
801
- litellmBaseUrl?: string | undefined;
802
- litellmApiKey?: string | undefined;
803
- litellmModelId?: string | undefined;
804
- currentApiConfigName?: string | undefined;
805
- listApiConfigMeta?: {
806
- id: string;
807
- name: string;
808
- apiProvider?: ("anthropic" | "glama" | "openrouter" | "bedrock" | "vertex" | "openai" | "ollama" | "vscode-lm" | "lmstudio" | "gemini" | "openai-native" | "mistral" | "deepseek" | "unbound" | "requesty" | "human-relay" | "fake-ai" | "xai" | "groq" | "chutes" | "litellm") | undefined;
809
- }[] | undefined;
810
- pinnedApiConfigs?: {
811
- [x: string]: boolean;
812
- } | undefined;
813
- lastShownAnnouncementId?: string | undefined;
814
- customInstructions?: string | undefined;
815
- taskHistory?: {
816
- id: string;
817
- number: number;
818
- ts: number;
819
- task: string;
820
- tokensIn: number;
821
- tokensOut: number;
822
- cacheWrites?: number | undefined;
823
- cacheReads?: number | undefined;
824
- totalCost: number;
825
- size?: number | undefined;
826
- workspace?: string | undefined;
827
- }[] | undefined;
828
- autoApprovalEnabled?: boolean | undefined;
829
- alwaysAllowReadOnly?: boolean | undefined;
830
- alwaysAllowReadOnlyOutsideWorkspace?: boolean | undefined;
831
- alwaysAllowWrite?: boolean | undefined;
832
- alwaysAllowWriteOutsideWorkspace?: boolean | undefined;
833
- writeDelayMs?: number | undefined;
834
- alwaysAllowBrowser?: boolean | undefined;
835
- alwaysApproveResubmit?: boolean | undefined;
836
- requestDelaySeconds?: number | undefined;
837
- alwaysAllowMcp?: boolean | undefined;
838
- alwaysAllowModeSwitch?: boolean | undefined;
839
- alwaysAllowSubtasks?: boolean | undefined;
840
- alwaysAllowExecute?: boolean | undefined;
841
- allowedCommands?: string[] | undefined;
842
- allowedMaxRequests?: number | undefined;
843
- browserToolEnabled?: boolean | undefined;
844
- browserViewportSize?: string | undefined;
845
- screenshotQuality?: number | undefined;
846
- remoteBrowserEnabled?: boolean | undefined;
847
- remoteBrowserHost?: string | undefined;
848
- cachedChromeHostUrl?: string | undefined;
849
- enableCheckpoints?: boolean | undefined;
850
- ttsEnabled?: boolean | undefined;
851
- ttsSpeed?: number | undefined;
852
- soundEnabled?: boolean | undefined;
853
- soundVolume?: number | undefined;
854
- maxOpenTabsContext?: number | undefined;
855
- maxWorkspaceFiles?: number | undefined;
856
- showRooIgnoredFiles?: boolean | undefined;
857
- maxReadFileLine?: number | undefined;
858
- terminalOutputLineLimit?: number | undefined;
859
- terminalShellIntegrationTimeout?: number | undefined;
860
- terminalShellIntegrationDisabled?: boolean | undefined;
861
- terminalCommandDelay?: number | undefined;
862
- terminalPowershellCounter?: boolean | undefined;
863
- terminalZshClearEolMark?: boolean | undefined;
864
- terminalZshOhMy?: boolean | undefined;
865
- terminalZshP10k?: boolean | undefined;
866
- terminalZdotdir?: boolean | undefined;
867
- terminalCompressProgressBar?: boolean | undefined;
868
- experiments?: {
869
- autoCondenseContext: boolean;
870
- powerSteering: boolean;
871
- } | undefined;
872
- language?: ("ca" | "de" | "en" | "es" | "fr" | "hi" | "it" | "ja" | "ko" | "nl" | "pl" | "pt-BR" | "ru" | "tr" | "vi" | "zh-CN" | "zh-TW") | undefined;
873
- telemetrySetting?: ("unset" | "enabled" | "disabled") | undefined;
874
- mcpEnabled?: boolean | undefined;
875
- enableMcpServerCreation?: boolean | undefined;
876
- mode?: string | undefined;
877
- modeApiConfigs?: {
878
- [x: string]: string;
879
- } | undefined;
880
- customModes?: {
881
- slug: string;
882
- name: string;
883
- roleDefinition: string;
884
- whenToUse?: string | undefined;
885
- customInstructions?: string | undefined;
886
- groups: (("read" | "edit" | "browser" | "command" | "mcp" | "modes") | [
887
- "read" | "edit" | "browser" | "command" | "mcp" | "modes",
888
- {
889
- fileRegex?: string | undefined;
890
- description?: string | undefined;
891
- }
892
- ])[];
893
- source?: ("global" | "project") | undefined;
894
- }[] | undefined;
895
- customModePrompts?: {
896
- [x: string]: {
897
- roleDefinition?: string | undefined;
898
- whenToUse?: string | undefined;
899
- customInstructions?: string | undefined;
900
- } | undefined;
901
- } | undefined;
902
- customSupportPrompts?: {
903
- [x: string]: string | undefined;
904
- } | undefined;
905
- enhancementApiConfigId?: string | undefined;
906
- historyPreviewCollapsed?: boolean | undefined;
907
- };
908
- text: string;
909
- images?: string[] | undefined;
910
- newTab?: boolean | undefined;
911
- };
912
- } | {
913
- commandName: "CancelTask";
914
- data: string;
915
- } | {
916
- commandName: "CloseTask";
917
- data: string;
918
- };
919
-
920
- type TaskEvent = {
921
- eventName: "message";
922
- payload: [
923
- {
924
- taskId: string;
925
- action: "created" | "updated";
926
- message: {
927
- ts: number;
928
- type: "ask" | "say";
929
- ask?: ("followup" | "command" | "command_output" | "completion_result" | "tool" | "api_req_failed" | "resume_task" | "resume_completed_task" | "mistake_limit_reached" | "browser_action_launch" | "use_mcp_server" | "auto_approval_max_req_reached") | undefined;
930
- say?: ("error" | "api_req_started" | "api_req_finished" | "api_req_retried" | "api_req_retry_delayed" | "api_req_deleted" | "text" | "reasoning" | "completion_result" | "user_feedback" | "user_feedback_diff" | "command_output" | "shell_integration_warning" | "browser_action" | "browser_action_result" | "mcp_server_request_started" | "mcp_server_response" | "subtask_result" | "checkpoint_saved" | "rooignore_error" | "diff_error" | "condense_context") | undefined;
931
- text?: string | undefined;
932
- images?: string[] | undefined;
933
- partial?: boolean | undefined;
934
- reasoning?: string | undefined;
935
- conversationHistoryIndex?: number | undefined;
936
- checkpoint?: {
937
- [x: string]: unknown;
938
- } | undefined;
939
- progressStatus?: {
940
- icon?: string | undefined;
941
- text?: string | undefined;
942
- } | undefined;
943
- contextCondense?: {
944
- cost: number;
945
- prevContextTokens: number;
946
- newContextTokens: number;
947
- summary: string;
948
- } | undefined;
949
- };
950
- }
951
- ];
952
- } | {
953
- eventName: "taskCreated";
954
- payload: [
955
- string
956
- ];
957
- } | {
958
- eventName: "taskStarted";
959
- payload: [
960
- string
961
- ];
962
- } | {
963
- eventName: "taskModeSwitched";
964
- payload: [
965
- string,
966
- string
967
- ];
968
- } | {
969
- eventName: "taskPaused";
970
- payload: [
971
- string
972
- ];
973
- } | {
974
- eventName: "taskUnpaused";
975
- payload: [
976
- string
977
- ];
978
- } | {
979
- eventName: "taskAskResponded";
980
- payload: [
981
- string
982
- ];
983
- } | {
984
- eventName: "taskAborted";
985
- payload: [
986
- string
987
- ];
988
- } | {
989
- eventName: "taskSpawned";
990
- payload: [
991
- string,
992
- string
993
- ];
994
- } | {
995
- eventName: "taskCompleted";
996
- payload: [
997
- string,
998
- {
999
- totalTokensIn: number;
1000
- totalTokensOut: number;
1001
- totalCacheWrites?: number | undefined;
1002
- totalCacheReads?: number | undefined;
1003
- totalCost: number;
1004
- contextTokens: number;
1005
- },
1006
- {
1007
- [x: string]: {
1008
- attempts: number;
1009
- failures: number;
1010
- };
1011
- }
1012
- ];
1013
- } | {
1014
- eventName: "taskTokenUsageUpdated";
1015
- payload: [
1016
- string,
1017
- {
1018
- totalTokensIn: number;
1019
- totalTokensOut: number;
1020
- totalCacheWrites?: number | undefined;
1021
- totalCacheReads?: number | undefined;
1022
- totalCost: number;
1023
- contextTokens: number;
1024
- }
1025
- ];
1026
- };
1027
-
1028
- declare const Package: {
1029
- readonly publisher: string;
1030
- readonly name: string;
1031
- readonly version: string;
1032
- };
1033
- /**
1034
- * ProviderName
1035
- */
1036
- declare const providerNames: readonly ["anthropic", "glama", "openrouter", "bedrock", "vertex", "openai", "ollama", "vscode-lm", "lmstudio", "gemini", "openai-native", "mistral", "deepseek", "unbound", "requesty", "human-relay", "fake-ai", "xai", "groq", "chutes", "litellm"];
1037
- /**
1038
- * RooCodeEvent
1039
- */
1040
- declare enum RooCodeEventName {
1041
- Message = "message",
1042
- TaskCreated = "taskCreated",
1043
- TaskStarted = "taskStarted",
1044
- TaskModeSwitched = "taskModeSwitched",
1045
- TaskPaused = "taskPaused",
1046
- TaskUnpaused = "taskUnpaused",
1047
- TaskAskResponded = "taskAskResponded",
1048
- TaskAborted = "taskAborted",
1049
- TaskSpawned = "taskSpawned",
1050
- TaskCompleted = "taskCompleted",
1051
- TaskTokenUsageUpdated = "taskTokenUsageUpdated",
1052
- TaskToolFailed = "taskToolFailed"
1053
- }
1054
- /**
1055
- * IpcMessage
1056
- */
1057
- declare enum IpcMessageType {
1058
- Connect = "Connect",
1059
- Disconnect = "Disconnect",
1060
- Ack = "Ack",
1061
- TaskCommand = "TaskCommand",
1062
- TaskEvent = "TaskEvent"
1063
- }
1064
- declare enum IpcOrigin {
1065
- Client = "client",
1066
- Server = "server"
1067
- }
1068
-
1069
- /**
1070
- * RooCodeAPI
1071
- */
1072
- type RooCodeSettings = GlobalSettings & ProviderSettings;
1073
- interface RooCodeAPI extends EventEmitter<RooCodeEvents> {
1074
- /**
1075
- * Starts a new task with an optional initial message and images.
1076
- * @param task Optional initial task message.
1077
- * @param images Optional array of image data URIs (e.g., "data:image/webp;base64,...").
1078
- * @returns The ID of the new task.
1079
- */
1080
- startNewTask({ configuration, text, images, newTab, }: {
1081
- configuration?: RooCodeSettings;
1082
- text?: string;
1083
- images?: string[];
1084
- newTab?: boolean;
1085
- }): Promise<string>;
1086
- /**
1087
- * Resumes a task with the given ID.
1088
- * @param taskId The ID of the task to resume.
1089
- * @throws Error if the task is not found in the task history.
1090
- */
1091
- resumeTask(taskId: string): Promise<void>;
1092
- /**
1093
- * Checks if a task with the given ID is in the task history.
1094
- * @param taskId The ID of the task to check.
1095
- * @returns True if the task is in the task history, false otherwise.
1096
- */
1097
- isTaskInHistory(taskId: string): Promise<boolean>;
1098
- /**
1099
- * Returns the current task stack.
1100
- * @returns An array of task IDs.
1101
- */
1102
- getCurrentTaskStack(): string[];
1103
- /**
1104
- * Clears the current task.
1105
- */
1106
- clearCurrentTask(lastMessage?: string): Promise<void>;
1107
- /**
1108
- * Cancels the current task.
1109
- */
1110
- cancelCurrentTask(): Promise<void>;
1111
- /**
1112
- * Sends a message to the current task.
1113
- * @param message Optional message to send.
1114
- * @param images Optional array of image data URIs (e.g., "data:image/webp;base64,...").
1115
- */
1116
- sendMessage(message?: string, images?: string[]): Promise<void>;
1117
- /**
1118
- * Simulates pressing the primary button in the chat interface.
1119
- */
1120
- pressPrimaryButton(): Promise<void>;
1121
- /**
1122
- * Simulates pressing the secondary button in the chat interface.
1123
- */
1124
- pressSecondaryButton(): Promise<void>;
1125
- /**
1126
- * Returns true if the API is ready to use.
1127
- */
1128
- isReady(): boolean;
1129
- /**
1130
- * Returns the current configuration.
1131
- * @returns The current configuration.
1132
- */
1133
- getConfiguration(): RooCodeSettings;
1134
- /**
1135
- * Sets the configuration for the current task.
1136
- * @param values An object containing key-value pairs to set.
1137
- */
1138
- setConfiguration(values: RooCodeSettings): Promise<void>;
1139
- /**
1140
- * Returns a list of all configured profile names
1141
- * @returns Array of profile names
1142
- */
1143
- getProfiles(): string[];
1144
- /**
1145
- * Returns the profile entry for a given name
1146
- * @param name The name of the profile
1147
- * @returns The profile entry, or undefined if the profile does not exist
1148
- */
1149
- getProfileEntry(name: string): ProviderSettingsEntry | undefined;
1150
- /**
1151
- * Creates a new API configuration profile
1152
- * @param name The name of the profile
1153
- * @param profile The profile to create; defaults to an empty object
1154
- * @param activate Whether to activate the profile after creation; defaults to true
1155
- * @returns The ID of the created profile
1156
- * @throws Error if the profile already exists
1157
- */
1158
- createProfile(name: string, profile?: ProviderSettings, activate?: boolean): Promise<string>;
1159
- /**
1160
- * Updates an existing API configuration profile
1161
- * @param name The name of the profile
1162
- * @param profile The profile to update
1163
- * @param activate Whether to activate the profile after update; defaults to true
1164
- * @returns The ID of the updated profile
1165
- * @throws Error if the profile does not exist
1166
- */
1167
- updateProfile(name: string, profile: ProviderSettings, activate?: boolean): Promise<string | undefined>;
1168
- /**
1169
- * Creates a new API configuration profile or updates an existing one
1170
- * @param name The name of the profile
1171
- * @param profile The profile to create or update; defaults to an empty object
1172
- * @param activate Whether to activate the profile after upsert; defaults to true
1173
- * @returns The ID of the upserted profile
1174
- */
1175
- upsertProfile(name: string, profile: ProviderSettings, activate?: boolean): Promise<string | undefined>;
1176
- /**
1177
- * Deletes a profile by name
1178
- * @param name The name of the profile to delete
1179
- * @throws Error if the profile does not exist
1180
- */
1181
- deleteProfile(name: string): Promise<void>;
1182
- /**
1183
- * Returns the name of the currently active profile
1184
- * @returns The profile name, or undefined if no profile is active
1185
- */
1186
- getActiveProfile(): string | undefined;
1187
- /**
1188
- * Changes the active API configuration profile
1189
- * @param name The name of the profile to activate
1190
- * @throws Error if the profile does not exist
1191
- */
1192
- setActiveProfile(name: string): Promise<string | undefined>;
1193
- }
1194
- /**
1195
- * RooCodeIpcServer
1196
- */
1197
- type IpcServerEvents = {
1198
- [IpcMessageType.Connect]: [clientId: string];
1199
- [IpcMessageType.Disconnect]: [clientId: string];
1200
- [IpcMessageType.TaskCommand]: [clientId: string, data: TaskCommand];
1201
- [IpcMessageType.TaskEvent]: [relayClientId: string | undefined, data: TaskEvent];
1202
- };
1203
- interface RooCodeIpcServer extends EventEmitter<IpcServerEvents> {
1204
- listen(): void;
1205
- broadcast(message: IpcMessage): void;
1206
- send(client: string | Socket, message: IpcMessage): void;
1207
- get socketPath(): string;
1208
- get isListening(): boolean;
1209
- }
1210
-
1211
- export { type ClineMessage, type GlobalSettings, type IpcMessage, IpcMessageType, IpcOrigin, type IpcServerEvents, Package, type ProviderName, type ProviderSettings, type ProviderSettingsEntry, type RooCodeAPI, RooCodeEventName, type RooCodeEvents, type RooCodeIpcServer, type RooCodeSettings, type TaskCommand, type TaskEvent, type TokenUsage, providerNames };