chore: generate

This commit is contained in:
opencode-agent[bot] 2026-05-21 11:01:36 +00:00
parent 9739d75892
commit 6bee6ee755
5 changed files with 68 additions and 3 deletions

View file

@ -4,7 +4,13 @@ import { Prompt } from "@opencode-ai/core/session-prompt"
import { SessionV2 } from "@/v2/session"
import { Schema } from "effect"
import { HttpApiEndpoint, HttpApiGroup, HttpApiSchema, OpenApi } from "effect/unstable/httpapi"
import { InvalidCursorError, InvalidRequestError, ServiceUnavailableError, SessionNotFoundError, UnknownError } from "../../errors"
import {
InvalidCursorError,
InvalidRequestError,
ServiceUnavailableError,
SessionNotFoundError,
UnknownError,
} from "../../errors"
import { V2Authorization } from "../../middleware/authorization"
import { WorkspaceRoutingQuery, WorkspaceRoutingQueryFields } from "../../middleware/workspace-routing"
import { QueryBoolean } from "../query"

View file

@ -3,7 +3,13 @@ import { SessionV2 } from "@/v2/session"
import { DateTime, Effect, Option, Schema } from "effect"
import { HttpApiBuilder, HttpApiSchema } from "effect/unstable/httpapi"
import { InstanceHttpApi } from "../../api"
import { InvalidCursorError, InvalidRequestError, ServiceUnavailableError, SessionNotFoundError, UnknownError } from "../../errors"
import {
InvalidCursorError,
InvalidRequestError,
ServiceUnavailableError,
SessionNotFoundError,
UnknownError,
} from "../../errors"
const DefaultSessionsLimit = 50

View file

@ -110,7 +110,9 @@ export interface Interface {
direction: "previous" | "next"
}
}) => Effect.Effect<SessionMessage.Message[], NotFoundError | MessageDecodeError>
readonly context: (sessionID: SessionID) => Effect.Effect<SessionMessage.Message[], NotFoundError | MessageDecodeError>
readonly context: (
sessionID: SessionID,
) => Effect.Effect<SessionMessage.Message[], NotFoundError | MessageDecodeError>
readonly prompt: (input: {
id?: EventV2.ID
sessionID: SessionID

View file

@ -1836,6 +1836,12 @@ export type ServiceUnavailableError = {
service?: string
}
export type UnknownError1 = {
_tag: "UnknownError"
message: string
ref?: string
}
export type V2SessionMessagesResponse = {
items: Array<SessionMessage>
cursor: {
@ -7311,6 +7317,10 @@ export type V2SessionContextErrors = {
* SessionNotFoundError
*/
404: SessionNotFoundError
/**
* UnknownError
*/
500: UnknownError1
}
export type V2SessionContextError = V2SessionContextErrors[keyof V2SessionContextErrors]
@ -7355,6 +7365,10 @@ export type V2SessionMessagesErrors = {
* SessionNotFoundError
*/
404: SessionNotFoundError
/**
* UnknownError
*/
500: UnknownError1
}
export type V2SessionMessagesError = V2SessionMessagesErrors[keyof V2SessionMessagesErrors]

View file

@ -8517,6 +8517,16 @@
}
}
}
},
"500": {
"description": "UnknownError",
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/UnknownError1"
}
}
}
}
},
"description": "Retrieve the active context messages for a v2 session (all messages after the last compaction).",
@ -8634,6 +8644,16 @@
}
}
}
},
"500": {
"description": "UnknownError",
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/UnknownError1"
}
}
}
}
},
"description": "Retrieve projected v2 messages for a session. Items keep the requested order across pages; use cursor.next or cursor.previous to move through the ordered timeline.",
@ -15735,6 +15755,23 @@
"required": ["_tag", "message"],
"additionalProperties": false
},
"UnknownError1": {
"type": "object",
"properties": {
"_tag": {
"type": "string",
"enum": ["UnknownError"]
},
"message": {
"type": "string"
},
"ref": {
"type": "string"
}
},
"required": ["_tag", "message"],
"additionalProperties": false
},
"V2SessionMessagesResponse": {
"type": "object",
"properties": {