@opencode-ai/protocol 0.0.0-next-14854 → 0.0.0-reserved.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.
Files changed (63) hide show
  1. package/README.md +3 -0
  2. package/index.js +1 -0
  3. package/package.json +3 -23
  4. package/dist/api.d.ts +0 -49
  5. package/dist/api.js +0 -65
  6. package/dist/client.d.ts +0 -75
  7. package/dist/client.js +0 -61
  8. package/dist/errors.d.ts +0 -127
  9. package/dist/errors.js +0 -99
  10. package/dist/groups/agent.d.ts +0 -95
  11. package/dist/groups/agent.js +0 -15
  12. package/dist/groups/command.d.ts +0 -51
  13. package/dist/groups/command.js +0 -20
  14. package/dist/groups/credential.d.ts +0 -23
  15. package/dist/groups/credential.js +0 -28
  16. package/dist/groups/event.d.ts +0 -17224
  17. package/dist/groups/event.js +0 -49
  18. package/dist/groups/form.d.ts +0 -789
  19. package/dist/groups/form.js +0 -99
  20. package/dist/groups/fs.d.ts +0 -35
  21. package/dist/groups/fs.js +0 -51
  22. package/dist/groups/generate.d.ts +0 -32
  23. package/dist/groups/generate.js +0 -27
  24. package/dist/groups/health.d.ts +0 -5
  25. package/dist/groups/health.js +0 -9
  26. package/dist/groups/integration.d.ts +0 -105
  27. package/dist/groups/integration.js +0 -98
  28. package/dist/groups/location.d.ts +0 -16
  29. package/dist/groups/location.js +0 -32
  30. package/dist/groups/mcp.d.ts +0 -30
  31. package/dist/groups/mcp.js +0 -17
  32. package/dist/groups/message.d.ts +0 -446
  33. package/dist/groups/message.js +0 -42
  34. package/dist/groups/model.d.ts +0 -312
  35. package/dist/groups/model.js +0 -33
  36. package/dist/groups/permission.d.ts +0 -153
  37. package/dist/groups/permission.js +0 -99
  38. package/dist/groups/plugin.d.ts +0 -14
  39. package/dist/groups/plugin.js +0 -20
  40. package/dist/groups/project-copy.d.ts +0 -49
  41. package/dist/groups/project-copy.js +0 -44
  42. package/dist/groups/project.d.ts +0 -24
  43. package/dist/groups/project.js +0 -30
  44. package/dist/groups/provider.d.ts +0 -164
  45. package/dist/groups/provider.js +0 -34
  46. package/dist/groups/pty.d.ts +0 -145
  47. package/dist/groups/pty.js +0 -111
  48. package/dist/groups/question.d.ts +0 -92
  49. package/dist/groups/question.js +0 -56
  50. package/dist/groups/reference.d.ts +0 -13
  51. package/dist/groups/reference.js +0 -20
  52. package/dist/groups/session.d.ts +0 -5457
  53. package/dist/groups/session.js +0 -423
  54. package/dist/groups/shell.d.ts +0 -120
  55. package/dist/groups/shell.js +0 -65
  56. package/dist/groups/skill.d.ts +0 -19
  57. package/dist/groups/skill.js +0 -20
  58. package/dist/groups/vcs.d.ts +0 -33
  59. package/dist/groups/vcs.js +0 -37
  60. package/dist/middleware/authorization.d.ts +0 -13
  61. package/dist/middleware/authorization.js +0 -6
  62. package/dist/middleware/schema-error.d.ts +0 -13
  63. package/dist/middleware/schema-error.js +0 -4
@@ -1,33 +0,0 @@
1
- import { Location } from "@opencode-ai/schema/location";
2
- import { Schema } from "effect";
3
- import { HttpApiEndpoint, HttpApiGroup } from "effect/unstable/httpapi";
4
- export declare const VcsGroup: HttpApiGroup.HttpApiGroup<"server.vcs", HttpApiEndpoint.HttpApiEndpoint<"vcs.status", "GET", "/api/vcs/status", HttpApiEndpoint.StringTree<never>, HttpApiEndpoint.StringTree<Schema.Struct<{
5
- readonly location: Schema.optional<Schema.Struct<{
6
- readonly directory: Schema.optional<Schema.String>;
7
- readonly workspace: Schema.optional<Schema.String>;
8
- }>>;
9
- }>>, HttpApiEndpoint.StringTree<never>, HttpApiEndpoint.StringTree<never>, HttpApiEndpoint.Json<Schema.Struct<{
10
- readonly location: typeof Location.Info;
11
- readonly data: Schema.$Array<Schema.Struct<{
12
- readonly file: Schema.String;
13
- readonly additions: Schema.Int;
14
- readonly deletions: Schema.Int;
15
- readonly status: Schema.Literals<readonly ["added", "deleted", "modified"]>;
16
- }>>;
17
- }>>, HttpApiEndpoint.Json<never>, never, never> | HttpApiEndpoint.HttpApiEndpoint<"vcs.diff", "GET", "/api/vcs/diff", HttpApiEndpoint.StringTree<never>, HttpApiEndpoint.StringTree<Schema.Struct<{
18
- readonly mode: Schema.Literals<readonly ["working", "branch"]>;
19
- readonly context: Schema.optional<Schema.compose<Schema.Int, Schema.NumberFromString>>;
20
- readonly location: Schema.optional<Schema.Struct<{
21
- readonly directory: Schema.optional<Schema.String>;
22
- readonly workspace: Schema.optional<Schema.String>;
23
- }>>;
24
- }>>, HttpApiEndpoint.StringTree<never>, HttpApiEndpoint.StringTree<never>, HttpApiEndpoint.Json<Schema.Struct<{
25
- readonly location: typeof Location.Info;
26
- readonly data: Schema.$Array<Schema.Struct<{
27
- readonly file: Schema.decodeTo<Schema.optional<Schema.toType<Schema.String>>, Schema.optionalKey<Schema.String>, never, never>;
28
- readonly patch: Schema.decodeTo<Schema.optional<Schema.toType<Schema.String>>, Schema.optionalKey<Schema.String>, never, never>;
29
- readonly additions: Schema.Finite;
30
- readonly deletions: Schema.Finite;
31
- readonly status: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Literals<readonly ["added", "deleted", "modified"]>>>, Schema.optionalKey<Schema.Literals<readonly ["added", "deleted", "modified"]>>, never, never>;
32
- }>>;
33
- }>>, HttpApiEndpoint.Json<never>, never, never>, false>;
@@ -1,37 +0,0 @@
1
- import { FileDiff } from "@opencode-ai/schema/file-diff";
2
- import { Location } from "@opencode-ai/schema/location";
3
- import { NonNegativeInt } from "@opencode-ai/schema/schema";
4
- import { Vcs } from "@opencode-ai/schema/vcs";
5
- import { Schema } from "effect";
6
- import { HttpApiEndpoint, HttpApiGroup, OpenApi } from "effect/unstable/httpapi";
7
- import { LocationQuery, locationQueryOpenApi } from "./location.js";
8
- const DiffQuery = Schema.Struct({
9
- ...LocationQuery.fields,
10
- mode: Vcs.Mode,
11
- context: Schema.NumberFromString.pipe(Schema.decodeTo(NonNegativeInt), Schema.optional),
12
- });
13
- export const VcsGroup = HttpApiGroup.make("server.vcs")
14
- .add(HttpApiEndpoint.get("vcs.status", "/api/vcs/status", {
15
- query: LocationQuery,
16
- success: Location.response(Schema.Array(Vcs.FileStatus)),
17
- })
18
- .annotateMerge(locationQueryOpenApi)
19
- .annotateMerge(OpenApi.annotations({
20
- identifier: "v2.vcs.status",
21
- summary: "VCS status",
22
- description: "List uncommitted working-copy changes relative to the requested location.",
23
- })))
24
- .add(HttpApiEndpoint.get("vcs.diff", "/api/vcs/diff", {
25
- query: DiffQuery,
26
- success: Location.response(Schema.Array(FileDiff.Info)),
27
- })
28
- .annotateMerge(locationQueryOpenApi)
29
- .annotateMerge(OpenApi.annotations({
30
- identifier: "v2.vcs.diff",
31
- summary: "VCS diff",
32
- description: "Diff the working copy against HEAD (mode git) or the default-branch merge base (mode branch) for the requested location.",
33
- })))
34
- .annotateMerge(OpenApi.annotations({
35
- title: "vcs",
36
- description: "Location-scoped version control routes.",
37
- }));
@@ -1,13 +0,0 @@
1
- import { HttpApiMiddleware } from "effect/unstable/httpapi";
2
- import { UnauthorizedError } from "../errors.js";
3
- declare const Authorization_base: HttpApiMiddleware.ServiceClass<Authorization, "@opencode/HttpApiAuthorization", {
4
- requires: never;
5
- provides: never;
6
- error: typeof UnauthorizedError;
7
- clientError: never;
8
- requiredForClient: false;
9
- security: never;
10
- }, HttpApiMiddleware.HttpApiMiddleware<never, typeof UnauthorizedError, never>>;
11
- export declare class Authorization extends Authorization_base {
12
- }
13
- export {};
@@ -1,6 +0,0 @@
1
- import { HttpApiMiddleware } from "effect/unstable/httpapi";
2
- import { UnauthorizedError } from "../errors.js";
3
- export class Authorization extends HttpApiMiddleware.Service()("@opencode/HttpApiAuthorization", {
4
- error: UnauthorizedError,
5
- }) {
6
- }
@@ -1,13 +0,0 @@
1
- import { HttpApiMiddleware } from "effect/unstable/httpapi";
2
- import { InvalidRequestError } from "../errors.js";
3
- declare const SchemaErrorMiddleware_base: HttpApiMiddleware.ServiceClass<SchemaErrorMiddleware, "@opencode/HttpApiSchemaError", {
4
- requires: never;
5
- provides: never;
6
- error: typeof InvalidRequestError;
7
- clientError: never;
8
- requiredForClient: false;
9
- security: never;
10
- }, HttpApiMiddleware.HttpApiMiddleware<never, typeof InvalidRequestError, never>>;
11
- export declare class SchemaErrorMiddleware extends SchemaErrorMiddleware_base {
12
- }
13
- export {};
@@ -1,4 +0,0 @@
1
- import { HttpApiMiddleware } from "effect/unstable/httpapi";
2
- import { InvalidRequestError } from "../errors.js";
3
- export class SchemaErrorMiddleware extends HttpApiMiddleware.Service()("@opencode/HttpApiSchemaError", { error: InvalidRequestError }) {
4
- }