@opencode-ai/sdk 1.0.129 → 1.0.130
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 +173 -92
- package/package.json +1 -1
package/dist/gen/types.gen.d.ts
CHANGED
|
@@ -668,6 +668,10 @@ export type KeybindsConfig = {
|
|
|
668
668
|
* Navigate to last message
|
|
669
669
|
*/
|
|
670
670
|
messages_last?: string;
|
|
671
|
+
/**
|
|
672
|
+
* Navigate to last user message
|
|
673
|
+
*/
|
|
674
|
+
messages_last_user?: string;
|
|
671
675
|
/**
|
|
672
676
|
* Copy message
|
|
673
677
|
*/
|
|
@@ -684,6 +688,10 @@ export type KeybindsConfig = {
|
|
|
684
688
|
* Toggle code block concealment in messages
|
|
685
689
|
*/
|
|
686
690
|
messages_toggle_conceal?: string;
|
|
691
|
+
/**
|
|
692
|
+
* Toggle tool details visibility
|
|
693
|
+
*/
|
|
694
|
+
tool_details?: string;
|
|
687
695
|
/**
|
|
688
696
|
* List available models
|
|
689
697
|
*/
|
|
@@ -792,6 +800,74 @@ export type AgentConfig = {
|
|
|
792
800
|
external_directory?: "ask" | "allow" | "deny";
|
|
793
801
|
} | undefined;
|
|
794
802
|
};
|
|
803
|
+
export type ProviderConfig = {
|
|
804
|
+
api?: string;
|
|
805
|
+
name?: string;
|
|
806
|
+
env?: Array<string>;
|
|
807
|
+
id?: string;
|
|
808
|
+
npm?: string;
|
|
809
|
+
models?: {
|
|
810
|
+
[key: string]: {
|
|
811
|
+
id?: string;
|
|
812
|
+
name?: string;
|
|
813
|
+
release_date?: string;
|
|
814
|
+
attachment?: boolean;
|
|
815
|
+
reasoning?: boolean;
|
|
816
|
+
temperature?: boolean;
|
|
817
|
+
tool_call?: boolean;
|
|
818
|
+
cost?: {
|
|
819
|
+
input: number;
|
|
820
|
+
output: number;
|
|
821
|
+
cache_read?: number;
|
|
822
|
+
cache_write?: number;
|
|
823
|
+
context_over_200k?: {
|
|
824
|
+
input: number;
|
|
825
|
+
output: number;
|
|
826
|
+
cache_read?: number;
|
|
827
|
+
cache_write?: number;
|
|
828
|
+
};
|
|
829
|
+
};
|
|
830
|
+
limit?: {
|
|
831
|
+
context: number;
|
|
832
|
+
output: number;
|
|
833
|
+
};
|
|
834
|
+
modalities?: {
|
|
835
|
+
input: Array<"text" | "audio" | "image" | "video" | "pdf">;
|
|
836
|
+
output: Array<"text" | "audio" | "image" | "video" | "pdf">;
|
|
837
|
+
};
|
|
838
|
+
experimental?: boolean;
|
|
839
|
+
status?: "alpha" | "beta" | "deprecated";
|
|
840
|
+
options?: {
|
|
841
|
+
[key: string]: unknown;
|
|
842
|
+
};
|
|
843
|
+
headers?: {
|
|
844
|
+
[key: string]: string;
|
|
845
|
+
};
|
|
846
|
+
provider?: {
|
|
847
|
+
npm: string;
|
|
848
|
+
};
|
|
849
|
+
};
|
|
850
|
+
};
|
|
851
|
+
whitelist?: Array<string>;
|
|
852
|
+
blacklist?: Array<string>;
|
|
853
|
+
options?: {
|
|
854
|
+
apiKey?: string;
|
|
855
|
+
baseURL?: string;
|
|
856
|
+
/**
|
|
857
|
+
* GitHub Enterprise URL for copilot authentication
|
|
858
|
+
*/
|
|
859
|
+
enterpriseUrl?: string;
|
|
860
|
+
/**
|
|
861
|
+
* Enable promptCacheKey for this provider (default false)
|
|
862
|
+
*/
|
|
863
|
+
setCacheKey?: boolean;
|
|
864
|
+
/**
|
|
865
|
+
* Timeout in milliseconds for requests to this provider. Default is 300000 (5 minutes). Set to false to disable timeout.
|
|
866
|
+
*/
|
|
867
|
+
timeout?: number | false;
|
|
868
|
+
[key: string]: unknown | string | boolean | (number | false) | undefined;
|
|
869
|
+
};
|
|
870
|
+
};
|
|
795
871
|
export type McpLocalConfig = {
|
|
796
872
|
/**
|
|
797
873
|
* Type of MCP server connection
|
|
@@ -947,74 +1023,7 @@ export type Config = {
|
|
|
947
1023
|
* Custom provider configurations and model overrides
|
|
948
1024
|
*/
|
|
949
1025
|
provider?: {
|
|
950
|
-
[key: string]:
|
|
951
|
-
api?: string;
|
|
952
|
-
name?: string;
|
|
953
|
-
env?: Array<string>;
|
|
954
|
-
id?: string;
|
|
955
|
-
npm?: string;
|
|
956
|
-
models?: {
|
|
957
|
-
[key: string]: {
|
|
958
|
-
id?: string;
|
|
959
|
-
name?: string;
|
|
960
|
-
release_date?: string;
|
|
961
|
-
attachment?: boolean;
|
|
962
|
-
reasoning?: boolean;
|
|
963
|
-
temperature?: boolean;
|
|
964
|
-
tool_call?: boolean;
|
|
965
|
-
cost?: {
|
|
966
|
-
input: number;
|
|
967
|
-
output: number;
|
|
968
|
-
cache_read?: number;
|
|
969
|
-
cache_write?: number;
|
|
970
|
-
context_over_200k?: {
|
|
971
|
-
input: number;
|
|
972
|
-
output: number;
|
|
973
|
-
cache_read?: number;
|
|
974
|
-
cache_write?: number;
|
|
975
|
-
};
|
|
976
|
-
};
|
|
977
|
-
limit?: {
|
|
978
|
-
context: number;
|
|
979
|
-
output: number;
|
|
980
|
-
};
|
|
981
|
-
modalities?: {
|
|
982
|
-
input: Array<"text" | "audio" | "image" | "video" | "pdf">;
|
|
983
|
-
output: Array<"text" | "audio" | "image" | "video" | "pdf">;
|
|
984
|
-
};
|
|
985
|
-
experimental?: boolean;
|
|
986
|
-
status?: "alpha" | "beta" | "deprecated";
|
|
987
|
-
options?: {
|
|
988
|
-
[key: string]: unknown;
|
|
989
|
-
};
|
|
990
|
-
headers?: {
|
|
991
|
-
[key: string]: string;
|
|
992
|
-
};
|
|
993
|
-
provider?: {
|
|
994
|
-
npm: string;
|
|
995
|
-
};
|
|
996
|
-
};
|
|
997
|
-
};
|
|
998
|
-
whitelist?: Array<string>;
|
|
999
|
-
blacklist?: Array<string>;
|
|
1000
|
-
options?: {
|
|
1001
|
-
apiKey?: string;
|
|
1002
|
-
baseURL?: string;
|
|
1003
|
-
/**
|
|
1004
|
-
* GitHub Enterprise URL for copilot authentication
|
|
1005
|
-
*/
|
|
1006
|
-
enterpriseUrl?: string;
|
|
1007
|
-
/**
|
|
1008
|
-
* Enable promptCacheKey for this provider (default false)
|
|
1009
|
-
*/
|
|
1010
|
-
setCacheKey?: boolean;
|
|
1011
|
-
/**
|
|
1012
|
-
* Timeout in milliseconds for requests to this provider. Default is 300000 (5 minutes). Set to false to disable timeout.
|
|
1013
|
-
*/
|
|
1014
|
-
timeout?: number | false;
|
|
1015
|
-
[key: string]: unknown | string | boolean | (number | false) | undefined;
|
|
1016
|
-
};
|
|
1017
|
-
};
|
|
1026
|
+
[key: string]: ProviderConfig;
|
|
1018
1027
|
};
|
|
1019
1028
|
/**
|
|
1020
1029
|
* MCP (Model Context Protocol) server configurations
|
|
@@ -1096,6 +1105,10 @@ export type Config = {
|
|
|
1096
1105
|
* Enable the batch tool
|
|
1097
1106
|
*/
|
|
1098
1107
|
batch_tool?: boolean;
|
|
1108
|
+
/**
|
|
1109
|
+
* Tools that should only be available to primary agents.
|
|
1110
|
+
*/
|
|
1111
|
+
primary_tools?: Array<string>;
|
|
1099
1112
|
};
|
|
1100
1113
|
};
|
|
1101
1114
|
export type BadRequestError = {
|
|
@@ -1176,50 +1189,70 @@ export type Command = {
|
|
|
1176
1189
|
};
|
|
1177
1190
|
export type Model = {
|
|
1178
1191
|
id: string;
|
|
1192
|
+
providerID: string;
|
|
1193
|
+
api: {
|
|
1194
|
+
id: string;
|
|
1195
|
+
url: string;
|
|
1196
|
+
npm: string;
|
|
1197
|
+
};
|
|
1179
1198
|
name: string;
|
|
1180
|
-
|
|
1181
|
-
|
|
1182
|
-
|
|
1183
|
-
|
|
1184
|
-
|
|
1199
|
+
capabilities: {
|
|
1200
|
+
temperature: boolean;
|
|
1201
|
+
reasoning: boolean;
|
|
1202
|
+
attachment: boolean;
|
|
1203
|
+
toolcall: boolean;
|
|
1204
|
+
input: {
|
|
1205
|
+
text: boolean;
|
|
1206
|
+
audio: boolean;
|
|
1207
|
+
image: boolean;
|
|
1208
|
+
video: boolean;
|
|
1209
|
+
pdf: boolean;
|
|
1210
|
+
};
|
|
1211
|
+
output: {
|
|
1212
|
+
text: boolean;
|
|
1213
|
+
audio: boolean;
|
|
1214
|
+
image: boolean;
|
|
1215
|
+
video: boolean;
|
|
1216
|
+
pdf: boolean;
|
|
1217
|
+
};
|
|
1218
|
+
};
|
|
1185
1219
|
cost: {
|
|
1186
1220
|
input: number;
|
|
1187
1221
|
output: number;
|
|
1188
|
-
|
|
1189
|
-
|
|
1190
|
-
|
|
1222
|
+
cache: {
|
|
1223
|
+
read: number;
|
|
1224
|
+
write: number;
|
|
1225
|
+
};
|
|
1226
|
+
experimentalOver200K?: {
|
|
1191
1227
|
input: number;
|
|
1192
1228
|
output: number;
|
|
1193
|
-
|
|
1194
|
-
|
|
1229
|
+
cache: {
|
|
1230
|
+
read: number;
|
|
1231
|
+
write: number;
|
|
1232
|
+
};
|
|
1195
1233
|
};
|
|
1196
1234
|
};
|
|
1197
1235
|
limit: {
|
|
1198
1236
|
context: number;
|
|
1199
1237
|
output: number;
|
|
1200
1238
|
};
|
|
1201
|
-
|
|
1202
|
-
input: Array<"text" | "audio" | "image" | "video" | "pdf">;
|
|
1203
|
-
output: Array<"text" | "audio" | "image" | "video" | "pdf">;
|
|
1204
|
-
};
|
|
1205
|
-
experimental?: boolean;
|
|
1206
|
-
status?: "alpha" | "beta" | "deprecated";
|
|
1239
|
+
status: "alpha" | "beta" | "deprecated" | "active";
|
|
1207
1240
|
options: {
|
|
1208
1241
|
[key: string]: unknown;
|
|
1209
1242
|
};
|
|
1210
|
-
headers
|
|
1243
|
+
headers: {
|
|
1211
1244
|
[key: string]: string;
|
|
1212
1245
|
};
|
|
1213
|
-
provider?: {
|
|
1214
|
-
npm: string;
|
|
1215
|
-
};
|
|
1216
1246
|
};
|
|
1217
1247
|
export type Provider = {
|
|
1218
|
-
|
|
1248
|
+
id: string;
|
|
1219
1249
|
name: string;
|
|
1250
|
+
source: "env" | "config" | "custom" | "api";
|
|
1220
1251
|
env: Array<string>;
|
|
1221
|
-
|
|
1222
|
-
|
|
1252
|
+
key?: string;
|
|
1253
|
+
options: {
|
|
1254
|
+
[key: string]: unknown;
|
|
1255
|
+
};
|
|
1223
1256
|
models: {
|
|
1224
1257
|
[key: string]: Model;
|
|
1225
1258
|
};
|
|
@@ -2307,7 +2340,55 @@ export type ProviderListResponses = {
|
|
|
2307
2340
|
* List of providers
|
|
2308
2341
|
*/
|
|
2309
2342
|
200: {
|
|
2310
|
-
all: Array<
|
|
2343
|
+
all: Array<{
|
|
2344
|
+
api?: string;
|
|
2345
|
+
name: string;
|
|
2346
|
+
env: Array<string>;
|
|
2347
|
+
id: string;
|
|
2348
|
+
npm?: string;
|
|
2349
|
+
models: {
|
|
2350
|
+
[key: string]: {
|
|
2351
|
+
id: string;
|
|
2352
|
+
name: string;
|
|
2353
|
+
release_date: string;
|
|
2354
|
+
attachment: boolean;
|
|
2355
|
+
reasoning: boolean;
|
|
2356
|
+
temperature: boolean;
|
|
2357
|
+
tool_call: boolean;
|
|
2358
|
+
cost?: {
|
|
2359
|
+
input: number;
|
|
2360
|
+
output: number;
|
|
2361
|
+
cache_read?: number;
|
|
2362
|
+
cache_write?: number;
|
|
2363
|
+
context_over_200k?: {
|
|
2364
|
+
input: number;
|
|
2365
|
+
output: number;
|
|
2366
|
+
cache_read?: number;
|
|
2367
|
+
cache_write?: number;
|
|
2368
|
+
};
|
|
2369
|
+
};
|
|
2370
|
+
limit: {
|
|
2371
|
+
context: number;
|
|
2372
|
+
output: number;
|
|
2373
|
+
};
|
|
2374
|
+
modalities?: {
|
|
2375
|
+
input: Array<"text" | "audio" | "image" | "video" | "pdf">;
|
|
2376
|
+
output: Array<"text" | "audio" | "image" | "video" | "pdf">;
|
|
2377
|
+
};
|
|
2378
|
+
experimental?: boolean;
|
|
2379
|
+
status?: "alpha" | "beta" | "deprecated";
|
|
2380
|
+
options: {
|
|
2381
|
+
[key: string]: unknown;
|
|
2382
|
+
};
|
|
2383
|
+
headers?: {
|
|
2384
|
+
[key: string]: string;
|
|
2385
|
+
};
|
|
2386
|
+
provider?: {
|
|
2387
|
+
npm: string;
|
|
2388
|
+
};
|
|
2389
|
+
};
|
|
2390
|
+
};
|
|
2391
|
+
}>;
|
|
2311
2392
|
default: {
|
|
2312
2393
|
[key: string]: string;
|
|
2313
2394
|
};
|