@opencode/protocol 0.0.0-dev-1309 → 0.0.0-dev-1310

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.
@@ -3,5 +3,7 @@ import { HttpApiEndpoint } from "effect/http-api";
3
3
  import { BlobNotFoundError } from "../errors.js";
4
4
  /** Lives in the `server.experimental` group (see `groups/experimental.ts`). */
5
5
  export declare const BlobGetEndpoint: HttpApiEndpoint.HttpApiEndpoint<"blob.get", "GET", "/api/experimental/blob/:id", Schema.toCodecStringTree<Schema.Struct<{
6
- id: Schema.brand<Schema.String, "Blob.ID">;
6
+ id: Schema.brand<Schema.String, "Blob.ID"> & {
7
+ create: () => string & import("effect/Brand").Brand<"Blob.ID">;
8
+ };
7
9
  }>>, never, never, never, Schema.toCodecJson<Schema.Uint8Array>, Schema.toCodecJson<typeof BlobNotFoundError>, never, never>;
@@ -10,7 +10,7 @@ export const BlobGetEndpoint = HttpApiEndpoint.get("blob.get", "/api/experimenta
10
10
  }).annotateMerge(OpenApi.annotations({
11
11
  identifier: "experimental.blob.get",
12
12
  summary: "Read a blob",
13
- description: "Stream a stored blob's bytes, such as a generated video, with single byte Range, ETag and 304 Not Modified support. Blobs are deleted 7 days after they're written. Experimental: may change without compatibility guarantees.",
13
+ description: "Stream a stored blob's bytes, such as a generated video, with single byte Range, ETag and 304 Not Modified support. Blobs are kept until removed. Experimental: may change without compatibility guarantees.",
14
14
  // The route shares the `server.experimental` group with the persistent PTY prototype; tag it on its own.
15
15
  transform: (operation) => ({ ...operation, tags: ["experimental"] }),
16
16
  }));
@@ -561,7 +561,9 @@ export declare const ExperimentalGroup: import("effect/http-api/HttpApiGroup").H
561
561
  }>;
562
562
  }>;
563
563
  }>>, import("effect/Schema").toCodecJson<typeof import("../errors.js").ForbiddenError | typeof import("../errors.js").AutomationNotFoundError>, never, never> | import("effect/http-api/HttpApiEndpoint").HttpApiEndpoint<"blob.get", "GET", "/api/experimental/blob/:id", import("effect/Schema").toCodecStringTree<import("effect/Schema").Struct<{
564
- id: import("effect/Schema").brand<import("effect/Schema").String, "Blob.ID">;
564
+ id: import("effect/Schema").brand<import("effect/Schema").String, "Blob.ID"> & {
565
+ create: () => string & import("effect/Brand").Brand<"Blob.ID">;
566
+ };
565
567
  }>>, never, never, never, import("effect/Schema").toCodecJson<import("effect/Schema").Uint8Array>, import("effect/Schema").toCodecJson<typeof import("../errors.js").BlobNotFoundError>, never, never> | import("effect/http-api/HttpApiEndpoint").HttpApiEndpoint<"job.list", "GET", "/api/experimental/job", never, import("effect/Schema").toCodecStringTree<import("effect/Schema").Struct<{
566
568
  readonly sessionID: import("effect/Schema").optional<import("effect/Schema").brand<import("effect/Schema").String, "SessionID"> & {
567
569
  create: () => string & import("effect/Brand").Brand<"SessionID">;
@@ -312,10 +312,11 @@ export declare const GenerateGroup: HttpApiGroup.HttpApiGroup<"server.generate",
312
312
  };
313
313
  readonly status: Schema.Literal<"completed">;
314
314
  readonly blobs: Schema.$Array<Schema.Struct<{
315
- readonly id: Schema.brand<Schema.String, "Blob.ID">;
315
+ readonly id: Schema.brand<Schema.String, "Blob.ID"> & {
316
+ create: () => string & import("effect/Brand").Brand<"Blob.ID">;
317
+ };
316
318
  readonly mime: Schema.String;
317
319
  readonly bytes: Schema.Finite;
318
- readonly expiresAt: Schema.Finite;
319
320
  }>>;
320
321
  }>, Schema.Struct<{
321
322
  readonly id: Schema.brand<Schema.String, "Generate.VideoID"> & {
@@ -51,7 +51,7 @@ export const GenerateGroup = HttpApiGroup.make("server.generate")
51
51
  }).annotateMerge(OpenApi.annotations({
52
52
  identifier: "experimental.generate.video.create",
53
53
  summary: "Create a video generation",
54
- description: "Submit a video job to a video model using the server's base configuration and return its ID once the provider accepted it. The server polls the job and stores the finished video as a blob for 7 days; read the job with GET /api/experimental/generate/video/:id and the video with GET /api/experimental/blob/:id. Behind the video_generate flag. Experimental: may change without compatibility guarantees.",
54
+ description: "Submit a video job to a video model using the server's base configuration and return its ID once the provider accepted it. The server polls the job and stores the finished videos as blobs; read the job with GET /api/experimental/generate/video/:id and the video with GET /api/experimental/blob/:id. Behind the video_generate flag. Experimental: may change without compatibility guarantees.",
55
55
  })))
56
56
  .add(HttpApiEndpoint.get("generate.video.get", "/api/experimental/generate/video/:id", {
57
57
  params: { id: Generate.VideoID },
@@ -60,7 +60,7 @@ export const GenerateGroup = HttpApiGroup.make("server.generate")
60
60
  }).annotateMerge(OpenApi.annotations({
61
61
  identifier: "experimental.generate.video.get",
62
62
  summary: "Read a video generation",
63
- description: "Read a video job: running, completed with the video's blob, or error with a reason. Jobs are kept in memory, so a server restart forgets them; a finished video's blob stays readable. Behind the video_generate flag. Experimental: may change without compatibility guarantees.",
63
+ description: "Read a video job: running, completed with its videos' blobs, or error with a reason. Jobs survive a server restart, which resumes polling running ones. A job is not found 24 hours after it finished, or once none of its blobs remain. Behind the video_generate flag. Experimental: may change without compatibility guarantees.",
64
64
  })))
65
65
  .add(HttpApiEndpoint.post("generate.decisions", "/api/experimental/generate/decisions", {
66
66
  payload: Generate.DecisionRequest,
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "$schema": "https://json.schemastore.org/package.json",
3
3
  "name": "@opencode/protocol",
4
- "version": "0.0.0-dev-1309",
4
+ "version": "0.0.0-dev-1310",
5
5
  "type": "module",
6
6
  "license": "MIT",
7
7
  "repository": {
@@ -35,7 +35,7 @@
35
35
  "typecheck:tsc": "tsc --noEmit"
36
36
  },
37
37
  "dependencies": {
38
- "@opencode/schema": "0.0.0-dev-1309",
38
+ "@opencode/schema": "0.0.0-dev-1310",
39
39
  "effect": "4.1.0"
40
40
  },
41
41
  "devDependencies": {