@maiaos/cli 0.1.0-canary.3 → 0.1.0-canary.31
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/README.md +2 -2
- package/dist/agents/client.d.ts +35 -27
- package/dist/agents/client.js +10 -3
- package/dist/agents/commands.d.ts +1 -0
- package/dist/agents/commands.js +7 -1
- package/dist/agents/index.d.ts +1 -1
- package/dist/agents/index.js +1 -1
- package/dist/agents/input.d.ts +3 -1
- package/dist/agents/input.js +6 -0
- package/dist/agents/output/format.d.ts +2 -2
- package/dist/agents/output/format.js +8 -0
- package/dist/agents/tree/tree.js +13 -1
- package/dist/bin/maia.cdx.json +19 -19
- package/dist/bin/maia.mjs +1 -1
- package/dist/bootstrap/run.js +5 -2
- package/dist/cli/cli.d.ts +8 -2
- package/dist/cli/cli.js +25 -6
- package/dist/cli/index.d.ts +1 -1
- package/dist/cli/index.js +1 -1
- package/dist/command-line/context.d.ts +1 -0
- package/dist/command-line/index.d.ts +2 -2
- package/dist/command-line/index.js +2 -2
- package/dist/command-line/input/arguments.d.ts +7 -0
- package/dist/command-line/input/arguments.js +22 -10
- package/dist/command-line/input/index.d.ts +1 -1
- package/dist/command-line/input/index.js +1 -1
- package/dist/command-line/rows.d.ts +1 -0
- package/dist/command-line/rows.js +3 -0
- package/dist/command-receipt/command.js +1 -1
- package/dist/connection/access/client.d.ts +13 -0
- package/dist/connection/access/client.js +19 -0
- package/dist/connection/access/commands.d.ts +6 -0
- package/dist/connection/access/commands.js +60 -0
- package/dist/connection/access/format.d.ts +8 -0
- package/dist/connection/access/format.js +61 -0
- package/dist/connection/access/index.d.ts +3 -0
- package/dist/connection/access/index.js +3 -0
- package/dist/connection/access/input.d.ts +53 -0
- package/dist/connection/access/input.js +83 -0
- package/dist/connection/client.d.ts +6 -0
- package/dist/connection/client.js +2 -0
- package/dist/connection/index.d.ts +1 -0
- package/dist/connection/index.js +1 -0
- package/dist/connection/tree/tree.js +45 -7
- package/dist/local-node/client.d.ts +1 -0
- package/dist/local-node/client.js +1 -0
- package/dist/local-node/index.d.ts +2 -1
- package/dist/local-node/index.js +2 -1
- package/dist/local-node/wait.d.ts +10 -0
- package/dist/local-node/wait.js +17 -0
- package/dist/mcp/calls.js +2 -1
- package/dist/reference/resolve.js +9 -2
- package/dist/remote-node/connector.js +8 -1
- package/dist/session/agent-permission.d.ts +2 -2
- package/dist/session/approval/commands.js +7 -3
- package/dist/session/client.d.ts +10 -3
- package/dist/session/client.js +14 -2
- package/dist/session/commands.d.ts +1 -0
- package/dist/session/commands.js +45 -5
- package/dist/session/index.d.ts +1 -1
- package/dist/session/index.js +1 -1
- package/dist/session/output/human.d.ts +1 -0
- package/dist/session/output/human.js +4 -3
- package/dist/session/output/index.d.ts +1 -1
- package/dist/session/output/index.js +1 -1
- package/dist/session/tree/tree.js +12 -1
- package/dist/session/turn/client.js +7 -9
- package/dist/session/turn/commands.js +1 -6
- package/dist/status/client.d.ts +6 -1
- package/dist/status/command.js +3 -1
- package/dist/status/doctor.d.ts +5 -1
- package/dist/status/doctor.js +10 -4
- package/dist/status/output/compact.d.ts +1 -0
- package/dist/status/output/compact.js +3 -0
- package/dist/status/output/human.js +10 -0
- package/dist/terminal/control-commands.js +26 -9
- package/dist/terminal/keys.d.ts +12 -0
- package/dist/terminal/keys.js +62 -0
- package/dist/terminal/output/compact-list.d.ts +1 -0
- package/dist/terminal/output/compact-list.js +3 -0
- package/dist/terminal/output/human.js +2 -2
- package/dist/terminal/tree/tree.js +1 -1
- package/guidance/maia-cli/SKILL.md +1 -1
- package/guidance/maia-node/SKILL.md +54 -0
- package/guidance/maia-orchestration/SKILL.md +1 -2
- package/guidance/maia-sessions/SKILL.md +69 -0
- package/package.json +6 -6
|
@@ -0,0 +1,83 @@
|
|
|
1
|
+
import * as Effect from "effect/Effect";
|
|
2
|
+
import { CliArgumentError, parseOptions, readPageSize, requirePositionals, } from "../../command-line/index.js";
|
|
3
|
+
import { commandIdentifier } from "../../local-node/index.js";
|
|
4
|
+
const SCOPE_OPTIONS = ["--container", "--project"];
|
|
5
|
+
const isMode = (value) => value === "off" || value === "rotate" || value === "single";
|
|
6
|
+
const isState = (value) => value === "active" || value === "revoked";
|
|
7
|
+
const readScope = (options) => {
|
|
8
|
+
const project = options.get("--project");
|
|
9
|
+
const container = options.get("--container");
|
|
10
|
+
if (project !== undefined && container !== undefined)
|
|
11
|
+
throw new CliArgumentError("Use one of '--project' or '--container'.");
|
|
12
|
+
if (project !== undefined)
|
|
13
|
+
return { id: project, kind: "project" };
|
|
14
|
+
return container === undefined
|
|
15
|
+
? undefined
|
|
16
|
+
: { id: container, kind: "workspace" };
|
|
17
|
+
};
|
|
18
|
+
const requireScope = (options) => {
|
|
19
|
+
const scope = readScope(options);
|
|
20
|
+
if (scope === undefined)
|
|
21
|
+
throw new CliArgumentError("Use one of '--project' or '--container'.");
|
|
22
|
+
return scope;
|
|
23
|
+
};
|
|
24
|
+
const readPage = (options) => {
|
|
25
|
+
const afterCursor = options.get("--after");
|
|
26
|
+
return {
|
|
27
|
+
...(afterCursor === undefined ? {} : { afterCursor }),
|
|
28
|
+
limit: readPageSize(options.get("--limit")),
|
|
29
|
+
};
|
|
30
|
+
};
|
|
31
|
+
const withScope = (scope) => scope === undefined ? {} : { scope };
|
|
32
|
+
export const readGrantList = (tokens) => {
|
|
33
|
+
const parsed = parseOptions(tokens, new Set([
|
|
34
|
+
...SCOPE_OPTIONS,
|
|
35
|
+
"--after",
|
|
36
|
+
"--connection",
|
|
37
|
+
"--limit",
|
|
38
|
+
"--state",
|
|
39
|
+
]));
|
|
40
|
+
requirePositionals(parsed.positionals, 0);
|
|
41
|
+
const connectionId = parsed.options.get("--connection");
|
|
42
|
+
const state = parsed.options.get("--state");
|
|
43
|
+
if (state !== undefined && !isState(state))
|
|
44
|
+
throw new CliArgumentError("Option '--state' must be 'active' or 'revoked'.");
|
|
45
|
+
return {
|
|
46
|
+
...readPage(parsed.options),
|
|
47
|
+
...(connectionId === undefined ? {} : { connectionId }),
|
|
48
|
+
...withScope(readScope(parsed.options)),
|
|
49
|
+
...(state === undefined ? {} : { state }),
|
|
50
|
+
};
|
|
51
|
+
};
|
|
52
|
+
export const readPoolList = (tokens) => {
|
|
53
|
+
const parsed = parseOptions(tokens, new Set([...SCOPE_OPTIONS, "--after", "--limit"]));
|
|
54
|
+
requirePositionals(parsed.positionals, 0);
|
|
55
|
+
return {
|
|
56
|
+
...readPage(parsed.options),
|
|
57
|
+
...withScope(readScope(parsed.options)),
|
|
58
|
+
};
|
|
59
|
+
};
|
|
60
|
+
export const GRANT_SET_OPTIONS = new Set([
|
|
61
|
+
...SCOPE_OPTIONS,
|
|
62
|
+
"--command-id",
|
|
63
|
+
]);
|
|
64
|
+
export const readGrantPreview = (parsed) => {
|
|
65
|
+
requirePositionals(parsed.positionals, 1);
|
|
66
|
+
const scope = requireScope(parsed.options);
|
|
67
|
+
const connectionId = parsed.positionals[0] ?? "";
|
|
68
|
+
const granted = !parsed.flags.has("--revoke");
|
|
69
|
+
return Effect.map(commandIdentifier(parsed.options.get("--command-id")), (commandId) => ({ commandId, connectionId, granted, scope }));
|
|
70
|
+
};
|
|
71
|
+
export const POOL_SET_OPTIONS = new Set([
|
|
72
|
+
...SCOPE_OPTIONS,
|
|
73
|
+
"--command-id",
|
|
74
|
+
"--mode",
|
|
75
|
+
]);
|
|
76
|
+
export const readPoolPreview = (parsed) => {
|
|
77
|
+
const scope = requireScope(parsed.options);
|
|
78
|
+
const mode = parsed.options.get("--mode") ?? "";
|
|
79
|
+
if (!isMode(mode))
|
|
80
|
+
throw new CliArgumentError("Option '--mode' must be 'off', 'rotate' or 'single'.");
|
|
81
|
+
return Effect.map(commandIdentifier(parsed.options.get("--command-id")), (commandId) => ({ commandId, members: parsed.positionals, mode, scope }));
|
|
82
|
+
};
|
|
83
|
+
//# sourceMappingURL=input.js.map
|
|
@@ -1,6 +1,12 @@
|
|
|
1
1
|
import { type ConnectionCapacitySetParameters, type ConnectionCreateParameters, type ConnectionDetectParameters, type ConnectionGatewayCreateParameters, type ConnectionListParameters, type ConnectionLoginStartParameters, type ConnectionModelsListParameters, type ConnectionShowParameters, type ConnectionStateSetParameters, type ConnectionSystemConfirmParameters, type ConnectionSystemPreviewParameters, type ConnectionUpkeepConfirmParameters, type ConnectionUpkeepPreviewParameters, type ConnectionUpkeepRefreshParameters, type ConnectionUsageShowParameters } from "@maiaos/sdk";
|
|
2
2
|
import type { CliNodeOperations } from "../local-node/index.js";
|
|
3
3
|
export declare const makeConnectionClient: (node: CliNodeOperations) => {
|
|
4
|
+
confirmConnectionGrant: import("./access/client.js").Operation<import("@maiaos/sdk").ConnectionGrantSetConfirmParameters, import("@maiaos/sdk").ConnectionGrantSetConfirmResult>;
|
|
5
|
+
confirmConnectionPool: import("./access/client.js").Operation<import("@maiaos/sdk").ConnectionPoolSetConfirmParameters, import("@maiaos/sdk").ConnectionPoolSetConfirmResult>;
|
|
6
|
+
listConnectionGrants: import("./access/client.js").Operation<import("@maiaos/sdk").ConnectionGrantListParameters, import("@maiaos/sdk").ConnectionGrantListResult>;
|
|
7
|
+
listConnectionPools: import("./access/client.js").Operation<import("@maiaos/sdk").ConnectionPoolListParameters, import("@maiaos/sdk").ConnectionPoolListResult>;
|
|
8
|
+
previewConnectionGrant: import("./access/client.js").Operation<import("@maiaos/sdk").ConnectionGrantSetPreviewParameters, import("@maiaos/sdk").ConnectionGrantSetPreviewResult>;
|
|
9
|
+
previewConnectionPool: import("./access/client.js").Operation<import("@maiaos/sdk").ConnectionPoolSetPreviewParameters, import("@maiaos/sdk").ConnectionPoolSetPreviewResult>;
|
|
4
10
|
listConnectionModels: (input: ConnectionModelsListParameters) => import("../local-node/client.js").CliNodeEffect<{
|
|
5
11
|
readonly connectionId: string;
|
|
6
12
|
readonly format: "anthropic" | "openai";
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { connectionCapacitySetParametersSchema, connectionCreateParametersSchema, connectionDetectParametersSchema, connectionGatewayCreateParametersSchema, connectionListParametersSchema, connectionLoginStartParametersSchema, connectionModelsListParametersSchema, connectionShowParametersSchema, connectionStateSetParametersSchema, connectionSystemConfirmParametersSchema, connectionSystemPreviewParametersSchema, connectionUpkeepConfirmParametersSchema, connectionUpkeepPreviewParametersSchema, connectionUpkeepRefreshParametersSchema, connectionUsageShowParametersSchema, } from "@maiaos/sdk";
|
|
2
|
+
import { makeConnectionAccessClient } from "./access/index.js";
|
|
2
3
|
const readClient = (node) => ({
|
|
3
4
|
listConnectionModels: (input) => node.runValidatedNodeOperation(input, connectionModelsListParametersSchema, (client, parameters, options) => client.listConnectionModels(parameters, options)),
|
|
4
5
|
listConnections: (input) => node.runValidatedNodeOperation(input, connectionListParametersSchema, (client, parameters, options) => client.listConnections(parameters, options)),
|
|
@@ -25,6 +26,7 @@ const upkeepClient = (node) => ({
|
|
|
25
26
|
refreshConnectionUpkeep: (input) => node.runValidatedNodeOperation(input, connectionUpkeepRefreshParametersSchema, (client, parameters, options) => client.refreshConnectionUpkeep(parameters, options)),
|
|
26
27
|
});
|
|
27
28
|
export const makeConnectionClient = (node) => ({
|
|
29
|
+
...makeConnectionAccessClient(node),
|
|
28
30
|
...readClient(node),
|
|
29
31
|
...mutationClient(node),
|
|
30
32
|
...signInClient(node),
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
export { runConnectionGrantList, runConnectionGrantSet, runConnectionPoolList, runConnectionPoolSet, } from "./access/index.js";
|
|
1
2
|
export { type ConnectionCliDependencies, makeConnectionClient, } from "./client.js";
|
|
2
3
|
export { runConnectionCapacitySet, runConnectionCreate, runConnectionDisable, runConnectionEnable, runConnectionList, runConnectionLoginStart, runConnectionModelsList, runConnectionShow, runConnectionUsageShow, type VendorLogin, } from "./commands.js";
|
|
3
4
|
export { runVendorLogin } from "./login.js";
|
package/dist/connection/index.js
CHANGED
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
export { runConnectionGrantList, runConnectionGrantSet, runConnectionPoolList, runConnectionPoolSet, } from "./access/index.js";
|
|
1
2
|
export { makeConnectionClient, } from "./client.js";
|
|
2
3
|
export { runConnectionCapacitySet, runConnectionCreate, runConnectionDisable, runConnectionEnable, runConnectionList, runConnectionLoginStart, runConnectionModelsList, runConnectionShow, runConnectionUsageShow, } from "./commands.js";
|
|
3
4
|
export { runVendorLogin } from "./login.js";
|
|
@@ -10,7 +10,9 @@ export const CONNECTION_TREE = {
|
|
|
10
10
|
["connection usage", "A Connection's usage."],
|
|
11
11
|
["connection models", "Models a Connection offers."],
|
|
12
12
|
["connection capacity", "A Connection's Session limit."],
|
|
13
|
-
["connection
|
|
13
|
+
["connection grant", "Grants."],
|
|
14
|
+
["connection pool", "Pools."],
|
|
15
|
+
["connection update-policy", "Vendor CLI update proposals."],
|
|
14
16
|
["integration", "Approve vendor executables."],
|
|
15
17
|
["integration plan", "Plan approving a vendor executable."],
|
|
16
18
|
["integration status", "A vendor integration's status."],
|
|
@@ -24,7 +26,7 @@ export const CONNECTION_TREE = {
|
|
|
24
26
|
"setup [--max-sessions <1..16>] [--command-id <id>] [--dry-run | --confirm-stdin | --yes]",
|
|
25
27
|
1,
|
|
26
28
|
["connection.system.preview", "connection.system.confirm"],
|
|
27
|
-
"Use
|
|
29
|
+
"Use installed vendor CLIs as system-default accounts.",
|
|
28
30
|
{
|
|
29
31
|
example: "maia setup --max-sessions 4",
|
|
30
32
|
kind: "two-phase",
|
|
@@ -60,7 +62,7 @@ export const CONNECTION_TREE = {
|
|
|
60
62
|
"login gateway --name <name> --base-url <url> --api-key-stdin [--max-sessions <1..16>] [--command-id <id>]",
|
|
61
63
|
1,
|
|
62
64
|
"connection.gateway.create",
|
|
63
|
-
"Add
|
|
65
|
+
"Add a gateway Connection with its API key.",
|
|
64
66
|
{ run: [login, "runLoginGateway"] },
|
|
65
67
|
],
|
|
66
68
|
[
|
|
@@ -91,7 +93,7 @@ export const CONNECTION_TREE = {
|
|
|
91
93
|
"connection detect [--refresh]",
|
|
92
94
|
1,
|
|
93
95
|
["connection.detect", "connection.upkeep.refresh"],
|
|
94
|
-
"Detect
|
|
96
|
+
"Detect installed vendor CLIs and newer versions.",
|
|
95
97
|
{
|
|
96
98
|
example: "maia --json connection detect --refresh",
|
|
97
99
|
kind: "composite",
|
|
@@ -102,7 +104,7 @@ export const CONNECTION_TREE = {
|
|
|
102
104
|
"connection update-policy set <claude-code|codex-cli> <off|notify> [--command-id <id>] [--dry-run | --confirm-stdin | --yes]",
|
|
103
105
|
1,
|
|
104
106
|
["connection.upkeep.preview", "connection.upkeep.confirm"],
|
|
105
|
-
"
|
|
107
|
+
"Set a vendor CLI's update policy.",
|
|
106
108
|
{
|
|
107
109
|
example: "maia connection update-policy set codex-cli off",
|
|
108
110
|
kind: "two-phase",
|
|
@@ -113,7 +115,7 @@ export const CONNECTION_TREE = {
|
|
|
113
115
|
"connection login start <connection> [--device-code] [--command-id <id>]",
|
|
114
116
|
1,
|
|
115
117
|
"connection.login.start",
|
|
116
|
-
"Start a Node-side sign-in
|
|
118
|
+
"Start a Node-side sign-in.",
|
|
117
119
|
{ run: [connection, "runConnectionLoginStart"] },
|
|
118
120
|
],
|
|
119
121
|
[
|
|
@@ -127,7 +129,7 @@ export const CONNECTION_TREE = {
|
|
|
127
129
|
"connection models list --connection <connection>",
|
|
128
130
|
1,
|
|
129
131
|
"connection.models.list",
|
|
130
|
-
"List
|
|
132
|
+
"List a Connection's models.",
|
|
131
133
|
{ run: [connection, "runConnectionModelsList"] },
|
|
132
134
|
],
|
|
133
135
|
[
|
|
@@ -137,6 +139,42 @@ export const CONNECTION_TREE = {
|
|
|
137
139
|
"Set a Connection's Session limit.",
|
|
138
140
|
{ run: [connection, "runConnectionCapacitySet"] },
|
|
139
141
|
],
|
|
142
|
+
[
|
|
143
|
+
"connection grant list [--connection <connection>] [--project <project-id> | --container <container-id>] [--state <active|revoked>] [--limit <1..100>] [--after <cursor>]",
|
|
144
|
+
1,
|
|
145
|
+
"connection.grant.list",
|
|
146
|
+
"List grants.",
|
|
147
|
+
{ run: [connection, "runConnectionGrantList"] },
|
|
148
|
+
],
|
|
149
|
+
[
|
|
150
|
+
"connection grant set <connection> (--project <project-id> | --container <container-id> | --confirm-stdin) [--revoke] [--command-id <id>] [--dry-run]",
|
|
151
|
+
1,
|
|
152
|
+
["connection.grant.set.preview", "connection.grant.set.confirm"],
|
|
153
|
+
"Grant or revoke a Connection.",
|
|
154
|
+
{
|
|
155
|
+
example: "maia connection grant set claude-a --project maiaos",
|
|
156
|
+
kind: "two-phase",
|
|
157
|
+
run: [connection, "runConnectionGrantSet"],
|
|
158
|
+
},
|
|
159
|
+
],
|
|
160
|
+
[
|
|
161
|
+
"connection pool list [--project <project-id> | --container <container-id>] [--limit <1..100>] [--after <cursor>]",
|
|
162
|
+
1,
|
|
163
|
+
"connection.pool.list",
|
|
164
|
+
"List pools.",
|
|
165
|
+
{ run: [connection, "runConnectionPoolList"] },
|
|
166
|
+
],
|
|
167
|
+
[
|
|
168
|
+
"connection pool set (--project <project-id> | --container <container-id> | --confirm-stdin) --mode <off|rotate|single> [<connection>...] [--command-id <id>] [--dry-run]",
|
|
169
|
+
1,
|
|
170
|
+
["connection.pool.set.preview", "connection.pool.set.confirm"],
|
|
171
|
+
"Pin, rotate or clear a pool.",
|
|
172
|
+
{
|
|
173
|
+
example: "maia connection pool set --project maiaos --mode rotate claude-a claude-b",
|
|
174
|
+
kind: "two-phase",
|
|
175
|
+
run: [connection, "runConnectionPoolSet"],
|
|
176
|
+
},
|
|
177
|
+
],
|
|
140
178
|
[
|
|
141
179
|
"connection enable <connection> --expected-revision <revision> [--command-id <id>]",
|
|
142
180
|
1,
|
|
@@ -22,6 +22,7 @@ export declare const newCliIdentifier: (prefix: "command" | "request") => Effect
|
|
|
22
22
|
export declare const commandIdentifier: (commandId: string | undefined) => Effect.Effect<string, never, Crypto.Crypto>;
|
|
23
23
|
export declare const fillCommandIdentifier: (input: unknown) => Effect.Effect<unknown, never, Crypto.Crypto>;
|
|
24
24
|
export declare const connectLocalNode: CliNodeConnector;
|
|
25
|
+
export declare const holdsSessionCredential: Effect.Effect<boolean>;
|
|
25
26
|
export declare const outcomeCanBeAmbiguous: (error: unknown) => boolean;
|
|
26
27
|
export declare const invalidNodeInput: <TValue>(schemaError?: unknown) => Effect.Effect<CliNodeResult<TValue>>;
|
|
27
28
|
export type ParameterSchema<TParameters> = {
|
|
@@ -70,6 +70,7 @@ const sessionAttachmentDenied = () => new CliLocalNodeError({
|
|
|
70
70
|
retryable: false,
|
|
71
71
|
},
|
|
72
72
|
});
|
|
73
|
+
export const holdsSessionCredential = Effect.map(Config.option(Config.String(SESSION_CREDENTIAL_VARIABLE)), Option.isSome).pipe(Effect.orElseSucceed(() => false));
|
|
73
74
|
const sessionLaunch = Effect.gen(function* () {
|
|
74
75
|
const credential = yield* Config.option(Config.String(SESSION_CREDENTIAL_VARIABLE));
|
|
75
76
|
const origin = yield* Config.option(Config.String(SESSION_NODE_ORIGIN_VARIABLE));
|
|
@@ -1,3 +1,4 @@
|
|
|
1
1
|
export { type CliNodeCall, makeCallClient } from "./call.js";
|
|
2
|
-
export { type CliMutationRecovery, type CliNodeBinding, type CliNodeConnection, type CliNodeConnector, type CliNodeEffect, type CliNodeOperations, type CliNodeOperationsOptions, type CliNodeResult, commandIdentifier, connectLocalNode, discoveryOptionsFor, fillCommandIdentifier, invalidNodeInput, makeCliNodeOperations, newCliIdentifier, outcomeCanBeAmbiguous, type ParameterSchema, retryBriefSaturation, runLazyNodeDependency, } from "./client.js";
|
|
2
|
+
export { type CliMutationRecovery, type CliNodeBinding, type CliNodeConnection, type CliNodeConnector, type CliNodeEffect, type CliNodeOperations, type CliNodeOperationsOptions, type CliNodeResult, commandIdentifier, connectLocalNode, discoveryOptionsFor, fillCommandIdentifier, holdsSessionCredential, invalidNodeInput, makeCliNodeOperations, newCliIdentifier, outcomeCanBeAmbiguous, type ParameterSchema, retryBriefSaturation, runLazyNodeDependency, } from "./client.js";
|
|
3
|
+
export { repeatBoundedWait } from "./wait.js";
|
|
3
4
|
//# sourceMappingURL=index.d.ts.map
|
package/dist/local-node/index.js
CHANGED
|
@@ -1,3 +1,4 @@
|
|
|
1
1
|
export { makeCallClient } from "./call.js";
|
|
2
|
-
export { commandIdentifier, connectLocalNode, discoveryOptionsFor, fillCommandIdentifier, invalidNodeInput, makeCliNodeOperations, newCliIdentifier, outcomeCanBeAmbiguous, retryBriefSaturation, runLazyNodeDependency, } from "./client.js";
|
|
2
|
+
export { commandIdentifier, connectLocalNode, discoveryOptionsFor, fillCommandIdentifier, holdsSessionCredential, invalidNodeInput, makeCliNodeOperations, newCliIdentifier, outcomeCanBeAmbiguous, retryBriefSaturation, runLazyNodeDependency, } from "./client.js";
|
|
3
|
+
export { repeatBoundedWait } from "./wait.js";
|
|
3
4
|
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import type { CliNodeEffect } from "./client.js";
|
|
2
|
+
type BoundedWait<TValue> = {
|
|
3
|
+
readonly maxRequestMilliseconds: number;
|
|
4
|
+
readonly once: (waitMilliseconds: number) => CliNodeEffect<TValue>;
|
|
5
|
+
readonly satisfied: (value: TValue) => boolean;
|
|
6
|
+
readonly timeoutMilliseconds: number;
|
|
7
|
+
};
|
|
8
|
+
export declare const repeatBoundedWait: <TValue>(input: BoundedWait<TValue>) => CliNodeEffect<TValue>;
|
|
9
|
+
export {};
|
|
10
|
+
//# sourceMappingURL=wait.d.ts.map
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import * as Clock from "effect/Clock";
|
|
2
|
+
import * as Effect from "effect/Effect";
|
|
3
|
+
const monotonicMilliseconds = Effect.map(Clock.monotonicTimeNanos, (nanos) => Number(nanos / 1000000n));
|
|
4
|
+
export const repeatBoundedWait = (input) => Effect.gen(function* () {
|
|
5
|
+
const deadline = (yield* monotonicMilliseconds) + input.timeoutMilliseconds;
|
|
6
|
+
const next = () => Effect.gen(function* () {
|
|
7
|
+
const remaining = deadline - (yield* monotonicMilliseconds);
|
|
8
|
+
const result = yield* input.once(Math.max(0, Math.min(input.maxRequestMilliseconds, remaining)));
|
|
9
|
+
if (!result.ok || input.satisfied(result.value))
|
|
10
|
+
return result;
|
|
11
|
+
return (yield* monotonicMilliseconds) >= deadline
|
|
12
|
+
? result
|
|
13
|
+
: yield* next();
|
|
14
|
+
});
|
|
15
|
+
return yield* next();
|
|
16
|
+
});
|
|
17
|
+
//# sourceMappingURL=wait.js.map
|
package/dist/mcp/calls.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { agentsListParametersSchema, agentsShowParametersSchema, approvalListParametersSchema, approvalShowParametersSchema, connectionDetectParametersSchema, connectionListParametersSchema, connectionModelsListParametersSchema, connectionShowParametersSchema, connectionUsageShowParametersSchema, containerIndexListParametersSchema, COORDINATOR_TOOL_OPERATIONS, discoverySessionsListParametersSchema, invocationContextShowParametersSchema, LOCAL_NODE_CALL_METHODS, localNodeRequestPayloadSchema, portLeaseAcquireParametersSchema, portLeaseListParametersSchema, portLeaseReleaseParametersSchema, portLeaseRenewParametersSchema, projectGuardShowParametersSchema, projectListParametersSchema, projectShowParametersSchema, receiptGetParametersSchema, routineListParametersSchema, routineShowParametersSchema, runLedgerCreateParametersSchema, runLedgerListParametersSchema, runLedgerTaskDispatchParametersSchema, runLedgerTaskListParametersSchema, runLedgerTaskSettleParametersSchema, runLedgerTaskShowParametersSchema, sessionArchiveParametersSchema, sessionCreateParametersSchema, sessionDiffParametersSchema, sessionEventsListParametersSchema, sessionHistoryReadParametersSchema, sessionInboxAckParametersSchema, sessionInboxCheckParametersSchema, sessionListParametersSchema, sessionMessageSendParametersSchema, sessionObserveParametersSchema, sessionResumeParametersSchema, sessionShowParametersSchema, sessionStartParametersSchema, sessionStopParametersSchema, turnCancelParametersSchema, turnInterruptParametersSchema, turnQueueListParametersSchema, turnSendParametersSchema, turnShowParametersSchema, turnWaitParametersSchema, workerToolDefinitions, workspaceListParametersSchema, workspaceShowParametersSchema, } from "@maiaos/sdk";
|
|
1
|
+
import { agentsListParametersSchema, agentsShowParametersSchema, approvalListParametersSchema, approvalRespondParametersSchema, approvalShowParametersSchema, connectionDetectParametersSchema, connectionListParametersSchema, connectionModelsListParametersSchema, connectionShowParametersSchema, connectionUsageShowParametersSchema, containerIndexListParametersSchema, COORDINATOR_TOOL_OPERATIONS, discoverySessionsListParametersSchema, invocationContextShowParametersSchema, LOCAL_NODE_CALL_METHODS, localNodeRequestPayloadSchema, portLeaseAcquireParametersSchema, portLeaseListParametersSchema, portLeaseReleaseParametersSchema, portLeaseRenewParametersSchema, projectGuardShowParametersSchema, projectListParametersSchema, projectShowParametersSchema, receiptGetParametersSchema, routineListParametersSchema, routineShowParametersSchema, runLedgerCreateParametersSchema, runLedgerListParametersSchema, runLedgerTaskDispatchParametersSchema, runLedgerTaskListParametersSchema, runLedgerTaskSettleParametersSchema, runLedgerTaskShowParametersSchema, sessionArchiveParametersSchema, sessionCreateParametersSchema, sessionDiffParametersSchema, sessionEventsListParametersSchema, sessionHistoryReadParametersSchema, sessionInboxAckParametersSchema, sessionInboxCheckParametersSchema, sessionListParametersSchema, sessionMessageSendParametersSchema, sessionObserveParametersSchema, sessionResumeParametersSchema, sessionShowParametersSchema, sessionStartParametersSchema, sessionStopParametersSchema, turnCancelParametersSchema, turnInterruptParametersSchema, turnQueueListParametersSchema, turnSendParametersSchema, turnShowParametersSchema, turnWaitParametersSchema, workerToolDefinitions, workspaceListParametersSchema, workspaceShowParametersSchema, } from "@maiaos/sdk";
|
|
2
2
|
import { Effect, Predicate } from "effect";
|
|
3
3
|
import { invalidNodeInput, } from "../local-node/index.js";
|
|
4
4
|
const recoveryOf = (input) => Predicate.hasProperty(input, "commandId") &&
|
|
@@ -222,6 +222,7 @@ export const callCoordinator = (node) => (operation, input) => {
|
|
|
222
222
|
export const WORKER_CALLS = (() => {
|
|
223
223
|
const available = new Map(COORDINATOR_CALLS);
|
|
224
224
|
available.set("context.show", validated(invocationContextShowParametersSchema, (client, parameters, options) => client.showCurrentContext(parameters, options)));
|
|
225
|
+
available.set("approval.respond", validated(approvalRespondParametersSchema, (client, parameters, options) => client.respondToApproval(parameters, options)));
|
|
225
226
|
available.set("session.inbox.ack", validated(sessionInboxAckParametersSchema, (client, parameters, options) => client.acknowledgeSessionDelivery(parameters, options)));
|
|
226
227
|
available.set("session.inbox.check", validated(sessionInboxCheckParametersSchema, (client, parameters, options) => client.checkSessionInbox(parameters, options)));
|
|
227
228
|
available.set("session.message.send", validated(sessionMessageSendParametersSchema, (client, parameters, options) => client.sendSessionMessage(parameters, options)));
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import * as Data from "effect/Data";
|
|
2
2
|
import * as Effect from "effect/Effect";
|
|
3
|
-
import { cell, CliArgumentError, LOCAL_NODE,
|
|
3
|
+
import { cell, CliArgumentError, LOCAL_NODE, parseOptionsWith, reportError, tokenizeArguments, } from "../command-line/index.js";
|
|
4
4
|
import { parseUsage, REFERENCE_PLACEHOLDER, } from "../command-tree/index.js";
|
|
5
5
|
class ReferenceRefused extends Data.TaggedError("ReferenceRefused") {
|
|
6
6
|
}
|
|
@@ -36,6 +36,9 @@ const grammarOf = (arguments_) => ({
|
|
|
36
36
|
: [])),
|
|
37
37
|
positionals: arguments_.filter((argument) => argument.name.startsWith("<")),
|
|
38
38
|
});
|
|
39
|
+
const repeatableOf = (arguments_) => new Set(arguments_.flatMap((argument) => argument.name.startsWith("--") && argument.value?.includes("...") === true
|
|
40
|
+
? [argument.name]
|
|
41
|
+
: []));
|
|
39
42
|
const slotOf = (grammar, position) => {
|
|
40
43
|
const { positionals } = grammar;
|
|
41
44
|
const last = positionals.at(-1);
|
|
@@ -87,7 +90,11 @@ const locate = (arguments_, tokens) => Effect.try({
|
|
|
87
90
|
const grammar = grammarOf(arguments_);
|
|
88
91
|
const valueOptions = new Set(grammar.options.keys());
|
|
89
92
|
const end = tokens.indexOf("--");
|
|
90
|
-
|
|
93
|
+
parseOptionsWith(end === -1 ? tokens : tokens.slice(0, end), {
|
|
94
|
+
allowed: valueOptions,
|
|
95
|
+
allowedFlags: flagsOf(arguments_),
|
|
96
|
+
repeatable: repeatableOf(arguments_),
|
|
97
|
+
});
|
|
91
98
|
const roles = tokenizeArguments(tokens, valueOptions);
|
|
92
99
|
const placements = placementsOf(grammar, tokens, roles);
|
|
93
100
|
return {
|
|
@@ -23,13 +23,20 @@ const unreachable = (name, reason) => new MaiaClientError("transport_failure", r
|
|
|
23
23
|
retryable: true,
|
|
24
24
|
},
|
|
25
25
|
});
|
|
26
|
+
const unknownNode = (name) => new MaiaClientError("transport_failure", "no Node has this name", {
|
|
27
|
+
remoteError: {
|
|
28
|
+
code: "invalid_argument",
|
|
29
|
+
message: `No Node is named '${name}'; see maia node list.`,
|
|
30
|
+
retryable: false,
|
|
31
|
+
},
|
|
32
|
+
});
|
|
26
33
|
export const readRemoteNode = (connector, options, name) => Effect.gen(function* () {
|
|
27
34
|
const local = yield* connector(options);
|
|
28
35
|
const messageId = yield* newCliIdentifier("request");
|
|
29
36
|
const listed = yield* local.client.listRemoteNodes({}, { messageId });
|
|
30
37
|
const node = listed.nodes.find((candidate) => candidate.name === name);
|
|
31
38
|
if (node === undefined)
|
|
32
|
-
return yield* Effect.fail(
|
|
39
|
+
return yield* Effect.fail(unknownNode(name));
|
|
33
40
|
return node;
|
|
34
41
|
});
|
|
35
42
|
const spawnBridge = (node) => ChildProcess.make("ssh", sshCommandArguments({
|
|
@@ -18,7 +18,7 @@ export declare const makeAgentPermissionCliClient: (node: CliNodeOperations) =>
|
|
|
18
18
|
readonly commandId: string;
|
|
19
19
|
readonly grantedAt: string;
|
|
20
20
|
readonly inputDigest: string;
|
|
21
|
-
readonly operationIds: readonly ("agents.change.confirm" | "agents.change.preview" | "agents.list" | "agents.show" | "approval.list" | "approval.respond" | "approval.show" | "connection.capacity.set" | "connection.create" | "connection.detect" | "connection.gateway.create" | "connection.list" | "connection.login.start" | "connection.models.list" | "connection.show" | "connection.state.set" | "connection.system.confirm" | "connection.system.preview" | "connection.upkeep.confirm" | "connection.upkeep.preview" | "connection.upkeep.refresh" | "connection.usage.show" | "container.create.confirm" | "container.create.preview" | "container.index.list" | "container.list" | "container.rename.confirm" | "container.rename.preview" | "container.show" | "context.show" | "discovery.sessions.list" | "execution.catalog.get" | "execution.checkpoint.create" | "execution.checkpoint.show" | "execution.command.run" | "execution.file.read" | "execution.placement.create" | "execution.placement.show" | "execution.relocation.apply" | "execution.relocation.plan" | "execution.relocation.reconcile" | "execution.relocation.show" | "execution.worktree.create" | "execution.worktree.import" | "execution.worktree.reconcile" | "execution.worktree.remove.apply" | "execution.worktree.remove.plan" | "execution.worktree.status" | "harness.installed.list" | "hold.list" | "hold.place.confirm" | "hold.place.preview" | "hold.release.confirm" | "hold.release.preview" | "integration.apply.claude-code" | "integration.apply.codex" | "integration.apply.pi-rpc" | "integration.plan.claude-code" | "integration.plan.codex" | "integration.plan.pi-rpc" | "integration.remove.claude-code" | "integration.remove.codex" | "integration.remove.pi-rpc" | "integration.status.claude-code" | "integration.status.codex" | "integration.status.pi-rpc" | "interaction.cancel" | "interaction.create" | "interaction.list" | "interaction.respond" | "interaction.show" | "monitor.bootstrap.create" | "node.remote.install.confirm" | "node.remote.install.preview" | "node.remote.list" | "node.remote.register.confirm" | "node.remote.register.preview" | "node.remote.remove.confirm" | "node.remote.remove.preview" | "node.shutdown" | "node.status" | "port.lease.acquire" | "port.lease.list" | "port.lease.release" | "port.lease.renew" | "presentation.catalog.show" | "presentation.project-list.show" | "presentation.session-list.show" | "presentation.workspace-directory.show" | "project.context.list" | "project.context.record" | "project.context.show" | "project.create.confirm" | "project.create.preview" | "project.guard.confirm" | "project.guard.preview" | "project.guard.show" | "project.list" | "project.register" | "project.rename.confirm" | "project.rename.preview" | "project.show" | "provider.pool.list" | "receipt.get" | "receipt.list" | "reference.resolve" | "routine.create.confirm" | "routine.create.preview" | "routine.disable.confirm" | "routine.disable.preview" | "routine.list" | "routine.pause" | "routine.resume" | "routine.run.confirm" | "routine.run.preview" | "routine.show" | "run.create" | "run.dispatch.settle-terminal" | "run.dispatch.show" | "run.inbox.ack" | "run.inbox.check" | "run.ledger.create" | "run.ledger.list" | "run.ledger.task.dispatch" | "run.ledger.task.list" | "run.ledger.task.settle" | "run.ledger.task.show" | "run.list" | "run.question.cancel" | "run.question.open" | "run.question.reply" | "run.show" | "run.task.list" | "run.task.show" | "runtime.probe" | "session.adopt.confirm" | "session.adopt.preview" | "session.agent-permission.confirm" | "session.agent-permission.preview" | "session.archive" | "session.create" | "session.diff" | "session.events.list" | "session.history.read" | "session.inbox.ack" | "session.inbox.check" | "session.list" | "session.message.send" | "session.observe" | "session.rename" | "session.resume" | "session.show" | "session.spawn" | "session.start" | "session.stop" | "team-workspace.bootstrap.apply" | "team-workspace.bootstrap.preview" | "terminal.controller.acquire" | "terminal.controller.release" | "terminal.controller.renew" | "terminal.controller.request" | "terminal.controller.request.show" | "terminal.create" | "terminal.events.list" | "terminal.input.write" | "terminal.list" | "terminal.mutation.reconcile" | "terminal.observer.attach" | "terminal.observer.check" | "terminal.observer.detach" | "terminal.observer.resync" | "terminal.read" | "terminal.session.close" | "terminal.session.delete" | "terminal.session.resize" | "terminal.session.restart" | "terminal.session.signal" | "terminal.show" | "turn.cancel" | "turn.interrupt" | "turn.queue.list" | "turn.send" | "turn.show" | "turn.wait" | "voice.managed-turn.confirm" | "voice.managed-turn.preview" | "voice.orchestrator.context.show" | "voice.orchestrator.tool.call" | "voice.pi.relay" | "voice.pi.relay.preview" | "voice.pi.relay.reconcile" | "workspace.context.show" | "workspace.execution.configure" | "workspace.execution.show" | "workspace.list" | "workspace.membership.attach" | "workspace.repository.attach" | "workspace.select" | "workspace.show")[];
|
|
21
|
+
readonly operationIds: readonly ("agents.change.confirm" | "agents.change.preview" | "agents.detect" | "agents.list" | "agents.show" | "approval.list" | "approval.respond" | "approval.show" | "connection.capacity.set" | "connection.create" | "connection.detect" | "connection.gateway.create" | "connection.grant.list" | "connection.grant.set.confirm" | "connection.grant.set.preview" | "connection.list" | "connection.login.start" | "connection.models.list" | "connection.pool.list" | "connection.pool.set.confirm" | "connection.pool.set.preview" | "connection.show" | "connection.state.set" | "connection.system.confirm" | "connection.system.preview" | "connection.upkeep.confirm" | "connection.upkeep.preview" | "connection.upkeep.refresh" | "connection.usage.show" | "container.create.confirm" | "container.create.preview" | "container.index.list" | "container.list" | "container.rename.confirm" | "container.rename.preview" | "container.show" | "context.show" | "discovery.sessions.list" | "events.read" | "execution.catalog.get" | "execution.checkpoint.create" | "execution.checkpoint.show" | "execution.command.run" | "execution.file.read" | "execution.placement.create" | "execution.placement.show" | "execution.relocation.apply" | "execution.relocation.plan" | "execution.relocation.reconcile" | "execution.relocation.show" | "execution.worktree.create" | "execution.worktree.import" | "execution.worktree.reconcile" | "execution.worktree.remove.apply" | "execution.worktree.remove.plan" | "execution.worktree.status" | "harness.installed.list" | "hold.list" | "hold.place.confirm" | "hold.place.preview" | "hold.release.confirm" | "hold.release.preview" | "integration.apply.claude-code" | "integration.apply.codex" | "integration.apply.pi-rpc" | "integration.plan.claude-code" | "integration.plan.codex" | "integration.plan.pi-rpc" | "integration.remove.claude-code" | "integration.remove.codex" | "integration.remove.pi-rpc" | "integration.status.claude-code" | "integration.status.codex" | "integration.status.pi-rpc" | "interaction.cancel" | "interaction.create" | "interaction.list" | "interaction.respond" | "interaction.show" | "monitor.bootstrap.create" | "node.remote.install.confirm" | "node.remote.install.preview" | "node.remote.list" | "node.remote.register.confirm" | "node.remote.register.preview" | "node.remote.remove.confirm" | "node.remote.remove.preview" | "node.shutdown" | "node.status" | "port.lease.acquire" | "port.lease.list" | "port.lease.release" | "port.lease.renew" | "presentation.catalog.show" | "presentation.project-list.show" | "presentation.session-list.show" | "presentation.workspace-directory.show" | "project.context.list" | "project.context.record" | "project.context.show" | "project.create.confirm" | "project.create.preview" | "project.guard.confirm" | "project.guard.preview" | "project.guard.show" | "project.list" | "project.register" | "project.rename.confirm" | "project.rename.preview" | "project.show" | "provider.pool.list" | "receipt.get" | "receipt.list" | "reference.resolve" | "routine.create.confirm" | "routine.create.preview" | "routine.disable.confirm" | "routine.disable.preview" | "routine.list" | "routine.pause" | "routine.resume" | "routine.run.confirm" | "routine.run.preview" | "routine.show" | "run.create" | "run.dispatch.settle-terminal" | "run.dispatch.show" | "run.inbox.ack" | "run.inbox.check" | "run.ledger.create" | "run.ledger.list" | "run.ledger.task.dispatch" | "run.ledger.task.list" | "run.ledger.task.settle" | "run.ledger.task.show" | "run.list" | "run.question.cancel" | "run.question.open" | "run.question.reply" | "run.show" | "run.task.list" | "run.task.show" | "runtime.probe" | "session.adopt.confirm" | "session.adopt.preview" | "session.agent-permission.confirm" | "session.agent-permission.preview" | "session.archive" | "session.create" | "session.diff" | "session.events.list" | "session.history.read" | "session.inbox.ack" | "session.inbox.check" | "session.list" | "session.message.send" | "session.observe" | "session.rename" | "session.resume" | "session.show" | "session.spawn" | "session.start" | "session.stop" | "session.wait" | "team-workspace.bootstrap.apply" | "team-workspace.bootstrap.preview" | "terminal.controller.acquire" | "terminal.controller.release" | "terminal.controller.renew" | "terminal.controller.request" | "terminal.controller.request.show" | "terminal.create" | "terminal.events.list" | "terminal.input.write" | "terminal.list" | "terminal.mutation.reconcile" | "terminal.observer.attach" | "terminal.observer.check" | "terminal.observer.detach" | "terminal.observer.resync" | "terminal.read" | "terminal.session.close" | "terminal.session.delete" | "terminal.session.resize" | "terminal.session.restart" | "terminal.session.signal" | "terminal.show" | "turn.cancel" | "turn.interrupt" | "turn.queue.list" | "turn.send" | "turn.show" | "turn.wait" | "voice.managed-turn.confirm" | "voice.managed-turn.preview" | "voice.orchestrator.context.show" | "voice.orchestrator.tool.call" | "voice.pi.relay" | "voice.pi.relay.preview" | "voice.pi.relay.reconcile" | "workspace.context.show" | "workspace.execution.configure" | "workspace.execution.show" | "workspace.list" | "workspace.membership.attach" | "workspace.repository.attach" | "workspace.select" | "workspace.show")[];
|
|
22
22
|
readonly revision: "1";
|
|
23
23
|
};
|
|
24
24
|
readonly method: "session.agent-permission.confirm";
|
|
@@ -55,7 +55,7 @@ export declare const makeAgentPermissionCliClient: (node: CliNodeOperations) =>
|
|
|
55
55
|
readonly inputDigest: string;
|
|
56
56
|
readonly issuedAt: string;
|
|
57
57
|
readonly method: "session.agent-permission.preview";
|
|
58
|
-
readonly operationIds: readonly ("agents.change.confirm" | "agents.change.preview" | "agents.list" | "agents.show" | "approval.list" | "approval.respond" | "approval.show" | "connection.capacity.set" | "connection.create" | "connection.detect" | "connection.gateway.create" | "connection.list" | "connection.login.start" | "connection.models.list" | "connection.show" | "connection.state.set" | "connection.system.confirm" | "connection.system.preview" | "connection.upkeep.confirm" | "connection.upkeep.preview" | "connection.upkeep.refresh" | "connection.usage.show" | "container.create.confirm" | "container.create.preview" | "container.index.list" | "container.list" | "container.rename.confirm" | "container.rename.preview" | "container.show" | "context.show" | "discovery.sessions.list" | "execution.catalog.get" | "execution.checkpoint.create" | "execution.checkpoint.show" | "execution.command.run" | "execution.file.read" | "execution.placement.create" | "execution.placement.show" | "execution.relocation.apply" | "execution.relocation.plan" | "execution.relocation.reconcile" | "execution.relocation.show" | "execution.worktree.create" | "execution.worktree.import" | "execution.worktree.reconcile" | "execution.worktree.remove.apply" | "execution.worktree.remove.plan" | "execution.worktree.status" | "harness.installed.list" | "hold.list" | "hold.place.confirm" | "hold.place.preview" | "hold.release.confirm" | "hold.release.preview" | "integration.apply.claude-code" | "integration.apply.codex" | "integration.apply.pi-rpc" | "integration.plan.claude-code" | "integration.plan.codex" | "integration.plan.pi-rpc" | "integration.remove.claude-code" | "integration.remove.codex" | "integration.remove.pi-rpc" | "integration.status.claude-code" | "integration.status.codex" | "integration.status.pi-rpc" | "interaction.cancel" | "interaction.create" | "interaction.list" | "interaction.respond" | "interaction.show" | "monitor.bootstrap.create" | "node.remote.install.confirm" | "node.remote.install.preview" | "node.remote.list" | "node.remote.register.confirm" | "node.remote.register.preview" | "node.remote.remove.confirm" | "node.remote.remove.preview" | "node.shutdown" | "node.status" | "port.lease.acquire" | "port.lease.list" | "port.lease.release" | "port.lease.renew" | "presentation.catalog.show" | "presentation.project-list.show" | "presentation.session-list.show" | "presentation.workspace-directory.show" | "project.context.list" | "project.context.record" | "project.context.show" | "project.create.confirm" | "project.create.preview" | "project.guard.confirm" | "project.guard.preview" | "project.guard.show" | "project.list" | "project.register" | "project.rename.confirm" | "project.rename.preview" | "project.show" | "provider.pool.list" | "receipt.get" | "receipt.list" | "reference.resolve" | "routine.create.confirm" | "routine.create.preview" | "routine.disable.confirm" | "routine.disable.preview" | "routine.list" | "routine.pause" | "routine.resume" | "routine.run.confirm" | "routine.run.preview" | "routine.show" | "run.create" | "run.dispatch.settle-terminal" | "run.dispatch.show" | "run.inbox.ack" | "run.inbox.check" | "run.ledger.create" | "run.ledger.list" | "run.ledger.task.dispatch" | "run.ledger.task.list" | "run.ledger.task.settle" | "run.ledger.task.show" | "run.list" | "run.question.cancel" | "run.question.open" | "run.question.reply" | "run.show" | "run.task.list" | "run.task.show" | "runtime.probe" | "session.adopt.confirm" | "session.adopt.preview" | "session.agent-permission.confirm" | "session.agent-permission.preview" | "session.archive" | "session.create" | "session.diff" | "session.events.list" | "session.history.read" | "session.inbox.ack" | "session.inbox.check" | "session.list" | "session.message.send" | "session.observe" | "session.rename" | "session.resume" | "session.show" | "session.spawn" | "session.start" | "session.stop" | "team-workspace.bootstrap.apply" | "team-workspace.bootstrap.preview" | "terminal.controller.acquire" | "terminal.controller.release" | "terminal.controller.renew" | "terminal.controller.request" | "terminal.controller.request.show" | "terminal.create" | "terminal.events.list" | "terminal.input.write" | "terminal.list" | "terminal.mutation.reconcile" | "terminal.observer.attach" | "terminal.observer.check" | "terminal.observer.detach" | "terminal.observer.resync" | "terminal.read" | "terminal.session.close" | "terminal.session.delete" | "terminal.session.resize" | "terminal.session.restart" | "terminal.session.signal" | "terminal.show" | "turn.cancel" | "turn.interrupt" | "turn.queue.list" | "turn.send" | "turn.show" | "turn.wait" | "voice.managed-turn.confirm" | "voice.managed-turn.preview" | "voice.orchestrator.context.show" | "voice.orchestrator.tool.call" | "voice.pi.relay" | "voice.pi.relay.preview" | "voice.pi.relay.reconcile" | "workspace.context.show" | "workspace.execution.configure" | "workspace.execution.show" | "workspace.list" | "workspace.membership.attach" | "workspace.repository.attach" | "workspace.select" | "workspace.show")[];
|
|
58
|
+
readonly operationIds: readonly ("agents.change.confirm" | "agents.change.preview" | "agents.detect" | "agents.list" | "agents.show" | "approval.list" | "approval.respond" | "approval.show" | "connection.capacity.set" | "connection.create" | "connection.detect" | "connection.gateway.create" | "connection.grant.list" | "connection.grant.set.confirm" | "connection.grant.set.preview" | "connection.list" | "connection.login.start" | "connection.models.list" | "connection.pool.list" | "connection.pool.set.confirm" | "connection.pool.set.preview" | "connection.show" | "connection.state.set" | "connection.system.confirm" | "connection.system.preview" | "connection.upkeep.confirm" | "connection.upkeep.preview" | "connection.upkeep.refresh" | "connection.usage.show" | "container.create.confirm" | "container.create.preview" | "container.index.list" | "container.list" | "container.rename.confirm" | "container.rename.preview" | "container.show" | "context.show" | "discovery.sessions.list" | "events.read" | "execution.catalog.get" | "execution.checkpoint.create" | "execution.checkpoint.show" | "execution.command.run" | "execution.file.read" | "execution.placement.create" | "execution.placement.show" | "execution.relocation.apply" | "execution.relocation.plan" | "execution.relocation.reconcile" | "execution.relocation.show" | "execution.worktree.create" | "execution.worktree.import" | "execution.worktree.reconcile" | "execution.worktree.remove.apply" | "execution.worktree.remove.plan" | "execution.worktree.status" | "harness.installed.list" | "hold.list" | "hold.place.confirm" | "hold.place.preview" | "hold.release.confirm" | "hold.release.preview" | "integration.apply.claude-code" | "integration.apply.codex" | "integration.apply.pi-rpc" | "integration.plan.claude-code" | "integration.plan.codex" | "integration.plan.pi-rpc" | "integration.remove.claude-code" | "integration.remove.codex" | "integration.remove.pi-rpc" | "integration.status.claude-code" | "integration.status.codex" | "integration.status.pi-rpc" | "interaction.cancel" | "interaction.create" | "interaction.list" | "interaction.respond" | "interaction.show" | "monitor.bootstrap.create" | "node.remote.install.confirm" | "node.remote.install.preview" | "node.remote.list" | "node.remote.register.confirm" | "node.remote.register.preview" | "node.remote.remove.confirm" | "node.remote.remove.preview" | "node.shutdown" | "node.status" | "port.lease.acquire" | "port.lease.list" | "port.lease.release" | "port.lease.renew" | "presentation.catalog.show" | "presentation.project-list.show" | "presentation.session-list.show" | "presentation.workspace-directory.show" | "project.context.list" | "project.context.record" | "project.context.show" | "project.create.confirm" | "project.create.preview" | "project.guard.confirm" | "project.guard.preview" | "project.guard.show" | "project.list" | "project.register" | "project.rename.confirm" | "project.rename.preview" | "project.show" | "provider.pool.list" | "receipt.get" | "receipt.list" | "reference.resolve" | "routine.create.confirm" | "routine.create.preview" | "routine.disable.confirm" | "routine.disable.preview" | "routine.list" | "routine.pause" | "routine.resume" | "routine.run.confirm" | "routine.run.preview" | "routine.show" | "run.create" | "run.dispatch.settle-terminal" | "run.dispatch.show" | "run.inbox.ack" | "run.inbox.check" | "run.ledger.create" | "run.ledger.list" | "run.ledger.task.dispatch" | "run.ledger.task.list" | "run.ledger.task.settle" | "run.ledger.task.show" | "run.list" | "run.question.cancel" | "run.question.open" | "run.question.reply" | "run.show" | "run.task.list" | "run.task.show" | "runtime.probe" | "session.adopt.confirm" | "session.adopt.preview" | "session.agent-permission.confirm" | "session.agent-permission.preview" | "session.archive" | "session.create" | "session.diff" | "session.events.list" | "session.history.read" | "session.inbox.ack" | "session.inbox.check" | "session.list" | "session.message.send" | "session.observe" | "session.rename" | "session.resume" | "session.show" | "session.spawn" | "session.start" | "session.stop" | "session.wait" | "team-workspace.bootstrap.apply" | "team-workspace.bootstrap.preview" | "terminal.controller.acquire" | "terminal.controller.release" | "terminal.controller.renew" | "terminal.controller.request" | "terminal.controller.request.show" | "terminal.create" | "terminal.events.list" | "terminal.input.write" | "terminal.list" | "terminal.mutation.reconcile" | "terminal.observer.attach" | "terminal.observer.check" | "terminal.observer.detach" | "terminal.observer.resync" | "terminal.read" | "terminal.session.close" | "terminal.session.delete" | "terminal.session.resize" | "terminal.session.restart" | "terminal.session.signal" | "terminal.show" | "turn.cancel" | "turn.interrupt" | "turn.queue.list" | "turn.send" | "turn.show" | "turn.wait" | "voice.managed-turn.confirm" | "voice.managed-turn.preview" | "voice.orchestrator.context.show" | "voice.orchestrator.tool.call" | "voice.pi.relay" | "voice.pi.relay.preview" | "voice.pi.relay.reconcile" | "workspace.context.show" | "workspace.execution.configure" | "workspace.execution.show" | "workspace.list" | "workspace.membership.attach" | "workspace.repository.attach" | "workspace.select" | "workspace.show")[];
|
|
59
59
|
readonly proof: string;
|
|
60
60
|
}>;
|
|
61
61
|
};
|
|
@@ -2,7 +2,7 @@ import * as Effect from "effect/Effect";
|
|
|
2
2
|
import { listEach, writeMerged } from "../../address-space/index.js";
|
|
3
3
|
import { CliArgumentError, parseOptions, reportError, requirePositionals, writeNodeResult, } from "../../command-line/index.js";
|
|
4
4
|
import { mergeLists } from "../../fleet/index.js";
|
|
5
|
-
import { commandIdentifier, } from "../../local-node/index.js";
|
|
5
|
+
import { commandIdentifier, holdsSessionCredential, } from "../../local-node/index.js";
|
|
6
6
|
import { describeApproval, formatApprovalResult, formatMergedApprovals, } from "./output/index.js";
|
|
7
7
|
const missing = (name) => Effect.die(new Error(`Missing approval client: ${name}.`));
|
|
8
8
|
const write = (context) => (result) => writeNodeResult(result, context, {
|
|
@@ -124,8 +124,12 @@ const decide = (context, input) => {
|
|
|
124
124
|
}));
|
|
125
125
|
});
|
|
126
126
|
};
|
|
127
|
-
const runDecision = (verb, tokens, context) => {
|
|
128
|
-
|
|
127
|
+
const runDecision = (verb, tokens, context) => Effect.gen(function* () {
|
|
128
|
+
if (verb !== "answer" || !(yield* holdsSessionCredential))
|
|
129
|
+
requirePerson(context, verb);
|
|
130
|
+
return yield* parseDecision(verb, tokens, context);
|
|
131
|
+
});
|
|
132
|
+
const parseDecision = (verb, tokens, context) => {
|
|
129
133
|
const parsed = parseOptions(tokens, OPTIONS[verb], verb === "approve" ? new Set(["--for-session"]) : new Set());
|
|
130
134
|
requirePositionals(parsed.positionals, 1);
|
|
131
135
|
const commandId = parsed.options.get("--command-id");
|
package/dist/session/client.d.ts
CHANGED
|
@@ -1,10 +1,16 @@
|
|
|
1
|
-
import type { Session, SessionCreateParameters, SessionCreateResult, SessionCreationInput, SessionCreationOutcome, SessionCreationPlan, SessionEventsListResult, SessionInboxAckResult, SessionInboxCheckResult, SessionListParameters, SessionListResult, SessionMessageSendResult, SessionObserveResult, SessionResumeResult, SessionShowResult, SessionSpawnResult, SessionStartResult, SessionStopResult } from "@maiaos/sdk";
|
|
1
|
+
import type { Session, SessionCreateParameters, SessionCreateResult, SessionCreationInput, SessionCreationOutcome, SessionCreationPlan, SessionEventsListResult, SessionInboxAckResult, SessionInboxCheckResult, SessionListParameters, SessionListResult, SessionMessageSendResult, SessionObserveResult, SessionResumeResult, SessionShowResult, SessionSpawnResult, SessionStartResult, SessionStopResult, SessionWaitResult } from "@maiaos/sdk";
|
|
2
2
|
import { type CliNodeEffect, type CliNodeOperations } from "../local-node/index.js";
|
|
3
|
+
export type WaitSessionInput = {
|
|
4
|
+
readonly sessionId: string;
|
|
5
|
+
readonly states: readonly string[];
|
|
6
|
+
readonly timeoutMilliseconds: number;
|
|
7
|
+
};
|
|
3
8
|
export type CreateSessionInput = {
|
|
4
9
|
readonly agentId?: SessionCreateParameters["agentId"];
|
|
5
10
|
readonly baseRef?: string;
|
|
6
11
|
readonly commandId?: string;
|
|
7
12
|
readonly connectionId?: string;
|
|
13
|
+
readonly cwd?: string;
|
|
8
14
|
readonly definitionRef?: SessionCreateParameters["definitionRef"];
|
|
9
15
|
readonly effort?: SessionCreateParameters["effort"];
|
|
10
16
|
readonly executor?: SessionCreateParameters["executor"];
|
|
@@ -59,7 +65,7 @@ export declare const makeSessionClient: (node: CliNodeOperations) => {
|
|
|
59
65
|
readonly commandId: string;
|
|
60
66
|
readonly grantedAt: string;
|
|
61
67
|
readonly inputDigest: string;
|
|
62
|
-
readonly operationIds: readonly ("agents.change.confirm" | "agents.change.preview" | "agents.list" | "agents.show" | "approval.list" | "approval.respond" | "approval.show" | "connection.capacity.set" | "connection.create" | "connection.detect" | "connection.gateway.create" | "connection.list" | "connection.login.start" | "connection.models.list" | "connection.show" | "connection.state.set" | "connection.system.confirm" | "connection.system.preview" | "connection.upkeep.confirm" | "connection.upkeep.preview" | "connection.upkeep.refresh" | "connection.usage.show" | "container.create.confirm" | "container.create.preview" | "container.index.list" | "container.list" | "container.rename.confirm" | "container.rename.preview" | "container.show" | "context.show" | "discovery.sessions.list" | "execution.catalog.get" | "execution.checkpoint.create" | "execution.checkpoint.show" | "execution.command.run" | "execution.file.read" | "execution.placement.create" | "execution.placement.show" | "execution.relocation.apply" | "execution.relocation.plan" | "execution.relocation.reconcile" | "execution.relocation.show" | "execution.worktree.create" | "execution.worktree.import" | "execution.worktree.reconcile" | "execution.worktree.remove.apply" | "execution.worktree.remove.plan" | "execution.worktree.status" | "harness.installed.list" | "hold.list" | "hold.place.confirm" | "hold.place.preview" | "hold.release.confirm" | "hold.release.preview" | "integration.apply.claude-code" | "integration.apply.codex" | "integration.apply.pi-rpc" | "integration.plan.claude-code" | "integration.plan.codex" | "integration.plan.pi-rpc" | "integration.remove.claude-code" | "integration.remove.codex" | "integration.remove.pi-rpc" | "integration.status.claude-code" | "integration.status.codex" | "integration.status.pi-rpc" | "interaction.cancel" | "interaction.create" | "interaction.list" | "interaction.respond" | "interaction.show" | "monitor.bootstrap.create" | "node.remote.install.confirm" | "node.remote.install.preview" | "node.remote.list" | "node.remote.register.confirm" | "node.remote.register.preview" | "node.remote.remove.confirm" | "node.remote.remove.preview" | "node.shutdown" | "node.status" | "port.lease.acquire" | "port.lease.list" | "port.lease.release" | "port.lease.renew" | "presentation.catalog.show" | "presentation.project-list.show" | "presentation.session-list.show" | "presentation.workspace-directory.show" | "project.context.list" | "project.context.record" | "project.context.show" | "project.create.confirm" | "project.create.preview" | "project.guard.confirm" | "project.guard.preview" | "project.guard.show" | "project.list" | "project.register" | "project.rename.confirm" | "project.rename.preview" | "project.show" | "provider.pool.list" | "receipt.get" | "receipt.list" | "reference.resolve" | "routine.create.confirm" | "routine.create.preview" | "routine.disable.confirm" | "routine.disable.preview" | "routine.list" | "routine.pause" | "routine.resume" | "routine.run.confirm" | "routine.run.preview" | "routine.show" | "run.create" | "run.dispatch.settle-terminal" | "run.dispatch.show" | "run.inbox.ack" | "run.inbox.check" | "run.ledger.create" | "run.ledger.list" | "run.ledger.task.dispatch" | "run.ledger.task.list" | "run.ledger.task.settle" | "run.ledger.task.show" | "run.list" | "run.question.cancel" | "run.question.open" | "run.question.reply" | "run.show" | "run.task.list" | "run.task.show" | "runtime.probe" | "session.adopt.confirm" | "session.adopt.preview" | "session.agent-permission.confirm" | "session.agent-permission.preview" | "session.archive" | "session.create" | "session.diff" | "session.events.list" | "session.history.read" | "session.inbox.ack" | "session.inbox.check" | "session.list" | "session.message.send" | "session.observe" | "session.rename" | "session.resume" | "session.show" | "session.spawn" | "session.start" | "session.stop" | "team-workspace.bootstrap.apply" | "team-workspace.bootstrap.preview" | "terminal.controller.acquire" | "terminal.controller.release" | "terminal.controller.renew" | "terminal.controller.request" | "terminal.controller.request.show" | "terminal.create" | "terminal.events.list" | "terminal.input.write" | "terminal.list" | "terminal.mutation.reconcile" | "terminal.observer.attach" | "terminal.observer.check" | "terminal.observer.detach" | "terminal.observer.resync" | "terminal.read" | "terminal.session.close" | "terminal.session.delete" | "terminal.session.resize" | "terminal.session.restart" | "terminal.session.signal" | "terminal.show" | "turn.cancel" | "turn.interrupt" | "turn.queue.list" | "turn.send" | "turn.show" | "turn.wait" | "voice.managed-turn.confirm" | "voice.managed-turn.preview" | "voice.orchestrator.context.show" | "voice.orchestrator.tool.call" | "voice.pi.relay" | "voice.pi.relay.preview" | "voice.pi.relay.reconcile" | "workspace.context.show" | "workspace.execution.configure" | "workspace.execution.show" | "workspace.list" | "workspace.membership.attach" | "workspace.repository.attach" | "workspace.select" | "workspace.show")[];
|
|
68
|
+
readonly operationIds: readonly ("agents.change.confirm" | "agents.change.preview" | "agents.detect" | "agents.list" | "agents.show" | "approval.list" | "approval.respond" | "approval.show" | "connection.capacity.set" | "connection.create" | "connection.detect" | "connection.gateway.create" | "connection.grant.list" | "connection.grant.set.confirm" | "connection.grant.set.preview" | "connection.list" | "connection.login.start" | "connection.models.list" | "connection.pool.list" | "connection.pool.set.confirm" | "connection.pool.set.preview" | "connection.show" | "connection.state.set" | "connection.system.confirm" | "connection.system.preview" | "connection.upkeep.confirm" | "connection.upkeep.preview" | "connection.upkeep.refresh" | "connection.usage.show" | "container.create.confirm" | "container.create.preview" | "container.index.list" | "container.list" | "container.rename.confirm" | "container.rename.preview" | "container.show" | "context.show" | "discovery.sessions.list" | "events.read" | "execution.catalog.get" | "execution.checkpoint.create" | "execution.checkpoint.show" | "execution.command.run" | "execution.file.read" | "execution.placement.create" | "execution.placement.show" | "execution.relocation.apply" | "execution.relocation.plan" | "execution.relocation.reconcile" | "execution.relocation.show" | "execution.worktree.create" | "execution.worktree.import" | "execution.worktree.reconcile" | "execution.worktree.remove.apply" | "execution.worktree.remove.plan" | "execution.worktree.status" | "harness.installed.list" | "hold.list" | "hold.place.confirm" | "hold.place.preview" | "hold.release.confirm" | "hold.release.preview" | "integration.apply.claude-code" | "integration.apply.codex" | "integration.apply.pi-rpc" | "integration.plan.claude-code" | "integration.plan.codex" | "integration.plan.pi-rpc" | "integration.remove.claude-code" | "integration.remove.codex" | "integration.remove.pi-rpc" | "integration.status.claude-code" | "integration.status.codex" | "integration.status.pi-rpc" | "interaction.cancel" | "interaction.create" | "interaction.list" | "interaction.respond" | "interaction.show" | "monitor.bootstrap.create" | "node.remote.install.confirm" | "node.remote.install.preview" | "node.remote.list" | "node.remote.register.confirm" | "node.remote.register.preview" | "node.remote.remove.confirm" | "node.remote.remove.preview" | "node.shutdown" | "node.status" | "port.lease.acquire" | "port.lease.list" | "port.lease.release" | "port.lease.renew" | "presentation.catalog.show" | "presentation.project-list.show" | "presentation.session-list.show" | "presentation.workspace-directory.show" | "project.context.list" | "project.context.record" | "project.context.show" | "project.create.confirm" | "project.create.preview" | "project.guard.confirm" | "project.guard.preview" | "project.guard.show" | "project.list" | "project.register" | "project.rename.confirm" | "project.rename.preview" | "project.show" | "provider.pool.list" | "receipt.get" | "receipt.list" | "reference.resolve" | "routine.create.confirm" | "routine.create.preview" | "routine.disable.confirm" | "routine.disable.preview" | "routine.list" | "routine.pause" | "routine.resume" | "routine.run.confirm" | "routine.run.preview" | "routine.show" | "run.create" | "run.dispatch.settle-terminal" | "run.dispatch.show" | "run.inbox.ack" | "run.inbox.check" | "run.ledger.create" | "run.ledger.list" | "run.ledger.task.dispatch" | "run.ledger.task.list" | "run.ledger.task.settle" | "run.ledger.task.show" | "run.list" | "run.question.cancel" | "run.question.open" | "run.question.reply" | "run.show" | "run.task.list" | "run.task.show" | "runtime.probe" | "session.adopt.confirm" | "session.adopt.preview" | "session.agent-permission.confirm" | "session.agent-permission.preview" | "session.archive" | "session.create" | "session.diff" | "session.events.list" | "session.history.read" | "session.inbox.ack" | "session.inbox.check" | "session.list" | "session.message.send" | "session.observe" | "session.rename" | "session.resume" | "session.show" | "session.spawn" | "session.start" | "session.stop" | "session.wait" | "team-workspace.bootstrap.apply" | "team-workspace.bootstrap.preview" | "terminal.controller.acquire" | "terminal.controller.release" | "terminal.controller.renew" | "terminal.controller.request" | "terminal.controller.request.show" | "terminal.create" | "terminal.events.list" | "terminal.input.write" | "terminal.list" | "terminal.mutation.reconcile" | "terminal.observer.attach" | "terminal.observer.check" | "terminal.observer.detach" | "terminal.observer.resync" | "terminal.read" | "terminal.session.close" | "terminal.session.delete" | "terminal.session.resize" | "terminal.session.restart" | "terminal.session.signal" | "terminal.show" | "turn.cancel" | "turn.interrupt" | "turn.queue.list" | "turn.send" | "turn.show" | "turn.wait" | "voice.managed-turn.confirm" | "voice.managed-turn.preview" | "voice.orchestrator.context.show" | "voice.orchestrator.tool.call" | "voice.pi.relay" | "voice.pi.relay.preview" | "voice.pi.relay.reconcile" | "workspace.context.show" | "workspace.execution.configure" | "workspace.execution.show" | "workspace.list" | "workspace.membership.attach" | "workspace.repository.attach" | "workspace.select" | "workspace.show")[];
|
|
63
69
|
readonly revision: "1";
|
|
64
70
|
};
|
|
65
71
|
readonly method: "session.agent-permission.confirm";
|
|
@@ -96,7 +102,7 @@ export declare const makeSessionClient: (node: CliNodeOperations) => {
|
|
|
96
102
|
readonly inputDigest: string;
|
|
97
103
|
readonly issuedAt: string;
|
|
98
104
|
readonly method: "session.agent-permission.preview";
|
|
99
|
-
readonly operationIds: readonly ("agents.change.confirm" | "agents.change.preview" | "agents.list" | "agents.show" | "approval.list" | "approval.respond" | "approval.show" | "connection.capacity.set" | "connection.create" | "connection.detect" | "connection.gateway.create" | "connection.list" | "connection.login.start" | "connection.models.list" | "connection.show" | "connection.state.set" | "connection.system.confirm" | "connection.system.preview" | "connection.upkeep.confirm" | "connection.upkeep.preview" | "connection.upkeep.refresh" | "connection.usage.show" | "container.create.confirm" | "container.create.preview" | "container.index.list" | "container.list" | "container.rename.confirm" | "container.rename.preview" | "container.show" | "context.show" | "discovery.sessions.list" | "execution.catalog.get" | "execution.checkpoint.create" | "execution.checkpoint.show" | "execution.command.run" | "execution.file.read" | "execution.placement.create" | "execution.placement.show" | "execution.relocation.apply" | "execution.relocation.plan" | "execution.relocation.reconcile" | "execution.relocation.show" | "execution.worktree.create" | "execution.worktree.import" | "execution.worktree.reconcile" | "execution.worktree.remove.apply" | "execution.worktree.remove.plan" | "execution.worktree.status" | "harness.installed.list" | "hold.list" | "hold.place.confirm" | "hold.place.preview" | "hold.release.confirm" | "hold.release.preview" | "integration.apply.claude-code" | "integration.apply.codex" | "integration.apply.pi-rpc" | "integration.plan.claude-code" | "integration.plan.codex" | "integration.plan.pi-rpc" | "integration.remove.claude-code" | "integration.remove.codex" | "integration.remove.pi-rpc" | "integration.status.claude-code" | "integration.status.codex" | "integration.status.pi-rpc" | "interaction.cancel" | "interaction.create" | "interaction.list" | "interaction.respond" | "interaction.show" | "monitor.bootstrap.create" | "node.remote.install.confirm" | "node.remote.install.preview" | "node.remote.list" | "node.remote.register.confirm" | "node.remote.register.preview" | "node.remote.remove.confirm" | "node.remote.remove.preview" | "node.shutdown" | "node.status" | "port.lease.acquire" | "port.lease.list" | "port.lease.release" | "port.lease.renew" | "presentation.catalog.show" | "presentation.project-list.show" | "presentation.session-list.show" | "presentation.workspace-directory.show" | "project.context.list" | "project.context.record" | "project.context.show" | "project.create.confirm" | "project.create.preview" | "project.guard.confirm" | "project.guard.preview" | "project.guard.show" | "project.list" | "project.register" | "project.rename.confirm" | "project.rename.preview" | "project.show" | "provider.pool.list" | "receipt.get" | "receipt.list" | "reference.resolve" | "routine.create.confirm" | "routine.create.preview" | "routine.disable.confirm" | "routine.disable.preview" | "routine.list" | "routine.pause" | "routine.resume" | "routine.run.confirm" | "routine.run.preview" | "routine.show" | "run.create" | "run.dispatch.settle-terminal" | "run.dispatch.show" | "run.inbox.ack" | "run.inbox.check" | "run.ledger.create" | "run.ledger.list" | "run.ledger.task.dispatch" | "run.ledger.task.list" | "run.ledger.task.settle" | "run.ledger.task.show" | "run.list" | "run.question.cancel" | "run.question.open" | "run.question.reply" | "run.show" | "run.task.list" | "run.task.show" | "runtime.probe" | "session.adopt.confirm" | "session.adopt.preview" | "session.agent-permission.confirm" | "session.agent-permission.preview" | "session.archive" | "session.create" | "session.diff" | "session.events.list" | "session.history.read" | "session.inbox.ack" | "session.inbox.check" | "session.list" | "session.message.send" | "session.observe" | "session.rename" | "session.resume" | "session.show" | "session.spawn" | "session.start" | "session.stop" | "team-workspace.bootstrap.apply" | "team-workspace.bootstrap.preview" | "terminal.controller.acquire" | "terminal.controller.release" | "terminal.controller.renew" | "terminal.controller.request" | "terminal.controller.request.show" | "terminal.create" | "terminal.events.list" | "terminal.input.write" | "terminal.list" | "terminal.mutation.reconcile" | "terminal.observer.attach" | "terminal.observer.check" | "terminal.observer.detach" | "terminal.observer.resync" | "terminal.read" | "terminal.session.close" | "terminal.session.delete" | "terminal.session.resize" | "terminal.session.restart" | "terminal.session.signal" | "terminal.show" | "turn.cancel" | "turn.interrupt" | "turn.queue.list" | "turn.send" | "turn.show" | "turn.wait" | "voice.managed-turn.confirm" | "voice.managed-turn.preview" | "voice.orchestrator.context.show" | "voice.orchestrator.tool.call" | "voice.pi.relay" | "voice.pi.relay.preview" | "voice.pi.relay.reconcile" | "workspace.context.show" | "workspace.execution.configure" | "workspace.execution.show" | "workspace.list" | "workspace.membership.attach" | "workspace.repository.attach" | "workspace.select" | "workspace.show")[];
|
|
105
|
+
readonly operationIds: readonly ("agents.change.confirm" | "agents.change.preview" | "agents.detect" | "agents.list" | "agents.show" | "approval.list" | "approval.respond" | "approval.show" | "connection.capacity.set" | "connection.create" | "connection.detect" | "connection.gateway.create" | "connection.grant.list" | "connection.grant.set.confirm" | "connection.grant.set.preview" | "connection.list" | "connection.login.start" | "connection.models.list" | "connection.pool.list" | "connection.pool.set.confirm" | "connection.pool.set.preview" | "connection.show" | "connection.state.set" | "connection.system.confirm" | "connection.system.preview" | "connection.upkeep.confirm" | "connection.upkeep.preview" | "connection.upkeep.refresh" | "connection.usage.show" | "container.create.confirm" | "container.create.preview" | "container.index.list" | "container.list" | "container.rename.confirm" | "container.rename.preview" | "container.show" | "context.show" | "discovery.sessions.list" | "events.read" | "execution.catalog.get" | "execution.checkpoint.create" | "execution.checkpoint.show" | "execution.command.run" | "execution.file.read" | "execution.placement.create" | "execution.placement.show" | "execution.relocation.apply" | "execution.relocation.plan" | "execution.relocation.reconcile" | "execution.relocation.show" | "execution.worktree.create" | "execution.worktree.import" | "execution.worktree.reconcile" | "execution.worktree.remove.apply" | "execution.worktree.remove.plan" | "execution.worktree.status" | "harness.installed.list" | "hold.list" | "hold.place.confirm" | "hold.place.preview" | "hold.release.confirm" | "hold.release.preview" | "integration.apply.claude-code" | "integration.apply.codex" | "integration.apply.pi-rpc" | "integration.plan.claude-code" | "integration.plan.codex" | "integration.plan.pi-rpc" | "integration.remove.claude-code" | "integration.remove.codex" | "integration.remove.pi-rpc" | "integration.status.claude-code" | "integration.status.codex" | "integration.status.pi-rpc" | "interaction.cancel" | "interaction.create" | "interaction.list" | "interaction.respond" | "interaction.show" | "monitor.bootstrap.create" | "node.remote.install.confirm" | "node.remote.install.preview" | "node.remote.list" | "node.remote.register.confirm" | "node.remote.register.preview" | "node.remote.remove.confirm" | "node.remote.remove.preview" | "node.shutdown" | "node.status" | "port.lease.acquire" | "port.lease.list" | "port.lease.release" | "port.lease.renew" | "presentation.catalog.show" | "presentation.project-list.show" | "presentation.session-list.show" | "presentation.workspace-directory.show" | "project.context.list" | "project.context.record" | "project.context.show" | "project.create.confirm" | "project.create.preview" | "project.guard.confirm" | "project.guard.preview" | "project.guard.show" | "project.list" | "project.register" | "project.rename.confirm" | "project.rename.preview" | "project.show" | "provider.pool.list" | "receipt.get" | "receipt.list" | "reference.resolve" | "routine.create.confirm" | "routine.create.preview" | "routine.disable.confirm" | "routine.disable.preview" | "routine.list" | "routine.pause" | "routine.resume" | "routine.run.confirm" | "routine.run.preview" | "routine.show" | "run.create" | "run.dispatch.settle-terminal" | "run.dispatch.show" | "run.inbox.ack" | "run.inbox.check" | "run.ledger.create" | "run.ledger.list" | "run.ledger.task.dispatch" | "run.ledger.task.list" | "run.ledger.task.settle" | "run.ledger.task.show" | "run.list" | "run.question.cancel" | "run.question.open" | "run.question.reply" | "run.show" | "run.task.list" | "run.task.show" | "runtime.probe" | "session.adopt.confirm" | "session.adopt.preview" | "session.agent-permission.confirm" | "session.agent-permission.preview" | "session.archive" | "session.create" | "session.diff" | "session.events.list" | "session.history.read" | "session.inbox.ack" | "session.inbox.check" | "session.list" | "session.message.send" | "session.observe" | "session.rename" | "session.resume" | "session.show" | "session.spawn" | "session.start" | "session.stop" | "session.wait" | "team-workspace.bootstrap.apply" | "team-workspace.bootstrap.preview" | "terminal.controller.acquire" | "terminal.controller.release" | "terminal.controller.renew" | "terminal.controller.request" | "terminal.controller.request.show" | "terminal.create" | "terminal.events.list" | "terminal.input.write" | "terminal.list" | "terminal.mutation.reconcile" | "terminal.observer.attach" | "terminal.observer.check" | "terminal.observer.detach" | "terminal.observer.resync" | "terminal.read" | "terminal.session.close" | "terminal.session.delete" | "terminal.session.resize" | "terminal.session.restart" | "terminal.session.signal" | "terminal.show" | "turn.cancel" | "turn.interrupt" | "turn.queue.list" | "turn.send" | "turn.show" | "turn.wait" | "voice.managed-turn.confirm" | "voice.managed-turn.preview" | "voice.orchestrator.context.show" | "voice.orchestrator.tool.call" | "voice.pi.relay" | "voice.pi.relay.preview" | "voice.pi.relay.reconcile" | "workspace.context.show" | "workspace.execution.configure" | "workspace.execution.show" | "workspace.list" | "workspace.membership.attach" | "workspace.repository.attach" | "workspace.select" | "workspace.show")[];
|
|
100
106
|
readonly proof: string;
|
|
101
107
|
}>;
|
|
102
108
|
attachSession: (input: import("./attach-client.js").AttachSessionInput) => CliNodeEffect<import("./attach-client.js").SessionAttachStream>;
|
|
@@ -129,6 +135,7 @@ export declare const makeSessionClient: (node: CliNodeOperations) => {
|
|
|
129
135
|
spawnSession: (input: SpawnSessionInput) => CliNodeEffect<SessionSpawnResult>;
|
|
130
136
|
startSession: (input: StartSessionInput) => CliNodeEffect<SessionStartResult>;
|
|
131
137
|
stopSession: (input: StartSessionInput) => CliNodeEffect<SessionStopResult>;
|
|
138
|
+
waitSession: (input: WaitSessionInput) => CliNodeEffect<SessionWaitResult>;
|
|
132
139
|
};
|
|
133
140
|
export {};
|
|
134
141
|
//# sourceMappingURL=client.d.ts.map
|