@kilocode/sdk 7.4.11 → 7.4.15

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.
@@ -1,7 +1,7 @@
1
1
  export type ClientOptions = {
2
2
  baseUrl: `${string}://${string}` | (string & {});
3
3
  };
4
- export type Event = EventServerInstanceDisposed | EventSessionNetworkAsked | EventSessionNetworkReplied | EventSessionNetworkRejected | EventSessionNetworkRestored | EventBackgroundProcessUpdated | EventBackgroundProcessDeleted | EventInteractiveTerminalUpdated | EventInteractiveTerminalData | EventInteractiveTerminalDeleted | EventSessionTurnOpen | EventSessionTurnClose | EventSandboxStatusChanged | EventSuggestionShown | EventSuggestionAccepted | EventSuggestionDismissed | EventKilocodeAgentManagerStart | EventKilocodeAgentManagerRequested | EventKilocodeAgentManagerCancelled | EventKilocodeNotebookRequested | EventKilocodeNotebookCancelled | EventLspClientDiagnostics | EventKiloSessionsRemoteStatusChanged | EventMemoryStatus1 | EventMemoryUpdated1 | EventMemoryError1 | EventIndexingStatus | EventIndexingWarning | EventServerConnected | EventGlobalDisposed | EventGlobalConfigUpdated | EventPluginAdded | EventCatalogModelUpdated | EventSessionCreated | EventSessionUpdated | EventSessionDeleted | EventMessageUpdated | EventMessageRemoved | EventMessagePartUpdated | EventMessagePartRemoved | EventSessionNextAgentSwitched | EventSessionNextModelSwitched | EventSessionNextMoved | EventSessionNextPrompted | EventSessionNextPromptAdmitted | EventSessionNextPromptPromoted | EventSessionNextContextUpdated | EventSessionNextSynthetic | EventSessionNextShellStarted | EventSessionNextShellEnded | EventSessionNextStepStarted | EventSessionNextStepEnded | EventSessionNextStepFailed | EventSessionNextTextStarted | EventSessionNextTextDelta | EventSessionNextTextEnded | EventSessionNextReasoningStarted | EventSessionNextReasoningDelta | EventSessionNextReasoningEnded | EventSessionNextToolInputStarted | EventSessionNextToolInputDelta | EventSessionNextToolInputEnded | EventSessionNextToolCalled | EventSessionNextToolProgress | EventSessionNextToolSuccess | EventSessionNextToolFailed | EventSessionNextRetried | EventSessionNextCompactionStarted | EventSessionNextCompactionDelta | EventSessionNextCompactionEnded | EventQuestionAsked | EventQuestionReplied | EventQuestionRejected | EventTuiPromptAppend | EventTuiCommandExecute | EventTuiToastShow1 | EventTuiSessionSelect | EventMcpToolsChanged | EventMcpBrowserOpenFailed | EventMessagePartDelta | EventSessionDiff | EventSessionError | EventModelsDevRefreshed | EventInstallationUpdated | EventInstallationUpdateAvailable | EventPermissionAsked | EventPermissionReplied | EventTodoUpdated | EventSessionStatus | EventSessionIdle | EventSessionCompacted | EventCommandExecuted | EventProjectDirectoriesUpdated | EventProjectUpdated | EventLspUpdated | EventFileEdited | EventFileWatcherUpdated | EventVcsBranchUpdated | EventWorkspaceReady | EventWorkspaceFailed | EventWorkspaceStatus | EventWorktreeReady | EventWorktreeFailed | EventAccountAdded | EventAccountRemoved | EventAccountSwitched | EventPermissionV2Asked | EventPermissionV2Replied | EventPtyCreated | EventPtyUpdated | EventPtyExited | EventPtyDeleted | EventQuestionV2Asked | EventQuestionV2Replied | EventQuestionV2Rejected;
4
+ export type Event = EventServerInstanceDisposed | EventSessionNetworkAsked | EventSessionNetworkReplied | EventSessionNetworkRejected | EventSessionNetworkRestored | EventBackgroundProcessUpdated | EventBackgroundProcessDeleted | EventInteractiveTerminalUpdated | EventInteractiveTerminalData | EventInteractiveTerminalDeleted | EventSessionTurnOpen | EventSessionTurnClose | EventSandboxStatusChanged | EventSuggestionShown | EventSuggestionAccepted | EventSuggestionDismissed | EventKilocodeAgentManagerStart | EventKilocodeAgentManagerRequested | EventKilocodeAgentManagerCancelled | EventKilocodeNotebookRequested | EventKilocodeNotebookCancelled | EventLspClientDiagnostics | EventKiloSessionsRemoteStatusChanged | EventMemoryStatus1 | EventMemoryUpdated1 | EventMemoryError1 | EventIndexingStatus | EventIndexingWarning | EventServerConnected | EventGlobalDisposed | EventGlobalConfigUpdated | EventCredentialAdded | EventCredentialRemoved | EventCredentialSwitched | EventPluginAdded | EventCatalogModelUpdated | EventSessionCreated | EventSessionUpdated | EventSessionDeleted | EventMessageUpdated | EventMessageRemoved | EventMessagePartUpdated | EventMessagePartRemoved | EventSessionNextAgentSwitched | EventSessionNextModelSwitched | EventSessionNextMoved | EventSessionNextPrompted | EventSessionNextPromptAdmitted | EventSessionNextPromptPromoted | EventSessionNextInterruptRequested | EventSessionNextContextUpdated | EventSessionNextSynthetic | EventSessionNextShellStarted | EventSessionNextShellEnded | EventSessionNextStepStarted | EventSessionNextStepEnded | EventSessionNextStepFailed | EventSessionNextTextStarted | EventSessionNextTextDelta | EventSessionNextTextEnded | EventSessionNextReasoningStarted | EventSessionNextReasoningDelta | EventSessionNextReasoningEnded | EventSessionNextToolInputStarted | EventSessionNextToolInputDelta | EventSessionNextToolInputEnded | EventSessionNextToolCalled | EventSessionNextToolProgress | EventSessionNextToolSuccess | EventSessionNextToolFailed | EventSessionNextRetried | EventSessionNextCompactionStarted | EventSessionNextCompactionDelta | EventSessionNextCompactionEnded | EventQuestionAsked | EventQuestionReplied | EventQuestionRejected | EventTuiPromptAppend | EventTuiCommandExecute | EventTuiToastShow1 | EventTuiSessionSelect | EventMcpToolsChanged | EventMcpBrowserOpenFailed | EventMessagePartDelta | EventSessionDiff | EventSessionError | EventModelsDevRefreshed | EventInstallationUpdated | EventInstallationUpdateAvailable | EventPermissionAsked | EventPermissionReplied | EventReferenceUpdated | EventConnectorUpdated | EventPermissionV2Asked | EventPermissionV2Replied | EventFileEdited | EventFileWatcherUpdated | EventPtyCreated | EventPtyUpdated | EventPtyExited | EventPtyDeleted | EventQuestionV2Asked | EventQuestionV2Replied | EventQuestionV2Rejected | EventTodoUpdated | EventSessionStatus | EventSessionIdle | EventSessionCompacted | EventCommandExecuted | EventProjectDirectoriesUpdated | EventProjectUpdated | EventLspUpdated | EventVcsBranchUpdated | EventWorkspaceReady | EventWorkspaceFailed | EventWorkspaceStatus | EventWorktreeReady | EventWorktreeFailed;
5
5
  export type QuestionReplied = {
6
6
  sessionID: string;
7
7
  requestID: string;
@@ -136,7 +136,13 @@ export type AgentManagerPromptRequest = {
136
136
  targetSessionID: string;
137
137
  prompt: string;
138
138
  };
139
- export type AgentManagerRequest = AgentManagerOverviewRequest | AgentManagerPromptRequest;
139
+ export type AgentManagerStopRequest = {
140
+ id: AgentManagerRequestId;
141
+ sessionID: string;
142
+ operation: "stop";
143
+ targetSessionID: string;
144
+ };
145
+ export type AgentManagerRequest = AgentManagerOverviewRequest | AgentManagerPromptRequest | AgentManagerStopRequest;
140
146
  export type NotebookRequestId = string;
141
147
  export type NotebookReadRequest = {
142
148
  id: NotebookRequestId;
@@ -265,6 +271,7 @@ export type Session = {
265
271
  partID?: string;
266
272
  snapshot?: string;
267
273
  diff?: string;
274
+ workspace?: "restored" | "snapshots-disabled" | "unavailable";
268
275
  };
269
276
  };
270
277
  export type OutputFormatText = {
@@ -349,6 +356,12 @@ export type ContextOverflowError = {
349
356
  responseBody?: string;
350
357
  };
351
358
  };
359
+ export type ContentFilterError = {
360
+ name: "ContentFilterError";
361
+ data: {
362
+ message: string;
363
+ };
364
+ };
352
365
  export type ApiError = {
353
366
  name: "APIError";
354
367
  data: {
@@ -372,7 +385,7 @@ export type AssistantMessage = {
372
385
  created: number;
373
386
  completed?: number;
374
387
  };
375
- error?: ProviderAuthError | UnknownError | MessageOutputLengthError | MessageAbortedError | StructuredOutputError | ContextOverflowError | ApiError;
388
+ error?: ProviderAuthError | UnknownError | MessageOutputLengthError | MessageAbortedError | StructuredOutputError | ContextOverflowError | ContentFilterError | ApiError;
376
389
  parentID: string;
377
390
  modelID: string;
378
391
  providerID: string;
@@ -634,7 +647,6 @@ export type Prompt = {
634
647
  text: string;
635
648
  files?: Array<PromptFileAttachment>;
636
649
  agents?: Array<PromptAgentAttachment>;
637
- references?: Array<PromptReferenceAttachment>;
638
650
  };
639
651
  export type QuestionOption = {
640
652
  /**
@@ -729,6 +741,30 @@ export type AgentRequirementError = {
729
741
  }>;
730
742
  };
731
743
  };
744
+ export type Pty = {
745
+ id: string;
746
+ title: string;
747
+ command: string;
748
+ args: Array<string>;
749
+ cwd: string;
750
+ status: "running" | "exited";
751
+ pid: number;
752
+ sessionID?: string | null;
753
+ };
754
+ export type Todo = {
755
+ /**
756
+ * Brief description of the task
757
+ */
758
+ content: string;
759
+ /**
760
+ * Current status of the task: pending, in_progress, completed, cancelled
761
+ */
762
+ status: string;
763
+ /**
764
+ * Priority level of the task: high, medium, low
765
+ */
766
+ priority: string;
767
+ };
732
768
  export type SessionStatus = {
733
769
  type: "idle";
734
770
  } | {
@@ -751,21 +787,11 @@ export type SessionStatus = {
751
787
  requestID: string;
752
788
  message: string;
753
789
  };
754
- export type Pty = {
755
- id: string;
756
- title: string;
757
- command: string;
758
- args: Array<string>;
759
- cwd: string;
760
- status: "running" | "exited";
761
- pid: number;
762
- sessionID?: string | null;
763
- };
764
790
  export type GlobalEvent = {
765
791
  directory: string;
766
792
  project?: string;
767
793
  workspace?: string;
768
- payload: EventServerInstanceDisposed | EventSessionNetworkAsked | EventSessionNetworkReplied | EventSessionNetworkRejected | EventSessionNetworkRestored | EventBackgroundProcessUpdated | EventBackgroundProcessDeleted | EventInteractiveTerminalUpdated | EventInteractiveTerminalData | EventInteractiveTerminalDeleted | EventSessionTurnOpen | EventSessionTurnClose | EventSandboxStatusChanged | EventSuggestionShown | EventSuggestionAccepted | EventSuggestionDismissed | EventKilocodeAgentManagerStart | EventKilocodeAgentManagerRequested | EventKilocodeAgentManagerCancelled | EventKilocodeNotebookRequested | EventKilocodeNotebookCancelled | EventLspClientDiagnostics | EventKiloSessionsRemoteStatusChanged | EventMemoryStatus | EventMemoryUpdated | EventMemoryError | EventIndexingStatus | EventIndexingWarning | EventServerConnected | EventGlobalDisposed | EventGlobalConfigUpdated | EventPluginAdded | EventCatalogModelUpdated | EventSessionCreated | EventSessionUpdated | EventSessionDeleted | EventMessageUpdated | EventMessageRemoved | EventMessagePartUpdated | EventMessagePartRemoved | EventSessionNextAgentSwitched | EventSessionNextModelSwitched | EventSessionNextMoved | EventSessionNextPrompted | EventSessionNextPromptAdmitted | EventSessionNextPromptPromoted | EventSessionNextContextUpdated | EventSessionNextSynthetic | EventSessionNextShellStarted | EventSessionNextShellEnded | EventSessionNextStepStarted | EventSessionNextStepEnded | EventSessionNextStepFailed | EventSessionNextTextStarted | EventSessionNextTextDelta | EventSessionNextTextEnded | EventSessionNextReasoningStarted | EventSessionNextReasoningDelta | EventSessionNextReasoningEnded | EventSessionNextToolInputStarted | EventSessionNextToolInputDelta | EventSessionNextToolInputEnded | EventSessionNextToolCalled | EventSessionNextToolProgress | EventSessionNextToolSuccess | EventSessionNextToolFailed | EventSessionNextRetried | EventSessionNextCompactionStarted | EventSessionNextCompactionDelta | EventSessionNextCompactionEnded | EventQuestionAsked | EventQuestionReplied | EventQuestionRejected | EventTuiPromptAppend | EventTuiCommandExecute | EventTuiToastShow | EventTuiSessionSelect | EventMcpToolsChanged | EventMcpBrowserOpenFailed | EventMessagePartDelta | EventSessionDiff | EventSessionError | EventModelsDevRefreshed | EventInstallationUpdated | EventInstallationUpdateAvailable | EventPermissionAsked | EventPermissionReplied | EventTodoUpdated | EventSessionStatus | EventSessionIdle | EventSessionCompacted | EventCommandExecuted | EventProjectDirectoriesUpdated | EventProjectUpdated | EventLspUpdated | EventFileEdited | EventFileWatcherUpdated | EventVcsBranchUpdated | EventWorkspaceReady | EventWorkspaceFailed | EventWorkspaceStatus | EventWorktreeReady | EventWorktreeFailed | EventAccountAdded | EventAccountRemoved | EventAccountSwitched | EventPermissionV2Asked | EventPermissionV2Replied | EventPtyCreated | EventPtyUpdated | EventPtyExited | EventPtyDeleted | EventQuestionV2Asked | EventQuestionV2Replied | EventQuestionV2Rejected | SyncEventSessionCreated | SyncEventSessionUpdated | SyncEventSessionDeleted | SyncEventMessageUpdated | SyncEventMessageRemoved | SyncEventMessagePartUpdated | SyncEventMessagePartRemoved | SyncEventSessionNextAgentSwitched | SyncEventSessionNextModelSwitched | SyncEventSessionNextMoved | SyncEventSessionNextPrompted | SyncEventSessionNextPromptAdmitted | SyncEventSessionNextPromptPromoted | SyncEventSessionNextContextUpdated | SyncEventSessionNextSynthetic | SyncEventSessionNextShellStarted | SyncEventSessionNextShellEnded | SyncEventSessionNextStepStarted | SyncEventSessionNextStepEnded | SyncEventSessionNextStepFailed | SyncEventSessionNextTextStarted | SyncEventSessionNextTextEnded | SyncEventSessionNextReasoningStarted | SyncEventSessionNextReasoningEnded | SyncEventSessionNextToolInputStarted | SyncEventSessionNextToolInputEnded | SyncEventSessionNextToolCalled | SyncEventSessionNextToolProgress | SyncEventSessionNextToolSuccess | SyncEventSessionNextToolFailed | SyncEventSessionNextRetried | SyncEventSessionNextCompactionStarted | SyncEventSessionNextCompactionDelta | SyncEventSessionNextCompactionEnded;
794
+ payload: EventServerInstanceDisposed | EventSessionNetworkAsked | EventSessionNetworkReplied | EventSessionNetworkRejected | EventSessionNetworkRestored | EventBackgroundProcessUpdated | EventBackgroundProcessDeleted | EventInteractiveTerminalUpdated | EventInteractiveTerminalData | EventInteractiveTerminalDeleted | EventSessionTurnOpen | EventSessionTurnClose | EventSandboxStatusChanged | EventSuggestionShown | EventSuggestionAccepted | EventSuggestionDismissed | EventKilocodeAgentManagerStart | EventKilocodeAgentManagerRequested | EventKilocodeAgentManagerCancelled | EventKilocodeNotebookRequested | EventKilocodeNotebookCancelled | EventLspClientDiagnostics | EventKiloSessionsRemoteStatusChanged | EventMemoryStatus | EventMemoryUpdated | EventMemoryError | EventIndexingStatus | EventIndexingWarning | EventServerConnected | EventGlobalDisposed | EventGlobalConfigUpdated | EventCredentialAdded | EventCredentialRemoved | EventCredentialSwitched | EventPluginAdded | EventCatalogModelUpdated | EventSessionCreated | EventSessionUpdated | EventSessionDeleted | EventMessageUpdated | EventMessageRemoved | EventMessagePartUpdated | EventMessagePartRemoved | EventSessionNextAgentSwitched | EventSessionNextModelSwitched | EventSessionNextMoved | EventSessionNextPrompted | EventSessionNextPromptAdmitted | EventSessionNextPromptPromoted | EventSessionNextInterruptRequested | EventSessionNextContextUpdated | EventSessionNextSynthetic | EventSessionNextShellStarted | EventSessionNextShellEnded | EventSessionNextStepStarted | EventSessionNextStepEnded | EventSessionNextStepFailed | EventSessionNextTextStarted | EventSessionNextTextDelta | EventSessionNextTextEnded | EventSessionNextReasoningStarted | EventSessionNextReasoningDelta | EventSessionNextReasoningEnded | EventSessionNextToolInputStarted | EventSessionNextToolInputDelta | EventSessionNextToolInputEnded | EventSessionNextToolCalled | EventSessionNextToolProgress | EventSessionNextToolSuccess | EventSessionNextToolFailed | EventSessionNextRetried | EventSessionNextCompactionStarted | EventSessionNextCompactionDelta | EventSessionNextCompactionEnded | EventQuestionAsked | EventQuestionReplied | EventQuestionRejected | EventTuiPromptAppend | EventTuiCommandExecute | EventTuiToastShow | EventTuiSessionSelect | EventMcpToolsChanged | EventMcpBrowserOpenFailed | EventMessagePartDelta | EventSessionDiff | EventSessionError | EventModelsDevRefreshed | EventInstallationUpdated | EventInstallationUpdateAvailable | EventPermissionAsked | EventPermissionReplied | EventReferenceUpdated | EventConnectorUpdated | EventPermissionV2Asked | EventPermissionV2Replied | EventFileEdited | EventFileWatcherUpdated | EventPtyCreated | EventPtyUpdated | EventPtyExited | EventPtyDeleted | EventQuestionV2Asked | EventQuestionV2Replied | EventQuestionV2Rejected | EventTodoUpdated | EventSessionStatus | EventSessionIdle | EventSessionCompacted | EventCommandExecuted | EventProjectDirectoriesUpdated | EventProjectUpdated | EventLspUpdated | EventVcsBranchUpdated | EventWorkspaceReady | EventWorkspaceFailed | EventWorkspaceStatus | EventWorktreeReady | EventWorktreeFailed | SyncEventSessionCreated | SyncEventSessionUpdated | SyncEventSessionDeleted | SyncEventMessageUpdated | SyncEventMessageRemoved | SyncEventMessagePartUpdated | SyncEventMessagePartRemoved | SyncEventSessionNextAgentSwitched | SyncEventSessionNextModelSwitched | SyncEventSessionNextMoved | SyncEventSessionNextPrompted | SyncEventSessionNextPromptAdmitted | SyncEventSessionNextPromptPromoted | SyncEventSessionNextContextUpdated | SyncEventSessionNextSynthetic | SyncEventSessionNextShellStarted | SyncEventSessionNextShellEnded | SyncEventSessionNextStepStarted | SyncEventSessionNextStepEnded | SyncEventSessionNextStepFailed | SyncEventSessionNextTextStarted | SyncEventSessionNextTextEnded | SyncEventSessionNextReasoningStarted | SyncEventSessionNextReasoningEnded | SyncEventSessionNextToolInputStarted | SyncEventSessionNextToolInputEnded | SyncEventSessionNextToolCalled | SyncEventSessionNextToolProgress | SyncEventSessionNextToolSuccess | SyncEventSessionNextToolFailed | SyncEventSessionNextRetried | SyncEventSessionNextCompactionStarted | SyncEventSessionNextCompactionEnded;
769
795
  };
770
796
  /**
771
797
  * Log level
@@ -781,21 +807,6 @@ export type ServerConfig = {
781
807
  mdnsDomain?: string;
782
808
  cors?: Array<string>;
783
809
  };
784
- export type ReferenceConfigEntry = string | {
785
- /**
786
- * Git repository URL, host/path reference, or GitHub owner/repo shorthand
787
- */
788
- repository: string;
789
- branch?: string;
790
- } | {
791
- /**
792
- * Absolute path, ~/ path, or workspace-relative path to a local reference directory
793
- */
794
- path: string;
795
- };
796
- export type ReferenceConfig = {
797
- [key: string]: ReferenceConfigEntry;
798
- };
799
810
  export type IndexingConfig = {
800
811
  enabled?: boolean;
801
812
  provider?: "kilo" | "openai" | "ollama" | "openai-compatible" | "gemini" | "mistral" | "vercel-ai-gateway" | "bedrock" | "openrouter" | "voyage";
@@ -848,6 +859,7 @@ export type IndexingConfig = {
848
859
  searchMaxResults?: number;
849
860
  embeddingBatchSize?: number;
850
861
  scannerMaxBatchRetries?: number;
862
+ fileExtensions?: Array<string>;
851
863
  };
852
864
  export type PermissionActionConfig = "ask" | "allow" | "deny";
853
865
  export type PermissionObjectConfig = {
@@ -943,8 +955,11 @@ export type ProviderConfig = {
943
955
  * Timeout in milliseconds to wait for response headers. Provider integrations may set defaults. Set to false to disable timeout.
944
956
  */
945
957
  headerTimeout?: number | false;
946
- chunkTimeout?: number;
947
- [key: string]: unknown | string | boolean | number | false | number | false | number | undefined;
958
+ /**
959
+ * Timeout in milliseconds between streamed SSE chunks for this provider. If no chunk arrives within this window, the request is aborted. Set to false to disable the idle watchdog.
960
+ */
961
+ chunkTimeout?: number | false;
962
+ [key: string]: unknown | string | boolean | number | false | number | false | number | false | undefined;
948
963
  };
949
964
  models?: {
950
965
  [key: string]: {
@@ -960,7 +975,7 @@ export type ProviderConfig = {
960
975
  temperature?: boolean;
961
976
  tool_call?: boolean;
962
977
  interleaved?: true | {
963
- field: "reasoning_content" | "reasoning_details";
978
+ field: "reasoning" | "reasoning_content" | "reasoning_details";
964
979
  };
965
980
  cost?: {
966
981
  input: number;
@@ -1077,7 +1092,12 @@ export type Config = {
1077
1092
  paths?: Array<string>;
1078
1093
  urls?: Array<string>;
1079
1094
  };
1080
- reference?: ReferenceConfig;
1095
+ references?: {
1096
+ [key: string]: string | ConfigV2ReferenceGit | ConfigV2ReferenceLocal;
1097
+ };
1098
+ reference?: {
1099
+ [key: string]: string | ConfigV2ReferenceGit | ConfigV2ReferenceLocal;
1100
+ };
1081
1101
  watcher?: {
1082
1102
  ignore?: Array<string>;
1083
1103
  };
@@ -1276,7 +1296,7 @@ export type Model = {
1276
1296
  pdf: boolean;
1277
1297
  };
1278
1298
  interleaved: boolean | {
1279
- field: "reasoning_content" | "reasoning_details";
1299
+ field: "reasoning" | "reasoning_content" | "reasoning_details";
1280
1300
  };
1281
1301
  };
1282
1302
  cost: {
@@ -1475,6 +1495,7 @@ export type GlobalSession = {
1475
1495
  partID?: string;
1476
1496
  snapshot?: string;
1477
1497
  diff?: string;
1498
+ workspace?: "restored" | "snapshots-disabled" | "unavailable";
1478
1499
  };
1479
1500
  project: ProjectSummary | null;
1480
1501
  worktreeName?: string;
@@ -1670,6 +1691,7 @@ export type ProjectCopyError = {
1670
1691
  name: "ProjectCopyError";
1671
1692
  data: {
1672
1693
  message: string;
1694
+ forceRequired?: boolean;
1673
1695
  };
1674
1696
  };
1675
1697
  export type PtyNotFoundError = {
@@ -1808,6 +1830,7 @@ export type Session1 = {
1808
1830
  partID?: string;
1809
1831
  snapshot?: string;
1810
1832
  diff?: string;
1833
+ workspace?: "restored" | "snapshots-disabled" | "unavailable";
1811
1834
  };
1812
1835
  };
1813
1836
  export type Session2 = {
@@ -1860,6 +1883,7 @@ export type Session2 = {
1860
1883
  partID?: string;
1861
1884
  snapshot?: string;
1862
1885
  diff?: string;
1886
+ workspace?: "restored" | "snapshots-disabled" | "unavailable";
1863
1887
  };
1864
1888
  };
1865
1889
  export type NotFoundError = {
@@ -1868,20 +1892,6 @@ export type NotFoundError = {
1868
1892
  message: string;
1869
1893
  };
1870
1894
  };
1871
- export type Todo = {
1872
- /**
1873
- * Brief description of the task
1874
- */
1875
- content: string;
1876
- /**
1877
- * Current status of the task: pending, in_progress, completed, cancelled
1878
- */
1879
- status: string;
1880
- /**
1881
- * Priority level of the task: high, medium, low
1882
- */
1883
- priority: string;
1884
- };
1885
1895
  export type Session3 = {
1886
1896
  id: string;
1887
1897
  slug: string;
@@ -1932,6 +1942,7 @@ export type Session3 = {
1932
1942
  partID?: string;
1933
1943
  snapshot?: string;
1934
1944
  diff?: string;
1945
+ workspace?: "restored" | "snapshots-disabled" | "unavailable";
1935
1946
  };
1936
1947
  };
1937
1948
  export type Session4 = {
@@ -1984,6 +1995,7 @@ export type Session4 = {
1984
1995
  partID?: string;
1985
1996
  snapshot?: string;
1986
1997
  diff?: string;
1998
+ workspace?: "restored" | "snapshots-disabled" | "unavailable";
1987
1999
  };
1988
2000
  };
1989
2001
  export type Session5 = {
@@ -2036,6 +2048,7 @@ export type Session5 = {
2036
2048
  partID?: string;
2037
2049
  snapshot?: string;
2038
2050
  diff?: string;
2051
+ workspace?: "restored" | "snapshots-disabled" | "unavailable";
2039
2052
  };
2040
2053
  };
2041
2054
  export type Session6 = {
@@ -2088,6 +2101,7 @@ export type Session6 = {
2088
2101
  partID?: string;
2089
2102
  snapshot?: string;
2090
2103
  diff?: string;
2104
+ workspace?: "restored" | "snapshots-disabled" | "unavailable";
2091
2105
  };
2092
2106
  };
2093
2107
  export type Session7 = {
@@ -2140,6 +2154,7 @@ export type Session7 = {
2140
2154
  partID?: string;
2141
2155
  snapshot?: string;
2142
2156
  diff?: string;
2157
+ workspace?: "restored" | "snapshots-disabled" | "unavailable";
2143
2158
  };
2144
2159
  };
2145
2160
  export type TextPartInput = {
@@ -2241,6 +2256,7 @@ export type Session8 = {
2241
2256
  partID?: string;
2242
2257
  snapshot?: string;
2243
2258
  diff?: string;
2259
+ workspace?: "restored" | "snapshots-disabled" | "unavailable";
2244
2260
  };
2245
2261
  };
2246
2262
  export type Session9 = {
@@ -2293,6 +2309,7 @@ export type Session9 = {
2293
2309
  partID?: string;
2294
2310
  snapshot?: string;
2295
2311
  diff?: string;
2312
+ workspace?: "restored" | "snapshots-disabled" | "unavailable";
2296
2313
  };
2297
2314
  };
2298
2315
  export type EventTuiPromptAppend2 = {
@@ -2526,6 +2543,9 @@ export type EffectHttpApiErrorUnauthorized = {
2526
2543
  export type EffectHttpApiErrorServiceUnavailable = {
2527
2544
  _tag: "ServiceUnavailable";
2528
2545
  };
2546
+ export type CloudSessionImportError = {
2547
+ error: string;
2548
+ };
2529
2549
  export type AgentRequirementResult = {
2530
2550
  agent: string;
2531
2551
  directory: string;
@@ -2685,7 +2705,12 @@ export type AgentManagerPromptResult = {
2685
2705
  sessionID: string;
2686
2706
  delivered: true;
2687
2707
  };
2688
- export type AgentManagerResult = AgentManagerOverviewResult | AgentManagerPromptResult;
2708
+ export type AgentManagerStopResult = {
2709
+ operation: "stop";
2710
+ sessionID: string;
2711
+ stopped: true;
2712
+ };
2713
+ export type AgentManagerResult = AgentManagerOverviewResult | AgentManagerPromptResult | AgentManagerStopResult;
2689
2714
  export type AgentManagerFailure = {
2690
2715
  code: "cancelled" | "cross_workspace" | "disconnected" | "host_error" | "stale_session" | "timeout" | "unavailable_session" | "unknown_session" | "workspace_unavailable";
2691
2716
  message: string;
@@ -2759,7 +2784,7 @@ export type UnauthorizedError = {
2759
2784
  _tag: "UnauthorizedError";
2760
2785
  message: string;
2761
2786
  };
2762
- export type V2SessionsResponse = {
2787
+ export type SessionsResponse = {
2763
2788
  data: Array<SessionV2Info>;
2764
2789
  cursor: {
2765
2790
  previous?: string;
@@ -2785,7 +2810,7 @@ export type UnknownError1 = {
2785
2810
  message: string;
2786
2811
  ref?: string;
2787
2812
  };
2788
- export type V2SessionMessagesResponse = {
2813
+ export type SessionMessagesResponse = {
2789
2814
  data: Array<SessionMessage>;
2790
2815
  cursor: {
2791
2816
  previous?: string;
@@ -3168,6 +3193,53 @@ export type EventGlobalConfigUpdated = {
3168
3193
  [key: string]: unknown;
3169
3194
  };
3170
3195
  };
3196
+ export type CredentialOAuth = {
3197
+ type: "oauth";
3198
+ refresh: string;
3199
+ access: string;
3200
+ expires: number;
3201
+ metadata?: {
3202
+ [key: string]: string;
3203
+ };
3204
+ };
3205
+ export type CredentialKey = {
3206
+ type: "key";
3207
+ key: string;
3208
+ metadata?: {
3209
+ [key: string]: string;
3210
+ };
3211
+ };
3212
+ export type CredentialValue = CredentialOAuth | CredentialKey;
3213
+ export type CredentialInfo = {
3214
+ id: string;
3215
+ connectorID: string;
3216
+ methodID: string;
3217
+ label: string;
3218
+ value: CredentialValue;
3219
+ };
3220
+ export type EventCredentialAdded = {
3221
+ id: string;
3222
+ type: "credential.added";
3223
+ properties: {
3224
+ credential: CredentialInfo;
3225
+ };
3226
+ };
3227
+ export type EventCredentialRemoved = {
3228
+ id: string;
3229
+ type: "credential.removed";
3230
+ properties: {
3231
+ credential: CredentialInfo;
3232
+ };
3233
+ };
3234
+ export type EventCredentialSwitched = {
3235
+ id: string;
3236
+ type: "credential.switched";
3237
+ properties: {
3238
+ connectorID: string;
3239
+ from?: string;
3240
+ to?: string;
3241
+ };
3242
+ };
3171
3243
  export type EventPluginAdded = {
3172
3244
  id: string;
3173
3245
  type: "plugin.added";
@@ -3208,6 +3280,19 @@ export type ModelV2Info = {
3208
3280
  body: {
3209
3281
  [key: string]: unknown;
3210
3282
  };
3283
+ generation?: {
3284
+ maxTokens?: number | "NaN" | "Infinity" | "-Infinity" | "Infinity" | "-Infinity" | "NaN";
3285
+ temperature?: number | "NaN" | "Infinity" | "-Infinity" | "Infinity" | "-Infinity" | "NaN";
3286
+ topP?: number | "NaN" | "Infinity" | "-Infinity" | "Infinity" | "-Infinity" | "NaN";
3287
+ topK?: number | "NaN" | "Infinity" | "-Infinity" | "Infinity" | "-Infinity" | "NaN";
3288
+ frequencyPenalty?: number | "NaN" | "Infinity" | "-Infinity" | "Infinity" | "-Infinity" | "NaN";
3289
+ presencePenalty?: number | "NaN" | "Infinity" | "-Infinity" | "Infinity" | "-Infinity" | "NaN";
3290
+ seed?: number | "NaN" | "Infinity" | "-Infinity" | "Infinity" | "-Infinity" | "NaN";
3291
+ stop?: Array<string>;
3292
+ };
3293
+ options?: {
3294
+ [key: string]: unknown;
3295
+ };
3211
3296
  variant?: string;
3212
3297
  };
3213
3298
  variants: Array<{
@@ -3218,6 +3303,19 @@ export type ModelV2Info = {
3218
3303
  body: {
3219
3304
  [key: string]: unknown;
3220
3305
  };
3306
+ generation?: {
3307
+ maxTokens?: number | "NaN" | "Infinity" | "-Infinity" | "Infinity" | "-Infinity" | "NaN";
3308
+ temperature?: number | "NaN" | "Infinity" | "-Infinity" | "Infinity" | "-Infinity" | "NaN";
3309
+ topP?: number | "NaN" | "Infinity" | "-Infinity" | "Infinity" | "-Infinity" | "NaN";
3310
+ topK?: number | "NaN" | "Infinity" | "-Infinity" | "Infinity" | "-Infinity" | "NaN";
3311
+ frequencyPenalty?: number | "NaN" | "Infinity" | "-Infinity" | "Infinity" | "-Infinity" | "NaN";
3312
+ presencePenalty?: number | "NaN" | "Infinity" | "-Infinity" | "Infinity" | "-Infinity" | "NaN";
3313
+ seed?: number | "NaN" | "Infinity" | "-Infinity" | "Infinity" | "-Infinity" | "NaN";
3314
+ stop?: Array<string>;
3315
+ };
3316
+ options?: {
3317
+ [key: string]: unknown;
3318
+ };
3221
3319
  }>;
3222
3320
  time: {
3223
3321
  released: number | "NaN" | "Infinity" | "-Infinity" | "Infinity" | "-Infinity" | "NaN";
@@ -3361,17 +3459,6 @@ export type PromptAgentAttachment = {
3361
3459
  name: string;
3362
3460
  source?: PromptSource;
3363
3461
  };
3364
- export type PromptReferenceAttachment = {
3365
- name: string;
3366
- kind: "local" | "git" | "invalid";
3367
- uri?: string;
3368
- repository?: string;
3369
- branch?: string;
3370
- target?: string;
3371
- targetUri?: string;
3372
- problem?: string;
3373
- source?: PromptSource;
3374
- };
3375
3462
  export type EventSessionNextPrompted = {
3376
3463
  id: string;
3377
3464
  type: "session.next.prompted";
@@ -3405,6 +3492,14 @@ export type EventSessionNextPromptPromoted = {
3405
3492
  timeCreated: number;
3406
3493
  };
3407
3494
  };
3495
+ export type EventSessionNextInterruptRequested = {
3496
+ id: string;
3497
+ type: "session.next.interrupt.requested";
3498
+ properties: {
3499
+ timestamp: number;
3500
+ sessionID: string;
3501
+ };
3502
+ };
3408
3503
  export type EventSessionNextContextUpdated = {
3409
3504
  id: string;
3410
3505
  type: "session.next.context.updated";
@@ -3632,16 +3727,7 @@ export type ToolTextContent = {
3632
3727
  };
3633
3728
  export type ToolFileContent = {
3634
3729
  type: "file";
3635
- source: {
3636
- type: "data";
3637
- data: string;
3638
- } | {
3639
- type: "url";
3640
- url: string;
3641
- } | {
3642
- type: "file";
3643
- uri: string;
3644
- };
3730
+ uri: string;
3645
3731
  mime: string;
3646
3732
  name?: string;
3647
3733
  };
@@ -3671,6 +3757,7 @@ export type EventSessionNextToolSuccess = {
3671
3757
  [key: string]: unknown;
3672
3758
  };
3673
3759
  content: Array<ToolTextContent | ToolFileContent>;
3760
+ outputPaths?: Array<string>;
3674
3761
  result?: unknown;
3675
3762
  provider: {
3676
3763
  executed: boolean;
@@ -3740,6 +3827,7 @@ export type EventSessionNextCompactionDelta = {
3740
3827
  properties: {
3741
3828
  timestamp: number;
3742
3829
  sessionID: string;
3830
+ messageID: string;
3743
3831
  text: string;
3744
3832
  };
3745
3833
  };
@@ -3749,7 +3837,10 @@ export type EventSessionNextCompactionEnded = {
3749
3837
  properties: {
3750
3838
  timestamp: number;
3751
3839
  sessionID: string;
3840
+ messageID?: string;
3841
+ reason?: "auto" | "manual";
3752
3842
  text: string;
3843
+ recent?: string;
3753
3844
  include?: string;
3754
3845
  };
3755
3846
  };
@@ -3823,7 +3914,7 @@ export type EventSessionError = {
3823
3914
  type: "session.error";
3824
3915
  properties: {
3825
3916
  sessionID?: string;
3826
- error?: ProviderAuthError | UnknownError | MessageOutputLengthError | MessageAbortedError | StructuredOutputError | ContextOverflowError | ApiError | AgentRequirementError;
3917
+ error?: ProviderAuthError | UnknownError | MessageOutputLengthError | MessageAbortedError | StructuredOutputError | ContextOverflowError | ContentFilterError | ApiError | AgentRequirementError;
3827
3918
  };
3828
3919
  };
3829
3920
  export type EventModelsDevRefreshed = {
@@ -3874,99 +3965,48 @@ export type EventPermissionReplied = {
3874
3965
  reply: "once" | "always" | "reject";
3875
3966
  };
3876
3967
  };
3877
- export type SessionTodoInfo = {
3878
- /**
3879
- * Brief description of the task
3880
- */
3881
- content: string;
3882
- /**
3883
- * Current status of the task: pending, in_progress, completed, cancelled
3884
- */
3885
- status: string;
3886
- /**
3887
- * Priority level of the task: high, medium, low
3888
- */
3889
- priority: string;
3890
- };
3891
- export type EventTodoUpdated = {
3892
- id: string;
3893
- type: "todo.updated";
3894
- properties: {
3895
- sessionID: string;
3896
- todos: Array<SessionTodoInfo>;
3897
- };
3898
- };
3899
- export type EventSessionStatus = {
3900
- id: string;
3901
- type: "session.status";
3902
- properties: {
3903
- sessionID: string;
3904
- status: SessionStatus;
3905
- };
3906
- };
3907
- export type EventSessionIdle = {
3908
- id: string;
3909
- type: "session.idle";
3910
- properties: {
3911
- sessionID: string;
3912
- };
3913
- };
3914
- export type EventSessionCompacted = {
3968
+ export type EventReferenceUpdated = {
3915
3969
  id: string;
3916
- type: "session.compacted";
3970
+ type: "reference.updated";
3917
3971
  properties: {
3918
- sessionID: string;
3972
+ [key: string]: unknown;
3919
3973
  };
3920
3974
  };
3921
- export type EventCommandExecuted = {
3975
+ export type EventConnectorUpdated = {
3922
3976
  id: string;
3923
- type: "command.executed";
3977
+ type: "connector.updated";
3924
3978
  properties: {
3925
- name: string;
3926
- sessionID: string;
3927
- arguments: string;
3928
- messageID: string;
3979
+ [key: string]: unknown;
3929
3980
  };
3930
3981
  };
3931
- export type EventProjectDirectoriesUpdated = {
3932
- id: string;
3933
- type: "project.directories.updated";
3934
- properties: {
3935
- projectID: string;
3936
- };
3982
+ export type PermissionV2Source = {
3983
+ type: "tool";
3984
+ messageID: string;
3985
+ callID: string;
3937
3986
  };
3938
- export type EventProjectUpdated = {
3987
+ export type EventPermissionV2Asked = {
3939
3988
  id: string;
3940
- type: "project.updated";
3989
+ type: "permission.v2.asked";
3941
3990
  properties: {
3942
3991
  id: string;
3943
- worktree: string;
3944
- vcs?: "git";
3945
- name?: string;
3946
- icon?: {
3947
- url?: string;
3948
- override?: string;
3949
- color?: string;
3950
- };
3951
- commands?: {
3952
- /**
3953
- * Startup script to run when creating a new workspace (worktree)
3954
- */
3955
- start?: string;
3956
- };
3957
- time: {
3958
- created: number;
3959
- updated: number;
3960
- initialized?: number;
3992
+ sessionID: string;
3993
+ action: string;
3994
+ resources: Array<string>;
3995
+ save?: Array<string>;
3996
+ metadata?: {
3997
+ [key: string]: unknown;
3961
3998
  };
3962
- sandboxes: Array<string>;
3999
+ source?: PermissionV2Source;
3963
4000
  };
3964
4001
  };
3965
- export type EventLspUpdated = {
4002
+ export type PermissionV2Reply = "once" | "always" | "reject";
4003
+ export type EventPermissionV2Replied = {
3966
4004
  id: string;
3967
- type: "lsp.updated";
4005
+ type: "permission.v2.replied";
3968
4006
  properties: {
3969
- [key: string]: unknown;
4007
+ sessionID: string;
4008
+ requestID: string;
4009
+ reply: PermissionV2Reply;
3970
4010
  };
3971
4011
  };
3972
4012
  export type EventFileEdited = {
@@ -3984,151 +4024,33 @@ export type EventFileWatcherUpdated = {
3984
4024
  event: "add" | "change" | "unlink";
3985
4025
  };
3986
4026
  };
3987
- export type EventVcsBranchUpdated = {
3988
- id: string;
3989
- type: "vcs.branch.updated";
3990
- properties: {
3991
- branch?: string;
3992
- };
3993
- };
3994
- export type EventWorkspaceReady = {
4027
+ export type EventPtyCreated = {
3995
4028
  id: string;
3996
- type: "workspace.ready";
4029
+ type: "pty.created";
3997
4030
  properties: {
3998
- name: string;
4031
+ info: Pty;
3999
4032
  };
4000
4033
  };
4001
- export type EventWorkspaceFailed = {
4034
+ export type EventPtyUpdated = {
4002
4035
  id: string;
4003
- type: "workspace.failed";
4036
+ type: "pty.updated";
4004
4037
  properties: {
4005
- message: string;
4038
+ info: Pty;
4006
4039
  };
4007
4040
  };
4008
- export type EventWorkspaceStatus = {
4041
+ export type EventPtyExited = {
4009
4042
  id: string;
4010
- type: "workspace.status";
4043
+ type: "pty.exited";
4011
4044
  properties: {
4012
- workspaceID: string;
4013
- status: "connected" | "connecting" | "disconnected" | "error";
4045
+ id: string;
4046
+ exitCode: number;
4014
4047
  };
4015
4048
  };
4016
- export type EventWorktreeReady = {
4049
+ export type EventPtyDeleted = {
4017
4050
  id: string;
4018
- type: "worktree.ready";
4051
+ type: "pty.deleted";
4019
4052
  properties: {
4020
- name: string;
4021
- branch?: string;
4022
- };
4023
- };
4024
- export type EventWorktreeFailed = {
4025
- id: string;
4026
- type: "worktree.failed";
4027
- properties: {
4028
- message: string;
4029
- };
4030
- };
4031
- export type AuthOAuthCredential = {
4032
- type: "oauth";
4033
- refresh: string;
4034
- access: string;
4035
- expires: number;
4036
- accountId?: string;
4037
- };
4038
- export type AuthApiKeyCredential = {
4039
- type: "api";
4040
- key: string;
4041
- metadata?: {
4042
- [key: string]: string;
4043
- };
4044
- };
4045
- export type AuthCredential = AuthOAuthCredential | AuthApiKeyCredential;
4046
- export type AuthInfo = {
4047
- id: string;
4048
- serviceID: string;
4049
- description: string;
4050
- credential: AuthCredential;
4051
- };
4052
- export type EventAccountAdded = {
4053
- id: string;
4054
- type: "account.added";
4055
- properties: {
4056
- account: AuthInfo;
4057
- };
4058
- };
4059
- export type EventAccountRemoved = {
4060
- id: string;
4061
- type: "account.removed";
4062
- properties: {
4063
- account: AuthInfo;
4064
- };
4065
- };
4066
- export type EventAccountSwitched = {
4067
- id: string;
4068
- type: "account.switched";
4069
- properties: {
4070
- serviceID: string;
4071
- from?: string;
4072
- to?: string;
4073
- };
4074
- };
4075
- export type PermissionV2Source = {
4076
- type: "tool";
4077
- messageID: string;
4078
- callID: string;
4079
- };
4080
- export type EventPermissionV2Asked = {
4081
- id: string;
4082
- type: "permission.v2.asked";
4083
- properties: {
4084
- id: string;
4085
- sessionID: string;
4086
- action: string;
4087
- resources: Array<string>;
4088
- save?: Array<string>;
4089
- metadata?: {
4090
- [key: string]: unknown;
4091
- };
4092
- source?: PermissionV2Source;
4093
- };
4094
- };
4095
- export type PermissionV2Reply = "once" | "always" | "reject";
4096
- export type EventPermissionV2Replied = {
4097
- id: string;
4098
- type: "permission.v2.replied";
4099
- properties: {
4100
- sessionID: string;
4101
- requestID: string;
4102
- reply: PermissionV2Reply;
4103
- };
4104
- };
4105
- export type EventPtyCreated = {
4106
- id: string;
4107
- type: "pty.created";
4108
- properties: {
4109
- info: Pty;
4110
- };
4111
- };
4112
- export type EventPtyUpdated = {
4113
- id: string;
4114
- type: "pty.updated";
4115
- properties: {
4116
- info: Pty;
4117
- };
4118
- };
4119
- export type EventPtyExited = {
4120
- id: string;
4121
- type: "pty.exited";
4122
- properties: {
4123
- id: string;
4124
- exitCode: number;
4125
- };
4126
- };
4127
- export type EventPtyDeleted = {
4128
- id: string;
4129
- type: "pty.deleted";
4130
- properties: {
4131
- id: string;
4053
+ id: string;
4132
4054
  };
4133
4055
  };
4134
4056
  export type QuestionV2Option = {
@@ -4192,6 +4114,131 @@ export type EventQuestionV2Rejected = {
4192
4114
  requestID: string;
4193
4115
  };
4194
4116
  };
4117
+ export type EventTodoUpdated = {
4118
+ id: string;
4119
+ type: "todo.updated";
4120
+ properties: {
4121
+ sessionID: string;
4122
+ todos: Array<Todo>;
4123
+ };
4124
+ };
4125
+ export type EventSessionStatus = {
4126
+ id: string;
4127
+ type: "session.status";
4128
+ properties: {
4129
+ sessionID: string;
4130
+ status: SessionStatus;
4131
+ };
4132
+ };
4133
+ export type EventSessionIdle = {
4134
+ id: string;
4135
+ type: "session.idle";
4136
+ properties: {
4137
+ sessionID: string;
4138
+ };
4139
+ };
4140
+ export type EventSessionCompacted = {
4141
+ id: string;
4142
+ type: "session.compacted";
4143
+ properties: {
4144
+ sessionID: string;
4145
+ };
4146
+ };
4147
+ export type EventCommandExecuted = {
4148
+ id: string;
4149
+ type: "command.executed";
4150
+ properties: {
4151
+ name: string;
4152
+ sessionID: string;
4153
+ arguments: string;
4154
+ messageID: string;
4155
+ };
4156
+ };
4157
+ export type EventProjectDirectoriesUpdated = {
4158
+ id: string;
4159
+ type: "project.directories.updated";
4160
+ properties: {
4161
+ projectID: string;
4162
+ };
4163
+ };
4164
+ export type EventProjectUpdated = {
4165
+ id: string;
4166
+ type: "project.updated";
4167
+ properties: {
4168
+ id: string;
4169
+ worktree: string;
4170
+ vcs?: "git";
4171
+ name?: string;
4172
+ icon?: {
4173
+ url?: string;
4174
+ override?: string;
4175
+ color?: string;
4176
+ };
4177
+ commands?: {
4178
+ /**
4179
+ * Startup script to run when creating a new workspace (worktree)
4180
+ */
4181
+ start?: string;
4182
+ };
4183
+ time: {
4184
+ created: number;
4185
+ updated: number;
4186
+ initialized?: number;
4187
+ };
4188
+ sandboxes: Array<string>;
4189
+ };
4190
+ };
4191
+ export type EventLspUpdated = {
4192
+ id: string;
4193
+ type: "lsp.updated";
4194
+ properties: {
4195
+ [key: string]: unknown;
4196
+ };
4197
+ };
4198
+ export type EventVcsBranchUpdated = {
4199
+ id: string;
4200
+ type: "vcs.branch.updated";
4201
+ properties: {
4202
+ branch?: string;
4203
+ };
4204
+ };
4205
+ export type EventWorkspaceReady = {
4206
+ id: string;
4207
+ type: "workspace.ready";
4208
+ properties: {
4209
+ name: string;
4210
+ };
4211
+ };
4212
+ export type EventWorkspaceFailed = {
4213
+ id: string;
4214
+ type: "workspace.failed";
4215
+ properties: {
4216
+ message: string;
4217
+ };
4218
+ };
4219
+ export type EventWorkspaceStatus = {
4220
+ id: string;
4221
+ type: "workspace.status";
4222
+ properties: {
4223
+ workspaceID: string;
4224
+ status: "connected" | "connecting" | "disconnected" | "error";
4225
+ };
4226
+ };
4227
+ export type EventWorktreeReady = {
4228
+ id: string;
4229
+ type: "worktree.ready";
4230
+ properties: {
4231
+ name: string;
4232
+ branch?: string;
4233
+ };
4234
+ };
4235
+ export type EventWorktreeFailed = {
4236
+ id: string;
4237
+ type: "worktree.failed";
4238
+ properties: {
4239
+ message: string;
4240
+ };
4241
+ };
4195
4242
  export type SyncEventSessionCreated = {
4196
4243
  type: "sync";
4197
4244
  id: string;
@@ -4700,6 +4747,7 @@ export type SyncEventSessionNextToolSuccess = {
4700
4747
  [key: string]: unknown;
4701
4748
  };
4702
4749
  content: Array<ToolTextContent | ToolFileContent>;
4750
+ outputPaths?: Array<string>;
4703
4751
  result?: unknown;
4704
4752
  provider: {
4705
4753
  executed: boolean;
@@ -4770,21 +4818,6 @@ export type SyncEventSessionNextCompactionStarted = {
4770
4818
  };
4771
4819
  };
4772
4820
  };
4773
- export type SyncEventSessionNextCompactionDelta = {
4774
- type: "sync";
4775
- id: string;
4776
- syncEvent: {
4777
- type: "session.next.compaction.delta.1";
4778
- id: string;
4779
- seq: number;
4780
- aggregateID: string;
4781
- data: {
4782
- timestamp: number;
4783
- sessionID: string;
4784
- text: string;
4785
- };
4786
- };
4787
- };
4788
4821
  export type SyncEventSessionNextCompactionEnded = {
4789
4822
  type: "sync";
4790
4823
  id: string;
@@ -4796,18 +4829,35 @@ export type SyncEventSessionNextCompactionEnded = {
4796
4829
  data: {
4797
4830
  timestamp: number;
4798
4831
  sessionID: string;
4832
+ messageID?: string;
4833
+ reason?: "auto" | "manual";
4799
4834
  text: string;
4835
+ recent?: string;
4800
4836
  include?: string;
4801
4837
  };
4802
4838
  };
4803
4839
  };
4840
+ export type ConfigV2ReferenceGit = {
4841
+ repository: string;
4842
+ branch?: string;
4843
+ description?: string;
4844
+ hidden?: boolean;
4845
+ };
4846
+ export type ConfigV2ReferenceLocal = {
4847
+ path: string;
4848
+ description?: string;
4849
+ hidden?: boolean;
4850
+ };
4804
4851
  export type PolicyEffect = "allow" | "deny";
4805
4852
  export type ConfigV2ExperimentalPolicy = {
4806
4853
  action: "provider.use";
4807
4854
  effect: PolicyEffect;
4808
4855
  resource: string;
4809
4856
  };
4810
- export type ProjectDirectories = Array<string>;
4857
+ export type ProjectDirectories = Array<{
4858
+ directory: string;
4859
+ type: "main" | "root" | "git_worktree";
4860
+ }>;
4811
4861
  export type ProjectCopyCopy = {
4812
4862
  directory: string;
4813
4863
  };
@@ -4924,7 +4974,6 @@ export type SessionMessageUser = {
4924
4974
  text: string;
4925
4975
  files?: Array<PromptFileAttachment>;
4926
4976
  agents?: Array<PromptAgentAttachment>;
4927
- references?: Array<PromptReferenceAttachment>;
4928
4977
  type: "user";
4929
4978
  };
4930
4979
  export type SessionMessageSynthetic = {
@@ -5000,6 +5049,7 @@ export type SessionMessageToolStateCompleted = {
5000
5049
  };
5001
5050
  attachments?: Array<PromptFileAttachment>;
5002
5051
  content: Array<ToolTextContent | ToolFileContent>;
5052
+ outputPaths?: Array<string>;
5003
5053
  structured: {
5004
5054
  [key: string]: unknown;
5005
5055
  };
@@ -5080,7 +5130,7 @@ export type SessionMessageCompaction = {
5080
5130
  type: "compaction";
5081
5131
  reason: "auto" | "manual";
5082
5132
  summary: string;
5083
- include?: string;
5133
+ recent: string;
5084
5134
  id: string;
5085
5135
  metadata?: {
5086
5136
  [key: string]: unknown;
@@ -5097,8 +5147,8 @@ export type ProviderV2Info = {
5097
5147
  via: "env";
5098
5148
  name: string;
5099
5149
  } | {
5100
- via: "account";
5101
- service: string;
5150
+ via: "credential";
5151
+ credentialID: string;
5102
5152
  } | {
5103
5153
  via: "custom";
5104
5154
  data: {
@@ -5129,37 +5179,75 @@ export type ProviderV2Info = {
5129
5179
  };
5130
5180
  };
5131
5181
  };
5132
- export type PermissionV2Request = {
5133
- id: string;
5134
- sessionID: string;
5135
- action: string;
5136
- resources: Array<string>;
5137
- save?: Array<string>;
5138
- metadata?: {
5139
- [key: string]: unknown;
5140
- };
5141
- source?: PermissionV2Source;
5182
+ export type ConnectorWhen = {
5183
+ key: string;
5184
+ op: "eq" | "neq";
5185
+ value: string;
5142
5186
  };
5143
- export type PermissionSavedInfo = {
5187
+ export type ConnectorTextPrompt = {
5188
+ type: "text";
5189
+ key: string;
5190
+ message: string;
5191
+ placeholder?: string;
5192
+ when?: ConnectorWhen;
5193
+ };
5194
+ export type ConnectorSelectPrompt = {
5195
+ type: "select";
5196
+ key: string;
5197
+ message: string;
5198
+ options: Array<{
5199
+ label: string;
5200
+ value: string;
5201
+ hint?: string;
5202
+ }>;
5203
+ when?: ConnectorWhen;
5204
+ };
5205
+ export type ConnectorOAuthMethod = {
5206
+ id: string;
5207
+ type: "oauth";
5208
+ label: string;
5209
+ prompts?: Array<ConnectorTextPrompt | ConnectorSelectPrompt>;
5210
+ };
5211
+ export type ConnectorKeyMethod = {
5212
+ id: string;
5213
+ type: "key";
5214
+ label: string;
5215
+ prompts?: Array<ConnectorTextPrompt | ConnectorSelectPrompt>;
5216
+ };
5217
+ export type ConnectorInfo = {
5218
+ id: string;
5219
+ name: string;
5220
+ methods: Array<ConnectorOAuthMethod | ConnectorKeyMethod>;
5221
+ };
5222
+ export type ConnectorAttempt = {
5223
+ attemptID: string;
5224
+ url: string;
5225
+ instructions: string;
5226
+ mode: "auto" | "code";
5227
+ time: {
5228
+ created: number | "NaN" | "Infinity" | "-Infinity" | "Infinity" | "-Infinity" | "NaN";
5229
+ expires: number | "NaN" | "Infinity" | "-Infinity" | "Infinity" | "-Infinity" | "NaN";
5230
+ };
5231
+ };
5232
+ export type PermissionV2Request = {
5233
+ id: string;
5234
+ sessionID: string;
5235
+ action: string;
5236
+ resources: Array<string>;
5237
+ save?: Array<string>;
5238
+ metadata?: {
5239
+ [key: string]: unknown;
5240
+ };
5241
+ source?: PermissionV2Source;
5242
+ };
5243
+ export type PermissionSavedInfo = {
5144
5244
  id: string;
5145
5245
  projectID: string;
5146
5246
  action: string;
5147
5247
  resource: string;
5148
5248
  };
5149
- export type FileSystemTextContent = {
5150
- type: "text";
5151
- content: string;
5152
- mime: string;
5153
- };
5154
- export type FileSystemBinaryContent = {
5155
- type: "binary";
5156
- content: string;
5157
- encoding: "base64";
5158
- mime: string;
5159
- };
5160
5249
  export type FileSystemEntry = {
5161
5250
  path: string;
5162
- uri: string;
5163
5251
  type: "file" | "directory";
5164
5252
  mime: string;
5165
5253
  };
@@ -5197,6 +5285,26 @@ export type QuestionV2Reply = {
5197
5285
  */
5198
5286
  answers: Array<QuestionV2Answer>;
5199
5287
  };
5288
+ export type ReferenceLocalSource = {
5289
+ type: "local";
5290
+ path: string;
5291
+ description?: string;
5292
+ hidden?: boolean;
5293
+ };
5294
+ export type ReferenceGitSource = {
5295
+ type: "git";
5296
+ repository: string;
5297
+ branch?: string;
5298
+ description?: string;
5299
+ hidden?: boolean;
5300
+ };
5301
+ export type ReferenceInfo = {
5302
+ name: string;
5303
+ path: string;
5304
+ description?: string;
5305
+ hidden?: boolean;
5306
+ source: ReferenceLocalSource | ReferenceGitSource;
5307
+ };
5200
5308
  export type EventMemoryStatus1 = {
5201
5309
  id: string;
5202
5310
  type: "memory.status";
@@ -5338,6 +5446,19 @@ export type ModelV2Info1 = {
5338
5446
  body: {
5339
5447
  [key: string]: unknown;
5340
5448
  };
5449
+ generation?: {
5450
+ maxTokens?: number | "NaN" | "Infinity" | "-Infinity";
5451
+ temperature?: number | "NaN" | "Infinity" | "-Infinity";
5452
+ topP?: number | "NaN" | "Infinity" | "-Infinity";
5453
+ topK?: number | "NaN" | "Infinity" | "-Infinity";
5454
+ frequencyPenalty?: number | "NaN" | "Infinity" | "-Infinity";
5455
+ presencePenalty?: number | "NaN" | "Infinity" | "-Infinity";
5456
+ seed?: number | "NaN" | "Infinity" | "-Infinity";
5457
+ stop?: Array<string>;
5458
+ };
5459
+ options?: {
5460
+ [key: string]: unknown;
5461
+ };
5341
5462
  variant?: string;
5342
5463
  };
5343
5464
  variants: Array<{
@@ -5348,6 +5469,19 @@ export type ModelV2Info1 = {
5348
5469
  body: {
5349
5470
  [key: string]: unknown;
5350
5471
  };
5472
+ generation?: {
5473
+ maxTokens?: number | "NaN" | "Infinity" | "-Infinity";
5474
+ temperature?: number | "NaN" | "Infinity" | "-Infinity";
5475
+ topP?: number | "NaN" | "Infinity" | "-Infinity";
5476
+ topK?: number | "NaN" | "Infinity" | "-Infinity";
5477
+ frequencyPenalty?: number | "NaN" | "Infinity" | "-Infinity";
5478
+ presencePenalty?: number | "NaN" | "Infinity" | "-Infinity";
5479
+ seed?: number | "NaN" | "Infinity" | "-Infinity";
5480
+ stop?: Array<string>;
5481
+ };
5482
+ options?: {
5483
+ [key: string]: unknown;
5484
+ };
5351
5485
  }>;
5352
5486
  time: {
5353
5487
  released: number | "NaN" | "Infinity" | "-Infinity";
@@ -6943,12 +7077,12 @@ export type ProjectDirectoriesResponse = ProjectDirectoriesResponses[keyof Proje
6943
7077
  export type ExperimentalProjectCopyRemoveData = {
6944
7078
  body?: {
6945
7079
  directory: string;
7080
+ force: boolean;
6946
7081
  };
6947
7082
  path: {
6948
7083
  projectID: string;
6949
7084
  };
6950
7085
  query?: {
6951
- directory?: string;
6952
7086
  workspace?: string;
6953
7087
  };
6954
7088
  url: "/experimental/project/{projectID}/copy";
@@ -7861,7 +7995,7 @@ export type SessionMessagesResponses = {
7861
7995
  parts: Array<Part>;
7862
7996
  }>;
7863
7997
  };
7864
- export type SessionMessagesResponse = SessionMessagesResponses[keyof SessionMessagesResponses];
7998
+ export type SessionMessagesResponse2 = SessionMessagesResponses[keyof SessionMessagesResponses];
7865
7999
  export type SessionPromptData = {
7866
8000
  body?: {
7867
8001
  messageID?: string;
@@ -10514,6 +10648,10 @@ export type KiloCloudSessionImportErrors = {
10514
10648
  * Not found
10515
10649
  */
10516
10650
  404: NotFoundError;
10651
+ /**
10652
+ * CloudSessionImportError
10653
+ */
10654
+ 500: CloudSessionImportError;
10517
10655
  };
10518
10656
  export type KiloCloudSessionImportError = KiloCloudSessionImportErrors[keyof KiloCloudSessionImportErrors];
10519
10657
  export type KiloCloudSessionImportResponses = {
@@ -11270,6 +11408,7 @@ export type KilocodeSessionImportSessionData = {
11270
11408
  partID?: string;
11271
11409
  snapshot?: string;
11272
11410
  diff?: string;
11411
+ workspace?: "restored" | "snapshots-disabled" | "unavailable";
11273
11412
  };
11274
11413
  permission?: {
11275
11414
  [key: string]: unknown;
@@ -12247,6 +12386,35 @@ export type V2HealthGetResponses = {
12247
12386
  };
12248
12387
  };
12249
12388
  export type V2HealthGetResponse = V2HealthGetResponses[keyof V2HealthGetResponses];
12389
+ export type V2LocationGetData = {
12390
+ body?: never;
12391
+ path?: never;
12392
+ query?: {
12393
+ location?: {
12394
+ directory?: string;
12395
+ workspace?: string;
12396
+ };
12397
+ };
12398
+ url: "/api/location";
12399
+ };
12400
+ export type V2LocationGetErrors = {
12401
+ /**
12402
+ * InvalidRequestError
12403
+ */
12404
+ 400: InvalidRequestError;
12405
+ /**
12406
+ * UnauthorizedError
12407
+ */
12408
+ 401: UnauthorizedError;
12409
+ };
12410
+ export type V2LocationGetError = V2LocationGetErrors[keyof V2LocationGetErrors];
12411
+ export type V2LocationGetResponses = {
12412
+ /**
12413
+ * Location.Info
12414
+ */
12415
+ 200: LocationInfo;
12416
+ };
12417
+ export type V2LocationGetResponse = V2LocationGetResponses[keyof V2LocationGetResponses];
12250
12418
  export type V2AgentListData = {
12251
12419
  body?: never;
12252
12420
  path?: never;
@@ -12310,11 +12478,78 @@ export type V2SessionListErrors = {
12310
12478
  export type V2SessionListError = V2SessionListErrors[keyof V2SessionListErrors];
12311
12479
  export type V2SessionListResponses = {
12312
12480
  /**
12313
- * V2SessionsResponse
12481
+ * SessionsResponse
12314
12482
  */
12315
- 200: V2SessionsResponse;
12483
+ 200: SessionsResponse;
12316
12484
  };
12317
12485
  export type V2SessionListResponse = V2SessionListResponses[keyof V2SessionListResponses];
12486
+ export type V2SessionCreateData = {
12487
+ body: {
12488
+ id?: string;
12489
+ agent?: string;
12490
+ model?: {
12491
+ id: string;
12492
+ providerID: string;
12493
+ variant?: string;
12494
+ };
12495
+ location?: LocationRef;
12496
+ };
12497
+ path?: never;
12498
+ query?: never;
12499
+ url: "/api/session";
12500
+ };
12501
+ export type V2SessionCreateErrors = {
12502
+ /**
12503
+ * InvalidRequestError
12504
+ */
12505
+ 400: InvalidRequestError;
12506
+ /**
12507
+ * UnauthorizedError
12508
+ */
12509
+ 401: UnauthorizedError;
12510
+ };
12511
+ export type V2SessionCreateError = V2SessionCreateErrors[keyof V2SessionCreateErrors];
12512
+ export type V2SessionCreateResponses = {
12513
+ /**
12514
+ * Success
12515
+ */
12516
+ 200: {
12517
+ data: SessionV2Info;
12518
+ };
12519
+ };
12520
+ export type V2SessionCreateResponse = V2SessionCreateResponses[keyof V2SessionCreateResponses];
12521
+ export type V2SessionGetData = {
12522
+ body?: never;
12523
+ path: {
12524
+ sessionID: string;
12525
+ };
12526
+ query?: never;
12527
+ url: "/api/session/{sessionID}";
12528
+ };
12529
+ export type V2SessionGetErrors = {
12530
+ /**
12531
+ * InvalidRequestError
12532
+ */
12533
+ 400: InvalidRequestError;
12534
+ /**
12535
+ * UnauthorizedError
12536
+ */
12537
+ 401: UnauthorizedError;
12538
+ /**
12539
+ * SessionNotFoundError
12540
+ */
12541
+ 404: SessionNotFoundError;
12542
+ };
12543
+ export type V2SessionGetError = V2SessionGetErrors[keyof V2SessionGetErrors];
12544
+ export type V2SessionGetResponses = {
12545
+ /**
12546
+ * Success
12547
+ */
12548
+ 200: {
12549
+ data: SessionV2Info;
12550
+ };
12551
+ };
12552
+ export type V2SessionGetResponse = V2SessionGetResponses[keyof V2SessionGetResponses];
12318
12553
  export type V2SessionPromptData = {
12319
12554
  body: {
12320
12555
  id?: string;
@@ -12496,11 +12731,11 @@ export type V2SessionMessagesErrors = {
12496
12731
  export type V2SessionMessagesError = V2SessionMessagesErrors[keyof V2SessionMessagesErrors];
12497
12732
  export type V2SessionMessagesResponses = {
12498
12733
  /**
12499
- * V2SessionMessagesResponse
12734
+ * SessionMessagesResponse
12500
12735
  */
12501
- 200: V2SessionMessagesResponse;
12736
+ 200: SessionMessagesResponse;
12502
12737
  };
12503
- export type V2SessionMessagesResponse2 = V2SessionMessagesResponses[keyof V2SessionMessagesResponses];
12738
+ export type V2SessionMessagesResponse = V2SessionMessagesResponses[keyof V2SessionMessagesResponses];
12504
12739
  export type V2ModelListData = {
12505
12740
  body?: never;
12506
12741
  path?: never;
@@ -12615,7 +12850,7 @@ export type V2ProviderGetResponses = {
12615
12850
  };
12616
12851
  };
12617
12852
  export type V2ProviderGetResponse = V2ProviderGetResponses[keyof V2ProviderGetResponses];
12618
- export type V2PermissionRequestListData = {
12853
+ export type V2ConnectorListData = {
12619
12854
  body?: never;
12620
12855
  path?: never;
12621
12856
  query?: {
@@ -12624,9 +12859,9 @@ export type V2PermissionRequestListData = {
12624
12859
  workspace?: string;
12625
12860
  };
12626
12861
  };
12627
- url: "/api/permission/request";
12862
+ url: "/api/connector";
12628
12863
  };
12629
- export type V2PermissionRequestListErrors = {
12864
+ export type V2ConnectorListErrors = {
12630
12865
  /**
12631
12866
  * InvalidRequestError
12632
12867
  */
@@ -12636,26 +12871,31 @@ export type V2PermissionRequestListErrors = {
12636
12871
  */
12637
12872
  401: UnauthorizedError;
12638
12873
  };
12639
- export type V2PermissionRequestListError = V2PermissionRequestListErrors[keyof V2PermissionRequestListErrors];
12640
- export type V2PermissionRequestListResponses = {
12874
+ export type V2ConnectorListError = V2ConnectorListErrors[keyof V2ConnectorListErrors];
12875
+ export type V2ConnectorListResponses = {
12641
12876
  /**
12642
12877
  * Success
12643
12878
  */
12644
12879
  200: {
12645
12880
  location: LocationInfo;
12646
- data: Array<PermissionV2Request>;
12881
+ data: Array<ConnectorInfo>;
12647
12882
  };
12648
12883
  };
12649
- export type V2PermissionRequestListResponse = V2PermissionRequestListResponses[keyof V2PermissionRequestListResponses];
12650
- export type V2SessionPermissionListData = {
12884
+ export type V2ConnectorListResponse = V2ConnectorListResponses[keyof V2ConnectorListResponses];
12885
+ export type V2ConnectorGetData = {
12651
12886
  body?: never;
12652
12887
  path: {
12653
- sessionID: string;
12888
+ connectorID: string;
12654
12889
  };
12655
- query?: never;
12656
- url: "/api/session/{sessionID}/permission/request";
12890
+ query?: {
12891
+ location?: {
12892
+ directory?: string;
12893
+ workspace?: string;
12894
+ };
12895
+ };
12896
+ url: "/api/connector/{connectorID}";
12657
12897
  };
12658
- export type V2SessionPermissionListErrors = {
12898
+ export type V2ConnectorGetErrors = {
12659
12899
  /**
12660
12900
  * InvalidRequestError
12661
12901
  */
@@ -12664,34 +12904,141 @@ export type V2SessionPermissionListErrors = {
12664
12904
  * UnauthorizedError
12665
12905
  */
12666
12906
  401: UnauthorizedError;
12907
+ };
12908
+ export type V2ConnectorGetError = V2ConnectorGetErrors[keyof V2ConnectorGetErrors];
12909
+ export type V2ConnectorGetResponses = {
12667
12910
  /**
12668
- * SessionNotFoundError
12911
+ * Success
12669
12912
  */
12670
- 404: SessionNotFoundError;
12913
+ 200: {
12914
+ location: LocationInfo;
12915
+ data: ConnectorInfo;
12916
+ };
12671
12917
  };
12672
- export type V2SessionPermissionListError = V2SessionPermissionListErrors[keyof V2SessionPermissionListErrors];
12673
- export type V2SessionPermissionListResponses = {
12918
+ export type V2ConnectorGetResponse = V2ConnectorGetResponses[keyof V2ConnectorGetResponses];
12919
+ export type V2ConnectorConnectKeyData = {
12920
+ body: {
12921
+ methodID: string;
12922
+ key: string;
12923
+ inputs: {
12924
+ [key: string]: string;
12925
+ };
12926
+ label?: string;
12927
+ };
12928
+ path: {
12929
+ connectorID: string;
12930
+ };
12931
+ query?: {
12932
+ location?: {
12933
+ directory?: string;
12934
+ workspace?: string;
12935
+ };
12936
+ };
12937
+ url: "/api/connector/{connectorID}/connect/key";
12938
+ };
12939
+ export type V2ConnectorConnectKeyErrors = {
12940
+ /**
12941
+ * InvalidRequestError
12942
+ */
12943
+ 400: InvalidRequestError;
12944
+ /**
12945
+ * UnauthorizedError
12946
+ */
12947
+ 401: UnauthorizedError;
12948
+ };
12949
+ export type V2ConnectorConnectKeyError = V2ConnectorConnectKeyErrors[keyof V2ConnectorConnectKeyErrors];
12950
+ export type V2ConnectorConnectKeyResponses = {
12951
+ /**
12952
+ * <No Content>
12953
+ */
12954
+ 204: void;
12955
+ };
12956
+ export type V2ConnectorConnectKeyResponse = V2ConnectorConnectKeyResponses[keyof V2ConnectorConnectKeyResponses];
12957
+ export type V2ConnectorConnectOauthBeginData = {
12958
+ body: {
12959
+ methodID: string;
12960
+ inputs: {
12961
+ [key: string]: string;
12962
+ };
12963
+ label?: string;
12964
+ };
12965
+ path: {
12966
+ connectorID: string;
12967
+ };
12968
+ query?: {
12969
+ location?: {
12970
+ directory?: string;
12971
+ workspace?: string;
12972
+ };
12973
+ };
12974
+ url: "/api/connector/{connectorID}/connect/oauth";
12975
+ };
12976
+ export type V2ConnectorConnectOauthBeginErrors = {
12977
+ /**
12978
+ * InvalidRequestError
12979
+ */
12980
+ 400: InvalidRequestError;
12981
+ /**
12982
+ * UnauthorizedError
12983
+ */
12984
+ 401: UnauthorizedError;
12985
+ };
12986
+ export type V2ConnectorConnectOauthBeginError = V2ConnectorConnectOauthBeginErrors[keyof V2ConnectorConnectOauthBeginErrors];
12987
+ export type V2ConnectorConnectOauthBeginResponses = {
12674
12988
  /**
12675
12989
  * Success
12676
12990
  */
12677
12991
  200: {
12678
- data: Array<PermissionV2Request>;
12992
+ location: LocationInfo;
12993
+ data: ConnectorAttempt;
12679
12994
  };
12680
12995
  };
12681
- export type V2SessionPermissionListResponse = V2SessionPermissionListResponses[keyof V2SessionPermissionListResponses];
12682
- export type V2SessionPermissionReplyData = {
12683
- body: {
12684
- reply: PermissionV2Reply;
12685
- message?: string;
12996
+ export type V2ConnectorConnectOauthBeginResponse = V2ConnectorConnectOauthBeginResponses[keyof V2ConnectorConnectOauthBeginResponses];
12997
+ export type V2ConnectorConnectOauthCancelData = {
12998
+ body?: never;
12999
+ path: {
13000
+ attemptID: string;
13001
+ };
13002
+ query?: {
13003
+ location?: {
13004
+ directory?: string;
13005
+ workspace?: string;
13006
+ };
12686
13007
  };
13008
+ url: "/api/connector/oauth/{attemptID}";
13009
+ };
13010
+ export type V2ConnectorConnectOauthCancelErrors = {
13011
+ /**
13012
+ * InvalidRequestError
13013
+ */
13014
+ 400: InvalidRequestError;
13015
+ /**
13016
+ * UnauthorizedError
13017
+ */
13018
+ 401: UnauthorizedError;
13019
+ };
13020
+ export type V2ConnectorConnectOauthCancelError = V2ConnectorConnectOauthCancelErrors[keyof V2ConnectorConnectOauthCancelErrors];
13021
+ export type V2ConnectorConnectOauthCancelResponses = {
13022
+ /**
13023
+ * <No Content>
13024
+ */
13025
+ 204: void;
13026
+ };
13027
+ export type V2ConnectorConnectOauthCancelResponse = V2ConnectorConnectOauthCancelResponses[keyof V2ConnectorConnectOauthCancelResponses];
13028
+ export type V2ConnectorConnectOauthStatusData = {
13029
+ body?: never;
12687
13030
  path: {
12688
- sessionID: string;
12689
- requestID: string;
13031
+ attemptID: string;
12690
13032
  };
12691
- query?: never;
12692
- url: "/api/session/{sessionID}/permission/request/{requestID}/reply";
13033
+ query?: {
13034
+ location?: {
13035
+ directory?: string;
13036
+ workspace?: string;
13037
+ };
13038
+ };
13039
+ url: "/api/connector/oauth/{attemptID}";
12693
13040
  };
12694
- export type V2SessionPermissionReplyErrors = {
13041
+ export type V2ConnectorConnectOauthStatusErrors = {
12695
13042
  /**
12696
13043
  * InvalidRequestError
12697
13044
  */
@@ -12700,19 +13047,108 @@ export type V2SessionPermissionReplyErrors = {
12700
13047
  * UnauthorizedError
12701
13048
  */
12702
13049
  401: UnauthorizedError;
13050
+ };
13051
+ export type V2ConnectorConnectOauthStatusError = V2ConnectorConnectOauthStatusErrors[keyof V2ConnectorConnectOauthStatusErrors];
13052
+ export type V2ConnectorConnectOauthStatusResponses = {
12703
13053
  /**
12704
- * SessionNotFoundError | PermissionNotFoundError
13054
+ * Success
12705
13055
  */
12706
- 404: SessionNotFoundError | PermissionNotFoundError;
13056
+ 200: {
13057
+ location: LocationInfo;
13058
+ data: {
13059
+ status: "pending";
13060
+ time: {
13061
+ created: number | "NaN" | "Infinity" | "-Infinity" | "Infinity" | "-Infinity" | "NaN";
13062
+ expires: number | "NaN" | "Infinity" | "-Infinity" | "Infinity" | "-Infinity" | "NaN";
13063
+ };
13064
+ } | {
13065
+ status: "complete";
13066
+ time: {
13067
+ created: number | "NaN" | "Infinity" | "-Infinity" | "Infinity" | "-Infinity" | "NaN";
13068
+ expires: number | "NaN" | "Infinity" | "-Infinity" | "Infinity" | "-Infinity" | "NaN";
13069
+ };
13070
+ } | {
13071
+ status: "failed";
13072
+ message: string;
13073
+ time: {
13074
+ created: number | "NaN" | "Infinity" | "-Infinity" | "Infinity" | "-Infinity" | "NaN";
13075
+ expires: number | "NaN" | "Infinity" | "-Infinity" | "Infinity" | "-Infinity" | "NaN";
13076
+ };
13077
+ } | {
13078
+ status: "expired";
13079
+ time: {
13080
+ created: number | "NaN" | "Infinity" | "-Infinity" | "Infinity" | "-Infinity" | "NaN";
13081
+ expires: number | "NaN" | "Infinity" | "-Infinity" | "Infinity" | "-Infinity" | "NaN";
13082
+ };
13083
+ };
13084
+ };
12707
13085
  };
12708
- export type V2SessionPermissionReplyError = V2SessionPermissionReplyErrors[keyof V2SessionPermissionReplyErrors];
12709
- export type V2SessionPermissionReplyResponses = {
13086
+ export type V2ConnectorConnectOauthStatusResponse = V2ConnectorConnectOauthStatusResponses[keyof V2ConnectorConnectOauthStatusResponses];
13087
+ export type V2ConnectorConnectOauthCompleteData = {
13088
+ body: {
13089
+ code?: string;
13090
+ };
13091
+ path: {
13092
+ attemptID: string;
13093
+ };
13094
+ query?: {
13095
+ location?: {
13096
+ directory?: string;
13097
+ workspace?: string;
13098
+ };
13099
+ };
13100
+ url: "/api/connector/oauth/{attemptID}/complete";
13101
+ };
13102
+ export type V2ConnectorConnectOauthCompleteErrors = {
13103
+ /**
13104
+ * InvalidRequestError
13105
+ */
13106
+ 400: InvalidRequestError;
13107
+ /**
13108
+ * UnauthorizedError
13109
+ */
13110
+ 401: UnauthorizedError;
13111
+ };
13112
+ export type V2ConnectorConnectOauthCompleteError = V2ConnectorConnectOauthCompleteErrors[keyof V2ConnectorConnectOauthCompleteErrors];
13113
+ export type V2ConnectorConnectOauthCompleteResponses = {
12710
13114
  /**
12711
13115
  * <No Content>
12712
13116
  */
12713
13117
  204: void;
12714
13118
  };
12715
- export type V2SessionPermissionReplyResponse = V2SessionPermissionReplyResponses[keyof V2SessionPermissionReplyResponses];
13119
+ export type V2ConnectorConnectOauthCompleteResponse = V2ConnectorConnectOauthCompleteResponses[keyof V2ConnectorConnectOauthCompleteResponses];
13120
+ export type V2PermissionRequestListData = {
13121
+ body?: never;
13122
+ path?: never;
13123
+ query?: {
13124
+ location?: {
13125
+ directory?: string;
13126
+ workspace?: string;
13127
+ };
13128
+ };
13129
+ url: "/api/permission/request";
13130
+ };
13131
+ export type V2PermissionRequestListErrors = {
13132
+ /**
13133
+ * InvalidRequestError
13134
+ */
13135
+ 400: InvalidRequestError;
13136
+ /**
13137
+ * UnauthorizedError
13138
+ */
13139
+ 401: UnauthorizedError;
13140
+ };
13141
+ export type V2PermissionRequestListError = V2PermissionRequestListErrors[keyof V2PermissionRequestListErrors];
13142
+ export type V2PermissionRequestListResponses = {
13143
+ /**
13144
+ * Success
13145
+ */
13146
+ 200: {
13147
+ location: LocationInfo;
13148
+ data: Array<PermissionV2Request>;
13149
+ };
13150
+ };
13151
+ export type V2PermissionRequestListResponse = V2PermissionRequestListResponses[keyof V2PermissionRequestListResponses];
12716
13152
  export type V2PermissionSavedListData = {
12717
13153
  body?: never;
12718
13154
  path?: never;
@@ -12767,18 +13203,83 @@ export type V2PermissionSavedRemoveResponses = {
12767
13203
  204: void;
12768
13204
  };
12769
13205
  export type V2PermissionSavedRemoveResponse = V2PermissionSavedRemoveResponses[keyof V2PermissionSavedRemoveResponses];
13206
+ export type V2SessionPermissionListData = {
13207
+ body?: never;
13208
+ path: {
13209
+ sessionID: string;
13210
+ };
13211
+ query?: never;
13212
+ url: "/api/session/{sessionID}/permission";
13213
+ };
13214
+ export type V2SessionPermissionListErrors = {
13215
+ /**
13216
+ * InvalidRequestError
13217
+ */
13218
+ 400: InvalidRequestError;
13219
+ /**
13220
+ * UnauthorizedError
13221
+ */
13222
+ 401: UnauthorizedError;
13223
+ /**
13224
+ * SessionNotFoundError
13225
+ */
13226
+ 404: SessionNotFoundError;
13227
+ };
13228
+ export type V2SessionPermissionListError = V2SessionPermissionListErrors[keyof V2SessionPermissionListErrors];
13229
+ export type V2SessionPermissionListResponses = {
13230
+ /**
13231
+ * Success
13232
+ */
13233
+ 200: {
13234
+ data: Array<PermissionV2Request>;
13235
+ };
13236
+ };
13237
+ export type V2SessionPermissionListResponse = V2SessionPermissionListResponses[keyof V2SessionPermissionListResponses];
13238
+ export type V2SessionPermissionReplyData = {
13239
+ body: {
13240
+ reply: PermissionV2Reply;
13241
+ message?: string;
13242
+ };
13243
+ path: {
13244
+ sessionID: string;
13245
+ requestID: string;
13246
+ };
13247
+ query?: never;
13248
+ url: "/api/session/{sessionID}/permission/{requestID}/reply";
13249
+ };
13250
+ export type V2SessionPermissionReplyErrors = {
13251
+ /**
13252
+ * InvalidRequestError
13253
+ */
13254
+ 400: InvalidRequestError;
13255
+ /**
13256
+ * UnauthorizedError
13257
+ */
13258
+ 401: UnauthorizedError;
13259
+ /**
13260
+ * SessionNotFoundError | PermissionNotFoundError
13261
+ */
13262
+ 404: PermissionNotFoundError | SessionNotFoundError;
13263
+ };
13264
+ export type V2SessionPermissionReplyError = V2SessionPermissionReplyErrors[keyof V2SessionPermissionReplyErrors];
13265
+ export type V2SessionPermissionReplyResponses = {
13266
+ /**
13267
+ * <No Content>
13268
+ */
13269
+ 204: void;
13270
+ };
13271
+ export type V2SessionPermissionReplyResponse = V2SessionPermissionReplyResponses[keyof V2SessionPermissionReplyResponses];
12770
13272
  export type V2FsReadData = {
12771
13273
  body?: never;
12772
13274
  path?: never;
12773
- query: {
13275
+ query?: {
12774
13276
  location?: {
12775
13277
  directory?: string;
12776
13278
  workspace?: string;
12777
13279
  };
12778
- path: string;
12779
- reference?: string;
13280
+ path?: string;
12780
13281
  };
12781
- url: "/api/fs/read";
13282
+ url: "/api/fs/read/*";
12782
13283
  };
12783
13284
  export type V2FsReadErrors = {
12784
13285
  /**
@@ -12795,10 +13296,7 @@ export type V2FsReadResponses = {
12795
13296
  /**
12796
13297
  * Success
12797
13298
  */
12798
- 200: {
12799
- location: LocationInfo;
12800
- data: FileSystemTextContent | FileSystemBinaryContent;
12801
- };
13299
+ 200: Blob | File;
12802
13300
  };
12803
13301
  export type V2FsReadResponse = V2FsReadResponses[keyof V2FsReadResponses];
12804
13302
  export type V2FsListData = {
@@ -12810,7 +13308,6 @@ export type V2FsListData = {
12810
13308
  workspace?: string;
12811
13309
  };
12812
13310
  path?: string;
12813
- reference?: string;
12814
13311
  };
12815
13312
  url: "/api/fs/list";
12816
13313
  };
@@ -12835,6 +13332,41 @@ export type V2FsListResponses = {
12835
13332
  };
12836
13333
  };
12837
13334
  export type V2FsListResponse = V2FsListResponses[keyof V2FsListResponses];
13335
+ export type V2FsFindData = {
13336
+ body?: never;
13337
+ path?: never;
13338
+ query: {
13339
+ location?: {
13340
+ directory?: string;
13341
+ workspace?: string;
13342
+ };
13343
+ query: string;
13344
+ type?: "file" | "directory";
13345
+ limit?: string;
13346
+ };
13347
+ url: "/api/fs/find";
13348
+ };
13349
+ export type V2FsFindErrors = {
13350
+ /**
13351
+ * InvalidRequestError
13352
+ */
13353
+ 400: InvalidRequestError;
13354
+ /**
13355
+ * UnauthorizedError
13356
+ */
13357
+ 401: UnauthorizedError;
13358
+ };
13359
+ export type V2FsFindError = V2FsFindErrors[keyof V2FsFindErrors];
13360
+ export type V2FsFindResponses = {
13361
+ /**
13362
+ * Success
13363
+ */
13364
+ 200: {
13365
+ location: LocationInfo;
13366
+ data: Array<FileSystemEntry>;
13367
+ };
13368
+ };
13369
+ export type V2FsFindResponse = V2FsFindResponses[keyof V2FsFindResponses];
12838
13370
  export type V2CommandListData = {
12839
13371
  body?: never;
12840
13372
  path?: never;
@@ -12960,6 +13492,38 @@ export type V2QuestionRequestListResponses = {
12960
13492
  };
12961
13493
  };
12962
13494
  export type V2QuestionRequestListResponse = V2QuestionRequestListResponses[keyof V2QuestionRequestListResponses];
13495
+ export type V2SessionQuestionListData = {
13496
+ body?: never;
13497
+ path: {
13498
+ sessionID: string;
13499
+ };
13500
+ query?: never;
13501
+ url: "/api/session/{sessionID}/question";
13502
+ };
13503
+ export type V2SessionQuestionListErrors = {
13504
+ /**
13505
+ * InvalidRequestError
13506
+ */
13507
+ 400: InvalidRequestError;
13508
+ /**
13509
+ * UnauthorizedError
13510
+ */
13511
+ 401: UnauthorizedError;
13512
+ /**
13513
+ * SessionNotFoundError
13514
+ */
13515
+ 404: SessionNotFoundError;
13516
+ };
13517
+ export type V2SessionQuestionListError = V2SessionQuestionListErrors[keyof V2SessionQuestionListErrors];
13518
+ export type V2SessionQuestionListResponses = {
13519
+ /**
13520
+ * Success
13521
+ */
13522
+ 200: {
13523
+ data: Array<QuestionV2Request>;
13524
+ };
13525
+ };
13526
+ export type V2SessionQuestionListResponse = V2SessionQuestionListResponses[keyof V2SessionQuestionListResponses];
12963
13527
  export type V2SessionQuestionReplyData = {
12964
13528
  body: QuestionV2Reply;
12965
13529
  path: {
@@ -12967,7 +13531,7 @@ export type V2SessionQuestionReplyData = {
12967
13531
  requestID: string;
12968
13532
  };
12969
13533
  query?: never;
12970
- url: "/api/session/{sessionID}/question/request/{requestID}/reply";
13534
+ url: "/api/session/{sessionID}/question/{requestID}/reply";
12971
13535
  };
12972
13536
  export type V2SessionQuestionReplyErrors = {
12973
13537
  /**
@@ -12981,7 +13545,7 @@ export type V2SessionQuestionReplyErrors = {
12981
13545
  /**
12982
13546
  * SessionNotFoundError | QuestionNotFoundError
12983
13547
  */
12984
- 404: SessionNotFoundError | QuestionNotFoundError;
13548
+ 404: QuestionNotFoundError | SessionNotFoundError;
12985
13549
  };
12986
13550
  export type V2SessionQuestionReplyError = V2SessionQuestionReplyErrors[keyof V2SessionQuestionReplyErrors];
12987
13551
  export type V2SessionQuestionReplyResponses = {
@@ -12998,7 +13562,7 @@ export type V2SessionQuestionRejectData = {
12998
13562
  requestID: string;
12999
13563
  };
13000
13564
  query?: never;
13001
- url: "/api/session/{sessionID}/question/request/{requestID}/reject";
13565
+ url: "/api/session/{sessionID}/question/{requestID}/reject";
13002
13566
  };
13003
13567
  export type V2SessionQuestionRejectErrors = {
13004
13568
  /**
@@ -13012,7 +13576,7 @@ export type V2SessionQuestionRejectErrors = {
13012
13576
  /**
13013
13577
  * SessionNotFoundError | QuestionNotFoundError
13014
13578
  */
13015
- 404: SessionNotFoundError | QuestionNotFoundError;
13579
+ 404: QuestionNotFoundError | SessionNotFoundError;
13016
13580
  };
13017
13581
  export type V2SessionQuestionRejectError = V2SessionQuestionRejectErrors[keyof V2SessionQuestionRejectErrors];
13018
13582
  export type V2SessionQuestionRejectResponses = {
@@ -13022,6 +13586,38 @@ export type V2SessionQuestionRejectResponses = {
13022
13586
  204: void;
13023
13587
  };
13024
13588
  export type V2SessionQuestionRejectResponse = V2SessionQuestionRejectResponses[keyof V2SessionQuestionRejectResponses];
13589
+ export type V2ReferenceListData = {
13590
+ body?: never;
13591
+ path?: never;
13592
+ query?: {
13593
+ location?: {
13594
+ directory?: string;
13595
+ workspace?: string;
13596
+ };
13597
+ };
13598
+ url: "/api/reference";
13599
+ };
13600
+ export type V2ReferenceListErrors = {
13601
+ /**
13602
+ * InvalidRequestError
13603
+ */
13604
+ 400: InvalidRequestError;
13605
+ /**
13606
+ * UnauthorizedError
13607
+ */
13608
+ 401: UnauthorizedError;
13609
+ };
13610
+ export type V2ReferenceListError = V2ReferenceListErrors[keyof V2ReferenceListErrors];
13611
+ export type V2ReferenceListResponses = {
13612
+ /**
13613
+ * Success
13614
+ */
13615
+ 200: {
13616
+ location: LocationInfo;
13617
+ data: Array<ReferenceInfo>;
13618
+ };
13619
+ };
13620
+ export type V2ReferenceListResponse = V2ReferenceListResponses[keyof V2ReferenceListResponses];
13025
13621
  export type PtyConnectData = {
13026
13622
  body?: never;
13027
13623
  path: {