@opencode-ai/sdk 0.4.2 → 0.4.3
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/dist/gen/types.gen.d.ts +42 -16
- package/package.json +1 -1
package/dist/gen/types.gen.d.ts
CHANGED
|
@@ -13,14 +13,12 @@ export type Event = ({
|
|
|
13
13
|
} & EventMessagePartRemoved) | ({
|
|
14
14
|
type: "storage.write";
|
|
15
15
|
} & EventStorageWrite) | ({
|
|
16
|
-
type: "file.edited";
|
|
17
|
-
} & EventFileEdited) | ({
|
|
18
|
-
type: "server.connected";
|
|
19
|
-
} & EventServerConnected) | ({
|
|
20
16
|
type: "permission.updated";
|
|
21
17
|
} & EventPermissionUpdated) | ({
|
|
22
18
|
type: "permission.replied";
|
|
23
19
|
} & EventPermissionReplied) | ({
|
|
20
|
+
type: "file.edited";
|
|
21
|
+
} & EventFileEdited) | ({
|
|
24
22
|
type: "session.updated";
|
|
25
23
|
} & EventSessionUpdated) | ({
|
|
26
24
|
type: "session.deleted";
|
|
@@ -29,6 +27,8 @@ export type Event = ({
|
|
|
29
27
|
} & EventSessionIdle) | ({
|
|
30
28
|
type: "session.error";
|
|
31
29
|
} & EventSessionError) | ({
|
|
30
|
+
type: "server.connected";
|
|
31
|
+
} & EventServerConnected) | ({
|
|
32
32
|
type: "file.watcher.updated";
|
|
33
33
|
} & EventFileWatcherUpdated) | ({
|
|
34
34
|
type: "ide.installed";
|
|
@@ -143,6 +143,8 @@ export type EventMessagePartUpdated = {
|
|
|
143
143
|
export type Part = ({
|
|
144
144
|
type: "text";
|
|
145
145
|
} & TextPart) | ({
|
|
146
|
+
type: "reasoning";
|
|
147
|
+
} & ReasoningPart) | ({
|
|
146
148
|
type: "file";
|
|
147
149
|
} & FilePart) | ({
|
|
148
150
|
type: "tool";
|
|
@@ -169,6 +171,20 @@ export type TextPart = {
|
|
|
169
171
|
end?: number;
|
|
170
172
|
};
|
|
171
173
|
};
|
|
174
|
+
export type ReasoningPart = {
|
|
175
|
+
id: string;
|
|
176
|
+
sessionID: string;
|
|
177
|
+
messageID: string;
|
|
178
|
+
type: string;
|
|
179
|
+
text: string;
|
|
180
|
+
metadata?: {
|
|
181
|
+
[key: string]: unknown;
|
|
182
|
+
};
|
|
183
|
+
time: {
|
|
184
|
+
start: number;
|
|
185
|
+
end?: number;
|
|
186
|
+
};
|
|
187
|
+
};
|
|
172
188
|
export type FilePart = {
|
|
173
189
|
id: string;
|
|
174
190
|
sessionID: string;
|
|
@@ -334,18 +350,6 @@ export type EventStorageWrite = {
|
|
|
334
350
|
content?: unknown;
|
|
335
351
|
};
|
|
336
352
|
};
|
|
337
|
-
export type EventFileEdited = {
|
|
338
|
-
type: string;
|
|
339
|
-
properties: {
|
|
340
|
-
file: string;
|
|
341
|
-
};
|
|
342
|
-
};
|
|
343
|
-
export type EventServerConnected = {
|
|
344
|
-
type: string;
|
|
345
|
-
properties: {
|
|
346
|
-
[key: string]: unknown;
|
|
347
|
-
};
|
|
348
|
-
};
|
|
349
353
|
export type EventPermissionUpdated = {
|
|
350
354
|
type: string;
|
|
351
355
|
properties: Permission;
|
|
@@ -373,6 +377,12 @@ export type EventPermissionReplied = {
|
|
|
373
377
|
response: string;
|
|
374
378
|
};
|
|
375
379
|
};
|
|
380
|
+
export type EventFileEdited = {
|
|
381
|
+
type: string;
|
|
382
|
+
properties: {
|
|
383
|
+
file: string;
|
|
384
|
+
};
|
|
385
|
+
};
|
|
376
386
|
export type EventSessionUpdated = {
|
|
377
387
|
type: string;
|
|
378
388
|
properties: {
|
|
@@ -425,6 +435,12 @@ export type EventSessionError = {
|
|
|
425
435
|
} & MessageAbortedError);
|
|
426
436
|
};
|
|
427
437
|
};
|
|
438
|
+
export type EventServerConnected = {
|
|
439
|
+
type: string;
|
|
440
|
+
properties: {
|
|
441
|
+
[key: string]: unknown;
|
|
442
|
+
};
|
|
443
|
+
};
|
|
428
444
|
export type EventFileWatcherUpdated = {
|
|
429
445
|
type: string;
|
|
430
446
|
properties: {
|
|
@@ -595,6 +611,7 @@ export type Config = {
|
|
|
595
611
|
bash?: string | {
|
|
596
612
|
[key: string]: string;
|
|
597
613
|
};
|
|
614
|
+
webfetch?: string;
|
|
598
615
|
};
|
|
599
616
|
experimental?: {
|
|
600
617
|
hook?: {
|
|
@@ -790,6 +807,12 @@ export type AgentConfig = {
|
|
|
790
807
|
* Description of when to use the agent
|
|
791
808
|
*/
|
|
792
809
|
description?: string;
|
|
810
|
+
/**
|
|
811
|
+
* Additional model options passed through to provider
|
|
812
|
+
*/
|
|
813
|
+
options?: {
|
|
814
|
+
[key: string]: unknown;
|
|
815
|
+
};
|
|
793
816
|
mode?: string;
|
|
794
817
|
};
|
|
795
818
|
export type Provider = {
|
|
@@ -918,6 +941,9 @@ export type Agent = {
|
|
|
918
941
|
mode: string;
|
|
919
942
|
topP?: number;
|
|
920
943
|
temperature?: number;
|
|
944
|
+
options: {
|
|
945
|
+
[key: string]: unknown;
|
|
946
|
+
};
|
|
921
947
|
model?: {
|
|
922
948
|
modelID: string;
|
|
923
949
|
providerID: string;
|