@ai-matrx/desktop-protocol 0.21.18 → 0.21.20

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/CHANGELOG.md CHANGED
@@ -1,5 +1,17 @@
1
1
  # Changelog
2
2
 
3
+ ## 0.21.20
4
+
5
+ Automatic changed-only republish (docs/metadata drift since the last tag — see
6
+ `git diff npm/desktop-protocol/v0.21.19..npm/desktop-protocol/v0.21.20 -- apps/shared/desktop-protocol`).
7
+ No source changes intended and no consumer action required.
8
+
9
+ ## 0.21.19
10
+
11
+ Automatic changed-only republish (docs/metadata drift since the last tag — see
12
+ `git diff npm/desktop-protocol/v0.21.18..npm/desktop-protocol/v0.21.19 -- apps/shared/desktop-protocol`).
13
+ No source changes intended and no consumer action required.
14
+
3
15
  ## 0.21.18
4
16
 
5
17
  Automatic changed-only republish (docs/metadata drift since the last tag — see
package/dist/client.cjs CHANGED
@@ -144,7 +144,7 @@ var import_zod2 = require("zod");
144
144
  var import_zod = require("zod");
145
145
  var import_uuid = require("@ai-matrx/kit/uuid");
146
146
  var PROTOCOL_MAJOR = 1;
147
- var PROTOCOL_MINOR = 24;
147
+ var PROTOCOL_MINOR = 26;
148
148
  var PROTOCOL_VERSION = `${PROTOCOL_MAJOR}.${PROTOCOL_MINOR}`;
149
149
  var ProtocolVersion = import_zod.z.string().regex(/^[1-9][0-9]{0,2}\.[0-9]{1,3}$/);
150
150
  var RequestId = import_zod.z.string().min(1).max(64).regex(/^[A-Za-z0-9_-]+$/);
@@ -2244,7 +2244,13 @@ var AccountUsage = import_zod30.z.strictObject({
2244
2244
  /** 1.13: the account's plan as the app names it (Codex: "pro", "prolite"), when recorded. */
2245
2245
  plan: import_zod30.z.string().max(80).optional(),
2246
2246
  /** 1.13: the account's credit balance as the app records it (Codex), when recorded. */
2247
- credits: import_zod30.z.string().max(40).optional()
2247
+ credits: import_zod30.z.string().max(40).optional(),
2248
+ /**
2249
+ * 1.25: the latest the account's 5-hour window can reset: 5 hours after the first reading of this
2250
+ * window's use (its usage history), so the real reset is at or before it. Absent when no 5-hour
2251
+ * window is running (no use in the last reading, or the reading is over 5 hours old).
2252
+ */
2253
+ five_hour_resets_by_ms: epochMs.optional()
2248
2254
  });
2249
2255
  var AccountReset = import_zod30.z.strictObject({
2250
2256
  window: ChatPlace,
@@ -2443,6 +2449,29 @@ var AppsWindowsProcessesParams = import_zod30.z.strictObject({ app_key: AppKey }
2443
2449
  var AppsWindowsProcessesResult = import_zod30.z.strictObject({ processes: import_zod30.z.array(import_zod30.z.string().max(2e3)).max(2e3) });
2444
2450
  var AppsWindowsAddParams = import_zod30.z.strictObject({ app_key: AppKey, window: ChatPlace, email: import_zod30.z.string().min(3).max(320) });
2445
2451
  var AppsWindowsSaveNamesParams = import_zod30.z.strictObject({ app_key: AppKey });
2452
+ var AppsWindowsUpdateStateParams = import_zod30.z.strictObject({ app_key: AppKey });
2453
+ var AppsWindowsUpdateStateResult = import_zod30.z.strictObject({
2454
+ app_key: AppKey,
2455
+ pending: import_zod30.z.boolean(),
2456
+ /** The downloaded release's name (Claude: "Claude 2.31226.1"), when the app's log names it. */
2457
+ version: import_zod30.z.string().max(120).nullable(),
2458
+ /** When the update became pending (the download's time), when known. */
2459
+ since_ms: epochMs.nullable(),
2460
+ /** Windows open when the update became pending (or last seen open) that are closed now. */
2461
+ closed: import_zod30.z.array(ChatPlace).max(200)
2462
+ });
2463
+ var AppsWindowsReopenParams = import_zod30.z.strictObject({ app_key: AppKey, windows: import_zod30.z.array(ChatPlace).min(1).max(200) });
2464
+ var AppsWindowsReopenResult = import_zod30.z.strictObject({ message: import_zod30.z.string().max(400), opened: import_zod30.z.array(ChatPlace).max(200) });
2465
+ var AppsWindowsUpdateAndReopenParams = import_zod30.z.strictObject({ app_key: AppKey, force: import_zod30.z.boolean().default(false), dry_run: import_zod30.z.boolean().default(false) });
2466
+ var AppsWindowsUpdateAndReopenResult = import_zod30.z.strictObject({
2467
+ message: import_zod30.z.string().max(400),
2468
+ /** Windows quit (with dry_run: to be quit). */
2469
+ quit: import_zod30.z.array(ChatPlace).max(200),
2470
+ /** Windows reopened (with dry_run: to be reopened), main first. */
2471
+ reopened: import_zod30.z.array(ChatPlace).max(200),
2472
+ /** The version installed, null when the install did not happen (or dry_run). */
2473
+ installed_version: import_zod30.z.string().max(64).nullable()
2474
+ });
2446
2475
 
2447
2476
  // src/schema/registry.ts
2448
2477
  var FS_ERR = ["NOT_FOUND", "PERMISSION_DENIED_OS", "INVALID_PARAMS", "RESOURCE_BUSY", "INTERNAL"];
@@ -2585,7 +2614,11 @@ var OPS = {
2585
2614
  // 1.23: the signed-in person's own agents and Vault, read as them (the desktop's Agents library and Vault).
2586
2615
  "account.agents.list": { params: AccountAgentsListParams, result: AccountAgentsListResult, kind: "unary", since: "1.23", errors: ["INTERNAL"] },
2587
2616
  "account.vault.list": { params: AccountVaultListParams, result: AccountVaultListResult, kind: "unary", since: "1.23", errors: ["INTERNAL"] },
2588
- "account.vault.copy": { params: AccountVaultCopyParams, result: AccountVaultCopyResult, kind: "unary", since: "1.23", errors: ["AUTH_REQUIRED", "AUTH_FORBIDDEN", "NOT_FOUND", "INVALID_PARAMS", "DEVICE_OFFLINE", "INTERNAL"] }
2617
+ "account.vault.copy": { params: AccountVaultCopyParams, result: AccountVaultCopyResult, kind: "unary", since: "1.23", errors: ["AUTH_REQUIRED", "AUTH_FORBIDDEN", "NOT_FOUND", "INVALID_PARAMS", "DEVICE_OFFLINE", "INTERNAL"] },
2618
+ // 1.26: the app's own update (it installs only once every window quit) and bringing the windows back.
2619
+ "apps.windows.update_state": { params: AppsWindowsUpdateStateParams, result: AppsWindowsUpdateStateResult, kind: "unary", since: "1.26", errors: ["NOT_FOUND", "PLATFORM_UNSUPPORTED", "INTERNAL"] },
2620
+ "apps.windows.reopen": { params: AppsWindowsReopenParams, result: AppsWindowsReopenResult, kind: "unary", since: "1.26", errors: ["NOT_FOUND", "PLATFORM_UNSUPPORTED", "INTERNAL"] },
2621
+ "apps.windows.update_and_reopen": { params: AppsWindowsUpdateAndReopenParams, result: AppsWindowsUpdateAndReopenResult, kind: "unary", since: "1.26", errors: ["NOT_FOUND", "CONFLICT", "TIMEOUT", "PLATFORM_UNSUPPORTED", "INTERNAL"] }
2589
2622
  };
2590
2623
  var EVENTS = {
2591
2624
  "fs.changed": FsChangedEvent,