@opencode/protocol 0.0.0-beta-19398 → 0.0.0-beta-19422
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/message.d.ts +2 -0
- package/dist/groups/message.js +15 -1
- package/package.json +2 -2
package/dist/groups/message.d.ts
CHANGED
|
@@ -5,6 +5,7 @@ export declare const SessionMessagesQuery: Schema.Struct<{
|
|
|
5
5
|
readonly limit: Schema.optional<Schema.NumberFromString>;
|
|
6
6
|
readonly order: Schema.optional<Schema.Union<readonly [Schema.Literal<"asc">, Schema.Literal<"desc">]>>;
|
|
7
7
|
readonly cursor: Schema.optional<Schema.String>;
|
|
8
|
+
readonly type: Schema.optional<Schema.Literals<("skill" | "compaction" | "system" | "shell" | "agent-switched" | "model-switched" | "location-switched" | "user" | "synthetic" | "assistant")[]>>;
|
|
8
9
|
}>;
|
|
9
10
|
export declare const MessageGroup: HttpApiGroup.HttpApiGroup<"server.message", HttpApiEndpoint.HttpApiEndpoint<"session.messages", "GET", "/api/session/:sessionID/message", Schema.toCodecStringTree<Schema.Struct<{
|
|
10
11
|
sessionID: Schema.brand<Schema.String, "SessionID"> & {
|
|
@@ -15,6 +16,7 @@ export declare const MessageGroup: HttpApiGroup.HttpApiGroup<"server.message", H
|
|
|
15
16
|
readonly limit: Schema.optional<Schema.NumberFromString>;
|
|
16
17
|
readonly order: Schema.optional<Schema.Union<readonly [Schema.Literal<"asc">, Schema.Literal<"desc">]>>;
|
|
17
18
|
readonly cursor: Schema.optional<Schema.String>;
|
|
19
|
+
readonly type: Schema.optional<Schema.Literals<("skill" | "compaction" | "system" | "shell" | "agent-switched" | "model-switched" | "location-switched" | "user" | "synthetic" | "assistant")[]>>;
|
|
18
20
|
}>>, never, never, Schema.toCodecJson<Schema.Struct<{
|
|
19
21
|
readonly data: Schema.$Array<Schema.Union<readonly [Schema.Struct<{
|
|
20
22
|
readonly type: Schema.tag<"agent-switched">;
|
package/dist/groups/message.js
CHANGED
|
@@ -13,6 +13,20 @@ export const SessionMessagesQuery = Schema.Struct({
|
|
|
13
13
|
cursor: Schema.optional(Schema.String.annotate({
|
|
14
14
|
description: "Opaque pagination cursor returned as cursor.previous or cursor.next in the previous response. Do not combine with order.",
|
|
15
15
|
})),
|
|
16
|
+
type: Schema.optional(Schema.Literals([
|
|
17
|
+
"agent-switched",
|
|
18
|
+
"model-switched",
|
|
19
|
+
"location-switched",
|
|
20
|
+
"user",
|
|
21
|
+
"synthetic",
|
|
22
|
+
"system",
|
|
23
|
+
"skill",
|
|
24
|
+
"shell",
|
|
25
|
+
"assistant",
|
|
26
|
+
"compaction",
|
|
27
|
+
])).annotate({
|
|
28
|
+
description: "Filter by message type before pagination. When omitted, all message types are returned. Pass the same type when following cursors.",
|
|
29
|
+
}),
|
|
16
30
|
}).annotate({ identifier: "SessionMessagesQuery" });
|
|
17
31
|
export const MessageGroup = HttpApiGroup.make("server.message")
|
|
18
32
|
.add(HttpApiEndpoint.get("session.messages", "/api/session/:sessionID/message", {
|
|
@@ -29,7 +43,7 @@ export const MessageGroup = HttpApiGroup.make("server.message")
|
|
|
29
43
|
}).annotateMerge(OpenApi.annotations({
|
|
30
44
|
identifier: "v2.message.list",
|
|
31
45
|
summary: "Get session messages",
|
|
32
|
-
description: "Retrieve projected messages for a session. Items keep the requested order across pages; use cursor.next or cursor.previous to move through the ordered timeline.",
|
|
46
|
+
description: "Retrieve projected messages for a session, optionally filtered by type. Items keep the requested order across pages; use cursor.next or cursor.previous to move through the ordered timeline, passing the same type filter on each page.",
|
|
33
47
|
})))
|
|
34
48
|
.annotateMerge(OpenApi.annotations({
|
|
35
49
|
title: "session",
|
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": "0.0.0-beta-
|
|
4
|
+
"version": "0.0.0-beta-19422",
|
|
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": "0.0.0-beta-
|
|
35
|
+
"@opencode/schema": "0.0.0-beta-19422",
|
|
36
36
|
"effect": "4.0.0-rc.112"
|
|
37
37
|
},
|
|
38
38
|
"devDependencies": {
|