qlogicagent 2.19.1 → 2.19.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/agent-contract.js +1 -1
- package/dist/cli.js +1 -1
- package/dist/host-contract.js +1 -1
- package/dist/host-session-collection-contract.js +1 -0
- package/dist/index.js +478 -505
- package/dist/pet-host.js +8 -8
- package/dist/project-memory-host.js +23 -23
- package/dist/protocol.js +1 -1
- package/dist/types/cli/acp-commands.d.ts +1 -1
- package/dist/types/cli/acp-extended-handlers.d.ts +2 -8
- package/dist/types/cli/acp-extended-host-adapter.d.ts +0 -11
- package/dist/types/cli/acp-session-host.d.ts +2 -0
- package/dist/types/cli/core-tool-coordinator.d.ts +0 -9
- package/dist/types/cli/default-project-bootstrap.d.ts +2 -32
- package/dist/types/cli/handlers/session-handler.d.ts +0 -43
- package/dist/types/cli/handlers/solo-handler.d.ts +3 -14
- package/dist/types/cli/multi-agent-handler-host.d.ts +3 -16
- package/dist/types/cli/product-coordinator.d.ts +3 -14
- package/dist/types/cli/rpc-registry.d.ts +0 -2
- package/dist/types/cli/stdio-rpc-handler-hosts.d.ts +4 -1
- package/dist/types/cli/stdio-server.d.ts +1 -2
- package/dist/types/host-contract/index.d.ts +110 -18
- package/dist/types/host-session-collection-contract.d.ts +61 -0
- package/dist/types/orchestration/agent-instance.d.ts +4 -11
- package/dist/types/orchestration/agent-roster.d.ts +4 -4
- package/dist/types/orchestration/delegate-bridge.d.ts +8 -0
- package/dist/types/orchestration/goal-mode-adapters.d.ts +3 -3
- package/dist/types/orchestration/product-persistence.d.ts +0 -4
- package/dist/types/orchestration/product-planner.d.ts +4 -6
- package/dist/types/orchestration/solo-evaluator.d.ts +2 -5
- package/dist/types/orchestration/testing/delegate-test-bridge.d.ts +2 -1
- package/dist/types/orchestration/testing/host-agent-provider-directory-fixture.d.ts +7 -0
- package/dist/types/orchestration/workflow/qla-executor-host.d.ts +1 -1
- package/dist/types/protocol/agent-contract.d.ts +9 -3
- package/dist/types/protocol/methods.d.ts +20 -38
- package/dist/types/protocol/notifications.d.ts +1 -1
- package/dist/types/protocol/wire/acp-agent-management.d.ts +2 -190
- package/dist/types/protocol/wire/acp-protocol.d.ts +0 -4
- package/dist/types/protocol/wire/agent-methods.d.ts +1 -243
- package/dist/types/protocol/wire/gateway-rpc.d.ts +343 -15
- package/dist/types/protocol/wire/index.d.ts +3 -3
- package/dist/types/protocol/wire/notification-payloads.d.ts +48 -134
- package/dist/types/runtime/infra/host-agent-provider-directory.d.ts +17 -0
- package/dist/types/runtime/infra/project-authority-facade.d.ts +1 -1
- package/dist/types/runtime/infra/project-data-paths.d.ts +2 -1
- package/dist/types/runtime/infra/project-host-authority.d.ts +3 -2
- package/dist/types/runtime/infra/project-store.d.ts +4 -39
- package/dist/types/runtime/session/session-catalog.d.ts +0 -12
- package/dist/types/runtime/session/session-persistence.d.ts +1 -1
- package/dist/types/runtime/session/session-resource-key.d.ts +1 -1
- package/dist/types/runtime/session/session-types.d.ts +0 -23
- package/dist/types/transport/acp-server.d.ts +2 -10
- package/dist/workflow-host.js +10 -10
- package/package.json +8 -1
- package/dist/types/cli/agent-config-coordinator.d.ts +0 -27
- package/dist/types/cli/agent-config-runtime.d.ts +0 -11
- package/dist/types/cli/agent-status-notifier.d.ts +0 -11
- package/dist/types/cli/handlers/agents-handler.d.ts +0 -126
- package/dist/types/cli/handlers/project-handler.d.ts +0 -36
- package/dist/types/cli/project-command-service.d.ts +0 -28
- package/dist/types/orchestration/delegation-coordinator.d.ts +0 -100
- package/dist/types/runtime/infra/acp-detector.d.ts +0 -273
- package/dist/types/runtime/infra/agent-config-store.d.ts +0 -30
- package/dist/types/runtime/infra/agent-install-runner.d.ts +0 -80
- package/dist/types/runtime/infra/external-agent-approvals.d.ts +0 -59
- package/dist/types/runtime/infra/migrate-device-scope.d.ts +0 -49
- package/dist/types/runtime/infra/project-data-gc.d.ts +0 -15
- package/dist/types/runtime/session/native/claude-session-source.d.ts +0 -23
- package/dist/types/runtime/session/native/codex-index.d.ts +0 -21
- package/dist/types/runtime/session/native/codex-session-source.d.ts +0 -31
- package/dist/types/runtime/session/native/cwd-normalize.d.ts +0 -53
- package/dist/types/runtime/session/native/ephemeral-rollout-sweep.d.ts +0 -13
- package/dist/types/runtime/session/native/native-cwd-agents.d.ts +0 -17
- package/dist/types/runtime/session/native/native-session-source.d.ts +0 -89
- package/dist/types/runtime/session/native/native-title.d.ts +0 -1
- package/dist/types/runtime/session/native/register-builtin-sources.d.ts +0 -1
|
@@ -10,8 +10,109 @@
|
|
|
10
10
|
* Reference: CC uses Zod union in a single package; we use TypeScript interface map
|
|
11
11
|
* in a shared package (same effect — single source, compile-time checked).
|
|
12
12
|
*/
|
|
13
|
+
import type { NativeSessionRef, NativeTranscript } from "../../host-contract/index.js";
|
|
13
14
|
export type ProjectType = "default" | "personal" | "group" | "solo" | "product" | "automation";
|
|
14
|
-
export type ProjectStatus = "active" | "archived";
|
|
15
|
+
export type ProjectStatus = "active" | "detached" | "archived";
|
|
16
|
+
export type ProviderHostMethod = "provider.catalog" | "provider.list" | "provider.get" | "provider.install" | "provider.update" | "provider.uninstall" | "provider.enable" | "provider.disable" | "provider.diagnose" | "provider.auth.status" | "provider.auth.methods" | "provider.auth.start" | "provider.auth.attach" | "provider.auth.input" | "provider.auth.resize" | "provider.auth.cancel" | "provider.auth.logout" | "provider.models.list" | "provider.nativeSessions.list" | "provider.nativeSessions.load" | "provider.nativeSessions.resume";
|
|
17
|
+
export type AgentProviderState = "installed" | "auth_required" | "ready" | "disabled" | "incompatible" | "unresponsive" | "failed";
|
|
18
|
+
export interface AgentProviderDiagnosticWire {
|
|
19
|
+
providerId: string;
|
|
20
|
+
state: "ready" | "not_installed" | "disabled" | "incompatible" | "auth_required" | "unresponsive" | "failed";
|
|
21
|
+
stage: "install" | "manifest" | "auth" | "launch" | "initialize" | "models" | "native_sessions" | "request";
|
|
22
|
+
code: string;
|
|
23
|
+
message: string;
|
|
24
|
+
retryable: boolean;
|
|
25
|
+
providerVersion?: string;
|
|
26
|
+
payloadVersion?: string;
|
|
27
|
+
}
|
|
28
|
+
export interface AgentProviderErrorWire {
|
|
29
|
+
providerId: string;
|
|
30
|
+
stage: AgentProviderDiagnosticWire["stage"];
|
|
31
|
+
code: string;
|
|
32
|
+
message: string;
|
|
33
|
+
retryable: boolean;
|
|
34
|
+
data?: unknown;
|
|
35
|
+
}
|
|
36
|
+
export interface AgentProviderCatalogEntryWire {
|
|
37
|
+
schemaVersion: 1;
|
|
38
|
+
providerId: string;
|
|
39
|
+
displayName: string;
|
|
40
|
+
brandId: string;
|
|
41
|
+
category: "coding" | "assistant" | "custom";
|
|
42
|
+
order: number;
|
|
43
|
+
featured: boolean;
|
|
44
|
+
installPolicy: "builtin" | "managed-package";
|
|
45
|
+
distribution: {
|
|
46
|
+
kind: "builtin";
|
|
47
|
+
} | {
|
|
48
|
+
kind: "npm";
|
|
49
|
+
packageName: string;
|
|
50
|
+
exactVersion: string;
|
|
51
|
+
integrity: `sha512-${string}`;
|
|
52
|
+
mirrorAllowed: boolean;
|
|
53
|
+
} | {
|
|
54
|
+
kind: "signed-bundle";
|
|
55
|
+
artifactId: string;
|
|
56
|
+
exactVersion: string;
|
|
57
|
+
sha256: string;
|
|
58
|
+
};
|
|
59
|
+
expectedManifestDigest?: `sha256:${string}`;
|
|
60
|
+
}
|
|
61
|
+
export interface RegisteredAgentProviderWire {
|
|
62
|
+
providerId: string;
|
|
63
|
+
source: "builtin" | "installed";
|
|
64
|
+
installationId: string;
|
|
65
|
+
manifest: Readonly<Record<string, unknown>>;
|
|
66
|
+
manifestDigest: `sha256:${string}`;
|
|
67
|
+
state: AgentProviderState;
|
|
68
|
+
diagnostic?: AgentProviderDiagnosticWire;
|
|
69
|
+
}
|
|
70
|
+
export interface ProviderAuthTerminalSessionWire {
|
|
71
|
+
authSessionId: string;
|
|
72
|
+
providerId: string;
|
|
73
|
+
ownerId: string;
|
|
74
|
+
authMethodId: string;
|
|
75
|
+
state: "starting" | "interactive" | "verifying" | "succeeded" | "failed" | "cancelled";
|
|
76
|
+
cols: number;
|
|
77
|
+
rows: number;
|
|
78
|
+
exitCode?: number;
|
|
79
|
+
error?: AgentProviderErrorWire;
|
|
80
|
+
createdAt: string;
|
|
81
|
+
updatedAt: string;
|
|
82
|
+
}
|
|
83
|
+
export interface DelegationBindingKey {
|
|
84
|
+
parentSessionId: string;
|
|
85
|
+
providerId: string;
|
|
86
|
+
generation: number;
|
|
87
|
+
}
|
|
88
|
+
export interface DelegationBinding extends DelegationBindingKey {
|
|
89
|
+
bindingId: string;
|
|
90
|
+
projectId: string;
|
|
91
|
+
executionSessionId: string;
|
|
92
|
+
nativeResumeId?: string;
|
|
93
|
+
createdAt: string;
|
|
94
|
+
updatedAt: string;
|
|
95
|
+
revision: number;
|
|
96
|
+
}
|
|
97
|
+
export interface DelegationTurn {
|
|
98
|
+
delegationId: string;
|
|
99
|
+
bindingId: string;
|
|
100
|
+
parentMessageId: string;
|
|
101
|
+
requestId: string;
|
|
102
|
+
sequence: number;
|
|
103
|
+
state: "queued" | "running" | "completed" | "failed" | "cancelled";
|
|
104
|
+
}
|
|
105
|
+
export type DelegationErrorCode = "PROVIDER_NOT_INSTALLED" | "AUTH_REQUIRED" | "PROVIDER_UNAVAILABLE" | "SESSION_CREATE_FAILED" | "SESSION_RESUME_FAILED" | "TURN_FAILED" | "PROTOCOL_ERROR" | "CANCELLED";
|
|
106
|
+
export interface DelegationError {
|
|
107
|
+
code: DelegationErrorCode;
|
|
108
|
+
message: string;
|
|
109
|
+
stage: "validate" | "bind" | "spawn" | "resume" | "turn" | "cancel";
|
|
110
|
+
retryable: boolean;
|
|
111
|
+
providerId: string;
|
|
112
|
+
bindingId?: string;
|
|
113
|
+
delegationId?: string;
|
|
114
|
+
diagnosticId?: string;
|
|
115
|
+
}
|
|
15
116
|
export interface LocalizedTextWire {
|
|
16
117
|
key: string;
|
|
17
118
|
fallback: string;
|
|
@@ -110,6 +211,213 @@ export interface GatewayRpcMethodMap {
|
|
|
110
211
|
cancelled: boolean;
|
|
111
212
|
};
|
|
112
213
|
};
|
|
214
|
+
"provider.catalog": {
|
|
215
|
+
params: Record<string, never>;
|
|
216
|
+
result: {
|
|
217
|
+
providers: AgentProviderCatalogEntryWire[];
|
|
218
|
+
};
|
|
219
|
+
};
|
|
220
|
+
"provider.list": {
|
|
221
|
+
params: Record<string, never>;
|
|
222
|
+
result: {
|
|
223
|
+
providers: RegisteredAgentProviderWire[];
|
|
224
|
+
revision: number;
|
|
225
|
+
};
|
|
226
|
+
};
|
|
227
|
+
"provider.get": {
|
|
228
|
+
params: {
|
|
229
|
+
providerId: string;
|
|
230
|
+
};
|
|
231
|
+
result: {
|
|
232
|
+
provider: RegisteredAgentProviderWire | null;
|
|
233
|
+
revision: number;
|
|
234
|
+
};
|
|
235
|
+
};
|
|
236
|
+
"provider.install": {
|
|
237
|
+
params: {
|
|
238
|
+
providerId: string;
|
|
239
|
+
mirror: "official" | "china";
|
|
240
|
+
};
|
|
241
|
+
result: {
|
|
242
|
+
operationId: string;
|
|
243
|
+
state: AgentProviderState;
|
|
244
|
+
};
|
|
245
|
+
};
|
|
246
|
+
"provider.update": {
|
|
247
|
+
params: {
|
|
248
|
+
providerId: string;
|
|
249
|
+
mirror: "official" | "china";
|
|
250
|
+
};
|
|
251
|
+
result: {
|
|
252
|
+
operationId: string;
|
|
253
|
+
state: AgentProviderState;
|
|
254
|
+
};
|
|
255
|
+
};
|
|
256
|
+
"provider.uninstall": {
|
|
257
|
+
params: {
|
|
258
|
+
providerId: string;
|
|
259
|
+
};
|
|
260
|
+
result: {
|
|
261
|
+
ok: true;
|
|
262
|
+
nativeDataPreserved: true;
|
|
263
|
+
};
|
|
264
|
+
};
|
|
265
|
+
"provider.enable": {
|
|
266
|
+
params: {
|
|
267
|
+
providerId: string;
|
|
268
|
+
};
|
|
269
|
+
result: {
|
|
270
|
+
ok: true;
|
|
271
|
+
};
|
|
272
|
+
};
|
|
273
|
+
"provider.disable": {
|
|
274
|
+
params: {
|
|
275
|
+
providerId: string;
|
|
276
|
+
};
|
|
277
|
+
result: {
|
|
278
|
+
ok: true;
|
|
279
|
+
};
|
|
280
|
+
};
|
|
281
|
+
"provider.diagnose": {
|
|
282
|
+
params: {
|
|
283
|
+
providerId: string;
|
|
284
|
+
};
|
|
285
|
+
result: AgentProviderDiagnosticWire;
|
|
286
|
+
};
|
|
287
|
+
"provider.auth.status": {
|
|
288
|
+
params: {
|
|
289
|
+
providerId: string;
|
|
290
|
+
};
|
|
291
|
+
result: {
|
|
292
|
+
providerId: string;
|
|
293
|
+
preference?: "account" | "userKey" | "managed";
|
|
294
|
+
state: AgentProviderState;
|
|
295
|
+
};
|
|
296
|
+
};
|
|
297
|
+
"provider.auth.methods": {
|
|
298
|
+
params: {
|
|
299
|
+
providerId: string;
|
|
300
|
+
};
|
|
301
|
+
result: {
|
|
302
|
+
methods: Array<{
|
|
303
|
+
id: string;
|
|
304
|
+
label: string;
|
|
305
|
+
kind: "protocol" | "terminal";
|
|
306
|
+
}>;
|
|
307
|
+
};
|
|
308
|
+
};
|
|
309
|
+
"provider.auth.start": {
|
|
310
|
+
params: {
|
|
311
|
+
providerId: string;
|
|
312
|
+
authMethodId: string;
|
|
313
|
+
cols: number;
|
|
314
|
+
rows: number;
|
|
315
|
+
};
|
|
316
|
+
result: {
|
|
317
|
+
session: ProviderAuthTerminalSessionWire;
|
|
318
|
+
replay: string;
|
|
319
|
+
};
|
|
320
|
+
};
|
|
321
|
+
"provider.auth.attach": {
|
|
322
|
+
params: {
|
|
323
|
+
authSessionId: string;
|
|
324
|
+
};
|
|
325
|
+
result: {
|
|
326
|
+
session: ProviderAuthTerminalSessionWire;
|
|
327
|
+
replay: string;
|
|
328
|
+
};
|
|
329
|
+
};
|
|
330
|
+
"provider.auth.input": {
|
|
331
|
+
params: {
|
|
332
|
+
authSessionId: string;
|
|
333
|
+
data: string;
|
|
334
|
+
};
|
|
335
|
+
result: {
|
|
336
|
+
ok: true;
|
|
337
|
+
};
|
|
338
|
+
};
|
|
339
|
+
"provider.auth.resize": {
|
|
340
|
+
params: {
|
|
341
|
+
authSessionId: string;
|
|
342
|
+
cols: number;
|
|
343
|
+
rows: number;
|
|
344
|
+
};
|
|
345
|
+
result: {
|
|
346
|
+
ok: true;
|
|
347
|
+
};
|
|
348
|
+
};
|
|
349
|
+
"provider.auth.cancel": {
|
|
350
|
+
params: {
|
|
351
|
+
authSessionId: string;
|
|
352
|
+
};
|
|
353
|
+
result: {
|
|
354
|
+
ok: true;
|
|
355
|
+
};
|
|
356
|
+
};
|
|
357
|
+
"provider.auth.logout": {
|
|
358
|
+
params: {
|
|
359
|
+
providerId: string;
|
|
360
|
+
};
|
|
361
|
+
result: {
|
|
362
|
+
ok: true;
|
|
363
|
+
};
|
|
364
|
+
};
|
|
365
|
+
"provider.models.list": {
|
|
366
|
+
params: {
|
|
367
|
+
providerId: string;
|
|
368
|
+
};
|
|
369
|
+
result: {
|
|
370
|
+
models: Array<Record<string, unknown>>;
|
|
371
|
+
};
|
|
372
|
+
};
|
|
373
|
+
"provider.nativeSessions.list": {
|
|
374
|
+
params: {
|
|
375
|
+
providerId: string;
|
|
376
|
+
projectId: string;
|
|
377
|
+
limit?: number;
|
|
378
|
+
};
|
|
379
|
+
result: {
|
|
380
|
+
sessions: Array<Record<string, unknown>>;
|
|
381
|
+
};
|
|
382
|
+
};
|
|
383
|
+
"provider.nativeSessions.load": {
|
|
384
|
+
params: {
|
|
385
|
+
providerId: string;
|
|
386
|
+
nativeRef: NativeSessionRef;
|
|
387
|
+
};
|
|
388
|
+
result: NativeTranscript;
|
|
389
|
+
};
|
|
390
|
+
"provider.nativeSessions.resume": {
|
|
391
|
+
params: {
|
|
392
|
+
providerId: string;
|
|
393
|
+
nativeRef: NativeSessionRef;
|
|
394
|
+
parentSessionId: string;
|
|
395
|
+
};
|
|
396
|
+
result: {
|
|
397
|
+
executionSessionId: string;
|
|
398
|
+
nativeResumeId?: string;
|
|
399
|
+
};
|
|
400
|
+
};
|
|
401
|
+
"delegation.cancel": {
|
|
402
|
+
params: {
|
|
403
|
+
parentSessionId: string;
|
|
404
|
+
bindingId: string;
|
|
405
|
+
delegationId: string;
|
|
406
|
+
};
|
|
407
|
+
result: {
|
|
408
|
+
ok: true;
|
|
409
|
+
state: "cancelled";
|
|
410
|
+
};
|
|
411
|
+
};
|
|
412
|
+
"delegation.reset": {
|
|
413
|
+
params: {
|
|
414
|
+
parentSessionId: string;
|
|
415
|
+
providerId: string;
|
|
416
|
+
};
|
|
417
|
+
result: {
|
|
418
|
+
binding: DelegationBinding;
|
|
419
|
+
};
|
|
420
|
+
};
|
|
113
421
|
"session.list": {
|
|
114
422
|
params: {
|
|
115
423
|
limit?: number;
|
|
@@ -131,11 +439,7 @@ export interface GatewayRpcMethodMap {
|
|
|
131
439
|
projectId: string;
|
|
132
440
|
agentId?: string;
|
|
133
441
|
source?: "native";
|
|
134
|
-
nativeRef?:
|
|
135
|
-
agentId: string;
|
|
136
|
-
kind: "codex" | "claude";
|
|
137
|
-
file: string;
|
|
138
|
-
};
|
|
442
|
+
nativeRef?: NativeSessionRef;
|
|
139
443
|
sealedAt?: string | null;
|
|
140
444
|
previousSessionId?: string | null;
|
|
141
445
|
carryoverSummary?: string | null;
|
|
@@ -215,6 +519,22 @@ export interface GatewayRpcMethodMap {
|
|
|
215
519
|
ok: boolean;
|
|
216
520
|
};
|
|
217
521
|
};
|
|
522
|
+
"session.loadNativeTranscript": {
|
|
523
|
+
params: {
|
|
524
|
+
nativeRef: NativeSessionRef;
|
|
525
|
+
};
|
|
526
|
+
result: NativeTranscript;
|
|
527
|
+
};
|
|
528
|
+
"session.adoptNative": {
|
|
529
|
+
params: {
|
|
530
|
+
nativeRef: NativeSessionRef;
|
|
531
|
+
};
|
|
532
|
+
result: {
|
|
533
|
+
canonicalSessionId: string;
|
|
534
|
+
created: boolean;
|
|
535
|
+
title?: string;
|
|
536
|
+
};
|
|
537
|
+
};
|
|
218
538
|
"session.moveToProject": {
|
|
219
539
|
params: {
|
|
220
540
|
sessionId: string;
|
|
@@ -275,15 +595,30 @@ export interface GatewayRpcMethodMap {
|
|
|
275
595
|
deduplicated?: boolean;
|
|
276
596
|
};
|
|
277
597
|
};
|
|
278
|
-
"project.
|
|
598
|
+
"project.detach": {
|
|
279
599
|
params: {
|
|
280
600
|
projectId: string;
|
|
281
601
|
};
|
|
282
602
|
result: {
|
|
283
|
-
ok:
|
|
603
|
+
ok: true;
|
|
604
|
+
project: ProjectInfo & {
|
|
605
|
+
status: "detached";
|
|
606
|
+
};
|
|
284
607
|
switchedTo?: ProjectInfo;
|
|
285
608
|
};
|
|
286
609
|
};
|
|
610
|
+
"project.delete": {
|
|
611
|
+
params: {
|
|
612
|
+
projectId: string;
|
|
613
|
+
};
|
|
614
|
+
result: {
|
|
615
|
+
ok: true;
|
|
616
|
+
deleted: true;
|
|
617
|
+
internalDataDeleted: true;
|
|
618
|
+
workspacePreserved: true;
|
|
619
|
+
providerNativeSessionsPreserved: true;
|
|
620
|
+
};
|
|
621
|
+
};
|
|
287
622
|
"project.rename": {
|
|
288
623
|
params: {
|
|
289
624
|
projectId: string;
|
|
@@ -323,13 +658,6 @@ export interface GatewayRpcMethodMap {
|
|
|
323
658
|
ok: boolean;
|
|
324
659
|
};
|
|
325
660
|
};
|
|
326
|
-
"project.purgeAll": {
|
|
327
|
-
params: Record<string, never>;
|
|
328
|
-
result: {
|
|
329
|
-
ok: boolean;
|
|
330
|
-
deletedCount?: number;
|
|
331
|
-
};
|
|
332
|
-
};
|
|
333
661
|
"instructions.list": {
|
|
334
662
|
params: {
|
|
335
663
|
projectId?: string;
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
export { PETDEX_ANIMATION_IDS, type PetdexAnimationId, } from "./pet-contracts.js";
|
|
2
2
|
export { AGENT_RPC_APPROVAL_METHODS, AGENT_RPC_ERROR_CODES, AGENT_RPC_PROTOCOL_VERSION, isAgentRpcNotification, isAgentRpcRequest, isAgentRpcResponse, parseAgentRpcMessage, type AgentHelloParams, type AgentHelloResult, type AgentRpcError, type AgentRpcErrorCode, type AgentRpcMeta, type AgentRpcChannel, type AgentRpcMessage, type AgentRpcNotification, type AgentRpcRequest, type AgentRpcResponse, type ToolApprovalRequestParams, } from "./agent-rpc.js";
|
|
3
3
|
export { GatewayRpcContract, buildAgentRpcMeta, classifyGatewayRpcMethod, requireGatewayRpcMeta, requiresIdempotencyKey, type GatewayRpcClassification, type GatewayRpcMetrics, type GatewayRpcMutability, } from "./gateway-contract.js";
|
|
4
|
-
export { GATEWAY_RPC_METHODS, type AgentCall, type AgentCallOptions, type GatewayRpcMethodMap, type ProjectInfo as RpcProjectInfo, type ProjectStatus as RpcProjectStatus, type ProjectType as RpcProjectType, } from "./gateway-rpc.js";
|
|
4
|
+
export { GATEWAY_RPC_METHODS, type AgentCall, type AgentCallOptions, type GatewayRpcMethodMap, type AgentProviderCatalogEntryWire, type AgentProviderDiagnosticWire, type AgentProviderErrorWire, type AgentProviderState, type DelegationBinding, type DelegationBindingKey, type DelegationError, type DelegationErrorCode, type DelegationTurn, type ProviderAuthTerminalSessionWire, type ProviderHostMethod, type RegisteredAgentProviderWire, type ProjectInfo as RpcProjectInfo, type ProjectStatus as RpcProjectStatus, type ProjectType as RpcProjectType, } from "./gateway-rpc.js";
|
|
5
5
|
export { type ChatMessage, type ChatMessageRole, type LocalizedToolText, type ThinkingBlock, type ToolCapabilityCategory, type ToolCallMessage, type ToolDefinition, } from "./chat-types.js";
|
|
6
|
-
export { type
|
|
6
|
+
export { type AgentRpcMethodMap, type ProductInstanceDef, type ProductPhase, type ProductStatus, type ProductSummary, type ProductTaskDef, type ProductTaskStatus, type SoloAgentResult, type SoloAgentState, type SoloState, type SoloStatus, } from "./agent-methods.js";
|
|
7
7
|
export type * from "./acp-agent-management.js";
|
|
8
8
|
export { AGENT_TEAM_WS_EVENT_NAMES, AGENT_WS_EVENT_NAMES, ALL_AGENT_WS_EVENT_NAMES, type AgentTeamWsEventName, type AgentWsEventName, type AllAgentWsEventName, } from "./agent-events.js";
|
|
9
|
-
export { type AgentSource, type
|
|
9
|
+
export { type AgentSource, type ArtifactType, type MediaResultType, type MemoryDecayCompletedNotification, type MemoryUpdatedNotification, type NotificationMethod, type NotificationMethodMap, type NotificationThreadItem, type PermissionRuleUpdatedNotification, type PlanInterruptedNotification, type PongNotification, type ProductBudgetUpdateNotification, type ProductBudgetWarningNotification, type ProductCheckpointedNotification, type ProductCompletedNotification, type ProductDagTopologyNotification, type ProductTaskCompletedNotification, type ProductTaskFailedNotification, type ProductTaskOutputDeltaNotification, type ProductMembersNotification, type ProductAgentActivityNotification, type ProductTaskStartedNotification, type ProjectArchivedNotification, type ProjectCreatedNotification, type ProjectDeletedNotification, type ProjectDetachedNotification, type ProjectAttachedNotification, type ProjectRenamedNotification, type ProjectSwitchedNotification, type ProjectUnarchivedNotification, type SessionInfoNotification, type SessionRecoveryPendingNotification, type SoloAgentDeltaNotification, type SoloAgentUsageNotification, type SoloEvaluationNotification, type SoloProgressNotification, type TeamMemberNotification, type ToolApprovalRequestNotification, type TurnAnnotationsNotification, type TurnArtifactContractNotification, type TurnArtifactNotification, type TurnAskUserNotification, type TurnDeltaNotification, type TurnEndNotification, type TurnErrorNotification, type TurnExecProgressNotification, type TurnHeartbeatNotification, type TurnMediaPersistedNotification, type TurnMediaProgressNotification, type TurnMediaResultNotification, type TurnPlanUpdateNotification, type TurnProgressNotification, type TurnReasoningDeltaNotification, type TurnRecoveryNotification, type TurnSidechainCompletedNotification, type TurnSidechainStartedNotification, type TurnSkillAcquisitionNeededNotification, type TurnSkillInstructionNotification, type TurnStartNotification, type TurnSubagentDeltaNotification, type TurnSubagentEndedNotification, type TurnSubagentStartedNotification, type TurnSuggestionsNotification, type TurnTaskUpdatedNotification, type TurnTodosUpdatedNotification, type TurnToolBlockedNotification, type TurnToolCallNotification, type TurnToolResultNotification, type TurnToolUseSummaryNotification, type TurnUsageUpdateNotification, type WireTokenUsage, type ProductPlanReadyNotification, type ProductPlanFailedNotification, type ProductPlanningDeltaNotification, type ProductLeaderMessageNotification, type ProductPlanningAskNotification, type GoalRoundMessageNotification, type MentionDelegateStartedNotification, type MentionDelegateActivityNotification, type MentionDelegateSettledNotification, type PetSoulReadyNotification, type PetReactionNotification, type PetGrowthNotification, type PetStateNotification, type PetConfirmNotification, type WorkflowDeletedNotification, type WorkflowRecordNotification, type WorkflowRunCompletedNotification, type WorkflowRunFailedNotification, type WorkflowRunStartedNotification, } from "./notification-payloads.js";
|
|
10
10
|
export { ACP_EXTENDED_METHODS, ACP_EXTENDED_SESSION_UPDATE_TYPES, ACP_METHODS, ACP_PROTOCOL_VERSION, ACP_SESSION_UPDATE_TYPES, isAcpJsonRpcNotification, isAcpJsonRpcRequest, isAcpJsonRpcResponse, isExtendedSessionUpdateType, isStandardSessionUpdateType, parseAcpMessage, type AcpAgentCapabilities, type AcpAgentMessageChunkPayload, type AcpAgentThoughtChunkPayload, type AcpConfigOptionDescriptor, type AcpConfigOptionUpdatePayload, type AcpContentBlock, type AcpEndTurnPayload, type AcpExtendedMethod, type AcpExtendedSessionUpdateType, type AcpFsReadTextFileParams, type AcpFsReadTextFileResult, type AcpFsWriteTextFileParams, type AcpFsWriteTextFileResult, type AcpHostCapabilities, type AcpInitializeParams, type AcpInitializeResult, type AcpJsonRpcError, type AcpJsonRpcMessage, type AcpJsonRpcNotification, type AcpJsonRpcRequest, type AcpJsonRpcResponse, type AcpMode, type AcpPermissionOption, type AcpPermissionRequestParams, type AcpPermissionRequestResult, type AcpPlanPayload, type AcpSessionCancelParams, type AcpSessionCloseParams, type AcpSessionMeta, type AcpSessionLoadParams, type AcpSessionModeState, type AcpSessionNewParams, type AcpSessionNewResult, type AcpSessionPromptParams, type AcpSessionPromptResult, type AcpSessionSetConfigParams, type AcpSessionUpdateNotification, type AcpSessionUpdateType, type AcpStandardMethod, type AcpStandardSessionUpdateType, type AcpStopReason, type AcpToolCallPayload, type AcpToolCallUpdatePayload, type AcpUsage, type AcpUsageUpdatePayload, type AcpXSessionInfoPayload, type AcpXSkillInstructionPayload, } from "./acp-protocol.js";
|
|
11
11
|
export { type ApprovalRequiredToolContract, type ModelSelectionReason, type PendingPromptContract, type RuntimeCapabilitySummaryContract, type RuntimeSessionContract, type SessionIdentityContract, } from "./session.js";
|
|
12
12
|
export { type GatewayChannelExecutionEgressContract, type GatewayChannelExecutionEgressKind, type GatewayChannelExecutionIngressBindingContract, type GatewayChannelExecutionIngressSource, } from "./channel-ingress.js";
|
|
@@ -11,6 +11,7 @@
|
|
|
11
11
|
* 3. Add event name string in agent-events.ts (if WS-relayed)
|
|
12
12
|
*/
|
|
13
13
|
import type { ToolRiskLevel } from "./web-capability.js";
|
|
14
|
+
import type { DelegationError } from "./gateway-rpc.js";
|
|
14
15
|
/** Identifies which agent produced this notification (main or teammate). */
|
|
15
16
|
export interface AgentSource {
|
|
16
17
|
id: string;
|
|
@@ -547,125 +548,6 @@ export interface TurnUsageUpdateNotification {
|
|
|
547
548
|
model?: string;
|
|
548
549
|
sessionCostUSD?: number;
|
|
549
550
|
}
|
|
550
|
-
/** Agent status change notification. */
|
|
551
|
-
export interface AgentsStatusNotification {
|
|
552
|
-
agentId: string;
|
|
553
|
-
status: "available" | "spawning" | "running" | "hang" | "failed" | "unavailable";
|
|
554
|
-
health?: {
|
|
555
|
-
missedBeats: number;
|
|
556
|
-
lastActiveAt: string;
|
|
557
|
-
};
|
|
558
|
-
usage?: {
|
|
559
|
-
inputTokens: number;
|
|
560
|
-
outputTokens: number;
|
|
561
|
-
totalTokens: number;
|
|
562
|
-
};
|
|
563
|
-
error?: {
|
|
564
|
-
phase: string;
|
|
565
|
-
message: string;
|
|
566
|
-
retriesLeft: number;
|
|
567
|
-
};
|
|
568
|
-
}
|
|
569
|
-
/** Agent error notification. */
|
|
570
|
-
export interface AgentsErrorNotification {
|
|
571
|
-
agentId: string;
|
|
572
|
-
phase: "detect" | "spawn" | "handshake" | "runtime" | "shutdown" | "heartbeat";
|
|
573
|
-
error: string;
|
|
574
|
-
retriesLeft: number;
|
|
575
|
-
}
|
|
576
|
-
/** One-click install progress (state transitions + streamed log lines + final result). */
|
|
577
|
-
export interface AgentInstallProgressNotification {
|
|
578
|
-
agentId: string;
|
|
579
|
-
event: {
|
|
580
|
-
type: "state";
|
|
581
|
-
state: "installing" | "verifying" | "installed" | "failed";
|
|
582
|
-
} | {
|
|
583
|
-
type: "log";
|
|
584
|
-
stream: "stdout" | "stderr";
|
|
585
|
-
chunk: string;
|
|
586
|
-
} | {
|
|
587
|
-
type: "done";
|
|
588
|
-
ok: boolean;
|
|
589
|
-
error?: string;
|
|
590
|
-
};
|
|
591
|
-
}
|
|
592
|
-
/**
|
|
593
|
-
* Live streaming chunk from an EXTERNAL agent's prompt turn (agents.prompt). Echoes the gateway's
|
|
594
|
-
* turn identity (sessionId/turnId/requestId passed in agents.prompt params) so the gateway can
|
|
595
|
-
* re-emit it on the same turn.delta path the main agent uses — no separate frontend handling.
|
|
596
|
-
*/
|
|
597
|
-
export interface AgentsPromptDeltaNotification {
|
|
598
|
-
agentId: string;
|
|
599
|
-
sessionId?: string;
|
|
600
|
-
turnId?: string;
|
|
601
|
-
requestId?: string;
|
|
602
|
-
text: string;
|
|
603
|
-
/** When true this chunk is the agent's reasoning/thinking (→ turn.reasoning_delta), not reply text. */
|
|
604
|
-
reasoning?: boolean;
|
|
605
|
-
}
|
|
606
|
-
/**
|
|
607
|
-
* Live tool-call lifecycle from an EXTERNAL agent's prompt turn — same echo-the-turn-identity
|
|
608
|
-
* mechanism as AgentsPromptDeltaNotification, so the gateway re-emits it on the main
|
|
609
|
-
* turn.tool_call / turn.tool_result path and the UI shows external tools running, no extra handling.
|
|
610
|
-
*/
|
|
611
|
-
export interface AgentsPromptToolNotification {
|
|
612
|
-
agentId: string;
|
|
613
|
-
sessionId?: string;
|
|
614
|
-
turnId?: string;
|
|
615
|
-
requestId?: string;
|
|
616
|
-
event: {
|
|
617
|
-
kind: "call";
|
|
618
|
-
callId: string;
|
|
619
|
-
name: string;
|
|
620
|
-
arguments?: string;
|
|
621
|
-
inputSummary?: string;
|
|
622
|
-
} | {
|
|
623
|
-
kind: "result";
|
|
624
|
-
callId: string;
|
|
625
|
-
name: string;
|
|
626
|
-
ok: boolean;
|
|
627
|
-
outputPreview?: string;
|
|
628
|
-
error?: string;
|
|
629
|
-
};
|
|
630
|
-
}
|
|
631
|
-
/**
|
|
632
|
-
* Plan/task update from an EXTERNAL agent's prompt turn (ACP plan steps). The gateway maps the
|
|
633
|
-
* steps onto the main turn.task_updated path so the UI shows the agent's plan as a task list.
|
|
634
|
-
*/
|
|
635
|
-
export interface AgentsPromptPlanNotification {
|
|
636
|
-
agentId: string;
|
|
637
|
-
sessionId?: string;
|
|
638
|
-
turnId?: string;
|
|
639
|
-
requestId?: string;
|
|
640
|
-
steps: Array<{
|
|
641
|
-
content?: string;
|
|
642
|
-
title?: string;
|
|
643
|
-
status?: string;
|
|
644
|
-
priority?: string;
|
|
645
|
-
}>;
|
|
646
|
-
}
|
|
647
|
-
/**
|
|
648
|
-
* Interactive permission request from an EXTERNAL agent's prompt turn. Echoes the gateway's turn
|
|
649
|
-
* identity so the gateway re-emits it on the main turn.approval_request path → the UI shows an
|
|
650
|
-
* approval card; the user's decision returns via the agents.approvalResponse RPC.
|
|
651
|
-
*/
|
|
652
|
-
export interface AgentsPromptApprovalNotification {
|
|
653
|
-
agentId: string;
|
|
654
|
-
sessionId?: string;
|
|
655
|
-
turnId?: string;
|
|
656
|
-
requestId?: string;
|
|
657
|
-
approvalId: string;
|
|
658
|
-
callId?: string;
|
|
659
|
-
toolName: string;
|
|
660
|
-
arguments?: string;
|
|
661
|
-
message?: string;
|
|
662
|
-
category?: string;
|
|
663
|
-
options?: Array<{
|
|
664
|
-
optionId: string;
|
|
665
|
-
name?: string;
|
|
666
|
-
kind?: string;
|
|
667
|
-
}>;
|
|
668
|
-
}
|
|
669
551
|
/** Solo agent progress. */
|
|
670
552
|
export interface SoloProgressNotification {
|
|
671
553
|
soloId: string;
|
|
@@ -859,6 +741,29 @@ export interface ProjectSwitchedNotification {
|
|
|
859
741
|
export interface ProjectDeletedNotification {
|
|
860
742
|
id: string;
|
|
861
743
|
}
|
|
744
|
+
export interface ProjectDetachedNotification {
|
|
745
|
+
project: {
|
|
746
|
+
id: string;
|
|
747
|
+
name: string;
|
|
748
|
+
workspaceDir: string;
|
|
749
|
+
type: string;
|
|
750
|
+
status: "detached";
|
|
751
|
+
};
|
|
752
|
+
switchedTo?: {
|
|
753
|
+
id: string;
|
|
754
|
+
name: string;
|
|
755
|
+
workspaceDir: string;
|
|
756
|
+
};
|
|
757
|
+
}
|
|
758
|
+
export interface ProjectAttachedNotification {
|
|
759
|
+
project: {
|
|
760
|
+
id: string;
|
|
761
|
+
name: string;
|
|
762
|
+
workspaceDir: string;
|
|
763
|
+
type: string;
|
|
764
|
+
status: "active";
|
|
765
|
+
};
|
|
766
|
+
}
|
|
862
767
|
/** A project was renamed. */
|
|
863
768
|
export interface ProjectRenamedNotification {
|
|
864
769
|
id: string;
|
|
@@ -1058,27 +963,41 @@ export interface GoalRoundMessageNotification {
|
|
|
1058
963
|
};
|
|
1059
964
|
}
|
|
1060
965
|
export interface MentionDelegateStartedNotification {
|
|
1061
|
-
|
|
966
|
+
parentSessionId: string;
|
|
967
|
+
parentMessageId: string;
|
|
968
|
+
bindingId: string;
|
|
969
|
+
executionSessionId: string;
|
|
1062
970
|
delegationId: string;
|
|
1063
|
-
|
|
971
|
+
sequence: number;
|
|
972
|
+
providerId: string;
|
|
973
|
+
revision: number;
|
|
1064
974
|
brief?: string;
|
|
1065
|
-
productId?: string;
|
|
1066
|
-
suppressAgentContext?: boolean;
|
|
1067
975
|
}
|
|
1068
976
|
export interface MentionDelegateActivityNotification {
|
|
1069
|
-
|
|
977
|
+
parentSessionId: string;
|
|
978
|
+
parentMessageId: string;
|
|
979
|
+
bindingId: string;
|
|
980
|
+
executionSessionId: string;
|
|
1070
981
|
delegationId: string;
|
|
982
|
+
sequence: number;
|
|
983
|
+
providerId: string;
|
|
984
|
+
revision: number;
|
|
1071
985
|
toolName?: string;
|
|
1072
986
|
delta?: string;
|
|
1073
987
|
}
|
|
1074
988
|
export interface MentionDelegateSettledNotification {
|
|
1075
|
-
|
|
989
|
+
parentSessionId: string;
|
|
990
|
+
parentMessageId: string;
|
|
991
|
+
bindingId: string;
|
|
992
|
+
executionSessionId: string;
|
|
1076
993
|
delegationId: string;
|
|
1077
|
-
|
|
994
|
+
sequence: number;
|
|
995
|
+
providerId: string;
|
|
996
|
+
revision: number;
|
|
1078
997
|
status: "completed" | "failed" | "cancelled";
|
|
1079
998
|
changedFiles?: string[];
|
|
1080
999
|
finalText?: string;
|
|
1081
|
-
error?:
|
|
1000
|
+
error?: DelegationError;
|
|
1082
1001
|
}
|
|
1083
1002
|
export interface NotificationMethodMap {
|
|
1084
1003
|
"turn.start": TurnStartNotification;
|
|
@@ -1132,13 +1051,6 @@ export interface NotificationMethodMap {
|
|
|
1132
1051
|
"team.member.notification": TeamMemberNotification;
|
|
1133
1052
|
"turn.usage_update": TurnUsageUpdateNotification;
|
|
1134
1053
|
"pong": PongNotification;
|
|
1135
|
-
"agents.status": AgentsStatusNotification;
|
|
1136
|
-
"agents.error": AgentsErrorNotification;
|
|
1137
|
-
"agent.install.progress": AgentInstallProgressNotification;
|
|
1138
|
-
"agents.prompt.delta": AgentsPromptDeltaNotification;
|
|
1139
|
-
"agents.prompt.tool": AgentsPromptToolNotification;
|
|
1140
|
-
"agents.prompt.approval": AgentsPromptApprovalNotification;
|
|
1141
|
-
"agents.prompt.plan": AgentsPromptPlanNotification;
|
|
1142
1054
|
"solo.progress": SoloProgressNotification;
|
|
1143
1055
|
"solo.evaluation": SoloEvaluationNotification;
|
|
1144
1056
|
"solo.agentDelta": SoloAgentDeltaNotification;
|
|
@@ -1171,6 +1083,8 @@ export interface NotificationMethodMap {
|
|
|
1171
1083
|
"mention.delegate_settled": MentionDelegateSettledNotification;
|
|
1172
1084
|
"project.created": ProjectCreatedNotification;
|
|
1173
1085
|
"project.switched": ProjectSwitchedNotification;
|
|
1086
|
+
"project.detached": ProjectDetachedNotification;
|
|
1087
|
+
"project.attached": ProjectAttachedNotification;
|
|
1174
1088
|
"project.deleted": ProjectDeletedNotification;
|
|
1175
1089
|
"project.renamed": ProjectRenamedNotification;
|
|
1176
1090
|
"project.archived": ProjectArchivedNotification;
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { type HostAgentProviderDiagnostic, type HostAgentProviderGetResult, type HostAgentProviderListResult, type HostProviderRequestParams } from "../../host-contract/index.js";
|
|
2
|
+
export type HostProviderDirectoryErrorCode = "HOST_PROVIDER_DIRECTORY_UNAVAILABLE" | "HOST_PROVIDER_DIRECTORY_INVALID_RESPONSE";
|
|
3
|
+
export declare class HostProviderDirectoryError extends Error {
|
|
4
|
+
readonly code: HostProviderDirectoryErrorCode;
|
|
5
|
+
constructor(code: HostProviderDirectoryErrorCode, message: string, options?: ErrorOptions);
|
|
6
|
+
}
|
|
7
|
+
export interface HostProviderDirectoryRequester {
|
|
8
|
+
request(params: HostProviderRequestParams): Promise<unknown>;
|
|
9
|
+
}
|
|
10
|
+
export declare class HostAgentProviderDirectory {
|
|
11
|
+
private readonly requester;
|
|
12
|
+
constructor(requester: HostProviderDirectoryRequester);
|
|
13
|
+
list(): Promise<Readonly<HostAgentProviderListResult>>;
|
|
14
|
+
get(providerId: string): Promise<Readonly<HostAgentProviderGetResult>>;
|
|
15
|
+
diagnose(providerId: string): Promise<Readonly<HostAgentProviderDiagnostic>>;
|
|
16
|
+
private read;
|
|
17
|
+
}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/**
|
|
1
|
+
/** Project mutations are requests to the Gateway-owned X7 authority. */
|
|
2
2
|
import type { ProjectInfo, ProjectType } from "../../protocol/methods.js";
|
|
3
3
|
export declare function createProjectAuthoritative(params: {
|
|
4
4
|
name: string;
|