@opencode/protocol 2.0.20 → 2.0.22
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/groups/agent.d.ts
CHANGED
|
@@ -61,7 +61,8 @@ export declare const AgentGroup: HttpApiGroup.HttpApiGroup<"server.agent", HttpA
|
|
|
61
61
|
readonly request: Schema.Struct<{
|
|
62
62
|
readonly settings: Schema.withConstructorDefault<Schema.StructWithRest<Schema.Struct<{
|
|
63
63
|
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>;
|
|
64
|
-
readonly
|
|
64
|
+
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>;
|
|
65
|
+
readonly chunkTimeout: 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>;
|
|
65
66
|
readonly compaction: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Union<readonly [Schema.Struct<{
|
|
66
67
|
readonly type: Schema.Literal<"summary">;
|
|
67
68
|
}>, Schema.Struct<{
|
|
@@ -170,7 +171,8 @@ export declare const AgentGroup: HttpApiGroup.HttpApiGroup<"server.agent", HttpA
|
|
|
170
171
|
readonly request: Schema.Struct<{
|
|
171
172
|
readonly settings: Schema.withConstructorDefault<Schema.StructWithRest<Schema.Struct<{
|
|
172
173
|
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>;
|
|
173
|
-
readonly
|
|
174
|
+
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>;
|
|
175
|
+
readonly chunkTimeout: 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>;
|
|
174
176
|
readonly compaction: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Union<readonly [Schema.Struct<{
|
|
175
177
|
readonly type: Schema.Literal<"summary">;
|
|
176
178
|
}>, Schema.Struct<{
|
|
@@ -13,7 +13,8 @@ export declare const ProviderGroup: HttpApiGroup.HttpApiGroup<"server.provider",
|
|
|
13
13
|
readonly data: Schema.$Array<Schema.Struct<{
|
|
14
14
|
readonly settings: Schema.decodeTo<Schema.optional<Schema.toType<Schema.StructWithRest<Schema.Struct<{
|
|
15
15
|
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>;
|
|
16
|
-
readonly
|
|
16
|
+
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>;
|
|
17
|
+
readonly chunkTimeout: 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>;
|
|
17
18
|
readonly compaction: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Union<readonly [Schema.Struct<{
|
|
18
19
|
readonly type: Schema.Literal<"summary">;
|
|
19
20
|
}>, Schema.Struct<{
|
|
@@ -26,7 +27,8 @@ export declare const ProviderGroup: HttpApiGroup.HttpApiGroup<"server.provider",
|
|
|
26
27
|
readonly transport: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Literals<readonly ["http", "websocket"]>>>, Schema.optionalKey<Schema.Literals<readonly ["http", "websocket"]>>, never, never>;
|
|
27
28
|
}>, readonly [Schema.$Record<Schema.String, Schema.Any>]>>>, Schema.optionalKey<Schema.StructWithRest<Schema.Struct<{
|
|
28
29
|
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>;
|
|
29
|
-
readonly
|
|
30
|
+
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>;
|
|
31
|
+
readonly chunkTimeout: 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>;
|
|
30
32
|
readonly compaction: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Union<readonly [Schema.Struct<{
|
|
31
33
|
readonly type: Schema.Literal<"summary">;
|
|
32
34
|
}>, Schema.Struct<{
|
|
@@ -110,7 +112,8 @@ export declare const ProviderGroup: HttpApiGroup.HttpApiGroup<"server.provider",
|
|
|
110
112
|
readonly data: Schema.Struct<{
|
|
111
113
|
readonly settings: Schema.decodeTo<Schema.optional<Schema.toType<Schema.StructWithRest<Schema.Struct<{
|
|
112
114
|
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>;
|
|
113
|
-
readonly
|
|
115
|
+
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>;
|
|
116
|
+
readonly chunkTimeout: 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>;
|
|
114
117
|
readonly compaction: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Union<readonly [Schema.Struct<{
|
|
115
118
|
readonly type: Schema.Literal<"summary">;
|
|
116
119
|
}>, Schema.Struct<{
|
|
@@ -123,7 +126,8 @@ export declare const ProviderGroup: HttpApiGroup.HttpApiGroup<"server.provider",
|
|
|
123
126
|
readonly transport: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Literals<readonly ["http", "websocket"]>>>, Schema.optionalKey<Schema.Literals<readonly ["http", "websocket"]>>, never, never>;
|
|
124
127
|
}>, readonly [Schema.$Record<Schema.String, Schema.Any>]>>>, Schema.optionalKey<Schema.StructWithRest<Schema.Struct<{
|
|
125
128
|
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>;
|
|
126
|
-
readonly
|
|
129
|
+
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>;
|
|
130
|
+
readonly chunkTimeout: 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>;
|
|
127
131
|
readonly compaction: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Union<readonly [Schema.Struct<{
|
|
128
132
|
readonly type: Schema.Literal<"summary">;
|
|
129
133
|
}>, Schema.Struct<{
|
package/dist/groups/session.d.ts
CHANGED
|
@@ -473,6 +473,10 @@ export declare const makeSessionGroup: <I extends HttpApiMiddleware.AnyId, S, Fo
|
|
|
473
473
|
create: () => string & import("effect/Brand").Brand<"SessionID">;
|
|
474
474
|
descending: (id?: string) => string & import("effect/Brand").Brand<"SessionID">;
|
|
475
475
|
}>;
|
|
476
|
+
readonly parentID: Schema.optional<Schema.brand<Schema.String, "SessionID"> & {
|
|
477
|
+
create: () => string & import("effect/Brand").Brand<"SessionID">;
|
|
478
|
+
descending: (id?: string) => string & import("effect/Brand").Brand<"SessionID">;
|
|
479
|
+
}>;
|
|
476
480
|
readonly title: Schema.optional<Schema.String>;
|
|
477
481
|
readonly agent: Schema.optional<Schema.brand<Schema.String, "Agent.ID">>;
|
|
478
482
|
readonly model: Schema.optional<Schema.Struct<{
|
|
@@ -683,7 +687,7 @@ export declare const makeSessionGroup: <I extends HttpApiMiddleware.AnyId, S, Fo
|
|
|
683
687
|
}>]>;
|
|
684
688
|
}>>, never, never>;
|
|
685
689
|
}>;
|
|
686
|
-
}>>,
|
|
690
|
+
}>>, Schema.toCodecJson<typeof SessionNotFoundError>, never, never> | HttpApiEndpoint.HttpApiEndpoint<"session.import", "POST", "/api/experimental/session/import", never, never, Schema.toCodecJson<Schema.Struct<{
|
|
687
691
|
readonly location: Schema.optional<Schema.Struct<{
|
|
688
692
|
readonly directory: Schema.brand<Schema.String, "AbsolutePath">;
|
|
689
693
|
}>>;
|
|
@@ -11298,6 +11302,7 @@ export declare const makeSessionGroup: <I extends HttpApiMiddleware.AnyId, S, Fo
|
|
|
11298
11302
|
readonly answer: Schema.$Record<Schema.String, Schema.Union<readonly [Schema.String, Schema.Number, Schema.Boolean, Schema.$Array<Schema.String>]>>;
|
|
11299
11303
|
}>, Schema.Struct<{
|
|
11300
11304
|
readonly status: Schema.Literal<"cancelled">;
|
|
11305
|
+
readonly message: Schema.decodeTo<Schema.optional<Schema.toType<Schema.String>>, Schema.optionalKey<Schema.String>, never, never>;
|
|
11301
11306
|
}>]>;
|
|
11302
11307
|
readonly fields: Schema.NonEmptyArray<Schema.Union<readonly [Schema.Struct<{
|
|
11303
11308
|
readonly type: Schema.Literal<"string">;
|
|
@@ -11437,7 +11442,9 @@ export declare const makeSessionGroup: <I extends HttpApiMiddleware.AnyId, S, Fo
|
|
|
11437
11442
|
formID: Schema.brand<Schema.String, "Form.ID"> & {
|
|
11438
11443
|
create: (id?: string) => string & import("effect/Brand").Brand<"Form.ID">;
|
|
11439
11444
|
};
|
|
11440
|
-
}>>,
|
|
11445
|
+
}>>, Schema.toCodecStringTree<Schema.Struct<{
|
|
11446
|
+
readonly message: Schema.optional<Schema.String>;
|
|
11447
|
+
}>>, never, never, Schema.toCodecJson<HttpApiSchema.NoContent>, Schema.toCodecJson<typeof SessionNotFoundError | typeof FormNotFoundError | typeof FormAlreadySettledError>, FormI, HttpApiMiddleware.Requires<FormI>> | HttpApiEndpoint.HttpApiEndpoint<"session.environment", "PUT", "/api/session/:sessionID/environment", Schema.toCodecStringTree<Schema.Struct<{
|
|
11441
11448
|
sessionID: Schema.brand<Schema.String, "SessionID"> & {
|
|
11442
11449
|
create: () => string & import("effect/Brand").Brand<"SessionID">;
|
|
11443
11450
|
descending: (id?: string) => string & import("effect/Brand").Brand<"SessionID">;
|
package/dist/groups/session.js
CHANGED
|
@@ -153,6 +153,7 @@ export const makeSessionGroup = (sessionLocationMiddleware, formLocationMiddlewa
|
|
|
153
153
|
.add(HttpApiEndpoint.post("session.create", "/api/session", {
|
|
154
154
|
payload: Schema.Struct({
|
|
155
155
|
id: Session.ID.pipe(Schema.optional),
|
|
156
|
+
parentID: Session.ID.pipe(Schema.optional),
|
|
156
157
|
title: Schema.String.pipe(Schema.optional),
|
|
157
158
|
agent: Agent.ID.pipe(Schema.optional),
|
|
158
159
|
model: Model.Ref.pipe(Schema.optional),
|
|
@@ -161,10 +162,11 @@ export const makeSessionGroup = (sessionLocationMiddleware, formLocationMiddlewa
|
|
|
161
162
|
permissions: Permission.Ruleset.pipe(Schema.optional),
|
|
162
163
|
}),
|
|
163
164
|
success: Schema.Struct({ data: PublicSessionInfo }),
|
|
165
|
+
error: SessionNotFoundError,
|
|
164
166
|
}).annotateMerge(OpenApi.annotations({
|
|
165
167
|
identifier: "session.create",
|
|
166
168
|
summary: "Create session",
|
|
167
|
-
description: "Create a session at the requested location.",
|
|
169
|
+
description: "Create a session at the requested location. A parentID creates a linked child session at its parent's location.",
|
|
168
170
|
})))
|
|
169
171
|
.add(HttpApiEndpoint.post("session.import", "/api/experimental/session/import", {
|
|
170
172
|
payload: Schema.Struct({
|
|
@@ -614,6 +616,7 @@ export const makeSessionGroup = (sessionLocationMiddleware, formLocationMiddlewa
|
|
|
614
616
|
})))
|
|
615
617
|
.add(HttpApiEndpoint.delete("session.form.cancel", "/api/session/:sessionID/form/:formID", {
|
|
616
618
|
params: { sessionID: Schema.String, formID: Form.ID },
|
|
619
|
+
query: Schema.Struct({ message: Schema.optional(Schema.String) }),
|
|
617
620
|
success: HttpApiSchema.NoContent,
|
|
618
621
|
error: [SessionNotFoundError, FormAlreadySettledError, FormNotFoundError],
|
|
619
622
|
})
|
|
@@ -621,7 +624,7 @@ export const makeSessionGroup = (sessionLocationMiddleware, formLocationMiddlewa
|
|
|
621
624
|
.annotateMerge(OpenApi.annotations({
|
|
622
625
|
identifier: "session.form.cancel",
|
|
623
626
|
summary: "Cancel form",
|
|
624
|
-
description: "Cancel a pending form.",
|
|
627
|
+
description: "Cancel a pending form, optionally telling the asker why it was not answered.",
|
|
625
628
|
})))
|
|
626
629
|
.add(HttpApiEndpoint.put("session.environment", "/api/session/:sessionID/environment", {
|
|
627
630
|
params: { sessionID: Session.ID },
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"$schema": "https://json.schemastore.org/package.json",
|
|
3
3
|
"name": "@opencode/protocol",
|
|
4
|
-
"version": "2.0.
|
|
4
|
+
"version": "2.0.22",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"license": "MIT",
|
|
7
7
|
"repository": {
|
|
@@ -32,7 +32,7 @@
|
|
|
32
32
|
"typecheck": "tsgo --noEmit"
|
|
33
33
|
},
|
|
34
34
|
"dependencies": {
|
|
35
|
-
"@opencode/schema": "2.0.
|
|
35
|
+
"@opencode/schema": "2.0.22",
|
|
36
36
|
"effect": "4.0.0-rc.112"
|
|
37
37
|
},
|
|
38
38
|
"devDependencies": {
|