@opencode/protocol 0.0.0-dev-21106 → 0.0.0-dev-21108

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.
@@ -2,7 +2,7 @@ import { Model } from "@opencode/schema/model";
2
2
  import { Schema } from "effect";
3
3
  import { HttpApiEndpoint, HttpApiGroup } from "effect/http-api";
4
4
  import { ServiceUnavailableError } from "../errors.js";
5
- export declare const ModelGroup: HttpApiGroup.HttpApiGroup<"server.model", HttpApiEndpoint.HttpApiEndpoint<"model.list", "GET", "/api/model", never, Schema.toCodecStringTree<Schema.Struct<{
5
+ export declare const ModelGroup: HttpApiGroup.HttpApiGroup<"server.model", HttpApiEndpoint.HttpApiEndpoint<"model.default", "GET", "/api/model/default", never, Schema.toCodecStringTree<Schema.Struct<{
6
6
  readonly location: Schema.optional<Schema.Struct<{
7
7
  readonly directory: Schema.optional<Schema.String>;
8
8
  }>>;
@@ -10,80 +10,7 @@ export declare const ModelGroup: HttpApiGroup.HttpApiGroup<"server.model", HttpA
10
10
  readonly location: Schema.Struct<{
11
11
  readonly directory: Schema.brand<Schema.String, "AbsolutePath">;
12
12
  }>;
13
- readonly data: Schema.$Array<Schema.Struct<{
14
- readonly capabilities: Schema.Struct<{
15
- readonly tools: Schema.Boolean;
16
- readonly input: Schema.$Array<Schema.String>;
17
- readonly output: Schema.$Array<Schema.String>;
18
- readonly temperature: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Boolean>>, Schema.optionalKey<Schema.Boolean>, never, never>;
19
- }> & {
20
- default: () => {
21
- tools: true;
22
- input: string[];
23
- output: string[];
24
- };
25
- };
26
- readonly variants: Schema.$Array<Schema.Struct<{
27
- readonly settings: Schema.decodeTo<Schema.optional<Schema.toType<Schema.StructWithRest<Schema.Struct<{
28
- readonly compaction: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Union<readonly [Schema.Struct<{
29
- readonly type: Schema.Literal<"summary">;
30
- }>, Schema.Struct<{
31
- readonly type: Schema.Literal<"native">;
32
- }>]>>>, Schema.optionalKey<Schema.Union<readonly [Schema.Struct<{
33
- readonly type: Schema.Literal<"summary">;
34
- }>, Schema.Struct<{
35
- readonly type: Schema.Literal<"native">;
36
- }>]>>, never, never>;
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 [Schema.$Record<Schema.String, Schema.Any>]>>>, Schema.optionalKey<Schema.StructWithRest<Schema.Struct<{
39
- readonly compaction: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Union<readonly [Schema.Struct<{
40
- readonly type: Schema.Literal<"summary">;
41
- }>, Schema.Struct<{
42
- readonly type: Schema.Literal<"native">;
43
- }>]>>>, Schema.optionalKey<Schema.Union<readonly [Schema.Struct<{
44
- readonly type: Schema.Literal<"summary">;
45
- }>, Schema.Struct<{
46
- readonly type: Schema.Literal<"native">;
47
- }>]>>, never, never>;
48
- readonly encoding: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Literals<readonly ["zstd", "gzip", "none"]>>>, Schema.optionalKey<Schema.Literals<readonly ["zstd", "gzip", "none"]>>, never, never>;
49
- }>, readonly [Schema.$Record<Schema.String, Schema.Any>]>>, never, never>;
50
- readonly headers: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.String, Schema.String>>>, Schema.optionalKey<Schema.$Record<Schema.String, Schema.String>>, never, never>;
51
- readonly body: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.String, Schema.Any>>>, Schema.optionalKey<Schema.$Record<Schema.String, Schema.Any>>, never, never>;
52
- readonly id: Schema.brand<Schema.String, "Model.VariantID">;
53
- }>>;
54
- readonly time: Schema.Struct<{
55
- readonly released: Schema.Finite;
56
- }>;
57
- readonly cost: Schema.$Array<Schema.Struct<{
58
- readonly tier: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Struct<{
59
- readonly type: Schema.tag<"context">;
60
- readonly size: Schema.Int;
61
- }>>>, Schema.optionalKey<Schema.Struct<{
62
- readonly type: Schema.tag<"context">;
63
- readonly size: Schema.Int;
64
- }>>, never, never>;
65
- readonly input: Schema.brand<Schema.Finite, "Money.USDPerMillionTokens"> & {
66
- zero: number & import("effect/Brand").Brand<"Money.USDPerMillionTokens">;
67
- };
68
- readonly output: Schema.brand<Schema.Finite, "Money.USDPerMillionTokens"> & {
69
- zero: number & import("effect/Brand").Brand<"Money.USDPerMillionTokens">;
70
- };
71
- readonly cache: Schema.Struct<{
72
- readonly read: Schema.brand<Schema.Finite, "Money.USDPerMillionTokens"> & {
73
- zero: number & import("effect/Brand").Brand<"Money.USDPerMillionTokens">;
74
- };
75
- readonly write: Schema.brand<Schema.Finite, "Money.USDPerMillionTokens"> & {
76
- zero: number & import("effect/Brand").Brand<"Money.USDPerMillionTokens">;
77
- };
78
- }>;
79
- }>>;
80
- readonly status: Schema.Literals<readonly ["alpha", "beta", "deprecated", "active"]>;
81
- readonly enabled: Schema.Boolean;
82
- readonly limit: Schema.Struct<{
83
- readonly context: Schema.Int;
84
- readonly input: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Int>>, Schema.optionalKey<Schema.Int>, never, never>;
85
- readonly output: Schema.Int;
86
- }>;
13
+ readonly data: Schema.UndefinedOr<Schema.Struct<{
87
14
  readonly settings: Schema.decodeTo<Schema.optional<Schema.toType<Schema.StructWithRest<Schema.Struct<{
88
15
  readonly compaction: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Union<readonly [Schema.Struct<{
89
16
  readonly type: Schema.Literal<"summary">;
@@ -173,39 +100,6 @@ export declare const ModelGroup: HttpApiGroup.HttpApiGroup<"server.model", HttpA
173
100
  readonly supportsEffortUpdates: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Boolean>>, Schema.optionalKey<Schema.Boolean>, never, never>;
174
101
  }>>, never, never>;
175
102
  readonly package: Schema.decodeTo<Schema.optional<Schema.toType<Schema.String>>, Schema.optionalKey<Schema.String>, never, never>;
176
- }> & {
177
- default: (providerID: import("@opencode/schema/provider").ID, id: Model.ID) => {
178
- id: string & import("effect/Brand").Brand<"Model.ID">;
179
- modelID: string & import("effect/Brand").Brand<"Model.ID">;
180
- providerID: string & import("effect/Brand").Brand<"Provider.ID">;
181
- name: string & import("effect/Brand").Brand<"Model.ID">;
182
- capabilities: {
183
- tools: true;
184
- input: string[];
185
- output: string[];
186
- };
187
- variants: never[];
188
- time: {
189
- released: number;
190
- };
191
- cost: never[];
192
- status: "active";
193
- enabled: true;
194
- limit: {
195
- context: number;
196
- output: number;
197
- };
198
- };
199
- }>;
200
- }>>, Schema.toCodecJson<typeof ServiceUnavailableError>, never, never> | HttpApiEndpoint.HttpApiEndpoint<"model.default", "GET", "/api/model/default", never, Schema.toCodecStringTree<Schema.Struct<{
201
- readonly location: Schema.optional<Schema.Struct<{
202
- readonly directory: Schema.optional<Schema.String>;
203
- }>>;
204
- }>>, never, never, Schema.toCodecJson<Schema.Struct<{
205
- readonly location: Schema.Struct<{
206
- readonly directory: Schema.brand<Schema.String, "AbsolutePath">;
207
- }>;
208
- readonly data: Schema.UndefinedOr<Schema.Struct<{
209
103
  readonly capabilities: Schema.Struct<{
210
104
  readonly tools: Schema.Boolean;
211
105
  readonly input: Schema.$Array<Schema.String>;
@@ -279,6 +173,39 @@ export declare const ModelGroup: HttpApiGroup.HttpApiGroup<"server.model", HttpA
279
173
  readonly input: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Int>>, Schema.optionalKey<Schema.Int>, never, never>;
280
174
  readonly output: Schema.Int;
281
175
  }>;
176
+ }> & {
177
+ default: (providerID: import("@opencode/schema/provider").ID, id: Model.ID) => {
178
+ id: string & import("effect/Brand").Brand<"Model.ID">;
179
+ modelID: string & import("effect/Brand").Brand<"Model.ID">;
180
+ providerID: string & import("effect/Brand").Brand<"Provider.ID">;
181
+ name: string & import("effect/Brand").Brand<"Model.ID">;
182
+ capabilities: {
183
+ tools: true;
184
+ input: string[];
185
+ output: string[];
186
+ };
187
+ variants: never[];
188
+ time: {
189
+ released: number;
190
+ };
191
+ cost: never[];
192
+ status: "active";
193
+ enabled: true;
194
+ limit: {
195
+ context: number;
196
+ output: number;
197
+ };
198
+ };
199
+ }>;
200
+ }>>, Schema.toCodecJson<typeof ServiceUnavailableError>, never, never> | HttpApiEndpoint.HttpApiEndpoint<"model.list", "GET", "/api/model", never, Schema.toCodecStringTree<Schema.Struct<{
201
+ readonly location: Schema.optional<Schema.Struct<{
202
+ readonly directory: Schema.optional<Schema.String>;
203
+ }>>;
204
+ }>>, never, never, Schema.toCodecJson<Schema.Struct<{
205
+ readonly location: Schema.Struct<{
206
+ readonly directory: Schema.brand<Schema.String, "AbsolutePath">;
207
+ }>;
208
+ readonly data: Schema.$Array<Schema.Struct<{
282
209
  readonly settings: Schema.decodeTo<Schema.optional<Schema.toType<Schema.StructWithRest<Schema.Struct<{
283
210
  readonly compaction: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Union<readonly [Schema.Struct<{
284
211
  readonly type: Schema.Literal<"summary">;
@@ -368,6 +295,79 @@ export declare const ModelGroup: HttpApiGroup.HttpApiGroup<"server.model", HttpA
368
295
  readonly supportsEffortUpdates: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Boolean>>, Schema.optionalKey<Schema.Boolean>, never, never>;
369
296
  }>>, never, never>;
370
297
  readonly package: Schema.decodeTo<Schema.optional<Schema.toType<Schema.String>>, Schema.optionalKey<Schema.String>, never, never>;
298
+ readonly capabilities: Schema.Struct<{
299
+ readonly tools: Schema.Boolean;
300
+ readonly input: Schema.$Array<Schema.String>;
301
+ readonly output: Schema.$Array<Schema.String>;
302
+ readonly temperature: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Boolean>>, Schema.optionalKey<Schema.Boolean>, never, never>;
303
+ }> & {
304
+ default: () => {
305
+ tools: true;
306
+ input: string[];
307
+ output: string[];
308
+ };
309
+ };
310
+ readonly variants: Schema.$Array<Schema.Struct<{
311
+ readonly settings: Schema.decodeTo<Schema.optional<Schema.toType<Schema.StructWithRest<Schema.Struct<{
312
+ readonly compaction: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Union<readonly [Schema.Struct<{
313
+ readonly type: Schema.Literal<"summary">;
314
+ }>, Schema.Struct<{
315
+ readonly type: Schema.Literal<"native">;
316
+ }>]>>>, Schema.optionalKey<Schema.Union<readonly [Schema.Struct<{
317
+ readonly type: Schema.Literal<"summary">;
318
+ }>, Schema.Struct<{
319
+ readonly type: Schema.Literal<"native">;
320
+ }>]>>, never, never>;
321
+ readonly encoding: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Literals<readonly ["zstd", "gzip", "none"]>>>, Schema.optionalKey<Schema.Literals<readonly ["zstd", "gzip", "none"]>>, never, never>;
322
+ }>, readonly [Schema.$Record<Schema.String, Schema.Any>]>>>, Schema.optionalKey<Schema.StructWithRest<Schema.Struct<{
323
+ readonly compaction: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Union<readonly [Schema.Struct<{
324
+ readonly type: Schema.Literal<"summary">;
325
+ }>, Schema.Struct<{
326
+ readonly type: Schema.Literal<"native">;
327
+ }>]>>>, Schema.optionalKey<Schema.Union<readonly [Schema.Struct<{
328
+ readonly type: Schema.Literal<"summary">;
329
+ }>, Schema.Struct<{
330
+ readonly type: Schema.Literal<"native">;
331
+ }>]>>, never, never>;
332
+ readonly encoding: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Literals<readonly ["zstd", "gzip", "none"]>>>, Schema.optionalKey<Schema.Literals<readonly ["zstd", "gzip", "none"]>>, never, never>;
333
+ }>, readonly [Schema.$Record<Schema.String, Schema.Any>]>>, never, never>;
334
+ readonly headers: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.String, Schema.String>>>, Schema.optionalKey<Schema.$Record<Schema.String, Schema.String>>, never, never>;
335
+ readonly body: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.String, Schema.Any>>>, Schema.optionalKey<Schema.$Record<Schema.String, Schema.Any>>, never, never>;
336
+ readonly id: Schema.brand<Schema.String, "Model.VariantID">;
337
+ }>>;
338
+ readonly time: Schema.Struct<{
339
+ readonly released: Schema.Finite;
340
+ }>;
341
+ readonly cost: Schema.$Array<Schema.Struct<{
342
+ readonly tier: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Struct<{
343
+ readonly type: Schema.tag<"context">;
344
+ readonly size: Schema.Int;
345
+ }>>>, Schema.optionalKey<Schema.Struct<{
346
+ readonly type: Schema.tag<"context">;
347
+ readonly size: Schema.Int;
348
+ }>>, never, never>;
349
+ readonly input: Schema.brand<Schema.Finite, "Money.USDPerMillionTokens"> & {
350
+ zero: number & import("effect/Brand").Brand<"Money.USDPerMillionTokens">;
351
+ };
352
+ readonly output: Schema.brand<Schema.Finite, "Money.USDPerMillionTokens"> & {
353
+ zero: number & import("effect/Brand").Brand<"Money.USDPerMillionTokens">;
354
+ };
355
+ readonly cache: Schema.Struct<{
356
+ readonly read: Schema.brand<Schema.Finite, "Money.USDPerMillionTokens"> & {
357
+ zero: number & import("effect/Brand").Brand<"Money.USDPerMillionTokens">;
358
+ };
359
+ readonly write: Schema.brand<Schema.Finite, "Money.USDPerMillionTokens"> & {
360
+ zero: number & import("effect/Brand").Brand<"Money.USDPerMillionTokens">;
361
+ };
362
+ }>;
363
+ }>>;
364
+ readonly status: Schema.Literals<readonly ["alpha", "beta", "deprecated", "active"]>;
365
+ readonly enabled: Schema.Boolean;
366
+ readonly limit: Schema.Struct<{
367
+ readonly context: Schema.Int;
368
+ readonly input: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Int>>, Schema.optionalKey<Schema.Int>, never, never>;
369
+ readonly output: Schema.Int;
370
+ }>;
371
371
  }> & {
372
372
  default: (providerID: import("@opencode/schema/provider").ID, id: Model.ID) => {
373
373
  id: string & import("effect/Brand").Brand<"Model.ID">;
@@ -85,13 +85,16 @@ export declare const makePermissionGroup: <LocationId extends HttpApiMiddleware.
85
85
  };
86
86
  readonly effect: Schema.Literals<readonly ["allow", "deny", "ask"]>;
87
87
  }>;
88
- }>>, Schema.toCodecJson<typeof SessionNotFoundError>, SessionLocationId, HttpApiMiddleware.Requires<SessionLocationId>> | HttpApiEndpoint.HttpApiEndpoint<"session.permission.list", "GET", "/api/session/:sessionID/permission", Schema.toCodecStringTree<Schema.Struct<{
88
+ }>>, Schema.toCodecJson<typeof SessionNotFoundError>, SessionLocationId, HttpApiMiddleware.Requires<SessionLocationId>> | HttpApiEndpoint.HttpApiEndpoint<"session.permission.get", "GET", "/api/session/:sessionID/permission/:requestID", Schema.toCodecStringTree<Schema.Struct<{
89
89
  sessionID: Schema.brand<Schema.String, "SessionID"> & {
90
90
  create: () => string & import("effect/Brand").Brand<"SessionID">;
91
91
  descending: (id?: string) => string & import("effect/Brand").Brand<"SessionID">;
92
92
  };
93
+ requestID: Schema.brand<Schema.String, "Permission.ID"> & {
94
+ create: (id?: string) => string & import("effect/Brand").Brand<"Permission.ID">;
95
+ };
93
96
  }>>, never, never, never, Schema.toCodecJson<Schema.Struct<{
94
- readonly data: Schema.$Array<Schema.Struct<{
97
+ readonly data: Schema.Struct<{
95
98
  readonly sessionID: Schema.brand<Schema.String, "SessionID"> & {
96
99
  create: () => string & import("effect/Brand").Brand<"SessionID">;
97
100
  descending: (id?: string) => string & import("effect/Brand").Brand<"SessionID">;
@@ -113,17 +116,14 @@ export declare const makePermissionGroup: <LocationId extends HttpApiMiddleware.
113
116
  readonly id: Schema.brand<Schema.String, "Permission.ID"> & {
114
117
  create: (id?: string) => string & import("effect/Brand").Brand<"Permission.ID">;
115
118
  };
116
- }>>;
117
- }>>, Schema.toCodecJson<typeof LocationNotFoundError | typeof SessionNotFoundError>, never, never> | HttpApiEndpoint.HttpApiEndpoint<"session.permission.get", "GET", "/api/session/:sessionID/permission/:requestID", Schema.toCodecStringTree<Schema.Struct<{
119
+ }>;
120
+ }>>, Schema.toCodecJson<typeof SessionNotFoundError | typeof PermissionNotFoundError>, SessionLocationId, HttpApiMiddleware.Requires<SessionLocationId>> | HttpApiEndpoint.HttpApiEndpoint<"session.permission.list", "GET", "/api/session/:sessionID/permission", Schema.toCodecStringTree<Schema.Struct<{
118
121
  sessionID: Schema.brand<Schema.String, "SessionID"> & {
119
122
  create: () => string & import("effect/Brand").Brand<"SessionID">;
120
123
  descending: (id?: string) => string & import("effect/Brand").Brand<"SessionID">;
121
124
  };
122
- requestID: Schema.brand<Schema.String, "Permission.ID"> & {
123
- create: (id?: string) => string & import("effect/Brand").Brand<"Permission.ID">;
124
- };
125
125
  }>>, never, never, never, Schema.toCodecJson<Schema.Struct<{
126
- readonly data: Schema.Struct<{
126
+ readonly data: Schema.$Array<Schema.Struct<{
127
127
  readonly sessionID: Schema.brand<Schema.String, "SessionID"> & {
128
128
  create: () => string & import("effect/Brand").Brand<"SessionID">;
129
129
  descending: (id?: string) => string & import("effect/Brand").Brand<"SessionID">;
@@ -145,8 +145,8 @@ export declare const makePermissionGroup: <LocationId extends HttpApiMiddleware.
145
145
  readonly id: Schema.brand<Schema.String, "Permission.ID"> & {
146
146
  create: (id?: string) => string & import("effect/Brand").Brand<"Permission.ID">;
147
147
  };
148
- }>;
149
- }>>, Schema.toCodecJson<typeof SessionNotFoundError | typeof PermissionNotFoundError>, SessionLocationId, HttpApiMiddleware.Requires<SessionLocationId>> | HttpApiEndpoint.HttpApiEndpoint<"session.permission.reply", "POST", "/api/session/:sessionID/permission/:requestID/reply", Schema.toCodecStringTree<Schema.Struct<{
148
+ }>>;
149
+ }>>, Schema.toCodecJson<typeof LocationNotFoundError | typeof SessionNotFoundError>, never, never> | HttpApiEndpoint.HttpApiEndpoint<"session.permission.reply", "POST", "/api/session/:sessionID/permission/:requestID/reply", Schema.toCodecStringTree<Schema.Struct<{
150
150
  sessionID: Schema.brand<Schema.String, "SessionID"> & {
151
151
  create: () => string & import("effect/Brand").Brand<"SessionID">;
152
152
  descending: (id?: string) => string & import("effect/Brand").Brand<"SessionID">;
@@ -5,65 +5,24 @@ import { PTY_CONNECT_TICKET_QUERY, PTY_CONNECT_TOKEN_HEADER, PTY_CONNECT_TOKEN_H
5
5
  export { PTY_CONNECT_TICKET_QUERY, PTY_CONNECT_TOKEN_HEADER, PTY_CONNECT_TOKEN_HEADER_VALUE };
6
6
  export declare const PERSISTENT_PTY_CONNECT_PATH = "/api/experimental/persistent-pty/:ptyID/connect";
7
7
  export declare function hasPersistentPtyConnectTicketURL(url: URL): boolean;
8
- export declare const PersistentPtyGroup: HttpApiGroup.HttpApiGroup<"server.experimental", HttpApiEndpoint.HttpApiEndpoint<"persistentPty.read", "GET", "/api/experimental/session/:sessionID/terminal/read", Schema.toCodecStringTree<Schema.Struct<{
9
- sessionID: Schema.brand<Schema.String, "SessionID"> & {
10
- create: () => string & import("effect/Brand").Brand<"SessionID">;
11
- descending: (id?: string) => string & import("effect/Brand").Brand<"SessionID">;
8
+ export declare const PersistentPtyGroup: HttpApiGroup.HttpApiGroup<"server.experimental", HttpApiEndpoint.HttpApiEndpoint<"persistentPty.connect", "GET", "/api/experimental/persistent-pty/:ptyID/connect", Schema.toCodecStringTree<Schema.Struct<{
9
+ ptyID: Schema.brand<Schema.String, "PtyID"> & {
10
+ create: () => string & import("effect/Brand").Brand<"PtyID">;
11
+ ascending: (id?: string) => string & import("effect/Brand").Brand<"PtyID">;
12
12
  };
13
- }>>, Schema.toCodecStringTree<Schema.Struct<{
14
- lines: Schema.optional<Schema.compose<Schema.Int, Schema.NumberFromString>>;
15
- }>>, never, never, Schema.toCodecJson<Schema.Struct<{
16
- readonly data: Schema.NullOr<Schema.Struct<{
17
- readonly ptyID: Schema.brand<Schema.String, "PtyID"> & {
18
- create: () => string & import("effect/Brand").Brand<"PtyID">;
19
- ascending: (id?: string) => string & import("effect/Brand").Brand<"PtyID">;
20
- };
21
- readonly title: Schema.String;
22
- readonly cwd: Schema.String;
23
- readonly foregroundProcess: Schema.NullOr<Schema.String>;
24
- readonly screen: Schema.Struct<{
25
- readonly text: Schema.String;
26
- readonly cols: Schema.Int;
27
- readonly rows: Schema.Int;
28
- readonly cursor: Schema.Struct<{
29
- readonly x: Schema.Int;
30
- readonly y: Schema.Int;
31
- }>;
32
- }>;
33
- }>>;
34
- }>>, Schema.toCodecJson<typeof ServiceUnavailableError>, never, never> | HttpApiEndpoint.HttpApiEndpoint<"persistentPty.list", "GET", "/api/experimental/session/:sessionID/terminal", Schema.toCodecStringTree<Schema.Struct<{
35
- sessionID: Schema.brand<Schema.String, "SessionID"> & {
36
- create: () => string & import("effect/Brand").Brand<"SessionID">;
37
- descending: (id?: string) => string & import("effect/Brand").Brand<"SessionID">;
13
+ }>>, never, never, never, Schema.toCodecJson<Schema.Boolean>, Schema.toCodecJson<typeof ServiceUnavailableError | typeof ForbiddenError | typeof PtyNotFoundError>, never, never> | HttpApiEndpoint.HttpApiEndpoint<"persistentPty.connectToken", "POST", "/api/experimental/persistent-pty/:ptyID/connect-token", Schema.toCodecStringTree<Schema.Struct<{
14
+ ptyID: Schema.brand<Schema.String, "PtyID"> & {
15
+ create: () => string & import("effect/Brand").Brand<"PtyID">;
16
+ ascending: (id?: string) => string & import("effect/Brand").Brand<"PtyID">;
38
17
  };
39
- }>>, never, never, never, Schema.toCodecJson<Schema.Struct<{
40
- readonly data: Schema.$Array<Schema.Struct<{
41
- readonly sessionID: Schema.brand<Schema.String, "SessionID"> & {
42
- create: () => string & import("effect/Brand").Brand<"SessionID">;
43
- descending: (id?: string) => string & import("effect/Brand").Brand<"SessionID">;
44
- };
45
- readonly foregroundProcess: Schema.NullOr<Schema.String>;
46
- readonly size: Schema.Struct<{
47
- readonly cols: Schema.Int;
48
- readonly rows: Schema.Int;
49
- }>;
50
- readonly output: Schema.Struct<{
51
- readonly head: Schema.Int;
52
- readonly tail: Schema.Int;
53
- }>;
54
- readonly id: Schema.brand<Schema.String, "PtyID"> & {
55
- create: () => string & import("effect/Brand").Brand<"PtyID">;
56
- ascending: (id?: string) => string & import("effect/Brand").Brand<"PtyID">;
57
- };
58
- readonly title: Schema.String;
59
- readonly command: Schema.String;
60
- readonly args: Schema.$Array<Schema.String>;
61
- readonly cwd: Schema.String;
62
- readonly status: Schema.Literals<readonly ["running", "exited"]>;
63
- readonly pid: Schema.Int;
64
- readonly exitCode: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Int>>, Schema.optionalKey<Schema.Int>, never, never>;
65
- }>>;
66
- }>>, Schema.toCodecJson<typeof InvalidRequestError | typeof ServiceUnavailableError>, never, never> | HttpApiEndpoint.HttpApiEndpoint<"persistentPty.create", "POST", "/api/experimental/session/:sessionID/terminal", Schema.toCodecStringTree<Schema.Struct<{
18
+ }>>, never, never, Schema.toCodecStringTree<Schema.Struct<{
19
+ readonly "x-opencode-ticket": Schema.optional<Schema.String>;
20
+ }>>, Schema.toCodecJson<Schema.Struct<{
21
+ readonly data: Schema.Struct<{
22
+ readonly ticket: Schema.String;
23
+ readonly expires_in: Schema.Int;
24
+ }>;
25
+ }>>, Schema.toCodecJson<typeof ServiceUnavailableError | typeof ForbiddenError | typeof PtyNotFoundError>, never, never> | HttpApiEndpoint.HttpApiEndpoint<"persistentPty.create", "POST", "/api/experimental/session/:sessionID/terminal", Schema.toCodecStringTree<Schema.Struct<{
67
26
  sessionID: Schema.brand<Schema.String, "SessionID"> & {
68
27
  create: () => string & import("effect/Brand").Brand<"SessionID">;
69
28
  descending: (id?: string) => string & import("effect/Brand").Brand<"SessionID">;
@@ -83,6 +42,17 @@ export declare const PersistentPtyGroup: HttpApiGroup.HttpApiGroup<"server.exper
83
42
  }>>, never, never>;
84
43
  }>>, never, Schema.toCodecJson<Schema.Struct<{
85
44
  readonly data: Schema.Struct<{
45
+ readonly id: Schema.brand<Schema.String, "PtyID"> & {
46
+ create: () => string & import("effect/Brand").Brand<"PtyID">;
47
+ ascending: (id?: string) => string & import("effect/Brand").Brand<"PtyID">;
48
+ };
49
+ readonly title: Schema.String;
50
+ readonly command: Schema.String;
51
+ readonly args: Schema.$Array<Schema.String>;
52
+ readonly cwd: Schema.String;
53
+ readonly status: Schema.Literals<readonly ["running", "exited"]>;
54
+ readonly pid: Schema.Int;
55
+ readonly exitCode: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Int>>, Schema.optionalKey<Schema.Int>, never, never>;
86
56
  readonly sessionID: Schema.brand<Schema.String, "SessionID"> & {
87
57
  create: () => string & import("effect/Brand").Brand<"SessionID">;
88
58
  descending: (id?: string) => string & import("effect/Brand").Brand<"SessionID">;
@@ -96,6 +66,14 @@ export declare const PersistentPtyGroup: HttpApiGroup.HttpApiGroup<"server.exper
96
66
  readonly head: Schema.Int;
97
67
  readonly tail: Schema.Int;
98
68
  }>;
69
+ }>;
70
+ }>>, Schema.toCodecJson<typeof InvalidRequestError | typeof ServiceUnavailableError>, never, never> | HttpApiEndpoint.HttpApiEndpoint<"persistentPty.get", "GET", "/api/experimental/persistent-pty/:ptyID", Schema.toCodecStringTree<Schema.Struct<{
71
+ ptyID: Schema.brand<Schema.String, "PtyID"> & {
72
+ create: () => string & import("effect/Brand").Brand<"PtyID">;
73
+ ascending: (id?: string) => string & import("effect/Brand").Brand<"PtyID">;
74
+ };
75
+ }>>, never, never, never, Schema.toCodecJson<Schema.Struct<{
76
+ readonly data: Schema.Struct<{
99
77
  readonly id: Schema.brand<Schema.String, "PtyID"> & {
100
78
  create: () => string & import("effect/Brand").Brand<"PtyID">;
101
79
  ascending: (id?: string) => string & import("effect/Brand").Brand<"PtyID">;
@@ -107,21 +85,6 @@ export declare const PersistentPtyGroup: HttpApiGroup.HttpApiGroup<"server.exper
107
85
  readonly status: Schema.Literals<readonly ["running", "exited"]>;
108
86
  readonly pid: Schema.Int;
109
87
  readonly exitCode: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Int>>, Schema.optionalKey<Schema.Int>, never, never>;
110
- }>;
111
- }>>, Schema.toCodecJson<typeof InvalidRequestError | typeof ServiceUnavailableError>, never, never> | HttpApiEndpoint.HttpApiEndpoint<"persistentPty.shutdown", "POST", "/api/experimental/persistent-pty/shutdown", never, never, never, never, Schema.toCodecJson<HttpApiSchema.NoContent>, Schema.toCodecJson<typeof ServiceUnavailableError>, never, never> | HttpApiEndpoint.HttpApiEndpoint<"persistentPty.handoff", "POST", "/api/experimental/persistent-pty/handoff", never, never, never, never, Schema.toCodecJson<Schema.Struct<{
112
- readonly handoff: Schema.NullOr<Schema.Struct<{
113
- readonly directory: Schema.String;
114
- readonly instanceID: Schema.String;
115
- readonly ticket: Schema.String;
116
- readonly expiresAt: Schema.Number;
117
- }>>;
118
- }>>, Schema.toCodecJson<typeof ServiceUnavailableError>, never, never> | HttpApiEndpoint.HttpApiEndpoint<"persistentPty.get", "GET", "/api/experimental/persistent-pty/:ptyID", Schema.toCodecStringTree<Schema.Struct<{
119
- ptyID: Schema.brand<Schema.String, "PtyID"> & {
120
- create: () => string & import("effect/Brand").Brand<"PtyID">;
121
- ascending: (id?: string) => string & import("effect/Brand").Brand<"PtyID">;
122
- };
123
- }>>, never, never, never, Schema.toCodecJson<Schema.Struct<{
124
- readonly data: Schema.Struct<{
125
88
  readonly sessionID: Schema.brand<Schema.String, "SessionID"> & {
126
89
  create: () => string & import("effect/Brand").Brand<"SessionID">;
127
90
  descending: (id?: string) => string & import("effect/Brand").Brand<"SessionID">;
@@ -135,6 +98,21 @@ export declare const PersistentPtyGroup: HttpApiGroup.HttpApiGroup<"server.exper
135
98
  readonly head: Schema.Int;
136
99
  readonly tail: Schema.Int;
137
100
  }>;
101
+ }>;
102
+ }>>, Schema.toCodecJson<typeof ServiceUnavailableError | typeof PtyNotFoundError>, never, never> | HttpApiEndpoint.HttpApiEndpoint<"persistentPty.handoff", "POST", "/api/experimental/persistent-pty/handoff", never, never, never, never, Schema.toCodecJson<Schema.Struct<{
103
+ readonly handoff: Schema.NullOr<Schema.Struct<{
104
+ readonly directory: Schema.String;
105
+ readonly instanceID: Schema.String;
106
+ readonly ticket: Schema.String;
107
+ readonly expiresAt: Schema.Number;
108
+ }>>;
109
+ }>>, Schema.toCodecJson<typeof ServiceUnavailableError>, never, never> | HttpApiEndpoint.HttpApiEndpoint<"persistentPty.list", "GET", "/api/experimental/session/:sessionID/terminal", Schema.toCodecStringTree<Schema.Struct<{
110
+ sessionID: Schema.brand<Schema.String, "SessionID"> & {
111
+ create: () => string & import("effect/Brand").Brand<"SessionID">;
112
+ descending: (id?: string) => string & import("effect/Brand").Brand<"SessionID">;
113
+ };
114
+ }>>, never, never, never, Schema.toCodecJson<Schema.Struct<{
115
+ readonly data: Schema.$Array<Schema.Struct<{
138
116
  readonly id: Schema.brand<Schema.String, "PtyID"> & {
139
117
  create: () => string & import("effect/Brand").Brand<"PtyID">;
140
118
  ascending: (id?: string) => string & import("effect/Brand").Brand<"PtyID">;
@@ -146,20 +124,6 @@ export declare const PersistentPtyGroup: HttpApiGroup.HttpApiGroup<"server.exper
146
124
  readonly status: Schema.Literals<readonly ["running", "exited"]>;
147
125
  readonly pid: Schema.Int;
148
126
  readonly exitCode: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Int>>, Schema.optionalKey<Schema.Int>, never, never>;
149
- }>;
150
- }>>, Schema.toCodecJson<typeof ServiceUnavailableError | typeof PtyNotFoundError>, never, never> | HttpApiEndpoint.HttpApiEndpoint<"persistentPty.update", "PUT", "/api/experimental/persistent-pty/:ptyID", Schema.toCodecStringTree<Schema.Struct<{
151
- ptyID: Schema.brand<Schema.String, "PtyID"> & {
152
- create: () => string & import("effect/Brand").Brand<"PtyID">;
153
- ascending: (id?: string) => string & import("effect/Brand").Brand<"PtyID">;
154
- };
155
- }>>, never, Schema.toCodecJson<Schema.Struct<{
156
- readonly attachmentID: Schema.decodeTo<Schema.optional<Schema.toType<Schema.String>>, Schema.optionalKey<Schema.String>, never, never>;
157
- readonly size: Schema.Struct<{
158
- readonly cols: Schema.Int;
159
- readonly rows: Schema.Int;
160
- }>;
161
- }>>, never, Schema.toCodecJson<Schema.Struct<{
162
- readonly data: Schema.Struct<{
163
127
  readonly sessionID: Schema.brand<Schema.String, "SessionID"> & {
164
128
  create: () => string & import("effect/Brand").Brand<"SessionID">;
165
129
  descending: (id?: string) => string & import("effect/Brand").Brand<"SessionID">;
@@ -173,19 +137,39 @@ export declare const PersistentPtyGroup: HttpApiGroup.HttpApiGroup<"server.exper
173
137
  readonly head: Schema.Int;
174
138
  readonly tail: Schema.Int;
175
139
  }>;
176
- readonly id: Schema.brand<Schema.String, "PtyID"> & {
140
+ }>>;
141
+ }>>, Schema.toCodecJson<typeof InvalidRequestError | typeof ServiceUnavailableError>, never, never> | HttpApiEndpoint.HttpApiEndpoint<"persistentPty.read", "GET", "/api/experimental/session/:sessionID/terminal/read", Schema.toCodecStringTree<Schema.Struct<{
142
+ sessionID: Schema.brand<Schema.String, "SessionID"> & {
143
+ create: () => string & import("effect/Brand").Brand<"SessionID">;
144
+ descending: (id?: string) => string & import("effect/Brand").Brand<"SessionID">;
145
+ };
146
+ }>>, Schema.toCodecStringTree<Schema.Struct<{
147
+ lines: Schema.optional<Schema.compose<Schema.Int, Schema.NumberFromString>>;
148
+ }>>, never, never, Schema.toCodecJson<Schema.Struct<{
149
+ readonly data: Schema.NullOr<Schema.Struct<{
150
+ readonly ptyID: Schema.brand<Schema.String, "PtyID"> & {
177
151
  create: () => string & import("effect/Brand").Brand<"PtyID">;
178
152
  ascending: (id?: string) => string & import("effect/Brand").Brand<"PtyID">;
179
153
  };
180
154
  readonly title: Schema.String;
181
- readonly command: Schema.String;
182
- readonly args: Schema.$Array<Schema.String>;
183
155
  readonly cwd: Schema.String;
184
- readonly status: Schema.Literals<readonly ["running", "exited"]>;
185
- readonly pid: Schema.Int;
186
- readonly exitCode: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Int>>, Schema.optionalKey<Schema.Int>, never, never>;
187
- }>;
188
- }>>, Schema.toCodecJson<typeof ServiceUnavailableError | typeof PtyNotFoundError>, never, never> | HttpApiEndpoint.HttpApiEndpoint<"persistentPty.snapshot", "GET", "/api/experimental/persistent-pty/:ptyID/snapshot", Schema.toCodecStringTree<Schema.Struct<{
156
+ readonly foregroundProcess: Schema.NullOr<Schema.String>;
157
+ readonly screen: Schema.Struct<{
158
+ readonly text: Schema.String;
159
+ readonly cols: Schema.Int;
160
+ readonly rows: Schema.Int;
161
+ readonly cursor: Schema.Struct<{
162
+ readonly x: Schema.Int;
163
+ readonly y: Schema.Int;
164
+ }>;
165
+ }>;
166
+ }>>;
167
+ }>>, Schema.toCodecJson<typeof ServiceUnavailableError>, never, never> | HttpApiEndpoint.HttpApiEndpoint<"persistentPty.remove", "DELETE", "/api/experimental/persistent-pty/:ptyID", Schema.toCodecStringTree<Schema.Struct<{
168
+ ptyID: Schema.brand<Schema.String, "PtyID"> & {
169
+ create: () => string & import("effect/Brand").Brand<"PtyID">;
170
+ ascending: (id?: string) => string & import("effect/Brand").Brand<"PtyID">;
171
+ };
172
+ }>>, never, never, never, Schema.toCodecJson<HttpApiSchema.NoContent>, Schema.toCodecJson<typeof ServiceUnavailableError | typeof PtyNotFoundError>, never, never> | HttpApiEndpoint.HttpApiEndpoint<"persistentPty.shutdown", "POST", "/api/experimental/persistent-pty/shutdown", never, never, never, never, Schema.toCodecJson<HttpApiSchema.NoContent>, Schema.toCodecJson<typeof ServiceUnavailableError>, never, never> | HttpApiEndpoint.HttpApiEndpoint<"persistentPty.snapshot", "GET", "/api/experimental/persistent-pty/:ptyID/snapshot", Schema.toCodecStringTree<Schema.Struct<{
189
173
  ptyID: Schema.brand<Schema.String, "PtyID"> & {
190
174
  create: () => string & import("effect/Brand").Brand<"PtyID">;
191
175
  ascending: (id?: string) => string & import("effect/Brand").Brand<"PtyID">;
@@ -193,6 +177,17 @@ export declare const PersistentPtyGroup: HttpApiGroup.HttpApiGroup<"server.exper
193
177
  }>>, never, never, never, Schema.toCodecJson<Schema.Struct<{
194
178
  readonly data: Schema.Struct<{
195
179
  readonly info: Schema.Struct<{
180
+ readonly id: Schema.brand<Schema.String, "PtyID"> & {
181
+ create: () => string & import("effect/Brand").Brand<"PtyID">;
182
+ ascending: (id?: string) => string & import("effect/Brand").Brand<"PtyID">;
183
+ };
184
+ readonly title: Schema.String;
185
+ readonly command: Schema.String;
186
+ readonly args: Schema.$Array<Schema.String>;
187
+ readonly cwd: Schema.String;
188
+ readonly status: Schema.Literals<readonly ["running", "exited"]>;
189
+ readonly pid: Schema.Int;
190
+ readonly exitCode: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Int>>, Schema.optionalKey<Schema.Int>, never, never>;
196
191
  readonly sessionID: Schema.brand<Schema.String, "SessionID"> & {
197
192
  create: () => string & import("effect/Brand").Brand<"SessionID">;
198
193
  descending: (id?: string) => string & import("effect/Brand").Brand<"SessionID">;
@@ -206,17 +201,6 @@ export declare const PersistentPtyGroup: HttpApiGroup.HttpApiGroup<"server.exper
206
201
  readonly head: Schema.Int;
207
202
  readonly tail: Schema.Int;
208
203
  }>;
209
- readonly id: Schema.brand<Schema.String, "PtyID"> & {
210
- create: () => string & import("effect/Brand").Brand<"PtyID">;
211
- ascending: (id?: string) => string & import("effect/Brand").Brand<"PtyID">;
212
- };
213
- readonly title: Schema.String;
214
- readonly command: Schema.String;
215
- readonly args: Schema.$Array<Schema.String>;
216
- readonly cwd: Schema.String;
217
- readonly status: Schema.Literals<readonly ["running", "exited"]>;
218
- readonly pid: Schema.Int;
219
- readonly exitCode: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Int>>, Schema.optionalKey<Schema.Int>, never, never>;
220
204
  }>;
221
205
  readonly text: Schema.String;
222
206
  readonly checkpoint: Schema.Uint8Array;
@@ -225,26 +209,42 @@ export declare const PersistentPtyGroup: HttpApiGroup.HttpApiGroup<"server.exper
225
209
  readonly y: Schema.Int;
226
210
  }>;
227
211
  }>;
228
- }>>, Schema.toCodecJson<typeof ServiceUnavailableError | typeof PtyNotFoundError>, never, never> | HttpApiEndpoint.HttpApiEndpoint<"persistentPty.remove", "DELETE", "/api/experimental/persistent-pty/:ptyID", Schema.toCodecStringTree<Schema.Struct<{
229
- ptyID: Schema.brand<Schema.String, "PtyID"> & {
230
- create: () => string & import("effect/Brand").Brand<"PtyID">;
231
- ascending: (id?: string) => string & import("effect/Brand").Brand<"PtyID">;
232
- };
233
- }>>, never, never, never, Schema.toCodecJson<HttpApiSchema.NoContent>, Schema.toCodecJson<typeof ServiceUnavailableError | typeof PtyNotFoundError>, never, never> | HttpApiEndpoint.HttpApiEndpoint<"persistentPty.connectToken", "POST", "/api/experimental/persistent-pty/:ptyID/connect-token", Schema.toCodecStringTree<Schema.Struct<{
212
+ }>>, Schema.toCodecJson<typeof ServiceUnavailableError | typeof PtyNotFoundError>, never, never> | HttpApiEndpoint.HttpApiEndpoint<"persistentPty.update", "PUT", "/api/experimental/persistent-pty/:ptyID", Schema.toCodecStringTree<Schema.Struct<{
234
213
  ptyID: Schema.brand<Schema.String, "PtyID"> & {
235
214
  create: () => string & import("effect/Brand").Brand<"PtyID">;
236
215
  ascending: (id?: string) => string & import("effect/Brand").Brand<"PtyID">;
237
216
  };
238
- }>>, never, never, Schema.toCodecStringTree<Schema.Struct<{
239
- readonly "x-opencode-ticket": Schema.optional<Schema.String>;
240
- }>>, Schema.toCodecJson<Schema.Struct<{
217
+ }>>, never, Schema.toCodecJson<Schema.Struct<{
218
+ readonly attachmentID: Schema.decodeTo<Schema.optional<Schema.toType<Schema.String>>, Schema.optionalKey<Schema.String>, never, never>;
219
+ readonly size: Schema.Struct<{
220
+ readonly cols: Schema.Int;
221
+ readonly rows: Schema.Int;
222
+ }>;
223
+ }>>, never, Schema.toCodecJson<Schema.Struct<{
241
224
  readonly data: Schema.Struct<{
242
- readonly ticket: Schema.String;
243
- readonly expires_in: Schema.Int;
225
+ readonly id: Schema.brand<Schema.String, "PtyID"> & {
226
+ create: () => string & import("effect/Brand").Brand<"PtyID">;
227
+ ascending: (id?: string) => string & import("effect/Brand").Brand<"PtyID">;
228
+ };
229
+ readonly title: Schema.String;
230
+ readonly command: Schema.String;
231
+ readonly args: Schema.$Array<Schema.String>;
232
+ readonly cwd: Schema.String;
233
+ readonly status: Schema.Literals<readonly ["running", "exited"]>;
234
+ readonly pid: Schema.Int;
235
+ readonly exitCode: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Int>>, Schema.optionalKey<Schema.Int>, never, never>;
236
+ readonly sessionID: Schema.brand<Schema.String, "SessionID"> & {
237
+ create: () => string & import("effect/Brand").Brand<"SessionID">;
238
+ descending: (id?: string) => string & import("effect/Brand").Brand<"SessionID">;
239
+ };
240
+ readonly foregroundProcess: Schema.NullOr<Schema.String>;
241
+ readonly size: Schema.Struct<{
242
+ readonly cols: Schema.Int;
243
+ readonly rows: Schema.Int;
244
+ }>;
245
+ readonly output: Schema.Struct<{
246
+ readonly head: Schema.Int;
247
+ readonly tail: Schema.Int;
248
+ }>;
244
249
  }>;
245
- }>>, Schema.toCodecJson<typeof ServiceUnavailableError | typeof ForbiddenError | typeof PtyNotFoundError>, never, never> | HttpApiEndpoint.HttpApiEndpoint<"persistentPty.connect", "GET", "/api/experimental/persistent-pty/:ptyID/connect", Schema.toCodecStringTree<Schema.Struct<{
246
- ptyID: Schema.brand<Schema.String, "PtyID"> & {
247
- create: () => string & import("effect/Brand").Brand<"PtyID">;
248
- ascending: (id?: string) => string & import("effect/Brand").Brand<"PtyID">;
249
- };
250
- }>>, never, never, never, Schema.toCodecJson<Schema.Boolean>, Schema.toCodecJson<typeof ServiceUnavailableError | typeof ForbiddenError | typeof PtyNotFoundError>, never, never>, false>;
250
+ }>>, Schema.toCodecJson<typeof ServiceUnavailableError | typeof PtyNotFoundError>, never, never>, false>;