@ai-matrx/desktop-protocol 0.21.21 → 0.21.22

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/index.d.ts CHANGED
@@ -1,6 +1,6 @@
1
1
  import { z } from 'zod';
2
- import { O as OpName } from './models-ZQtKshfc.js';
3
- export { B as BEARER_PREFIX, g as CLOSE_RULES, h as CancelMsg, j as ClientToCoreMsg, e as ClientType, k as CloseAction, l as CloseCode, m as CloseCodeValue, C as CloseOutcome, n as CloseRule, o as CoreToClientMsg, p as CreditMsg, D as DesktopProtocolError, d as EVENTS, q as EndMsg, E as EndReason, r as ErrorCode, s as ErrorCodeName, t as ErrorData, u as ErrorMsg, v as ErrorReason, w as ErrorReasonName, x as EventMsg, y as EventName, F as FsPatchEditFailure, H as HelloMsg, L as Limits, z as MlInstallPhase, A as MlInstallProgress, f as MlProgress, G as MlRuntimeState, I as MlServiceState, J as MlServiceStatus, K as MlStatusParams, N as MlStatusResult, P as ModelsInstallParams, Q as ModelsInstallResult, R as ModelsProgressEvent, U as ModelsStatusParams, V as ModelsStatusResult, X as ModelsTranscribeParams, M as ModelsTranscribeResult, Y as NAMED_SCHEMAS, Z as NamedSchemaId, c as OPS, _ as OpDescriptor, a as OpParams, b as OpResult, $ as OpSpec, a0 as PING_TEXT, a1 as PONG_TEXT, a2 as ProtocolErrorBody, a3 as RelayMsg, a4 as RequestMsg, a5 as ResponseMsg, a6 as SERVICES, a7 as SUBPROTOCOL, a8 as ServiceId, a9 as ServiceOpName, aa as ServiceOpSpec, ab as ServiceSpec, S as StreamMeta, ac as StreamMsg, ad as TranscriptSegment, T as TranscriptionModelId, ae as TranscriptionModelInfo, W as Welcome, af as closeRule, i as isDesktopProtocolError, ag as isTerminalClose } from './models-ZQtKshfc.js';
2
+ import { O as OpName } from './models-qdApKBdY.js';
3
+ export { B as BEARER_PREFIX, g as CLOSE_RULES, h as CancelMsg, j as ClientToCoreMsg, e as ClientType, k as CloseAction, l as CloseCode, m as CloseCodeValue, C as CloseOutcome, n as CloseRule, o as CoreToClientMsg, p as CreditMsg, D as DesktopProtocolError, d as EVENTS, q as EndMsg, E as EndReason, r as ErrorCode, s as ErrorCodeName, t as ErrorData, u as ErrorMsg, v as ErrorReason, w as ErrorReasonName, x as EventMsg, y as EventName, F as FsPatchEditFailure, H as HelloMsg, L as Limits, z as MlInstallPhase, A as MlInstallProgress, f as MlProgress, G as MlRuntimeState, I as MlServiceState, J as MlServiceStatus, K as MlStatusParams, N as MlStatusResult, P as ModelsInstallParams, Q as ModelsInstallResult, R as ModelsProgressEvent, U as ModelsStatusParams, V as ModelsStatusResult, X as ModelsTranscribeParams, M as ModelsTranscribeResult, Y as NAMED_SCHEMAS, Z as NamedSchemaId, c as OPS, _ as OpDescriptor, a as OpParams, b as OpResult, $ as OpSpec, a0 as PING_TEXT, a1 as PONG_TEXT, a2 as ProtocolErrorBody, a3 as RelayMsg, a4 as RequestMsg, a5 as ResponseMsg, a6 as SERVICES, a7 as SUBPROTOCOL, a8 as ServiceId, a9 as ServiceOpName, aa as ServiceOpSpec, ab as ServiceSpec, S as StreamMeta, ac as StreamMsg, ad as TranscriptSegment, T as TranscriptionModelId, ae as TranscriptionModelInfo, W as Welcome, af as closeRule, i as isDesktopProtocolError, ag as isTerminalClose } from './models-qdApKBdY.js';
4
4
  export { BROADCAST_CID, DecodedFrame, FRAME_HEADER_BYTES, FRAME_STRUCT_FORMAT, FRAME_VERSION, FrameChannel, FrameChannelValue, FrameFlag, assertFrameHeader, connectionEndFrame, decodeFrame, encodeFrame, hasFlag, isConnectionEnd, readCid, stampCid } from './frame.js';
5
5
 
6
6
  /** @ai-matrx/desktop-protocol — version and primitive schemas. Schema source: lint-enforced rules in scripts/check-schema-source.mjs. */
@@ -49,10 +49,14 @@ declare const PROTOCOL_MAJOR: 1;
49
49
  * apps.windows.reopen and apps.windows.update_and_reopen (quit all, install, reopen all).
50
50
  * 1.27 — AppsWindowsUpdateStateResult.closed_by_update: the closed windows the update itself quit
51
51
  * (the app's log says it went down for the update), apart from ones a person closed.
52
+ * 1.28 — the `browser` capability: the AI Matrx extension as a client (browser.register, result,
53
+ * progress), the Browsers screen (browser.sessions, disconnect, set_enabled, pair_code,
54
+ * pair_reset), agents' browser.call, events browser.invoke / sessions_changed / progress,
55
+ * and the browser_* / awaiting_confirmation error reasons (REASONS_SINCE).
52
56
  */
53
- declare const PROTOCOL_MINOR: 27;
57
+ declare const PROTOCOL_MINOR: 28;
54
58
  /** This package's version as the wire spells it ("major.minor"): hello, welcome, relay status. */
55
- declare const PROTOCOL_VERSION: "1.27";
59
+ declare const PROTOCOL_VERSION: "1.28";
56
60
  /** Internal building blocks — deliberately unnamed in $defs (inlined wherever used). */
57
61
  declare const u32: z.ZodInt;
58
62
  declare const nonNegInt: z.ZodInt;
@@ -1044,6 +1048,11 @@ declare const RelayCallResponse: z.ZodDiscriminatedUnion<[z.ZodObject<{
1044
1048
  service_starting: "service_starting";
1045
1049
  service_restarted: "service_restarted";
1046
1050
  service_failed: "service_failed";
1051
+ browser_not_connected: "browser_not_connected";
1052
+ browser_ambiguous: "browser_ambiguous";
1053
+ browser_account_mismatch: "browser_account_mismatch";
1054
+ browser_connection_off: "browser_connection_off";
1055
+ awaiting_confirmation: "awaiting_confirmation";
1047
1056
  }>>;
1048
1057
  cap: z.ZodOptional<z.ZodString>;
1049
1058
  op: z.ZodOptional<z.ZodString>;
@@ -2954,6 +2963,11 @@ declare const ServiceErrorMsg: z.ZodObject<{
2954
2963
  service_starting: "service_starting";
2955
2964
  service_restarted: "service_restarted";
2956
2965
  service_failed: "service_failed";
2966
+ browser_not_connected: "browser_not_connected";
2967
+ browser_ambiguous: "browser_ambiguous";
2968
+ browser_account_mismatch: "browser_account_mismatch";
2969
+ browser_connection_off: "browser_connection_off";
2970
+ awaiting_confirmation: "awaiting_confirmation";
2957
2971
  }>>;
2958
2972
  cap: z.ZodOptional<z.ZodString>;
2959
2973
  op: z.ZodOptional<z.ZodString>;
@@ -3089,6 +3103,11 @@ declare const ServiceToCoreMsg: z.ZodDiscriminatedUnion<[z.ZodObject<{
3089
3103
  service_starting: "service_starting";
3090
3104
  service_restarted: "service_restarted";
3091
3105
  service_failed: "service_failed";
3106
+ browser_not_connected: "browser_not_connected";
3107
+ browser_ambiguous: "browser_ambiguous";
3108
+ browser_account_mismatch: "browser_account_mismatch";
3109
+ browser_connection_off: "browser_connection_off";
3110
+ awaiting_confirmation: "awaiting_confirmation";
3092
3111
  }>>;
3093
3112
  cap: z.ZodOptional<z.ZodString>;
3094
3113
  op: z.ZodOptional<z.ZodString>;
@@ -5248,6 +5267,305 @@ declare const CodingHistoryProgressEvent: z.ZodObject<{
5248
5267
  }, z.core.$strict>;
5249
5268
  type CodingHistoryProgressEvent = z.output<typeof CodingHistoryProgressEvent>;
5250
5269
 
5270
+ /**
5271
+ * @ai-matrx/desktop-protocol — cap browser (protocol 1.28): the AI Matrx browser extension as a
5272
+ * client of Matrx 2, and Matrx 2's agents driving it. Schema source: lint-enforced rules in
5273
+ * scripts/check-schema-source.mjs.
5274
+ *
5275
+ * The extension finds Matrx 2 with `GET /v1/health` (DesktopHealth, public, no token), pairs once
5276
+ * with `POST /v1/pair` (BrowserPairRequest → BrowserPairResult, loopback + an allowed extension
5277
+ * Origin), connects to `/v1/connect` as clientType "extension" with `bearer.<pair token>`, says
5278
+ * hello as usual (the envelope is unchanged) and then `browser.register` — once the welcome lists
5279
+ * it. Matrx 2 checks the extension's account against the device owner; only a session of the same
5280
+ * account is ever driven. An agent's call (`browser.call`) reaches exactly one session as the event
5281
+ * `browser.invoke`; the extension answers with `browser.result` (accepted only from that session)
5282
+ * and may say `browser.progress` while a person confirms the action in Chrome.
5283
+ */
5284
+
5285
+ /** Stable per Chrome profile (the extension mints it once): one session per instance. */
5286
+ declare const BrowserClientInstance: z.ZodString;
5287
+ declare const BrowserRegisterResult: z.ZodObject<{
5288
+ session: z.ZodObject<{
5289
+ client_instance: z.ZodString;
5290
+ client_label: z.ZodString;
5291
+ browser: z.ZodEnum<{
5292
+ other: "other";
5293
+ chrome: "chrome";
5294
+ edge: "edge";
5295
+ brave: "brave";
5296
+ arc: "arc";
5297
+ opera: "opera";
5298
+ vivaldi: "vivaldi";
5299
+ chromium: "chromium";
5300
+ firefox: "firefox";
5301
+ }>;
5302
+ extension_version: z.ZodString;
5303
+ state: z.ZodEnum<{
5304
+ connected: "connected";
5305
+ different_account: "different_account";
5306
+ extension_signed_out: "extension_signed_out";
5307
+ device_signed_out: "device_signed_out";
5308
+ unverified: "unverified";
5309
+ }>;
5310
+ routable: z.ZodBoolean;
5311
+ account_email: z.ZodNullable<z.ZodString>;
5312
+ connected_at_ms: z.ZodInt;
5313
+ last_call_at_ms: z.ZodNullable<z.ZodInt>;
5314
+ calls: z.ZodInt;
5315
+ errors: z.ZodInt;
5316
+ p50_ms: z.ZodNullable<z.ZodInt>;
5317
+ p95_ms: z.ZodNullable<z.ZodInt>;
5318
+ awaiting_confirmation: z.ZodBoolean;
5319
+ }, z.core.$strict>;
5320
+ }, z.core.$strict>;
5321
+ declare const BrowserCallError: z.ZodObject<{
5322
+ message: z.ZodString;
5323
+ code: z.ZodNullable<z.ZodString>;
5324
+ }, z.core.$strict>;
5325
+ declare const BrowserResultResult: z.ZodObject<{
5326
+ accepted: z.ZodBoolean;
5327
+ }, z.core.$strict>;
5328
+ /** The extension says where a call stands (the person is being asked to confirm it). */
5329
+ declare const BrowserProgressParams: z.ZodObject<{
5330
+ call_id: z.ZodString;
5331
+ phase: z.ZodEnum<{
5332
+ awaiting_confirmation: "awaiting_confirmation";
5333
+ running: "running";
5334
+ }>;
5335
+ }, z.core.$strict>;
5336
+ declare const BrowserProgressResult: z.ZodObject<{
5337
+ accepted: z.ZodBoolean;
5338
+ }, z.core.$strict>;
5339
+ declare const BrowserSessionsParams: z.ZodObject<{}, z.core.$strict>;
5340
+ declare const BrowserDisconnectParams: z.ZodObject<{
5341
+ client_instance: z.ZodString;
5342
+ }, z.core.$strict>;
5343
+ declare const BrowserDisconnectResult: z.ZodObject<{
5344
+ disconnected: z.ZodBoolean;
5345
+ }, z.core.$strict>;
5346
+ declare const BrowserSetEnabledParams: z.ZodObject<{
5347
+ enabled: z.ZodBoolean;
5348
+ }, z.core.$strict>;
5349
+ declare const BrowserSetEnabledResult: z.ZodObject<{
5350
+ enabled: z.ZodBoolean;
5351
+ }, z.core.$strict>;
5352
+ /** The pairing code a browser on another computer types in (screen clients on this computer only). */
5353
+ declare const BrowserPairCodeParams: z.ZodObject<{}, z.core.$strict>;
5354
+ declare const BrowserPairCodeResult: z.ZodObject<{
5355
+ code: z.ZodString;
5356
+ }, z.core.$strict>;
5357
+ declare const BrowserPairResetParams: z.ZodObject<{}, z.core.$strict>;
5358
+ /** Core → the app's screens: the session list changed (re-read browser.sessions). */
5359
+ declare const BrowserSessionsChangedEvent: z.ZodObject<{
5360
+ count: z.ZodInt;
5361
+ enabled: z.ZodBoolean;
5362
+ }, z.core.$strict>;
5363
+ /** Core → the caller of a browser.call: where it stands. */
5364
+ declare const BrowserProgressEvent: z.ZodObject<{
5365
+ call_id: z.ZodString;
5366
+ client_instance: z.ZodString;
5367
+ phase: z.ZodEnum<{
5368
+ awaiting_confirmation: "awaiting_confirmation";
5369
+ running: "running";
5370
+ }>;
5371
+ }, z.core.$strict>;
5372
+ /** `POST /v1/pair` body. */
5373
+ declare const BrowserPairRequest: z.ZodObject<{
5374
+ client_instance: z.ZodString;
5375
+ }, z.core.$strict>;
5376
+ /**
5377
+ * The extension IDs allowed to pair (Origin `chrome-extension://<id>`): the Chrome Web Store build
5378
+ * and the keyed development build. matrx-extend's src/config/identity.ts names the same IDs; this
5379
+ * constant is the one both sides read. The development ID is accepted only by development builds.
5380
+ */
5381
+ declare const MATRX_EXTENSION_IDS: {
5382
+ readonly store: "hnfolienncfklkgmdjjmhhegglimlamg";
5383
+ readonly development: "cihdmkcdjjckfhjpgoedmgfpoljebaml";
5384
+ };
5385
+ /** The discovery file Matrx 2 writes under ~/.matrx (Matrx Local keeps local.json). */
5386
+ declare const DISCOVERY_FILE: {
5387
+ readonly live: "matrx2.json";
5388
+ readonly development: "matrx2-dev.json";
5389
+ };
5390
+ /** The browser the extension runs in, as the extension reports it. */
5391
+ declare const BrowserKind: z.ZodEnum<{
5392
+ other: "other";
5393
+ chrome: "chrome";
5394
+ edge: "edge";
5395
+ brave: "brave";
5396
+ arc: "arc";
5397
+ opera: "opera";
5398
+ vivaldi: "vivaldi";
5399
+ chromium: "chromium";
5400
+ firefox: "firefox";
5401
+ }>;
5402
+ type BrowserKind = z.output<typeof BrowserKind>;
5403
+ /**
5404
+ * Whether this computer's agents may drive the session:
5405
+ * - `connected` — same account as the device owner: routable;
5406
+ * - `different_account` — the extension is signed in to another AI Matrx account: listed, never driven;
5407
+ * - `extension_signed_out` — the extension is signed out of AI Matrx: listed, never driven;
5408
+ * - `device_signed_out` — Matrx 2 itself is signed out, so there is no owner to match: listed, never driven;
5409
+ * - `unverified` — the account could not be checked (no network, keys unavailable): retried on the next register.
5410
+ */
5411
+ declare const BrowserSessionState: z.ZodEnum<{
5412
+ connected: "connected";
5413
+ different_account: "different_account";
5414
+ extension_signed_out: "extension_signed_out";
5415
+ device_signed_out: "device_signed_out";
5416
+ unverified: "unverified";
5417
+ }>;
5418
+ type BrowserSessionState = z.output<typeof BrowserSessionState>;
5419
+ declare const BrowserSession: z.ZodObject<{
5420
+ client_instance: z.ZodString;
5421
+ client_label: z.ZodString;
5422
+ browser: z.ZodEnum<{
5423
+ other: "other";
5424
+ chrome: "chrome";
5425
+ edge: "edge";
5426
+ brave: "brave";
5427
+ arc: "arc";
5428
+ opera: "opera";
5429
+ vivaldi: "vivaldi";
5430
+ chromium: "chromium";
5431
+ firefox: "firefox";
5432
+ }>;
5433
+ extension_version: z.ZodString;
5434
+ state: z.ZodEnum<{
5435
+ connected: "connected";
5436
+ different_account: "different_account";
5437
+ extension_signed_out: "extension_signed_out";
5438
+ device_signed_out: "device_signed_out";
5439
+ unverified: "unverified";
5440
+ }>;
5441
+ routable: z.ZodBoolean;
5442
+ account_email: z.ZodNullable<z.ZodString>;
5443
+ connected_at_ms: z.ZodInt;
5444
+ last_call_at_ms: z.ZodNullable<z.ZodInt>;
5445
+ calls: z.ZodInt;
5446
+ errors: z.ZodInt;
5447
+ p50_ms: z.ZodNullable<z.ZodInt>;
5448
+ p95_ms: z.ZodNullable<z.ZodInt>;
5449
+ awaiting_confirmation: z.ZodBoolean;
5450
+ }, z.core.$strict>;
5451
+ type BrowserSession = z.output<typeof BrowserSession>;
5452
+ declare const BrowserRegisterParams: z.ZodObject<{
5453
+ client_instance: z.ZodString;
5454
+ client_label: z.ZodString;
5455
+ browser: z.ZodEnum<{
5456
+ other: "other";
5457
+ chrome: "chrome";
5458
+ edge: "edge";
5459
+ brave: "brave";
5460
+ arc: "arc";
5461
+ opera: "opera";
5462
+ vivaldi: "vivaldi";
5463
+ chromium: "chromium";
5464
+ firefox: "firefox";
5465
+ }>;
5466
+ extension_version: z.ZodString;
5467
+ account_token: z.ZodNullable<z.ZodString>;
5468
+ }, z.core.$strict>;
5469
+ type BrowserRegisterParams = z.output<typeof BrowserRegisterParams>;
5470
+ /** The extension's answer to one `browser.invoke`. */
5471
+ declare const BrowserResultParams: z.ZodObject<{
5472
+ call_id: z.ZodString;
5473
+ ok: z.ZodBoolean;
5474
+ result: z.ZodUnknown;
5475
+ error: z.ZodNullable<z.ZodObject<{
5476
+ message: z.ZodString;
5477
+ code: z.ZodNullable<z.ZodString>;
5478
+ }, z.core.$strict>>;
5479
+ }, z.core.$strict>;
5480
+ type BrowserResultParams = z.output<typeof BrowserResultParams>;
5481
+ declare const BrowserCallPhase: z.ZodEnum<{
5482
+ awaiting_confirmation: "awaiting_confirmation";
5483
+ running: "running";
5484
+ }>;
5485
+ type BrowserCallPhase = z.output<typeof BrowserCallPhase>;
5486
+ declare const BrowserSessionsResult: z.ZodObject<{
5487
+ enabled: z.ZodBoolean;
5488
+ owner_signed_in: z.ZodBoolean;
5489
+ sessions: z.ZodArray<z.ZodObject<{
5490
+ client_instance: z.ZodString;
5491
+ client_label: z.ZodString;
5492
+ browser: z.ZodEnum<{
5493
+ other: "other";
5494
+ chrome: "chrome";
5495
+ edge: "edge";
5496
+ brave: "brave";
5497
+ arc: "arc";
5498
+ opera: "opera";
5499
+ vivaldi: "vivaldi";
5500
+ chromium: "chromium";
5501
+ firefox: "firefox";
5502
+ }>;
5503
+ extension_version: z.ZodString;
5504
+ state: z.ZodEnum<{
5505
+ connected: "connected";
5506
+ different_account: "different_account";
5507
+ extension_signed_out: "extension_signed_out";
5508
+ device_signed_out: "device_signed_out";
5509
+ unverified: "unverified";
5510
+ }>;
5511
+ routable: z.ZodBoolean;
5512
+ account_email: z.ZodNullable<z.ZodString>;
5513
+ connected_at_ms: z.ZodInt;
5514
+ last_call_at_ms: z.ZodNullable<z.ZodInt>;
5515
+ calls: z.ZodInt;
5516
+ errors: z.ZodInt;
5517
+ p50_ms: z.ZodNullable<z.ZodInt>;
5518
+ p95_ms: z.ZodNullable<z.ZodInt>;
5519
+ awaiting_confirmation: z.ZodBoolean;
5520
+ }, z.core.$strict>>;
5521
+ }, z.core.$strict>;
5522
+ type BrowserSessionsResult = z.output<typeof BrowserSessionsResult>;
5523
+ /**
5524
+ * Run one of the extension's own tools (any `chrome-extension` tool_def row) in one session. The
5525
+ * server validates `args` against that row's parameters; here they are opaque and size-capped.
5526
+ */
5527
+ declare const BrowserCallParams: z.ZodObject<{
5528
+ tool: z.ZodString;
5529
+ args: z.ZodRecord<z.ZodString, z.ZodUnknown>;
5530
+ client_instance: z.ZodOptional<z.ZodString>;
5531
+ timeout_ms: z.ZodOptional<z.ZodInt>;
5532
+ }, z.core.$strict>;
5533
+ type BrowserCallParams = z.output<typeof BrowserCallParams>;
5534
+ declare const BrowserCallResult: z.ZodObject<{
5535
+ client_instance: z.ZodString;
5536
+ result: z.ZodUnknown;
5537
+ duration_ms: z.ZodInt;
5538
+ }, z.core.$strict>;
5539
+ type BrowserCallResult = z.output<typeof BrowserCallResult>;
5540
+ /** Core → one extension session: run this tool and answer with browser.result. */
5541
+ declare const BrowserInvokeEvent: z.ZodObject<{
5542
+ call_id: z.ZodString;
5543
+ tool: z.ZodString;
5544
+ args: z.ZodRecord<z.ZodString, z.ZodUnknown>;
5545
+ deadline_ms: z.ZodInt;
5546
+ }, z.core.$strict>;
5547
+ type BrowserInvokeEvent = z.output<typeof BrowserInvokeEvent>;
5548
+ /** `GET /v1/health`: public, no token, no user id. Matrx 2 never serves `/health` (Matrx Local's). */
5549
+ declare const DesktopHealth: z.ZodObject<{
5550
+ status: z.ZodLiteral<"ok">;
5551
+ service: z.ZodLiteral<"matrx-desktop">;
5552
+ version: z.ZodString;
5553
+ protocol_version: z.ZodString;
5554
+ ws_path: z.ZodLiteral<"/v1/connect">;
5555
+ device_id: z.ZodString;
5556
+ browser_connection: z.ZodEnum<{
5557
+ off: "off";
5558
+ on: "on";
5559
+ }>;
5560
+ }, z.core.$strict>;
5561
+ type DesktopHealth = z.output<typeof DesktopHealth>;
5562
+ /** `POST /v1/pair` answer: the token rides `bearer.<pair_token>` on /v1/connect. */
5563
+ declare const BrowserPairResult: z.ZodObject<{
5564
+ pair_token: z.ZodString;
5565
+ ws_path: z.ZodLiteral<"/v1/connect">;
5566
+ }, z.core.$strict>;
5567
+ type BrowserPairResult = z.output<typeof BrowserPairResult>;
5568
+
5251
5569
  /**
5252
5570
  * Version skew is the normal state: a phone, the server and a desktop app in the field run
5253
5571
  * different package versions, and a minor protocol bump must never make any of them fail.
@@ -5357,6 +5675,11 @@ declare const REASONS_SINCE: {
5357
5675
  readonly service_starting: "1.2";
5358
5676
  readonly service_restarted: "1.2";
5359
5677
  readonly service_failed: "1.2";
5678
+ readonly browser_not_connected: "1.28";
5679
+ readonly browser_ambiguous: "1.28";
5680
+ readonly browser_account_mismatch: "1.28";
5681
+ readonly browser_connection_off: "1.28";
5682
+ readonly awaiting_confirmation: "1.28";
5360
5683
  };
5361
5684
  /** A device status for a reader at `version`: `since_ms` null ("never") becomes 0 before 1.1. */
5362
5685
  declare function statusForPeer<T extends {
@@ -5386,7 +5709,7 @@ declare function forPeer(op: OpName | null, part: "error", value: unknown, versi
5386
5709
  declare const VERSIONED_RESULT_OPS: readonly OpName[];
5387
5710
 
5388
5711
  /** SHA-256 of generated/desktop-protocol.schema.json: the contract both sides of a service connection were built from. */
5389
- declare const CONTRACT_SHA256: "eece2e5eba3e6e33126a0fda2fad8c91abe9c878fbfdc98bd049ff5af126cb09";
5712
+ declare const CONTRACT_SHA256: "d328d624d1de854696a07e9fb8f1e85894047e5c41164647944db79b3c1a638d";
5390
5713
 
5391
5714
  /**
5392
5715
  * The local tool catalog (SPEC §10): every tool a platform agent calls on a person's computer, the
@@ -5513,4 +5836,4 @@ declare function buildToolStatus(files: readonly unknown[], opts: {
5513
5836
  /** The committed text form. Columns: per platform, the three levels (P = programmatic, R = protocol, C = chat). */
5514
5837
  declare function renderToolStatusMarkdown(status: ToolStatus): string;
5515
5838
 
5516
- export { AbsPath, AccountAgent, AccountAgentsListParams, AccountAgentsListResult, AccountReadState, AccountReset, AccountRowId, AccountUsage, AccountVaultCopyParams, AccountVaultCopyResult, AccountVaultListParams, AccountVaultListResult, AppFeatureStatus, AppInfo, AppKey, AppProfile, AppProfileId, AppProfileLocator, AppSupport, AppUsageReading, AppWindowInfo, AppsAccountsResetsParams, AppsAccountsResetsResult, AppsAccountsUsageParams, AppsAccountsUsageResult, AppsChatsChangedEvent, AppsChatsColdParams, AppsChatsColdResult, AppsChatsListParams, AppsChatsListResult, AppsChatsOpenParams, AppsChatsPlaceParams, AppsChatsPlaceResult, AppsChatsStarParams, AppsChatsStarResult, AppsChatsWatchParams, AppsChatsWatchResult, AppsChatsWatchStateEvent, AppsListParams, AppsListResult, AppsOpenParams, AppsOpenResult, AppsProfilesListParams, AppsProfilesListResult, AppsProfilesRemoveParams, AppsProfilesRemoveResult, AppsProfilesSaveParams, AppsProfilesSaveResult, AppsProjectsCopyParams, AppsProjectsCopyResult, AppsProjectsCreateParams, AppsProjectsCreateResult, AppsProjectsFileManyParams, AppsProjectsFileManyResult, AppsProjectsFileParams, AppsProjectsFileResult, AppsProjectsImportPinsParams, AppsProjectsImportPinsResult, AppsProjectsMoveParams, AppsProjectsMoveResult, AppsProjectsToWindowParams, AppsProjectsToWindowResult, AppsProjectsUnfileParams, AppsProjectsUnfileResult, AppsProjectsUpdateParams, AppsProjectsUpdateResult, AppsSpendParams, AppsSpendResult, AppsSyncRunParams, AppsSyncStatusParams, AppsSyncStatusResult, AppsWindowActionResult, AppsWindowsAddParams, AppsWindowsListParams, AppsWindowsListResult, AppsWindowsOpenParams, AppsWindowsProcessesParams, AppsWindowsProcessesResult, AppsWindowsRefreshUsageParams, AppsWindowsReloadParams, AppsWindowsReopenParams, AppsWindowsReopenResult, AppsWindowsRestartParams, AppsWindowsSaveNamesParams, AppsWindowsShownParams, AppsWindowsShownResult, AppsWindowsUpdateAndReopenParams, AppsWindowsUpdateAndReopenResult, AppsWindowsUpdateStateParams, AppsWindowsUpdateStateResult, AudioDevice, AudioDevicesParams, AudioDevicesResult, AudioLevelsParams, AudioLevelsResult, AudioPlayParams, AudioPlayResult, AudioRecordParams, AudioRecordResult, AudioSetLevelsParams, CONTRACT_SHA256, type CatalogTool, type CellState, ChatAppProject, ChatFamily, ChatHidden, ChatId, ChatLastUse, ChatPin, ChatPlace, ChatProject, ChatProjectId, ChatRow, ChatRunning, ChatWindow, ClipboardReadParams, ClipboardReadResult, ClipboardWriteParams, ClipboardWriteResult, CodingHistoryBlocked, CodingHistoryFailure, CodingHistoryImportMissingParams, CodingHistoryImportMissingResult, CodingHistoryProgressEvent, CodingHistoryRun, CodingHistoryStep, CodingImportNextParams, CodingPlanMissingParams, CodingServiceCredentials, CodingServiceProgress, ColdChat, ContractHash, CoreToServiceMsg, DEFAULT_MAX_FRAME_PAYLOAD_BYTES, DEFAULT_MAX_MESSAGE_BYTES, DEFAULT_WINDOW_BYTES, DeviceId, DiagErrorEntry, DiagErrorKind, DiagErrorStatus, DiagErrorsChangedEvent, DiagErrorsListParams, DiagErrorsListResult, DiagErrorsReportParams, DiagErrorsReportResult, DiagProcess, EXCLUDED_TOOLS, ExecCwdEvent, ExecExitedEvent, ExecJobId, ExecJobInfo, ExecJobListParams, ExecJobListResult, ExecJobOutputParams, ExecJobOutputResult, ExecJobStartParams, ExecJobStartResult, ExecJobStopParams, ExecJobStopResult, ExecListParams, ExecListResult, ExecPtyKillParams, ExecPtyKillResult, ExecPtyResizeParams, ExecPtyResizeResult, ExecPtySignalParams, ExecPtySignalResult, ExecPtyStartParams, ExecPtyStartResult, ExecPtyWriteParams, ExecPtyWriteResult, ExecRunParams, ExecRunResult, ExecTitleEvent, FIELDS_SINCE, type FieldsSincePath, FrameHeader, FsChange, FsChangedEvent, FsDeleteParams, FsDeleteResult, FsEncoding, FsEntry, FsKind, FsListParams, FsListResult, FsMkdirParams, FsMkdirResult, FsMoveParams, FsMoveResult, FsPatchEditApplied, FsPatchParams, FsPatchResult, FsReadParams, FsReadResult, FsReadStreamParams, FsReadStreamResult, FsSearchContentParams, FsSearchContentResult, FsSearchPathsParams, FsSearchPathsResult, FsStatParams, FsStatResult, FsWatchEventsParams, FsWatchEventsResult, FsWatchId, FsWatchParams, FsWatchResult, FsWatchStartParams, FsWatchStartResult, FsWatchStopParams, FsWatchStopResult, FsWriteParams, FsWriteResult, GIT_MAX_OUTPUT_CHARS, GitAddParams, GitBranchParams, GitBranchResult, GitCloneParams, GitCommitParams, GitCommitResult, GitDiffParams, GitDiffResult, GitLogCommit, GitLogParams, GitLogResult, GitOutputResult, GitPullParams, GitPushParams, GitStashParams, GitStatusFile, GitStatusParams, GitStatusResult, InputHotkeyParams, InputHotkeyResult, InputKey, InputKeyboardSettingsParams, InputKeyboardSettingsResult, InputMouseClickParams, InputMouseClickResult, InputMouseMoveParams, InputMouseMoveResult, InputPoint, InputSetKeyboardSettingsParams, InputTypeTextParams, InputTypeTextResult, LEGACY_ACTIONS, LEGACY_DISPATCHERS, type LegacyDisposition, NULL_SINCE, OpName, OsPermissionName, PROTOCOL_MAJOR, PROTOCOL_MINOR, PROTOCOL_VERSION, PowerEnergy, PowerHistoryParams, PowerHistoryPoint, PowerHistoryResult, PowerPreventSleepParams, PowerPreventSleepResult, PowerStatusParams, PowerStatusResult, ProcInfo, ProcKillParams, ProcKillResult, ProcListParams, ProcListResult, ProcPort, ProcPortsParams, ProcPortsResult, ProcSort, ProjectMoveChat, ProjectMoveGroup, ProjectMoveSkip, ProtocolVersion, PtyInfo, REASONS_SINCE, RELAY_CALL_HELLO_ID, RELAY_CALL_REQUEST_ID, RELAY_CALL_VERSION_HEADER, RelayAuthExpiringEvent, RelayCallEnvelope, RelayCallHello, RelayCallRequest, RelayCallResponse, RelayDeviceStatusEvent, RelayHopConnectionEnd, RelayHopEnvelopeHeader, RelayStatusResponse, RequestId, ResourceId, ResourceInfo, ResourcesActivityParams, ResourcesActivityResult, ResourcesDisk, ResourcesIncident, ResourcesIncidentsParams, ResourcesIncidentsResult, ResourcesJob, ResourcesJobKind, ResourcesPressure, ResourcesProcess, ResourcesSample, ResourcesSnapshotParams, ResourcesSnapshotResult, ResourcesStopJobParams, ResourcesStopJobResult, ResourcesStrain, ResourcesVerdict, SERVICE_MAX_FRAME_BYTES, ScreenCaptureParams, ScreenCaptureResult, ScreenDisplay, ScreenListParams, ScreenListResult, ServiceCancel, ServiceErrorMsg, ServiceHello, ServiceName, ServicePing, ServicePong, ServiceProgressMsg, ServiceRequest, ServiceResponse, ServiceShutdown, ServiceToCoreMsg, ServiceToken, ServiceWelcome, SessionAttachParams, SessionAttachResult, SessionControlChangedEvent, SessionDetachParams, SessionDetachResult, SessionListParams, SessionListResult, SessionReleaseParams, SessionReleaseResult, ShownSection, Signal, SpendAccount, SpendChat, SpendDay, SpendHelper, SpendIdle, SpendIdleScope, SpendLive, SpendModel, SpendScopes, SpendSplit, SpendStart, StackErrorsParams, StackErrorsResult, StackEvent, StackLogsParams, StackLogsResult, StackRunResult, StackServer, StackServerActionParams, StackServerActionResult, StackServerName, StackStartParams, StackStateParams, StackStateResult, StackStopParams, StackTone, type StatusCell, type StatusEvidence, type StatusRow, SysinfoGetParams, SysinfoGetResult, SysinfoHardwareParams, SysinfoHardwareResult, SystemNotifyParams, SystemNotifyResult, SystemOpenPathParams, SystemOpenPathResult, SystemOpenSettingsParams, SystemOpenSettingsResult, SystemOpenUrlParams, SystemOpenUrlResult, SystemSettingsPane, TOOL_CATALOG, TOOL_GROUPS, TOOL_LEVELS, TOOL_PLATFORMS, type ToolGroup, type ToolGroupId, ToolLevel, ToolLevelResult, ToolName, ToolOutcome, type ToolPath, ToolPlatform, ToolResultsFile, type ToolState, type ToolStatus, ToolTransport, ToolsServiceProgress, ToolsWebSearchParams, VERSIONED_RESULT_OPS, VaultFieldSummary, VaultItemKind, VaultItemSummary, WEB_MAX_TEXT_CHARS, WebBrowserFetchParams, WebBrowserFetchResult, WebFetchParams, WebFetchResult, WebHeader, WebScrapePage, WebScrapeParams, WebScrapeResult, WebSearchHit, WebSearchParams, WebSearchQueryResult, WebSearchResult, WindowFocusParams, WindowFocusResult, WindowInfo, WindowListParams, WindowListResult, WindowMinimizeParams, WindowMinimizeResult, WindowMoveParams, WindowMoveResult, announcedVersion, buildToolStatus, builtOps, compareVersions, epochMs, forPeer, knows, negotiate, nonNegInt, renderToolStatusMarkdown, statusForPeer, u32, versionSubprotocol };
5839
+ export { AbsPath, AccountAgent, AccountAgentsListParams, AccountAgentsListResult, AccountReadState, AccountReset, AccountRowId, AccountUsage, AccountVaultCopyParams, AccountVaultCopyResult, AccountVaultListParams, AccountVaultListResult, AppFeatureStatus, AppInfo, AppKey, AppProfile, AppProfileId, AppProfileLocator, AppSupport, AppUsageReading, AppWindowInfo, AppsAccountsResetsParams, AppsAccountsResetsResult, AppsAccountsUsageParams, AppsAccountsUsageResult, AppsChatsChangedEvent, AppsChatsColdParams, AppsChatsColdResult, AppsChatsListParams, AppsChatsListResult, AppsChatsOpenParams, AppsChatsPlaceParams, AppsChatsPlaceResult, AppsChatsStarParams, AppsChatsStarResult, AppsChatsWatchParams, AppsChatsWatchResult, AppsChatsWatchStateEvent, AppsListParams, AppsListResult, AppsOpenParams, AppsOpenResult, AppsProfilesListParams, AppsProfilesListResult, AppsProfilesRemoveParams, AppsProfilesRemoveResult, AppsProfilesSaveParams, AppsProfilesSaveResult, AppsProjectsCopyParams, AppsProjectsCopyResult, AppsProjectsCreateParams, AppsProjectsCreateResult, AppsProjectsFileManyParams, AppsProjectsFileManyResult, AppsProjectsFileParams, AppsProjectsFileResult, AppsProjectsImportPinsParams, AppsProjectsImportPinsResult, AppsProjectsMoveParams, AppsProjectsMoveResult, AppsProjectsToWindowParams, AppsProjectsToWindowResult, AppsProjectsUnfileParams, AppsProjectsUnfileResult, AppsProjectsUpdateParams, AppsProjectsUpdateResult, AppsSpendParams, AppsSpendResult, AppsSyncRunParams, AppsSyncStatusParams, AppsSyncStatusResult, AppsWindowActionResult, AppsWindowsAddParams, AppsWindowsListParams, AppsWindowsListResult, AppsWindowsOpenParams, AppsWindowsProcessesParams, AppsWindowsProcessesResult, AppsWindowsRefreshUsageParams, AppsWindowsReloadParams, AppsWindowsReopenParams, AppsWindowsReopenResult, AppsWindowsRestartParams, AppsWindowsSaveNamesParams, AppsWindowsShownParams, AppsWindowsShownResult, AppsWindowsUpdateAndReopenParams, AppsWindowsUpdateAndReopenResult, AppsWindowsUpdateStateParams, AppsWindowsUpdateStateResult, AudioDevice, AudioDevicesParams, AudioDevicesResult, AudioLevelsParams, AudioLevelsResult, AudioPlayParams, AudioPlayResult, AudioRecordParams, AudioRecordResult, AudioSetLevelsParams, BrowserCallError, BrowserCallParams, BrowserCallPhase, BrowserCallResult, BrowserClientInstance, BrowserDisconnectParams, BrowserDisconnectResult, BrowserInvokeEvent, BrowserKind, BrowserPairCodeParams, BrowserPairCodeResult, BrowserPairRequest, BrowserPairResetParams, BrowserPairResult, BrowserProgressEvent, BrowserProgressParams, BrowserProgressResult, BrowserRegisterParams, BrowserRegisterResult, BrowserResultParams, BrowserResultResult, BrowserSession, BrowserSessionState, BrowserSessionsChangedEvent, BrowserSessionsParams, BrowserSessionsResult, BrowserSetEnabledParams, BrowserSetEnabledResult, CONTRACT_SHA256, type CatalogTool, type CellState, ChatAppProject, ChatFamily, ChatHidden, ChatId, ChatLastUse, ChatPin, ChatPlace, ChatProject, ChatProjectId, ChatRow, ChatRunning, ChatWindow, ClipboardReadParams, ClipboardReadResult, ClipboardWriteParams, ClipboardWriteResult, CodingHistoryBlocked, CodingHistoryFailure, CodingHistoryImportMissingParams, CodingHistoryImportMissingResult, CodingHistoryProgressEvent, CodingHistoryRun, CodingHistoryStep, CodingImportNextParams, CodingPlanMissingParams, CodingServiceCredentials, CodingServiceProgress, ColdChat, ContractHash, CoreToServiceMsg, DEFAULT_MAX_FRAME_PAYLOAD_BYTES, DEFAULT_MAX_MESSAGE_BYTES, DEFAULT_WINDOW_BYTES, DISCOVERY_FILE, DesktopHealth, DeviceId, DiagErrorEntry, DiagErrorKind, DiagErrorStatus, DiagErrorsChangedEvent, DiagErrorsListParams, DiagErrorsListResult, DiagErrorsReportParams, DiagErrorsReportResult, DiagProcess, EXCLUDED_TOOLS, ExecCwdEvent, ExecExitedEvent, ExecJobId, ExecJobInfo, ExecJobListParams, ExecJobListResult, ExecJobOutputParams, ExecJobOutputResult, ExecJobStartParams, ExecJobStartResult, ExecJobStopParams, ExecJobStopResult, ExecListParams, ExecListResult, ExecPtyKillParams, ExecPtyKillResult, ExecPtyResizeParams, ExecPtyResizeResult, ExecPtySignalParams, ExecPtySignalResult, ExecPtyStartParams, ExecPtyStartResult, ExecPtyWriteParams, ExecPtyWriteResult, ExecRunParams, ExecRunResult, ExecTitleEvent, FIELDS_SINCE, type FieldsSincePath, FrameHeader, FsChange, FsChangedEvent, FsDeleteParams, FsDeleteResult, FsEncoding, FsEntry, FsKind, FsListParams, FsListResult, FsMkdirParams, FsMkdirResult, FsMoveParams, FsMoveResult, FsPatchEditApplied, FsPatchParams, FsPatchResult, FsReadParams, FsReadResult, FsReadStreamParams, FsReadStreamResult, FsSearchContentParams, FsSearchContentResult, FsSearchPathsParams, FsSearchPathsResult, FsStatParams, FsStatResult, FsWatchEventsParams, FsWatchEventsResult, FsWatchId, FsWatchParams, FsWatchResult, FsWatchStartParams, FsWatchStartResult, FsWatchStopParams, FsWatchStopResult, FsWriteParams, FsWriteResult, GIT_MAX_OUTPUT_CHARS, GitAddParams, GitBranchParams, GitBranchResult, GitCloneParams, GitCommitParams, GitCommitResult, GitDiffParams, GitDiffResult, GitLogCommit, GitLogParams, GitLogResult, GitOutputResult, GitPullParams, GitPushParams, GitStashParams, GitStatusFile, GitStatusParams, GitStatusResult, InputHotkeyParams, InputHotkeyResult, InputKey, InputKeyboardSettingsParams, InputKeyboardSettingsResult, InputMouseClickParams, InputMouseClickResult, InputMouseMoveParams, InputMouseMoveResult, InputPoint, InputSetKeyboardSettingsParams, InputTypeTextParams, InputTypeTextResult, LEGACY_ACTIONS, LEGACY_DISPATCHERS, type LegacyDisposition, MATRX_EXTENSION_IDS, NULL_SINCE, OpName, OsPermissionName, PROTOCOL_MAJOR, PROTOCOL_MINOR, PROTOCOL_VERSION, PowerEnergy, PowerHistoryParams, PowerHistoryPoint, PowerHistoryResult, PowerPreventSleepParams, PowerPreventSleepResult, PowerStatusParams, PowerStatusResult, ProcInfo, ProcKillParams, ProcKillResult, ProcListParams, ProcListResult, ProcPort, ProcPortsParams, ProcPortsResult, ProcSort, ProjectMoveChat, ProjectMoveGroup, ProjectMoveSkip, ProtocolVersion, PtyInfo, REASONS_SINCE, RELAY_CALL_HELLO_ID, RELAY_CALL_REQUEST_ID, RELAY_CALL_VERSION_HEADER, RelayAuthExpiringEvent, RelayCallEnvelope, RelayCallHello, RelayCallRequest, RelayCallResponse, RelayDeviceStatusEvent, RelayHopConnectionEnd, RelayHopEnvelopeHeader, RelayStatusResponse, RequestId, ResourceId, ResourceInfo, ResourcesActivityParams, ResourcesActivityResult, ResourcesDisk, ResourcesIncident, ResourcesIncidentsParams, ResourcesIncidentsResult, ResourcesJob, ResourcesJobKind, ResourcesPressure, ResourcesProcess, ResourcesSample, ResourcesSnapshotParams, ResourcesSnapshotResult, ResourcesStopJobParams, ResourcesStopJobResult, ResourcesStrain, ResourcesVerdict, SERVICE_MAX_FRAME_BYTES, ScreenCaptureParams, ScreenCaptureResult, ScreenDisplay, ScreenListParams, ScreenListResult, ServiceCancel, ServiceErrorMsg, ServiceHello, ServiceName, ServicePing, ServicePong, ServiceProgressMsg, ServiceRequest, ServiceResponse, ServiceShutdown, ServiceToCoreMsg, ServiceToken, ServiceWelcome, SessionAttachParams, SessionAttachResult, SessionControlChangedEvent, SessionDetachParams, SessionDetachResult, SessionListParams, SessionListResult, SessionReleaseParams, SessionReleaseResult, ShownSection, Signal, SpendAccount, SpendChat, SpendDay, SpendHelper, SpendIdle, SpendIdleScope, SpendLive, SpendModel, SpendScopes, SpendSplit, SpendStart, StackErrorsParams, StackErrorsResult, StackEvent, StackLogsParams, StackLogsResult, StackRunResult, StackServer, StackServerActionParams, StackServerActionResult, StackServerName, StackStartParams, StackStateParams, StackStateResult, StackStopParams, StackTone, type StatusCell, type StatusEvidence, type StatusRow, SysinfoGetParams, SysinfoGetResult, SysinfoHardwareParams, SysinfoHardwareResult, SystemNotifyParams, SystemNotifyResult, SystemOpenPathParams, SystemOpenPathResult, SystemOpenSettingsParams, SystemOpenSettingsResult, SystemOpenUrlParams, SystemOpenUrlResult, SystemSettingsPane, TOOL_CATALOG, TOOL_GROUPS, TOOL_LEVELS, TOOL_PLATFORMS, type ToolGroup, type ToolGroupId, ToolLevel, ToolLevelResult, ToolName, ToolOutcome, type ToolPath, ToolPlatform, ToolResultsFile, type ToolState, type ToolStatus, ToolTransport, ToolsServiceProgress, ToolsWebSearchParams, VERSIONED_RESULT_OPS, VaultFieldSummary, VaultItemKind, VaultItemSummary, WEB_MAX_TEXT_CHARS, WebBrowserFetchParams, WebBrowserFetchResult, WebFetchParams, WebFetchResult, WebHeader, WebScrapePage, WebScrapeParams, WebScrapeResult, WebSearchHit, WebSearchParams, WebSearchQueryResult, WebSearchResult, WindowFocusParams, WindowFocusResult, WindowInfo, WindowListParams, WindowListResult, WindowMinimizeParams, WindowMinimizeResult, WindowMoveParams, WindowMoveResult, announcedVersion, buildToolStatus, builtOps, compareVersions, epochMs, forPeer, knows, negotiate, nonNegInt, renderToolStatusMarkdown, statusForPeer, u32, versionSubprotocol };