@opencode-ai/plugin 1.1.18 → 1.1.20

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.
Files changed (2) hide show
  1. package/dist/tool.d.ts +16 -0
  2. package/package.json +2 -2
package/dist/tool.d.ts CHANGED
@@ -4,6 +4,21 @@ export type ToolContext = {
4
4
  messageID: string;
5
5
  agent: string;
6
6
  abort: AbortSignal;
7
+ metadata(input: {
8
+ title?: string;
9
+ metadata?: {
10
+ [key: string]: any;
11
+ };
12
+ }): void;
13
+ ask(input: AskInput): Promise<void>;
14
+ };
15
+ type AskInput = {
16
+ permission: string;
17
+ patterns: string[];
18
+ always: string[];
19
+ metadata: {
20
+ [key: string]: any;
21
+ };
7
22
  };
8
23
  export declare function tool<Args extends z.ZodRawShape>(input: {
9
24
  description: string;
@@ -18,3 +33,4 @@ export declare namespace tool {
18
33
  var schema: typeof z;
19
34
  }
20
35
  export type ToolDefinition = ReturnType<typeof tool>;
36
+ export {};
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": "1.1.18",
4
+ "version": "1.1.20",
5
5
  "type": "module",
6
6
  "license": "MIT",
7
7
  "scripts": {
@@ -22,7 +22,7 @@
22
22
  "dist"
23
23
  ],
24
24
  "dependencies": {
25
- "@opencode-ai/sdk": "1.1.18",
25
+ "@opencode-ai/sdk": "1.1.20",
26
26
  "zod": "4.1.8"
27
27
  },
28
28
  "devDependencies": {