@ai-matrx/desktop-protocol 0.16.1 → 0.17.1

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-CCOaAWaM.cjs';
5
- export { i as isDesktopProtocolError } from './models-CCOaAWaM.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-Dj_B9wHj.cjs';
5
+ export { i as isDesktopProtocolError } from './models-Dj_B9wHj.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-CCOaAWaM.js';
5
- export { i as isDesktopProtocolError } from './models-CCOaAWaM.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-Dj_B9wHj.js';
5
+ export { i as isDesktopProtocolError } from './models-Dj_B9wHj.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
@@ -94,7 +94,7 @@ import { z as z2 } from "zod";
94
94
  // src/schema/primitives.ts
95
95
  import { z } from "zod";
96
96
  var PROTOCOL_MAJOR = 1;
97
- var PROTOCOL_MINOR = 5;
97
+ var PROTOCOL_MINOR = 6;
98
98
  var PROTOCOL_VERSION = `${PROTOCOL_MAJOR}.${PROTOCOL_MINOR}`;
99
99
  var ProtocolVersion = z.string().regex(/^[1-9][0-9]{0,2}\.[0-9]{1,3}$/);
100
100
  var RequestId = z.string().min(1).max(64).regex(/^[A-Za-z0-9_-]+$/);
@@ -1077,117 +1077,147 @@ var PowerPreventSleepResult = z17.strictObject({
1077
1077
  awake_until_ms: epochMs.nullable()
1078
1078
  });
1079
1079
 
1080
- // src/schema/resources.ts
1080
+ // src/schema/audio.ts
1081
1081
  import { z as z18 } from "zod";
1082
- var ResourcesDisk = z18.strictObject({
1082
+ var AudioDevice = z18.strictObject({
1083
+ /** The OS's name for it, as audio.record takes it. */
1084
+ id: z18.string().min(1).max(256),
1085
+ name: z18.string().max(256),
1086
+ default: z18.boolean()
1087
+ });
1088
+ var AudioDevicesParams = z18.strictObject({});
1089
+ var AudioDevicesResult = z18.strictObject({
1090
+ inputs: z18.array(AudioDevice).max(64),
1091
+ outputs: z18.array(AudioDevice).max(64)
1092
+ });
1093
+ var AudioRecordParams = z18.strictObject({
1094
+ seconds: z18.number().min(0.5).max(600),
1095
+ /** The microphone (from audio.devices); the default input when absent. */
1096
+ device_id: z18.string().min(1).max(256).optional(),
1097
+ /** Where the WAV file goes; a new file in the temp folder when absent. */
1098
+ path: AbsPath.optional()
1099
+ });
1100
+ var AudioRecordResult = z18.strictObject({
1101
+ path: AbsPath,
1102
+ seconds: z18.number().min(0),
1103
+ bytes: nonNegInt,
1104
+ /** Loudest sample, 0–1: 0 means the device gave silence. */
1105
+ peak: z18.number().min(0).max(1)
1106
+ });
1107
+ var AudioPlayParams = z18.strictObject({ path: AbsPath });
1108
+ var AudioPlayResult = z18.strictObject({ path: AbsPath, seconds: z18.number().min(0) });
1109
+
1110
+ // src/schema/resources.ts
1111
+ import { z as z19 } from "zod";
1112
+ var ResourcesDisk = z19.strictObject({
1083
1113
  /** Where it is mounted ("/", "C:"). */
1084
- mount: z18.string().max(512),
1114
+ mount: z19.string().max(512),
1085
1115
  /** The file system ("apfs", "NTFS", "ext4"). */
1086
- fs: z18.string().max(64),
1116
+ fs: z19.string().max(64),
1087
1117
  size_bytes: nonNegInt,
1088
1118
  used_bytes: nonNegInt,
1089
1119
  available_bytes: nonNegInt
1090
1120
  });
1091
- var ResourcesSnapshotParams = z18.strictObject({});
1092
- var ResourcesSnapshotResult = z18.strictObject({
1093
- cpu: z18.strictObject({
1121
+ var ResourcesSnapshotParams = z19.strictObject({});
1122
+ var ResourcesSnapshotResult = z19.strictObject({
1123
+ cpu: z19.strictObject({
1094
1124
  /** Busy share of all cores, 0–100, measured now. */
1095
- percent: z18.number().min(0).max(100),
1096
- cores: z18.int().min(1),
1125
+ percent: z19.number().min(0).max(100),
1126
+ cores: z19.int().min(1),
1097
1127
  /** 1, 5 and 15 minute load averages; null on Windows. */
1098
- load: z18.array(z18.number().min(0)).length(3).nullable()
1128
+ load: z19.array(z19.number().min(0)).length(3).nullable()
1099
1129
  }),
1100
- memory: z18.strictObject({ total_bytes: nonNegInt, used_bytes: nonNegInt, available_bytes: nonNegInt }),
1101
- swap: z18.strictObject({ total_bytes: nonNegInt, used_bytes: nonNegInt }),
1102
- disks: z18.array(ResourcesDisk).max(64),
1130
+ memory: z19.strictObject({ total_bytes: nonNegInt, used_bytes: nonNegInt, available_bytes: nonNegInt }),
1131
+ swap: z19.strictObject({ total_bytes: nonNegInt, used_bytes: nonNegInt }),
1132
+ disks: z19.array(ResourcesDisk).max(64),
1103
1133
  uptime_seconds: nonNegInt
1104
1134
  });
1105
1135
 
1106
1136
  // src/schema/fs-watch.ts
1107
- import { z as z19 } from "zod";
1108
- var FsWatchId = z19.string().regex(/^fw_[A-Za-z0-9]{12,40}$/);
1109
- var FsWatchStartParams = z19.strictObject({
1137
+ import { z as z20 } from "zod";
1138
+ var FsWatchId = z20.string().regex(/^fw_[A-Za-z0-9]{12,40}$/);
1139
+ var FsWatchStartParams = z20.strictObject({
1110
1140
  path: AbsPath,
1111
- recursive: z19.boolean().default(true),
1141
+ recursive: z20.boolean().default(true),
1112
1142
  /** Globs relative to `path` whose changes are not reported (".git/**", "node_modules/**"). */
1113
- ignore: z19.array(z19.string().max(256)).max(64).default([])
1143
+ ignore: z20.array(z20.string().max(256)).max(64).default([])
1114
1144
  });
1115
- var FsWatchStartResult = z19.strictObject({
1145
+ var FsWatchStartResult = z20.strictObject({
1116
1146
  watch_id: FsWatchId,
1117
1147
  path: AbsPath,
1118
1148
  /** The watch ends by itself if nobody reads it for 30 minutes. */
1119
1149
  expires_at_ms: epochMs
1120
1150
  });
1121
- var FsWatchEventsParams = z19.strictObject({
1151
+ var FsWatchEventsParams = z20.strictObject({
1122
1152
  watch_id: FsWatchId,
1123
1153
  /** Wait up to this long for a first change when none is waiting (0 answers at once). */
1124
- wait_ms: z19.int().min(0).max(25e3).default(0)
1154
+ wait_ms: z20.int().min(0).max(25e3).default(0)
1125
1155
  });
1126
- var FsWatchEventsResult = z19.strictObject({
1156
+ var FsWatchEventsResult = z20.strictObject({
1127
1157
  /** What changed since the last read, oldest first; re-checked against the disk when read. */
1128
- changes: z19.array(FsChange).max(1e3),
1158
+ changes: z20.array(FsChange).max(1e3),
1129
1159
  /** Changes were dropped (more than 1000 waited): list the folder again. */
1130
- overflow: z19.boolean(),
1160
+ overflow: z20.boolean(),
1131
1161
  expires_at_ms: epochMs
1132
1162
  });
1133
- var FsWatchStopParams = z19.strictObject({ watch_id: FsWatchId });
1134
- var FsWatchStopResult = z19.strictObject({ watch_id: FsWatchId });
1163
+ var FsWatchStopParams = z20.strictObject({ watch_id: FsWatchId });
1164
+ var FsWatchStopResult = z20.strictObject({ watch_id: FsWatchId });
1135
1165
 
1136
1166
  // src/schema/exec-job.ts
1137
- import { z as z20 } from "zod";
1138
- var ExecJobId = z20.string().regex(/^job_[A-Za-z0-9]{12,40}$/);
1139
- var ExecJobStartParams = z20.strictObject({
1140
- command: z20.string().min(1).max(131072),
1167
+ import { z as z21 } from "zod";
1168
+ var ExecJobId = z21.string().regex(/^job_[A-Za-z0-9]{12,40}$/);
1169
+ var ExecJobStartParams = z21.strictObject({
1170
+ command: z21.string().min(1).max(131072),
1141
1171
  /** The folder it runs in; the home folder when absent. */
1142
1172
  cwd: AbsPath.optional(),
1143
- env: z20.record(z20.string().regex(/^[A-Za-z_][A-Za-z0-9_]*$/).max(128), z20.string().max(32768)).optional()
1173
+ env: z21.record(z21.string().regex(/^[A-Za-z_][A-Za-z0-9_]*$/).max(128), z21.string().max(32768)).optional()
1144
1174
  });
1145
- var ExecJobStartResult = z20.strictObject({ job_id: ExecJobId, pid: z20.int().min(1), cwd: AbsPath });
1146
- var ExecJobOutputParams = z20.strictObject({
1175
+ var ExecJobStartResult = z21.strictObject({ job_id: ExecJobId, pid: z21.int().min(1), cwd: AbsPath });
1176
+ var ExecJobOutputParams = z21.strictObject({
1147
1177
  job_id: ExecJobId,
1148
1178
  /** Byte offset into the job's output to read from (next_offset of the last read; 0 = the start). */
1149
1179
  offset: nonNegInt.default(0),
1150
1180
  /** Wait up to this long for new output or the exit when none is waiting (0 answers at once). */
1151
- wait_ms: z20.int().min(0).max(25e3).default(0),
1152
- max_bytes: z20.int().min(1024).max(1048576).default(65536)
1181
+ wait_ms: z21.int().min(0).max(25e3).default(0),
1182
+ max_bytes: z21.int().min(1024).max(1048576).default(65536)
1153
1183
  });
1154
- var ExecJobOutputResult = z20.strictObject({
1184
+ var ExecJobOutputResult = z21.strictObject({
1155
1185
  /** stdout and stderr interleaved as they arrived (UTF-8). */
1156
- output: z20.string(),
1186
+ output: z21.string(),
1157
1187
  next_offset: nonNegInt,
1158
1188
  /** Bytes before `offset` that are gone (the job keeps its last 4 MiB). */
1159
1189
  dropped_bytes: nonNegInt,
1160
- running: z20.boolean(),
1161
- exit_code: z20.int().nullable()
1190
+ running: z21.boolean(),
1191
+ exit_code: z21.int().nullable()
1162
1192
  });
1163
- var ExecJobStopParams = z20.strictObject({
1193
+ var ExecJobStopParams = z21.strictObject({
1164
1194
  job_id: ExecJobId,
1165
1195
  /** End it at once (SIGKILL; on Windows the whole tree with /F) instead of asking it to quit. */
1166
- force: z20.boolean().default(false)
1196
+ force: z21.boolean().default(false)
1167
1197
  });
1168
- var ExecJobStopResult = z20.strictObject({ job_id: ExecJobId, exited: z20.boolean(), exit_code: z20.int().nullable() });
1169
- var ExecJobInfo = z20.strictObject({
1198
+ var ExecJobStopResult = z21.strictObject({ job_id: ExecJobId, exited: z21.boolean(), exit_code: z21.int().nullable() });
1199
+ var ExecJobInfo = z21.strictObject({
1170
1200
  job_id: ExecJobId,
1171
- command: z20.string().max(1024),
1172
- pid: z20.int().min(1),
1201
+ command: z21.string().max(1024),
1202
+ pid: z21.int().min(1),
1173
1203
  cwd: AbsPath,
1174
- running: z20.boolean(),
1175
- exit_code: z20.int().nullable(),
1204
+ running: z21.boolean(),
1205
+ exit_code: z21.int().nullable(),
1176
1206
  started_at_ms: epochMs,
1177
1207
  output_bytes: nonNegInt
1178
1208
  });
1179
- var ExecJobListParams = z20.strictObject({});
1180
- var ExecJobListResult = z20.strictObject({ jobs: z20.array(ExecJobInfo).max(64) });
1209
+ var ExecJobListParams = z21.strictObject({});
1210
+ var ExecJobListResult = z21.strictObject({ jobs: z21.array(ExecJobInfo).max(64) });
1181
1211
 
1182
1212
  // src/schema/coding.ts
1183
- import { z as z21 } from "zod";
1184
- var CodingServiceCredentials = z21.strictObject({
1185
- access_token: z21.string().min(16).max(16384),
1186
- user_id: z21.string().regex(/^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/),
1213
+ import { z as z22 } from "zod";
1214
+ var CodingServiceCredentials = z22.strictObject({
1215
+ access_token: z22.string().min(16).max(16384),
1216
+ user_id: z22.string().regex(/^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/),
1187
1217
  /** The AI Matrx server this app talks to (production, or a local server on the nightly copy). */
1188
- server_url: z21.string().min(1).max(2048).regex(/^https?:\/\/[^\s/?#]+(\/[^\s?#]*)?$/)
1218
+ server_url: z22.string().min(1).max(2048).regex(/^https?:\/\/[^\s/?#]+(\/[^\s?#]*)?$/)
1189
1219
  });
1190
- var CodingHistoryBlocked = z21.enum([
1220
+ var CodingHistoryBlocked = z22.enum([
1191
1221
  "signed_out",
1192
1222
  "offline",
1193
1223
  "organization_required",
@@ -1195,11 +1225,11 @@ var CodingHistoryBlocked = z21.enum([
1195
1225
  "cloud_list_unavailable",
1196
1226
  "history_too_large"
1197
1227
  ]);
1198
- var CodingHistoryFailure = z21.strictObject({
1199
- session_id: z21.string().max(64),
1200
- reason: z21.string().max(300)
1228
+ var CodingHistoryFailure = z22.strictObject({
1229
+ session_id: z22.string().max(64),
1230
+ reason: z22.string().max(300)
1201
1231
  });
1202
- var CodingHistoryRun = z21.strictObject({
1232
+ var CodingHistoryRun = z22.strictObject({
1203
1233
  /** Claude Code sessions found on this computer. */
1204
1234
  local_sessions: nonNegInt,
1205
1235
  /** Of those, already complete in AI Matrx. */
@@ -1214,39 +1244,39 @@ var CodingHistoryRun = z21.strictObject({
1214
1244
  /** Changed while being read; a later run takes them. */
1215
1245
  changed: nonNegInt,
1216
1246
  failed: nonNegInt,
1217
- failures: z21.array(CodingHistoryFailure).max(20),
1247
+ failures: z22.array(CodingHistoryFailure).max(20),
1218
1248
  /** Candidates not reached yet. */
1219
1249
  remaining: nonNegInt,
1220
1250
  /** The one line a person reads, e.g. "Imported 12 of 14 sessions. 140 already in AI Matrx." */
1221
- summary: z21.string().max(400)
1251
+ summary: z22.string().max(400)
1222
1252
  });
1223
- var CodingHistoryStep = z21.strictObject({
1253
+ var CodingHistoryStep = z22.strictObject({
1224
1254
  /** Null when the run could not start (blocked before a plan existed). */
1225
- plan_id: z21.string().regex(/^[0-9a-f]{32}$/).nullable(),
1226
- finished: z21.boolean(),
1255
+ plan_id: z22.string().regex(/^[0-9a-f]{32}$/).nullable(),
1256
+ finished: z22.boolean(),
1227
1257
  blocked: CodingHistoryBlocked.nullable(),
1228
1258
  run: CodingHistoryRun
1229
1259
  });
1230
- var CodingPlanMissingParams = z21.strictObject({ credentials: CodingServiceCredentials.nullable() });
1231
- var CodingImportNextParams = z21.strictObject({
1232
- plan_id: z21.string().regex(/^[0-9a-f]{32}$/),
1260
+ var CodingPlanMissingParams = z22.strictObject({ credentials: CodingServiceCredentials.nullable() });
1261
+ var CodingImportNextParams = z22.strictObject({
1262
+ plan_id: z22.string().regex(/^[0-9a-f]{32}$/),
1233
1263
  credentials: CodingServiceCredentials.nullable()
1234
1264
  });
1235
- var CodingServiceProgress = z21.strictObject({
1236
- phase: z21.enum(["checking", "importing"]),
1265
+ var CodingServiceProgress = z22.strictObject({
1266
+ phase: z22.enum(["checking", "importing"]),
1237
1267
  done: nonNegInt,
1238
1268
  total: nonNegInt
1239
1269
  });
1240
- var CodingHistoryImportMissingParams = z21.strictObject({});
1241
- var CodingHistoryImportMissingResult = z21.strictObject({
1242
- state: z21.enum(["done", "blocked", "cancelled"]),
1270
+ var CodingHistoryImportMissingParams = z22.strictObject({});
1271
+ var CodingHistoryImportMissingResult = z22.strictObject({
1272
+ state: z22.enum(["done", "blocked", "cancelled"]),
1243
1273
  blocked: CodingHistoryBlocked.nullable(),
1244
1274
  run: CodingHistoryRun,
1245
1275
  elapsed_ms: nonNegInt
1246
1276
  });
1247
- var CodingHistoryProgressEvent = z21.strictObject({
1277
+ var CodingHistoryProgressEvent = z22.strictObject({
1248
1278
  request_id: RequestId,
1249
- phase: z21.enum(["checking", "importing"]),
1279
+ phase: z22.enum(["checking", "importing"]),
1250
1280
  /** Sessions settled so far, of `total` candidates (0 of 0 while checking). */
1251
1281
  done: nonNegInt,
1252
1282
  total: nonNegInt,
@@ -1255,22 +1285,22 @@ var CodingHistoryProgressEvent = z21.strictObject({
1255
1285
  });
1256
1286
 
1257
1287
  // src/schema/apps.ts
1258
- import { z as z22 } from "zod";
1259
- var AppKey = z22.string().regex(/^[a-z][a-z0-9_-]{0,39}$/);
1260
- var AppProfileId = z22.string().regex(/^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/);
1261
- var AppProfileLocator = z22.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}$/);
1262
- var AppSupport = z22.enum(["supported", "partial", "unsupported"]);
1263
- var AppFeatureStatus = z22.strictObject({
1288
+ import { z as z23 } from "zod";
1289
+ var AppKey = z23.string().regex(/^[a-z][a-z0-9_-]{0,39}$/);
1290
+ var AppProfileId = z23.string().regex(/^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/);
1291
+ var AppProfileLocator = z23.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}$/);
1292
+ var AppSupport = z23.enum(["supported", "partial", "unsupported"]);
1293
+ var AppFeatureStatus = z23.strictObject({
1264
1294
  status: AppSupport,
1265
1295
  /** One line, set whenever status is not "supported". */
1266
- reason: z22.string().max(140).nullable()
1296
+ reason: z23.string().max(140).nullable()
1267
1297
  });
1268
- var AppInfo = z22.strictObject({
1298
+ var AppInfo = z23.strictObject({
1269
1299
  app_key: AppKey,
1270
- name: z22.string().max(64),
1271
- installed: z22.boolean(),
1300
+ name: z23.string().max(64),
1301
+ installed: z23.boolean(),
1272
1302
  /** The app's own version string, or null when it is not installed or does not say. */
1273
- version: z22.string().max(64).nullable(),
1303
+ version: z23.string().max(64).nullable(),
1274
1304
  /** The install found (an .app bundle, an .exe, a binary), or null. */
1275
1305
  location: AbsPath.nullable(),
1276
1306
  /** Open the app at all on this OS. */
@@ -1280,69 +1310,69 @@ var AppInfo = z22.strictObject({
1280
1310
  /** Plan usage read from the app's own files on this OS. */
1281
1311
  usage: AppFeatureStatus
1282
1312
  });
1283
- var AppUsageReading = z22.strictObject({
1284
- window: z22.enum(["five_hour", "weekly", "extra"]),
1313
+ var AppUsageReading = z23.strictObject({
1314
+ window: z23.enum(["five_hour", "weekly", "extra"]),
1285
1315
  /** 0–100 for five_hour and weekly; extra-usage spend as a percent of its cap (may pass 100). */
1286
- percent: z22.number().min(0).max(1e4),
1316
+ percent: z23.number().min(0).max(1e4),
1287
1317
  /** When the app recorded it. */
1288
1318
  sampled_at_ms: epochMs,
1289
1319
  /** True when the window has rolled over since the sample, so the figure has reset. */
1290
- reset_since: z22.boolean()
1320
+ reset_since: z23.boolean()
1291
1321
  });
1292
- var AppProfile = z22.strictObject({
1322
+ var AppProfile = z23.strictObject({
1293
1323
  /** The row's id; null for a folder found on disk that no row names yet. */
1294
1324
  id: AppProfileId.nullable(),
1295
1325
  app_key: AppKey,
1296
- display_name: z22.string().min(1).max(120),
1326
+ display_name: z23.string().min(1).max(120),
1297
1327
  /** The account the person means to be signed in here; null when not stated (never guessed). */
1298
- account_identity: z22.string().min(3).max(320).nullable(),
1328
+ account_identity: z23.string().min(3).max(320).nullable(),
1299
1329
  profile_locator: AppProfileLocator.nullable(),
1300
1330
  /** The device the row is tied to; null when the row names none. */
1301
1331
  device_id: DeviceId.nullable(),
1302
1332
  /** The folder this profile resolves to on this device; null for a row tied to another device. */
1303
1333
  folder: AbsPath.nullable(),
1304
1334
  /** The folder exists on this device. */
1305
- on_disk: z22.boolean(),
1335
+ on_disk: z23.boolean(),
1306
1336
  /** An instance with this profile is running; null when it could not be determined. */
1307
- running: z22.boolean().nullable(),
1337
+ running: z23.boolean().nullable(),
1308
1338
  /** Usage the app recorded for this profile; null when the app exposes none here. */
1309
- usage: z22.array(AppUsageReading).nullable(),
1339
+ usage: z23.array(AppUsageReading).nullable(),
1310
1340
  last_opened_ms: epochMs.nullable()
1311
1341
  });
1312
- var AppsListParams = z22.strictObject({});
1313
- var AppsListResult = z22.strictObject({ apps: z22.array(AppInfo) });
1314
- var AppsProfilesListParams = z22.strictObject({
1342
+ var AppsListParams = z23.strictObject({});
1343
+ var AppsListResult = z23.strictObject({ apps: z23.array(AppInfo) });
1344
+ var AppsProfilesListParams = z23.strictObject({
1315
1345
  /** Only this app's profiles; every app's when absent. */
1316
1346
  app_key: AppKey.optional()
1317
1347
  });
1318
- var AppsProfilesListResult = z22.strictObject({
1319
- profiles: z22.array(AppProfile),
1348
+ var AppsProfilesListResult = z23.strictObject({
1349
+ profiles: z23.array(AppProfile),
1320
1350
  /**
1321
1351
  * Whether the saved rows could be read: false while signed out or offline, when only folders
1322
1352
  * found on disk are listed.
1323
1353
  */
1324
- registry: z22.enum(["ok", "signed_out", "unavailable"])
1354
+ registry: z23.enum(["ok", "signed_out", "unavailable"])
1325
1355
  });
1326
- var AppsProfilesSaveParams = z22.strictObject({
1356
+ var AppsProfilesSaveParams = z23.strictObject({
1327
1357
  id: AppProfileId.optional(),
1328
1358
  app_key: AppKey,
1329
- display_name: z22.string().min(1).max(120),
1330
- account_identity: z22.string().min(3).max(320).nullable(),
1359
+ display_name: z23.string().min(1).max(120),
1360
+ account_identity: z23.string().min(3).max(320).nullable(),
1331
1361
  /** On create: the folder to use (one found on disk), or null for the app's default profile. Ignored on update. */
1332
1362
  profile_locator: AppProfileLocator.nullable(),
1333
1363
  /** On create with profile_locator null: make a new folder named after display_name instead. */
1334
- new_folder: z22.boolean().default(false)
1364
+ new_folder: z23.boolean().default(false)
1335
1365
  });
1336
1366
  var AppsProfilesSaveResult = AppProfile;
1337
- var AppsProfilesRemoveParams = z22.strictObject({ id: AppProfileId });
1338
- var AppsProfilesRemoveResult = z22.strictObject({ removed: z22.boolean() });
1339
- var AppsOpenParams = z22.strictObject({
1367
+ var AppsProfilesRemoveParams = z23.strictObject({ id: AppProfileId });
1368
+ var AppsProfilesRemoveResult = z23.strictObject({ removed: z23.boolean() });
1369
+ var AppsOpenParams = z23.strictObject({
1340
1370
  app_key: AppKey,
1341
1371
  profile_id: AppProfileId.optional()
1342
1372
  });
1343
- var AppsOpenResult = z22.strictObject({
1373
+ var AppsOpenResult = z23.strictObject({
1344
1374
  /** True when an instance with this profile was already running; it is brought forward. */
1345
- already_running: z22.boolean(),
1375
+ already_running: z23.boolean(),
1346
1376
  folder: AbsPath.nullable()
1347
1377
  });
1348
1378
 
@@ -1411,6 +1441,9 @@ var OPS = {
1411
1441
  "power.status": { params: PowerStatusParams, result: PowerStatusResult, kind: "unary", since: "1.4", errors: ["INTERNAL"] },
1412
1442
  "power.prevent_sleep": { params: PowerPreventSleepParams, result: PowerPreventSleepResult, kind: "unary", since: "1.4", errors: ["PERMISSION_DENIED_OS", "PLATFORM_UNSUPPORTED", "INTERNAL"] },
1413
1443
  "resources.snapshot": { params: ResourcesSnapshotParams, result: ResourcesSnapshotResult, kind: "unary", since: "1.4", errors: ["INTERNAL"] },
1444
+ "audio.devices": { params: AudioDevicesParams, result: AudioDevicesResult, kind: "unary", since: "1.6", errors: ["PLATFORM_UNSUPPORTED", "INTERNAL"] },
1445
+ "audio.record": { params: AudioRecordParams, result: AudioRecordResult, kind: "unary", since: "1.6", errors: ["NOT_FOUND", "PERMISSION_DENIED_OS", "PLATFORM_UNSUPPORTED", "RESOURCE_BUSY", "INTERNAL"] },
1446
+ "audio.play": { params: AudioPlayParams, result: AudioPlayResult, kind: "unary", since: "1.6", errors: ["NOT_FOUND", "INVALID_PARAMS", "PLATFORM_UNSUPPORTED", "INTERNAL"] },
1414
1447
  // Claude Code history (SPEC §6 coding): served by the `coding` Python service through SERVICES below.
1415
1448
  "coding.history.import_missing": { params: CodingHistoryImportMissingParams, result: CodingHistoryImportMissingResult, kind: "unary", since: "1.5", errors: ["RESOURCE_BUSY", "RESOURCE_GONE", "CANCELLED", "INTERNAL"] }
1416
1449
  };