@opencode-ai/protocol
Advanced tools
+2
-2
@@ -81,7 +81,7 @@ import { Schema } from "effect"; | ||
| } | ||
| declare const CommandEvaluationError_base: Schema.Class<CommandEvaluationError, Schema.TaggedStruct<"CommandEvaluationError", { | ||
| declare const CommandExecutionError_base: Schema.Class<CommandExecutionError, Schema.TaggedStruct<"CommandExecutionError", { | ||
| readonly command: Schema.String; | ||
| readonly message: Schema.String; | ||
| }>, import("effect/Cause").YieldableError>; | ||
| export declare class CommandEvaluationError extends CommandEvaluationError_base { | ||
| export declare class CommandExecutionError extends CommandExecutionError_base { | ||
| } | ||
@@ -88,0 +88,0 @@ declare const InvalidCursorError_base: Schema.Class<InvalidCursorError, Schema.TaggedStruct<"InvalidCursorError", { |
+1
-1
@@ -67,3 +67,3 @@ import { Schema } from "effect"; | ||
| } | ||
| export class CommandEvaluationError extends Schema.TaggedError()("CommandEvaluationError", { | ||
| export class CommandExecutionError extends Schema.TaggedError()("CommandExecutionError", { | ||
| command: Schema.String, | ||
@@ -70,0 +70,0 @@ message: Schema.String, |
@@ -13,52 +13,4 @@ import { Location } from "@opencode-ai/schema/location"; | ||
| readonly name: Schema.String; | ||
| readonly template: Schema.String; | ||
| readonly description: Schema.decodeTo<Schema.optional<Schema.toType<Schema.String>>, Schema.optionalKey<Schema.String>, never, never>; | ||
| readonly agent: Schema.decodeTo<Schema.optional<Schema.toType<Schema.brand<Schema.String, "Agent.ID">>>, Schema.optionalKey<Schema.brand<Schema.String, "Agent.ID">>, never, never>; | ||
| readonly model: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Struct<{ | ||
| readonly id: Schema.brand<Schema.String, "Model.ID">; | ||
| readonly providerID: Schema.brand<Schema.String, "Provider.ID"> & { | ||
| opencode: string & import("effect/Brand").Brand<"Provider.ID">; | ||
| anthropic: string & import("effect/Brand").Brand<"Provider.ID">; | ||
| openai: string & import("effect/Brand").Brand<"Provider.ID">; | ||
| google: string & import("effect/Brand").Brand<"Provider.ID">; | ||
| googleVertex: string & import("effect/Brand").Brand<"Provider.ID">; | ||
| githubCopilot: string & import("effect/Brand").Brand<"Provider.ID">; | ||
| amazonBedrock: string & import("effect/Brand").Brand<"Provider.ID">; | ||
| azure: string & import("effect/Brand").Brand<"Provider.ID">; | ||
| openrouter: string & import("effect/Brand").Brand<"Provider.ID">; | ||
| mistral: string & import("effect/Brand").Brand<"Provider.ID">; | ||
| gitlab: string & import("effect/Brand").Brand<"Provider.ID">; | ||
| }; | ||
| readonly variant: Schema.decodeTo<Schema.optional<Schema.toType<Schema.brand<Schema.String, "Model.VariantID">>>, Schema.optionalKey<Schema.brand<Schema.String, "Model.VariantID">>, never, never>; | ||
| }> & { | ||
| parse: (input: string) => { | ||
| readonly id: string & import("effect/Brand").Brand<"Model.ID">; | ||
| readonly providerID: string & import("effect/Brand").Brand<"Provider.ID">; | ||
| readonly variant?: (string & import("effect/Brand").Brand<"Model.VariantID">) | undefined; | ||
| }; | ||
| }>>, Schema.optionalKey<Schema.Struct<{ | ||
| readonly id: Schema.brand<Schema.String, "Model.ID">; | ||
| readonly providerID: Schema.brand<Schema.String, "Provider.ID"> & { | ||
| opencode: string & import("effect/Brand").Brand<"Provider.ID">; | ||
| anthropic: string & import("effect/Brand").Brand<"Provider.ID">; | ||
| openai: string & import("effect/Brand").Brand<"Provider.ID">; | ||
| google: string & import("effect/Brand").Brand<"Provider.ID">; | ||
| googleVertex: string & import("effect/Brand").Brand<"Provider.ID">; | ||
| githubCopilot: string & import("effect/Brand").Brand<"Provider.ID">; | ||
| amazonBedrock: string & import("effect/Brand").Brand<"Provider.ID">; | ||
| azure: string & import("effect/Brand").Brand<"Provider.ID">; | ||
| openrouter: string & import("effect/Brand").Brand<"Provider.ID">; | ||
| mistral: string & import("effect/Brand").Brand<"Provider.ID">; | ||
| gitlab: string & import("effect/Brand").Brand<"Provider.ID">; | ||
| }; | ||
| readonly variant: Schema.decodeTo<Schema.optional<Schema.toType<Schema.brand<Schema.String, "Model.VariantID">>>, Schema.optionalKey<Schema.brand<Schema.String, "Model.VariantID">>, never, never>; | ||
| }> & { | ||
| parse: (input: string) => { | ||
| readonly id: string & import("effect/Brand").Brand<"Model.ID">; | ||
| readonly providerID: string & import("effect/Brand").Brand<"Provider.ID">; | ||
| readonly variant?: (string & import("effect/Brand").Brand<"Model.VariantID">) | undefined; | ||
| }; | ||
| }>, never, never>; | ||
| readonly subtask: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Boolean>>, Schema.optionalKey<Schema.Boolean>, never, never>; | ||
| }>>; | ||
| }>>, never, never, never>, false>; |
@@ -14,3 +14,3 @@ import { SessionMessage } from "@opencode-ai/schema/session-message"; | ||
| import { HttpApiEndpoint, HttpApiGroup, HttpApiMiddleware, HttpApiSchema, OpenApi } from "effect/unstable/httpapi"; | ||
| import { ConflictError, CommandEvaluationError, CommandNotFoundError, InvalidCursorError, InvalidRequestError, MessageNotFoundError, ServiceUnavailableError, SessionBusyError, SessionNotFoundError, SkillNotFoundError, UnknownError, } from "../errors.js"; | ||
| import { ConflictError, CommandExecutionError, CommandNotFoundError, InvalidCursorError, InvalidRequestError, MessageNotFoundError, ServiceUnavailableError, SessionBusyError, SessionNotFoundError, SkillNotFoundError, UnknownError, } from "../errors.js"; | ||
| import { Agent } from "@opencode-ai/schema/agent"; | ||
@@ -267,15 +267,8 @@ import { Skill } from "@opencode-ai/schema/skill"; | ||
| payload: Schema.Struct({ | ||
| id: SessionMessage.ID.pipe(Schema.optional), | ||
| command: Schema.String, | ||
| arguments: Schema.String.pipe(Schema.optional), | ||
| agent: Agent.ID.pipe(Schema.optional), | ||
| model: Model.Ref.pipe(Schema.optional), | ||
| files: PromptInput.Prompt.fields.files, | ||
| agents: PromptInput.Prompt.fields.agents, | ||
| skills: PromptInput.Prompt.fields.skills, | ||
| ...PromptInput.Prompt.fields, | ||
| delivery: SessionInbox.Delivery.pipe(Schema.optional), | ||
| resume: Schema.Boolean.pipe(Schema.optional), | ||
| }), | ||
| success: Schema.Struct({ data: SessionInbox.User }), | ||
| error: [ConflictError, InvalidRequestError, SessionNotFoundError, CommandNotFoundError, CommandEvaluationError], | ||
| success: HttpApiSchema.NoContent, | ||
| error: [SessionNotFoundError, CommandNotFoundError, CommandExecutionError], | ||
| }) | ||
@@ -286,3 +279,3 @@ .middleware(sessionLocationMiddleware) | ||
| summary: "Run command", | ||
| description: "Resolve a slash command into prompt input, admit it durably, and schedule execution unless resume is false.", | ||
| description: "Execute a slash command callback immediately.", | ||
| }))) | ||
@@ -289,0 +282,0 @@ .add(HttpApiEndpoint.post("session.skill", "/api/session/:sessionID/skill", { |
+2
-2
| { | ||
| "$schema": "https://json.schemastore.org/package.json", | ||
| "name": "@opencode-ai/protocol", | ||
| "version": "0.0.0-dev-18110", | ||
| "version": "0.0.0-dev-18111", | ||
| "type": "module", | ||
@@ -35,3 +35,3 @@ "license": "MIT", | ||
| "dependencies": { | ||
| "@opencode-ai/schema": "0.0.0-dev-18110", | ||
| "@opencode-ai/schema": "0.0.0-dev-18111", | ||
| "effect": "4.0.0-rc.111" | ||
@@ -38,0 +38,0 @@ }, |
Sorry, the diff of this file is too big to display
URL strings
Supply chain riskPackage contains fragments of external URLs or IP addresses, which the package may be accessing at runtime.
URL strings
Supply chain riskPackage contains fragments of external URLs or IP addresses, which the package may be accessing at runtime.
1910768
-0.74%30846
-0.73%+ Added
- Removed