@murmurv2/cli 2.12.0 → 2.14.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (64) hide show
  1. package/README.md +65 -24
  2. package/package.json +7 -6
  3. package/runtime/bin/murmur-svc.exe +0 -0
  4. package/runtime/npm-runtime-manifest.json +175 -79
  5. package/runtime/package.json +1 -1
  6. package/runtime/packages/mcp-server/dist/src/agent-config.js +1 -0
  7. package/runtime/packages/setup/bin/murmur.mjs +3 -2
  8. package/runtime/packages/setup/dist/src/autoreply.d.ts +23 -0
  9. package/runtime/packages/setup/dist/src/autoreply.js +71 -0
  10. package/runtime/packages/setup/dist/src/backups.d.ts +36 -0
  11. package/runtime/packages/setup/dist/src/backups.js +128 -0
  12. package/runtime/packages/setup/dist/src/broker-input.d.ts +24 -0
  13. package/runtime/packages/setup/dist/src/broker-input.js +98 -0
  14. package/runtime/packages/setup/dist/src/broker-migration.d.ts +35 -0
  15. package/runtime/packages/setup/dist/src/broker-migration.js +138 -0
  16. package/runtime/packages/setup/dist/src/cli-error.d.ts +2 -0
  17. package/runtime/packages/setup/dist/src/cli-error.js +30 -0
  18. package/runtime/packages/setup/dist/src/cli.js +113 -10
  19. package/runtime/packages/setup/dist/src/clients.d.ts +33 -81
  20. package/runtime/packages/setup/dist/src/clients.js +159 -25
  21. package/runtime/packages/setup/dist/src/commands.d.ts +1 -0
  22. package/runtime/packages/setup/dist/src/commands.js +18 -6
  23. package/runtime/packages/setup/dist/src/config.d.ts +8 -0
  24. package/runtime/packages/setup/dist/src/config.js +58 -10
  25. package/runtime/packages/setup/dist/src/connect.d.ts +143 -0
  26. package/runtime/packages/setup/dist/src/connect.js +128 -0
  27. package/runtime/packages/setup/dist/src/conversations.d.ts +193 -0
  28. package/runtime/packages/setup/dist/src/conversations.js +674 -0
  29. package/runtime/packages/setup/dist/src/doctor.d.ts +30 -0
  30. package/runtime/packages/setup/dist/src/doctor.js +72 -10
  31. package/runtime/packages/setup/dist/src/installation.d.ts +25 -0
  32. package/runtime/packages/setup/dist/src/installation.js +89 -0
  33. package/runtime/packages/setup/dist/src/message-status.d.ts +1 -0
  34. package/runtime/packages/setup/dist/src/message-status.js +3 -0
  35. package/runtime/packages/setup/dist/src/onboarding.d.ts +11 -6
  36. package/runtime/packages/setup/dist/src/onboarding.js +92 -21
  37. package/runtime/packages/setup/dist/src/paths.d.ts +7 -0
  38. package/runtime/packages/setup/dist/src/paths.js +39 -24
  39. package/runtime/packages/setup/dist/src/platform/darwin.d.ts +3 -0
  40. package/runtime/packages/setup/dist/src/platform/darwin.js +247 -9
  41. package/runtime/packages/setup/dist/src/platform/linux.js +156 -12
  42. package/runtime/packages/setup/dist/src/platform/profile-usage.d.ts +20 -0
  43. package/runtime/packages/setup/dist/src/platform/profile-usage.js +89 -0
  44. package/runtime/packages/setup/dist/src/platform/windows.js +48 -8
  45. package/runtime/packages/setup/dist/src/private-file.d.ts +4 -1
  46. package/runtime/packages/setup/dist/src/private-file.js +39 -3
  47. package/runtime/packages/setup/dist/src/state.d.ts +4 -0
  48. package/runtime/packages/setup/dist/src/state.js +65 -1
  49. package/runtime/packages/setup/dist/src/status.d.ts +9 -0
  50. package/runtime/packages/setup/dist/src/status.js +7 -3
  51. package/runtime/packages/setup/dist/src/types.d.ts +11 -1
  52. package/runtime/packages/setup/dist/src/wake-readers.d.ts +12 -0
  53. package/runtime/packages/setup/dist/src/wake-readers.js +65 -0
  54. package/runtime/packages/setup/package.json +1 -1
  55. package/runtime/scripts/auth-security.mjs +93 -0
  56. package/runtime/scripts/codex-app-server-wake.mjs +36 -4
  57. package/runtime/scripts/daemon-contacts.mjs +1 -1
  58. package/runtime/scripts/murmur-auth-token.mjs +140 -0
  59. package/runtime/scripts/murmur-daemon.mjs +27 -8
  60. package/runtime/scripts/murmur-jetstream-advisory.mjs +27 -0
  61. package/runtime/scripts/murmur-shell-send.mjs +7 -3
  62. package/runtime/scripts/owner-review-store.mjs +54 -0
  63. package/runtime/scripts/wake-drain-claude.mjs +124 -7
  64. package/runtime/scripts/wake-monitor.mjs +49 -10
@@ -1,8 +1,12 @@
1
+ import { migrateBroker } from './broker-migration.js';
1
2
  import { configureClient, previewClientConfiguration } from './clients.js';
3
+ import { previewBackups, cleanupBackups } from './backups.js';
4
+ import { checkInstallationSelection, selectInstallation, showInstallation } from './installation.js';
2
5
  import { prepareReplyTest, checkReplyTest } from './reply-test.js';
3
6
  import { listOutboxAttention, setOutboxDismissed } from './outbox-attention.js';
4
7
  import { dismissWake } from './wake-attention.js';
5
8
  import { initialize, invite, join, importPeer } from './onboarding.js';
9
+ import { connect, renderConnect } from './connect.js';
6
10
  import { runDoctor } from './doctor.js';
7
11
  import { parseArgs } from 'node:util';
8
12
  import path from 'node:path';
@@ -14,6 +18,8 @@ import { readStatus } from './status.js';
14
18
  import { setWakeEnabled, markInboxRead, readInbox, readLogPath } from './commands.js';
15
19
  import { renderStatusLine } from './status-line.js';
16
20
  import { readVersion, checkUpdates, setUpdateChecks } from './updates.js';
21
+ import { listConversations, showConversation, showRouting, sendDirect, markConversationRead, inboxFeed, listSessions } from './conversations.js';
22
+ import { showAutoreply, setAutoreply } from './autoreply.js';
17
23
  export function platformAdapter() {
18
24
  if (process.platform === 'linux')
19
25
  return createLinuxAdapter();
@@ -42,9 +48,15 @@ export async function main(args, adapter = platformAdapter(), input = process.st
42
48
  let parsed;
43
49
  try {
44
50
  parsed = parseArgs({ args, allowPositionals: true, options: {
51
+ kind: { type: 'string' }, 'config-file': { type: 'string' }, 'keep-file': { type: 'string', multiple: true },
52
+ 'installation-file': { type: 'string' }, select: { type: 'boolean' },
45
53
  'msg-id': { type: 'string' }, 'expected-state': { type: 'string' }, 'expected-agent': { type: 'string' },
54
+ 'project-dir': { type: 'string' },
55
+ 'user-file': { type: 'string' }, 'password-file': { type: 'string' }, 'ca-file': { type: 'string' }, 'server-name': { type: 'string' },
46
56
  'agent-id': { type: 'string' }, 'broker-url': { type: 'string' }, broker: { type: 'string' }, 'token-file': { type: 'string' }, 'invite-file': { type: 'string' }, 'reply-file': { type: 'string' }, 'reply-out': { type: 'string' }, out: { type: 'string' },
57
+ invite: { type: 'string' }, 'no-service': { type: 'boolean' }, 'copy-reply': { type: 'boolean' }, 'print-secret': { type: 'boolean' },
47
58
  'invite-stdin': { type: 'boolean' }, 'reply-stdin': { type: 'boolean' },
59
+ id: { type: 'string' }, to: { type: 'string' }, conversation: { type: 'string' }, 'text-stdin': { type: 'boolean' }, 'text-file': { type: 'string' }, 'expect-after': { type: 'string' }, 'resend-of': { type: 'string' }, through: { type: 'string' },
48
60
  client: { type: 'string' }, replace: { type: 'boolean' }, 'replace-previous': { type: 'boolean' }, 'plan-id': { type: 'string' }, 'test-token': { type: 'string' }, json: { type: 'boolean' }, line: { type: 'boolean' }, limit: { type: 'string' }, peer: { type: 'string' }, timeout: { type: 'string' }, 'data-dir': { type: 'string' }, 'service-name': { type: 'string' }, apply: { type: 'boolean' }, help: { type: 'boolean' },
49
61
  } });
50
62
  }
@@ -54,11 +66,15 @@ export async function main(args, adapter = platformAdapter(), input = process.st
54
66
  }
55
67
  const { values, positionals } = parsed;
56
68
  if (values.help || !positionals.length)
57
- return { commands: ['version --json', 'updates check|enable|disable --json', 'init --agent-id ID --broker-url URL [--token-file FILE]', 'invite [--out FILE] [--broker PUBLIC_URL] [--json]', 'join --agent-id ID (--invite-stdin|--invite-file FILE) [--reply-out FILE] [--json]', 'add-peer (--reply-stdin|--reply-file FILE)', 'status --json|--line', 'doctor --json [--peer AGENT] [--timeout MILLISECONDS]', 'logs path --json', 'service install [--replace-previous]|start|stop|uninstall', 'clients detect', 'clients preview --client ID', 'clients configure --client ID [--replace] [--plan-id SHA256]', 'reply-test prepare --peer AGENT', 'reply-test check --test-token TOKEN', 'wake pause|resume [--apply]', 'wake dismiss --msg-id ID --expected-agent ID', 'inbox read [--limit 1..100]', 'inbox mark-read', 'outbox list --json', 'outbox dismiss|restore --msg-id ID --expected-state TOKEN --expected-agent ID', 'mcp serve --data-dir ABSOLUTE'],
69
+ return { commands: ['broker migrate --broker-url URL [--token-file FILE|--user-file FILE --password-file FILE] [--ca-file FILE] [--server-name NAME] [--apply]', 'installation show [--installation-file ABSOLUTE]', 'installation select --data-dir ABSOLUTE [--replace] [--installation-file ABSOLUTE]', 'backups preview|cleanup --kind agent|client [--config-file ABSOLUTE] [--keep-file ABSOLUTE] [--plan-id SHA256]', 'version --json', 'updates check|enable|disable --json', 'init --agent-id ID --broker-url URL [--token-file FILE] [--select]', 'invite [--out FILE] [--broker-url PUBLIC_URL|--broker PUBLIC_URL] [--print-secret] [--json]', 'connect (--invite TEXT_OR_FILE|--invite-file FILE|--invite-stdin) [--agent-id ID] [--data-dir ABSOLUTE] [--reply-out FILE] [--client auto|claude-code|claude-desktop|codex|codex-cli|cursor|gemini|antigravity|none] [--no-service] [--copy-reply] [--json]', 'join --agent-id ID (--invite-stdin|--invite-file FILE) [--reply-out FILE] [--select] [--json]', 'add-peer (--reply-stdin|--reply-file FILE)', 'status --json|--line', 'doctor --json [--peer AGENT] [--timeout MILLISECONDS]', 'logs path --json', 'service install [--replace-previous]|start|stop|uninstall', 'clients detect', 'clients preview --client ID [--project-dir ABSOLUTE]', 'clients configure --client ID [--project-dir ABSOLUTE] [--replace] [--plan-id SHA256]', 'reply-test prepare --peer AGENT', 'reply-test check --test-token TOKEN', 'wake pause|resume [--apply]', 'wake dismiss --msg-id ID --expected-agent ID', 'conversations list [--limit 1..200]', 'conversations show --id ID [--limit 1..200]', 'routing show', 'conversations read --id ID --through MSG_ID --expected-agent ID', 'inbox feed [--limit 1..100]', 'sessions list', 'autoreply show', 'autoreply enable|disable --peer AGENT --expected-agent ID', 'send --to PEER --conversation ID --msg-id UUID --expected-agent ID [--expect-after MSG_ID] (--text-stdin|--text-file FILE|--resend-of MSG_ID)', 'inbox read [--limit 1..100]', 'inbox mark-read', 'outbox list --json', 'outbox dismiss|restore --msg-id ID --expected-state TOKEN --expected-agent ID', 'mcp serve [--data-dir ABSOLUTE]'],
58
70
  options: ['--data-dir ABSOLUTE', '--service-name NAME'], note: 'Windows service mutations require an elevated terminal and the matching native helper.' };
59
71
  const [command, action, extra] = positionals;
60
72
  if (extra)
61
73
  throw new Error('cli.unexpected-argument');
74
+ if (['token-file', 'user-file', 'password-file', 'ca-file', 'server-name'].some(key => values[key] !== undefined)
75
+ && !['init', 'join'].includes(command) && !(command === 'broker' && action === 'migrate')
76
+ || values['broker-url'] !== undefined && !['init', 'invite'].includes(command) && !(command === 'broker' && action === 'migrate'))
77
+ throw new Error('cli.option-not-supported');
62
78
  if (values.line && command !== 'status')
63
79
  throw new Error('cli.line-only-for-status');
64
80
  if (values.line && values.json)
@@ -69,11 +85,23 @@ export async function main(args, adapter = platformAdapter(), input = process.st
69
85
  return checkUpdates();
70
86
  if (command === 'updates' && ['enable', 'disable'].includes(action))
71
87
  return setUpdateChecks(action === 'enable');
72
- const context = resolveContext({ dataDir: values['data-dir'], serviceName: values['service-name'] });
88
+ if (values['project-dir'] !== undefined && !['clients', 'doctor'].includes(command))
89
+ throw new Error('cli.project-dir-only-for-clients-or-doctor');
73
90
  const required = (name) => { const value = values[name]; if (typeof value !== 'string' || !value)
74
91
  throw new Error('cli.required-option:' + name); return value; };
75
- if (command === 'init' && !action)
76
- return initialize(context, { agentId: required('agent-id'), brokerUrl: required('broker-url'), tokenFile: values['token-file'] });
92
+ if (command === 'backups' && ['preview', 'cleanup'].includes(action) && values.kind === 'client') {
93
+ const selection = { kind: 'client', configFile: required('config-file'), keepFiles: values['keep-file'] };
94
+ return action === 'preview' ? previewBackups(null, selection) : cleanupBackups(null, selection, required('plan-id'));
95
+ }
96
+ if (command === 'installation' && action === 'show')
97
+ return showInstallation(values['installation-file']);
98
+ if (command === 'installation' && action === 'select' && values['data-dir'] === undefined)
99
+ throw new Error('cli.required-option:data-dir');
100
+ if (values.select && !['init', 'join'].includes(command))
101
+ throw new Error('cli.select-only-for-init-or-join');
102
+ if ((values.invite !== undefined || values['no-service'] || values['copy-reply']) && command !== 'connect'
103
+ || (values.broker !== undefined || values['print-secret']) && command !== 'invite')
104
+ throw new Error('cli.option-not-supported');
77
105
  const onboardingInput = async (kind) => {
78
106
  if (values[`${kind}-file`] !== undefined && values[`${kind}-stdin`])
79
107
  throw new Error('onboarding.input-conflict');
@@ -95,11 +123,45 @@ export async function main(args, adapter = platformAdapter(), input = process.st
95
123
  }
96
124
  return Buffer.concat(chunks).toString('utf8');
97
125
  };
98
- if (command === 'invite' && !action)
99
- return invite(context, values.out, { brokerUrl: values.broker });
126
+ if (command === 'connect' && !action) {
127
+ if ([values.invite !== undefined, values['invite-file'] !== undefined, !!values['invite-stdin']].filter(Boolean).length !== 1) {
128
+ throw new Error('connect.one-invite-input-required');
129
+ }
130
+ const result = await connect(adapter, {
131
+ agentId: values['agent-id'], dataDir: values['data-dir'], inviteFile: values['invite-file'],
132
+ inviteArgument: values.invite, invitation: values['invite-stdin'] ? await onboardingInput('invite') : undefined,
133
+ replyOut: values['reply-out'], client: values.client, noService: values['no-service'], copyReply: values['copy-reply'],
134
+ });
135
+ return values.json ? result : rawCliOutput(renderConnect(result));
136
+ }
137
+ const context = resolveContext({ dataDir: values['data-dir'], serviceName: values['service-name'], installationFile: values['installation-file'], clientProjectDir: values['project-dir'] });
138
+ if (command === 'backups' && ['preview', 'cleanup'].includes(action)) {
139
+ const kind = required('kind');
140
+ if (kind !== 'agent' && kind !== 'client')
141
+ throw new Error('backups.kind-required');
142
+ const selection = { kind, configFile: values['config-file'], keepFiles: values['keep-file'] };
143
+ return action === 'preview' ? previewBackups(context, selection) : cleanupBackups(context, selection, required('plan-id'));
144
+ }
145
+ if (command === 'installation' && action === 'select')
146
+ return selectInstallation(context, { file: values['installation-file'], replace: values.replace });
147
+ if (values.select)
148
+ checkInstallationSelection(context, { file: values['installation-file'], replace: values.replace });
149
+ const selected = async (result) => values.select ? { ...result, installation: await selectInstallation(context, { file: values['installation-file'], replace: values.replace }) } : result;
150
+ const brokerFiles = { tokenFile: values['token-file'], userFile: values['user-file'], passwordFile: values['password-file'],
151
+ caFile: values['ca-file'], serverName: values['server-name'] };
152
+ if (command === 'broker' && action === 'migrate')
153
+ return migrateBroker(context, adapter, { ...brokerFiles,
154
+ brokerUrl: required('broker-url'), apply: values.apply });
155
+ if (command === 'init' && !action)
156
+ return selected(await initialize(context, { agentId: required('agent-id'), brokerUrl: required('broker-url'), ...brokerFiles }));
157
+ if (command === 'invite' && !action) {
158
+ if (values['broker-url'] !== undefined && values.broker !== undefined)
159
+ throw new Error('cli.broker-options-conflict');
160
+ return invite(context, values.out, { brokerUrl: values['broker-url'] ?? values.broker, printSecret: values['print-secret'] });
161
+ }
100
162
  if (command === 'join' && !action)
101
- return join(context, { agentId: required('agent-id'), inviteFile: values['invite-file'],
102
- invitation: await onboardingInput('invite'), replyOut: values['reply-out'] });
163
+ return selected(await join(context, { agentId: required('agent-id'), inviteFile: values['invite-file'],
164
+ invitation: await onboardingInput('invite'), replyOut: values['reply-out'], ...brokerFiles }));
103
165
  if (command === 'add-peer' && !action)
104
166
  return importPeer(context, values['reply-file'], await onboardingInput('reply'));
105
167
  if (command === 'status' && !action) {
@@ -111,8 +173,6 @@ export async function main(args, adapter = platformAdapter(), input = process.st
111
173
  if (command === 'outbox' && ['dismiss', 'restore'].includes(action))
112
174
  return setOutboxDismissed(context, required('msg-id'), required('expected-state'), required('expected-agent'), action === 'dismiss');
113
175
  if (command === 'mcp' && action === 'serve') {
114
- if (values['data-dir'] === undefined)
115
- throw new Error('cli.required-option:data-dir');
116
176
  process.env.DATA_DIR = context.dataDir;
117
177
  process.env.MURMUR_DATA_DIR = context.dataDir;
118
178
  process.env.MURMUR_STORE_PATH = context.storePath;
@@ -144,6 +204,49 @@ export async function main(args, adapter = platformAdapter(), input = process.st
144
204
  return setWakeEnabled(context, adapter, action === 'resume', values.apply);
145
205
  if (command === 'wake' && action === 'dismiss')
146
206
  return dismissWake(context, required('msg-id'), required('expected-agent'));
207
+ if (command === 'conversations' && action === 'list')
208
+ return listConversations(context, values.limit === undefined ? 50 : Number(values.limit));
209
+ if (command === 'conversations' && action === 'show')
210
+ return showConversation(context, required('id'), values.limit === undefined ? 60 : Number(values.limit));
211
+ if (command === 'routing' && action === 'show')
212
+ return showRouting(context);
213
+ if (command === 'conversations' && action === 'read')
214
+ return markConversationRead(context, required('id'), required('through'), required('expected-agent'));
215
+ if (command === 'inbox' && action === 'feed')
216
+ return inboxFeed(context, values.limit === undefined ? 30 : Number(values.limit));
217
+ if (command === 'sessions' && action === 'list')
218
+ return listSessions(context);
219
+ if (command === 'autoreply' && action === 'show')
220
+ return showAutoreply(context);
221
+ if (command === 'autoreply' && (action === 'enable' || action === 'disable'))
222
+ return setAutoreply(context, required('peer'), action === 'enable', required('expected-agent'));
223
+ if (command === 'send' && !action) {
224
+ if ([values['text-file'] !== undefined, values['text-stdin'], values['resend-of'] !== undefined].filter(Boolean).length > 1)
225
+ throw new Error('send.input-conflict');
226
+ let text;
227
+ if (values['resend-of'] !== undefined)
228
+ text = undefined;
229
+ else if (values['text-file'] !== undefined)
230
+ text = await (await import('node:fs/promises')).readFile(values['text-file'], 'utf8');
231
+ else if (values['text-stdin']) {
232
+ if (input === process.stdin && process.stdin.isTTY)
233
+ throw new Error('send.stdin-required');
234
+ const chunks = [];
235
+ let size = 0;
236
+ for await (const chunk of input) {
237
+ const bytes = Buffer.from(chunk);
238
+ size += bytes.length;
239
+ if (size > 16384)
240
+ throw new Error('send.text-too-large');
241
+ chunks.push(bytes);
242
+ }
243
+ text = Buffer.concat(chunks).toString('utf8');
244
+ }
245
+ else
246
+ throw new Error('send.input-required');
247
+ return sendDirect(context, { to: required('to'), conversationId: required('conversation'), msgId: required('msg-id'),
248
+ expectedAgent: required('expected-agent'), expectAfter: values['expect-after'], resendOf: values['resend-of'], text });
249
+ }
147
250
  if (command === 'inbox' && action === 'read')
148
251
  return readInbox(context, values.limit === undefined ? 20 : Number(values.limit));
149
252
  if (command === 'inbox' && action === 'mark-read')
@@ -1,16 +1,24 @@
1
1
  import type { PlatformAdapter, ServiceContext } from './types.js';
2
2
  export { sameClientFileIdentity } from './file-identity.js';
3
+ /**
4
+ * Read-only: what Claude Code carries for this profile, for doctor's wake stage (#293).
5
+ * `current` means the installed Stop hook is exactly the one this runtime writes; it says
6
+ * nothing about a live session having been woken, which is a separate proof.
7
+ */
8
+ export declare function claudeWakeHookState(c: ServiceContext, adapter: PlatformAdapter): Promise<'current' | 'outdated' | 'absent'>;
3
9
  /** Read-only preview: even a missing parent directory is not created. */
4
10
  export declare function previewClientConfiguration(c: ServiceContext, adapter: PlatformAdapter, clientId: string): Promise<{
5
11
  wakeHook?: {
12
+ repointed?: string[] | undefined;
6
13
  settingsPath: string;
7
14
  action: "replace" | "unchanged" | "add";
8
15
  } | undefined;
9
16
  schema: string;
10
- client: "claude-code" | "claude-desktop" | "codex-cli" | "codex-desktop";
17
+ client: "claude-code" | "claude-desktop" | "codex-cli" | "codex-desktop" | "cursor" | "gemini";
11
18
  configPath: string;
12
19
  agentId: string;
13
20
  dataDir: string;
21
+ serverName: string;
14
22
  action: string;
15
23
  planId: string;
16
24
  configExisted: boolean;
@@ -21,21 +29,12 @@ export declare function previewClientConfiguration(c: ServiceContext, adapter: P
21
29
  * also install the Stop wake hook, so a delivered message wakes the session without a human turn.
22
30
  */
23
31
  export declare function configureClient(c: ServiceContext, adapter: PlatformAdapter, clientId: string, replace?: boolean, expectedPlan?: string): Promise<{
24
- planId: string;
25
- agentId: string;
26
- dataDir: string;
27
- schema: string;
28
- client: "claude-code" | "claude-desktop" | "codex-cli" | "codex-desktop";
29
- configPath: string;
30
- changed: boolean;
31
- backup: null;
32
- restartRequired: boolean;
33
- } | {
34
- planId?: undefined;
35
- agentId?: undefined;
36
- dataDir?: undefined;
32
+ serverName: string;
33
+ planId?: string | undefined;
34
+ agentId?: string | undefined;
35
+ dataDir?: string | undefined;
37
36
  schema: string;
38
- client: "claude-code" | "claude-desktop" | "codex-cli" | "codex-desktop";
37
+ client: "claude-code" | "claude-desktop" | "codex-cli" | "codex-desktop" | "cursor" | "gemini";
39
38
  configPath: string;
40
39
  changed: boolean;
41
40
  backup: null;
@@ -43,46 +42,15 @@ export declare function configureClient(c: ServiceContext, adapter: PlatformAdap
43
42
  } | {
44
43
  restartRequired: boolean;
45
44
  instruction: string;
46
- planId: string;
47
- agentId: string;
48
- dataDir: string;
45
+ serverName: string;
46
+ planId?: string | undefined;
47
+ agentId?: string | undefined;
48
+ dataDir?: string | undefined;
49
49
  schema: string;
50
- client: "claude-code" | "claude-desktop" | "codex-cli" | "codex-desktop";
50
+ client: "claude-code" | "claude-desktop" | "codex-cli" | "codex-desktop" | "cursor" | "gemini";
51
51
  configPath: string;
52
52
  changed: boolean;
53
53
  backup: string | null;
54
- } | {
55
- restartRequired: boolean;
56
- instruction: string;
57
- planId?: undefined;
58
- agentId?: undefined;
59
- dataDir?: undefined;
60
- schema: string;
61
- client: "claude-code" | "claude-desktop" | "codex-cli" | "codex-desktop";
62
- configPath: string;
63
- changed: boolean;
64
- backup: string | null;
65
- } | {
66
- changed: boolean;
67
- wakeHook: {
68
- settingsPath: string;
69
- action: "unchanged";
70
- changed: boolean;
71
- backup: null;
72
- } | {
73
- settingsPath: string;
74
- action: "replace" | "add";
75
- changed: boolean;
76
- backup: string | null;
77
- };
78
- planId: string;
79
- agentId: string;
80
- dataDir: string;
81
- schema: string;
82
- client: "claude-code" | "claude-desktop" | "codex-cli" | "codex-desktop";
83
- configPath: string;
84
- backup: null;
85
- restartRequired: boolean;
86
54
  } | {
87
55
  changed: boolean;
88
56
  wakeHook: {
@@ -90,17 +58,20 @@ export declare function configureClient(c: ServiceContext, adapter: PlatformAdap
90
58
  action: "unchanged";
91
59
  changed: boolean;
92
60
  backup: null;
61
+ repointed: string[];
93
62
  } | {
94
63
  settingsPath: string;
95
64
  action: "replace" | "add";
96
65
  changed: boolean;
97
66
  backup: string | null;
67
+ repointed: string[];
98
68
  };
99
- planId?: undefined;
100
- agentId?: undefined;
101
- dataDir?: undefined;
69
+ serverName: string;
70
+ planId?: string | undefined;
71
+ agentId?: string | undefined;
72
+ dataDir?: string | undefined;
102
73
  schema: string;
103
- client: "claude-code" | "claude-desktop" | "codex-cli" | "codex-desktop";
74
+ client: "claude-code" | "claude-desktop" | "codex-cli" | "codex-desktop" | "cursor" | "gemini";
104
75
  configPath: string;
105
76
  backup: null;
106
77
  restartRequired: boolean;
@@ -111,41 +82,22 @@ export declare function configureClient(c: ServiceContext, adapter: PlatformAdap
111
82
  action: "unchanged";
112
83
  changed: boolean;
113
84
  backup: null;
85
+ repointed: string[];
114
86
  } | {
115
87
  settingsPath: string;
116
88
  action: "replace" | "add";
117
89
  changed: boolean;
118
90
  backup: string | null;
91
+ repointed: string[];
119
92
  };
120
93
  restartRequired: boolean;
121
94
  instruction: string;
122
- planId: string;
123
- agentId: string;
124
- dataDir: string;
125
- schema: string;
126
- client: "claude-code" | "claude-desktop" | "codex-cli" | "codex-desktop";
127
- configPath: string;
128
- backup: string | null;
129
- } | {
130
- changed: boolean;
131
- wakeHook: {
132
- settingsPath: string;
133
- action: "unchanged";
134
- changed: boolean;
135
- backup: null;
136
- } | {
137
- settingsPath: string;
138
- action: "replace" | "add";
139
- changed: boolean;
140
- backup: string | null;
141
- };
142
- restartRequired: boolean;
143
- instruction: string;
144
- planId?: undefined;
145
- agentId?: undefined;
146
- dataDir?: undefined;
95
+ serverName: string;
96
+ planId?: string | undefined;
97
+ agentId?: string | undefined;
98
+ dataDir?: string | undefined;
147
99
  schema: string;
148
- client: "claude-code" | "claude-desktop" | "codex-cli" | "codex-desktop";
100
+ client: "claude-code" | "claude-desktop" | "codex-cli" | "codex-desktop" | "cursor" | "gemini";
149
101
  configPath: string;
150
102
  backup: string | null;
151
103
  }>;