@ai-matrx/desktop-protocol 0.21.30 → 0.21.32

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/client.d.cts CHANGED
@@ -1,8 +1,8 @@
1
1
  import { BackoffOptions } from '@ai-matrx/realtime';
2
2
  export { RECONNECT_ALARM_ATTEMPTS } from '@ai-matrx/realtime';
3
3
  import { z } from 'zod';
4
- import { W as Welcome, D as DesktopProtocolError, C as CloseOutcome, O as OpName, a as OpParams, b as OpResult, c as OPS, S as StreamMeta, E as EndReason, d as EVENTS, e as ClientType, M as ModelsTranscribeResult, T as TranscriptionModelId, f as MlProgress } from './models-CzKyJhDP.cjs';
5
- export { i as isDesktopProtocolError } from './models-CzKyJhDP.cjs';
4
+ import { W as Welcome, D as DesktopProtocolError, C as CloseOutcome, O as OpName, a as OpParams, b as OpResult, c as OPS, S as StreamMeta, E as EndReason, d as EVENTS, e as ClientType, M as ModelsTranscribeResult, T as TranscriptionModelId, f as MlProgress } from './models-BNbWn8EL.cjs';
5
+ export { i as isDesktopProtocolError } from './models-BNbWn8EL.cjs';
6
6
  import { FrameHeader } from './frame.cjs';
7
7
 
8
8
  /** The subset of the WHATWG WebSocket the client uses — browser, React Native, `ws` and Workers all fit. */
package/dist/client.d.ts CHANGED
@@ -1,8 +1,8 @@
1
1
  import { BackoffOptions } from '@ai-matrx/realtime';
2
2
  export { RECONNECT_ALARM_ATTEMPTS } from '@ai-matrx/realtime';
3
3
  import { z } from 'zod';
4
- import { W as Welcome, D as DesktopProtocolError, C as CloseOutcome, O as OpName, a as OpParams, b as OpResult, c as OPS, S as StreamMeta, E as EndReason, d as EVENTS, e as ClientType, M as ModelsTranscribeResult, T as TranscriptionModelId, f as MlProgress } from './models-CzKyJhDP.js';
5
- export { i as isDesktopProtocolError } from './models-CzKyJhDP.js';
4
+ import { W as Welcome, D as DesktopProtocolError, C as CloseOutcome, O as OpName, a as OpParams, b as OpResult, c as OPS, S as StreamMeta, E as EndReason, d as EVENTS, e as ClientType, M as ModelsTranscribeResult, T as TranscriptionModelId, f as MlProgress } from './models-BNbWn8EL.js';
5
+ export { i as isDesktopProtocolError } from './models-BNbWn8EL.js';
6
6
  import { FrameHeader } from './frame.js';
7
7
 
8
8
  /** The subset of the WHATWG WebSocket the client uses — browser, React Native, `ws` and Workers all fit. */
package/dist/client.js CHANGED
@@ -112,7 +112,7 @@ import { z as z2 } from "zod";
112
112
  import { z } from "zod";
113
113
  import { UUID_SHAPE_PATTERN } from "@ai-matrx/kit/uuid";
114
114
  var PROTOCOL_MAJOR = 1;
115
- var PROTOCOL_MINOR = 39;
115
+ var PROTOCOL_MINOR = 42;
116
116
  var PROTOCOL_VERSION = `${PROTOCOL_MAJOR}.${PROTOCOL_MINOR}`;
117
117
  var ProtocolVersion = z.string().regex(/^[1-9][0-9]{0,2}\.[0-9]{1,3}$/);
118
118
  var RequestId = z.string().min(1).max(64).regex(/^[A-Za-z0-9_-]+$/);
@@ -395,8 +395,17 @@ var OsPermissionName = z5.enum([
395
395
  "location",
396
396
  "local_network",
397
397
  "bluetooth",
398
- "notifications"
398
+ "notifications",
399
+ // (1.41) Matrx Local's remaining kinds, checked on every OS (its permissions checker): a peer
400
+ // older than 1.41 is never sent these rows (versioning.ts PERMISSIONS_SINCE).
401
+ "reminders",
402
+ "speech_recognition",
403
+ "messages",
404
+ "mail",
405
+ "wifi"
399
406
  ]);
407
+ var OsGrantState = z5.enum(["granted", "denied", "not_determined", "not_applicable"]);
408
+ var OsRequirementName = z5.enum(["secret_storage", "tray", "display_server", "helper_programs", "smart_app_control", "path_length"]);
400
409
  var SysinfoGetParams = z5.strictObject({});
401
410
  var SysinfoGetResult = z5.strictObject({
402
411
  device_id: DeviceId,
@@ -426,9 +435,20 @@ var SysinfoGetResult = z5.strictObject({
426
435
  z5.strictObject({
427
436
  name: OsPermissionName,
428
437
  state: z5.enum(["granted", "denied", "not_determined", "not_applicable"]),
429
- settings_url: z5.string().max(512).nullable()
438
+ settings_url: z5.string().max(512).nullable(),
439
+ /** (1.41) One short fact when the state alone does not say it ("No camera", "Bluetooth is off"); absent when there is none. */
440
+ detail: z5.string().max(256).optional()
430
441
  })
431
- )
442
+ ),
443
+ /** (1.41) The requirements beyond the grants (OsRequirementName), each read when asked. */
444
+ requirements: z5.array(
445
+ z5.strictObject({
446
+ name: OsRequirementName,
447
+ state: OsGrantState,
448
+ settings_url: z5.string().max(512).nullable(),
449
+ detail: z5.string().max(256).nullable()
450
+ })
451
+ ).optional()
432
452
  });
433
453
  var SysinfoHardwareParams = z5.strictObject({});
434
454
  var SysinfoHardwareResult = z5.strictObject({
@@ -975,10 +995,12 @@ var GitCloneParams = z12.strictObject({
975
995
  });
976
996
 
977
997
  // src/schema/web.ts
998
+ import { UUID_SHAPE_PATTERN as UUID_SHAPE_PATTERN2 } from "@ai-matrx/kit/uuid";
978
999
  import { z as z13 } from "zod";
979
1000
  var WEB_MAX_TEXT_CHARS = 524288;
980
1001
  var WebUrl = z13.string().min(1).max(8192).regex(/^https?:\/\//);
981
1002
  var WebText = z13.string().max(WEB_MAX_TEXT_CHARS);
1003
+ var OrgId = z13.string().regex(UUID_SHAPE_PATTERN2);
982
1004
  var WebHeader = z13.strictObject({ name: z13.string().min(1).max(256), value: z13.string().max(8192) });
983
1005
  var WebFetchParams = z13.strictObject({
984
1006
  url: WebUrl,
@@ -1000,10 +1022,65 @@ var WebFetchResult = z13.strictObject({
1000
1022
  bytes: nonNegInt,
1001
1023
  elapsed_ms: nonNegInt
1002
1024
  });
1025
+ var WebAttachTarget = z13.strictObject({
1026
+ entity_type: z13.string().min(1).max(64),
1027
+ entity_id: z13.string().min(1).max(128),
1028
+ label: z13.string().max(200).optional()
1029
+ });
1030
+ var WebLand = z13.strictObject({
1031
+ /** The organization the page is saved in; absent: this computer's active organization. */
1032
+ organization_id: OrgId.optional(),
1033
+ /** Keep it: AI processing starts (chunks, search). Unkept pages are saved and wait. */
1034
+ keep: z13.boolean().default(false),
1035
+ attach_to: z13.array(WebAttachTarget).max(8).default([])
1036
+ });
1037
+ var WebNotSavedReason = z13.enum([
1038
+ /** Nobody is signed in on this computer. Saved on sign-in. */
1039
+ "signed_out",
1040
+ /** AI Matrx could not be reached. Retried on its own. */
1041
+ "offline",
1042
+ /** AI Matrx refused it (the message says why). Kept until the person retries or discards it. */
1043
+ "rejected",
1044
+ /** Waiting its turn behind other pages (retried on its own). */
1045
+ "queued"
1046
+ ]);
1047
+ var WebSourceNotice = z13.strictObject({ code: z13.string().max(120), message: z13.string().max(2e3), remedy: z13.string().max(120) });
1048
+ var WebSourceState = z13.discriminatedUnion("state", [
1049
+ z13.strictObject({
1050
+ state: z13.literal("saved"),
1051
+ processed_document_id: z13.string().min(1).max(64),
1052
+ source_id: z13.string().min(1).max(128),
1053
+ /** The page was already saved and nothing changed ("Already saved, no change"). */
1054
+ reused_existing: z13.boolean(),
1055
+ /** The page changed: this is a new version of that Source. */
1056
+ new_version_of: z13.string().max(64).nullable(),
1057
+ kept: z13.boolean(),
1058
+ intelligence: z13.enum(["queued", "deferred", "never"]),
1059
+ /** The original page as captured, kept by AI Matrx (null: the organization keeps none). */
1060
+ original_file_id: z13.string().max(128).nullable(),
1061
+ /** The organization it was saved in. */
1062
+ organization_id: OrgId,
1063
+ notices: z13.array(WebSourceNotice).max(20)
1064
+ }),
1065
+ z13.strictObject({
1066
+ state: z13.literal("not_saved"),
1067
+ outbox_id: z13.string().min(1).max(64),
1068
+ reason: WebNotSavedReason,
1069
+ message: z13.string().max(2e3)
1070
+ })
1071
+ ]);
1003
1072
  var WebScrapeParams = z13.strictObject({
1004
1073
  urls: z13.array(WebUrl).min(1).max(20),
1005
1074
  use_cache: z13.boolean().default(true),
1006
- get_links: z13.boolean().default(false)
1075
+ get_links: z13.boolean().default(false),
1076
+ /**
1077
+ * Since 1.38. `auto` (absent): this computer's scraper (HTTP, its browser only when a page needs
1078
+ * it). `browser`: this computer's own browser renders every page. `server`: AI Matrx's servers
1079
+ * read it (their connection, not this computer's; saved there as a web capture).
1080
+ */
1081
+ engine: z13.enum(["auto", "browser", "server"]).optional(),
1082
+ /** Since 1.38: where the pages are saved (see WebLand). */
1083
+ land: WebLand.optional()
1007
1084
  });
1008
1085
  var WebScrapePage = z13.strictObject({
1009
1086
  url: z13.string(),
@@ -1018,7 +1095,9 @@ var WebScrapePage = z13.strictObject({
1018
1095
  /** Why the page failed (blocked, timeout, not found…), in the scraper's words; null when ok. */
1019
1096
  error: z13.string().nullable(),
1020
1097
  /** How the page was fetched (http, browser, cache). */
1021
- via: z13.string().nullable()
1098
+ via: z13.string().nullable(),
1099
+ /** Since 1.38: the page's Source (absent from a 1.37 core, and for a page that failed). */
1100
+ source: WebSourceState.optional()
1022
1101
  });
1023
1102
  var WebScrapeResult = z13.strictObject({ pages: z13.array(WebScrapePage), elapsed_ms: nonNegInt });
1024
1103
  var WebSearchParams = z13.strictObject({
@@ -1042,7 +1121,9 @@ var WebBrowserFetchParams = z13.strictObject({
1042
1121
  wait_for: z13.string().max(1024).optional(),
1043
1122
  wait_timeout_ms: z13.int().min(100).max(12e4).default(3e4),
1044
1123
  /** true: readable text; false: the rendered HTML. */
1045
- extract_text: z13.boolean().default(true)
1124
+ extract_text: z13.boolean().default(true),
1125
+ /** Since 1.38: where the rendered page is saved (see WebLand). */
1126
+ land: WebLand.optional()
1046
1127
  });
1047
1128
  var WebBrowserFetchResult = z13.strictObject({
1048
1129
  url: z13.string(),
@@ -1050,14 +1131,144 @@ var WebBrowserFetchResult = z13.strictObject({
1050
1131
  title: z13.string().nullable(),
1051
1132
  content: WebText,
1052
1133
  truncated: z13.boolean(),
1053
- elapsed_ms: nonNegInt
1134
+ elapsed_ms: nonNegInt,
1135
+ /** Since 1.38: the rendered page's Source (absent from a 1.37 core). */
1136
+ source: WebSourceState.optional()
1137
+ });
1138
+ var ToolsParseFile = z13.strictObject({
1139
+ /** Absolute path of the gzipped JSON the core reads, saves and then removes. */
1140
+ path: z13.string().min(1).max(4096),
1141
+ bytes: nonNegInt
1142
+ });
1143
+ var ToolsWebScrapeParams = z13.strictObject({
1144
+ urls: z13.array(WebUrl).min(1).max(20),
1145
+ use_cache: z13.boolean().default(true),
1146
+ get_links: z13.boolean().default(false),
1147
+ /** `browser`: render every page in this computer's browser, then parse it. */
1148
+ engine: z13.enum(["auto", "browser"]).default("auto"),
1149
+ /** Pages read at once (desktop.web/scrape_concurrency). */
1150
+ concurrency: z13.int().min(1).max(20).default(5),
1151
+ /** The wait between pages from the same site (desktop.web/request_delay_ms). */
1152
+ delay_ms: z13.int().min(0).max(3e4).default(0),
1153
+ /** Where the parse files go (the core's spool folder). */
1154
+ spool_dir: z13.string().min(1).max(4096)
1155
+ });
1156
+ var ToolsWebScrapePage = z13.strictObject({
1157
+ page: WebScrapePage,
1158
+ /** The page's whole parse, for the door; null when the page failed or had no words. */
1159
+ parse: ToolsParseFile.nullable(),
1160
+ /** The page as fetched, for research (rendered HTML or the HTTP body); null when not kept. */
1161
+ html: ToolsParseFile.nullable()
1162
+ });
1163
+ var ToolsWebScrapeResult = z13.strictObject({ pages: z13.array(ToolsWebScrapePage), elapsed_ms: nonNegInt });
1164
+ var ToolsWebBrowserFetchParams = z13.strictObject({
1165
+ url: WebUrl,
1166
+ wait_for: z13.string().max(1024).optional(),
1167
+ wait_timeout_ms: z13.int().min(100).max(12e4).default(3e4),
1168
+ extract_text: z13.boolean().default(true),
1169
+ spool_dir: z13.string().min(1).max(4096)
1170
+ });
1171
+ var ToolsWebBrowserFetchResult = z13.strictObject({ result: WebBrowserFetchResult, parse: ToolsParseFile.nullable() });
1172
+ var WebRuntimeStateName = z13.enum(["not_installed", "installing", "installed", "failed"]);
1173
+ var WebRuntimeParams = z13.strictObject({});
1174
+ var WebRuntimeState = z13.strictObject({
1175
+ state: WebRuntimeStateName,
1176
+ /** Why it failed, in the installer's words; null otherwise. */
1177
+ error: z13.string().max(2e3).nullable(),
1178
+ /** Bytes the browser takes on this computer (its packages and Chromium); null when unknown. */
1179
+ size_bytes: nonNegInt.nullable(),
1180
+ /** Whether it can show a window while it works (false: only the headless shell is installed). */
1181
+ can_show_window: z13.boolean()
1182
+ });
1183
+ var WebOutboxItem = z13.strictObject({
1184
+ outbox_id: z13.string().min(1).max(64),
1185
+ url: z13.string().max(8192),
1186
+ title: z13.string().max(500).nullable(),
1187
+ organization_id: OrgId.nullable(),
1188
+ reason: WebNotSavedReason,
1189
+ message: z13.string().max(2e3),
1190
+ attempts: nonNegInt,
1191
+ created_at_ms: nonNegInt,
1192
+ last_attempt_at_ms: nonNegInt.nullable(),
1193
+ bytes: nonNegInt
1194
+ });
1195
+ var WebOutboxListParams = z13.strictObject({});
1196
+ var WebOutboxListResult = z13.strictObject({
1197
+ items: z13.array(WebOutboxItem),
1198
+ bytes: nonNegInt,
1199
+ /** The most the outbox holds; past it the oldest pages are dropped (and the log says so). */
1200
+ cap_bytes: nonNegInt
1201
+ });
1202
+ var WebOutboxRetryParams = z13.strictObject({ outbox_id: z13.string().min(1).max(64).optional() });
1203
+ var WebOutboxRetryResult = z13.strictObject({ saved: nonNegInt, waiting: nonNegInt });
1204
+ var WebOutboxDiscardParams = z13.strictObject({ outbox_id: z13.string().min(1).max(64) });
1205
+ var WebOutboxDiscardResult = z13.strictObject({ discarded: z13.boolean() });
1206
+ var WebLogVia = z13.enum(["this_computer", "browser", "server"]);
1207
+ var WebLogCaller = z13.enum(["person", "agent", "research", "phone", "other"]);
1208
+ var WebLogResult = z13.enum(["saved", "not_saved", "failed", "blocked", "read"]);
1209
+ var WebLogEntry = z13.strictObject({
1210
+ id: z13.string().min(1).max(64),
1211
+ at_ms: nonNegInt,
1212
+ caller: WebLogCaller,
1213
+ url: z13.string().max(8192),
1214
+ title: z13.string().max(500).nullable(),
1215
+ result: WebLogResult,
1216
+ /** One sentence: why it failed or was blocked, or the save's notice. Never page text. */
1217
+ detail: z13.string().max(1e3).nullable(),
1218
+ via: WebLogVia,
1219
+ duration_ms: nonNegInt,
1220
+ processed_document_id: z13.string().max(64).nullable()
1221
+ });
1222
+ var WebLogListParams = z13.strictObject({ since_ms: nonNegInt.optional(), limit: z13.int().min(1).max(1e3).default(200) });
1223
+ var WebLogListResult = z13.strictObject({ entries: z13.array(WebLogEntry) });
1224
+ var WebLogClearParams = z13.strictObject({});
1225
+ var WebLogClearResult = z13.strictObject({ cleared: nonNegInt });
1226
+ var WebProgressEvent = z13.strictObject({
1227
+ request_id: RequestId,
1228
+ phase: z13.enum(["installing", "fetching", "saving"]),
1229
+ done: nonNegInt,
1230
+ total: nonNegInt
1231
+ });
1232
+ var WebResearchItemState = z13.enum(["waiting", "fetching", "saved", "thin", "failed", "cannot_edit", "blocked"]);
1233
+ var WebResearchItem = z13.strictObject({
1234
+ topic_id: z13.string().min(1).max(64),
1235
+ topic_name: z13.string().max(500),
1236
+ source_id: z13.string().min(1).max(64),
1237
+ url: z13.string().max(8192),
1238
+ title: z13.string().max(500).nullable(),
1239
+ /** The capture level this computer would try (1 quick, 2 scroll); 3+ is the extension's. */
1240
+ level: z13.int().min(1).max(4),
1241
+ last_failure: z13.string().max(1e3).nullable(),
1242
+ state: WebResearchItemState,
1243
+ /** One sentence after a fetch: what happened. */
1244
+ message: z13.string().max(1e3).nullable()
1245
+ });
1246
+ var WebResearchQueueParams = z13.strictObject({ topic_id: z13.string().min(1).max(64).optional() });
1247
+ var WebResearchQueueResult = z13.strictObject({
1248
+ state: z13.enum(["ready", "signed_out", "unavailable"]),
1249
+ problem: z13.string().max(1e3).nullable(),
1250
+ /** L1/L2 items on topics this person can edit: what this computer can fetch. */
1251
+ items: z13.array(WebResearchItem),
1252
+ /** Items on topics the person can view but not add to (shown, never fetched). */
1253
+ view_only: nonNegInt
1254
+ });
1255
+ var WebResearchFetchParams = z13.strictObject({
1256
+ topic_id: z13.string().min(1).max(64).optional(),
1257
+ source_ids: z13.array(z13.string().min(1).max(64)).max(200).optional()
1258
+ });
1259
+ var WebResearchFetchResult = z13.strictObject({
1260
+ items: z13.array(WebResearchItem),
1261
+ saved: nonNegInt,
1262
+ thin: nonNegInt,
1263
+ failed: nonNegInt,
1264
+ cannot_edit: nonNegInt
1054
1265
  });
1055
1266
  var ToolsServiceProgress = z13.strictObject({ phase: z13.enum(["fetching", "installing"]), done: nonNegInt, total: nonNegInt });
1056
1267
 
1057
1268
  // src/schema/account.ts
1058
1269
  import { z as z14 } from "zod";
1059
- import { UUID_SHAPE_PATTERN as UUID_SHAPE_PATTERN2 } from "@ai-matrx/kit/uuid";
1060
- var AccountRowId = z14.string().regex(UUID_SHAPE_PATTERN2);
1270
+ import { UUID_SHAPE_PATTERN as UUID_SHAPE_PATTERN3 } from "@ai-matrx/kit/uuid";
1271
+ var AccountRowId = z14.string().regex(UUID_SHAPE_PATTERN3);
1061
1272
  var AccountReadState = z14.enum(["ok", "signed_out", "unavailable"]);
1062
1273
  var AccountAgent = z14.strictObject({
1063
1274
  id: AccountRowId,
@@ -1291,7 +1502,27 @@ var SystemSettingsPane = z16.enum([
1291
1502
  "storage",
1292
1503
  "system_report",
1293
1504
  /** (1.35) Privacy & Security › Microphone: where the person allows Matrx 2 the microphone. */
1294
- "microphone"
1505
+ "microphone",
1506
+ // (1.41) Each other privacy grant's own page (Settings › Permissions and privacy's buttons), named
1507
+ // as sysinfo's OsPermissionName so a row opens its pane by its own name. A 1.40 core refuses these
1508
+ // as INVALID_PARAMS, so a client asks only a 1.41 core for them.
1509
+ "full_disk_access",
1510
+ "accessibility",
1511
+ "screen_recording",
1512
+ "camera",
1513
+ "automation",
1514
+ "contacts",
1515
+ "calendars",
1516
+ "reminders",
1517
+ "photos",
1518
+ "location",
1519
+ "local_network",
1520
+ "bluetooth",
1521
+ "wifi",
1522
+ "notifications",
1523
+ "speech_recognition",
1524
+ "messages",
1525
+ "mail"
1295
1526
  ]);
1296
1527
  var SystemOpenSettingsParams = z16.strictObject({ pane: SystemSettingsPane });
1297
1528
  var SystemOpenSettingsResult = z16.strictObject({ pane: SystemSettingsPane });
@@ -1997,10 +2228,10 @@ var ExecJobListResult = z26.strictObject({ jobs: z26.array(ExecJobInfo).max(64)
1997
2228
 
1998
2229
  // src/schema/coding.ts
1999
2230
  import { z as z27 } from "zod";
2000
- import { UUID_SHAPE_PATTERN as UUID_SHAPE_PATTERN3 } from "@ai-matrx/kit/uuid";
2231
+ import { UUID_SHAPE_PATTERN as UUID_SHAPE_PATTERN4 } from "@ai-matrx/kit/uuid";
2001
2232
  var CodingServiceCredentials = z27.strictObject({
2002
2233
  access_token: z27.string().min(16).max(16384),
2003
- user_id: z27.string().regex(UUID_SHAPE_PATTERN3),
2234
+ user_id: z27.string().regex(UUID_SHAPE_PATTERN4),
2004
2235
  /** The AI Matrx server this app talks to (production, or a local server on the nightly copy). */
2005
2236
  server_url: z27.string().min(1).max(2048).regex(/^https?:\/\/[^\s/?#]+(\/[^\s?#]*)?$/)
2006
2237
  });
@@ -2438,9 +2669,9 @@ var SessionIdentifyResult = z28.strictObject({ label: z28.string().max(60) });
2438
2669
 
2439
2670
  // src/schema/apps.ts
2440
2671
  import { z as z29 } from "zod";
2441
- import { UUID_SHAPE_PATTERN as UUID_SHAPE_PATTERN4 } from "@ai-matrx/kit/uuid";
2672
+ import { UUID_SHAPE_PATTERN as UUID_SHAPE_PATTERN5 } from "@ai-matrx/kit/uuid";
2442
2673
  var AppKey = z29.string().regex(/^[a-z][a-z0-9_-]{0,39}$/);
2443
- var AppProfileId = z29.string().regex(UUID_SHAPE_PATTERN4);
2674
+ var AppProfileId = z29.string().regex(UUID_SHAPE_PATTERN5);
2444
2675
  var AppProfileLocator = z29.string().min(1).max(512).regex(/^[A-Za-z0-9 _()+@,-][A-Za-z0-9 ._()+@,-]{0,127}(\/[A-Za-z0-9 _()+@,-][A-Za-z0-9 ._()+@,-]{0,127}){0,7}$/);
2445
2676
  var AppSupport = z29.enum(["supported", "partial", "unsupported"]);
2446
2677
  var AppFeatureStatus = z29.strictObject({
@@ -3378,7 +3609,12 @@ var MessagesListResult = z34.strictObject({ messages: z34.array(MessagesMessage)
3378
3609
  var MessagesSendParams = z34.strictObject({
3379
3610
  /** A phone number or email the person can message. */
3380
3611
  to: z34.string().min(3).max(320),
3381
- text: z34.string().min(1).max(2e4)
3612
+ text: z34.string().min(1).max(2e4),
3613
+ /**
3614
+ * Send only over this service (Matrx Local's SendMessage `service`). Absent: iMessage first, and
3615
+ * SMS when the recipient has no iMessage (since 1.42).
3616
+ */
3617
+ service: z34.enum(["iMessage", "SMS"]).optional()
3382
3618
  });
3383
3619
  var MessagesSendResult = z34.strictObject({ sent: z34.boolean() });
3384
3620
  var ContactsSearchParams = z34.strictObject({
@@ -3932,6 +4168,16 @@ var OPS = {
3932
4168
  "web.scrape": { params: WebScrapeParams, result: WebScrapeResult, kind: "unary", since: "1.22", errors: ["INVALID_PARAMS", "TIMEOUT", "RESOURCE_BUSY", "AUTH_REQUIRED", "INTERNAL"] },
3933
4169
  "web.search": { params: WebSearchParams, result: WebSearchResult, kind: "unary", since: "1.22", errors: ["INVALID_PARAMS", "TIMEOUT", "RESOURCE_BUSY", "AUTH_REQUIRED", "INTERNAL"] },
3934
4170
  "web.fetch_with_browser": { params: WebBrowserFetchParams, result: WebBrowserFetchResult, kind: "unary", since: "1.22", errors: ["INVALID_PARAMS", "TIMEOUT", "RESOURCE_BUSY", "AUTH_REQUIRED", "INTERNAL"] },
4171
+ "web.runtime.state": { params: WebRuntimeParams, result: WebRuntimeState, kind: "unary", since: "1.40", errors: ["INTERNAL"] },
4172
+ "web.runtime.install": { params: WebRuntimeParams, result: WebRuntimeState, kind: "unary", since: "1.40", errors: ["TIMEOUT", "RESOURCE_BUSY", "CANCELLED", "INTERNAL"] },
4173
+ "web.runtime.remove": { params: WebRuntimeParams, result: WebRuntimeState, kind: "unary", since: "1.40", errors: ["RESOURCE_BUSY", "INTERNAL"] },
4174
+ "web.outbox.list": { params: WebOutboxListParams, result: WebOutboxListResult, kind: "unary", since: "1.40", errors: ["INTERNAL"] },
4175
+ "web.outbox.retry": { params: WebOutboxRetryParams, result: WebOutboxRetryResult, kind: "unary", since: "1.40", errors: ["NOT_FOUND", "AUTH_REQUIRED", "INTERNAL"] },
4176
+ "web.outbox.discard": { params: WebOutboxDiscardParams, result: WebOutboxDiscardResult, kind: "unary", since: "1.40", errors: ["NOT_FOUND", "INTERNAL"] },
4177
+ "web.log.list": { params: WebLogListParams, result: WebLogListResult, kind: "unary", since: "1.40", errors: ["INVALID_PARAMS"] },
4178
+ "web.log.clear": { params: WebLogClearParams, result: WebLogClearResult, kind: "unary", since: "1.40", errors: ["INTERNAL"] },
4179
+ "web.research.queue": { params: WebResearchQueueParams, result: WebResearchQueueResult, kind: "unary", since: "1.40", errors: ["INVALID_PARAMS", "INTERNAL"] },
4180
+ "web.research.fetch": { params: WebResearchFetchParams, result: WebResearchFetchResult, kind: "unary", since: "1.40", errors: ["INVALID_PARAMS", "AUTH_REQUIRED", "RESOURCE_BUSY", "CANCELLED", "INTERNAL"] },
3935
4181
  // 1.23: the signed-in person's own agents and Vault, read as them (the desktop's Agents library and Vault).
3936
4182
  "account.agents.list": { params: AccountAgentsListParams, result: AccountAgentsListResult, kind: "unary", since: "1.23", errors: ["INTERNAL"] },
3937
4183
  "account.vault.list": { params: AccountVaultListParams, result: AccountVaultListResult, kind: "unary", since: "1.23", errors: ["INTERNAL"] },
@@ -4022,7 +4268,9 @@ var EVENTS = {
4022
4268
  "diag.errors.changed": DiagErrorsChangedEvent,
4023
4269
  "browser.invoke": BrowserInvokeEvent,
4024
4270
  "browser.sessions_changed": BrowserSessionsChangedEvent,
4025
- "browser.progress": BrowserProgressEvent
4271
+ "browser.progress": BrowserProgressEvent,
4272
+ "web.log.entry": WebLogEntry,
4273
+ "web.progress": WebProgressEvent
4026
4274
  };
4027
4275
 
4028
4276
  // src/versioning.ts
@@ -4039,7 +4287,9 @@ var RESULT_PATH = /* @__PURE__ */ new Map([
4039
4287
  ["apps.chats.list", "AppsChatsListResult"],
4040
4288
  ["apps.accounts.usage", "AppsAccountsUsageResult"],
4041
4289
  ["apps.accounts.resets", "AppsAccountsResetsResult"],
4042
- ["apps.windows.update_state", "AppsWindowsUpdateStateResult"]
4290
+ ["apps.windows.update_state", "AppsWindowsUpdateStateResult"],
4291
+ ["web.fetch_with_browser", "WebBrowserFetchResult"],
4292
+ ["sysinfo.get", "SysinfoGetResult"]
4043
4293
  ]);
4044
4294
  var NESTED_RESULTS = /* @__PURE__ */ new Map([
4045
4295
  ["apps.chats.list", [["chats", "ChatRow"]]],
@@ -4052,7 +4302,9 @@ var NESTED_RESULTS = /* @__PURE__ */ new Map([
4052
4302
  ["apps.accounts.usage", [["accounts", "AccountUsage"]]],
4053
4303
  ["resources.snapshot", [["disks", "ResourcesDisk"]]],
4054
4304
  ["stack.state", [["servers", "StackServer"]]],
4055
- ["account.agents.list", [["agents", "AccountAgent"]]]
4305
+ ["account.agents.list", [["agents", "AccountAgent"]]],
4306
+ ["web.scrape", [["pages", "WebScrapePage"]]],
4307
+ ["sysinfo.get", [["permissions", "SysinfoGetResult.permissions[]"]]]
4056
4308
  ]);
4057
4309
  var WINDOW_RESULTS = /* @__PURE__ */ new Map([
4058
4310
  ["window.list", "windows"],