@opencode/plugin 2.0.31 → 2.1.0

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.
@@ -35,7 +35,8 @@ export interface SessionContext extends SessionRequest {
35
35
  }
36
36
  export interface SessionCompactionResult {
37
37
  summary: string;
38
- providerState?: SessionMessage.ProviderState;
38
+ /** `native.messages`, when set, must be a provider replacement window; it replays instead of `summary`. */
39
+ native?: SessionMessage.Native;
39
40
  metadata?: Record<string, unknown>;
40
41
  tokens?: TokenUsage.Info;
41
42
  }
@@ -140,6 +141,6 @@ export interface SessionHooks {
140
141
  readonly "experimental.ws.receive": SessionWebSocketReceive;
141
142
  readonly retry: SessionRetry;
142
143
  }
143
- export type SessionDomain = Pick<SessionApi<unknown>, "create" | "get" | "remove" | "switchAgent" | "switchModel" | "prompt" | "generate" | "command" | "compact" | "synthetic" | "interrupt" | "update" | "move" | "wait" | "context"> & {
144
+ export type SessionDomain = Pick<SessionApi<unknown>, "list" | "create" | "get" | "remove" | "switchAgent" | "switchModel" | "prompt" | "generate" | "command" | "compact" | "synthetic" | "interrupt" | "update" | "move" | "wait" | "context"> & {
144
145
  readonly hook: ModelHooks<SessionHooks>;
145
146
  };
@@ -426,6 +426,7 @@ export function fromPromise(plugin) {
426
426
  },
427
427
  session: {
428
428
  hook: (name, callback, options) => register(host.session.hook(name, (event) => Effect.promise(() => Promise.resolve(callback(event))), options)),
429
+ list: adaptApiMethod(SessionEndpoints["session.list"], host.session.list),
429
430
  create: adaptApiMethod(SessionEndpoints["session.create"], host.session.create),
430
431
  get: adaptApiMethod(SessionEndpoints["session.get"], host.session.get),
431
432
  remove: adaptApiMethod(SessionEndpoints["session.remove"], host.session.remove),
@@ -35,7 +35,8 @@ export interface SessionContext extends SessionRequest {
35
35
  }
36
36
  export interface SessionCompactionResult {
37
37
  summary: string;
38
- providerState?: SessionMessage.ProviderState;
38
+ /** `native.messages`, when set, must be a provider replacement window; it replays instead of `summary`. */
39
+ native?: SessionMessage.Native;
39
40
  metadata?: Record<string, unknown>;
40
41
  tokens?: TokenUsage.Info;
41
42
  }
@@ -140,6 +141,6 @@ export interface SessionHooks {
140
141
  readonly "experimental.ws.receive": SessionWebSocketReceive;
141
142
  readonly retry: SessionRetry;
142
143
  }
143
- export type SessionDomain = Pick<SessionApi, "create" | "get" | "remove" | "switchAgent" | "switchModel" | "prompt" | "generate" | "command" | "compact" | "synthetic" | "interrupt" | "update" | "move" | "wait" | "context"> & {
144
+ export type SessionDomain = Pick<SessionApi, "list" | "create" | "get" | "remove" | "switchAgent" | "switchModel" | "prompt" | "generate" | "command" | "compact" | "synthetic" | "interrupt" | "update" | "move" | "wait" | "context"> & {
144
145
  readonly hook: ModelHooks<SessionHooks>;
145
146
  };
package/dist/source.d.ts CHANGED
@@ -5,4 +5,4 @@ export declare function createPluginSources(watch: (file: string) => Promise<voi
5
5
  }>;
6
6
  dispose: () => void;
7
7
  };
8
- export declare function localSource(spec: string, directory: string): import("url").URL | undefined;
8
+ export declare function localSource(spec: string, directory: string): URL | undefined;
package/package.json CHANGED
@@ -1,12 +1,12 @@
1
1
  {
2
2
  "$schema": "https://json.schemastore.org/package.json",
3
3
  "name": "@opencode/plugin",
4
- "version": "2.0.31",
4
+ "version": "2.1.0",
5
5
  "type": "module",
6
6
  "license": "MIT",
7
7
  "scripts": {
8
8
  "test": "bun test --only-failures",
9
- "typecheck": "tsgo --noEmit",
9
+ "typecheck": "tsc --noEmit",
10
10
  "build": "tsc -p tsconfig.build.json"
11
11
  },
12
12
  "exports": {
@@ -47,17 +47,17 @@
47
47
  ],
48
48
  "dependencies": {
49
49
  "@ai-sdk/provider": "3.0.8",
50
- "@opencode/ai": "2.0.31",
51
- "@opencode/client": "2.0.31",
52
- "@opencode/protocol": "2.0.31",
53
- "@opencode/schema": "2.0.31",
54
- "@opencode/util": "2.0.31",
50
+ "@opencode/ai": "2.1.0",
51
+ "@opencode/client": "2.1.0",
52
+ "@opencode/protocol": "2.1.0",
53
+ "@opencode/schema": "2.1.0",
54
+ "@opencode/util": "2.1.0",
55
55
  "effect": "4.0.1"
56
56
  },
57
57
  "peerDependencies": {
58
- "@opencode/theme": "2.0.31",
59
- "@opentui/core": ">=0.5.17",
60
- "@opentui/solid": ">=0.5.17",
58
+ "@opencode/theme": "2.1.0",
59
+ "@opentui/core": ">=0.6.6",
60
+ "@opentui/solid": ">=0.6.6",
61
61
  "solid-js": ">=1.9.0"
62
62
  },
63
63
  "peerDependenciesMeta": {
@@ -75,15 +75,15 @@
75
75
  }
76
76
  },
77
77
  "devDependencies": {
78
- "@opencode/theme": "2.0.31",
79
- "@opentui/core": "0.5.17",
80
- "@opentui/solid": "0.5.17",
78
+ "@opencode/theme": "2.1.0",
79
+ "@opentui/core": "0.6.6",
80
+ "@opentui/solid": "0.6.6",
81
81
  "@tsconfig/bun": "1.0.9",
82
82
  "@tsconfig/node22": "22.0.2",
83
83
  "@types/bun": "1.4.0",
84
84
  "@types/node": "24.12.2",
85
85
  "solid-js": "1.9.15",
86
- "typescript": "5.8.2",
87
- "@typescript/native-preview": "7.0.0-dev.20251207.1"
86
+ "typescript": "npm:@typescript/typescript6@6.0.2",
87
+ "@typescript/native": "npm:typescript@7.0.2"
88
88
  }
89
89
  }