@moltzap/client 2026.802.0 → 2026.804.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.
- package/dist/bounded-map.d.ts +3 -3
- package/dist/bounded-map.js +3 -3
- package/dist/channel-base/index.d.ts +1 -7
- package/dist/channel-base/index.d.ts.map +1 -1
- package/dist/channel-base/index.js +0 -6
- package/dist/channel-base/index.js.map +1 -1
- package/dist/channel-core-test-support.d.ts +5 -27
- package/dist/channel-core-test-support.d.ts.map +1 -1
- package/dist/channel-core-test-support.js +2 -90
- package/dist/channel-core-test-support.js.map +1 -1
- package/dist/channel-core.d.ts +156 -248
- package/dist/channel-core.d.ts.map +1 -1
- package/dist/channel-core.js +195 -525
- package/dist/channel-core.js.map +1 -1
- package/dist/cli/commands/start.d.ts +1 -5
- package/dist/cli/commands/start.d.ts.map +1 -1
- package/dist/cli/commands/start.js +0 -3
- package/dist/cli/commands/start.js.map +1 -1
- package/dist/harness/client-runtime.d.ts +24 -0
- package/dist/harness/client-runtime.d.ts.map +1 -0
- package/dist/harness/client-runtime.js +107 -0
- package/dist/harness/client-runtime.js.map +1 -0
- package/dist/harness/index.d.ts +5 -0
- package/dist/harness/index.d.ts.map +1 -0
- package/dist/harness/index.js +5 -0
- package/dist/harness/index.js.map +1 -0
- package/dist/harness/runtime.d.ts +149 -0
- package/dist/harness/runtime.d.ts.map +1 -0
- package/dist/harness/runtime.js +68 -0
- package/dist/harness/runtime.js.map +1 -0
- package/dist/harness-client.d.ts +43 -0
- package/dist/harness-client.d.ts.map +1 -0
- package/dist/harness-client.js +21 -0
- package/dist/harness-client.js.map +1 -0
- package/dist/harness-mcp-server.d.ts.map +1 -1
- package/dist/harness-mcp-server.js +107 -17
- package/dist/harness-mcp-server.js.map +1 -1
- package/dist/harness-mcp-subscription.d.ts +21 -0
- package/dist/harness-mcp-subscription.d.ts.map +1 -0
- package/dist/harness-mcp-subscription.js +324 -0
- package/dist/harness-mcp-subscription.js.map +1 -0
- package/dist/harness-mcp-wire.d.ts +9 -2
- package/dist/harness-mcp-wire.d.ts.map +1 -1
- package/dist/harness-mcp-wire.js +41 -10
- package/dist/harness-mcp-wire.js.map +1 -1
- package/dist/index.d.ts +3 -5
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +3 -3
- package/dist/index.js.map +1 -1
- package/dist/local-daemon-rpc.d.ts +12 -195
- package/dist/local-daemon-rpc.d.ts.map +1 -1
- package/dist/local-daemon-rpc.js +1 -5
- package/dist/local-daemon-rpc.js.map +1 -1
- package/dist/moltzapd.d.ts +2 -1
- package/dist/moltzapd.d.ts.map +1 -1
- package/dist/moltzapd.js +19 -5
- package/dist/moltzapd.js.map +1 -1
- package/dist/notification/__tests__/subscribe-signatures.types-check.d.ts +14 -14
- package/dist/notification/__tests__/subscribe-signatures.types-check.d.ts.map +1 -1
- package/dist/notification/__tests__/subscribe-signatures.types-check.js +5 -5
- package/dist/notification/__tests__/subscribe-signatures.types-check.js.map +1 -1
- package/dist/service-local-daemon.d.ts +1 -1
- package/dist/service-local-daemon.d.ts.map +1 -1
- package/dist/service-local-daemon.js +2 -4
- package/dist/service-local-daemon.js.map +1 -1
- package/dist/service.d.ts +4 -25
- package/dist/service.d.ts.map +1 -1
- package/dist/service.js +7 -44
- package/dist/service.js.map +1 -1
- package/dist/test-utils/channel-service-fixture.d.ts +1 -3
- package/dist/test-utils/channel-service-fixture.d.ts.map +1 -1
- package/dist/test-utils/channel-service-fixture.js +2 -22
- package/dist/test-utils/channel-service-fixture.js.map +1 -1
- package/dist/test-utils/ids.d.ts +0 -13
- package/dist/test-utils/ids.d.ts.map +1 -1
- package/dist/test-utils/ids.js +1 -16
- package/dist/test-utils/ids.js.map +1 -1
- package/dist/test-utils/index.d.ts +1 -1
- package/dist/test-utils/index.d.ts.map +1 -1
- package/dist/test-utils/index.js +1 -1
- package/dist/test-utils/index.js.map +1 -1
- package/dist/tsconfig.tsbuildinfo +1 -1
- package/package.json +8 -4
- package/dist/app-client.d.ts +0 -5
- package/dist/app-client.d.ts.map +0 -1
- package/dist/app-client.js +0 -3
- package/dist/app-client.js.map +0 -1
- package/dist/channel-base/lease-guard.d.ts +0 -31
- package/dist/channel-base/lease-guard.d.ts.map +0 -1
- package/dist/channel-base/lease-guard.js +0 -44
- package/dist/channel-base/lease-guard.js.map +0 -1
- package/dist/channel-base/lease-store.d.ts +0 -48
- package/dist/channel-base/lease-store.d.ts.map +0 -1
- package/dist/channel-base/lease-store.js +0 -77
- package/dist/channel-base/lease-store.js.map +0 -1
- package/dist/channel-base/lease.d.ts +0 -96
- package/dist/channel-base/lease.d.ts.map +0 -1
- package/dist/channel-base/lease.js +0 -106
- package/dist/channel-base/lease.js.map +0 -1
package/dist/harness-mcp-wire.js
CHANGED
|
@@ -2,15 +2,20 @@ import { createMcpHandler, fromJsonSchema, McpServer, } from "@modelcontextproto
|
|
|
2
2
|
import { Headers } from "@effect/platform";
|
|
3
3
|
import { Rpc } from "@effect/rpc";
|
|
4
4
|
import { Effect, JSONSchema } from "effect";
|
|
5
|
+
import { decodeHarnessReplyRoute, HARNESS_EVENTS_EXTENSION, HARNESS_REPLY_TOOL, harnessReplyInputJsonSchema, harnessReplyResultJsonSchema, } from "./harness/index.js";
|
|
6
|
+
import { makeHarnessMcpSubscriptionHandler, } from "./harness-mcp-subscription.js";
|
|
5
7
|
import { statusCommandRpc, } from "./local-daemon-rpc.js";
|
|
6
8
|
const STATUS_TOOL_NAME = "status";
|
|
7
9
|
const statusInputSchema = fromJsonSchema(
|
|
8
10
|
/* Safe because Effect and MCP expose the same JSON Schema wire shape with different array mutability declarations. */ JSONSchema.make(statusCommandRpc.payloadSchema, { target: "jsonSchema2020-12" }));
|
|
9
11
|
const statusOutputSchema = fromJsonSchema(
|
|
10
12
|
/* Safe because Effect and MCP expose the same JSON Schema wire shape with different array mutability declarations. */ JSONSchema.make(statusCommandRpc.successSchema, { target: "jsonSchema2020-12" }));
|
|
13
|
+
const replyInputSchema = fromJsonSchema(
|
|
14
|
+
/* Safe because Effect and MCP expose the same JSON Schema wire shape with different array mutability declarations. */ harnessReplyInputJsonSchema);
|
|
15
|
+
const replyOutputSchema = fromJsonSchema(
|
|
16
|
+
/* Safe because Effect and MCP expose the same JSON Schema wire shape with different array mutability declarations. */ harnessReplyResultJsonSchema);
|
|
11
17
|
const makeRegistrationServer = (implementation) => new McpServer(implementation);
|
|
12
|
-
const
|
|
13
|
-
const server = new McpServer(implementation);
|
|
18
|
+
const registerStatusTool = (server, status) => {
|
|
14
19
|
server.registerTool(STATUS_TOOL_NAME, {
|
|
15
20
|
inputSchema: statusInputSchema,
|
|
16
21
|
outputSchema: statusOutputSchema,
|
|
@@ -27,6 +32,29 @@ const makeActiveServer = (implementation, status) => {
|
|
|
27
32
|
structuredContent: result,
|
|
28
33
|
})));
|
|
29
34
|
});
|
|
35
|
+
};
|
|
36
|
+
const registerReplyTool = (server, reply) => {
|
|
37
|
+
server.registerTool(HARNESS_REPLY_TOOL, {
|
|
38
|
+
inputSchema: replyInputSchema,
|
|
39
|
+
outputSchema: replyOutputSchema,
|
|
40
|
+
}, (input, context) => Effect.runPromise(Effect.gen(function* () {
|
|
41
|
+
const route = yield* decodeHarnessReplyRoute(context.mcpReq._meta);
|
|
42
|
+
yield* reply(route.conversationId, input.payload);
|
|
43
|
+
const result = {};
|
|
44
|
+
return {
|
|
45
|
+
content: [{ type: "text", text: JSON.stringify(result) }],
|
|
46
|
+
structuredContent: result,
|
|
47
|
+
};
|
|
48
|
+
}), { signal: context.mcpReq.signal }));
|
|
49
|
+
};
|
|
50
|
+
const makeActiveServer = (implementation, status, reply) => {
|
|
51
|
+
const server = new McpServer(implementation, {
|
|
52
|
+
capabilities: {
|
|
53
|
+
extensions: { [HARNESS_EVENTS_EXTENSION]: {} },
|
|
54
|
+
},
|
|
55
|
+
});
|
|
56
|
+
registerStatusTool(server, status);
|
|
57
|
+
registerReplyTool(server, reply);
|
|
30
58
|
return server;
|
|
31
59
|
};
|
|
32
60
|
/**
|
|
@@ -34,15 +62,18 @@ const makeActiveServer = (implementation, status) => {
|
|
|
34
62
|
*
|
|
35
63
|
* @param options Existing daemon capabilities exposed through MCP.
|
|
36
64
|
* @param options.implementation Existing MCP server identity.
|
|
65
|
+
* @param options.reply Conversation-bound raw reply handler.
|
|
37
66
|
* @param options.status Existing local daemon status handler.
|
|
38
67
|
* @returns The registration and active-agent HTTP handlers.
|
|
39
68
|
*/
|
|
40
|
-
export const makeHarnessMcpHttpHandlers = ({ implementation, status, }) =>
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
})
|
|
69
|
+
export const makeHarnessMcpHttpHandlers = ({ implementation, reply, status, }) => {
|
|
70
|
+
const activeDelegate = createMcpHandler(() => makeActiveServer(implementation, status, reply), { legacy: "reject" });
|
|
71
|
+
return {
|
|
72
|
+
registration: createMcpHandler(() => makeRegistrationServer(implementation), { legacy: "reject" }),
|
|
73
|
+
active: makeHarnessMcpSubscriptionHandler({
|
|
74
|
+
delegate: activeDelegate,
|
|
75
|
+
implementation,
|
|
76
|
+
}),
|
|
77
|
+
};
|
|
78
|
+
};
|
|
48
79
|
//# sourceMappingURL=harness-mcp-wire.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"harness-mcp-wire.js","sourceRoot":"","sources":["../src/harness-mcp-wire.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,gBAAgB,EAChB,cAAc,EACd,SAAS,GAIV,MAAM,8BAA8B,CAAC;AACtC,OAAO,EAAE,OAAO,EAAE,MAAM,kBAAkB,CAAC;AAC3C,OAAO,EAAE,GAAG,EAAE,MAAM,aAAa,CAAC;AAClC,OAAO,EAAE,MAAM,EAAE,UAAU,EAAe,MAAM,QAAQ,CAAC;
|
|
1
|
+
{"version":3,"file":"harness-mcp-wire.js","sourceRoot":"","sources":["../src/harness-mcp-wire.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,gBAAgB,EACh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AAE,CAAC;YAClE,iBAAiB,EAAE,MAAM;SAC1B,CAAC;IACJ,CAAC,CAAC,EACF,EAAE,MAAM,EAAE,OAAO,CAAC,MAAM,CAAC,MAAM,EAAE,CAClC,CACJ,CAAC;AACJ,CAAC,CAAC;AAEF,MAAM,gBAAgB,GAAG,CACvB,cAA8B,EAC9B,MAAqB,EACrB,KAAmB,EACR,EAAE;IACb,MAAM,MAAM,GAAG,IAAI,SAAS,CAAC,cAAc,EAAE;QAC3C,YAAY,EAAE;YACZ,UAAU,EAAE,EAAE,CAAC,wBAAwB,CAAC,EAAE,EAAE,EAAE;SAC/C;KACF,CAAC,CAAC;IACH,kBAAkB,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;IACnC,iBAAiB,CAAC,MAAM,EAAE,KAAK,CAAC,CAAC;IACjC,OAAO,MAAM,CAAC;AAChB,CAAC,CAAC;AAEF;;;;;;;;GAQG;AACH,MAAM,CAAC,MAAM,0BAA0B,GAAG,CAAC,EACzC,cAAc,EACd,KAAK,EACL,MAAM,GACmB,EAGzB,EAAE;IACF,MAAM,cAAc,GAAG,gBAAgB,CACrC,GAAG,EAAE,CAAC,gBAAgB,CAAC,cAAc,EAAE,MAAM,EAAE,KAAK,CAAC,EACrD,EAAE,MAAM,EAAE,QAAQ,EAAE,CACrB,CAAC;IACF,OAAO;QACL,YAAY,EAAE,gBAAgB,CAC5B,GAAG,EAAE,CAAC,sBAAsB,CAAC,cAAc,CAAC,EAC5C,EAAE,MAAM,EAAE,QAAQ,EAAE,CACrB;QACD,MAAM,EAAE,iCAAiC,CAAC;YACxC,QAAQ,EAAE,cAAc;YACxB,cAAc;SACf,CAAC;KACH,CAAC;AACJ,CAAC,CAAC"}
|
package/dist/index.d.ts
CHANGED
|
@@ -3,9 +3,7 @@
|
|
|
3
3
|
*/
|
|
4
4
|
export { MoltZapService, type ConversationMeta, type ContextOptions, type ServiceRpcError, } from "./service.js";
|
|
5
5
|
/** Re-exports the public API from `./agent-client.js`. */
|
|
6
|
-
export { MoltZapAgentClient, type AgentClientOptions } from "./agent-client.js";
|
|
7
|
-
/** Re-exports the
|
|
8
|
-
export {
|
|
9
|
-
/** Re-exports the public API from `@moltzap/protocol/socket`. */
|
|
10
|
-
export type { AppCallbackHandlers } from "@moltzap/protocol/socket";
|
|
6
|
+
export { MoltZapAgentClient, type AgentClientOptions, type RpcCallOptions, } from "./agent-client.js";
|
|
7
|
+
/** Re-exports the adapter-facing daemon client capability. */
|
|
8
|
+
export { acquireHarnessClient, HarnessClient, makeHarnessClientLayer, type HarnessClientOptions, type HarnessClientService, type HarnessTurn, } from "./harness-client.js";
|
|
11
9
|
//# sourceMappingURL=index.d.ts.map
|
package/dist/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,OAAO,EACL,cAAc,EACd,KAAK,gBAAgB,EACrB,KAAK,cAAc,EACnB,KAAK,eAAe,GACrB,MAAM,cAAc,CAAC;AACtB,0DAA0D;AAC1D,OAAO,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,OAAO,EACL,cAAc,EACd,KAAK,gBAAgB,EACrB,KAAK,cAAc,EACnB,KAAK,eAAe,GACrB,MAAM,cAAc,CAAC;AACtB,0DAA0D;AAC1D,OAAO,EACL,kBAAkB,EAClB,KAAK,kBAAkB,EACvB,KAAK,cAAc,GACpB,MAAM,mBAAmB,CAAC;AAC3B,8DAA8D;AAC9D,OAAO,EACL,oBAAoB,EACpB,aAAa,EACb,sBAAsB,EACtB,KAAK,oBAAoB,EACzB,KAAK,oBAAoB,EACzB,KAAK,WAAW,GACjB,MAAM,qBAAqB,CAAC"}
|
package/dist/index.js
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
*/
|
|
4
4
|
export { MoltZapService, } from "./service.js";
|
|
5
5
|
/** Re-exports the public API from `./agent-client.js`. */
|
|
6
|
-
export { MoltZapAgentClient } from "./agent-client.js";
|
|
7
|
-
/** Re-exports the
|
|
8
|
-
export {
|
|
6
|
+
export { MoltZapAgentClient, } from "./agent-client.js";
|
|
7
|
+
/** Re-exports the adapter-facing daemon client capability. */
|
|
8
|
+
export { acquireHarnessClient, HarnessClient, makeHarnessClientLayer, } from "./harness-client.js";
|
|
9
9
|
//# sourceMappingURL=index.js.map
|
package/dist/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,OAAO,EACL,cAAc,GAIf,MAAM,cAAc,CAAC;AACtB,0DAA0D;AAC1D,OAAO,
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,OAAO,EACL,cAAc,GAIf,MAAM,cAAc,CAAC;AACtB,0DAA0D;AAC1D,OAAO,EACL,kBAAkB,GAGnB,MAAM,mBAAmB,CAAC;AAC3B,8DAA8D;AAC9D,OAAO,EACL,oBAAoB,EACpB,aAAa,EACb,sBAAsB,GAIvB,MAAM,qBAAqB,CAAC"}
|
|
@@ -2,10 +2,6 @@ import { Rpc, RpcGroup } from "@effect/rpc";
|
|
|
2
2
|
import { Schema } from "effect";
|
|
3
3
|
import type * as SchemaAST from "effect/SchemaAST";
|
|
4
4
|
import { NotConnectedError, RpcTimeoutError } from "@moltzap/protocol/rpc";
|
|
5
|
-
/** Validates and decodes app id v4 values. */
|
|
6
|
-
declare const appIdV4: Schema.filter<Schema.Schema<import("@moltzap/protocol/identity").AppId, string, never>>;
|
|
7
|
-
/** Represents app id v4 values. */
|
|
8
|
-
export type AppIdV4 = Schema.Schema.Type<typeof appIdV4>;
|
|
9
5
|
/** A conversation is the whole address. */
|
|
10
6
|
export declare const sendTarget: Schema.transformOrFail<typeof Schema.String, Schema.Struct<{
|
|
11
7
|
conversationId: Schema.Schema<import("@moltzap/protocol/conversation").ConversationId, string, never>;
|
|
@@ -52,7 +48,6 @@ declare const startCommandPayload: Schema.Struct<{
|
|
|
52
48
|
name: Schema.filter<Schema.filter<typeof Schema.String>>;
|
|
53
49
|
}>]>, never>>;
|
|
54
50
|
message: Schema.optional<typeof Schema.String>;
|
|
55
|
-
appId: Schema.optional<Schema.filter<Schema.Schema<import("@moltzap/protocol/identity").AppId, string, never>>>;
|
|
56
51
|
}>;
|
|
57
52
|
declare const startCommandResult: Schema.Struct<{
|
|
58
53
|
conversationId: Schema.Schema<import("@moltzap/protocol/conversation").ConversationId, string, never>;
|
|
@@ -125,14 +120,6 @@ declare const localDaemonErrorSchema: Schema.Union<[typeof LocalDaemonInputError
|
|
|
125
120
|
readonly _tag: "Forbidden";
|
|
126
121
|
readonly data?: unknown;
|
|
127
122
|
readonly message?: string | undefined;
|
|
128
|
-
}, never> | Schema.Schema<import("@moltzap/protocol/rpc").ForbiddenError | import("@moltzap/protocol/rpc").UnauthorizedError, {
|
|
129
|
-
readonly _tag: "Unauthorized";
|
|
130
|
-
readonly data?: unknown;
|
|
131
|
-
readonly message?: string | undefined;
|
|
132
|
-
} | {
|
|
133
|
-
readonly _tag: "Forbidden";
|
|
134
|
-
readonly data?: unknown;
|
|
135
|
-
readonly message?: string | undefined;
|
|
136
123
|
}, never> | Schema.Schema<import("@moltzap/protocol/rpc").ForbiddenError | import("@moltzap/protocol/rpc").InvalidParamsError | import("@moltzap/protocol/rpc").UnauthorizedError, {
|
|
137
124
|
readonly _tag: "Unauthorized";
|
|
138
125
|
readonly data?: unknown;
|
|
@@ -177,7 +164,7 @@ declare const localDaemonErrorSchema: Schema.Union<[typeof LocalDaemonInputError
|
|
|
177
164
|
readonly _tag: "ConversationFull";
|
|
178
165
|
readonly data?: unknown;
|
|
179
166
|
readonly message?: string | undefined;
|
|
180
|
-
}, never> | Schema.Schema<import("@moltzap/protocol/
|
|
167
|
+
}, never> | Schema.Schema<import("@moltzap/protocol/rpc").ForbiddenError | import("@moltzap/protocol/rpc").UnauthorizedError, {
|
|
181
168
|
readonly _tag: "Unauthorized";
|
|
182
169
|
readonly data?: unknown;
|
|
183
170
|
readonly message?: string | undefined;
|
|
@@ -185,19 +172,11 @@ declare const localDaemonErrorSchema: Schema.Union<[typeof LocalDaemonInputError
|
|
|
185
172
|
readonly _tag: "Forbidden";
|
|
186
173
|
readonly data?: unknown;
|
|
187
174
|
readonly message?: string | undefined;
|
|
188
|
-
} | {
|
|
189
|
-
readonly _tag: "HookBlocked";
|
|
190
|
-
readonly data?: unknown;
|
|
191
|
-
readonly message?: string | undefined;
|
|
192
|
-
} | {
|
|
193
|
-
readonly _tag: "DispatchNotFound";
|
|
194
|
-
readonly data?: unknown;
|
|
195
|
-
readonly message?: string | undefined;
|
|
196
175
|
}, never>)[]]>;
|
|
197
176
|
/** Represents local daemon error conditions. */
|
|
198
177
|
export type LocalDaemonError = Schema.Schema.Type<typeof localDaemonErrorSchema>;
|
|
199
178
|
/** Validates and decodes is local daemon error values. */
|
|
200
|
-
export declare const isLocalDaemonError: (u: unknown, overrideOptions?: SchemaAST.ParseOptions | number) => u is import("@moltzap/protocol/identity").AgentNotFoundError | import("@moltzap/protocol/rpc").AlreadyConnected | import("@moltzap/protocol/conversation").ConversationFullError | import("@moltzap/protocol/conversation").ConversationNotFoundError | import("@moltzap/protocol/
|
|
179
|
+
export declare const isLocalDaemonError: (u: unknown, overrideOptions?: SchemaAST.ParseOptions | number) => u is import("@moltzap/protocol/identity").AgentNotFoundError | import("@moltzap/protocol/rpc").AlreadyConnected | import("@moltzap/protocol/conversation").ConversationFullError | import("@moltzap/protocol/conversation").ConversationNotFoundError | import("@moltzap/protocol/rpc").ForbiddenError | import("@moltzap/protocol/rpc").InvalidParamsError | LocalDaemonInputError | NotConnectedError | import("@moltzap/protocol/network").ProtocolMismatchError | RpcTimeoutError | ServiceInputError | StartPartialFailure | StartUsageError | import("@moltzap/protocol/rpc").UnauthorizedError;
|
|
201
180
|
/**
|
|
202
181
|
* Provides the to local daemon error runtime value.
|
|
203
182
|
* @param error Error to inspect.
|
|
@@ -239,14 +218,6 @@ export declare const statusCommandRpc: Rpc.Rpc<"daemon/status", Schema.Struct<{}
|
|
|
239
218
|
readonly _tag: "Forbidden";
|
|
240
219
|
readonly data?: unknown;
|
|
241
220
|
readonly message?: string | undefined;
|
|
242
|
-
}, never> | Schema.Schema<import("@moltzap/protocol/rpc").ForbiddenError | import("@moltzap/protocol/rpc").UnauthorizedError, {
|
|
243
|
-
readonly _tag: "Unauthorized";
|
|
244
|
-
readonly data?: unknown;
|
|
245
|
-
readonly message?: string | undefined;
|
|
246
|
-
} | {
|
|
247
|
-
readonly _tag: "Forbidden";
|
|
248
|
-
readonly data?: unknown;
|
|
249
|
-
readonly message?: string | undefined;
|
|
250
221
|
}, never> | Schema.Schema<import("@moltzap/protocol/rpc").ForbiddenError | import("@moltzap/protocol/rpc").InvalidParamsError | import("@moltzap/protocol/rpc").UnauthorizedError, {
|
|
251
222
|
readonly _tag: "Unauthorized";
|
|
252
223
|
readonly data?: unknown;
|
|
@@ -291,7 +262,7 @@ export declare const statusCommandRpc: Rpc.Rpc<"daemon/status", Schema.Struct<{}
|
|
|
291
262
|
readonly _tag: "ConversationFull";
|
|
292
263
|
readonly data?: unknown;
|
|
293
264
|
readonly message?: string | undefined;
|
|
294
|
-
}, never> | Schema.Schema<import("@moltzap/protocol/
|
|
265
|
+
}, never> | Schema.Schema<import("@moltzap/protocol/rpc").ForbiddenError | import("@moltzap/protocol/rpc").UnauthorizedError, {
|
|
295
266
|
readonly _tag: "Unauthorized";
|
|
296
267
|
readonly data?: unknown;
|
|
297
268
|
readonly message?: string | undefined;
|
|
@@ -299,14 +270,6 @@ export declare const statusCommandRpc: Rpc.Rpc<"daemon/status", Schema.Struct<{}
|
|
|
299
270
|
readonly _tag: "Forbidden";
|
|
300
271
|
readonly data?: unknown;
|
|
301
272
|
readonly message?: string | undefined;
|
|
302
|
-
} | {
|
|
303
|
-
readonly _tag: "HookBlocked";
|
|
304
|
-
readonly data?: unknown;
|
|
305
|
-
readonly message?: string | undefined;
|
|
306
|
-
} | {
|
|
307
|
-
readonly _tag: "DispatchNotFound";
|
|
308
|
-
readonly data?: unknown;
|
|
309
|
-
readonly message?: string | undefined;
|
|
310
273
|
}, never>)[]]>, never>;
|
|
311
274
|
/** Provides the messages list command rpc runtime value. */
|
|
312
275
|
export declare const messagesListCommandRpc: Rpc.Rpc<"cli/messages/list", Schema.Struct<{
|
|
@@ -363,14 +326,6 @@ export declare const messagesListCommandRpc: Rpc.Rpc<"cli/messages/list", Schema
|
|
|
363
326
|
readonly _tag: "Forbidden";
|
|
364
327
|
readonly data?: unknown;
|
|
365
328
|
readonly message?: string | undefined;
|
|
366
|
-
}, never> | Schema.Schema<import("@moltzap/protocol/rpc").ForbiddenError | import("@moltzap/protocol/rpc").UnauthorizedError, {
|
|
367
|
-
readonly _tag: "Unauthorized";
|
|
368
|
-
readonly data?: unknown;
|
|
369
|
-
readonly message?: string | undefined;
|
|
370
|
-
} | {
|
|
371
|
-
readonly _tag: "Forbidden";
|
|
372
|
-
readonly data?: unknown;
|
|
373
|
-
readonly message?: string | undefined;
|
|
374
329
|
}, never> | Schema.Schema<import("@moltzap/protocol/rpc").ForbiddenError | import("@moltzap/protocol/rpc").InvalidParamsError | import("@moltzap/protocol/rpc").UnauthorizedError, {
|
|
375
330
|
readonly _tag: "Unauthorized";
|
|
376
331
|
readonly data?: unknown;
|
|
@@ -415,7 +370,7 @@ export declare const messagesListCommandRpc: Rpc.Rpc<"cli/messages/list", Schema
|
|
|
415
370
|
readonly _tag: "ConversationFull";
|
|
416
371
|
readonly data?: unknown;
|
|
417
372
|
readonly message?: string | undefined;
|
|
418
|
-
}, never> | Schema.Schema<import("@moltzap/protocol/
|
|
373
|
+
}, never> | Schema.Schema<import("@moltzap/protocol/rpc").ForbiddenError | import("@moltzap/protocol/rpc").UnauthorizedError, {
|
|
419
374
|
readonly _tag: "Unauthorized";
|
|
420
375
|
readonly data?: unknown;
|
|
421
376
|
readonly message?: string | undefined;
|
|
@@ -423,14 +378,6 @@ export declare const messagesListCommandRpc: Rpc.Rpc<"cli/messages/list", Schema
|
|
|
423
378
|
readonly _tag: "Forbidden";
|
|
424
379
|
readonly data?: unknown;
|
|
425
380
|
readonly message?: string | undefined;
|
|
426
|
-
} | {
|
|
427
|
-
readonly _tag: "HookBlocked";
|
|
428
|
-
readonly data?: unknown;
|
|
429
|
-
readonly message?: string | undefined;
|
|
430
|
-
} | {
|
|
431
|
-
readonly _tag: "DispatchNotFound";
|
|
432
|
-
readonly data?: unknown;
|
|
433
|
-
readonly message?: string | undefined;
|
|
434
381
|
}, never>)[]]>, never>;
|
|
435
382
|
/** Provides the start command rpc runtime value. */
|
|
436
383
|
export declare const startCommandRpc: Rpc.Rpc<"cli/start", Schema.Struct<{
|
|
@@ -444,7 +391,6 @@ export declare const startCommandRpc: Rpc.Rpc<"cli/start", Schema.Struct<{
|
|
|
444
391
|
name: Schema.filter<Schema.filter<typeof Schema.String>>;
|
|
445
392
|
}>]>, never>>;
|
|
446
393
|
message: Schema.optional<typeof Schema.String>;
|
|
447
|
-
appId: Schema.optional<Schema.filter<Schema.Schema<import("@moltzap/protocol/identity").AppId, string, never>>>;
|
|
448
394
|
}>, Schema.Struct<{
|
|
449
395
|
conversationId: Schema.Schema<import("@moltzap/protocol/conversation").ConversationId, string, never>;
|
|
450
396
|
sentMessageId: Schema.optional<Schema.Schema<import("@moltzap/protocol/conversation").MessageId, string, never>>;
|
|
@@ -478,14 +424,6 @@ export declare const startCommandRpc: Rpc.Rpc<"cli/start", Schema.Struct<{
|
|
|
478
424
|
readonly _tag: "Forbidden";
|
|
479
425
|
readonly data?: unknown;
|
|
480
426
|
readonly message?: string | undefined;
|
|
481
|
-
}, never> | Schema.Schema<import("@moltzap/protocol/rpc").ForbiddenError | import("@moltzap/protocol/rpc").UnauthorizedError, {
|
|
482
|
-
readonly _tag: "Unauthorized";
|
|
483
|
-
readonly data?: unknown;
|
|
484
|
-
readonly message?: string | undefined;
|
|
485
|
-
} | {
|
|
486
|
-
readonly _tag: "Forbidden";
|
|
487
|
-
readonly data?: unknown;
|
|
488
|
-
readonly message?: string | undefined;
|
|
489
427
|
}, never> | Schema.Schema<import("@moltzap/protocol/rpc").ForbiddenError | import("@moltzap/protocol/rpc").InvalidParamsError | import("@moltzap/protocol/rpc").UnauthorizedError, {
|
|
490
428
|
readonly _tag: "Unauthorized";
|
|
491
429
|
readonly data?: unknown;
|
|
@@ -530,7 +468,7 @@ export declare const startCommandRpc: Rpc.Rpc<"cli/start", Schema.Struct<{
|
|
|
530
468
|
readonly _tag: "ConversationFull";
|
|
531
469
|
readonly data?: unknown;
|
|
532
470
|
readonly message?: string | undefined;
|
|
533
|
-
}, never> | Schema.Schema<import("@moltzap/protocol/
|
|
471
|
+
}, never> | Schema.Schema<import("@moltzap/protocol/rpc").ForbiddenError | import("@moltzap/protocol/rpc").UnauthorizedError, {
|
|
534
472
|
readonly _tag: "Unauthorized";
|
|
535
473
|
readonly data?: unknown;
|
|
536
474
|
readonly message?: string | undefined;
|
|
@@ -538,14 +476,6 @@ export declare const startCommandRpc: Rpc.Rpc<"cli/start", Schema.Struct<{
|
|
|
538
476
|
readonly _tag: "Forbidden";
|
|
539
477
|
readonly data?: unknown;
|
|
540
478
|
readonly message?: string | undefined;
|
|
541
|
-
} | {
|
|
542
|
-
readonly _tag: "HookBlocked";
|
|
543
|
-
readonly data?: unknown;
|
|
544
|
-
readonly message?: string | undefined;
|
|
545
|
-
} | {
|
|
546
|
-
readonly _tag: "DispatchNotFound";
|
|
547
|
-
readonly data?: unknown;
|
|
548
|
-
readonly message?: string | undefined;
|
|
549
479
|
}, never>)[]]>, never>;
|
|
550
480
|
declare const LocalDaemonRpcs_base: RpcGroup.RpcGroup<Rpc.Rpc<"cli/agents/list", Schema.Struct<{
|
|
551
481
|
limit: Schema.optional<Schema.filter<Schema.filter<Schema.filter<typeof Schema.Number>>>>;
|
|
@@ -595,14 +525,6 @@ declare const LocalDaemonRpcs_base: RpcGroup.RpcGroup<Rpc.Rpc<"cli/agents/list",
|
|
|
595
525
|
readonly _tag: "Forbidden";
|
|
596
526
|
readonly data?: unknown;
|
|
597
527
|
readonly message?: string | undefined;
|
|
598
|
-
}, never> | Schema.Schema<import("@moltzap/protocol/rpc").ForbiddenError | import("@moltzap/protocol/rpc").UnauthorizedError, {
|
|
599
|
-
readonly _tag: "Unauthorized";
|
|
600
|
-
readonly data?: unknown;
|
|
601
|
-
readonly message?: string | undefined;
|
|
602
|
-
} | {
|
|
603
|
-
readonly _tag: "Forbidden";
|
|
604
|
-
readonly data?: unknown;
|
|
605
|
-
readonly message?: string | undefined;
|
|
606
528
|
}, never> | Schema.Schema<import("@moltzap/protocol/rpc").ForbiddenError | import("@moltzap/protocol/rpc").InvalidParamsError | import("@moltzap/protocol/rpc").UnauthorizedError, {
|
|
607
529
|
readonly _tag: "Unauthorized";
|
|
608
530
|
readonly data?: unknown;
|
|
@@ -647,7 +569,7 @@ declare const LocalDaemonRpcs_base: RpcGroup.RpcGroup<Rpc.Rpc<"cli/agents/list",
|
|
|
647
569
|
readonly _tag: "ConversationFull";
|
|
648
570
|
readonly data?: unknown;
|
|
649
571
|
readonly message?: string | undefined;
|
|
650
|
-
}, never> | Schema.Schema<import("@moltzap/protocol/
|
|
572
|
+
}, never> | Schema.Schema<import("@moltzap/protocol/rpc").ForbiddenError | import("@moltzap/protocol/rpc").UnauthorizedError, {
|
|
651
573
|
readonly _tag: "Unauthorized";
|
|
652
574
|
readonly data?: unknown;
|
|
653
575
|
readonly message?: string | undefined;
|
|
@@ -655,14 +577,6 @@ declare const LocalDaemonRpcs_base: RpcGroup.RpcGroup<Rpc.Rpc<"cli/agents/list",
|
|
|
655
577
|
readonly _tag: "Forbidden";
|
|
656
578
|
readonly data?: unknown;
|
|
657
579
|
readonly message?: string | undefined;
|
|
658
|
-
} | {
|
|
659
|
-
readonly _tag: "HookBlocked";
|
|
660
|
-
readonly data?: unknown;
|
|
661
|
-
readonly message?: string | undefined;
|
|
662
|
-
} | {
|
|
663
|
-
readonly _tag: "DispatchNotFound";
|
|
664
|
-
readonly data?: unknown;
|
|
665
|
-
readonly message?: string | undefined;
|
|
666
580
|
}, never>)[]]>, never> | Rpc.Rpc<"cli/agents/search", Schema.Struct<{
|
|
667
581
|
names: Schema.filter<Schema.filter<Schema.Array$<Schema.filter<Schema.filter<typeof Schema.String>>>>>;
|
|
668
582
|
}>, Schema.Struct<{
|
|
@@ -711,14 +625,6 @@ declare const LocalDaemonRpcs_base: RpcGroup.RpcGroup<Rpc.Rpc<"cli/agents/list",
|
|
|
711
625
|
readonly _tag: "Forbidden";
|
|
712
626
|
readonly data?: unknown;
|
|
713
627
|
readonly message?: string | undefined;
|
|
714
|
-
}, never> | Schema.Schema<import("@moltzap/protocol/rpc").ForbiddenError | import("@moltzap/protocol/rpc").UnauthorizedError, {
|
|
715
|
-
readonly _tag: "Unauthorized";
|
|
716
|
-
readonly data?: unknown;
|
|
717
|
-
readonly message?: string | undefined;
|
|
718
|
-
} | {
|
|
719
|
-
readonly _tag: "Forbidden";
|
|
720
|
-
readonly data?: unknown;
|
|
721
|
-
readonly message?: string | undefined;
|
|
722
628
|
}, never> | Schema.Schema<import("@moltzap/protocol/rpc").ForbiddenError | import("@moltzap/protocol/rpc").InvalidParamsError | import("@moltzap/protocol/rpc").UnauthorizedError, {
|
|
723
629
|
readonly _tag: "Unauthorized";
|
|
724
630
|
readonly data?: unknown;
|
|
@@ -763,7 +669,7 @@ declare const LocalDaemonRpcs_base: RpcGroup.RpcGroup<Rpc.Rpc<"cli/agents/list",
|
|
|
763
669
|
readonly _tag: "ConversationFull";
|
|
764
670
|
readonly data?: unknown;
|
|
765
671
|
readonly message?: string | undefined;
|
|
766
|
-
}, never> | Schema.Schema<import("@moltzap/protocol/
|
|
672
|
+
}, never> | Schema.Schema<import("@moltzap/protocol/rpc").ForbiddenError | import("@moltzap/protocol/rpc").UnauthorizedError, {
|
|
767
673
|
readonly _tag: "Unauthorized";
|
|
768
674
|
readonly data?: unknown;
|
|
769
675
|
readonly message?: string | undefined;
|
|
@@ -771,14 +677,6 @@ declare const LocalDaemonRpcs_base: RpcGroup.RpcGroup<Rpc.Rpc<"cli/agents/list",
|
|
|
771
677
|
readonly _tag: "Forbidden";
|
|
772
678
|
readonly data?: unknown;
|
|
773
679
|
readonly message?: string | undefined;
|
|
774
|
-
} | {
|
|
775
|
-
readonly _tag: "HookBlocked";
|
|
776
|
-
readonly data?: unknown;
|
|
777
|
-
readonly message?: string | undefined;
|
|
778
|
-
} | {
|
|
779
|
-
readonly _tag: "DispatchNotFound";
|
|
780
|
-
readonly data?: unknown;
|
|
781
|
-
readonly message?: string | undefined;
|
|
782
680
|
}, never>)[]]>, never> | Rpc.Rpc<"cli/messages/list", Schema.Struct<{
|
|
783
681
|
conversationId: Schema.Schema<import("@moltzap/protocol/conversation").ConversationId, string, never>;
|
|
784
682
|
limit: Schema.optional<Schema.filter<Schema.filter<Schema.filter<typeof Schema.Number>>>>;
|
|
@@ -833,14 +731,6 @@ declare const LocalDaemonRpcs_base: RpcGroup.RpcGroup<Rpc.Rpc<"cli/agents/list",
|
|
|
833
731
|
readonly _tag: "Forbidden";
|
|
834
732
|
readonly data?: unknown;
|
|
835
733
|
readonly message?: string | undefined;
|
|
836
|
-
}, never> | Schema.Schema<import("@moltzap/protocol/rpc").ForbiddenError | import("@moltzap/protocol/rpc").UnauthorizedError, {
|
|
837
|
-
readonly _tag: "Unauthorized";
|
|
838
|
-
readonly data?: unknown;
|
|
839
|
-
readonly message?: string | undefined;
|
|
840
|
-
} | {
|
|
841
|
-
readonly _tag: "Forbidden";
|
|
842
|
-
readonly data?: unknown;
|
|
843
|
-
readonly message?: string | undefined;
|
|
844
734
|
}, never> | Schema.Schema<import("@moltzap/protocol/rpc").ForbiddenError | import("@moltzap/protocol/rpc").InvalidParamsError | import("@moltzap/protocol/rpc").UnauthorizedError, {
|
|
845
735
|
readonly _tag: "Unauthorized";
|
|
846
736
|
readonly data?: unknown;
|
|
@@ -885,7 +775,7 @@ declare const LocalDaemonRpcs_base: RpcGroup.RpcGroup<Rpc.Rpc<"cli/agents/list",
|
|
|
885
775
|
readonly _tag: "ConversationFull";
|
|
886
776
|
readonly data?: unknown;
|
|
887
777
|
readonly message?: string | undefined;
|
|
888
|
-
}, never> | Schema.Schema<import("@moltzap/protocol/
|
|
778
|
+
}, never> | Schema.Schema<import("@moltzap/protocol/rpc").ForbiddenError | import("@moltzap/protocol/rpc").UnauthorizedError, {
|
|
889
779
|
readonly _tag: "Unauthorized";
|
|
890
780
|
readonly data?: unknown;
|
|
891
781
|
readonly message?: string | undefined;
|
|
@@ -893,14 +783,6 @@ declare const LocalDaemonRpcs_base: RpcGroup.RpcGroup<Rpc.Rpc<"cli/agents/list",
|
|
|
893
783
|
readonly _tag: "Forbidden";
|
|
894
784
|
readonly data?: unknown;
|
|
895
785
|
readonly message?: string | undefined;
|
|
896
|
-
} | {
|
|
897
|
-
readonly _tag: "HookBlocked";
|
|
898
|
-
readonly data?: unknown;
|
|
899
|
-
readonly message?: string | undefined;
|
|
900
|
-
} | {
|
|
901
|
-
readonly _tag: "DispatchNotFound";
|
|
902
|
-
readonly data?: unknown;
|
|
903
|
-
readonly message?: string | undefined;
|
|
904
786
|
}, never>)[]]>, never> | Rpc.Rpc<"cli/send", Schema.Struct<{
|
|
905
787
|
target: Schema.transformOrFail<typeof Schema.String, Schema.Struct<{
|
|
906
788
|
conversationId: Schema.Schema<import("@moltzap/protocol/conversation").ConversationId, string, never>;
|
|
@@ -938,14 +820,6 @@ declare const LocalDaemonRpcs_base: RpcGroup.RpcGroup<Rpc.Rpc<"cli/agents/list",
|
|
|
938
820
|
readonly _tag: "Forbidden";
|
|
939
821
|
readonly data?: unknown;
|
|
940
822
|
readonly message?: string | undefined;
|
|
941
|
-
}, never> | Schema.Schema<import("@moltzap/protocol/rpc").ForbiddenError | import("@moltzap/protocol/rpc").UnauthorizedError, {
|
|
942
|
-
readonly _tag: "Unauthorized";
|
|
943
|
-
readonly data?: unknown;
|
|
944
|
-
readonly message?: string | undefined;
|
|
945
|
-
} | {
|
|
946
|
-
readonly _tag: "Forbidden";
|
|
947
|
-
readonly data?: unknown;
|
|
948
|
-
readonly message?: string | undefined;
|
|
949
823
|
}, never> | Schema.Schema<import("@moltzap/protocol/rpc").ForbiddenError | import("@moltzap/protocol/rpc").InvalidParamsError | import("@moltzap/protocol/rpc").UnauthorizedError, {
|
|
950
824
|
readonly _tag: "Unauthorized";
|
|
951
825
|
readonly data?: unknown;
|
|
@@ -990,7 +864,7 @@ declare const LocalDaemonRpcs_base: RpcGroup.RpcGroup<Rpc.Rpc<"cli/agents/list",
|
|
|
990
864
|
readonly _tag: "ConversationFull";
|
|
991
865
|
readonly data?: unknown;
|
|
992
866
|
readonly message?: string | undefined;
|
|
993
|
-
}, never> | Schema.Schema<import("@moltzap/protocol/
|
|
867
|
+
}, never> | Schema.Schema<import("@moltzap/protocol/rpc").ForbiddenError | import("@moltzap/protocol/rpc").UnauthorizedError, {
|
|
994
868
|
readonly _tag: "Unauthorized";
|
|
995
869
|
readonly data?: unknown;
|
|
996
870
|
readonly message?: string | undefined;
|
|
@@ -998,14 +872,6 @@ declare const LocalDaemonRpcs_base: RpcGroup.RpcGroup<Rpc.Rpc<"cli/agents/list",
|
|
|
998
872
|
readonly _tag: "Forbidden";
|
|
999
873
|
readonly data?: unknown;
|
|
1000
874
|
readonly message?: string | undefined;
|
|
1001
|
-
} | {
|
|
1002
|
-
readonly _tag: "HookBlocked";
|
|
1003
|
-
readonly data?: unknown;
|
|
1004
|
-
readonly message?: string | undefined;
|
|
1005
|
-
} | {
|
|
1006
|
-
readonly _tag: "DispatchNotFound";
|
|
1007
|
-
readonly data?: unknown;
|
|
1008
|
-
readonly message?: string | undefined;
|
|
1009
875
|
}, never>)[]]>, never> | Rpc.Rpc<"cli/start", Schema.Struct<{
|
|
1010
876
|
name: Schema.filter<Schema.filter<typeof Schema.String>>;
|
|
1011
877
|
participants: Schema.Array$<Schema.transformOrFail<typeof Schema.String, Schema.Union<[Schema.Struct<{
|
|
@@ -1017,7 +883,6 @@ declare const LocalDaemonRpcs_base: RpcGroup.RpcGroup<Rpc.Rpc<"cli/agents/list",
|
|
|
1017
883
|
name: Schema.filter<Schema.filter<typeof Schema.String>>;
|
|
1018
884
|
}>]>, never>>;
|
|
1019
885
|
message: Schema.optional<typeof Schema.String>;
|
|
1020
|
-
appId: Schema.optional<Schema.filter<Schema.Schema<import("@moltzap/protocol/identity").AppId, string, never>>>;
|
|
1021
886
|
}>, Schema.Struct<{
|
|
1022
887
|
conversationId: Schema.Schema<import("@moltzap/protocol/conversation").ConversationId, string, never>;
|
|
1023
888
|
sentMessageId: Schema.optional<Schema.Schema<import("@moltzap/protocol/conversation").MessageId, string, never>>;
|
|
@@ -1051,14 +916,6 @@ declare const LocalDaemonRpcs_base: RpcGroup.RpcGroup<Rpc.Rpc<"cli/agents/list",
|
|
|
1051
916
|
readonly _tag: "Forbidden";
|
|
1052
917
|
readonly data?: unknown;
|
|
1053
918
|
readonly message?: string | undefined;
|
|
1054
|
-
}, never> | Schema.Schema<import("@moltzap/protocol/rpc").ForbiddenError | import("@moltzap/protocol/rpc").UnauthorizedError, {
|
|
1055
|
-
readonly _tag: "Unauthorized";
|
|
1056
|
-
readonly data?: unknown;
|
|
1057
|
-
readonly message?: string | undefined;
|
|
1058
|
-
} | {
|
|
1059
|
-
readonly _tag: "Forbidden";
|
|
1060
|
-
readonly data?: unknown;
|
|
1061
|
-
readonly message?: string | undefined;
|
|
1062
919
|
}, never> | Schema.Schema<import("@moltzap/protocol/rpc").ForbiddenError | import("@moltzap/protocol/rpc").InvalidParamsError | import("@moltzap/protocol/rpc").UnauthorizedError, {
|
|
1063
920
|
readonly _tag: "Unauthorized";
|
|
1064
921
|
readonly data?: unknown;
|
|
@@ -1103,7 +960,7 @@ declare const LocalDaemonRpcs_base: RpcGroup.RpcGroup<Rpc.Rpc<"cli/agents/list",
|
|
|
1103
960
|
readonly _tag: "ConversationFull";
|
|
1104
961
|
readonly data?: unknown;
|
|
1105
962
|
readonly message?: string | undefined;
|
|
1106
|
-
}, never> | Schema.Schema<import("@moltzap/protocol/
|
|
963
|
+
}, never> | Schema.Schema<import("@moltzap/protocol/rpc").ForbiddenError | import("@moltzap/protocol/rpc").UnauthorizedError, {
|
|
1107
964
|
readonly _tag: "Unauthorized";
|
|
1108
965
|
readonly data?: unknown;
|
|
1109
966
|
readonly message?: string | undefined;
|
|
@@ -1111,14 +968,6 @@ declare const LocalDaemonRpcs_base: RpcGroup.RpcGroup<Rpc.Rpc<"cli/agents/list",
|
|
|
1111
968
|
readonly _tag: "Forbidden";
|
|
1112
969
|
readonly data?: unknown;
|
|
1113
970
|
readonly message?: string | undefined;
|
|
1114
|
-
} | {
|
|
1115
|
-
readonly _tag: "HookBlocked";
|
|
1116
|
-
readonly data?: unknown;
|
|
1117
|
-
readonly message?: string | undefined;
|
|
1118
|
-
} | {
|
|
1119
|
-
readonly _tag: "DispatchNotFound";
|
|
1120
|
-
readonly data?: unknown;
|
|
1121
|
-
readonly message?: string | undefined;
|
|
1122
971
|
}, never>)[]]>, never> | Rpc.Rpc<"daemon/history", Schema.Struct<{
|
|
1123
972
|
conversationId: Schema.Schema<import("@moltzap/protocol/conversation").ConversationId, string, never>;
|
|
1124
973
|
limit: Schema.optionalWith<Schema.filter<Schema.filter<typeof Schema.Number>>, {
|
|
@@ -1173,14 +1022,6 @@ declare const LocalDaemonRpcs_base: RpcGroup.RpcGroup<Rpc.Rpc<"cli/agents/list",
|
|
|
1173
1022
|
readonly _tag: "Forbidden";
|
|
1174
1023
|
readonly data?: unknown;
|
|
1175
1024
|
readonly message?: string | undefined;
|
|
1176
|
-
}, never> | Schema.Schema<import("@moltzap/protocol/rpc").ForbiddenError | import("@moltzap/protocol/rpc").UnauthorizedError, {
|
|
1177
|
-
readonly _tag: "Unauthorized";
|
|
1178
|
-
readonly data?: unknown;
|
|
1179
|
-
readonly message?: string | undefined;
|
|
1180
|
-
} | {
|
|
1181
|
-
readonly _tag: "Forbidden";
|
|
1182
|
-
readonly data?: unknown;
|
|
1183
|
-
readonly message?: string | undefined;
|
|
1184
1025
|
}, never> | Schema.Schema<import("@moltzap/protocol/rpc").ForbiddenError | import("@moltzap/protocol/rpc").InvalidParamsError | import("@moltzap/protocol/rpc").UnauthorizedError, {
|
|
1185
1026
|
readonly _tag: "Unauthorized";
|
|
1186
1027
|
readonly data?: unknown;
|
|
@@ -1225,7 +1066,7 @@ declare const LocalDaemonRpcs_base: RpcGroup.RpcGroup<Rpc.Rpc<"cli/agents/list",
|
|
|
1225
1066
|
readonly _tag: "ConversationFull";
|
|
1226
1067
|
readonly data?: unknown;
|
|
1227
1068
|
readonly message?: string | undefined;
|
|
1228
|
-
}, never> | Schema.Schema<import("@moltzap/protocol/
|
|
1069
|
+
}, never> | Schema.Schema<import("@moltzap/protocol/rpc").ForbiddenError | import("@moltzap/protocol/rpc").UnauthorizedError, {
|
|
1229
1070
|
readonly _tag: "Unauthorized";
|
|
1230
1071
|
readonly data?: unknown;
|
|
1231
1072
|
readonly message?: string | undefined;
|
|
@@ -1233,14 +1074,6 @@ declare const LocalDaemonRpcs_base: RpcGroup.RpcGroup<Rpc.Rpc<"cli/agents/list",
|
|
|
1233
1074
|
readonly _tag: "Forbidden";
|
|
1234
1075
|
readonly data?: unknown;
|
|
1235
1076
|
readonly message?: string | undefined;
|
|
1236
|
-
} | {
|
|
1237
|
-
readonly _tag: "HookBlocked";
|
|
1238
|
-
readonly data?: unknown;
|
|
1239
|
-
readonly message?: string | undefined;
|
|
1240
|
-
} | {
|
|
1241
|
-
readonly _tag: "DispatchNotFound";
|
|
1242
|
-
readonly data?: unknown;
|
|
1243
|
-
readonly message?: string | undefined;
|
|
1244
1077
|
}, never>)[]]>, never> | Rpc.Rpc<"daemon/status", Schema.Struct<{}>, Schema.Struct<{
|
|
1245
1078
|
agentId: Schema.optional<Schema.Schema<import("@moltzap/protocol/identity").AgentId, string, never>>;
|
|
1246
1079
|
connected: typeof Schema.Boolean;
|
|
@@ -1275,14 +1108,6 @@ declare const LocalDaemonRpcs_base: RpcGroup.RpcGroup<Rpc.Rpc<"cli/agents/list",
|
|
|
1275
1108
|
readonly _tag: "Forbidden";
|
|
1276
1109
|
readonly data?: unknown;
|
|
1277
1110
|
readonly message?: string | undefined;
|
|
1278
|
-
}, never> | Schema.Schema<import("@moltzap/protocol/rpc").ForbiddenError | import("@moltzap/protocol/rpc").UnauthorizedError, {
|
|
1279
|
-
readonly _tag: "Unauthorized";
|
|
1280
|
-
readonly data?: unknown;
|
|
1281
|
-
readonly message?: string | undefined;
|
|
1282
|
-
} | {
|
|
1283
|
-
readonly _tag: "Forbidden";
|
|
1284
|
-
readonly data?: unknown;
|
|
1285
|
-
readonly message?: string | undefined;
|
|
1286
1111
|
}, never> | Schema.Schema<import("@moltzap/protocol/rpc").ForbiddenError | import("@moltzap/protocol/rpc").InvalidParamsError | import("@moltzap/protocol/rpc").UnauthorizedError, {
|
|
1287
1112
|
readonly _tag: "Unauthorized";
|
|
1288
1113
|
readonly data?: unknown;
|
|
@@ -1327,7 +1152,7 @@ declare const LocalDaemonRpcs_base: RpcGroup.RpcGroup<Rpc.Rpc<"cli/agents/list",
|
|
|
1327
1152
|
readonly _tag: "ConversationFull";
|
|
1328
1153
|
readonly data?: unknown;
|
|
1329
1154
|
readonly message?: string | undefined;
|
|
1330
|
-
}, never> | Schema.Schema<import("@moltzap/protocol/
|
|
1155
|
+
}, never> | Schema.Schema<import("@moltzap/protocol/rpc").ForbiddenError | import("@moltzap/protocol/rpc").UnauthorizedError, {
|
|
1331
1156
|
readonly _tag: "Unauthorized";
|
|
1332
1157
|
readonly data?: unknown;
|
|
1333
1158
|
readonly message?: string | undefined;
|
|
@@ -1335,14 +1160,6 @@ declare const LocalDaemonRpcs_base: RpcGroup.RpcGroup<Rpc.Rpc<"cli/agents/list",
|
|
|
1335
1160
|
readonly _tag: "Forbidden";
|
|
1336
1161
|
readonly data?: unknown;
|
|
1337
1162
|
readonly message?: string | undefined;
|
|
1338
|
-
} | {
|
|
1339
|
-
readonly _tag: "HookBlocked";
|
|
1340
|
-
readonly data?: unknown;
|
|
1341
|
-
readonly message?: string | undefined;
|
|
1342
|
-
} | {
|
|
1343
|
-
readonly _tag: "DispatchNotFound";
|
|
1344
|
-
readonly data?: unknown;
|
|
1345
|
-
readonly message?: string | undefined;
|
|
1346
1163
|
}, never>)[]]>, never>>;
|
|
1347
1164
|
/** Implements local daemon rpcs. */
|
|
1348
1165
|
export declare class LocalDaemonRpcs extends LocalDaemonRpcs_base {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"local-daemon-rpc.d.ts","sourceRoot":"","sources":["../src/local-daemon-rpc.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,GAAG,EAAE,QAAQ,EAAE,MAAM,aAAa,CAAC;AAC5C,OAAO,EAAuB,MAAM,EAAE,MAAM,QAAQ,CAAC;AACrD,OAAO,KAAK,KAAK,SAAS,MAAM,kBAAkB,CAAC;AAKnD,OAAO,EAAE,iBAAiB,EAAE,eAAe,EAAE,MAAM,uBAAuB,CAAC;
|
|
1
|
+
{"version":3,"file":"local-daemon-rpc.d.ts","sourceRoot":"","sources":["../src/local-daemon-rpc.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,GAAG,EAAE,QAAQ,EAAE,MAAM,aAAa,CAAC;AAC5C,OAAO,EAAuB,MAAM,EAAE,MAAM,QAAQ,CAAC;AACrD,OAAO,KAAK,KAAK,SAAS,MAAM,kBAAkB,CAAC;AAKnD,OAAO,EAAE,iBAAiB,EAAE,eAAe,EAAE,MAAM,uBAAuB,CAAC;AAsC3E,2CAA2C;AAC3C,eAAO,MAAM,UAAU;;UAiBtB,CAAC;AACF,qCAAqC;AACrC,MAAM,MAAM,UAAU,GAAG,MAAM,CAAC,MAAM,CAAC,IAAI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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAEH,oCAAoC;AACpC,qBAAa,eAAgB,SAAQ,oBAoBpC;CAAG;AAEJ,+CAA+C;AAC/C,MAAM,MAAM,mBAAmB,GAAG,QAAQ,CAAC,YAAY,CACrD,QAAQ,CAAC,IAAI,CAAC,OAAO,eAAe,CAAC,CACtC,CAAC"}
|
package/dist/local-daemon-rpc.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { Rpc, RpcGroup } from "@effect/rpc";
|
|
2
2
|
import { Effect, ParseResult, Schema } from "effect";
|
|
3
|
-
import { agentId, agentsList
|
|
3
|
+
import { agentId, agentsList } from "@moltzap/protocol/identity";
|
|
4
4
|
import { agentCallableMethods } from "@moltzap/protocol/socket/catalog";
|
|
5
5
|
import { conversationId, messageId } from "@moltzap/protocol/conversation";
|
|
6
6
|
import { messagesList } from "@moltzap/protocol/message";
|
|
@@ -18,9 +18,6 @@ const localDaemonStatusResultSchema = Schema.Struct({
|
|
|
18
18
|
conversations: Schema.Number.pipe(Schema.int(), Schema.nonNegative()),
|
|
19
19
|
});
|
|
20
20
|
const pageLimit = Schema.Number.pipe(Schema.int(), Schema.greaterThanOrEqualTo(1), Schema.lessThanOrEqualTo(MAX_PAGE_LIMIT));
|
|
21
|
-
/** Validates and decodes app id v4 values. */
|
|
22
|
-
const appIdV4 = appId.pipe(Schema.filter((value) => (typeof value === "string" && UUID_V4_RE.test(value)) ||
|
|
23
|
-
"must be a UUID v4"));
|
|
24
21
|
const parseStringIssue = (ast, actual, message) => Effect.fail(new ParseResult.Type(ast, actual, message));
|
|
25
22
|
const sendTargetParts = Schema.Struct({
|
|
26
23
|
conversationId: conversationId,
|
|
@@ -107,7 +104,6 @@ const startCommandPayload = Schema.Struct({
|
|
|
107
104
|
name: Schema.String.pipe(Schema.minLength(1), Schema.maxLength(100)),
|
|
108
105
|
participants: Schema.Array(startParticipant),
|
|
109
106
|
message: Schema.optional(Schema.String),
|
|
110
|
-
appId: Schema.optional(appIdV4),
|
|
111
107
|
});
|
|
112
108
|
const startCommandResult = Schema.Struct({
|
|
113
109
|
conversationId: conversationId,
|