@opencode/server 0.0.0-dev-19596 → 0.0.0-dev-19598

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.
package/dist/api.d.ts CHANGED
@@ -145,7 +145,7 @@ export declare const Api: import("@opencode/protocol/api").Api<LocationMiddlewar
145
145
  };
146
146
  readonly created: import("effect/Schema").Finite;
147
147
  readonly metadata: import("effect/Schema").decodeTo<import("effect/Schema").optional<import("effect/Schema").toType<import("effect/Schema").$Record<import("effect/Schema").String, import("effect/Schema").Unknown>>>, import("effect/Schema").optionalKey<import("effect/Schema").$Record<import("effect/Schema").String, import("effect/Schema").Unknown>>, never, never>;
148
- readonly type: import("effect/Schema").Literal<"catalog.updated">;
148
+ readonly type: import("effect/Schema").Literal<"provider.updated">;
149
149
  readonly location: import("effect/Schema").decodeTo<import("effect/Schema").optional<import("effect/Schema").toType<import("effect/Schema").Struct<{
150
150
  readonly directory: import("effect/Schema").brand<import("effect/Schema").String, "AbsolutePath">;
151
151
  readonly workspaceID: import("effect/Schema").decodeTo<import("effect/Schema").optional<import("effect/Schema").toType<import("effect/Schema").brand<import("effect/Schema").String, "Workspace.ID"> & {
@@ -167,7 +167,39 @@ export declare const Api: import("@opencode/protocol/api").Api<LocationMiddlewar
167
167
  }>>, never, never>;
168
168
  readonly data: import("effect/Schema").Struct<{}>;
169
169
  }> & {
170
- type: "catalog.updated";
170
+ type: "provider.updated";
171
+ durability: "ephemeral";
172
+ durable: undefined;
173
+ data: import("effect/Schema").Struct<{}>;
174
+ }, import("effect/Schema").Struct<{
175
+ readonly id: import("effect/Schema").brand<import("effect/Schema").String, "Event.ID"> & {
176
+ create: () => string & import("effect/Brand").Brand<"Event.ID">;
177
+ };
178
+ readonly created: import("effect/Schema").Finite;
179
+ readonly metadata: import("effect/Schema").decodeTo<import("effect/Schema").optional<import("effect/Schema").toType<import("effect/Schema").$Record<import("effect/Schema").String, import("effect/Schema").Unknown>>>, import("effect/Schema").optionalKey<import("effect/Schema").$Record<import("effect/Schema").String, import("effect/Schema").Unknown>>, never, never>;
180
+ readonly type: import("effect/Schema").Literal<"model.updated">;
181
+ readonly location: import("effect/Schema").decodeTo<import("effect/Schema").optional<import("effect/Schema").toType<import("effect/Schema").Struct<{
182
+ readonly directory: import("effect/Schema").brand<import("effect/Schema").String, "AbsolutePath">;
183
+ readonly workspaceID: import("effect/Schema").decodeTo<import("effect/Schema").optional<import("effect/Schema").toType<import("effect/Schema").brand<import("effect/Schema").String, "Workspace.ID"> & {
184
+ ascending: (id?: string) => string & import("effect/Brand").Brand<"Workspace.ID">;
185
+ create: () => string & import("effect/Brand").Brand<"Workspace.ID">;
186
+ }>>, import("effect/Schema").optionalKey<import("effect/Schema").brand<import("effect/Schema").String, "Workspace.ID"> & {
187
+ ascending: (id?: string) => string & import("effect/Brand").Brand<"Workspace.ID">;
188
+ create: () => string & import("effect/Brand").Brand<"Workspace.ID">;
189
+ }>, never, never>;
190
+ }>>>, import("effect/Schema").optionalKey<import("effect/Schema").Struct<{
191
+ readonly directory: import("effect/Schema").brand<import("effect/Schema").String, "AbsolutePath">;
192
+ readonly workspaceID: import("effect/Schema").decodeTo<import("effect/Schema").optional<import("effect/Schema").toType<import("effect/Schema").brand<import("effect/Schema").String, "Workspace.ID"> & {
193
+ ascending: (id?: string) => string & import("effect/Brand").Brand<"Workspace.ID">;
194
+ create: () => string & import("effect/Brand").Brand<"Workspace.ID">;
195
+ }>>, import("effect/Schema").optionalKey<import("effect/Schema").brand<import("effect/Schema").String, "Workspace.ID"> & {
196
+ ascending: (id?: string) => string & import("effect/Brand").Brand<"Workspace.ID">;
197
+ create: () => string & import("effect/Brand").Brand<"Workspace.ID">;
198
+ }>, never, never>;
199
+ }>>, never, never>;
200
+ readonly data: import("effect/Schema").Struct<{}>;
201
+ }> & {
202
+ type: "model.updated";
171
203
  durability: "ephemeral";
172
204
  durable: undefined;
173
205
  data: import("effect/Schema").Struct<{}>;
@@ -6450,6 +6482,30 @@ export declare const Api: import("@opencode/protocol/api").Api<LocationMiddlewar
6450
6482
  readonly metadata?: {
6451
6483
  readonly [x: string]: unknown;
6452
6484
  } | undefined;
6485
+ } | {
6486
+ readonly id: string & import("effect/Brand").Brand<"Event.ID">;
6487
+ readonly data: {};
6488
+ readonly type: "provider.updated";
6489
+ readonly created: number;
6490
+ readonly location?: {
6491
+ readonly directory: string & import("effect/Brand").Brand<"AbsolutePath">;
6492
+ readonly workspaceID?: (string & import("effect/Brand").Brand<"Workspace.ID">) | undefined;
6493
+ } | undefined;
6494
+ readonly metadata?: {
6495
+ readonly [x: string]: unknown;
6496
+ } | undefined;
6497
+ } | {
6498
+ readonly id: string & import("effect/Brand").Brand<"Event.ID">;
6499
+ readonly data: {};
6500
+ readonly type: "model.updated";
6501
+ readonly created: number;
6502
+ readonly location?: {
6503
+ readonly directory: string & import("effect/Brand").Brand<"AbsolutePath">;
6504
+ readonly workspaceID?: (string & import("effect/Brand").Brand<"Workspace.ID">) | undefined;
6505
+ } | undefined;
6506
+ readonly metadata?: {
6507
+ readonly [x: string]: unknown;
6508
+ } | undefined;
6453
6509
  } | {
6454
6510
  readonly id: string & import("effect/Brand").Brand<"Event.ID">;
6455
6511
  readonly data: {
@@ -7942,18 +7998,6 @@ export declare const Api: import("@opencode/protocol/api").Api<LocationMiddlewar
7942
7998
  readonly metadata?: {
7943
7999
  readonly [x: string]: unknown;
7944
8000
  } | undefined;
7945
- } | {
7946
- readonly id: string & import("effect/Brand").Brand<"Event.ID">;
7947
- readonly data: {};
7948
- readonly type: "catalog.updated";
7949
- readonly created: number;
7950
- readonly location?: {
7951
- readonly directory: string & import("effect/Brand").Brand<"AbsolutePath">;
7952
- readonly workspaceID?: (string & import("effect/Brand").Brand<"Workspace.ID">) | undefined;
7953
- } | undefined;
7954
- readonly metadata?: {
7955
- readonly [x: string]: unknown;
7956
- } | undefined;
7957
8001
  } | {
7958
8002
  readonly id: string & import("effect/Brand").Brand<"Event.ID">;
7959
8003
  readonly data: {};
@@ -1,14 +1,14 @@
1
- import { Catalog } from "@opencode/core/catalog";
1
+ import { Model } from "@opencode/core/model";
2
2
  import { Effect } from "effect";
3
3
  import { HttpApiBuilder } from "effect/unstable/httpapi";
4
4
  import { Api } from "../api";
5
5
  import { response } from "../location";
6
6
  export const ModelHandler = HttpApiBuilder.group(Api, "server.model", (handlers) => Effect.gen(function* () {
7
7
  return handlers.handle("model.list", Effect.fn(function* () {
8
- const catalog = yield* Catalog.Service;
9
- return yield* response(catalog.model.available());
8
+ const models = yield* Model.Service;
9
+ return yield* response(models.available());
10
10
  })).handle("model.default", Effect.fn(function* () {
11
- const catalog = yield* Catalog.Service;
12
- return yield* response(catalog.model.default());
11
+ const models = yield* Model.Service;
12
+ return yield* response(models.default());
13
13
  }));
14
14
  }));
@@ -1,4 +1,4 @@
1
- import { Catalog } from "@opencode/core/catalog";
1
+ import { Provider } from "@opencode/core/provider";
2
2
  import { ProviderNotFoundError } from "@opencode/protocol/errors";
3
3
  import { Effect } from "effect";
4
4
  import { HttpApiBuilder } from "effect/unstable/httpapi";
@@ -6,10 +6,10 @@ import { Api } from "../api";
6
6
  import { response } from "../location";
7
7
  export const ProviderHandler = HttpApiBuilder.group(Api, "server.provider", (handlers) => Effect.gen(function* () {
8
8
  return handlers.handle("provider.list", Effect.fn(function* () {
9
- const catalog = yield* Catalog.Service;
10
- return yield* response(catalog.provider.available());
9
+ const providers = yield* Provider.Service;
10
+ return yield* response(providers.available());
11
11
  })).handle("provider.get", Effect.fn(function* (ctx) {
12
- const provider = yield* (yield* Catalog.Service).provider.get(ctx.params.providerID);
12
+ const provider = yield* (yield* Provider.Service).get(ctx.params.providerID);
13
13
  if (!provider)
14
14
  return yield* new ProviderNotFoundError({
15
15
  providerID: ctx.params.providerID,
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "$schema": "https://json.schemastore.org/package.json",
3
3
  "name": "@opencode/server",
4
- "version": "0.0.0-dev-19596",
4
+ "version": "0.0.0-dev-19598",
5
5
  "type": "module",
6
6
  "license": "MIT",
7
7
  "repository": {
@@ -30,17 +30,17 @@
30
30
  "dependencies": {
31
31
  "@effect/platform-node": "4.0.0-rc.112",
32
32
  "@effect/platform-node-shared": "4.0.0-rc.112",
33
- "@opencode/core": "0.0.0-dev-19596",
34
- "@opencode/protocol": "0.0.0-dev-19596",
35
- "@opencode/schema": "0.0.0-dev-19596",
36
- "@opencode/simulation": "0.0.0-dev-19596",
37
- "@opencode/util": "0.0.0-dev-19596",
33
+ "@opencode/core": "0.0.0-dev-19598",
34
+ "@opencode/protocol": "0.0.0-dev-19598",
35
+ "@opencode/schema": "0.0.0-dev-19598",
36
+ "@opencode/simulation": "0.0.0-dev-19598",
37
+ "@opencode/util": "0.0.0-dev-19598",
38
38
  "drizzle-orm": "1.0.0-rc.5-169397b",
39
39
  "effect": "4.0.0-rc.112"
40
40
  },
41
41
  "devDependencies": {
42
- "@opencode/client": "0.0.0-dev-19596",
43
- "@opencode/plugin": "0.0.0-dev-19596",
42
+ "@opencode/client": "0.0.0-dev-19598",
43
+ "@opencode/plugin": "0.0.0-dev-19598",
44
44
  "@tsconfig/bun": "1.0.9",
45
45
  "@types/bun": "1.4.0",
46
46
  "@typescript/native-preview": "7.0.0-dev.20251207.1"