chore: generate

This commit is contained in:
opencode-agent[bot] 2026-05-06 01:35:13 +00:00
parent 8555de8189
commit 6e7c9eb820
4 changed files with 74 additions and 54 deletions

View File

@ -60,9 +60,9 @@ export const SessionDeleteCommand = effectCmd({
handler: Effect.fn("Cli.session.delete")(function* (args) { handler: Effect.fn("Cli.session.delete")(function* (args) {
const svc = yield* Session.Service const svc = yield* Session.Service
const sessionID = SessionID.make(args.sessionID) const sessionID = SessionID.make(args.sessionID)
yield* svc.remove(sessionID).pipe( yield* svc
Effect.catchIf(NotFoundError.isInstance, () => fail(`Session not found: ${args.sessionID}`)), .remove(sessionID)
) .pipe(Effect.catchIf(NotFoundError.isInstance, () => fail(`Session not found: ${args.sessionID}`)))
UI.println(UI.Style.TEXT_SUCCESS_BOLD + `Session ${args.sessionID} deleted` + UI.Style.TEXT_NORMAL) UI.println(UI.Style.TEXT_SUCCESS_BOLD + `Session ${args.sessionID} deleted` + UI.Style.TEXT_NORMAL)
}), }),
}) })

View File

@ -131,6 +131,7 @@ import type {
SessionDeleteResponses, SessionDeleteResponses,
SessionDelivery, SessionDelivery,
SessionDiffResponses, SessionDiffResponses,
SessionForkErrors,
SessionForkResponses, SessionForkResponses,
SessionGetErrors, SessionGetErrors,
SessionGetResponses, SessionGetResponses,
@ -3320,7 +3321,7 @@ export class Session2 extends HeyApiClient {
}, },
], ],
) )
return (options?.client ?? this.client).post<SessionForkResponses, unknown, ThrowOnError>({ return (options?.client ?? this.client).post<SessionForkResponses, SessionForkErrors, ThrowOnError>({
url: "/session/{sessionID}/fork", url: "/session/{sessionID}/fork",
...options, ...options,
...params, ...params,

View File

@ -1561,6 +1561,13 @@ export type McpUnsupportedOAuthError = {
error: string error: string
} }
export type NotFoundError = {
name: "NotFoundError"
data: {
message: string
}
}
export type EffectHttpApiErrorForbidden = { export type EffectHttpApiErrorForbidden = {
_tag: "Forbidden" _tag: "Forbidden"
} }
@ -3224,13 +3231,6 @@ export type BadRequestError = {
success: false success: false
} }
export type NotFoundError = {
name: "NotFoundError"
data: {
message: string
}
}
export type AuthRemoveData = { export type AuthRemoveData = {
body?: never body?: never
path: { path: {
@ -4571,7 +4571,7 @@ export type PtyRemoveData = {
export type PtyRemoveErrors = { export type PtyRemoveErrors = {
/** /**
* Not found * NotFoundError
*/ */
404: NotFoundError 404: NotFoundError
} }
@ -4601,7 +4601,7 @@ export type PtyGetData = {
export type PtyGetErrors = { export type PtyGetErrors = {
/** /**
* Not found * NotFoundError
*/ */
404: NotFoundError 404: NotFoundError
} }
@ -4671,7 +4671,7 @@ export type PtyConnectTokenErrors = {
*/ */
403: EffectHttpApiErrorForbidden 403: EffectHttpApiErrorForbidden
/** /**
* Not found * NotFoundError
*/ */
404: NotFoundError 404: NotFoundError
} }
@ -5070,7 +5070,7 @@ export type SessionDeleteErrors = {
*/ */
400: BadRequestError 400: BadRequestError
/** /**
* Not found * NotFoundError
*/ */
404: NotFoundError 404: NotFoundError
} }
@ -5104,7 +5104,7 @@ export type SessionGetErrors = {
*/ */
400: BadRequestError 400: BadRequestError
/** /**
* Not found * NotFoundError
*/ */
404: NotFoundError 404: NotFoundError
} }
@ -5144,7 +5144,7 @@ export type SessionUpdateErrors = {
*/ */
400: BadRequestError 400: BadRequestError
/** /**
* Not found * NotFoundError
*/ */
404: NotFoundError 404: NotFoundError
} }
@ -5270,7 +5270,7 @@ export type SessionMessagesErrors = {
*/ */
400: BadRequestError 400: BadRequestError
/** /**
* Not found * NotFoundError
*/ */
404: NotFoundError 404: NotFoundError
} }
@ -5395,7 +5395,7 @@ export type SessionMessageErrors = {
*/ */
400: BadRequestError 400: BadRequestError
/** /**
* Not found * NotFoundError
*/ */
404: NotFoundError 404: NotFoundError
} }
@ -5428,6 +5428,15 @@ export type SessionForkData = {
url: "/session/{sessionID}/fork" url: "/session/{sessionID}/fork"
} }
export type SessionForkErrors = {
/**
* NotFoundError
*/
404: NotFoundError
}
export type SessionForkError = SessionForkErrors[keyof SessionForkErrors]
export type SessionForkResponses = { export type SessionForkResponses = {
/** /**
* 200 * 200
@ -5527,7 +5536,7 @@ export type SessionUnshareErrors = {
*/ */
400: BadRequestError 400: BadRequestError
/** /**
* Not found * NotFoundError
*/ */
404: NotFoundError 404: NotFoundError
} }
@ -5561,7 +5570,7 @@ export type SessionShareErrors = {
*/ */
400: BadRequestError 400: BadRequestError
/** /**
* Not found * NotFoundError
*/ */
404: NotFoundError 404: NotFoundError
} }
@ -5599,7 +5608,7 @@ export type SessionSummarizeErrors = {
*/ */
400: BadRequestError 400: BadRequestError
/** /**
* Not found * NotFoundError
*/ */
404: NotFoundError 404: NotFoundError
} }
@ -6463,7 +6472,7 @@ export type TuiSelectSessionErrors = {
*/ */
400: BadRequestError 400: BadRequestError
/** /**
* Not found * NotFoundError
*/ */
404: NotFoundError 404: NotFoundError
} }

View File

@ -3241,7 +3241,7 @@
} }
}, },
"404": { "404": {
"description": "Not found", "description": "NotFoundError",
"content": { "content": {
"application/json": { "application/json": {
"schema": { "schema": {
@ -3394,7 +3394,7 @@
} }
}, },
"404": { "404": {
"description": "Not found", "description": "NotFoundError",
"content": { "content": {
"application/json": { "application/json": {
"schema": { "schema": {
@ -3479,7 +3479,7 @@
} }
}, },
"404": { "404": {
"description": "Not found", "description": "NotFoundError",
"content": { "content": {
"application/json": { "application/json": {
"schema": { "schema": {
@ -4454,7 +4454,7 @@
} }
}, },
"404": { "404": {
"description": "Not found", "description": "NotFoundError",
"content": { "content": {
"application/json": { "application/json": {
"schema": { "schema": {
@ -4526,7 +4526,7 @@
} }
}, },
"404": { "404": {
"description": "Not found", "description": "NotFoundError",
"content": { "content": {
"application/json": { "application/json": {
"schema": { "schema": {
@ -4597,7 +4597,7 @@
} }
}, },
"404": { "404": {
"description": "Not found", "description": "NotFoundError",
"content": { "content": {
"application/json": { "application/json": {
"schema": { "schema": {
@ -4952,7 +4952,7 @@
} }
}, },
"404": { "404": {
"description": "Not found", "description": "NotFoundError",
"content": { "content": {
"application/json": { "application/json": {
"schema": { "schema": {
@ -5200,7 +5200,7 @@
} }
}, },
"404": { "404": {
"description": "Not found", "description": "NotFoundError",
"content": { "content": {
"application/json": { "application/json": {
"schema": { "schema": {
@ -5342,6 +5342,16 @@
} }
} }
} }
},
"404": {
"description": "NotFoundError",
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/NotFoundError"
}
}
}
} }
}, },
"description": "Create a new session by forking an existing session at a specific message point.", "description": "Create a new session by forking an existing session at a specific message point.",
@ -5592,7 +5602,7 @@
} }
}, },
"404": { "404": {
"description": "Not found", "description": "NotFoundError",
"content": { "content": {
"application/json": { "application/json": {
"schema": { "schema": {
@ -5663,7 +5673,7 @@
} }
}, },
"404": { "404": {
"description": "Not found", "description": "NotFoundError",
"content": { "content": {
"application/json": { "application/json": {
"schema": { "schema": {
@ -5737,7 +5747,7 @@
} }
}, },
"404": { "404": {
"description": "Not found", "description": "NotFoundError",
"content": { "content": {
"application/json": { "application/json": {
"schema": { "schema": {
@ -7897,7 +7907,7 @@
} }
}, },
"404": { "404": {
"description": "Not found", "description": "NotFoundError",
"content": { "content": {
"application/json": { "application/json": {
"schema": { "schema": {
@ -12904,6 +12914,25 @@
"required": ["error"], "required": ["error"],
"additionalProperties": false "additionalProperties": false
}, },
"NotFoundError": {
"type": "object",
"required": ["name", "data"],
"properties": {
"name": {
"type": "string",
"enum": ["NotFoundError"]
},
"data": {
"type": "object",
"required": ["message"],
"properties": {
"message": {
"type": "string"
}
}
}
}
},
"effect_HttpApiError_Forbidden": { "effect_HttpApiError_Forbidden": {
"type": "object", "type": "object",
"properties": { "properties": {
@ -18026,25 +18055,6 @@
"enum": [false] "enum": [false]
} }
} }
},
"NotFoundError": {
"type": "object",
"required": ["name", "data"],
"properties": {
"name": {
"type": "string",
"enum": ["NotFoundError"]
},
"data": {
"type": "object",
"required": ["message"],
"properties": {
"message": {
"type": "string"
}
}
}
}
} }
} }
}, },