@ai-matrx/desktop-protocol 0.21.65 → 0.21.67

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,7 +1,8 @@
1
1
  # Changelog
2
2
 
3
- ## 0.21.65
3
+ ## 0.21.67
4
4
 
5
+ - **Protocol 1.67 — Matrx Local's local_mac_apps and local_windows_ps contracts, carried whole (2026-10-21).** Every parameter and result field those two dispatchers had now has a home: `mail.send` `bcc`; `mail.accounts` `mailboxes`; `messages.list` `contact` / `unread_only` (+ `read`, `service`, `chat_name`); `messages.chats` `last_message`; `contacts.search` without a `query` (the first `limit`); `calendar.list` `calendars` (+ `url`); `reminders.list` `lists` (+ `priority`, `completed_at_ms`); `photos.search` `media_type` (+ `media_type`, `duration_s`); `photos.get` `thumbnail_size` (+ `thumbnail_png_base64`); `location.get` `altitude_m`, `vertical_accuracy_m`, `speed_mps`, `course_deg`; `windows.services` `status`; `windows.service_control` `pause` / `resume`; `windows.event_log` `source`; `windows.features` `installed_only`. Optional; result fields stripped for a 1.66 peer by `forPeer`. Consumer action: Matrx 2's core serves them (matrx-desktop test/unit/legacy-contract-parity.test.ts).
5
6
  - **Protocol 1.66 — matrx-local's window and audio contracts on Matrx 2 (2026-10-21).** `window.list` takes `app` (owning app name substring, local_window's app_filter); `window.minimize` takes `mode` minimize / maximize / restore (local_window's window_action) and echoes it; `audio.record` takes `channels` and `sample_rate` and reports both; `audio.play` takes `device_id` (an output from audio.devices). Optional fields only, in FIELDS_SINCE; an older core refuses the new params as INVALID_PARAMS. Consumer action: none.
6
7
  - **Protocol 1.65 — "Continued from <account>" is a transcript item (2026-10-21).** `CodingTranscriptItem` gains `continued` (`id`, `from`, `text`, `at`): the line across a coding chat where it moved from another account (@ai-matrx/coding-sessions emits it where it used to emit an info `notice`). `forPeer` sends a 1.64 peer's `coding.history` / `coding.transcript.read` each as that `notice`, so its strict union never refuses the whole transcript. Consumer action: draw it as a divider at its place (the coding-sessions screen does).
7
8
  - **Protocol 1.64 — agent versions in Matrx 2 (2026-10-21).** New ops `account.agents.versions` (an agent's saved versions: number, age, note; the current version), `account.agents.version_diff` (one version and the current one as agent-definition records for `@ai-matrx/agents/versions/react` AgentDiffViewer) and `account.agents.restore_version` (`agx_promote_version`). New ops only; an older peer never sees them. Consumer action: none.
@@ -6,7 +6,7 @@ import {
6
6
  import { z } from "zod";
7
7
  import { UUID_SHAPE_PATTERN } from "@ai-matrx/kit/uuid";
8
8
  var PROTOCOL_MAJOR = 1;
9
- var PROTOCOL_MINOR = 66;
9
+ var PROTOCOL_MINOR = 67;
10
10
  var PROTOCOL_VERSION = `${PROTOCOL_MAJOR}.${PROTOCOL_MINOR}`;
11
11
  var ProtocolVersion = z.string().regex(/^[1-9][0-9]{0,2}\.[0-9]{1,3}$/);
12
12
  var RequestId = z.string().min(1).max(64).regex(/^[A-Za-z0-9_-]+$/);
@@ -3058,7 +3058,7 @@ var AudioRecordParams = z30.strictObject({
3058
3058
  path: AbsPath.optional(),
3059
3059
  /** (1.66) 1 (mono, the default) or 2 (stereo). */
3060
3060
  channels: z30.int().min(1).max(2).optional(),
3061
- /** (1.66) Samples per second; the device's own rate when absent. */
3061
+ /** (1.66) Samples per second; 16000 when absent (the rate Whisper reads). */
3062
3062
  sample_rate: z30.int().min(8e3).max(192e3).optional()
3063
3063
  });
3064
3064
  var AudioRecordResult = z30.strictObject({
@@ -3957,7 +3957,13 @@ var AutomationScriptResult = z37.strictObject({
3957
3957
  elapsed_ms: nonNegInt
3958
3958
  });
3959
3959
  var MailAccountsParams = z37.strictObject({});
3960
- var MailAccount = z37.strictObject({ name: z37.string(), emails: z37.array(z37.string()), enabled: z37.boolean() });
3960
+ var MailAccount = z37.strictObject({
3961
+ name: z37.string(),
3962
+ emails: z37.array(z37.string()),
3963
+ enabled: z37.boolean(),
3964
+ /** (1.67) The account's mailboxes by name (Matrx Local's email_accounts listed them). */
3965
+ mailboxes: z37.array(z37.string()).optional()
3966
+ });
3961
3967
  var MailAccountsResult = z37.strictObject({ accounts: z37.array(MailAccount) });
3962
3968
  var MailListParams = z37.strictObject({
3963
3969
  /** The account's name in Mail; absent: every account. */
@@ -3982,6 +3988,8 @@ var MailListResult = z37.strictObject({ messages: z37.array(MailMessage) });
3982
3988
  var MailSendParams = z37.strictObject({
3983
3989
  to: z37.array(z37.string().min(3).max(320)).min(1).max(50),
3984
3990
  cc: z37.array(z37.string().min(3).max(320)).max(50).default([]),
3991
+ /** (1.67) Blind copies (Matrx Local's send_email bcc). */
3992
+ bcc: z37.array(z37.string().min(3).max(320)).max(50).optional(),
3985
3993
  subject: z37.string().max(998),
3986
3994
  body: Text,
3987
3995
  /** The sending account's address; absent: Mail's default. */
@@ -4060,13 +4068,19 @@ var MessagesChat = z37.strictObject({
4060
4068
  name: z37.string().nullable(),
4061
4069
  participants: z37.array(z37.string()),
4062
4070
  last_message_at_ms: epochMs.nullable(),
4063
- service: z37.string().nullable()
4071
+ service: z37.string().nullable(),
4072
+ /** (1.67) The newest message's text (Matrx Local's list_conversations preview); absent when it has none. */
4073
+ last_message: z37.string().optional()
4064
4074
  });
4065
4075
  var MessagesChatsResult = z37.strictObject({ chats: z37.array(MessagesChat) });
4066
4076
  var MessagesListParams = z37.strictObject({
4067
4077
  /** One chat (messages.chats' chat_id); absent: the newest across all. */
4068
4078
  chat_id: z37.string().min(1).max(512).optional(),
4069
- limit: z37.int().min(1).max(500).default(50)
4079
+ limit: z37.int().min(1).max(500).default(50),
4080
+ /** (1.67) Only messages with this handle or chat name in them (partial: a phone, an email, a name). */
4081
+ contact: z37.string().min(1).max(320).optional(),
4082
+ /** (1.67) Only messages not yet read. */
4083
+ unread_only: z37.boolean().optional()
4070
4084
  });
4071
4085
  var MessagesMessage = z37.strictObject({
4072
4086
  id: z37.string(),
@@ -4075,7 +4089,13 @@ var MessagesMessage = z37.strictObject({
4075
4089
  from_me: z37.boolean(),
4076
4090
  /** The other person's handle (phone or email); null for the person's own messages. */
4077
4091
  sender: z37.string().nullable(),
4078
- sent_at_ms: epochMs.nullable()
4092
+ sent_at_ms: epochMs.nullable(),
4093
+ /** (1.67) Whether it has been read. */
4094
+ read: z37.boolean().optional(),
4095
+ /** (1.67) iMessage, SMS or RCS, as the Messages database says. */
4096
+ service: z37.string().optional(),
4097
+ /** (1.67) The chat's name (group chats); absent for a one-to-one chat. */
4098
+ chat_name: z37.string().optional()
4079
4099
  });
4080
4100
  var MessagesListResult = z37.strictObject({ messages: z37.array(MessagesMessage) });
4081
4101
  var MessagesSendParams = z37.strictObject({
@@ -4090,8 +4110,8 @@ var MessagesSendParams = z37.strictObject({
4090
4110
  });
4091
4111
  var MessagesSendResult = z37.strictObject({ sent: z37.boolean() });
4092
4112
  var ContactsSearchParams = z37.strictObject({
4093
- /** Matched against names, organizations, emails and phone numbers. */
4094
- query: z37.string().min(1).max(256),
4113
+ /** Matched against names, organizations, emails and phone numbers; absent (1.67): the first `limit` contacts. */
4114
+ query: z37.string().min(1).max(256).optional(),
4095
4115
  limit: z37.int().min(1).max(200).default(25)
4096
4116
  });
4097
4117
  var ContactLabeled = z37.strictObject({ label: z37.string().nullable(), value: z37.string() });
@@ -4121,6 +4141,8 @@ var CalendarListParams = z37.strictObject({
4121
4141
  to_ms: epochMs,
4122
4142
  /** One calendar's name; absent: every calendar. */
4123
4143
  calendar: z37.string().min(1).max(256).optional(),
4144
+ /** (1.67) Several calendars by name (Matrx Local's calendar_names); with `calendar`, both count. */
4145
+ calendars: z37.array(z37.string().min(1).max(256)).min(1).max(100).optional(),
4124
4146
  limit: z37.int().min(1).max(500).default(100)
4125
4147
  });
4126
4148
  var CalendarEvent = z37.strictObject({
@@ -4131,7 +4153,9 @@ var CalendarEvent = z37.strictObject({
4131
4153
  all_day: z37.boolean(),
4132
4154
  calendar: z37.string(),
4133
4155
  location: z37.string().nullable(),
4134
- notes: z37.string().nullable()
4156
+ notes: z37.string().nullable(),
4157
+ /** (1.67) The event's link; absent when it has none. */
4158
+ url: z37.string().optional()
4135
4159
  });
4136
4160
  var CalendarListResult = z37.strictObject({ events: z37.array(CalendarEvent) });
4137
4161
  var CalendarCreateParams = z37.strictObject({
@@ -4148,6 +4172,8 @@ var CalendarCreateResult = z37.strictObject({ id: z37.string(), calendar: z37.st
4148
4172
  var RemindersListParams = z37.strictObject({
4149
4173
  /** One list's name; absent: every list. */
4150
4174
  list: z37.string().min(1).max(256).optional(),
4175
+ /** (1.67) Several lists by name (Matrx Local's list_names); with `list`, both count. */
4176
+ lists: z37.array(z37.string().min(1).max(256)).min(1).max(100).optional(),
4151
4177
  include_completed: z37.boolean().default(false),
4152
4178
  limit: z37.int().min(1).max(500).default(100)
4153
4179
  });
@@ -4157,7 +4183,11 @@ var Reminder = z37.strictObject({
4157
4183
  list: z37.string(),
4158
4184
  due_ms: epochMs.nullable(),
4159
4185
  completed: z37.boolean(),
4160
- notes: z37.string().nullable()
4186
+ notes: z37.string().nullable(),
4187
+ /** (1.67) 0 none, 1 high … 9 low (EventKit's scale). */
4188
+ priority: z37.int().min(0).max(9).optional(),
4189
+ /** (1.67) When it was completed; absent while open. */
4190
+ completed_at_ms: epochMs.optional()
4161
4191
  });
4162
4192
  var RemindersListResult = z37.strictObject({ reminders: z37.array(Reminder) });
4163
4193
  var RemindersCreateParams = z37.strictObject({
@@ -4173,6 +4203,8 @@ var PhotosSearchParams = z37.strictObject({
4173
4203
  from_ms: epochMs.optional(),
4174
4204
  to_ms: epochMs.optional(),
4175
4205
  favorites_only: z37.boolean().default(false),
4206
+ /** (1.67) image, video or all (Matrx Local's media_type); absent: all. */
4207
+ media_type: z37.enum(["image", "video", "all"]).optional(),
4176
4208
  limit: z37.int().min(1).max(200).default(25)
4177
4209
  });
4178
4210
  var Photo = z37.strictObject({
@@ -4182,15 +4214,26 @@ var Photo = z37.strictObject({
4182
4214
  width: nonNegInt.nullable(),
4183
4215
  height: nonNegInt.nullable(),
4184
4216
  favorite: z37.boolean(),
4185
- title: z37.string().nullable()
4217
+ title: z37.string().nullable(),
4218
+ /** (1.67) What the asset is. */
4219
+ media_type: z37.enum(["image", "video", "audio", "unknown"]).optional(),
4220
+ /** (1.67) A video's length in seconds; absent for a still. */
4221
+ duration_s: z37.number().min(0).optional()
4186
4222
  });
4187
4223
  var PhotosSearchResult = z37.strictObject({ photos: z37.array(Photo) });
4188
4224
  var PhotosGetParams = z37.strictObject({
4189
4225
  id: z37.string().min(1).max(256),
4190
4226
  /** Copy the original into a folder Matrx 2 owns and answer its path (then fs_read or desktop_documents reads it). */
4191
- export: z37.boolean().default(false)
4227
+ export: z37.boolean().default(false),
4228
+ /** (1.67) Also answer a PNG thumbnail no larger than this many pixels a side (Matrx Local's get_photo thumbnail). */
4229
+ thumbnail_size: z37.int().min(64).max(2048).optional()
4230
+ });
4231
+ var PhotosGetResult = z37.strictObject({
4232
+ photo: Photo,
4233
+ path: z37.string().nullable(),
4234
+ /** (1.67) The thumbnail as base64 PNG, when thumbnail_size asked for one; absent when it could not be drawn. */
4235
+ thumbnail_png_base64: z37.string().optional()
4192
4236
  });
4193
- var PhotosGetResult = z37.strictObject({ photo: Photo, path: z37.string().nullable() });
4194
4237
  var LocationGetParams = z37.strictObject({ timeout_s: z37.int().min(1).max(60).default(15) });
4195
4238
  var LocationGetResult = z37.strictObject({
4196
4239
  latitude: z37.number().min(-90).max(90),
@@ -4199,7 +4242,12 @@ var LocationGetResult = z37.strictObject({
4199
4242
  accuracy_m: z37.number().min(0).nullable(),
4200
4243
  at_ms: epochMs,
4201
4244
  /** Who answered: the OS's own location service. */
4202
- source: z37.enum(["corelocation", "windows", "geoclue"])
4245
+ source: z37.enum(["corelocation", "windows", "geoclue"]),
4246
+ /** (1.67) Metres above sea level, its accuracy, speed (m/s) and course (degrees); absent where the OS does not say. */
4247
+ altitude_m: z37.number().optional(),
4248
+ vertical_accuracy_m: z37.number().min(0).optional(),
4249
+ speed_mps: z37.number().min(0).optional(),
4250
+ course_deg: z37.number().min(0).max(360).optional()
4203
4251
  });
4204
4252
 
4205
4253
  // src/schema/windows.ts
@@ -4231,6 +4279,8 @@ var WindowsRegistryWriteResult = z38.strictObject({ key: z38.string(), name: z38
4231
4279
  var WindowsServicesParams = z38.strictObject({
4232
4280
  /** Matched against the service's name and display name. */
4233
4281
  filter: z38.string().min(1).max(256).optional(),
4282
+ /** (1.67) Only services in this state (Matrx Local's service_list status). */
4283
+ status: z38.enum(["running", "stopped", "paused"]).optional(),
4234
4284
  limit: z38.int().min(1).max(1e3).default(200)
4235
4285
  });
4236
4286
  var WindowsService = z38.strictObject({
@@ -4244,7 +4294,8 @@ var WindowsService = z38.strictObject({
4244
4294
  var WindowsServicesResult = z38.strictObject({ services: z38.array(WindowsService) });
4245
4295
  var WindowsServiceControlParams = z38.strictObject({
4246
4296
  name: z38.string().min(1).max(256),
4247
- action: z38.enum(["start", "stop", "restart"])
4297
+ /** pause and resume since 1.67 (Matrx Local's service_control). */
4298
+ action: z38.enum(["start", "stop", "restart", "pause", "resume"])
4248
4299
  });
4249
4300
  var WindowsServiceControlResult = z38.strictObject({ name: z38.string(), status: z38.string() });
4250
4301
  var WindowsEventLogParams = z38.strictObject({
@@ -4252,6 +4303,8 @@ var WindowsEventLogParams = z38.strictObject({
4252
4303
  /** Only these levels; absent: all. */
4253
4304
  levels: z38.array(z38.enum(["critical", "error", "warning", "information", "verbose"])).max(5).optional(),
4254
4305
  since_ms: epochMs.optional(),
4306
+ /** (1.67) Only events whose source (provider) name contains this. */
4307
+ source: z38.string().min(1).max(256).optional(),
4255
4308
  limit: z38.int().min(1).max(500).default(50)
4256
4309
  });
4257
4310
  var WindowsEvent = z38.strictObject({
@@ -4262,7 +4315,11 @@ var WindowsEvent = z38.strictObject({
4262
4315
  message: z38.string()
4263
4316
  });
4264
4317
  var WindowsEventLogResult = z38.strictObject({ log: z38.string(), events: z38.array(WindowsEvent) });
4265
- var WindowsFeaturesParams = z38.strictObject({ filter: z38.string().min(1).max(256).optional() });
4318
+ var WindowsFeaturesParams = z38.strictObject({
4319
+ filter: z38.string().min(1).max(256).optional(),
4320
+ /** (1.67) Only features that are on (Matrx Local's windows_features installed_only). */
4321
+ installed_only: z38.boolean().optional()
4322
+ });
4266
4323
  var WindowsFeature = z38.strictObject({ name: z38.string(), state: z38.string() });
4267
4324
  var WindowsFeaturesResult = z38.strictObject({ features: z38.array(WindowsFeature) });
4268
4325
 
@@ -5670,6 +5727,24 @@ var FIELDS_SINCE = {
5670
5727
  SysinfoGetResult: { requirements: "1.41" },
5671
5728
  "SysinfoGetResult.permissions[]": { detail: "1.41" },
5672
5729
  MessagesSendParams: { service: "1.42" },
5730
+ // 1.67: Matrx Local's local_mac_apps and local_windows_ps contracts, carried whole.
5731
+ MailAccount: { mailboxes: "1.67" },
5732
+ MailSendParams: { bcc: "1.67" },
5733
+ MessagesChat: { last_message: "1.67" },
5734
+ MessagesListParams: { contact: "1.67", unread_only: "1.67" },
5735
+ MessagesMessage: { read: "1.67", service: "1.67", chat_name: "1.67" },
5736
+ CalendarListParams: { calendars: "1.67" },
5737
+ CalendarEvent: { url: "1.67" },
5738
+ RemindersListParams: { lists: "1.67" },
5739
+ Reminder: { priority: "1.67", completed_at_ms: "1.67" },
5740
+ PhotosSearchParams: { media_type: "1.67" },
5741
+ Photo: { media_type: "1.67", duration_s: "1.67" },
5742
+ PhotosGetParams: { thumbnail_size: "1.67" },
5743
+ PhotosGetResult: { thumbnail_png_base64: "1.67" },
5744
+ LocationGetResult: { altitude_m: "1.67", vertical_accuracy_m: "1.67", speed_mps: "1.67", course_deg: "1.67" },
5745
+ WindowsServicesParams: { status: "1.67" },
5746
+ WindowsEventLogParams: { source: "1.67" },
5747
+ WindowsFeaturesParams: { installed_only: "1.67" },
5673
5748
  SysinfoHardwareResult: { graphics: "1.45" },
5674
5749
  DownloadRow: { error: "1.46" },
5675
5750
  CopyRestart: { reopened: "1.60" }
@@ -5754,7 +5829,10 @@ var RESULT_PATH = /* @__PURE__ */ new Map([
5754
5829
  ["web.fetch_with_browser", "WebBrowserFetchResult"],
5755
5830
  ["sysinfo.get", "SysinfoGetResult"],
5756
5831
  ["sysinfo.hardware", "SysinfoHardwareResult"],
5757
- ["apps.projects.to_window", "AppsProjectsToWindowResult"]
5832
+ ["apps.projects.to_window", "AppsProjectsToWindowResult"],
5833
+ // 1.67: Matrx Local's local_mac_apps result fields.
5834
+ ["photos.get", "PhotosGetResult"],
5835
+ ["location.get", "LocationGetResult"]
5758
5836
  ]);
5759
5837
  var NESTED_RESULTS = /* @__PURE__ */ new Map([
5760
5838
  ["apps.chats.list", [["chats", "ChatRow"]]],
@@ -5778,6 +5856,14 @@ var NESTED_RESULTS = /* @__PURE__ */ new Map([
5778
5856
  // 1.63: what an instance record still lacks.
5779
5857
  ["apps.instances.list", [["instances", "AppInstance"]]],
5780
5858
  ["apps.windows.set_remote_control", [["remote_control", "WindowRemoteControl"]]],
5859
+ // 1.67: Matrx Local's local_mac_apps result fields.
5860
+ ["mail.accounts", [["accounts", "MailAccount"]]],
5861
+ ["messages.chats", [["chats", "MessagesChat"]]],
5862
+ ["messages.list", [["messages", "MessagesMessage"]]],
5863
+ ["calendar.list", [["events", "CalendarEvent"]]],
5864
+ ["reminders.list", [["reminders", "Reminder"]]],
5865
+ ["photos.search", [["photos", "Photo"]]],
5866
+ ["photos.get", [["photo", "Photo"]]],
5781
5867
  ["coding.providers", [["providers", "CodingProviderStatus"]]],
5782
5868
  // 1.57: the account a coding record belongs to.
5783
5869
  ["coding.sessions.list", [["sessions", "CodingSessionRecord"], ["recent", "CodingRecentRow"]]],
@@ -6788,4 +6874,4 @@ export {
6788
6874
  closeRule,
6789
6875
  isTerminalClose
6790
6876
  };
6791
- //# sourceMappingURL=chunk-server-K7IQDLLV.js.map
6877
+ //# sourceMappingURL=chunk-server-AHS5QIQV.js.map