@opencode-ai/plugin 0.0.0-next-15543 → 0.0.0-next-15548

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.
@@ -8,8 +8,13 @@ import type { Hooks, Transform } from "./registration.js";
8
8
  export interface Context {
9
9
  readonly sessionID: Session.ID;
10
10
  readonly agent: Agent.ID;
11
- readonly assistantMessageID: SessionMessage.ID;
12
- readonly toolCallID: string;
11
+ readonly messageID: SessionMessage.ID;
12
+ readonly callID: string;
13
+ readonly progress: (update: Progress) => Effect.Effect<void>;
14
+ }
15
+ export interface Progress {
16
+ readonly structured: Readonly<Record<string, unknown>>;
17
+ readonly content?: ReadonlyArray<Content>;
13
18
  }
14
19
  export type SchemaType<A> = Schema.Codec<A, any>;
15
20
  type ToolDefinition = {
@@ -116,16 +121,16 @@ export interface ToolExecuteBeforeEvent {
116
121
  readonly tool: string;
117
122
  readonly sessionID: Session.ID;
118
123
  readonly agent: Agent.ID;
119
- readonly assistantMessageID: SessionMessage.ID;
120
- readonly toolCallID: string;
124
+ readonly messageID: SessionMessage.ID;
125
+ readonly callID: string;
121
126
  input: unknown;
122
127
  }
123
128
  export interface ToolExecuteAfterEvent {
124
129
  readonly tool: string;
125
130
  readonly sessionID: Session.ID;
126
131
  readonly agent: Agent.ID;
127
- readonly assistantMessageID: SessionMessage.ID;
128
- readonly toolCallID: string;
132
+ readonly messageID: SessionMessage.ID;
133
+ readonly callID: string;
129
134
  readonly input: unknown;
130
135
  result: ToolResultValue;
131
136
  output?: ToolOutput;
@@ -4,7 +4,9 @@ import type { Session } from "@opencode-ai/schema/session";
4
4
  import type { SessionMessage } from "@opencode-ai/schema/session-message";
5
5
  import type { JsonSchema, Schema } from "effect";
6
6
  import type { Hooks, Transform } from "./registration.js";
7
- export type Context = Tool.Context;
7
+ export type Context = Omit<Tool.Context, "progress"> & {
8
+ readonly progress: (update: Tool.Progress) => Promise<void>;
9
+ };
8
10
  export type SchemaType<A> = Tool.SchemaType<A>;
9
11
  export type Content = Tool.Content;
10
12
  export type DynamicOutput = Tool.DynamicOutput;
@@ -38,16 +40,16 @@ export interface ToolExecuteBeforeEvent {
38
40
  readonly tool: string;
39
41
  readonly sessionID: Session.ID;
40
42
  readonly agent: Agent.ID;
41
- readonly assistantMessageID: SessionMessage.ID;
42
- readonly toolCallID: string;
43
+ readonly messageID: SessionMessage.ID;
44
+ readonly callID: string;
43
45
  input: unknown;
44
46
  }
45
47
  export interface ToolExecuteAfterEvent {
46
48
  readonly tool: string;
47
49
  readonly sessionID: Session.ID;
48
50
  readonly agent: Agent.ID;
49
- readonly assistantMessageID: SessionMessage.ID;
50
- readonly toolCallID: string;
51
+ readonly messageID: SessionMessage.ID;
52
+ readonly callID: string;
51
53
  readonly input: unknown;
52
54
  result: Tool.ToolExecuteAfterEvent["result"];
53
55
  output?: Tool.ToolExecuteAfterEvent["output"];
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "$schema": "https://json.schemastore.org/package.json",
3
3
  "name": "@opencode-ai/plugin",
4
- "version": "0.0.0-next-15543",
4
+ "version": "0.0.0-next-15548",
5
5
  "type": "module",
6
6
  "license": "MIT",
7
7
  "scripts": {
@@ -52,9 +52,9 @@
52
52
  ],
53
53
  "dependencies": {
54
54
  "@ai-sdk/provider": "3.0.8",
55
- "@opencode-ai/client": "0.0.0-next-15543",
56
- "@opencode-ai/schema": "0.0.0-next-15543",
57
- "@opencode-ai/sdk": "0.0.0-next-15543",
55
+ "@opencode-ai/client": "0.0.0-next-15548",
56
+ "@opencode-ai/schema": "0.0.0-next-15548",
57
+ "@opencode-ai/sdk": "0.0.0-next-15548",
58
58
  "effect": "4.0.0-beta.83",
59
59
  "zod": "4.1.8"
60
60
  },