@opencode-ai/schema 0.0.0-dev-17471
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/agent.d.ts +164 -0
- package/dist/agent.js +46 -0
- package/dist/ai.d.ts +4 -0
- package/dist/ai.js +5 -0
- package/dist/catalog.d.ts +69 -0
- package/dist/catalog.js +4 -0
- package/dist/command.d.ts +124 -0
- package/dist/command.js +19 -0
- package/dist/config/agent.d.ts +42 -0
- package/dist/config/agent.js +20 -0
- package/dist/config/command.d.ts +27 -0
- package/dist/config/command.js +12 -0
- package/dist/config/compaction.d.ts +14 -0
- package/dist/config/compaction.js +13 -0
- package/dist/config/experimental.d.ts +17 -0
- package/dist/config/experimental.js +16 -0
- package/dist/config/formatter.d.ts +11 -0
- package/dist/config/formatter.js +11 -0
- package/dist/config/lsp.d.ts +20 -0
- package/dist/config/lsp.js +16 -0
- package/dist/config/mcp.d.ts +18 -0
- package/dist/config/mcp.js +14 -0
- package/dist/config/media.d.ts +15 -0
- package/dist/config/media.js +14 -0
- package/dist/config/model.d.ts +18 -0
- package/dist/config/model.js +28 -0
- package/dist/config/plugin.d.ts +11 -0
- package/dist/config/plugin.js +10 -0
- package/dist/config/policy.d.ts +10 -0
- package/dist/config/policy.js +8 -0
- package/dist/config/provider.d.ts +106 -0
- package/dist/config/provider.js +62 -0
- package/dist/config/reference.d.ts +21 -0
- package/dist/config/reference.js +18 -0
- package/dist/config/tool-output.d.ts +8 -0
- package/dist/config/tool-output.js +8 -0
- package/dist/config/warming.d.ts +10 -0
- package/dist/config/warming.js +16 -0
- package/dist/config/watcher.d.ts +7 -0
- package/dist/config/watcher.js +7 -0
- package/dist/config/websearch.d.ts +9 -0
- package/dist/config/websearch.js +8 -0
- package/dist/config.d.ts +175 -0
- package/dist/config.js +136 -0
- package/dist/connection.d.ts +28 -0
- package/dist/connection.js +15 -0
- package/dist/credential.d.ts +38 -0
- package/dist/credential.js +25 -0
- package/dist/durable-event-manifest.d.ts +3 -0
- package/dist/durable-event-manifest.js +5 -0
- package/dist/event-log.d.ts +14 -0
- package/dist/event-log.js +17 -0
- package/dist/event-manifest.d.ts +11372 -0
- package/dist/event-manifest.js +45 -0
- package/dist/event.d.ts +142 -0
- package/dist/event.js +110 -0
- package/dist/file-diff.d.ts +21 -0
- package/dist/file-diff.js +18 -0
- package/dist/filesystem-v1.d.ts +1 -0
- package/dist/filesystem-v1.js +1 -0
- package/dist/filesystem.d.ts +118 -0
- package/dist/filesystem.js +35 -0
- package/dist/form.d.ts +1259 -0
- package/dist/form.js +120 -0
- package/dist/ide-event.d.ts +76 -0
- package/dist/ide-event.js +10 -0
- package/dist/identifier.d.ts +3 -0
- package/dist/identifier.js +24 -0
- package/dist/index.d.ts +39 -0
- package/dist/index.js +39 -0
- package/dist/installation-event.d.ts +149 -0
- package/dist/installation-event.js +16 -0
- package/dist/instruction-entry.d.ts +23 -0
- package/dist/instruction-entry.js +22 -0
- package/dist/instruction.d.ts +13 -0
- package/dist/instruction.js +8 -0
- package/dist/integration-id.d.ts +5 -0
- package/dist/integration-id.js +3 -0
- package/dist/integration.d.ts +1675 -0
- package/dist/integration.js +87 -0
- package/dist/legacy-event.d.ts +1 -0
- package/dist/legacy-event.js +1 -0
- package/dist/llm.d.ts +4 -0
- package/dist/llm.js +3 -0
- package/dist/location.d.ts +37 -0
- package/dist/location.js +22 -0
- package/dist/lsp-event.d.ts +67 -0
- package/dist/lsp-event.js +4 -0
- package/dist/mcp-event.d.ts +222 -0
- package/dist/mcp-event.js +24 -0
- package/dist/mcp.d.ts +138 -0
- package/dist/mcp.js +111 -0
- package/dist/model.d.ts +186 -0
- package/dist/model.js +104 -0
- package/dist/models-dev.d.ts +69 -0
- package/dist/models-dev.js +7 -0
- package/dist/money.d.ts +10 -0
- package/dist/money.js +5 -0
- package/dist/permission-saved.d.ts +18 -0
- package/dist/permission-saved.js +12 -0
- package/dist/permission-v1.d.ts +1 -0
- package/dist/permission-v1.js +1 -0
- package/dist/permission.d.ts +306 -0
- package/dist/permission.js +45 -0
- package/dist/plugin.d.ts +150 -0
- package/dist/plugin.js +16 -0
- package/dist/project-id.d.ts +5 -0
- package/dist/project-id.js +3 -0
- package/dist/project.d.ts +241 -0
- package/dist/project.js +37 -0
- package/dist/prompt-input.d.ts +143 -0
- package/dist/prompt-input.js +25 -0
- package/dist/prompt.d.ts +297 -0
- package/dist/prompt.js +61 -0
- package/dist/provider.d.ts +60 -0
- package/dist/provider.js +42 -0
- package/dist/pty-ticket.d.ts +8 -0
- package/dist/pty-ticket.js +7 -0
- package/dist/pty.d.ts +462 -0
- package/dist/pty.js +43 -0
- package/dist/question-v1.d.ts +1 -0
- package/dist/question-v1.js +1 -0
- package/dist/question.d.ts +15 -0
- package/dist/question.js +15 -0
- package/dist/reference.d.ts +120 -0
- package/dist/reference.js +30 -0
- package/dist/schema.d.ts +10 -0
- package/dist/schema.js +14 -0
- package/dist/server-event.d.ts +132 -0
- package/dist/server-event.js +5 -0
- package/dist/session-compaction-event.d.ts +87 -0
- package/dist/session-compaction-event.js +10 -0
- package/dist/session-error.d.ts +9 -0
- package/dist/session-error.js +8 -0
- package/dist/session-event.d.ts +17994 -0
- package/dist/session-event.js +499 -0
- package/dist/session-fork.d.ts +26 -0
- package/dist/session-fork.js +11 -0
- package/dist/session-id.d.ts +6 -0
- package/dist/session-id.js +10 -0
- package/dist/session-inbox.d.ts +748 -0
- package/dist/session-inbox.js +47 -0
- package/dist/session-message.d.ts +1512 -0
- package/dist/session-message.js +209 -0
- package/dist/session-revert.d.ts +480 -0
- package/dist/session-revert.js +63 -0
- package/dist/session-status-event.d.ts +299 -0
- package/dist/session-status-event.js +43 -0
- package/dist/session-transfer.d.ts +744 -0
- package/dist/session-transfer.js +8 -0
- package/dist/session-v1.d.ts +1 -0
- package/dist/session-v1.js +1 -0
- package/dist/session.d.ts +218 -0
- package/dist/session.js +45 -0
- package/dist/shell.d.ts +381 -0
- package/dist/shell.js +58 -0
- package/dist/skill.d.ts +133 -0
- package/dist/skill.js +48 -0
- package/dist/snapshot.d.ts +4 -0
- package/dist/snapshot.js +3 -0
- package/dist/token-usage.d.ts +13 -0
- package/dist/token-usage.js +11 -0
- package/dist/tool.d.ts +74 -0
- package/dist/tool.js +22 -0
- package/dist/tui-event.d.ts +307 -0
- package/dist/tui-event.js +53 -0
- package/dist/v1/filesystem.d.ts +78 -0
- package/dist/v1/filesystem.js +8 -0
- package/dist/v1/legacy-event.d.ts +108 -0
- package/dist/v1/legacy-event.js +15 -0
- package/dist/v1/permission.d.ts +316 -0
- package/dist/v1/permission.js +41 -0
- package/dist/v1/question.d.ts +444 -0
- package/dist/v1/question.js +57 -0
- package/dist/v1/session.d.ts +7657 -0
- package/dist/v1/session.js +535 -0
- package/dist/vcs-event.d.ts +76 -0
- package/dist/vcs-event.js +11 -0
- package/dist/vcs.d.ts +26 -0
- package/dist/vcs.js +17 -0
- package/dist/websearch.d.ts +108 -0
- package/dist/websearch.js +31 -0
- package/dist/workspace-event.d.ts +247 -0
- package/dist/workspace-event.js +25 -0
- package/dist/workspace-id.d.ts +6 -0
- package/dist/workspace-id.js +16 -0
- package/dist/workspace.d.ts +9 -0
- package/dist/workspace.js +5 -0
- package/dist/worktree-event.d.ts +153 -0
- package/dist/worktree-event.js +18 -0
- package/dist/worktree.d.ts +255 -0
- package/dist/worktree.js +61 -0
- package/package.json +42 -0
|
@@ -0,0 +1,87 @@
|
|
|
1
|
+
export * as Integration from "./integration.js";
|
|
2
|
+
import { Schema } from "effect";
|
|
3
|
+
import { optional } from "./schema.js";
|
|
4
|
+
import { ephemeral, inventory } from "./event.js";
|
|
5
|
+
import { Connection } from "./connection.js";
|
|
6
|
+
import { ascending } from "./identifier.js";
|
|
7
|
+
import { statics } from "./schema.js";
|
|
8
|
+
import { IntegrationID, IntegrationMethodID } from "./integration-id.js";
|
|
9
|
+
import { Form } from "./form.js";
|
|
10
|
+
export const ID = IntegrationID;
|
|
11
|
+
export const MethodID = IntegrationMethodID;
|
|
12
|
+
export const OAuthMethod = Schema.Struct({
|
|
13
|
+
id: MethodID,
|
|
14
|
+
type: Schema.Literal("oauth"),
|
|
15
|
+
label: Schema.String,
|
|
16
|
+
form: optional(Form.Fields),
|
|
17
|
+
}).annotate({ identifier: "Integration.OAuthMethod" });
|
|
18
|
+
export const CommandMethod = Schema.Struct({
|
|
19
|
+
id: MethodID,
|
|
20
|
+
type: Schema.Literal("command"),
|
|
21
|
+
label: Schema.String,
|
|
22
|
+
command: Schema.Array(Schema.String),
|
|
23
|
+
}).annotate({ identifier: "Integration.CommandMethod" });
|
|
24
|
+
export const KeyMethod = Schema.Struct({
|
|
25
|
+
type: Schema.Literal("key"),
|
|
26
|
+
label: optional(Schema.String),
|
|
27
|
+
form: optional(Form.Fields),
|
|
28
|
+
}).annotate({ identifier: "Integration.KeyMethod" });
|
|
29
|
+
export const EnvMethod = Schema.Struct({
|
|
30
|
+
type: Schema.Literal("env"),
|
|
31
|
+
names: Schema.Array(Schema.String),
|
|
32
|
+
}).annotate({ identifier: "Integration.EnvMethod" });
|
|
33
|
+
export const Method = Schema.Union([OAuthMethod, CommandMethod, KeyMethod, EnvMethod])
|
|
34
|
+
.pipe(Schema.toTaggedUnion("type"))
|
|
35
|
+
.annotate({ identifier: "Integration.Method" });
|
|
36
|
+
const Updated = ephemeral({
|
|
37
|
+
type: "integration.updated",
|
|
38
|
+
schema: {},
|
|
39
|
+
});
|
|
40
|
+
const ConnectionUpdated = ephemeral({
|
|
41
|
+
type: "integration.connection.updated",
|
|
42
|
+
schema: { integrationID: ID },
|
|
43
|
+
});
|
|
44
|
+
export const Event = { Updated, ConnectionUpdated, Definitions: inventory(Updated, ConnectionUpdated) };
|
|
45
|
+
export const Ref = Schema.Struct({
|
|
46
|
+
id: ID,
|
|
47
|
+
name: Schema.String,
|
|
48
|
+
}).annotate({ identifier: "Integration.Ref" });
|
|
49
|
+
export const Info = Schema.Struct({
|
|
50
|
+
id: ID,
|
|
51
|
+
name: Schema.String,
|
|
52
|
+
methods: Schema.Array(Method),
|
|
53
|
+
connections: Schema.Array(Connection.Info),
|
|
54
|
+
}).annotate({ identifier: "Integration.Info" });
|
|
55
|
+
export const AttemptID = Schema.String.pipe(Schema.brand("Integration.AttemptID"), statics((schema) => ({ create: () => schema.make("con_" + ascending()) })));
|
|
56
|
+
const AttemptTime = Schema.Struct({
|
|
57
|
+
created: Schema.Number,
|
|
58
|
+
expires: Schema.Number,
|
|
59
|
+
});
|
|
60
|
+
export class Attempt extends Schema.Class("Integration.Attempt")({
|
|
61
|
+
attemptID: AttemptID,
|
|
62
|
+
url: Schema.String,
|
|
63
|
+
instructions: Schema.String,
|
|
64
|
+
mode: Schema.Literals(["auto", "code"]),
|
|
65
|
+
time: AttemptTime,
|
|
66
|
+
}) {
|
|
67
|
+
}
|
|
68
|
+
export const AttemptStatus = Schema.Union([
|
|
69
|
+
Schema.Struct({ status: Schema.Literal("pending"), time: AttemptTime }),
|
|
70
|
+
Schema.Struct({ status: Schema.Literal("complete"), time: AttemptTime }),
|
|
71
|
+
Schema.Struct({ status: Schema.Literal("failed"), message: Schema.String, time: AttemptTime }),
|
|
72
|
+
Schema.Struct({ status: Schema.Literal("expired"), time: AttemptTime }),
|
|
73
|
+
])
|
|
74
|
+
.pipe(Schema.toTaggedUnion("status"))
|
|
75
|
+
.annotate({ identifier: "Integration.AttemptStatus" });
|
|
76
|
+
export const CommandAttempt = Schema.Struct({
|
|
77
|
+
attemptID: AttemptID,
|
|
78
|
+
time: AttemptTime,
|
|
79
|
+
}).annotate({ identifier: "Integration.CommandAttempt" });
|
|
80
|
+
export const CommandAttemptStatus = Schema.Union([
|
|
81
|
+
Schema.Struct({ status: Schema.Literal("pending"), message: optional(Schema.String), time: AttemptTime }),
|
|
82
|
+
Schema.Struct({ status: Schema.Literal("complete"), time: AttemptTime }),
|
|
83
|
+
Schema.Struct({ status: Schema.Literal("failed"), message: Schema.String, time: AttemptTime }),
|
|
84
|
+
Schema.Struct({ status: Schema.Literal("expired"), time: AttemptTime }),
|
|
85
|
+
])
|
|
86
|
+
.pipe(Schema.toTaggedUnion("status"))
|
|
87
|
+
.annotate({ identifier: "Integration.CommandAttemptStatus" });
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from "./v1/legacy-event.js";
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from "./v1/legacy-event.js";
|
package/dist/llm.d.ts
ADDED
package/dist/llm.js
ADDED
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
export * as Location from "./location.js";
|
|
2
|
+
import { Schema } from "effect";
|
|
3
|
+
export interface Ref extends Schema.Schema.Type<typeof Ref> {
|
|
4
|
+
}
|
|
5
|
+
export declare const Ref: Schema.Struct<{
|
|
6
|
+
readonly directory: Schema.brand<Schema.String, "AbsolutePath">;
|
|
7
|
+
readonly workspaceID: Schema.decodeTo<Schema.optional<Schema.toType<Schema.brand<Schema.String, "Workspace.ID"> & {
|
|
8
|
+
ascending: (id?: string) => string & import("effect/Brand").Brand<"Workspace.ID">;
|
|
9
|
+
create: () => string & import("effect/Brand").Brand<"Workspace.ID">;
|
|
10
|
+
}>>, Schema.optionalKey<Schema.brand<Schema.String, "Workspace.ID"> & {
|
|
11
|
+
ascending: (id?: string) => string & import("effect/Brand").Brand<"Workspace.ID">;
|
|
12
|
+
create: () => string & import("effect/Brand").Brand<"Workspace.ID">;
|
|
13
|
+
}>, never, never>;
|
|
14
|
+
}>;
|
|
15
|
+
declare const Info_base: Schema.Class<Info, Schema.Struct<{
|
|
16
|
+
readonly directory: Schema.brand<Schema.String, "AbsolutePath">;
|
|
17
|
+
readonly workspaceID: Schema.decodeTo<Schema.optional<Schema.toType<Schema.brand<Schema.String, "Workspace.ID"> & {
|
|
18
|
+
ascending: (id?: string) => string & import("effect/Brand").Brand<"Workspace.ID">;
|
|
19
|
+
create: () => string & import("effect/Brand").Brand<"Workspace.ID">;
|
|
20
|
+
}>>, Schema.optionalKey<Schema.brand<Schema.String, "Workspace.ID"> & {
|
|
21
|
+
ascending: (id?: string) => string & import("effect/Brand").Brand<"Workspace.ID">;
|
|
22
|
+
create: () => string & import("effect/Brand").Brand<"Workspace.ID">;
|
|
23
|
+
}>, never, never>;
|
|
24
|
+
readonly project: Schema.Struct<{
|
|
25
|
+
readonly id: Schema.brand<Schema.String, "Project.ID"> & {
|
|
26
|
+
global: string & import("effect/Brand").Brand<"Project.ID">;
|
|
27
|
+
};
|
|
28
|
+
readonly directory: Schema.brand<Schema.String, "AbsolutePath">;
|
|
29
|
+
readonly canonical: Schema.brand<Schema.String, "AbsolutePath">;
|
|
30
|
+
}>;
|
|
31
|
+
}>, {}>;
|
|
32
|
+
export declare class Info extends Info_base {
|
|
33
|
+
}
|
|
34
|
+
export declare function response<S extends Schema.Top>(data: S): Schema.Struct<{
|
|
35
|
+
readonly location: typeof Info;
|
|
36
|
+
readonly data: S;
|
|
37
|
+
}>;
|
package/dist/location.js
ADDED
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
export * as Location from "./location.js";
|
|
2
|
+
import { Schema } from "effect";
|
|
3
|
+
import { AbsolutePath, optional } from "./schema.js";
|
|
4
|
+
import { ProjectID } from "./project-id.js";
|
|
5
|
+
import { WorkspaceID } from "./workspace-id.js";
|
|
6
|
+
export const Ref = Schema.Struct({
|
|
7
|
+
directory: AbsolutePath,
|
|
8
|
+
workspaceID: optional(WorkspaceID),
|
|
9
|
+
}).annotate({ identifier: "Location.Ref" });
|
|
10
|
+
export class Info extends Schema.Class("Location.Info")({
|
|
11
|
+
directory: AbsolutePath,
|
|
12
|
+
workspaceID: optional(WorkspaceID),
|
|
13
|
+
project: Schema.Struct({
|
|
14
|
+
id: ProjectID,
|
|
15
|
+
directory: AbsolutePath,
|
|
16
|
+
canonical: AbsolutePath,
|
|
17
|
+
}),
|
|
18
|
+
}) {
|
|
19
|
+
}
|
|
20
|
+
export function response(data) {
|
|
21
|
+
return Schema.Struct({ location: Info, data });
|
|
22
|
+
}
|
|
@@ -0,0 +1,67 @@
|
|
|
1
|
+
export * as LspEvent from "./lsp-event.js";
|
|
2
|
+
export declare const Updated: import("effect/Schema").Struct<{
|
|
3
|
+
readonly id: import("effect/Schema").brand<import("effect/Schema").String, "Event.ID"> & {
|
|
4
|
+
create: () => string & import("effect/Brand").Brand<"Event.ID">;
|
|
5
|
+
};
|
|
6
|
+
readonly created: import("effect/Schema").Finite;
|
|
7
|
+
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>;
|
|
8
|
+
readonly type: import("effect/Schema").Literal<"lsp.updated">;
|
|
9
|
+
readonly location: import("effect/Schema").decodeTo<import("effect/Schema").optional<import("effect/Schema").toType<import("effect/Schema").Struct<{
|
|
10
|
+
readonly directory: import("effect/Schema").brand<import("effect/Schema").String, "AbsolutePath">;
|
|
11
|
+
readonly workspaceID: import("effect/Schema").decodeTo<import("effect/Schema").optional<import("effect/Schema").toType<import("effect/Schema").brand<import("effect/Schema").String, "Workspace.ID"> & {
|
|
12
|
+
ascending: (id?: string) => string & import("effect/Brand").Brand<"Workspace.ID">;
|
|
13
|
+
create: () => string & import("effect/Brand").Brand<"Workspace.ID">;
|
|
14
|
+
}>>, import("effect/Schema").optionalKey<import("effect/Schema").brand<import("effect/Schema").String, "Workspace.ID"> & {
|
|
15
|
+
ascending: (id?: string) => string & import("effect/Brand").Brand<"Workspace.ID">;
|
|
16
|
+
create: () => string & import("effect/Brand").Brand<"Workspace.ID">;
|
|
17
|
+
}>, never, never>;
|
|
18
|
+
}>>>, import("effect/Schema").optionalKey<import("effect/Schema").Struct<{
|
|
19
|
+
readonly directory: import("effect/Schema").brand<import("effect/Schema").String, "AbsolutePath">;
|
|
20
|
+
readonly workspaceID: import("effect/Schema").decodeTo<import("effect/Schema").optional<import("effect/Schema").toType<import("effect/Schema").brand<import("effect/Schema").String, "Workspace.ID"> & {
|
|
21
|
+
ascending: (id?: string) => string & import("effect/Brand").Brand<"Workspace.ID">;
|
|
22
|
+
create: () => string & import("effect/Brand").Brand<"Workspace.ID">;
|
|
23
|
+
}>>, import("effect/Schema").optionalKey<import("effect/Schema").brand<import("effect/Schema").String, "Workspace.ID"> & {
|
|
24
|
+
ascending: (id?: string) => string & import("effect/Brand").Brand<"Workspace.ID">;
|
|
25
|
+
create: () => string & import("effect/Brand").Brand<"Workspace.ID">;
|
|
26
|
+
}>, never, never>;
|
|
27
|
+
}>>, never, never>;
|
|
28
|
+
readonly data: import("effect/Schema").Struct<{}>;
|
|
29
|
+
}> & {
|
|
30
|
+
type: "lsp.updated";
|
|
31
|
+
durability: "ephemeral";
|
|
32
|
+
durable: undefined;
|
|
33
|
+
data: import("effect/Schema").Struct<{}>;
|
|
34
|
+
};
|
|
35
|
+
export declare const Definitions: readonly [import("effect/Schema").Struct<{
|
|
36
|
+
readonly id: import("effect/Schema").brand<import("effect/Schema").String, "Event.ID"> & {
|
|
37
|
+
create: () => string & import("effect/Brand").Brand<"Event.ID">;
|
|
38
|
+
};
|
|
39
|
+
readonly created: import("effect/Schema").Finite;
|
|
40
|
+
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>;
|
|
41
|
+
readonly type: import("effect/Schema").Literal<"lsp.updated">;
|
|
42
|
+
readonly location: import("effect/Schema").decodeTo<import("effect/Schema").optional<import("effect/Schema").toType<import("effect/Schema").Struct<{
|
|
43
|
+
readonly directory: import("effect/Schema").brand<import("effect/Schema").String, "AbsolutePath">;
|
|
44
|
+
readonly workspaceID: import("effect/Schema").decodeTo<import("effect/Schema").optional<import("effect/Schema").toType<import("effect/Schema").brand<import("effect/Schema").String, "Workspace.ID"> & {
|
|
45
|
+
ascending: (id?: string) => string & import("effect/Brand").Brand<"Workspace.ID">;
|
|
46
|
+
create: () => string & import("effect/Brand").Brand<"Workspace.ID">;
|
|
47
|
+
}>>, import("effect/Schema").optionalKey<import("effect/Schema").brand<import("effect/Schema").String, "Workspace.ID"> & {
|
|
48
|
+
ascending: (id?: string) => string & import("effect/Brand").Brand<"Workspace.ID">;
|
|
49
|
+
create: () => string & import("effect/Brand").Brand<"Workspace.ID">;
|
|
50
|
+
}>, never, never>;
|
|
51
|
+
}>>>, import("effect/Schema").optionalKey<import("effect/Schema").Struct<{
|
|
52
|
+
readonly directory: import("effect/Schema").brand<import("effect/Schema").String, "AbsolutePath">;
|
|
53
|
+
readonly workspaceID: import("effect/Schema").decodeTo<import("effect/Schema").optional<import("effect/Schema").toType<import("effect/Schema").brand<import("effect/Schema").String, "Workspace.ID"> & {
|
|
54
|
+
ascending: (id?: string) => string & import("effect/Brand").Brand<"Workspace.ID">;
|
|
55
|
+
create: () => string & import("effect/Brand").Brand<"Workspace.ID">;
|
|
56
|
+
}>>, import("effect/Schema").optionalKey<import("effect/Schema").brand<import("effect/Schema").String, "Workspace.ID"> & {
|
|
57
|
+
ascending: (id?: string) => string & import("effect/Brand").Brand<"Workspace.ID">;
|
|
58
|
+
create: () => string & import("effect/Brand").Brand<"Workspace.ID">;
|
|
59
|
+
}>, never, never>;
|
|
60
|
+
}>>, never, never>;
|
|
61
|
+
readonly data: import("effect/Schema").Struct<{}>;
|
|
62
|
+
}> & {
|
|
63
|
+
type: "lsp.updated";
|
|
64
|
+
durability: "ephemeral";
|
|
65
|
+
durable: undefined;
|
|
66
|
+
data: import("effect/Schema").Struct<{}>;
|
|
67
|
+
}];
|
|
@@ -0,0 +1,222 @@
|
|
|
1
|
+
export * as McpEvent from "./mcp-event.js";
|
|
2
|
+
import { Schema } from "effect";
|
|
3
|
+
export declare const ToolsChanged: Schema.Struct<{
|
|
4
|
+
readonly id: Schema.brand<Schema.String, "Event.ID"> & {
|
|
5
|
+
create: () => string & import("effect/Brand").Brand<"Event.ID">;
|
|
6
|
+
};
|
|
7
|
+
readonly created: Schema.Finite;
|
|
8
|
+
readonly metadata: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.String, Schema.Unknown>>>, Schema.optionalKey<Schema.$Record<Schema.String, Schema.Unknown>>, never, never>;
|
|
9
|
+
readonly type: Schema.Literal<"mcp.tools.changed">;
|
|
10
|
+
readonly location: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Struct<{
|
|
11
|
+
readonly directory: Schema.brand<Schema.String, "AbsolutePath">;
|
|
12
|
+
readonly workspaceID: Schema.decodeTo<Schema.optional<Schema.toType<Schema.brand<Schema.String, "Workspace.ID"> & {
|
|
13
|
+
ascending: (id?: string) => string & import("effect/Brand").Brand<"Workspace.ID">;
|
|
14
|
+
create: () => string & import("effect/Brand").Brand<"Workspace.ID">;
|
|
15
|
+
}>>, Schema.optionalKey<Schema.brand<Schema.String, "Workspace.ID"> & {
|
|
16
|
+
ascending: (id?: string) => string & import("effect/Brand").Brand<"Workspace.ID">;
|
|
17
|
+
create: () => string & import("effect/Brand").Brand<"Workspace.ID">;
|
|
18
|
+
}>, never, never>;
|
|
19
|
+
}>>>, Schema.optionalKey<Schema.Struct<{
|
|
20
|
+
readonly directory: Schema.brand<Schema.String, "AbsolutePath">;
|
|
21
|
+
readonly workspaceID: Schema.decodeTo<Schema.optional<Schema.toType<Schema.brand<Schema.String, "Workspace.ID"> & {
|
|
22
|
+
ascending: (id?: string) => string & import("effect/Brand").Brand<"Workspace.ID">;
|
|
23
|
+
create: () => string & import("effect/Brand").Brand<"Workspace.ID">;
|
|
24
|
+
}>>, Schema.optionalKey<Schema.brand<Schema.String, "Workspace.ID"> & {
|
|
25
|
+
ascending: (id?: string) => string & import("effect/Brand").Brand<"Workspace.ID">;
|
|
26
|
+
create: () => string & import("effect/Brand").Brand<"Workspace.ID">;
|
|
27
|
+
}>, never, never>;
|
|
28
|
+
}>>, never, never>;
|
|
29
|
+
readonly data: Schema.Struct<{
|
|
30
|
+
readonly server: Schema.String;
|
|
31
|
+
}>;
|
|
32
|
+
}> & {
|
|
33
|
+
type: "mcp.tools.changed";
|
|
34
|
+
durability: "ephemeral";
|
|
35
|
+
durable: undefined;
|
|
36
|
+
data: Schema.Struct<{
|
|
37
|
+
readonly server: Schema.String;
|
|
38
|
+
}>;
|
|
39
|
+
};
|
|
40
|
+
export declare const ResourcesChanged: Schema.Struct<{
|
|
41
|
+
readonly id: Schema.brand<Schema.String, "Event.ID"> & {
|
|
42
|
+
create: () => string & import("effect/Brand").Brand<"Event.ID">;
|
|
43
|
+
};
|
|
44
|
+
readonly created: Schema.Finite;
|
|
45
|
+
readonly metadata: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.String, Schema.Unknown>>>, Schema.optionalKey<Schema.$Record<Schema.String, Schema.Unknown>>, never, never>;
|
|
46
|
+
readonly type: Schema.Literal<"mcp.resources.changed">;
|
|
47
|
+
readonly location: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Struct<{
|
|
48
|
+
readonly directory: Schema.brand<Schema.String, "AbsolutePath">;
|
|
49
|
+
readonly workspaceID: Schema.decodeTo<Schema.optional<Schema.toType<Schema.brand<Schema.String, "Workspace.ID"> & {
|
|
50
|
+
ascending: (id?: string) => string & import("effect/Brand").Brand<"Workspace.ID">;
|
|
51
|
+
create: () => string & import("effect/Brand").Brand<"Workspace.ID">;
|
|
52
|
+
}>>, Schema.optionalKey<Schema.brand<Schema.String, "Workspace.ID"> & {
|
|
53
|
+
ascending: (id?: string) => string & import("effect/Brand").Brand<"Workspace.ID">;
|
|
54
|
+
create: () => string & import("effect/Brand").Brand<"Workspace.ID">;
|
|
55
|
+
}>, never, never>;
|
|
56
|
+
}>>>, Schema.optionalKey<Schema.Struct<{
|
|
57
|
+
readonly directory: Schema.brand<Schema.String, "AbsolutePath">;
|
|
58
|
+
readonly workspaceID: Schema.decodeTo<Schema.optional<Schema.toType<Schema.brand<Schema.String, "Workspace.ID"> & {
|
|
59
|
+
ascending: (id?: string) => string & import("effect/Brand").Brand<"Workspace.ID">;
|
|
60
|
+
create: () => string & import("effect/Brand").Brand<"Workspace.ID">;
|
|
61
|
+
}>>, Schema.optionalKey<Schema.brand<Schema.String, "Workspace.ID"> & {
|
|
62
|
+
ascending: (id?: string) => string & import("effect/Brand").Brand<"Workspace.ID">;
|
|
63
|
+
create: () => string & import("effect/Brand").Brand<"Workspace.ID">;
|
|
64
|
+
}>, never, never>;
|
|
65
|
+
}>>, never, never>;
|
|
66
|
+
readonly data: Schema.Struct<{
|
|
67
|
+
readonly server: Schema.String;
|
|
68
|
+
}>;
|
|
69
|
+
}> & {
|
|
70
|
+
type: "mcp.resources.changed";
|
|
71
|
+
durability: "ephemeral";
|
|
72
|
+
durable: undefined;
|
|
73
|
+
data: Schema.Struct<{
|
|
74
|
+
readonly server: Schema.String;
|
|
75
|
+
}>;
|
|
76
|
+
};
|
|
77
|
+
export declare const StatusChanged: Schema.Struct<{
|
|
78
|
+
readonly id: Schema.brand<Schema.String, "Event.ID"> & {
|
|
79
|
+
create: () => string & import("effect/Brand").Brand<"Event.ID">;
|
|
80
|
+
};
|
|
81
|
+
readonly created: Schema.Finite;
|
|
82
|
+
readonly metadata: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.String, Schema.Unknown>>>, Schema.optionalKey<Schema.$Record<Schema.String, Schema.Unknown>>, never, never>;
|
|
83
|
+
readonly type: Schema.Literal<"mcp.status.changed">;
|
|
84
|
+
readonly location: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Struct<{
|
|
85
|
+
readonly directory: Schema.brand<Schema.String, "AbsolutePath">;
|
|
86
|
+
readonly workspaceID: Schema.decodeTo<Schema.optional<Schema.toType<Schema.brand<Schema.String, "Workspace.ID"> & {
|
|
87
|
+
ascending: (id?: string) => string & import("effect/Brand").Brand<"Workspace.ID">;
|
|
88
|
+
create: () => string & import("effect/Brand").Brand<"Workspace.ID">;
|
|
89
|
+
}>>, Schema.optionalKey<Schema.brand<Schema.String, "Workspace.ID"> & {
|
|
90
|
+
ascending: (id?: string) => string & import("effect/Brand").Brand<"Workspace.ID">;
|
|
91
|
+
create: () => string & import("effect/Brand").Brand<"Workspace.ID">;
|
|
92
|
+
}>, never, never>;
|
|
93
|
+
}>>>, Schema.optionalKey<Schema.Struct<{
|
|
94
|
+
readonly directory: Schema.brand<Schema.String, "AbsolutePath">;
|
|
95
|
+
readonly workspaceID: Schema.decodeTo<Schema.optional<Schema.toType<Schema.brand<Schema.String, "Workspace.ID"> & {
|
|
96
|
+
ascending: (id?: string) => string & import("effect/Brand").Brand<"Workspace.ID">;
|
|
97
|
+
create: () => string & import("effect/Brand").Brand<"Workspace.ID">;
|
|
98
|
+
}>>, Schema.optionalKey<Schema.brand<Schema.String, "Workspace.ID"> & {
|
|
99
|
+
ascending: (id?: string) => string & import("effect/Brand").Brand<"Workspace.ID">;
|
|
100
|
+
create: () => string & import("effect/Brand").Brand<"Workspace.ID">;
|
|
101
|
+
}>, never, never>;
|
|
102
|
+
}>>, never, never>;
|
|
103
|
+
readonly data: Schema.Struct<{
|
|
104
|
+
readonly server: Schema.String;
|
|
105
|
+
}>;
|
|
106
|
+
}> & {
|
|
107
|
+
type: "mcp.status.changed";
|
|
108
|
+
durability: "ephemeral";
|
|
109
|
+
durable: undefined;
|
|
110
|
+
data: Schema.Struct<{
|
|
111
|
+
readonly server: Schema.String;
|
|
112
|
+
}>;
|
|
113
|
+
};
|
|
114
|
+
export declare const Definitions: readonly [Schema.Struct<{
|
|
115
|
+
readonly id: Schema.brand<Schema.String, "Event.ID"> & {
|
|
116
|
+
create: () => string & import("effect/Brand").Brand<"Event.ID">;
|
|
117
|
+
};
|
|
118
|
+
readonly created: Schema.Finite;
|
|
119
|
+
readonly metadata: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.String, Schema.Unknown>>>, Schema.optionalKey<Schema.$Record<Schema.String, Schema.Unknown>>, never, never>;
|
|
120
|
+
readonly type: Schema.Literal<"mcp.tools.changed">;
|
|
121
|
+
readonly location: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Struct<{
|
|
122
|
+
readonly directory: Schema.brand<Schema.String, "AbsolutePath">;
|
|
123
|
+
readonly workspaceID: Schema.decodeTo<Schema.optional<Schema.toType<Schema.brand<Schema.String, "Workspace.ID"> & {
|
|
124
|
+
ascending: (id?: string) => string & import("effect/Brand").Brand<"Workspace.ID">;
|
|
125
|
+
create: () => string & import("effect/Brand").Brand<"Workspace.ID">;
|
|
126
|
+
}>>, Schema.optionalKey<Schema.brand<Schema.String, "Workspace.ID"> & {
|
|
127
|
+
ascending: (id?: string) => string & import("effect/Brand").Brand<"Workspace.ID">;
|
|
128
|
+
create: () => string & import("effect/Brand").Brand<"Workspace.ID">;
|
|
129
|
+
}>, never, never>;
|
|
130
|
+
}>>>, Schema.optionalKey<Schema.Struct<{
|
|
131
|
+
readonly directory: Schema.brand<Schema.String, "AbsolutePath">;
|
|
132
|
+
readonly workspaceID: Schema.decodeTo<Schema.optional<Schema.toType<Schema.brand<Schema.String, "Workspace.ID"> & {
|
|
133
|
+
ascending: (id?: string) => string & import("effect/Brand").Brand<"Workspace.ID">;
|
|
134
|
+
create: () => string & import("effect/Brand").Brand<"Workspace.ID">;
|
|
135
|
+
}>>, Schema.optionalKey<Schema.brand<Schema.String, "Workspace.ID"> & {
|
|
136
|
+
ascending: (id?: string) => string & import("effect/Brand").Brand<"Workspace.ID">;
|
|
137
|
+
create: () => string & import("effect/Brand").Brand<"Workspace.ID">;
|
|
138
|
+
}>, never, never>;
|
|
139
|
+
}>>, never, never>;
|
|
140
|
+
readonly data: Schema.Struct<{
|
|
141
|
+
readonly server: Schema.String;
|
|
142
|
+
}>;
|
|
143
|
+
}> & {
|
|
144
|
+
type: "mcp.tools.changed";
|
|
145
|
+
durability: "ephemeral";
|
|
146
|
+
durable: undefined;
|
|
147
|
+
data: Schema.Struct<{
|
|
148
|
+
readonly server: Schema.String;
|
|
149
|
+
}>;
|
|
150
|
+
}, Schema.Struct<{
|
|
151
|
+
readonly id: Schema.brand<Schema.String, "Event.ID"> & {
|
|
152
|
+
create: () => string & import("effect/Brand").Brand<"Event.ID">;
|
|
153
|
+
};
|
|
154
|
+
readonly created: Schema.Finite;
|
|
155
|
+
readonly metadata: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.String, Schema.Unknown>>>, Schema.optionalKey<Schema.$Record<Schema.String, Schema.Unknown>>, never, never>;
|
|
156
|
+
readonly type: Schema.Literal<"mcp.resources.changed">;
|
|
157
|
+
readonly location: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Struct<{
|
|
158
|
+
readonly directory: Schema.brand<Schema.String, "AbsolutePath">;
|
|
159
|
+
readonly workspaceID: Schema.decodeTo<Schema.optional<Schema.toType<Schema.brand<Schema.String, "Workspace.ID"> & {
|
|
160
|
+
ascending: (id?: string) => string & import("effect/Brand").Brand<"Workspace.ID">;
|
|
161
|
+
create: () => string & import("effect/Brand").Brand<"Workspace.ID">;
|
|
162
|
+
}>>, Schema.optionalKey<Schema.brand<Schema.String, "Workspace.ID"> & {
|
|
163
|
+
ascending: (id?: string) => string & import("effect/Brand").Brand<"Workspace.ID">;
|
|
164
|
+
create: () => string & import("effect/Brand").Brand<"Workspace.ID">;
|
|
165
|
+
}>, never, never>;
|
|
166
|
+
}>>>, Schema.optionalKey<Schema.Struct<{
|
|
167
|
+
readonly directory: Schema.brand<Schema.String, "AbsolutePath">;
|
|
168
|
+
readonly workspaceID: Schema.decodeTo<Schema.optional<Schema.toType<Schema.brand<Schema.String, "Workspace.ID"> & {
|
|
169
|
+
ascending: (id?: string) => string & import("effect/Brand").Brand<"Workspace.ID">;
|
|
170
|
+
create: () => string & import("effect/Brand").Brand<"Workspace.ID">;
|
|
171
|
+
}>>, Schema.optionalKey<Schema.brand<Schema.String, "Workspace.ID"> & {
|
|
172
|
+
ascending: (id?: string) => string & import("effect/Brand").Brand<"Workspace.ID">;
|
|
173
|
+
create: () => string & import("effect/Brand").Brand<"Workspace.ID">;
|
|
174
|
+
}>, never, never>;
|
|
175
|
+
}>>, never, never>;
|
|
176
|
+
readonly data: Schema.Struct<{
|
|
177
|
+
readonly server: Schema.String;
|
|
178
|
+
}>;
|
|
179
|
+
}> & {
|
|
180
|
+
type: "mcp.resources.changed";
|
|
181
|
+
durability: "ephemeral";
|
|
182
|
+
durable: undefined;
|
|
183
|
+
data: Schema.Struct<{
|
|
184
|
+
readonly server: Schema.String;
|
|
185
|
+
}>;
|
|
186
|
+
}, Schema.Struct<{
|
|
187
|
+
readonly id: Schema.brand<Schema.String, "Event.ID"> & {
|
|
188
|
+
create: () => string & import("effect/Brand").Brand<"Event.ID">;
|
|
189
|
+
};
|
|
190
|
+
readonly created: Schema.Finite;
|
|
191
|
+
readonly metadata: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.String, Schema.Unknown>>>, Schema.optionalKey<Schema.$Record<Schema.String, Schema.Unknown>>, never, never>;
|
|
192
|
+
readonly type: Schema.Literal<"mcp.status.changed">;
|
|
193
|
+
readonly location: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Struct<{
|
|
194
|
+
readonly directory: Schema.brand<Schema.String, "AbsolutePath">;
|
|
195
|
+
readonly workspaceID: Schema.decodeTo<Schema.optional<Schema.toType<Schema.brand<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
|
+
}>>, Schema.optionalKey<Schema.brand<Schema.String, "Workspace.ID"> & {
|
|
199
|
+
ascending: (id?: string) => string & import("effect/Brand").Brand<"Workspace.ID">;
|
|
200
|
+
create: () => string & import("effect/Brand").Brand<"Workspace.ID">;
|
|
201
|
+
}>, never, never>;
|
|
202
|
+
}>>>, Schema.optionalKey<Schema.Struct<{
|
|
203
|
+
readonly directory: Schema.brand<Schema.String, "AbsolutePath">;
|
|
204
|
+
readonly workspaceID: Schema.decodeTo<Schema.optional<Schema.toType<Schema.brand<Schema.String, "Workspace.ID"> & {
|
|
205
|
+
ascending: (id?: string) => string & import("effect/Brand").Brand<"Workspace.ID">;
|
|
206
|
+
create: () => string & import("effect/Brand").Brand<"Workspace.ID">;
|
|
207
|
+
}>>, Schema.optionalKey<Schema.brand<Schema.String, "Workspace.ID"> & {
|
|
208
|
+
ascending: (id?: string) => string & import("effect/Brand").Brand<"Workspace.ID">;
|
|
209
|
+
create: () => string & import("effect/Brand").Brand<"Workspace.ID">;
|
|
210
|
+
}>, never, never>;
|
|
211
|
+
}>>, never, never>;
|
|
212
|
+
readonly data: Schema.Struct<{
|
|
213
|
+
readonly server: Schema.String;
|
|
214
|
+
}>;
|
|
215
|
+
}> & {
|
|
216
|
+
type: "mcp.status.changed";
|
|
217
|
+
durability: "ephemeral";
|
|
218
|
+
durable: undefined;
|
|
219
|
+
data: Schema.Struct<{
|
|
220
|
+
readonly server: Schema.String;
|
|
221
|
+
}>;
|
|
222
|
+
}];
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
export * as McpEvent from "./mcp-event.js";
|
|
2
|
+
import { Schema } from "effect";
|
|
3
|
+
import { Event } from "./event.js";
|
|
4
|
+
export const ToolsChanged = Event.ephemeral({
|
|
5
|
+
type: "mcp.tools.changed",
|
|
6
|
+
schema: {
|
|
7
|
+
server: Schema.String,
|
|
8
|
+
},
|
|
9
|
+
});
|
|
10
|
+
export const ResourcesChanged = Event.ephemeral({
|
|
11
|
+
type: "mcp.resources.changed",
|
|
12
|
+
schema: {
|
|
13
|
+
server: Schema.String,
|
|
14
|
+
},
|
|
15
|
+
});
|
|
16
|
+
// Emitted whenever a server's connection status settles (connected, failed, needs_auth, closed) so
|
|
17
|
+
// observers can refresh status without polling.
|
|
18
|
+
export const StatusChanged = Event.ephemeral({
|
|
19
|
+
type: "mcp.status.changed",
|
|
20
|
+
schema: {
|
|
21
|
+
server: Schema.String,
|
|
22
|
+
},
|
|
23
|
+
});
|
|
24
|
+
export const Definitions = Event.inventory(ToolsChanged, ResourcesChanged, StatusChanged);
|
package/dist/mcp.d.ts
ADDED
|
@@ -0,0 +1,138 @@
|
|
|
1
|
+
export * as Mcp from "./mcp.js";
|
|
2
|
+
import { Schema } from "effect";
|
|
3
|
+
declare const TimeoutConfig_base: Schema.Class<TimeoutConfig, Schema.Struct<{
|
|
4
|
+
readonly startup: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Int>>, Schema.optionalKey<Schema.Int>, never, never>;
|
|
5
|
+
readonly catalog: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Int>>, Schema.optionalKey<Schema.Int>, never, never>;
|
|
6
|
+
readonly execution: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Int>>, Schema.optionalKey<Schema.Int>, never, never>;
|
|
7
|
+
}>, {}>;
|
|
8
|
+
export declare class TimeoutConfig extends TimeoutConfig_base {
|
|
9
|
+
}
|
|
10
|
+
declare const LocalConfig_base: Schema.Class<LocalConfig, Schema.Struct<{
|
|
11
|
+
readonly type: Schema.Literal<"local">;
|
|
12
|
+
readonly command: Schema.$Array<Schema.String>;
|
|
13
|
+
readonly cwd: Schema.decodeTo<Schema.optional<Schema.toType<Schema.String>>, Schema.optionalKey<Schema.String>, never, never>;
|
|
14
|
+
readonly environment: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.String, Schema.String>>>, Schema.optionalKey<Schema.$Record<Schema.String, Schema.String>>, never, never>;
|
|
15
|
+
readonly disabled: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Boolean>>, Schema.optionalKey<Schema.Boolean>, never, never>;
|
|
16
|
+
readonly codemode: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Boolean>>, Schema.optionalKey<Schema.Boolean>, never, never>;
|
|
17
|
+
readonly timeout: Schema.decodeTo<Schema.optional<Schema.toType<typeof TimeoutConfig>>, Schema.optionalKey<typeof TimeoutConfig>, never, never>;
|
|
18
|
+
}>, {}>;
|
|
19
|
+
export declare class LocalConfig extends LocalConfig_base {
|
|
20
|
+
}
|
|
21
|
+
declare const OAuthConfig_base: Schema.Class<OAuthConfig, Schema.Struct<{
|
|
22
|
+
readonly client_id: Schema.decodeTo<Schema.optional<Schema.toType<Schema.String>>, Schema.optionalKey<Schema.String>, never, never>;
|
|
23
|
+
readonly client_secret: Schema.decodeTo<Schema.optional<Schema.toType<Schema.String>>, Schema.optionalKey<Schema.String>, never, never>;
|
|
24
|
+
readonly scope: Schema.decodeTo<Schema.optional<Schema.toType<Schema.String>>, Schema.optionalKey<Schema.String>, never, never>;
|
|
25
|
+
readonly callback_port: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Int>>, Schema.optionalKey<Schema.Int>, never, never>;
|
|
26
|
+
readonly redirect_uri: Schema.decodeTo<Schema.optional<Schema.toType<Schema.String>>, Schema.optionalKey<Schema.String>, never, never>;
|
|
27
|
+
}>, {}>;
|
|
28
|
+
export declare class OAuthConfig extends OAuthConfig_base {
|
|
29
|
+
}
|
|
30
|
+
declare const RemoteConfig_base: Schema.Class<RemoteConfig, Schema.Struct<{
|
|
31
|
+
readonly type: Schema.Literal<"remote">;
|
|
32
|
+
readonly url: Schema.String;
|
|
33
|
+
readonly headers: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.String, Schema.String>>>, Schema.optionalKey<Schema.$Record<Schema.String, Schema.String>>, never, never>;
|
|
34
|
+
readonly oauth: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Union<readonly [typeof OAuthConfig, Schema.Literal<false>]>>>, Schema.optionalKey<Schema.Union<readonly [typeof OAuthConfig, Schema.Literal<false>]>>, never, never>;
|
|
35
|
+
readonly disabled: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Boolean>>, Schema.optionalKey<Schema.Boolean>, never, never>;
|
|
36
|
+
readonly codemode: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Boolean>>, Schema.optionalKey<Schema.Boolean>, never, never>;
|
|
37
|
+
readonly timeout: Schema.decodeTo<Schema.optional<Schema.toType<typeof TimeoutConfig>>, Schema.optionalKey<typeof TimeoutConfig>, never, never>;
|
|
38
|
+
}>, {}>;
|
|
39
|
+
export declare class RemoteConfig extends RemoteConfig_base {
|
|
40
|
+
}
|
|
41
|
+
export declare const ServerConfig: Schema.toTaggedUnion<"type", readonly [typeof LocalConfig, typeof RemoteConfig]>;
|
|
42
|
+
export type ServerConfig = typeof ServerConfig.Type;
|
|
43
|
+
export type Status = typeof Status.Type;
|
|
44
|
+
export declare const Status: Schema.toTaggedUnion<"status", readonly [Schema.Struct<{
|
|
45
|
+
readonly status: Schema.Literal<"connected">;
|
|
46
|
+
}>, Schema.Struct<{
|
|
47
|
+
readonly status: Schema.Literal<"pending">;
|
|
48
|
+
}>, Schema.Struct<{
|
|
49
|
+
readonly status: Schema.Literal<"disabled">;
|
|
50
|
+
}>, Schema.Struct<{
|
|
51
|
+
readonly status: Schema.Literal<"failed">;
|
|
52
|
+
readonly error: Schema.String;
|
|
53
|
+
}>, Schema.Struct<{
|
|
54
|
+
readonly status: Schema.Literal<"needs_auth">;
|
|
55
|
+
}>]>;
|
|
56
|
+
export interface Server extends Schema.Schema.Type<typeof Server> {
|
|
57
|
+
}
|
|
58
|
+
export declare const Server: Schema.Struct<{
|
|
59
|
+
readonly name: Schema.String;
|
|
60
|
+
readonly status: Schema.toTaggedUnion<"status", readonly [Schema.Struct<{
|
|
61
|
+
readonly status: Schema.Literal<"connected">;
|
|
62
|
+
}>, Schema.Struct<{
|
|
63
|
+
readonly status: Schema.Literal<"pending">;
|
|
64
|
+
}>, Schema.Struct<{
|
|
65
|
+
readonly status: Schema.Literal<"disabled">;
|
|
66
|
+
}>, Schema.Struct<{
|
|
67
|
+
readonly status: Schema.Literal<"failed">;
|
|
68
|
+
readonly error: Schema.String;
|
|
69
|
+
}>, Schema.Struct<{
|
|
70
|
+
readonly status: Schema.Literal<"needs_auth">;
|
|
71
|
+
}>]>;
|
|
72
|
+
readonly integrationID: Schema.decodeTo<Schema.optional<Schema.toType<Schema.brand<Schema.String, "Integration.ID">>>, Schema.optionalKey<Schema.brand<Schema.String, "Integration.ID">>, never, never>;
|
|
73
|
+
}>;
|
|
74
|
+
export interface Resource extends Schema.Schema.Type<typeof Resource> {
|
|
75
|
+
}
|
|
76
|
+
export declare const Resource: Schema.Struct<{
|
|
77
|
+
readonly server: Schema.String;
|
|
78
|
+
readonly name: Schema.String;
|
|
79
|
+
readonly uri: Schema.String;
|
|
80
|
+
readonly description: Schema.decodeTo<Schema.optional<Schema.toType<Schema.String>>, Schema.optionalKey<Schema.String>, never, never>;
|
|
81
|
+
readonly mimeType: Schema.decodeTo<Schema.optional<Schema.toType<Schema.String>>, Schema.optionalKey<Schema.String>, never, never>;
|
|
82
|
+
}>;
|
|
83
|
+
export interface ResourceTemplate extends Schema.Schema.Type<typeof ResourceTemplate> {
|
|
84
|
+
}
|
|
85
|
+
export declare const ResourceTemplate: Schema.Struct<{
|
|
86
|
+
readonly server: Schema.String;
|
|
87
|
+
readonly name: Schema.String;
|
|
88
|
+
readonly uriTemplate: Schema.String;
|
|
89
|
+
readonly description: Schema.decodeTo<Schema.optional<Schema.toType<Schema.String>>, Schema.optionalKey<Schema.String>, never, never>;
|
|
90
|
+
readonly mimeType: Schema.decodeTo<Schema.optional<Schema.toType<Schema.String>>, Schema.optionalKey<Schema.String>, never, never>;
|
|
91
|
+
}>;
|
|
92
|
+
export interface ResourceCatalog extends Schema.Schema.Type<typeof ResourceCatalog> {
|
|
93
|
+
}
|
|
94
|
+
export declare const ResourceCatalog: Schema.Struct<{
|
|
95
|
+
readonly resources: Schema.$Array<Schema.Struct<{
|
|
96
|
+
readonly server: Schema.String;
|
|
97
|
+
readonly name: Schema.String;
|
|
98
|
+
readonly uri: Schema.String;
|
|
99
|
+
readonly description: Schema.decodeTo<Schema.optional<Schema.toType<Schema.String>>, Schema.optionalKey<Schema.String>, never, never>;
|
|
100
|
+
readonly mimeType: Schema.decodeTo<Schema.optional<Schema.toType<Schema.String>>, Schema.optionalKey<Schema.String>, never, never>;
|
|
101
|
+
}>>;
|
|
102
|
+
readonly templates: Schema.$Array<Schema.Struct<{
|
|
103
|
+
readonly server: Schema.String;
|
|
104
|
+
readonly name: Schema.String;
|
|
105
|
+
readonly uriTemplate: Schema.String;
|
|
106
|
+
readonly description: Schema.decodeTo<Schema.optional<Schema.toType<Schema.String>>, Schema.optionalKey<Schema.String>, never, never>;
|
|
107
|
+
readonly mimeType: Schema.decodeTo<Schema.optional<Schema.toType<Schema.String>>, Schema.optionalKey<Schema.String>, never, never>;
|
|
108
|
+
}>>;
|
|
109
|
+
}>;
|
|
110
|
+
export declare const ResourceContentPart: Schema.Union<readonly [Schema.Struct<{
|
|
111
|
+
readonly type: Schema.Literal<"text">;
|
|
112
|
+
readonly uri: Schema.String;
|
|
113
|
+
readonly text: Schema.String;
|
|
114
|
+
readonly mimeType: Schema.decodeTo<Schema.optional<Schema.toType<Schema.String>>, Schema.optionalKey<Schema.String>, never, never>;
|
|
115
|
+
}>, Schema.Struct<{
|
|
116
|
+
readonly type: Schema.Literal<"blob">;
|
|
117
|
+
readonly uri: Schema.String;
|
|
118
|
+
readonly blob: Schema.String;
|
|
119
|
+
readonly mimeType: Schema.decodeTo<Schema.optional<Schema.toType<Schema.String>>, Schema.optionalKey<Schema.String>, never, never>;
|
|
120
|
+
}>]>;
|
|
121
|
+
export type ResourceContentPart = typeof ResourceContentPart.Type;
|
|
122
|
+
export interface ResourceContent extends Schema.Schema.Type<typeof ResourceContent> {
|
|
123
|
+
}
|
|
124
|
+
export declare const ResourceContent: Schema.Struct<{
|
|
125
|
+
readonly server: Schema.String;
|
|
126
|
+
readonly uri: Schema.String;
|
|
127
|
+
readonly contents: Schema.$Array<Schema.Union<readonly [Schema.Struct<{
|
|
128
|
+
readonly type: Schema.Literal<"text">;
|
|
129
|
+
readonly uri: Schema.String;
|
|
130
|
+
readonly text: Schema.String;
|
|
131
|
+
readonly mimeType: Schema.decodeTo<Schema.optional<Schema.toType<Schema.String>>, Schema.optionalKey<Schema.String>, never, never>;
|
|
132
|
+
}>, Schema.Struct<{
|
|
133
|
+
readonly type: Schema.Literal<"blob">;
|
|
134
|
+
readonly uri: Schema.String;
|
|
135
|
+
readonly blob: Schema.String;
|
|
136
|
+
readonly mimeType: Schema.decodeTo<Schema.optional<Schema.toType<Schema.String>>, Schema.optionalKey<Schema.String>, never, never>;
|
|
137
|
+
}>]>>;
|
|
138
|
+
}>;
|