@opencode/schema 0.0.0-dev-1285 → 0.0.0-dev-1288
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/agent.d.ts +9 -0
- package/dist/config/experimental.d.ts +0 -1
- package/dist/config/flag.d.ts +0 -1
- package/dist/config/flag.js +0 -1
- package/dist/config/provider.d.ts +45 -0
- package/dist/provider.d.ts +61 -0
- package/dist/provider.js +7 -0
- package/package.json +1 -1
package/dist/agent.d.ts
CHANGED
|
@@ -93,6 +93,15 @@ export declare const Info: Schema.Struct<{
|
|
|
93
93
|
}>>, never, never>;
|
|
94
94
|
readonly transport: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Literals<readonly ["http", "websocket"]>>>, Schema.optionalKey<Schema.Literals<readonly ["http", "websocket"]>>, never, never>;
|
|
95
95
|
readonly encoding: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Literals<readonly ["zstd", "gzip", "none"]>>>, Schema.optionalKey<Schema.Literals<readonly ["zstd", "gzip", "none"]>>, never, never>;
|
|
96
|
+
readonly tls: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Struct<{
|
|
97
|
+
readonly cert: Schema.String;
|
|
98
|
+
readonly key: Schema.String;
|
|
99
|
+
readonly passphrase: Schema.decodeTo<Schema.optional<Schema.toType<Schema.String>>, Schema.optionalKey<Schema.String>, never, never>;
|
|
100
|
+
}>>>, Schema.optionalKey<Schema.Struct<{
|
|
101
|
+
readonly cert: Schema.String;
|
|
102
|
+
readonly key: Schema.String;
|
|
103
|
+
readonly passphrase: Schema.decodeTo<Schema.optional<Schema.toType<Schema.String>>, Schema.optionalKey<Schema.String>, never, never>;
|
|
104
|
+
}>>, never, never>;
|
|
96
105
|
}>, readonly [Schema.$Record<Schema.String, Schema.Any>]>>;
|
|
97
106
|
readonly headers: Schema.$Record<Schema.String, Schema.String>;
|
|
98
107
|
readonly body: Schema.$Record<Schema.String, Schema.Any>;
|
|
@@ -67,7 +67,6 @@ declare const Info_base: Schema.Class<Info, Schema.Struct<{
|
|
|
67
67
|
readonly mcp_events: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Boolean>>, Schema.optionalKey<Schema.Boolean>, never, never>;
|
|
68
68
|
readonly media_blob: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Boolean>>, Schema.optionalKey<Schema.Boolean>, never, never>;
|
|
69
69
|
readonly schedules: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Boolean>>, Schema.optionalKey<Schema.Boolean>, never, never>;
|
|
70
|
-
readonly shell_timeout_background: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Boolean>>, Schema.optionalKey<Schema.Boolean>, never, never>;
|
|
71
70
|
readonly todo: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Boolean>>, Schema.optionalKey<Schema.Boolean>, never, never>;
|
|
72
71
|
}>, {}>;
|
|
73
72
|
export declare class Info extends Info_base {
|
package/dist/config/flag.d.ts
CHANGED
|
@@ -12,7 +12,6 @@ export declare const registry: {
|
|
|
12
12
|
readonly media_blob: "Store new session media once in a deduplicated blob table instead of inline in every message row.";
|
|
13
13
|
readonly schedules: "Enable experimental scheduled tasks that wake a session with a prompt.";
|
|
14
14
|
readonly artifacts: "Enable experimental artifacts backed by pluggable providers.";
|
|
15
|
-
readonly shell_timeout_background: "Move foreground shell commands to the background when their timeout expires.";
|
|
16
15
|
readonly console_watches: "Watch Slack threads, GitHub pull requests, issues, commits and Actions runs, and the workspace's MCP servers' events through OpenCode Console, and wake sessions when they change.";
|
|
17
16
|
readonly mcp_events: "Enable experimental MCP Events, a draft MCP extension: declare support to MCP servers and read the events of servers that offer them.";
|
|
18
17
|
};
|
package/dist/config/flag.js
CHANGED
|
@@ -12,7 +12,6 @@ export const registry = {
|
|
|
12
12
|
media_blob: "Store new session media once in a deduplicated blob table instead of inline in every message row.",
|
|
13
13
|
schedules: "Enable experimental scheduled tasks that wake a session with a prompt.",
|
|
14
14
|
artifacts: "Enable experimental artifacts backed by pluggable providers.",
|
|
15
|
-
shell_timeout_background: "Move foreground shell commands to the background when their timeout expires.",
|
|
16
15
|
console_watches: "Watch Slack threads, GitHub pull requests, issues, commits and Actions runs, and the workspace's MCP servers' events through OpenCode Console, and wake sessions when they change.",
|
|
17
16
|
mcp_events: "Enable experimental MCP Events, a draft MCP extension: declare support to MCP servers and read the events of servers that offer them.",
|
|
18
17
|
};
|
|
@@ -35,6 +35,15 @@ export declare const Settings: Schema.StructWithRest<Schema.Struct<{
|
|
|
35
35
|
}>>, never, never>;
|
|
36
36
|
readonly transport: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Literals<readonly ["http", "websocket"]>>>, Schema.optionalKey<Schema.Literals<readonly ["http", "websocket"]>>, never, never>;
|
|
37
37
|
readonly encoding: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Literals<readonly ["zstd", "gzip", "none"]>>>, Schema.optionalKey<Schema.Literals<readonly ["zstd", "gzip", "none"]>>, never, never>;
|
|
38
|
+
readonly tls: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Struct<{
|
|
39
|
+
readonly cert: Schema.String;
|
|
40
|
+
readonly key: Schema.String;
|
|
41
|
+
readonly passphrase: Schema.decodeTo<Schema.optional<Schema.toType<Schema.String>>, Schema.optionalKey<Schema.String>, never, never>;
|
|
42
|
+
}>>>, Schema.optionalKey<Schema.Struct<{
|
|
43
|
+
readonly cert: Schema.String;
|
|
44
|
+
readonly key: Schema.String;
|
|
45
|
+
readonly passphrase: Schema.decodeTo<Schema.optional<Schema.toType<Schema.String>>, Schema.optionalKey<Schema.String>, never, never>;
|
|
46
|
+
}>>, never, never>;
|
|
38
47
|
}>, readonly [Schema.$Record<Schema.String, Schema.UndefinedOr<Schema.Codec<Schema.Json, Schema.Json, never, never>>>]>;
|
|
39
48
|
export type Settings = typeof Settings.Type;
|
|
40
49
|
export declare const ModelSettings: Schema.StructWithRest<Schema.Struct<{
|
|
@@ -104,6 +113,15 @@ export declare const Overlays: {
|
|
|
104
113
|
}>>, never, never>;
|
|
105
114
|
readonly transport: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Literals<readonly ["http", "websocket"]>>>, Schema.optionalKey<Schema.Literals<readonly ["http", "websocket"]>>, never, never>;
|
|
106
115
|
readonly encoding: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Literals<readonly ["zstd", "gzip", "none"]>>>, Schema.optionalKey<Schema.Literals<readonly ["zstd", "gzip", "none"]>>, never, never>;
|
|
116
|
+
readonly tls: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Struct<{
|
|
117
|
+
readonly cert: Schema.String;
|
|
118
|
+
readonly key: Schema.String;
|
|
119
|
+
readonly passphrase: Schema.decodeTo<Schema.optional<Schema.toType<Schema.String>>, Schema.optionalKey<Schema.String>, never, never>;
|
|
120
|
+
}>>>, Schema.optionalKey<Schema.Struct<{
|
|
121
|
+
readonly cert: Schema.String;
|
|
122
|
+
readonly key: Schema.String;
|
|
123
|
+
readonly passphrase: Schema.decodeTo<Schema.optional<Schema.toType<Schema.String>>, Schema.optionalKey<Schema.String>, never, never>;
|
|
124
|
+
}>>, never, never>;
|
|
107
125
|
}>, readonly [Schema.$Record<Schema.String, Schema.UndefinedOr<Schema.Codec<Schema.Json, Schema.Json, never, never>>>]>>>, Schema.optionalKey<Schema.StructWithRest<Schema.Struct<{
|
|
108
126
|
readonly timeout: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Union<readonly [Schema.Finite, Schema.Literal<false>]>>>, Schema.optionalKey<Schema.Union<readonly [Schema.Finite, Schema.Literal<false>]>>, never, never>;
|
|
109
127
|
readonly headerTimeout: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Union<readonly [Schema.Finite, Schema.Literal<false>]>>>, Schema.optionalKey<Schema.Union<readonly [Schema.Finite, Schema.Literal<false>]>>, never, never>;
|
|
@@ -138,6 +156,15 @@ export declare const Overlays: {
|
|
|
138
156
|
}>>, never, never>;
|
|
139
157
|
readonly transport: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Literals<readonly ["http", "websocket"]>>>, Schema.optionalKey<Schema.Literals<readonly ["http", "websocket"]>>, never, never>;
|
|
140
158
|
readonly encoding: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Literals<readonly ["zstd", "gzip", "none"]>>>, Schema.optionalKey<Schema.Literals<readonly ["zstd", "gzip", "none"]>>, never, never>;
|
|
159
|
+
readonly tls: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Struct<{
|
|
160
|
+
readonly cert: Schema.String;
|
|
161
|
+
readonly key: Schema.String;
|
|
162
|
+
readonly passphrase: Schema.decodeTo<Schema.optional<Schema.toType<Schema.String>>, Schema.optionalKey<Schema.String>, never, never>;
|
|
163
|
+
}>>>, Schema.optionalKey<Schema.Struct<{
|
|
164
|
+
readonly cert: Schema.String;
|
|
165
|
+
readonly key: Schema.String;
|
|
166
|
+
readonly passphrase: Schema.decodeTo<Schema.optional<Schema.toType<Schema.String>>, Schema.optionalKey<Schema.String>, never, never>;
|
|
167
|
+
}>>, never, never>;
|
|
141
168
|
}>, readonly [Schema.$Record<Schema.String, Schema.UndefinedOr<Schema.Codec<Schema.Json, Schema.Json, never, never>>>]>>, never, never>;
|
|
142
169
|
headers: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.String, Schema.String>>>, Schema.optionalKey<Schema.$Record<Schema.String, Schema.String>>, never, never>;
|
|
143
170
|
body: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.String, Schema.Codec<Schema.Json, Schema.Json, never, never>>>>, Schema.optionalKey<Schema.$Record<Schema.String, Schema.Codec<Schema.Json, Schema.Json, never, never>>>, never, never>;
|
|
@@ -460,6 +487,15 @@ declare const Info_base: Schema.Class<Info, Schema.Struct<{
|
|
|
460
487
|
}>>, never, never>;
|
|
461
488
|
readonly transport: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Literals<readonly ["http", "websocket"]>>>, Schema.optionalKey<Schema.Literals<readonly ["http", "websocket"]>>, never, never>;
|
|
462
489
|
readonly encoding: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Literals<readonly ["zstd", "gzip", "none"]>>>, Schema.optionalKey<Schema.Literals<readonly ["zstd", "gzip", "none"]>>, never, never>;
|
|
490
|
+
readonly tls: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Struct<{
|
|
491
|
+
readonly cert: Schema.String;
|
|
492
|
+
readonly key: Schema.String;
|
|
493
|
+
readonly passphrase: Schema.decodeTo<Schema.optional<Schema.toType<Schema.String>>, Schema.optionalKey<Schema.String>, never, never>;
|
|
494
|
+
}>>>, Schema.optionalKey<Schema.Struct<{
|
|
495
|
+
readonly cert: Schema.String;
|
|
496
|
+
readonly key: Schema.String;
|
|
497
|
+
readonly passphrase: Schema.decodeTo<Schema.optional<Schema.toType<Schema.String>>, Schema.optionalKey<Schema.String>, never, never>;
|
|
498
|
+
}>>, never, never>;
|
|
463
499
|
}>, readonly [Schema.$Record<Schema.String, Schema.UndefinedOr<Schema.Codec<Schema.Json, Schema.Json, never, never>>>]>>>, Schema.optionalKey<Schema.StructWithRest<Schema.Struct<{
|
|
464
500
|
readonly timeout: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Union<readonly [Schema.Finite, Schema.Literal<false>]>>>, Schema.optionalKey<Schema.Union<readonly [Schema.Finite, Schema.Literal<false>]>>, never, never>;
|
|
465
501
|
readonly headerTimeout: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Union<readonly [Schema.Finite, Schema.Literal<false>]>>>, Schema.optionalKey<Schema.Union<readonly [Schema.Finite, Schema.Literal<false>]>>, never, never>;
|
|
@@ -494,6 +530,15 @@ declare const Info_base: Schema.Class<Info, Schema.Struct<{
|
|
|
494
530
|
}>>, never, never>;
|
|
495
531
|
readonly transport: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Literals<readonly ["http", "websocket"]>>>, Schema.optionalKey<Schema.Literals<readonly ["http", "websocket"]>>, never, never>;
|
|
496
532
|
readonly encoding: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Literals<readonly ["zstd", "gzip", "none"]>>>, Schema.optionalKey<Schema.Literals<readonly ["zstd", "gzip", "none"]>>, never, never>;
|
|
533
|
+
readonly tls: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Struct<{
|
|
534
|
+
readonly cert: Schema.String;
|
|
535
|
+
readonly key: Schema.String;
|
|
536
|
+
readonly passphrase: Schema.decodeTo<Schema.optional<Schema.toType<Schema.String>>, Schema.optionalKey<Schema.String>, never, never>;
|
|
537
|
+
}>>>, Schema.optionalKey<Schema.Struct<{
|
|
538
|
+
readonly cert: Schema.String;
|
|
539
|
+
readonly key: Schema.String;
|
|
540
|
+
readonly passphrase: Schema.decodeTo<Schema.optional<Schema.toType<Schema.String>>, Schema.optionalKey<Schema.String>, never, never>;
|
|
541
|
+
}>>, never, never>;
|
|
497
542
|
}>, readonly [Schema.$Record<Schema.String, Schema.UndefinedOr<Schema.Codec<Schema.Json, Schema.Json, never, never>>>]>>, never, never>;
|
|
498
543
|
readonly headers: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.String, Schema.String>>>, Schema.optionalKey<Schema.$Record<Schema.String, Schema.String>>, never, never>;
|
|
499
544
|
readonly body: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.String, Schema.Codec<Schema.Json, Schema.Json, never, never>>>>, Schema.optionalKey<Schema.$Record<Schema.String, Schema.Codec<Schema.Json, Schema.Json, never, never>>>, never, never>;
|
package/dist/provider.d.ts
CHANGED
|
@@ -120,6 +120,13 @@ export type Cache = typeof Cache.Type;
|
|
|
120
120
|
/** HTTP request body compression; only endpoints known to decode it should enable it. */
|
|
121
121
|
export declare const Encoding: Schema.Literals<readonly ["zstd", "gzip", "none"]>;
|
|
122
122
|
export type Encoding = typeof Encoding.Type;
|
|
123
|
+
/** Client certificate for gateways that require mutual TLS. Values are PEM text; use `{file:...}` to read a file. */
|
|
124
|
+
export declare const Tls: Schema.Struct<{
|
|
125
|
+
readonly cert: Schema.String;
|
|
126
|
+
readonly key: Schema.String;
|
|
127
|
+
readonly passphrase: Schema.decodeTo<Schema.optional<Schema.toType<Schema.String>>, Schema.optionalKey<Schema.String>, never, never>;
|
|
128
|
+
}>;
|
|
129
|
+
export type Tls = typeof Tls.Type;
|
|
123
130
|
export declare const Settings: Schema.StructWithRest<Schema.Struct<{
|
|
124
131
|
readonly timeout: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Union<readonly [Schema.Finite, Schema.Literal<false>]>>>, Schema.optionalKey<Schema.Union<readonly [Schema.Finite, Schema.Literal<false>]>>, never, never>;
|
|
125
132
|
readonly headerTimeout: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Union<readonly [Schema.Finite, Schema.Literal<false>]>>>, Schema.optionalKey<Schema.Union<readonly [Schema.Finite, Schema.Literal<false>]>>, never, never>;
|
|
@@ -154,6 +161,15 @@ export declare const Settings: Schema.StructWithRest<Schema.Struct<{
|
|
|
154
161
|
}>>, never, never>;
|
|
155
162
|
readonly transport: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Literals<readonly ["http", "websocket"]>>>, Schema.optionalKey<Schema.Literals<readonly ["http", "websocket"]>>, never, never>;
|
|
156
163
|
readonly encoding: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Literals<readonly ["zstd", "gzip", "none"]>>>, Schema.optionalKey<Schema.Literals<readonly ["zstd", "gzip", "none"]>>, never, never>;
|
|
164
|
+
readonly tls: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Struct<{
|
|
165
|
+
readonly cert: Schema.String;
|
|
166
|
+
readonly key: Schema.String;
|
|
167
|
+
readonly passphrase: Schema.decodeTo<Schema.optional<Schema.toType<Schema.String>>, Schema.optionalKey<Schema.String>, never, never>;
|
|
168
|
+
}>>>, Schema.optionalKey<Schema.Struct<{
|
|
169
|
+
readonly cert: Schema.String;
|
|
170
|
+
readonly key: Schema.String;
|
|
171
|
+
readonly passphrase: Schema.decodeTo<Schema.optional<Schema.toType<Schema.String>>, Schema.optionalKey<Schema.String>, never, never>;
|
|
172
|
+
}>>, never, never>;
|
|
157
173
|
}>, readonly [Schema.$Record<Schema.String, Schema.Any>]>;
|
|
158
174
|
export type Settings = typeof Settings.Type;
|
|
159
175
|
export declare const Overlays: {
|
|
@@ -191,6 +207,15 @@ export declare const Overlays: {
|
|
|
191
207
|
}>>, never, never>;
|
|
192
208
|
readonly transport: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Literals<readonly ["http", "websocket"]>>>, Schema.optionalKey<Schema.Literals<readonly ["http", "websocket"]>>, never, never>;
|
|
193
209
|
readonly encoding: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Literals<readonly ["zstd", "gzip", "none"]>>>, Schema.optionalKey<Schema.Literals<readonly ["zstd", "gzip", "none"]>>, never, never>;
|
|
210
|
+
readonly tls: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Struct<{
|
|
211
|
+
readonly cert: Schema.String;
|
|
212
|
+
readonly key: Schema.String;
|
|
213
|
+
readonly passphrase: Schema.decodeTo<Schema.optional<Schema.toType<Schema.String>>, Schema.optionalKey<Schema.String>, never, never>;
|
|
214
|
+
}>>>, Schema.optionalKey<Schema.Struct<{
|
|
215
|
+
readonly cert: Schema.String;
|
|
216
|
+
readonly key: Schema.String;
|
|
217
|
+
readonly passphrase: Schema.decodeTo<Schema.optional<Schema.toType<Schema.String>>, Schema.optionalKey<Schema.String>, never, never>;
|
|
218
|
+
}>>, never, never>;
|
|
194
219
|
}>, readonly [Schema.$Record<Schema.String, Schema.Any>]>>>, Schema.optionalKey<Schema.StructWithRest<Schema.Struct<{
|
|
195
220
|
readonly timeout: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Union<readonly [Schema.Finite, Schema.Literal<false>]>>>, Schema.optionalKey<Schema.Union<readonly [Schema.Finite, Schema.Literal<false>]>>, never, never>;
|
|
196
221
|
readonly headerTimeout: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Union<readonly [Schema.Finite, Schema.Literal<false>]>>>, Schema.optionalKey<Schema.Union<readonly [Schema.Finite, Schema.Literal<false>]>>, never, never>;
|
|
@@ -225,6 +250,15 @@ export declare const Overlays: {
|
|
|
225
250
|
}>>, never, never>;
|
|
226
251
|
readonly transport: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Literals<readonly ["http", "websocket"]>>>, Schema.optionalKey<Schema.Literals<readonly ["http", "websocket"]>>, never, never>;
|
|
227
252
|
readonly encoding: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Literals<readonly ["zstd", "gzip", "none"]>>>, Schema.optionalKey<Schema.Literals<readonly ["zstd", "gzip", "none"]>>, never, never>;
|
|
253
|
+
readonly tls: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Struct<{
|
|
254
|
+
readonly cert: Schema.String;
|
|
255
|
+
readonly key: Schema.String;
|
|
256
|
+
readonly passphrase: Schema.decodeTo<Schema.optional<Schema.toType<Schema.String>>, Schema.optionalKey<Schema.String>, never, never>;
|
|
257
|
+
}>>>, Schema.optionalKey<Schema.Struct<{
|
|
258
|
+
readonly cert: Schema.String;
|
|
259
|
+
readonly key: Schema.String;
|
|
260
|
+
readonly passphrase: Schema.decodeTo<Schema.optional<Schema.toType<Schema.String>>, Schema.optionalKey<Schema.String>, never, never>;
|
|
261
|
+
}>>, never, never>;
|
|
228
262
|
}>, readonly [Schema.$Record<Schema.String, Schema.Any>]>>, never, never>;
|
|
229
263
|
headers: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.String, Schema.String>>>, Schema.optionalKey<Schema.$Record<Schema.String, Schema.String>>, never, never>;
|
|
230
264
|
body: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.String, Schema.Any>>>, Schema.optionalKey<Schema.$Record<Schema.String, Schema.Any>>, never, never>;
|
|
@@ -266,6 +300,15 @@ export declare const Request: Schema.Struct<{
|
|
|
266
300
|
}>>, never, never>;
|
|
267
301
|
readonly transport: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Literals<readonly ["http", "websocket"]>>>, Schema.optionalKey<Schema.Literals<readonly ["http", "websocket"]>>, never, never>;
|
|
268
302
|
readonly encoding: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Literals<readonly ["zstd", "gzip", "none"]>>>, Schema.optionalKey<Schema.Literals<readonly ["zstd", "gzip", "none"]>>, never, never>;
|
|
303
|
+
readonly tls: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Struct<{
|
|
304
|
+
readonly cert: Schema.String;
|
|
305
|
+
readonly key: Schema.String;
|
|
306
|
+
readonly passphrase: Schema.decodeTo<Schema.optional<Schema.toType<Schema.String>>, Schema.optionalKey<Schema.String>, never, never>;
|
|
307
|
+
}>>>, Schema.optionalKey<Schema.Struct<{
|
|
308
|
+
readonly cert: Schema.String;
|
|
309
|
+
readonly key: Schema.String;
|
|
310
|
+
readonly passphrase: Schema.decodeTo<Schema.optional<Schema.toType<Schema.String>>, Schema.optionalKey<Schema.String>, never, never>;
|
|
311
|
+
}>>, never, never>;
|
|
269
312
|
}>, readonly [Schema.$Record<Schema.String, Schema.Any>]>>;
|
|
270
313
|
readonly headers: Schema.$Record<Schema.String, Schema.String>;
|
|
271
314
|
readonly body: Schema.$Record<Schema.String, Schema.Any>;
|
|
@@ -307,6 +350,15 @@ export declare const Info: Schema.Struct<{
|
|
|
307
350
|
}>>, never, never>;
|
|
308
351
|
readonly transport: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Literals<readonly ["http", "websocket"]>>>, Schema.optionalKey<Schema.Literals<readonly ["http", "websocket"]>>, never, never>;
|
|
309
352
|
readonly encoding: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Literals<readonly ["zstd", "gzip", "none"]>>>, Schema.optionalKey<Schema.Literals<readonly ["zstd", "gzip", "none"]>>, never, never>;
|
|
353
|
+
readonly tls: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Struct<{
|
|
354
|
+
readonly cert: Schema.String;
|
|
355
|
+
readonly key: Schema.String;
|
|
356
|
+
readonly passphrase: Schema.decodeTo<Schema.optional<Schema.toType<Schema.String>>, Schema.optionalKey<Schema.String>, never, never>;
|
|
357
|
+
}>>>, Schema.optionalKey<Schema.Struct<{
|
|
358
|
+
readonly cert: Schema.String;
|
|
359
|
+
readonly key: Schema.String;
|
|
360
|
+
readonly passphrase: Schema.decodeTo<Schema.optional<Schema.toType<Schema.String>>, Schema.optionalKey<Schema.String>, never, never>;
|
|
361
|
+
}>>, never, never>;
|
|
310
362
|
}>, readonly [Schema.$Record<Schema.String, Schema.Any>]>>>, Schema.optionalKey<Schema.StructWithRest<Schema.Struct<{
|
|
311
363
|
readonly timeout: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Union<readonly [Schema.Finite, Schema.Literal<false>]>>>, Schema.optionalKey<Schema.Union<readonly [Schema.Finite, Schema.Literal<false>]>>, never, never>;
|
|
312
364
|
readonly headerTimeout: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Union<readonly [Schema.Finite, Schema.Literal<false>]>>>, Schema.optionalKey<Schema.Union<readonly [Schema.Finite, Schema.Literal<false>]>>, never, never>;
|
|
@@ -341,6 +393,15 @@ export declare const Info: Schema.Struct<{
|
|
|
341
393
|
}>>, never, never>;
|
|
342
394
|
readonly transport: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Literals<readonly ["http", "websocket"]>>>, Schema.optionalKey<Schema.Literals<readonly ["http", "websocket"]>>, never, never>;
|
|
343
395
|
readonly encoding: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Literals<readonly ["zstd", "gzip", "none"]>>>, Schema.optionalKey<Schema.Literals<readonly ["zstd", "gzip", "none"]>>, never, never>;
|
|
396
|
+
readonly tls: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Struct<{
|
|
397
|
+
readonly cert: Schema.String;
|
|
398
|
+
readonly key: Schema.String;
|
|
399
|
+
readonly passphrase: Schema.decodeTo<Schema.optional<Schema.toType<Schema.String>>, Schema.optionalKey<Schema.String>, never, never>;
|
|
400
|
+
}>>>, Schema.optionalKey<Schema.Struct<{
|
|
401
|
+
readonly cert: Schema.String;
|
|
402
|
+
readonly key: Schema.String;
|
|
403
|
+
readonly passphrase: Schema.decodeTo<Schema.optional<Schema.toType<Schema.String>>, Schema.optionalKey<Schema.String>, never, never>;
|
|
404
|
+
}>>, never, never>;
|
|
344
405
|
}>, readonly [Schema.$Record<Schema.String, Schema.Any>]>>, never, never>;
|
|
345
406
|
readonly headers: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.String, Schema.String>>>, Schema.optionalKey<Schema.$Record<Schema.String, Schema.String>>, never, never>;
|
|
346
407
|
readonly body: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.String, Schema.Any>>>, Schema.optionalKey<Schema.$Record<Schema.String, Schema.Any>>, never, never>;
|
package/dist/provider.js
CHANGED
|
@@ -53,6 +53,12 @@ export const Cache = Schema.Struct({
|
|
|
53
53
|
/** HTTP request body compression; only endpoints known to decode it should enable it. */
|
|
54
54
|
export const Encoding = Schema.Literals(["zstd", "gzip", "none"]).annotate({ identifier: "Provider.Encoding" });
|
|
55
55
|
const Timeout = Schema.Union([Schema.Finite, Schema.Literal(false)]).pipe(optional);
|
|
56
|
+
/** Client certificate for gateways that require mutual TLS. Values are PEM text; use `{file:...}` to read a file. */
|
|
57
|
+
export const Tls = Schema.Struct({
|
|
58
|
+
cert: Schema.String.annotate({ description: "PEM client certificate, usually `{file:/path/to/client.pem}`" }),
|
|
59
|
+
key: Schema.String.annotate({ description: "PEM private key, usually `{file:/path/to/client.key}`" }),
|
|
60
|
+
passphrase: Schema.String.pipe(optional).annotate({ description: "Passphrase for an encrypted private key" }),
|
|
61
|
+
}).annotate({ identifier: "Provider.Tls" });
|
|
56
62
|
// The named fields are the settings OpenCode reads itself; every other key is a provider option for the provider package.
|
|
57
63
|
export const Settings = Schema.StructWithRest(Schema.Struct({
|
|
58
64
|
timeout: Timeout,
|
|
@@ -62,6 +68,7 @@ export const Settings = Schema.StructWithRest(Schema.Struct({
|
|
|
62
68
|
cache: Cache.pipe(optional),
|
|
63
69
|
transport: Transport.pipe(optional),
|
|
64
70
|
encoding: Encoding.pipe(optional),
|
|
71
|
+
tls: Tls.pipe(optional),
|
|
65
72
|
}), [Schema.Record(Schema.String, Schema.Any)]).annotate({ identifier: "Provider.Settings" });
|
|
66
73
|
export const Overlays = {
|
|
67
74
|
settings: Settings.pipe(optional),
|